export type AdminInventoryCreateInput = {
  skuCode?: string
  displayValue?: string
  batchNo?: string
  credentialType?: string
  inventoryGroupCode?: string
}

export type AdminInventoryImportRowInput = {
  skuCode?: string
  displayValue?: string
  batchNo?: string
  credentialType?: string
  inventoryGroupCode?: string
}

export type AdminInventoryImportInput = {
  rows?: AdminInventoryImportRowInput[]
  codes?: unknown[]
  skuCode?: string
  batchNo?: string
  credentialType?: string
  inventoryGroupCode?: string
}

export type AdminUserInventoryGroupsInput = {
  inventoryGroupCodes?: string[]
}

export type AdminAgisoMessagingDefaultsInput = {
  messageTemplate?: string
  autoDeliveryMessageTemplate?: string
}

export type AdminAgisoShopConfigWriteItemInput = {
  shopId?: string
  shopName?: string
  accessToken?: string
  enabled?: boolean | null
  messageTemplate?: string
  autoDeliveryMessageTemplate?: string
  appSecret?: string
  apiVersion?: string
  sendMessageEndpoint?: string
}

export type AdminAgisoShopConfigSaveInput = {
  defaults?: AdminAgisoMessagingDefaultsInput
  shops?: AdminAgisoShopConfigWriteItemInput[]
}

export type AdminKuaishouCloudFulfillmentItemInput = {
  id?: string
  enabled?: boolean
  priority?: number | string
  provider?: string
  platform?: string
  shopId?: string
  internalSkuCode?: string
  internalSkuName?: string
  externalSkuCode?: string
  externalItemId?: string
  externalSkuName?: string
  resolvedSkuName?: string
  cloudSourceKey?: string
  cloudSourceKeyFallbacks?: string[]
  cloudSkuId?: number | string
  cloudSkuName?: string
  vnKey?: string
  autoBuyEnabled?: boolean
  minAssetReserve?: number | string
  autoReturnNumberAfterDispatch?: boolean
  autoConsumeAfterDispatch?: boolean
  kuaishouConsumeShopId?: string
  kuaishouConsumeShopName?: string
  notes?: string
}

export type AdminKuaishouCloudFulfillmentConfigInput = {
  enabled?: boolean
  items?: AdminKuaishouCloudFulfillmentItemInput[]
}

export type AdminKuaishouEticketShopConfigWriteItemInput = {
  shopId?: string
  kshopName?: string
  cookie?: string
  userAvatar?: string
  enabled?: boolean
}

export type AdminKuaishouEticketSourceConfigInput = {
  enabled?: boolean
  baseUrl?: string
  shops?: AdminKuaishouEticketShopConfigWriteItemInput[]
}

export type AdminNotificationBarkRecipientInput = {
  id?: string
  name?: string
  deviceKey?: string
  enabled?: boolean
}

export type AdminNotificationConfigInput = {
  enabled?: boolean
  channels?: {
    bark?: {
      enabled?: boolean
      serverUrl?: string
      recipients?: AdminNotificationBarkRecipientInput[]
    }
  }
}

export type AdminNotificationTestInput = {
  title?: string
  body?: string
  url?: string
}

export type AdminScheduledJobInput = {
  id?: string
  type?: string
  enabled?: boolean
  intervalSeconds?: number | string
  cooldownSeconds?: number | string
  config?: {
    assetThreshold?: number | string
  }
}

export type AdminScheduledJobsConfigInput = {
  enabled?: boolean
  jobs?: AdminScheduledJobInput[]
}

export type AdminKuaishouEticketShopInfoInput = {
  baseUrl?: string
  shopId?: string
  cookie?: string
}

export type AdminKuaishouEticketDetailQueryInput = {
  baseUrl?: string
  shopId?: string
  cookie?: string
  eTicketId?: string
}

export type AdminKuaishouEticketConsumeInput = {
  baseUrl?: string
  shopId?: string
  cookie?: string
  eTicketId?: string
  oid?: string
  formToken?: string
  num?: number | string
  storeId?: string
}

export type AdminCloudtentaclesSourceConfigInput = {
  sourceKey?: string
  enabled?: boolean
  baseUrl?: string
  username?: string
  password?: string
  phone?: string
  deviceId?: string
  deviceType?: number | string
  sources?: AdminCloudtentaclesSourceConfigInput[]
}

export type AdminCloudtentaclesSendSmsCodeInput = {
  sourceKey?: string
  baseUrl?: string
  username?: string
  phone?: string
  deviceId?: string
  deviceType?: number | string
}

export type AdminCloudtentaclesTestLoginInput = {
  sourceKey?: string
  baseUrl?: string
  username?: string
  password?: string
  phone?: string
  code?: string
  deviceId?: string
  deviceType?: number | string
}

export type AdminCloudtentaclesValidateSessionInput = {
  sourceKey?: string
  baseUrl?: string
  token?: string
  deviceId?: string
  deviceType?: number | string
}

export type AdminCloudtentaclesCatalogQueryInput = {
  sourceKey?: string
  baseUrl?: string
  token?: string
  deviceId?: string
  deviceType?: number | string
}

export type AdminCloudtentaclesSkuBuyInput = {
  sourceKey?: string
  baseUrl?: string
  token?: string
  deviceId?: string
  deviceType?: number | string
  id?: number | string
  count?: number | string
}

export type AdminCloudtentaclesSkuUseInput = {
  sourceKey?: string
  baseUrl?: string
  token?: string
  deviceId?: string
  deviceType?: number | string
  id?: number | string
  virtualNumberId?: number | string
  phone?: string
}

export type AdminCloudtentaclesVirtualNumberInput = {
  sourceKey?: string
  baseUrl?: string
  token?: string
  deviceId?: string
  deviceType?: number | string
  key?: string
  id?: number | string
  phone?: string
  code?: string
}

export type AdminCloudtentaclesFullFlowInput = {
  sourceKey?: string
  baseUrl?: string
  token?: string
  deviceId?: string
  deviceType?: number | string
  skuId?: number | string
  skuCount?: number | string
  vnKey?: string
}

export type AdminFulfillmentBindingLookupInput = {
  provider?: string
  platform?: string
  shopId?: string
  platformOrderId?: string
}

export type AdminFulfillmentBindingConfigWriteItemInput = {
  provider?: string
  platform?: string
  shopId?: string
  shopName?: string
  skuCode?: string
  skuName?: string
  profileKey?: string
  enabled?: boolean
  priority?: number | string
  config?: Record<string, unknown>
  match?: {
    externalSkuCode?: string
    externalItemId?: string
    externalSkuName?: string
    config?: Record<string, unknown>
  }
}

export type AdminFulfillmentBindingConfigSaveInput = {
  bindings?: AdminFulfillmentBindingConfigWriteItemInput[]
}

export type AdminInventoryInvalidateInput = {
  reason?: string
}

export type AdminTaskManualDispatchInput = {
  outcome?: string
  resultMessage?: string
  deliveryReference?: string
  deliveredCredential?: string
}

export type AdminTaskKuaishouCloudDispatchInput = {
  ticketCode?: string
}

export type AdminManualRedeemCreateInput = {
  proofValue?: string
  skuCode?: string
  skuName?: string
  remark?: string
}
