// This file is auto-generated by @hey-api/openapi-ts

export type ClientOptions = {
  baseUrl: `${string}://${string}` | (string & {})
}

export type AccessChannels = {
  enabled?: boolean
  webappRows?: Array<WebAppAccessRow>
  cli?: CliAccess
}

export type AccessModeOption = {
  mode?: string
  label?: string
  disabled?: boolean
  selected?: boolean
}

export type AccessPolicyDetail = {
  accessMode?: string
  subjects?: Array<AccessSubjectDisplay>
  options?: Array<AccessModeOption>
}

export type AccessStatus = {
  accessChannelsEnabled?: boolean
  webappUrl?: string
  cliUrl?: string
  developerApiEnabled?: boolean
  apiKeyCount?: number
}

export type AccessSubject = {
  subjectId?: string
  subjectType?: string
}

export type AccessSubjectDisplay = {
  id?: string
  subjectType?: string
  name?: string
  avatarUrl?: string
  memberCount?: string
}

export type Account = {
  id?: string
  email?: string
  name?: string
}

export type AccountDetail = {
  account?: Account
  status?: string
  createdAt?: string
  lastActiveAt?: string
  workspaces?: Array<AccountInWorkspace>
  groups?: Array<AccountDetailGroup>
}

export type AccountDetailGroup = {
  id?: string
  name?: string
}

export type AccountInWorkspace = {
  workspaceId?: string
  workspaceName?: string
  role?: string
}

export type AckDeploymentReply = {
  accepted?: boolean
  newVersion?: string
}

export type AckDeploymentReq = {
  deploymentId?: string
  instanceId?: string
  expectedVersion?: string
  status?: string
  observedReleaseId?: string
  lastError?: LastError
}

export type AppInstanceBasicInfo = {
  id?: string
  name?: string
  description?: string
  sourceAppId?: string
  sourceAppName?: string
  mode?: string
  createdAt?: string
}

export type AppInstanceCard = {
  id?: string
  name?: string
  icon?: string
  mode?: string
  sourceAppName?: string
  statuses?: Array<StatusCount>
  lastDeployedAt?: string
}

export type AppRunnerBatchRuntimeArtifactReply = {
  results?: Array<AppRunnerRuntimeArtifactResult>
}

export type AppRunnerBatchRuntimeArtifactRequest = {
  artifacts?: Array<AppRunnerRuntimeArtifactRequest>
}

export type AppRunnerBootstrapAssignment = {
  appId?: string
  environmentId?: string
  workflowId?: string
  instanceId?: string
  workspaceId?: string
  instanceVersion?: string
  bindingSnapshotVersion?: string
  executionTokenVersion?: string
  executionToken?: string
  releaseId?: string
}

export type AppRunnerBootstrapReply = {
  runnerId?: string
  assignmentRevision?: string
  assignments?: Array<AppRunnerBootstrapAssignment>
}

export type AppRunnerBootstrapRequest = {
  runner?: AppRunnerRunnerInfo
}

export type AppRunnerRunnerInfo = {
  hostname?: string
}

export type AppRunnerRuntimeArtifactReply = {
  dslYaml?: string
  bindingSnapshotVersion?: string
  bindingSnapshot?: {
    [key: string]: unknown
  }
}

export type AppRunnerRuntimeArtifactRequest = {
  instanceId?: string
  releaseId?: string
  bindingSnapshotVersion?: string
}

export type AppRunnerRuntimeArtifactResult = {
  instanceId?: string
  releaseId?: string
  artifact?: AppRunnerRuntimeArtifactReply
  errorCode?: string
  errorMessage?: string
}

export type AppRunnerTokenExchangeReply = {
  accessToken?: string
  expiresAt?: string
}

export type AppRunnerTokenExchangeRequest = {
  joinToken?: string
}

export type AuthSettingsReply = {
  userSsoSettings?: SsoSettings
  webSsoSettings?: SsoSettings
  dashboardSsoSettings?: SsoSettings
  userSsoSamlAcsUrl?: string
  userSsoOidcCallbackUrl?: string
  userSsoOauth2CallbackUrl?: string
  webSsoSamlAcsUrl?: string
  webSsoOidcCallbackUrl?: string
  webSsoOauth2CallbackUrl?: string
  webSsoMembersSamlAcsUrl?: string
  webSsoMembersOidcCallbackUrl?: string
  webSsoMembersOauth2CallbackUrl?: string
  dashboardSsoSamlAcsUrl?: string
  dashboardSsoOidcCallbackUrl?: string
  dashboardSsoOauth2CallbackUrl?: string
}

export type AuthSettingsReq = {
  ssoType?: string
  ssoSettings?: SsoSettings
}

export type BootstrapProgress = {
  currentStep?: string
  completedSteps?: Array<string>
  attemptCount?: number
  lastAttemptAt?: string
  lastErrorCode?: string
  lastErrorMessage?: string
}

export type BrandingInfo = {
  enabled?: boolean
  applicationTitle?: string
  loginPageLogo?: string
  workspaceLogo?: string
  favicon?: string
}

export type CancelRuntimeDeploymentReply = {
  status?: string
}

export type CancelRuntimeDeploymentReq = {
  appInstanceId?: string
  runtimeInstanceId?: string
}

export type CheckPasswordStatusReply = {
  requirePasswordChange?: boolean
  changeReason?: number
  daysToExpire?: number
  message?: string
}

export type ClearDefaultWorkspaceReply = {
  [key: string]: unknown
}

export type CliAccess = {
  url?: string
}

export type ConsoleEnvironment = {
  id?: string
  name?: string
  runtime?: string
  type?: string
  status?: string
}

export type ConsoleRelease = {
  id?: string
  name?: string
  shortCommitId?: string
  createdAt?: string
}

export type ConsoleUser = {
  id?: string
  name?: string
}

export type CreateAppInstanceReply = {
  appInstanceId?: string
  initialRelease?: ConsoleRelease
}

export type CreateAppInstanceReq = {
  sourceAppId?: string
  name?: string
  description?: string
}

export type CreateBearerTokenResponse = {
  token?: string
}

export type CreateDeploymentReply = {
  runtimeInstanceId?: string
  deploymentId?: string
  status?: string
}

export type CreateDeploymentReq = {
  appInstanceId?: string
  environmentId?: string
  releaseId?: string
  bindings?: Array<DeploymentRuntimeBinding>
}

export type CreateDeveloperApiKeyReply = {
  apiKey?: DeveloperApiKeyRow
  token?: string
}

export type CreateDeveloperApiKeyReq = {
  appInstanceId?: string
  environmentId?: string
  name?: string
}

export type CreateEnvironmentReply = {
  environment?: Environment
}

export type CreateEnvironmentReq = {
  name?: string
  description?: string
  mode?: number
  backend?: number
  k8s?: K8sEnvironmentConfig
  host?: HostEnvironmentConfig
}

export type CreateMemberReply = {
  id?: string
  password?: string
}

export type CreateMemberReq = {
  name?: string
  email?: string
  status?: string
}

export type CreateNewGroupsReq = {
  groups?: Array<CreateNewGroupsReqGroup>
}

export type CreateNewGroupsReqGroup = {
  name?: string
}

export type CreateNewGroupsRes = {
  groups?: Array<SubjectGroupData>
}

export type CreateReleaseReply = {
  release?: ConsoleRelease
}

export type CreateReleaseReq = {
  appInstanceId?: string
  name?: string
  description?: string
}

export type CreateSecretKeyReply = {
  id?: string
  name?: string
  secretKey?: string
  createdAt?: string
  lastActive?: string
}

export type CreateSecretKeyReq = {
  name?: string
}

export type CreateUserReply = {
  id?: string
  password?: string
}

export type CreateUserReq = {
  name?: string
  email?: string
  status?: string
}

export type CreateWorkspaceReply = {
  workspace?: Workspace
}

export type CreateWorkspaceReq = {
  name?: string
  email?: string
  status?: string
}

export type CurrentUserReply = {
  id?: string
  name?: string
  email?: string
  interfaceLanguage?: string
  timezone?: string
}

export type DashboardSsooidcLoginReply = {
  url?: string
  state?: string
}

export type DashboardSsoOauth2LoginReply = {
  url?: string
  state?: string
}

export type DashboardSsosamlLoginReply = {
  url?: string
}

export type DeleteAppInstanceReply = {
  [key: string]: unknown
}

export type DeleteDeveloperApiKeyReply = {
  [key: string]: unknown
}

export type DeleteEnvironmentReply = {
  [key: string]: unknown
}

export type DeleteGroupsRes = {
  message?: string
}

export type DeleteGuard = {
  canDelete?: boolean
  disabledReason?: string
}

export type DeleteMemberReply = {
  account?: Account
}

export type DeleteSecretKeyReply = {
  message?: string
}

export type DeleteUserReply = {
  account?: Account
}

export type DeleteWorkspaceReply = {
  [key: string]: unknown
}

export type DeployedEnvironment = {
  environmentId?: string
  environmentName?: string
}

export type DeploymentBindingOptionSlot = {
  slot?: string
  kind?: string
  label?: string
  required?: boolean
  candidates?: Array<DeploymentCredentialOption>
  envVarCandidates?: Array<DeploymentEnvVarOption>
}

export type DeploymentCredentialOption = {
  credentialId?: string
  displayName?: string
  pluginId?: string
  pluginName?: string
  pluginVersion?: string
}

export type DeploymentEnvVarOption = {
  envVarId?: string
  name?: string
  valueType?: string
  displayValue?: string
}

export type DeploymentEnvironmentOption = {
  id?: string
  name?: string
  type?: string
  backend?: string
  status?: string
  managedBy?: string
  deployable?: boolean
  disabledReason?: string
}

export type DeploymentRuntimeBinding = {
  slot?: string
  credentialId?: string
  envVarId?: string
}

export type DeploymentStatusRow = {
  environment?: ConsoleEnvironment
  release?: ConsoleRelease
  status?: string
}

export type DeveloperApiAccess = {
  enabled?: boolean
  apiKeys?: Array<DeveloperApiKeyRow>
}

export type DeveloperApiKeyRow = {
  id?: string
  name?: string
  environment?: ConsoleEnvironment
  maskedKey?: string
}

export type EndpointReply = {
  mode?: number
  metricsEndpoint?: OtelExporterEndpoint
  tracesEndpoint?: OtelExporterEndpoint
}

export type EnterpriseSystemUserSettingReply = {
  ssoEnforcedForSignin?: boolean
  ssoEnforcedForSigninProtocol?: string
  enableEmailPasswordLogin?: boolean
}

export type Environment = {
  id?: string
  name?: string
  description?: string
  mode?: number
  namespace?: string
  apiServer?: string
  status?: number
  statusMessage?: string
  bootstrapProgress?: BootstrapProgress
  managedBy?: string
  createdAt?: string
  updatedAt?: string
  backend?: number
  host?: string
}

export type EnvironmentAccessRow = {
  environment?: ConsoleEnvironment
  currentRelease?: ConsoleRelease
  accessMode?: string
  accessModeLabel?: string
  hint?: string
}

export type EnvironmentFilter = {
  id?: string
  name?: string
  kind?: string
}

export type GetAppInstanceAccessReply = {
  permissions?: Array<EnvironmentAccessRow>
  accessChannels?: AccessChannels
  developerApi?: DeveloperApiAccess
}

export type GetAppInstanceOverviewReply = {
  instance?: AppInstanceBasicInfo
  deployments?: Array<DeploymentStatusRow>
  access?: AccessStatus
}

export type GetAppInstanceSettingsReply = {
  name?: string
  description?: string
  deleteGuard?: DeleteGuard
}

export type GetBearerTokenResponse = {
  maskedToken?: string
}

export type GetClusterInfoReply = {
  mode?: string
  clusterId?: string
  verifyMode?: string
}

export type GetDefaultWorkspaceReply = {
  workspaceId?: string
  workspace?: Workspace
}

export type GetEnvironmentAccessPolicyReply = {
  policy?: AccessPolicyDetail
}

export type GetEnvironmentReply = {
  environment?: Environment
}

export type GetGroupSubjectsRes = {
  subjects?: Array<Subject>
}

export type GetGroupsRes = {
  groups?: Array<SubjectGroupData>
}

export type GetInstanceReply = {
  instanceId?: string
  status?: string
  desiredReleaseId?: string
  observedReleaseId?: string
  currentDeploymentId?: string
  version?: string
}

export type GetJoinedGroupsRes = {
  groups?: Array<SubjectGroupData>
}

export type GetLicenseReply = {
  license?: LicenseInfo
}

export type GetLicenseStatusReply = {
  status?: string
}

export type GetMfaInfoReply = {
  userEnabled?: boolean
  userSetup?: boolean
  globalEnabled?: boolean
}

export type GetMemberReply = {
  account?: AccountDetail
}

export type GetUserReply = {
  account?: AccountDetail
}

export type GetWebAppAccessModeRes = {
  accessMode?: string
}

export type GetWebAppAuthInfoRes = {
  allowSso?: boolean
  allowEmailCodeLogin?: boolean
  allowEmailPasswordLogin?: boolean
}

export type GetWebAppWhitelistSubjectsRes = {
  groups?: Array<SubjectGroupData>
  members?: Array<GetWebAppWhitelistSubjectsResMember>
}

export type GetWebAppWhitelistSubjectsResMember = {
  id?: string
  name?: string
  email?: string
  avatar?: string
}

export type GetWorkspacePermissionReply = {
  permission?: WorkspacePermission
}

export type GetWorkspaceReply = {
  workspace?: Workspace
}

export type HealthzReply = {
  message?: string
  status?: string
}

export type HostEnvironmentConfig = {
  machineId?: string
  joinTokenHash?: string
}

export type InfoConfigReply = {
  SSOEnforcedForSignin?: boolean
  SSOEnforcedForSigninProtocol?: string
  SSOEnforcedForWeb?: boolean
  SSOEnforcedForWebProtocol?: string
  EnableEmailCodeLogin?: boolean
  EnableEmailPasswordLogin?: boolean
  IsAllowRegister?: boolean
  IsAllowCreateWorkspace?: boolean
  License?: LicenseStatus
  Branding?: BrandingInfo
  WebAppAuth?: WebAppAuthInfo
  PluginInstallationPermission?: PluginInstallationPermissionInfo
}

export type InnerBatchGetWebAppAccessModesByIdReq = {
  appIds?: Array<string>
}

export type InnerBatchGetWebAppAccessModesByIdRes = {
  accessModes?: {
    [key: string]: string
  }
}

export type InnerBatchIsUserAllowedToAccessWebAppReq = {
  userId?: string
  appIds?: Array<string>
}

export type InnerBatchIsUserAllowedToAccessWebAppRes = {
  permissions?: {
    [key: string]: boolean
  }
}

export type InnerCheckAppDeployAccessReply = {
  allowed?: boolean
  matchedPolicyId?: string
  matchedScopeType?: string
  reason?: string
  cacheTtlSeconds?: number
}

export type InnerCheckAppDeployAccessReq = {
  appInstanceId?: string
  environmentId?: string
  principalType?: string
  principalId?: string
}

export type InnerCleanAppRes = {
  message?: string
}

export type InnerGetTokenRouteReply = {
  environmentId?: string
  namespace?: string
  serviceName?: string
  servicePort?: number
  environmentStatus?: string
  appId?: string
  tenantId?: string
  instanceId?: string
  observedReleaseId?: string
  instanceStatus?: string
}

export type InnerGetTokenRouteReq = {
  token?: string
}

export type InnerGetWebAppAccessModeByCodeRes = {
  accessMode?: string
}

export type InnerGetWebAppAccessModeByIdRes = {
  accessMode?: string
}

export type InnerIsUserAllowedToAccessWebAppRes = {
  result?: boolean
}

export type InnerTryAddAccountToDefaultWorkspaceReply = {
  workspaceId?: string
  joined?: boolean
  message?: string
}

export type InnerTryAddAccountToDefaultWorkspaceReq = {
  accountId?: string
}

export type IsUserAllowedToAccessWebAppRes = {
  result?: boolean
}

export type JoinWorkspaceReply = {
  message?: string
}

export type JoinWorkspaceReq = {
  id?: string
  email?: string
  role?: string
}

export type K8sEnvironmentConfig = {
  namespace?: string
  apiServer?: string
  caBundle?: string
  bearerToken?: string
}

export type LastError = {
  phase?: string
  code?: string
  message?: string
  releaseId?: string
}

export type LicenseInfo = {
  uuid?: string
  expiredAt?: string
  clusterId?: string
  product?: string
  limits?: LimitFields
}

export type LicenseStatus = {
  status?: string
  expiredAt?: string
  workspaces?: ResourceQuota
}

export type LimitFields = {
  workspaceMembers?: number
  workspaces?: ResourceQuota
}

export type ListAppInstancesReply = {
  filters?: Array<EnvironmentFilter>
  data?: Array<AppInstanceCard>
  pagination?: Pagination
}

export type ListDeploymentBindingOptionsReply = {
  slots?: Array<DeploymentBindingOptionSlot>
}

export type ListDeploymentEnvironmentOptionsReply = {
  environments?: Array<DeploymentEnvironmentOption>
}

export type ListEnvironmentsReply = {
  data?: Array<Environment>
  pagination?: Pagination
}

export type ListMembersReply = {
  data?: Array<AccountDetail>
  pagination?: Pagination
}

export type ListReleasesReply = {
  data?: Array<ReleaseRow>
  pagination?: Pagination
}

export type ListRuntimeInstancesReply = {
  data?: Array<RuntimeInstanceRow>
}

export type ListSecretKeysReply = {
  data?: Array<SecretKey>
  pagination?: Pagination
}

export type ListUsersReply = {
  data?: Array<AccountDetail>
  pagination?: Pagination
}

export type ListWorkspacesReply = {
  data?: Array<Workspace>
  pagination?: Pagination
}

export type LoginTypesReply = {
  enabledEmailCodeLogin?: boolean
  enableEmailPasswordLogin?: boolean
  isAllowRegister?: boolean
  isAllowCreateWorkspace?: boolean
}

export type LoginTypesReq = {
  enabledEmailCodeLogin?: boolean
  enableEmailPasswordLogin?: boolean
  isAllowRegister?: boolean
  isAllowCreateWorkspace?: boolean
}

export type MfaBackupCodesRes = {
  codes?: Array<string>
  validCounts?: number
  createdAt?: string
}

export type MfaDeleteBackupCodesRes = {
  message?: string
}

export type MfaDeleteRes = {
  token?: string
}

export type MfaDownloadBackupCodesSummaryRes = {
  content?: string
}

export type MfaEnrollReq = {
  code?: string
}

export type MfaEnrollRes = {
  token?: string
}

export type MfaGetEnrollInfoRes = {
  qrCode?: string
  secret?: string
}

export type MfaModifyRes = {
  message?: string
}

export type OAuth2Config = {
  clientId?: string
  clientSecret?: string
  authUrl?: string
  tokenUrl?: string
  userinfoUrl?: string
  scopes?: string
  enablePkce?: boolean
}

export type OAuth2LoginReply = {
  url?: string
  state?: string
}

export type OidcConfig = {
  issuerUrl?: string
  clientId?: string
  clientSecret?: string
  enablePkce?: boolean
}

export type OidcReply = {
  url?: string
  state?: string
}

export type OtelExporterEndpoint = {
  endpoint?: string
  compression?: string
  protocol?: number
  timeout?: string
  headers?: {
    [key: string]: string
  }
  tlsCaPem?: string
  tlsInsecure?: boolean
  tlsClientCertPem?: string
  tlsClientKeyPem?: string
  enabled?: boolean
  tlsInsecureSkipVerify?: boolean
}

export type OtelExporterStatusReply = {
  connectedAt?: string
  bytesPushed?: string
  itemsInQueue?: string
  logs?: string
  status?: number
}

export type PasswordPolicyConfig = {
  minLength?: number
  requireDigit?: boolean
  requireLowercase?: boolean
  requireUppercase?: boolean
  requireSpecial?: boolean
  forbidRepeated?: boolean
  forbidSequential?: boolean
  expiryEnabled?: boolean
  expiryDays?: number
}

export type PasswordStrengthReply = {
  level?: number
}

export type PasswordStrengthReq = {
  password?: string
}

export type PluginInstallationPermissionInfo = {
  pluginInstallationScope?: string
  restrictToMarketplaceOnly?: boolean
}

export type PluginInstallationSettingsReply = {
  pluginInstallationScope?: number
  restrictToMarketplaceOnly?: boolean
}

export type PreviewReleaseReply = {
  release?: ConsoleRelease
  bindings?: Array<ReleaseRuntimeBinding>
}

export type PreviewReleaseReq = {
  appInstanceId?: string
  releaseId?: string
}

export type ReleaseRow = {
  id?: string
  name?: string
  createdAt?: string
  createdBy?: ConsoleUser
  deployedTo?: Array<DeployedEnvironment>
}

export type ReleaseRuntimeBinding = {
  kind?: string
  label?: string
  displayValue?: string
  valueType?: string
}

export type ResetMemberPasswordReply = {
  id?: string
  password?: string
}

export type ResetMemberPasswordReq = {
  id?: string
}

export type ResetPasswordReply = {
  message?: string
}

export type ResetPasswordReq = {
  currentPassword?: string
  newPassword?: string
  confirmPassword?: string
}

export type ResetUserPasswordReply = {
  id?: string
  password?: string
}

export type ResetUserPasswordReq = {
  id?: string
}

export type ResolveCredentialsReply = {
  resolved?: Array<ResolvedCredential>
}

export type ResolveCredentialsReq = {
  instanceId?: string
  deploymentId?: string
  slots?: Array<string>
}

export type ResolvedCredential = {
  slot?: string
  credentialId?: string
  envVarId?: string
  value?: string
}

export type ResourceQuota = {
  used?: number
  limit?: number
  enabled?: boolean
}

export type RetryEnvironmentReply = {
  environment?: Environment
}

export type RetryEnvironmentReq = {
  id?: string
}

export type RuntimeEndpoints = {
  run?: string
  health?: string
}

export type RuntimeInstanceDetail = {
  deploymentName?: string
  replicas?: number
  runtimeMode?: string
  runtimeNote?: string
  endpoints?: RuntimeEndpoints
  bindings?: Array<ReleaseRuntimeBinding>
}

export type RuntimeInstanceRow = {
  id?: string
  environment?: ConsoleEnvironment
  status?: string
  currentRelease?: ConsoleRelease
  detail?: RuntimeInstanceDetail
}

export type SamlConfig = {
  idpSsoUrl?: string
  certificate?: string
}

export type SamlLoginReply = {
  url?: string
}

export type SsoIdPProvider = {
  protocol?: string
  provider?: string
  samlConfig?: SamlConfig
  oidcConfig?: OidcConfig
  oauth2Config?: OAuth2Config
}

export type SsoSettings = {
  ssoEnforced?: boolean
  sessionTimeout?: number
  ssoIdpProvider?: SsoIdPProvider
}

export type SsoSettingsReply = {
  enabled?: boolean
}

export type ScimSettings = {
  enabled?: boolean
  lastSyncTime?: string
}

export type SearchAccessSubjectsReply = {
  data?: Array<AccessSubjectDisplay>
}

export type SearchForWhilteListCandidatesRes = {
  subjects?: Array<Subject>
  currPage?: number
  hasMore?: boolean
}

export type SecretKey = {
  id?: string
  name?: string
  secretKeyMasked?: string
  createdAt?: string
  lastActive?: string
}

export type SetDefaultWorkspaceReply = {
  workspaceId?: string
}

export type SetDefaultWorkspaceReq = {
  id?: string
}

export type StatusCount = {
  status?: string
  count?: number
}

export type Subject = {
  subjectId?: string
  subjectType?: string
  accountData?: SubjectAccountData
  groupData?: SubjectGroupData
}

export type SubjectAccountData = {
  id?: string
  name?: string
  email?: string
  avatar?: string
}

export type SubjectGroupData = {
  id?: string
  name?: string
  groupSize?: number
}

export type SystemUserSettingReply = {
  isAllowRegister?: boolean
  enableEmailPasswordLogin?: boolean
}

export type SystemUserSettingReq = {
  isAllowRegister?: boolean
  enableEmailPasswordLogin?: boolean
}

export type TestConnectionReply = {
  success?: boolean
  error?: string
}

export type TestEnvironmentConnectionReply = {
  ok?: boolean
  reachableServerVersion?: string
  namespaceExists?: boolean
  missingPermissions?: Array<string>
  error?: string
  probedAt?: string
}

export type TestEnvironmentConnectionReq = {
  id?: string
}

export type ToggleEndpointRequest = {
  enabled?: boolean
}

export type UndeployRuntimeInstanceReply = {
  deploymentId?: string
  status?: string
}

export type UndeployRuntimeInstanceReq = {
  appInstanceId?: string
  runtimeInstanceId?: string
}

export type UpdateAccessChannelsReply = {
  accessChannels?: AccessChannels
}

export type UpdateAccessChannelsReq = {
  appInstanceId?: string
  enabled?: boolean
}

export type UpdateAccessModeReq = {
  appId?: string
  accessMode?: string
}

export type UpdateAccessModeRes = {
  message?: string
}

export type UpdateAppInstanceReply = {
  appInstanceId?: string
}

export type UpdateAppInstanceReq = {
  appInstanceId?: string
  name?: string
  description?: string
}

export type UpdateBrandingInfoReq = {
  enabled?: boolean
  applicationTitle?: string
  loginPageLogo?: string
  workspaceLogo?: string
  favicon?: string
}

export type UpdateDeveloperApiReply = {
  developerApi?: DeveloperApiAccess
}

export type UpdateDeveloperApiReq = {
  appInstanceId?: string
  enabled?: boolean
}

export type UpdateEnvironmentAccessPolicyReply = {
  permission?: EnvironmentAccessRow
}

export type UpdateEnvironmentAccessPolicyReq = {
  appInstanceId?: string
  environmentId?: string
  accessMode?: string
  subjects?: Array<AccessSubject>
}

export type UpdateEnvironmentReply = {
  environment?: Environment
}

export type UpdateEnvironmentReq = {
  id?: string
  name?: string
  description?: string
}

export type UpdateGroupSubjectsReq = {
  groupId?: string
  subjects?: Array<Subject>
}

export type UpdateGroupSubjectsRes = {
  message?: string
}

export type UpdateGroupsReq = {
  groups?: Array<UpdateGroupsReqGroup>
}

export type UpdateGroupsReqGroup = {
  id?: string
  name?: string
}

export type UpdateGroupsRes = {
  groups?: Array<SubjectGroupData>
}

export type UpdateJoinedGroupsReq = {
  accountId?: string
  groupIds?: Array<string>
}

export type UpdateJoinedGroupsRes = {
  message?: string
}

export type UpdateLicenseReply = {
  message?: string
}

export type UpdateLicenseReq = {
  licenseId?: string
}

export type UpdateMfaStatusReq = {
  enabled?: boolean
}

export type UpdateMfaStatusRes = {
  message?: string
}

export type UpdateMemberReply = {
  account?: Account
}

export type UpdateMemberReq = {
  id?: string
  name?: string
  email?: string
  status?: string
}

export type UpdateMembersInGroupsReq = {
  groupId?: string
  accountIds?: Array<string>
}

export type UpdateMembersInGroupsRes = {
  message?: string
}

export type UpdateOfflineLicenseReply = {
  message?: string
}

export type UpdateOfflineLicenseReq = {
  offlineCode?: string
}

export type UpdatePluginInstallationSettingsRequest = {
  pluginInstallationScope?: number
  restrictToMarketplaceOnly?: boolean
}

export type UpdateUserReply = {
  account?: AccountDetail
}

export type UpdateUserReq = {
  id?: string
  name?: string
  email?: string
  status?: string
}

export type UpdateWebAppAuthInfoReq = {
  allowSso?: boolean
  allowEmailCodeLogin?: boolean
  allowEmailPasswordLogin?: boolean
}

export type UpdateWebAppAuthInfoRes = {
  message?: string
}

export type UpdateWebAppWhitelistSubjectsReq = {
  appId?: string
  subjects?: Array<Subject>
  accessMode?: string
}

export type UpdateWebAppWhitelistSubjectsRes = {
  message?: string
}

export type UpdateWorkspacePermissionReply = {
  message?: string
  permission?: WorkspacePermission
}

export type UpdateWorkspacePermissionReq = {
  id?: string
  permission?: WorkspacePermission
}

export type UpdateWorkspaceReply = {
  workspace?: Workspace
}

export type UpdateWorkspaceReq = {
  id?: string
  name?: string
  email?: string
  status?: string
}

export type WebAppAccessRow = {
  environment?: ConsoleEnvironment
  url?: string
}

export type WebAppAuthInfo = {
  allowSso?: boolean
  allowEmailCodeLogin?: boolean
  allowEmailPasswordLogin?: boolean
}

export type WebOAuth2LoginReply = {
  url?: string
  state?: string
}

export type WebOidcLoginReply = {
  url?: string
}

export type WebSamlLoginReply = {
  url?: string
}

export type Workspace = {
  id?: string
  name?: string
  status?: string
  createdAt?: string
  owner?: Account
}

export type WorkspaceInfoReply = {
  WorkspaceMembers?: ResourceQuota
}

export type WorkspacePermission = {
  workspaceId?: string
  allowMemberInvite?: boolean
  allowOwnerTransfer?: boolean
}

export type Pagination = {
  totalCount?: number
  perPage?: number
  currentPage?: number
  totalPages?: number
}

export type EnterpriseAppDeployConsoleListAppInstancesData = {
  body?: never
  path?: never
  query?: {
    environmentId?: string
    notDeployed?: boolean
    query?: string
    pageNumber?: number
    resultsPerPage?: number
  }
  url: '/enterprise/app-instances'
}

export type EnterpriseAppDeployConsoleListAppInstancesResponses = {
  200: ListAppInstancesReply
}

export type EnterpriseAppDeployConsoleListAppInstancesResponse
  = EnterpriseAppDeployConsoleListAppInstancesResponses[keyof EnterpriseAppDeployConsoleListAppInstancesResponses]

export type EnterpriseAppDeployConsoleCreateAppInstanceData = {
  body: CreateAppInstanceReq
  path?: never
  query?: never
  url: '/enterprise/app-instances'
}

export type EnterpriseAppDeployConsoleCreateAppInstanceResponses = {
  200: CreateAppInstanceReply
}

export type EnterpriseAppDeployConsoleCreateAppInstanceResponse
  = EnterpriseAppDeployConsoleCreateAppInstanceResponses[keyof EnterpriseAppDeployConsoleCreateAppInstanceResponses]

export type EnterpriseAppDeployConsoleDeleteAppInstanceData = {
  body?: never
  path: {
    appInstanceId: string
  }
  query?: never
  url: '/enterprise/app-instances/{appInstanceId}'
}

export type EnterpriseAppDeployConsoleDeleteAppInstanceResponses = {
  200: DeleteAppInstanceReply
}

export type EnterpriseAppDeployConsoleDeleteAppInstanceResponse
  = EnterpriseAppDeployConsoleDeleteAppInstanceResponses[keyof EnterpriseAppDeployConsoleDeleteAppInstanceResponses]

export type EnterpriseAppDeployConsoleUpdateAppInstanceData = {
  body: UpdateAppInstanceReq
  path: {
    appInstanceId: string
  }
  query?: never
  url: '/enterprise/app-instances/{appInstanceId}'
}

export type EnterpriseAppDeployConsoleUpdateAppInstanceResponses = {
  200: UpdateAppInstanceReply
}

export type EnterpriseAppDeployConsoleUpdateAppInstanceResponse
  = EnterpriseAppDeployConsoleUpdateAppInstanceResponses[keyof EnterpriseAppDeployConsoleUpdateAppInstanceResponses]

export type EnterpriseAppDeployConsoleGetAppInstanceAccessData = {
  body?: never
  path: {
    appInstanceId: string
  }
  query?: never
  url: '/enterprise/app-instances/{appInstanceId}/access'
}

export type EnterpriseAppDeployConsoleGetAppInstanceAccessResponses = {
  200: GetAppInstanceAccessReply
}

export type EnterpriseAppDeployConsoleGetAppInstanceAccessResponse
  = EnterpriseAppDeployConsoleGetAppInstanceAccessResponses[keyof EnterpriseAppDeployConsoleGetAppInstanceAccessResponses]

export type EnterpriseAppDeployConsoleUpdateAccessChannelsData = {
  body: UpdateAccessChannelsReq
  path: {
    appInstanceId: string
  }
  query?: never
  url: '/enterprise/app-instances/{appInstanceId}/access-channels'
}

export type EnterpriseAppDeployConsoleUpdateAccessChannelsResponses = {
  200: UpdateAccessChannelsReply
}

export type EnterpriseAppDeployConsoleUpdateAccessChannelsResponse
  = EnterpriseAppDeployConsoleUpdateAccessChannelsResponses[keyof EnterpriseAppDeployConsoleUpdateAccessChannelsResponses]

export type EnterpriseAppDeployConsoleSearchAccessSubjectsData = {
  body?: never
  path: {
    appInstanceId: string
  }
  query?: {
    keyword?: string
    subjectTypes?: Array<string>
  }
  url: '/enterprise/app-instances/{appInstanceId}/access-subjects:search'
}

export type EnterpriseAppDeployConsoleSearchAccessSubjectsResponses = {
  200: SearchAccessSubjectsReply
}

export type EnterpriseAppDeployConsoleSearchAccessSubjectsResponse
  = EnterpriseAppDeployConsoleSearchAccessSubjectsResponses[keyof EnterpriseAppDeployConsoleSearchAccessSubjectsResponses]

export type EnterpriseAppDeployConsoleCreateDeveloperApiKeyData = {
  body: CreateDeveloperApiKeyReq
  path: {
    appInstanceId: string
  }
  query?: never
  url: '/enterprise/app-instances/{appInstanceId}/api-keys'
}

export type EnterpriseAppDeployConsoleCreateDeveloperApiKeyResponses = {
  200: CreateDeveloperApiKeyReply
}

export type EnterpriseAppDeployConsoleCreateDeveloperApiKeyResponse
  = EnterpriseAppDeployConsoleCreateDeveloperApiKeyResponses[keyof EnterpriseAppDeployConsoleCreateDeveloperApiKeyResponses]

export type EnterpriseAppDeployConsoleDeleteDeveloperApiKeyData = {
  body?: never
  path: {
    appInstanceId: string
    apiKeyId: string
  }
  query?: never
  url: '/enterprise/app-instances/{appInstanceId}/api-keys/{apiKeyId}'
}

export type EnterpriseAppDeployConsoleDeleteDeveloperApiKeyResponses = {
  200: DeleteDeveloperApiKeyReply
}

export type EnterpriseAppDeployConsoleDeleteDeveloperApiKeyResponse
  = EnterpriseAppDeployConsoleDeleteDeveloperApiKeyResponses[keyof EnterpriseAppDeployConsoleDeleteDeveloperApiKeyResponses]

export type EnterpriseAppDeployConsoleListDeploymentBindingOptionsData = {
  body?: never
  path: {
    appInstanceId: string
  }
  query?: never
  url: '/enterprise/app-instances/{appInstanceId}/deployment-binding-options'
}

export type EnterpriseAppDeployConsoleListDeploymentBindingOptionsResponses = {
  200: ListDeploymentBindingOptionsReply
}

export type EnterpriseAppDeployConsoleListDeploymentBindingOptionsResponse
  = EnterpriseAppDeployConsoleListDeploymentBindingOptionsResponses[keyof EnterpriseAppDeployConsoleListDeploymentBindingOptionsResponses]

export type EnterpriseAppDeployConsoleCreateDeploymentData = {
  body: CreateDeploymentReq
  path: {
    appInstanceId: string
  }
  query?: never
  url: '/enterprise/app-instances/{appInstanceId}/deployments'
}

export type EnterpriseAppDeployConsoleCreateDeploymentResponses = {
  200: CreateDeploymentReply
}

export type EnterpriseAppDeployConsoleCreateDeploymentResponse
  = EnterpriseAppDeployConsoleCreateDeploymentResponses[keyof EnterpriseAppDeployConsoleCreateDeploymentResponses]

export type EnterpriseAppDeployConsoleUpdateDeveloperApiData = {
  body: UpdateDeveloperApiReq
  path: {
    appInstanceId: string
  }
  query?: never
  url: '/enterprise/app-instances/{appInstanceId}/developer-api'
}

export type EnterpriseAppDeployConsoleUpdateDeveloperApiResponses = {
  200: UpdateDeveloperApiReply
}

export type EnterpriseAppDeployConsoleUpdateDeveloperApiResponse
  = EnterpriseAppDeployConsoleUpdateDeveloperApiResponses[keyof EnterpriseAppDeployConsoleUpdateDeveloperApiResponses]

export type EnterpriseAppDeployConsoleGetEnvironmentAccessPolicyData = {
  body?: never
  path: {
    appInstanceId: string
    environmentId: string
  }
  query?: never
  url: '/enterprise/app-instances/{appInstanceId}/environments/{environmentId}/access-policy'
}

export type EnterpriseAppDeployConsoleGetEnvironmentAccessPolicyResponses = {
  200: GetEnvironmentAccessPolicyReply
}

export type EnterpriseAppDeployConsoleGetEnvironmentAccessPolicyResponse
  = EnterpriseAppDeployConsoleGetEnvironmentAccessPolicyResponses[keyof EnterpriseAppDeployConsoleGetEnvironmentAccessPolicyResponses]

export type EnterpriseAppDeployConsoleUpdateEnvironmentAccessPolicyData = {
  body: UpdateEnvironmentAccessPolicyReq
  path: {
    appInstanceId: string
    environmentId: string
  }
  query?: never
  url: '/enterprise/app-instances/{appInstanceId}/environments/{environmentId}/access-policy'
}

export type EnterpriseAppDeployConsoleUpdateEnvironmentAccessPolicyResponses = {
  200: UpdateEnvironmentAccessPolicyReply
}

export type EnterpriseAppDeployConsoleUpdateEnvironmentAccessPolicyResponse
  = EnterpriseAppDeployConsoleUpdateEnvironmentAccessPolicyResponses[keyof EnterpriseAppDeployConsoleUpdateEnvironmentAccessPolicyResponses]

export type EnterpriseAppDeployConsoleGetAppInstanceOverviewData = {
  body?: never
  path: {
    appInstanceId: string
  }
  query?: never
  url: '/enterprise/app-instances/{appInstanceId}/overview'
}

export type EnterpriseAppDeployConsoleGetAppInstanceOverviewResponses = {
  200: GetAppInstanceOverviewReply
}

export type EnterpriseAppDeployConsoleGetAppInstanceOverviewResponse
  = EnterpriseAppDeployConsoleGetAppInstanceOverviewResponses[keyof EnterpriseAppDeployConsoleGetAppInstanceOverviewResponses]

export type EnterpriseAppDeployConsoleListReleasesData = {
  body?: never
  path: {
    appInstanceId: string
  }
  query?: {
    pageNumber?: number
    resultsPerPage?: number
  }
  url: '/enterprise/app-instances/{appInstanceId}/releases'
}

export type EnterpriseAppDeployConsoleListReleasesResponses = {
  200: ListReleasesReply
}

export type EnterpriseAppDeployConsoleListReleasesResponse
  = EnterpriseAppDeployConsoleListReleasesResponses[keyof EnterpriseAppDeployConsoleListReleasesResponses]

export type EnterpriseAppDeployConsoleCreateReleaseData = {
  body: CreateReleaseReq
  path: {
    appInstanceId: string
  }
  query?: never
  url: '/enterprise/app-instances/{appInstanceId}/releases'
}

export type EnterpriseAppDeployConsoleCreateReleaseResponses = {
  200: CreateReleaseReply
}

export type EnterpriseAppDeployConsoleCreateReleaseResponse
  = EnterpriseAppDeployConsoleCreateReleaseResponses[keyof EnterpriseAppDeployConsoleCreateReleaseResponses]

export type EnterpriseAppDeployConsolePreviewReleaseData = {
  body: PreviewReleaseReq
  path: {
    appInstanceId: string
  }
  query?: never
  url: '/enterprise/app-instances/{appInstanceId}/releases:preview'
}

export type EnterpriseAppDeployConsolePreviewReleaseResponses = {
  200: PreviewReleaseReply
}

export type EnterpriseAppDeployConsolePreviewReleaseResponse
  = EnterpriseAppDeployConsolePreviewReleaseResponses[keyof EnterpriseAppDeployConsolePreviewReleaseResponses]

export type EnterpriseAppDeployConsoleListRuntimeInstancesData = {
  body?: never
  path: {
    appInstanceId: string
  }
  query?: never
  url: '/enterprise/app-instances/{appInstanceId}/runtime-instances'
}

export type EnterpriseAppDeployConsoleListRuntimeInstancesResponses = {
  200: ListRuntimeInstancesReply
}

export type EnterpriseAppDeployConsoleListRuntimeInstancesResponse
  = EnterpriseAppDeployConsoleListRuntimeInstancesResponses[keyof EnterpriseAppDeployConsoleListRuntimeInstancesResponses]

export type EnterpriseAppDeployConsoleCancelRuntimeDeploymentData = {
  body: CancelRuntimeDeploymentReq
  path: {
    appInstanceId: string
    runtimeInstanceId: string
  }
  query?: never
  url: '/enterprise/app-instances/{appInstanceId}/runtime-instances/{runtimeInstanceId}/deployment:cancel'
}

export type EnterpriseAppDeployConsoleCancelRuntimeDeploymentResponses = {
  200: CancelRuntimeDeploymentReply
}

export type EnterpriseAppDeployConsoleCancelRuntimeDeploymentResponse
  = EnterpriseAppDeployConsoleCancelRuntimeDeploymentResponses[keyof EnterpriseAppDeployConsoleCancelRuntimeDeploymentResponses]

export type EnterpriseAppDeployConsoleUndeployRuntimeInstanceData = {
  body: UndeployRuntimeInstanceReq
  path: {
    appInstanceId: string
    runtimeInstanceId: string
  }
  query?: never
  url: '/enterprise/app-instances/{appInstanceId}/runtime-instances/{runtimeInstanceId}:undeploy'
}

export type EnterpriseAppDeployConsoleUndeployRuntimeInstanceResponses = {
  200: UndeployRuntimeInstanceReply
}

export type EnterpriseAppDeployConsoleUndeployRuntimeInstanceResponse
  = EnterpriseAppDeployConsoleUndeployRuntimeInstanceResponses[keyof EnterpriseAppDeployConsoleUndeployRuntimeInstanceResponses]

export type EnterpriseAppDeployConsoleGetAppInstanceSettingsData = {
  body?: never
  path: {
    appInstanceId: string
  }
  query?: never
  url: '/enterprise/app-instances/{appInstanceId}/settings'
}

export type EnterpriseAppDeployConsoleGetAppInstanceSettingsResponses = {
  200: GetAppInstanceSettingsReply
}

export type EnterpriseAppDeployConsoleGetAppInstanceSettingsResponse
  = EnterpriseAppDeployConsoleGetAppInstanceSettingsResponses[keyof EnterpriseAppDeployConsoleGetAppInstanceSettingsResponses]

export type EnterpriseAppDeployConsoleListDeploymentEnvironmentOptionsData = {
  body?: never
  path?: never
  query?: never
  url: '/enterprise/deployment-environment-options'
}

export type EnterpriseAppDeployConsoleListDeploymentEnvironmentOptionsResponses = {
  200: ListDeploymentEnvironmentOptionsReply
}

export type EnterpriseAppDeployConsoleListDeploymentEnvironmentOptionsResponse
  = EnterpriseAppDeployConsoleListDeploymentEnvironmentOptionsResponses[keyof EnterpriseAppDeployConsoleListDeploymentEnvironmentOptionsResponses]

export type ConsoleSsoOAuth2LoginData = {
  body?: never
  path?: never
  query?: never
  url: '/enterprise/sso/oauth2/login'
}

export type ConsoleSsoOAuth2LoginResponses = {
  200: OAuth2LoginReply
}

export type ConsoleSsoOAuth2LoginResponse
  = ConsoleSsoOAuth2LoginResponses[keyof ConsoleSsoOAuth2LoginResponses]

export type ConsoleSsoOidcLoginData = {
  body?: never
  path?: never
  query?: never
  url: '/enterprise/sso/oidc/login'
}

export type ConsoleSsoOidcLoginResponses = {
  200: OidcReply
}

export type ConsoleSsoOidcLoginResponse
  = ConsoleSsoOidcLoginResponses[keyof ConsoleSsoOidcLoginResponses]

export type ConsoleSsoSamlLoginData = {
  body?: never
  path?: never
  query?: never
  url: '/enterprise/sso/saml/login'
}

export type ConsoleSsoSamlLoginResponses = {
  200: SamlLoginReply
}

export type ConsoleSsoSamlLoginResponse
  = ConsoleSsoSamlLoginResponses[keyof ConsoleSsoSamlLoginResponses]

export type WebAppAuthGetWebAppAccessModeData = {
  body?: never
  path?: never
  query?: {
    appId?: string
  }
  url: '/enterprise/webapp/app/access-mode'
}

export type WebAppAuthGetWebAppAccessModeResponses = {
  200: GetWebAppAccessModeRes
}

export type WebAppAuthGetWebAppAccessModeResponse
  = WebAppAuthGetWebAppAccessModeResponses[keyof WebAppAuthGetWebAppAccessModeResponses]

export type WebAppAuthUpdateWebAppWhitelistSubjectsData = {
  body: UpdateWebAppWhitelistSubjectsReq
  path?: never
  query?: never
  url: '/enterprise/webapp/app/access-mode'
}

export type WebAppAuthUpdateWebAppWhitelistSubjectsResponses = {
  200: UpdateWebAppWhitelistSubjectsRes
}

export type WebAppAuthUpdateWebAppWhitelistSubjectsResponse
  = WebAppAuthUpdateWebAppWhitelistSubjectsResponses[keyof WebAppAuthUpdateWebAppWhitelistSubjectsResponses]

export type WebAppAuthSearchForWhilteListCandidatesData = {
  body?: never
  path?: never
  query?: {
    keyword?: string
    pageNumber?: number
    resultsPerPage?: number
    groupId?: string
  }
  url: '/enterprise/webapp/app/subject/search'
}

export type WebAppAuthSearchForWhilteListCandidatesResponses = {
  200: SearchForWhilteListCandidatesRes
}

export type WebAppAuthSearchForWhilteListCandidatesResponse
  = WebAppAuthSearchForWhilteListCandidatesResponses[keyof WebAppAuthSearchForWhilteListCandidatesResponses]

export type WebAppAuthGetWebAppWhitelistSubjectsData = {
  body?: never
  path?: never
  query?: {
    appId?: string
  }
  url: '/enterprise/webapp/app/subjects'
}

export type WebAppAuthGetWebAppWhitelistSubjectsResponses = {
  200: GetWebAppWhitelistSubjectsRes
}

export type WebAppAuthGetWebAppWhitelistSubjectsResponse
  = WebAppAuthGetWebAppWhitelistSubjectsResponses[keyof WebAppAuthGetWebAppWhitelistSubjectsResponses]

export type WebAppAuthGetGroupSubjectsData = {
  body?: never
  path?: never
  query?: {
    groupId?: string
  }
  url: '/enterprise/webapp/group/subjects'
}

export type WebAppAuthGetGroupSubjectsResponses = {
  200: GetGroupSubjectsRes
}

export type WebAppAuthGetGroupSubjectsResponse
  = WebAppAuthGetGroupSubjectsResponses[keyof WebAppAuthGetGroupSubjectsResponses]

export type WebAppAuthIsUserAllowedToAccessWebAppData = {
  body?: never
  path?: never
  query?: {
    appId?: string
  }
  url: '/enterprise/webapp/permission'
}

export type WebAppAuthIsUserAllowedToAccessWebAppResponses = {
  200: IsUserAllowedToAccessWebAppRes
}

export type WebAppAuthIsUserAllowedToAccessWebAppResponse
  = WebAppAuthIsUserAllowedToAccessWebAppResponses[keyof WebAppAuthIsUserAllowedToAccessWebAppResponses]
