@zitadel/api 0.1.0-alpha.9 → 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +66 -3
- package/dist/fetch-CtYe0OvX.d.mts +113 -0
- package/dist/fetch-CtYe0OvX.d.mts.map +1 -0
- package/dist/generated/endpoints/zitadelNextGen.d.mts +2 -2
- package/dist/generated/endpoints/zitadelNextGen.mjs +2466 -459
- package/dist/generated/endpoints/zitadelNextGen.mjs.map +1 -1
- package/dist/generated/endpoints/zitadelNextGen.msw.d.mts +183 -82
- package/dist/generated/endpoints/zitadelNextGen.msw.d.mts.map +1 -1
- package/dist/generated/endpoints/zitadelNextGen.msw.mjs +14447 -732
- package/dist/generated/endpoints/zitadelNextGen.msw.mjs.map +1 -1
- package/dist/generated/endpoints/zitadelNextGen.zod.d.mts +11600 -1195
- package/dist/generated/endpoints/zitadelNextGen.zod.d.mts.map +1 -1
- package/dist/generated/endpoints/zitadelNextGen.zod.mjs +10766 -1031
- package/dist/generated/endpoints/zitadelNextGen.zod.mjs.map +1 -1
- package/dist/generated/model/index.d.mts +2 -2
- package/dist/generated/model/index.mjs +1573 -91
- package/dist/generated/model/index.mjs.map +1 -1
- package/dist/generated/operations.d.mts +42 -0
- package/dist/generated/operations.d.mts.map +1 -0
- package/dist/generated/operations.mjs +2078 -0
- package/dist/generated/operations.mjs.map +1 -0
- package/dist/index-D7-l5LV6.d.mts +53940 -0
- package/dist/index-D7-l5LV6.d.mts.map +1 -0
- package/dist/runtime/api-factory.d.mts +20 -10
- package/dist/runtime/api-factory.d.mts.map +1 -1
- package/dist/runtime/api-factory.mjs +8 -2
- package/dist/runtime/api-factory.mjs.map +1 -1
- package/dist/runtime/auth.d.mts +27 -3
- package/dist/runtime/auth.d.mts.map +1 -1
- package/dist/runtime/auth.mjs +75 -1
- package/dist/runtime/auth.mjs.map +1 -1
- package/dist/runtime/base-url.d.mts +2 -3
- package/dist/runtime/base-url.d.mts.map +1 -1
- package/dist/runtime/base-url.mjs.map +1 -1
- package/dist/runtime/config.d.mts +19 -8
- package/dist/runtime/config.d.mts.map +1 -1
- package/dist/runtime/config.mjs +8 -4
- package/dist/runtime/config.mjs.map +1 -1
- package/dist/runtime/fetch.d.mts +2 -36
- package/dist/runtime/fetch.mjs +187 -13
- package/dist/runtime/fetch.mjs.map +1 -1
- package/dist/zitadelNextGen-Cw3DrCn1.d.mts +1332 -0
- package/dist/zitadelNextGen-Cw3DrCn1.d.mts.map +1 -0
- package/package.json +43 -9
- package/src/generated/endpoints/zitadelNextGen.faker.ts +358 -0
- package/src/generated/endpoints/zitadelNextGen.msw.ts +1349 -2838
- package/src/generated/endpoints/zitadelNextGen.ts +3982 -878
- package/src/generated/endpoints/zitadelNextGen.zod.ts +10361 -3768
- package/src/generated/model/addOrigin201.ts +13 -0
- package/src/generated/model/addOrigin201Kind.ts +15 -0
- package/src/generated/model/addOriginBody.ts +23 -0
- package/src/generated/model/addOriginBodyKind.ts +15 -0
- package/src/generated/model/addOriginDefault.ts +135 -0
- package/src/generated/model/beginUserPasskeyRegistration201.ts +25 -0
- package/src/generated/model/beginUserPasskeyRegistration201Options.ts +13 -0
- package/src/generated/model/beginUserPasskeyRegistration400.ts +20 -0
- package/src/generated/model/beginUserPasskeyRegistration400Details.ts +12 -0
- package/src/generated/model/beginUserPasskeyRegistration401.ts +20 -0
- package/src/generated/model/beginUserPasskeyRegistration401Details.ts +12 -0
- package/src/generated/model/beginUserPasskeyRegistration403.ts +20 -0
- package/src/generated/model/beginUserPasskeyRegistration403Details.ts +12 -0
- package/src/generated/model/beginUserPasskeyRegistration404.ts +20 -0
- package/src/generated/model/beginUserPasskeyRegistration404Details.ts +12 -0
- package/src/generated/model/beginUserPasskeyRegistration500.ts +20 -0
- package/src/generated/model/beginUserPasskeyRegistration500Details.ts +12 -0
- package/src/generated/model/beginUserPasskeyRegistrationBody.ts +33 -0
- package/src/generated/model/beginUserPasskeyRegistrationDefault.ts +126 -0
- package/src/generated/model/buildRelease200.ts +96 -0
- package/src/generated/model/buildRelease200Metadata.ts +43 -0
- package/src/generated/model/buildRelease200MetadataCreatedByType.ts +20 -0
- package/src/generated/model/buildRelease200PointersItem.ts +60 -0
- package/src/generated/model/buildRelease200PointersItemKind.ts +28 -0
- package/src/generated/model/buildRelease201.ts +96 -0
- package/src/generated/model/buildRelease201Metadata.ts +43 -0
- package/src/generated/model/buildRelease201MetadataCreatedByType.ts +20 -0
- package/src/generated/model/buildRelease201PointersItem.ts +60 -0
- package/src/generated/model/buildRelease201PointersItemKind.ts +28 -0
- package/src/generated/model/buildRelease400.ts +31 -0
- package/src/generated/model/buildRelease400Details.ts +13 -0
- package/src/generated/model/buildRelease400DetailsResourcesItem.ts +41 -0
- package/src/generated/model/buildRelease400DetailsResourcesItemKind.ts +28 -0
- package/src/generated/model/buildReleaseBody.ts +62 -0
- package/src/generated/model/buildReleaseBodyBundle.ts +99 -0
- package/src/generated/model/buildReleaseBodyBundleBranding.ts +78 -0
- package/src/generated/model/buildReleaseBodyBundleBrandingLayout.ts +26 -0
- package/src/generated/model/buildReleaseBodyBundleBrandingShape.ts +30 -0
- package/src/generated/model/buildReleaseBodyBundleBrandingShapeDensity.ts +19 -0
- package/src/generated/model/buildReleaseBodyBundleBrandingTheme.ts +43 -0
- package/src/generated/model/buildReleaseBodyBundleBrandingThemeDark.ts +34 -0
- package/src/generated/model/buildReleaseBodyBundleBrandingThemeDarkPalette.ts +209 -0
- package/src/generated/model/buildReleaseBodyBundleBrandingThemeLight.ts +34 -0
- package/src/generated/model/buildReleaseBodyBundleBrandingThemeLightPalette.ts +209 -0
- package/src/generated/model/buildReleaseBodyBundleBrandingThemeMode.ts +19 -0
- package/src/generated/model/buildReleaseBodyBundleBrandingTypography.ts +47 -0
- package/src/generated/model/buildReleaseBodyBundleFlowDefinitionsItem.ts +74 -0
- package/src/generated/model/buildReleaseBodyBundleFlowDefinitionsItemAudience.ts +20 -0
- package/src/generated/model/buildReleaseBodyBundleFlowDefinitionsItemStatus.ts +23 -0
- package/src/generated/model/buildReleaseBodyBundleFlowDefinitionsItemStepsItem.ts +91 -0
- package/src/generated/model/buildReleaseBodyBundleFlowDefinitionsItemStepsItemActionsItem.ts +47 -0
- package/src/generated/model/buildReleaseBodyBundleFlowDefinitionsItemStepsItemActionsItemKind.ts +29 -0
- package/src/generated/model/buildReleaseBodyBundleFlowDefinitionsItemStepsItemComplete.ts +20 -0
- package/src/generated/model/buildReleaseBodyBundleFlowDefinitionsItemStepsItemGates.ts +35 -0
- package/src/generated/model/buildReleaseBodyBundleFlowDefinitionsItemStepsItemGatesConfig.ts +13 -0
- package/src/generated/model/buildReleaseBodyBundleFlowDefinitionsItemStepsItemGatesKind.ts +19 -0
- package/src/generated/model/buildReleaseBodyBundleFlowDefinitionsItemStepsItemOnSuccess.ts +25 -0
- package/src/generated/model/buildReleaseBodyBundleFlowDefinitionsItemStepsItemTransitions.ts +48 -0
- package/src/generated/model/buildReleaseBodyBundleFlowDefinitionsItemStepsItemTransitionsAction.ts +25 -0
- package/src/generated/model/buildReleaseBodyBundleFlowDefinitionsItemStepsItemTransitionsPurpose.ts +30 -0
- package/src/generated/model/buildReleaseBodyBundleIdpsItem.ts +44 -0
- package/src/generated/model/buildReleaseBodyBundleIdpsItemClaimMapping.ts +12 -0
- package/src/generated/model/buildReleaseBodyBundleIdpsItemOidc.ts +65 -0
- package/src/generated/model/buildReleaseBodyBundleIdpsItemOidcStaticAuthorizeParameters.ts +12 -0
- package/src/generated/model/buildReleaseBodyBundleIdpsItemOidcTokenEndpointAuthMethod.ts +18 -0
- package/src/generated/model/buildReleaseBodyBundleIdpsItemProtocol.ts +17 -0
- package/src/generated/model/buildReleaseBodyBundleIdpsItemProvisioning.ts +15 -0
- package/src/generated/model/buildReleaseBodyBundleIdpsItemProvisioningCreation.ts +15 -0
- package/src/generated/model/buildReleaseBodyBundleIdpsItemVerifiedClaims.ts +12 -0
- package/src/generated/model/buildReleaseBodyBundlePoliciesItem.ts +47 -0
- package/src/generated/model/buildReleaseBodyBundleSchemasItem.ts +85 -0
- package/src/generated/model/buildReleaseDefault.ts +225 -0
- package/src/generated/model/buildReleaseParams.ts +15 -0
- package/src/generated/model/completeClaim200.ts +19 -0
- package/src/generated/model/completeClaim400.ts +20 -0
- package/src/generated/model/completeClaim400Details.ts +12 -0
- package/src/generated/model/completeClaim401.ts +23 -0
- package/src/generated/model/completeClaim403.ts +36 -0
- package/src/generated/model/completeClaim404.ts +20 -0
- package/src/generated/model/completeClaim404Details.ts +12 -0
- package/src/generated/model/completeClaim409.ts +25 -0
- package/src/generated/model/completeClaim409Details.ts +14 -0
- package/src/generated/model/completeClaim410.ts +27 -0
- package/src/generated/model/completeClaim429.ts +20 -0
- package/src/generated/model/completeClaim429Details.ts +12 -0
- package/src/generated/model/completeClaimBody.ts +18 -0
- package/src/generated/model/completeClaimDefault.ts +144 -0
- package/src/generated/model/createAuthAttempt201.ts +49 -44
- package/src/generated/model/createAuthAttempt201ChallengesItem.ts +26 -22
- package/src/generated/model/createAuthAttempt201ChallengesItemMethod.ts +8 -7
- package/src/generated/model/createAuthAttempt201ChallengesItemPayload.ts +24 -26
- package/src/generated/model/createAuthAttempt201ChallengesItemState.ts +9 -10
- package/src/generated/model/createAuthAttempt201CompletedFactorsItem.ts +11 -10
- package/src/generated/model/createAuthAttempt201CompletedFactorsItemMethod.ts +7 -6
- package/src/generated/model/createAuthAttempt201CompletedFactorsItemPayload.ts +27 -23
- package/src/generated/model/createAuthAttempt201RequiredFactorsItem.ts +7 -6
- package/src/generated/model/createAuthAttempt201State.ts +11 -12
- package/src/generated/model/createAuthAttempt403.ts +20 -0
- package/src/generated/model/createAuthAttempt403Details.ts +12 -0
- package/src/generated/model/createAuthAttemptBody.ts +21 -8
- package/src/generated/model/createAuthAttemptDefault.ts +92 -22
- package/src/generated/model/createBranding201.ts +32 -0
- package/src/generated/model/createBranding201Branding.ts +78 -0
- package/src/generated/model/createBranding201BrandingLayout.ts +26 -0
- package/src/generated/model/createBranding201BrandingShape.ts +30 -0
- package/src/generated/model/createBranding201BrandingShapeDensity.ts +19 -0
- package/src/generated/model/createBranding201BrandingTheme.ts +43 -0
- package/src/generated/model/createBranding201BrandingThemeDark.ts +34 -0
- package/src/generated/model/createBranding201BrandingThemeDarkPalette.ts +209 -0
- package/src/generated/model/createBranding201BrandingThemeLight.ts +34 -0
- package/src/generated/model/createBranding201BrandingThemeLightPalette.ts +209 -0
- package/src/generated/model/createBranding201BrandingThemeMode.ts +19 -0
- package/src/generated/model/createBranding201BrandingTypography.ts +47 -0
- package/src/generated/model/createBranding400.ts +20 -0
- package/src/generated/model/createBranding400Details.ts +12 -0
- package/src/generated/model/createBrandingBody.ts +78 -0
- package/src/generated/model/createBrandingBodyLayout.ts +26 -0
- package/src/generated/model/createBrandingBodyShape.ts +30 -0
- package/src/generated/model/createBrandingBodyShapeDensity.ts +19 -0
- package/src/generated/model/createBrandingBodyTheme.ts +43 -0
- package/src/generated/model/createBrandingBodyThemeDark.ts +34 -0
- package/src/generated/model/createBrandingBodyThemeDarkPalette.ts +209 -0
- package/src/generated/model/createBrandingBodyThemeLight.ts +34 -0
- package/src/generated/model/createBrandingBodyThemeLightPalette.ts +209 -0
- package/src/generated/model/createBrandingBodyThemeMode.ts +19 -0
- package/src/generated/model/createBrandingBodyTypography.ts +47 -0
- package/src/generated/model/createBrandingDefault.ts +99 -0
- package/src/generated/model/createBrandingParams.ts +15 -0
- package/src/generated/model/createDeployment200.ts +74 -0
- package/src/generated/model/createDeployment200Kind.ts +18 -0
- package/src/generated/model/createDeployment200Metadata.ts +35 -0
- package/src/generated/model/createDeployment200MetadataDeployedByType.ts +20 -0
- package/src/generated/model/createDeployment200MetadataReason.ts +20 -0
- package/src/generated/model/createDeployment200Release.ts +96 -0
- package/src/generated/model/createDeployment200ReleaseMetadata.ts +43 -0
- package/src/generated/model/createDeployment200ReleaseMetadataCreatedByType.ts +20 -0
- package/src/generated/model/createDeployment200ReleasePointersItem.ts +60 -0
- package/src/generated/model/createDeployment200ReleasePointersItemKind.ts +28 -0
- package/src/generated/model/createDeployment200Status.ts +22 -0
- package/src/generated/model/createDeployment200TargetsItem.ts +28 -0
- package/src/generated/model/createDeployment201.ts +74 -0
- package/src/generated/model/createDeployment201Kind.ts +18 -0
- package/src/generated/model/createDeployment201Metadata.ts +35 -0
- package/src/generated/model/createDeployment201MetadataDeployedByType.ts +20 -0
- package/src/generated/model/createDeployment201MetadataReason.ts +20 -0
- package/src/generated/model/createDeployment201Release.ts +96 -0
- package/src/generated/model/createDeployment201ReleaseMetadata.ts +43 -0
- package/src/generated/model/createDeployment201ReleaseMetadataCreatedByType.ts +20 -0
- package/src/generated/model/createDeployment201ReleasePointersItem.ts +60 -0
- package/src/generated/model/createDeployment201ReleasePointersItemKind.ts +28 -0
- package/src/generated/model/createDeployment201Status.ts +22 -0
- package/src/generated/model/createDeployment201TargetsItem.ts +28 -0
- package/src/generated/model/createDeployment400.ts +45 -0
- package/src/generated/model/createDeployment403.ts +20 -0
- package/src/generated/model/createDeployment403Details.ts +12 -0
- package/src/generated/model/createDeployment404.ts +20 -0
- package/src/generated/model/createDeployment404Details.ts +12 -0
- package/src/generated/model/createDeployment409.ts +259 -0
- package/src/generated/model/createDeploymentBody.ts +93 -0
- package/src/generated/model/createDeploymentBodyReason.ts +20 -0
- package/src/generated/model/createDeploymentDefault.ts +171 -0
- package/src/generated/model/createDeploymentParams.ts +15 -0
- package/src/generated/model/createFlow201.ts +34 -23
- package/src/generated/model/createFlow201Branding.ts +63 -18
- package/src/generated/model/createFlow201BrandingLayout.ts +14 -9
- package/src/generated/model/createFlow201BrandingShape.ts +30 -0
- package/src/generated/model/createFlow201BrandingShapeDensity.ts +19 -0
- package/src/generated/model/createFlow201BrandingTheme.ts +43 -0
- package/src/generated/model/createFlow201BrandingThemeDark.ts +34 -0
- package/src/generated/model/createFlow201BrandingThemeDarkPalette.ts +209 -0
- package/src/generated/model/createFlow201BrandingThemeLight.ts +34 -0
- package/src/generated/model/createFlow201BrandingThemeLightPalette.ts +209 -0
- package/src/generated/model/createFlow201BrandingThemeMode.ts +19 -0
- package/src/generated/model/createFlow201BrandingTypography.ts +47 -0
- package/src/generated/model/createFlow201Step.ts +112 -40
- package/src/generated/model/createFlow201StepActionsItem.ts +27 -14
- package/src/generated/model/createFlow201StepActionsItemKind.ts +27 -0
- package/src/generated/model/createFlow201StepChallenge.ts +19 -18
- package/src/generated/model/createFlow201StepChallengeMethod.ts +5 -4
- package/src/generated/model/createFlow201StepChallengeOptions.ts +4 -5
- package/src/generated/model/createFlow201StepComplete.ts +7 -8
- package/src/generated/model/createFlow201StepFieldsItem.ts +63 -26
- package/src/generated/model/createFlow201StepFieldsItemType.ts +17 -18
- package/src/generated/model/createFlow201StepFieldsItemValidation.ts +28 -27
- package/src/generated/model/createFlow201StepFieldsItemValidationFormat.ts +11 -12
- package/src/generated/model/createFlow201StepGates.ts +24 -24
- package/src/generated/model/createFlow201StepGatesConfig.ts +2 -3
- package/src/generated/model/createFlow201StepGatesKind.ts +6 -7
- package/src/generated/model/createFlow201StepIdentifier.ts +58 -0
- package/src/generated/model/createFlow201StepPurpose.ts +26 -0
- package/src/generated/model/createFlow201StepSsoProvidersItem.ts +1 -1
- package/src/generated/model/createFlow201StepTexts.ts +8 -4
- package/src/generated/model/createFlow400.ts +2 -2
- package/src/generated/model/createFlow400Details.ts +1 -1
- package/src/generated/model/createFlow403.ts +20 -0
- package/src/generated/model/createFlow403Details.ts +12 -0
- package/src/generated/model/createFlow409.ts +20 -0
- package/src/generated/model/createFlow409Details.ts +12 -0
- package/src/generated/model/createFlowBody.ts +32 -15
- package/src/generated/model/createFlowBodyHint.ts +2 -2
- package/src/generated/model/createFlowBodyPurpose.ts +9 -9
- package/src/generated/model/createFlowDefault.ts +193 -6
- package/src/generated/model/createFlowDefinition201.ts +20 -13
- package/src/generated/model/createFlowDefinition201FlowDefinition.ts +50 -34
- package/src/generated/model/createFlowDefinition201FlowDefinitionAudience.ts +4 -5
- package/src/generated/model/createFlowDefinition201FlowDefinitionStatus.ts +23 -0
- package/src/generated/model/createFlowDefinition201FlowDefinitionStepsItem.ts +72 -52
- package/src/generated/model/createFlowDefinition201FlowDefinitionStepsItemActionsItem.ts +33 -14
- package/src/generated/model/createFlowDefinition201FlowDefinitionStepsItemActionsItemKind.ts +29 -0
- package/src/generated/model/createFlowDefinition201FlowDefinitionStepsItemComplete.ts +7 -8
- package/src/generated/model/createFlowDefinition201FlowDefinitionStepsItemGates.ts +25 -25
- package/src/generated/model/createFlowDefinition201FlowDefinitionStepsItemGatesConfig.ts +2 -3
- package/src/generated/model/createFlowDefinition201FlowDefinitionStepsItemGatesKind.ts +6 -7
- package/src/generated/model/createFlowDefinition201FlowDefinitionStepsItemOnSuccess.ts +12 -8
- package/src/generated/model/createFlowDefinition201FlowDefinitionStepsItemTransitions.ts +38 -25
- package/src/generated/model/createFlowDefinition201FlowDefinitionStepsItemTransitionsAction.ts +25 -0
- package/src/generated/model/createFlowDefinition201FlowDefinitionStepsItemTransitionsPurpose.ts +30 -0
- package/src/generated/model/createFlowDefinition201UserSchema.ts +26 -0
- package/src/generated/model/createFlowDefinition201UserSchemaMetadata.ts +12 -0
- package/src/generated/model/createFlowDefinition201UserSchemaSchema.ts +83 -0
- package/src/generated/model/createFlowDefinition400.ts +2 -2
- package/src/generated/model/createFlowDefinition400Details.ts +1 -1
- package/src/generated/model/createFlowDefinitionBody.ts +22 -15
- package/src/generated/model/createFlowDefinitionBodyFlowDefinition.ts +50 -34
- package/src/generated/model/createFlowDefinitionBodyFlowDefinitionAudience.ts +4 -5
- package/src/generated/model/createFlowDefinitionBodyFlowDefinitionStatus.ts +23 -0
- package/src/generated/model/createFlowDefinitionBodyFlowDefinitionStepsItem.ts +72 -52
- package/src/generated/model/createFlowDefinitionBodyFlowDefinitionStepsItemActionsItem.ts +33 -14
- package/src/generated/model/createFlowDefinitionBodyFlowDefinitionStepsItemActionsItemKind.ts +29 -0
- package/src/generated/model/createFlowDefinitionBodyFlowDefinitionStepsItemComplete.ts +7 -8
- package/src/generated/model/createFlowDefinitionBodyFlowDefinitionStepsItemGates.ts +25 -25
- package/src/generated/model/createFlowDefinitionBodyFlowDefinitionStepsItemGatesConfig.ts +2 -3
- package/src/generated/model/createFlowDefinitionBodyFlowDefinitionStepsItemGatesKind.ts +6 -7
- package/src/generated/model/createFlowDefinitionBodyFlowDefinitionStepsItemOnSuccess.ts +12 -8
- package/src/generated/model/createFlowDefinitionBodyFlowDefinitionStepsItemTransitions.ts +38 -25
- package/src/generated/model/createFlowDefinitionBodyFlowDefinitionStepsItemTransitionsAction.ts +25 -0
- package/src/generated/model/createFlowDefinitionBodyFlowDefinitionStepsItemTransitionsPurpose.ts +30 -0
- package/src/generated/model/createFlowDefinitionDefault.ts +103 -6
- package/src/generated/model/createGrant201.ts +49 -0
- package/src/generated/model/createGrant201ObjectType.ts +17 -0
- package/src/generated/model/createGrant201Relation.ts +19 -0
- package/src/generated/model/createGrant201Team.ts +36 -0
- package/src/generated/model/createGrant201TeamStatus.ts +21 -0
- package/src/generated/model/createGrant201User.ts +52 -0
- package/src/generated/model/createGrant201UserAttributes.ts +13 -0
- package/src/generated/model/createGrant201UserMetadata.ts +45 -0
- package/src/generated/model/createGrant201UserMetadataLifecycleOwnerTeam.ts +44 -0
- package/src/generated/model/createGrant201UserMetadataLifecycleOwnerTeamStatus.ts +21 -0
- package/src/generated/model/createGrant201UserMetadataStatus.ts +20 -0
- package/src/generated/model/createGrant400.ts +20 -0
- package/src/generated/model/createGrant400Details.ts +12 -0
- package/src/generated/model/createGrant401.ts +20 -0
- package/src/generated/model/createGrant401Details.ts +12 -0
- package/src/generated/model/createGrant403.ts +20 -0
- package/src/generated/model/createGrant403Details.ts +12 -0
- package/src/generated/model/createGrant404.ts +20 -0
- package/src/generated/model/createGrant404Details.ts +12 -0
- package/src/generated/model/createGrant409.ts +20 -0
- package/src/generated/model/createGrant409Details.ts +12 -0
- package/src/generated/model/createGrant429.ts +20 -0
- package/src/generated/model/createGrant429Details.ts +12 -0
- package/src/generated/model/createGrantBody.ts +38 -0
- package/src/generated/model/createGrantBodyRelation.ts +19 -0
- package/src/generated/model/createGrantBodyTeam.ts +23 -0
- package/src/generated/model/createGrantBodyUser.ts +27 -0
- package/src/generated/model/createGrantDefault.ts +117 -0
- package/src/generated/model/createGrantParams.ts +15 -0
- package/src/generated/model/createHandoff200.ts +16 -16
- package/src/generated/model/createHandoff409.ts +20 -0
- package/src/generated/model/createHandoff409Details.ts +12 -0
- package/src/generated/model/createHandoffDefault.ts +92 -42
- package/src/generated/model/createIdp200.ts +38 -0
- package/src/generated/model/createIdp200Definition.ts +44 -0
- package/src/generated/model/createIdp200DefinitionClaimMapping.ts +12 -0
- package/src/generated/model/createIdp200DefinitionOidc.ts +65 -0
- package/src/generated/model/createIdp200DefinitionOidcStaticAuthorizeParameters.ts +12 -0
- package/src/generated/model/createIdp200DefinitionOidcTokenEndpointAuthMethod.ts +18 -0
- package/src/generated/model/createIdp200DefinitionProtocol.ts +17 -0
- package/src/generated/model/createIdp200DefinitionProvisioning.ts +15 -0
- package/src/generated/model/createIdp200DefinitionProvisioningCreation.ts +15 -0
- package/src/generated/model/createIdp200DefinitionVerifiedClaims.ts +12 -0
- package/src/generated/model/createIdp201.ts +38 -0
- package/src/generated/model/createIdp201Definition.ts +44 -0
- package/src/generated/model/createIdp201DefinitionClaimMapping.ts +12 -0
- package/src/generated/model/createIdp201DefinitionOidc.ts +65 -0
- package/src/generated/model/createIdp201DefinitionOidcStaticAuthorizeParameters.ts +12 -0
- package/src/generated/model/createIdp201DefinitionOidcTokenEndpointAuthMethod.ts +18 -0
- package/src/generated/model/createIdp201DefinitionProtocol.ts +17 -0
- package/src/generated/model/createIdp201DefinitionProvisioning.ts +15 -0
- package/src/generated/model/createIdp201DefinitionProvisioningCreation.ts +15 -0
- package/src/generated/model/createIdp201DefinitionVerifiedClaims.ts +12 -0
- package/src/generated/model/createIdp400.ts +20 -0
- package/src/generated/model/createIdp400Details.ts +12 -0
- package/src/generated/model/createIdp401.ts +20 -0
- package/src/generated/model/createIdp401Details.ts +12 -0
- package/src/generated/model/createIdp403.ts +20 -0
- package/src/generated/model/createIdp403Details.ts +12 -0
- package/src/generated/model/createIdp404.ts +20 -0
- package/src/generated/model/createIdp404Details.ts +12 -0
- package/src/generated/model/createIdpBody.ts +15 -0
- package/src/generated/model/createIdpBodyIdp.ts +44 -0
- package/src/generated/model/createIdpBodyIdpClaimMapping.ts +12 -0
- package/src/generated/model/createIdpBodyIdpOidc.ts +65 -0
- package/src/generated/model/createIdpBodyIdpOidcStaticAuthorizeParameters.ts +12 -0
- package/src/generated/model/createIdpBodyIdpOidcTokenEndpointAuthMethod.ts +18 -0
- package/src/generated/model/createIdpBodyIdpProtocol.ts +17 -0
- package/src/generated/model/createIdpBodyIdpProvisioning.ts +15 -0
- package/src/generated/model/createIdpBodyIdpProvisioningCreation.ts +15 -0
- package/src/generated/model/createIdpBodyIdpVerifiedClaims.ts +12 -0
- package/src/generated/model/createIdpDefault.ts +108 -0
- package/src/generated/model/createIdpParams.ts +15 -0
- package/src/generated/model/createProject201.ts +15 -11
- package/src/generated/model/createProject201OriginsItem.ts +23 -0
- package/src/generated/model/createProject201OriginsItemKind.ts +15 -0
- package/src/generated/model/createProject429.ts +2 -2
- package/src/generated/model/createProject429Details.ts +1 -1
- package/src/generated/model/createProjectBody.ts +16 -4
- package/src/generated/model/createProjectBodyOriginsItem.ts +23 -0
- package/src/generated/model/createProjectBodyOriginsItemKind.ts +15 -0
- package/src/generated/model/createProjectDefault.ts +130 -6
- package/src/generated/model/createRelease200.ts +96 -0
- package/src/generated/model/createRelease200Metadata.ts +43 -0
- package/src/generated/model/createRelease200MetadataCreatedByType.ts +20 -0
- package/src/generated/model/createRelease200PointersItem.ts +60 -0
- package/src/generated/model/createRelease200PointersItemKind.ts +28 -0
- package/src/generated/model/createRelease201.ts +96 -0
- package/src/generated/model/createRelease201Metadata.ts +43 -0
- package/src/generated/model/createRelease201MetadataCreatedByType.ts +20 -0
- package/src/generated/model/createRelease201PointersItem.ts +60 -0
- package/src/generated/model/createRelease201PointersItemKind.ts +28 -0
- package/src/generated/model/createReleaseBody.ts +54 -0
- package/src/generated/model/createReleaseBodyPointersItem.ts +38 -0
- package/src/generated/model/createReleaseBodyPointersItemKind.ts +28 -0
- package/src/generated/model/createReleaseDefault.ts +126 -0
- package/src/generated/model/createReleaseParams.ts +15 -0
- package/src/generated/model/createSchema201.ts +1 -1
- package/src/generated/model/createSchemaBody.ts +78 -83
- package/src/generated/model/createSchemaDefault.ts +139 -6
- package/src/generated/model/createSchemaParams.ts +11 -11
- package/src/generated/model/createSession201.ts +16 -15
- package/src/generated/model/createSession201Session.ts +49 -36
- package/src/generated/model/createSession201SessionFactorsItem.ts +11 -10
- package/src/generated/model/createSession201SessionFactorsItemMethod.ts +7 -6
- package/src/generated/model/createSession201SessionFactorsItemPayload.ts +27 -23
- package/src/generated/model/createSession201SessionMetadata.ts +1 -1
- package/src/generated/model/createSession201SessionState.ts +9 -12
- package/src/generated/model/createSession201SessionUser.ts +40 -0
- package/src/generated/model/createSession201SessionUserAgent.ts +2 -2
- package/src/generated/model/createSession400.ts +2 -2
- package/src/generated/model/createSession400Details.ts +1 -1
- package/src/generated/model/createSessionBody.ts +7 -6
- package/src/generated/model/createSessionBodyUserAgent.ts +4 -5
- package/src/generated/model/createSessionDefault.ts +103 -6
- package/src/generated/model/createTeam201.ts +17 -2
- package/src/generated/model/createTeam201Status.ts +21 -0
- package/src/generated/model/createTeam400.ts +2 -2
- package/src/generated/model/createTeam400Details.ts +1 -1
- package/src/generated/model/createTeam401.ts +20 -0
- package/src/generated/model/createTeam401Details.ts +12 -0
- package/src/generated/model/createTeam403.ts +20 -0
- package/src/generated/model/createTeam403Details.ts +12 -0
- package/src/generated/model/createTeam404.ts +20 -0
- package/src/generated/model/createTeam404Details.ts +12 -0
- package/src/generated/model/createTeam409.ts +20 -0
- package/src/generated/model/createTeam409Details.ts +12 -0
- package/src/generated/model/createTeam429.ts +2 -2
- package/src/generated/model/createTeam429Details.ts +1 -1
- package/src/generated/model/createTeamBody.ts +9 -2
- package/src/generated/model/createTeamDefault.ts +103 -6
- package/src/generated/model/createTeamParams.ts +6 -6
- package/src/generated/model/createUser201.ts +65 -6
- package/src/generated/model/createUser201Attributes.ts +13 -0
- package/src/generated/model/createUser201Metadata.ts +45 -0
- package/src/generated/model/createUser201MetadataLifecycleOwnerTeam.ts +44 -0
- package/src/generated/model/createUser201MetadataLifecycleOwnerTeamStatus.ts +21 -0
- package/src/generated/model/createUser201MetadataStatus.ts +20 -0
- package/src/generated/model/createUser201TeamsItem.ts +33 -0
- package/src/generated/model/createUser201TeamsItemMembershipStatus.ts +20 -0
- package/src/generated/model/createUser400.ts +2 -2
- package/src/generated/model/createUser400Details.ts +1 -1
- package/src/generated/model/createUser401.ts +2 -2
- package/src/generated/model/createUser401Details.ts +1 -1
- package/src/generated/model/createUser403.ts +2 -2
- package/src/generated/model/createUser403Details.ts +1 -1
- package/src/generated/model/createUser409.ts +2 -2
- package/src/generated/model/createUser409Details.ts +1 -1
- package/src/generated/model/createUser500.ts +20 -0
- package/src/generated/model/createUser500Details.ts +12 -0
- package/src/generated/model/createUserBody.ts +26 -7
- package/src/generated/model/createUserBodyAttributes.ts +13 -0
- package/src/generated/model/createUserDefault.ts +94 -6
- package/src/generated/model/createUserParams.ts +22 -11
- package/src/generated/model/deleteGrant401.ts +20 -0
- package/src/generated/model/deleteGrant401Details.ts +12 -0
- package/src/generated/model/deleteGrant403.ts +20 -0
- package/src/generated/model/deleteGrant403Details.ts +12 -0
- package/src/generated/model/deleteGrant404.ts +20 -0
- package/src/generated/model/deleteGrant404Details.ts +12 -0
- package/src/generated/model/deleteGrantDefault.ts +90 -0
- package/src/generated/model/deleteGrantParams.ts +15 -0
- package/src/generated/model/deleteTeam400.ts +20 -0
- package/src/generated/model/deleteTeam400Details.ts +12 -0
- package/src/generated/model/deleteTeam401.ts +20 -0
- package/src/generated/model/deleteTeam401Details.ts +12 -0
- package/src/generated/model/deleteTeam403.ts +20 -0
- package/src/generated/model/deleteTeam403Details.ts +12 -0
- package/src/generated/model/deleteTeam409.ts +20 -0
- package/src/generated/model/deleteTeam409Details.ts +12 -0
- package/src/generated/model/deleteTeamDefault.ts +90 -0
- package/src/generated/model/deleteUserByID401.ts +20 -0
- package/src/generated/model/deleteUserByID401Details.ts +12 -0
- package/src/generated/model/deleteUserByID404.ts +20 -0
- package/src/generated/model/deleteUserByID404Details.ts +12 -0
- package/src/generated/model/deleteUserByIDDefault.ts +90 -0
- package/src/generated/model/deleteVariableDefault.ts +81 -0
- package/src/generated/model/deleteVariableKind.ts +15 -0
- package/src/generated/model/deleteVariableParams.ts +21 -0
- package/src/generated/model/exchangeHandoff200.ts +16 -15
- package/src/generated/model/exchangeHandoff200Session.ts +49 -36
- package/src/generated/model/exchangeHandoff200SessionFactorsItem.ts +11 -10
- package/src/generated/model/exchangeHandoff200SessionFactorsItemMethod.ts +7 -6
- package/src/generated/model/exchangeHandoff200SessionFactorsItemPayload.ts +27 -23
- package/src/generated/model/exchangeHandoff200SessionMetadata.ts +1 -1
- package/src/generated/model/exchangeHandoff200SessionState.ts +9 -12
- package/src/generated/model/exchangeHandoff200SessionUser.ts +40 -0
- package/src/generated/model/exchangeHandoff200SessionUserAgent.ts +2 -2
- package/src/generated/model/exchangeHandoff400.ts +2 -2
- package/src/generated/model/exchangeHandoff400Details.ts +1 -1
- package/src/generated/model/exchangeHandoff401.ts +2 -2
- package/src/generated/model/exchangeHandoff401Details.ts +1 -1
- package/src/generated/model/exchangeHandoff403.ts +20 -0
- package/src/generated/model/exchangeHandoff403Details.ts +12 -0
- package/src/generated/model/exchangeHandoff409.ts +20 -0
- package/src/generated/model/exchangeHandoff409Details.ts +12 -0
- package/src/generated/model/exchangeHandoffBody.ts +10 -7
- package/src/generated/model/exchangeHandoffDefault.ts +166 -6
- package/src/generated/model/exchangeHandoffParams.ts +6 -6
- package/src/generated/model/finishUserPasskeyRegistration201.ts +19 -0
- package/src/generated/model/finishUserPasskeyRegistration400.ts +20 -0
- package/src/generated/model/finishUserPasskeyRegistration400Details.ts +12 -0
- package/src/generated/model/finishUserPasskeyRegistration401.ts +20 -0
- package/src/generated/model/finishUserPasskeyRegistration401Details.ts +12 -0
- package/src/generated/model/finishUserPasskeyRegistration403.ts +20 -0
- package/src/generated/model/finishUserPasskeyRegistration403Details.ts +12 -0
- package/src/generated/model/finishUserPasskeyRegistration404.ts +20 -0
- package/src/generated/model/finishUserPasskeyRegistration404Details.ts +12 -0
- package/src/generated/model/finishUserPasskeyRegistration500.ts +20 -0
- package/src/generated/model/finishUserPasskeyRegistration500Details.ts +12 -0
- package/src/generated/model/finishUserPasskeyRegistrationBody.ts +21 -0
- package/src/generated/model/finishUserPasskeyRegistrationBodyAttestation.ts +12 -0
- package/src/generated/model/finishUserPasskeyRegistrationDefault.ts +180 -0
- package/src/generated/model/getAuthAttempt200.ts +49 -44
- package/src/generated/model/getAuthAttempt200ChallengesItem.ts +26 -22
- package/src/generated/model/getAuthAttempt200ChallengesItemMethod.ts +8 -7
- package/src/generated/model/getAuthAttempt200ChallengesItemPayload.ts +24 -26
- package/src/generated/model/getAuthAttempt200ChallengesItemState.ts +9 -10
- package/src/generated/model/getAuthAttempt200CompletedFactorsItem.ts +11 -10
- package/src/generated/model/getAuthAttempt200CompletedFactorsItemMethod.ts +7 -6
- package/src/generated/model/getAuthAttempt200CompletedFactorsItemPayload.ts +27 -23
- package/src/generated/model/getAuthAttempt200RequiredFactorsItem.ts +7 -6
- package/src/generated/model/getAuthAttempt200State.ts +11 -12
- package/src/generated/model/getAuthAttemptDefault.ts +56 -22
- package/src/generated/model/getBrandingById200.ts +32 -0
- package/src/generated/model/getBrandingById200Branding.ts +78 -0
- package/src/generated/model/getBrandingById200BrandingLayout.ts +26 -0
- package/src/generated/model/getBrandingById200BrandingShape.ts +30 -0
- package/src/generated/model/getBrandingById200BrandingShapeDensity.ts +19 -0
- package/src/generated/model/getBrandingById200BrandingTheme.ts +43 -0
- package/src/generated/model/getBrandingById200BrandingThemeDark.ts +34 -0
- package/src/generated/model/getBrandingById200BrandingThemeDarkPalette.ts +209 -0
- package/src/generated/model/getBrandingById200BrandingThemeLight.ts +34 -0
- package/src/generated/model/getBrandingById200BrandingThemeLightPalette.ts +209 -0
- package/src/generated/model/getBrandingById200BrandingThemeMode.ts +19 -0
- package/src/generated/model/getBrandingById200BrandingTypography.ts +47 -0
- package/src/generated/model/getBrandingById404.ts +20 -0
- package/src/generated/model/getBrandingById404Details.ts +12 -0
- package/src/generated/model/getBrandingByIdDefault.ts +72 -0
- package/src/generated/model/getClaimStatus200.ts +28 -0
- package/src/generated/model/getClaimStatus401.ts +20 -0
- package/src/generated/model/getClaimStatus401Details.ts +12 -0
- package/src/generated/model/getClaimStatus403.ts +23 -0
- package/src/generated/model/getClaimStatus404.ts +20 -0
- package/src/generated/model/getClaimStatus404Details.ts +12 -0
- package/src/generated/model/getClaimStatus410.ts +27 -0
- package/src/generated/model/getClaimStatus429.ts +20 -0
- package/src/generated/model/getClaimStatus429Details.ts +12 -0
- package/src/generated/model/getClaimStatusDefault.ts +99 -0
- package/src/generated/model/getClaimStatusParams.ts +15 -0
- package/src/generated/model/getClaimWindow200.ts +23 -0
- package/src/generated/model/getClaimWindow404.ts +20 -0
- package/src/generated/model/getClaimWindow404Details.ts +12 -0
- package/src/generated/model/getClaimWindow429.ts +20 -0
- package/src/generated/model/getClaimWindow429Details.ts +12 -0
- package/src/generated/model/getClaimWindowDefault.ts +36 -0
- package/src/generated/model/getClaimWindowParams.ts +15 -0
- package/src/generated/model/getDeploymentById200.ts +74 -0
- package/src/generated/model/getDeploymentById200Kind.ts +18 -0
- package/src/generated/model/getDeploymentById200Metadata.ts +35 -0
- package/src/generated/model/getDeploymentById200MetadataDeployedByType.ts +20 -0
- package/src/generated/model/getDeploymentById200MetadataReason.ts +20 -0
- package/src/generated/model/getDeploymentById200Release.ts +96 -0
- package/src/generated/model/getDeploymentById200ReleaseMetadata.ts +43 -0
- package/src/generated/model/getDeploymentById200ReleaseMetadataCreatedByType.ts +20 -0
- package/src/generated/model/getDeploymentById200ReleasePointersItem.ts +60 -0
- package/src/generated/model/getDeploymentById200ReleasePointersItemKind.ts +28 -0
- package/src/generated/model/getDeploymentById200Status.ts +22 -0
- package/src/generated/model/getDeploymentById200TargetsItem.ts +28 -0
- package/src/generated/model/getDeploymentByIdDefault.ts +72 -0
- package/src/generated/model/getDeploymentByIdParams.ts +15 -0
- package/src/generated/model/getDeploymentVariables200.ts +17 -0
- package/src/generated/model/getDeploymentVariablesDefault.ts +90 -0
- package/src/generated/model/getDeploymentVariablesParams.ts +15 -0
- package/src/generated/model/getEvent200.ts +3705 -0
- package/src/generated/model/getEvent401.ts +20 -0
- package/src/generated/model/getEvent401Details.ts +12 -0
- package/src/generated/model/getEvent403.ts +20 -0
- package/src/generated/model/getEvent403Details.ts +12 -0
- package/src/generated/model/getEvent404.ts +20 -0
- package/src/generated/model/getEvent404Details.ts +12 -0
- package/src/generated/model/getEventDefault.ts +81 -0
- package/src/generated/model/getEventParams.ts +15 -0
- package/src/generated/model/getFlowDefinition200.ts +20 -13
- package/src/generated/model/getFlowDefinition200FlowDefinition.ts +50 -34
- package/src/generated/model/getFlowDefinition200FlowDefinitionAudience.ts +4 -5
- package/src/generated/model/getFlowDefinition200FlowDefinitionStatus.ts +23 -0
- package/src/generated/model/getFlowDefinition200FlowDefinitionStepsItem.ts +72 -52
- package/src/generated/model/getFlowDefinition200FlowDefinitionStepsItemActionsItem.ts +33 -14
- package/src/generated/model/getFlowDefinition200FlowDefinitionStepsItemActionsItemKind.ts +29 -0
- package/src/generated/model/getFlowDefinition200FlowDefinitionStepsItemComplete.ts +7 -8
- package/src/generated/model/getFlowDefinition200FlowDefinitionStepsItemGates.ts +25 -25
- package/src/generated/model/getFlowDefinition200FlowDefinitionStepsItemGatesConfig.ts +2 -3
- package/src/generated/model/getFlowDefinition200FlowDefinitionStepsItemGatesKind.ts +6 -7
- package/src/generated/model/getFlowDefinition200FlowDefinitionStepsItemOnSuccess.ts +12 -8
- package/src/generated/model/getFlowDefinition200FlowDefinitionStepsItemTransitions.ts +38 -25
- package/src/generated/model/getFlowDefinition200FlowDefinitionStepsItemTransitionsAction.ts +25 -0
- package/src/generated/model/getFlowDefinition200FlowDefinitionStepsItemTransitionsPurpose.ts +30 -0
- package/src/generated/model/getFlowDefinition200UserSchema.ts +26 -0
- package/src/generated/model/getFlowDefinition200UserSchemaMetadata.ts +12 -0
- package/src/generated/model/getFlowDefinition200UserSchemaSchema.ts +83 -0
- package/src/generated/model/getFlowDefinitionDefault.ts +76 -6
- package/src/generated/model/getFlowStep200.ts +34 -23
- package/src/generated/model/getFlowStep200Branding.ts +63 -18
- package/src/generated/model/getFlowStep200BrandingLayout.ts +14 -9
- package/src/generated/model/getFlowStep200BrandingShape.ts +30 -0
- package/src/generated/model/getFlowStep200BrandingShapeDensity.ts +19 -0
- package/src/generated/model/getFlowStep200BrandingTheme.ts +43 -0
- package/src/generated/model/getFlowStep200BrandingThemeDark.ts +34 -0
- package/src/generated/model/getFlowStep200BrandingThemeDarkPalette.ts +209 -0
- package/src/generated/model/getFlowStep200BrandingThemeLight.ts +34 -0
- package/src/generated/model/getFlowStep200BrandingThemeLightPalette.ts +209 -0
- package/src/generated/model/getFlowStep200BrandingThemeMode.ts +19 -0
- package/src/generated/model/getFlowStep200BrandingTypography.ts +47 -0
- package/src/generated/model/getFlowStep200Step.ts +112 -40
- package/src/generated/model/getFlowStep200StepActionsItem.ts +27 -14
- package/src/generated/model/getFlowStep200StepActionsItemKind.ts +27 -0
- package/src/generated/model/getFlowStep200StepChallenge.ts +19 -18
- package/src/generated/model/getFlowStep200StepChallengeMethod.ts +5 -4
- package/src/generated/model/getFlowStep200StepChallengeOptions.ts +4 -5
- package/src/generated/model/getFlowStep200StepComplete.ts +7 -8
- package/src/generated/model/getFlowStep200StepFieldsItem.ts +63 -26
- package/src/generated/model/getFlowStep200StepFieldsItemType.ts +17 -18
- package/src/generated/model/getFlowStep200StepFieldsItemValidation.ts +28 -27
- package/src/generated/model/getFlowStep200StepFieldsItemValidationFormat.ts +11 -12
- package/src/generated/model/getFlowStep200StepGates.ts +24 -24
- package/src/generated/model/getFlowStep200StepGatesConfig.ts +2 -3
- package/src/generated/model/getFlowStep200StepGatesKind.ts +6 -7
- package/src/generated/model/getFlowStep200StepIdentifier.ts +58 -0
- package/src/generated/model/getFlowStep200StepPurpose.ts +26 -0
- package/src/generated/model/getFlowStep200StepSsoProvidersItem.ts +1 -1
- package/src/generated/model/getFlowStep200StepTexts.ts +8 -4
- package/src/generated/model/getFlowStep404.ts +2 -2
- package/src/generated/model/getFlowStep404Details.ts +1 -1
- package/src/generated/model/getFlowStep409.ts +20 -0
- package/src/generated/model/getFlowStep409Details.ts +12 -0
- package/src/generated/model/getFlowStep410.ts +2 -2
- package/src/generated/model/getFlowStep410Details.ts +1 -1
- package/src/generated/model/getFlowStepDefault.ts +328 -6
- package/src/generated/model/getGrant200.ts +49 -0
- package/src/generated/model/getGrant200ObjectType.ts +17 -0
- package/src/generated/model/getGrant200Relation.ts +19 -0
- package/src/generated/model/getGrant200Team.ts +36 -0
- package/src/generated/model/getGrant200TeamStatus.ts +21 -0
- package/src/generated/model/getGrant200User.ts +52 -0
- package/src/generated/model/getGrant200UserAttributes.ts +13 -0
- package/src/generated/model/getGrant200UserMetadata.ts +45 -0
- package/src/generated/model/getGrant200UserMetadataLifecycleOwnerTeam.ts +44 -0
- package/src/generated/model/getGrant200UserMetadataLifecycleOwnerTeamStatus.ts +21 -0
- package/src/generated/model/getGrant200UserMetadataStatus.ts +20 -0
- package/src/generated/model/getGrant401.ts +20 -0
- package/src/generated/model/getGrant401Details.ts +12 -0
- package/src/generated/model/getGrant403.ts +20 -0
- package/src/generated/model/getGrant403Details.ts +12 -0
- package/src/generated/model/getGrant404.ts +20 -0
- package/src/generated/model/getGrant404Details.ts +12 -0
- package/src/generated/model/getGrantDefault.ts +90 -0
- package/src/generated/model/getGrantExpandItem.ts +29 -0
- package/src/generated/model/getGrantParams.ts +21 -0
- package/src/generated/model/getIdpById200.ts +38 -0
- package/src/generated/model/getIdpById200Definition.ts +44 -0
- package/src/generated/model/getIdpById200DefinitionClaimMapping.ts +12 -0
- package/src/generated/model/getIdpById200DefinitionOidc.ts +65 -0
- package/src/generated/model/getIdpById200DefinitionOidcStaticAuthorizeParameters.ts +12 -0
- package/src/generated/model/getIdpById200DefinitionOidcTokenEndpointAuthMethod.ts +18 -0
- package/src/generated/model/getIdpById200DefinitionProtocol.ts +17 -0
- package/src/generated/model/getIdpById200DefinitionProvisioning.ts +15 -0
- package/src/generated/model/getIdpById200DefinitionProvisioningCreation.ts +15 -0
- package/src/generated/model/getIdpById200DefinitionVerifiedClaims.ts +12 -0
- package/src/generated/model/getIdpById401.ts +20 -0
- package/src/generated/model/getIdpById401Details.ts +12 -0
- package/src/generated/model/getIdpById403.ts +20 -0
- package/src/generated/model/getIdpById403Details.ts +12 -0
- package/src/generated/model/getIdpById404.ts +20 -0
- package/src/generated/model/getIdpById404Details.ts +12 -0
- package/src/generated/model/getIdpByIdDefault.ts +72 -0
- package/src/generated/model/getIdpByIdParams.ts +15 -0
- package/src/generated/model/getIdpRevisionById200.ts +38 -0
- package/src/generated/model/getIdpRevisionById200Definition.ts +44 -0
- package/src/generated/model/getIdpRevisionById200DefinitionClaimMapping.ts +12 -0
- package/src/generated/model/getIdpRevisionById200DefinitionOidc.ts +65 -0
- package/src/generated/model/getIdpRevisionById200DefinitionOidcStaticAuthorizeParameters.ts +12 -0
- package/src/generated/model/getIdpRevisionById200DefinitionOidcTokenEndpointAuthMethod.ts +18 -0
- package/src/generated/model/getIdpRevisionById200DefinitionProtocol.ts +17 -0
- package/src/generated/model/getIdpRevisionById200DefinitionProvisioning.ts +15 -0
- package/src/generated/model/getIdpRevisionById200DefinitionProvisioningCreation.ts +15 -0
- package/src/generated/model/getIdpRevisionById200DefinitionVerifiedClaims.ts +12 -0
- package/src/generated/model/getIdpRevisionById401.ts +20 -0
- package/src/generated/model/getIdpRevisionById401Details.ts +12 -0
- package/src/generated/model/getIdpRevisionById403.ts +20 -0
- package/src/generated/model/getIdpRevisionById403Details.ts +12 -0
- package/src/generated/model/getIdpRevisionById404.ts +20 -0
- package/src/generated/model/getIdpRevisionById404Details.ts +12 -0
- package/src/generated/model/getIdpRevisionByIdDefault.ts +72 -0
- package/src/generated/model/getIdpRevisionByIdParams.ts +15 -0
- package/src/generated/model/getLive4xx.ts +2 -2
- package/src/generated/model/getLive4xxDetails.ts +1 -1
- package/src/generated/model/getLiveDefault.ts +13 -6
- package/src/generated/model/getMyPasswordState200.ts +16 -0
- package/src/generated/model/getMyPasswordState401.ts +23 -0
- package/src/generated/model/getMyPasswordState403.ts +23 -0
- package/src/generated/model/getMyPasswordStateDefault.ts +72 -0
- package/src/generated/model/getMyPasswordStateParams.ts +26 -0
- package/src/generated/model/getMySession200.ts +49 -36
- package/src/generated/model/getMySession200FactorsItem.ts +11 -10
- package/src/generated/model/getMySession200FactorsItemMethod.ts +7 -6
- package/src/generated/model/getMySession200FactorsItemPayload.ts +27 -23
- package/src/generated/model/getMySession200Metadata.ts +1 -1
- package/src/generated/model/getMySession200State.ts +9 -11
- package/src/generated/model/getMySession200User.ts +40 -0
- package/src/generated/model/getMySession200UserAgent.ts +2 -2
- package/src/generated/model/getMySession401.ts +7 -4
- package/src/generated/model/getMySession403.ts +23 -0
- package/src/generated/model/getMySession404.ts +7 -4
- package/src/generated/model/getMySessionCsrfToken200.ts +18 -0
- package/src/generated/model/getMySessionCsrfToken401.ts +23 -0
- package/src/generated/model/getMySessionCsrfToken403.ts +23 -0
- package/src/generated/model/getMySessionCsrfTokenDefault.ts +72 -0
- package/src/generated/model/getMySessionCsrfTokenParams.ts +26 -0
- package/src/generated/model/getMySessionDefault.ts +58 -6
- package/src/generated/model/getMySessionParams.ts +26 -0
- package/src/generated/model/getMyUser200.ts +70 -2
- package/src/generated/model/getMyUser200Attributes.ts +13 -0
- package/src/generated/model/getMyUser200Metadata.ts +45 -0
- package/src/generated/model/getMyUser200MetadataLifecycleOwnerTeam.ts +44 -0
- package/src/generated/model/getMyUser200MetadataLifecycleOwnerTeamStatus.ts +21 -0
- package/src/generated/model/getMyUser200MetadataStatus.ts +20 -0
- package/src/generated/model/getMyUser200TeamsItem.ts +33 -0
- package/src/generated/model/getMyUser200TeamsItemMembershipStatus.ts +20 -0
- package/src/generated/model/getMyUser401.ts +2 -2
- package/src/generated/model/getMyUser401Details.ts +1 -1
- package/src/generated/model/getMyUser403.ts +23 -0
- package/src/generated/model/getMyUser404.ts +4 -5
- package/src/generated/model/getMyUserDefault.ts +58 -6
- package/src/generated/model/getMyUserParams.ts +26 -0
- package/src/generated/model/getMyUserSchema200.ts +31 -0
- package/src/generated/model/getMyUserSchema200Metadata.ts +12 -0
- package/src/generated/model/getMyUserSchema200Schema.ts +83 -0
- package/src/generated/model/getMyUserSchema401.ts +23 -0
- package/src/generated/model/getMyUserSchema403.ts +23 -0
- package/src/generated/model/getMyUserSchema404.ts +23 -0
- package/src/generated/model/getMyUserSchemaDefault.ts +72 -0
- package/src/generated/model/getMyUserSchemaParams.ts +26 -0
- package/src/generated/model/getPolicy200.ts +62 -0
- package/src/generated/model/getPolicyDefault.ts +72 -0
- package/src/generated/model/getPolicyParams.ts +15 -0
- package/src/generated/model/getPolicyRevision200.ts +62 -0
- package/src/generated/model/getPolicyRevisionDefault.ts +72 -0
- package/src/generated/model/getPolicyRevisionParams.ts +15 -0
- package/src/generated/model/getProject200.ts +78 -5
- package/src/generated/model/getProject401.ts +2 -2
- package/src/generated/model/getProject401Details.ts +1 -1
- package/src/generated/model/getProject404.ts +2 -2
- package/src/generated/model/getProject404Details.ts +1 -1
- package/src/generated/model/getProjectDefault.ts +58 -6
- package/src/generated/model/getReady4xx.ts +2 -2
- package/src/generated/model/getReady4xxDetails.ts +1 -1
- package/src/generated/model/getReadyDefault.ts +13 -6
- package/src/generated/model/getReleaseById200.ts +96 -0
- package/src/generated/model/getReleaseById200Metadata.ts +43 -0
- package/src/generated/model/getReleaseById200MetadataCreatedByType.ts +20 -0
- package/src/generated/model/getReleaseById200PointersItem.ts +60 -0
- package/src/generated/model/getReleaseById200PointersItemKind.ts +28 -0
- package/src/generated/model/getReleaseByIdDefault.ts +72 -0
- package/src/generated/model/getReleaseByIdParams.ts +15 -0
- package/src/generated/model/getSchemaById200.ts +22 -74
- package/src/generated/model/getSchemaById200Metadata.ts +12 -0
- package/src/generated/model/getSchemaById200Schema.ts +83 -0
- package/src/generated/model/getSchemaByIdDefault.ts +58 -6
- package/src/generated/model/getSchemaByIdParams.ts +12 -11
- package/src/generated/model/getSession200.ts +49 -36
- package/src/generated/model/getSession200FactorsItem.ts +11 -10
- package/src/generated/model/getSession200FactorsItemMethod.ts +7 -6
- package/src/generated/model/getSession200FactorsItemPayload.ts +27 -23
- package/src/generated/model/getSession200Metadata.ts +1 -1
- package/src/generated/model/getSession200State.ts +9 -11
- package/src/generated/model/getSession200User.ts +40 -0
- package/src/generated/model/getSession200UserAgent.ts +2 -2
- package/src/generated/model/getSession401.ts +2 -2
- package/src/generated/model/getSession401Details.ts +1 -1
- package/src/generated/model/getSession403.ts +20 -0
- package/src/generated/model/getSession403Details.ts +12 -0
- package/src/generated/model/getSession404.ts +2 -2
- package/src/generated/model/getSession404Details.ts +1 -1
- package/src/generated/model/getSessionDefault.ts +58 -6
- package/src/generated/model/getTeam200.ts +14 -4
- package/src/generated/model/getTeam200Status.ts +21 -0
- package/src/generated/model/getTeam401.ts +2 -2
- package/src/generated/model/getTeam401Details.ts +1 -1
- package/src/generated/model/getTeam404.ts +2 -2
- package/src/generated/model/getTeam404Details.ts +1 -1
- package/src/generated/model/getTeamDefault.ts +58 -6
- package/src/generated/model/getUserByID200.ts +70 -2
- package/src/generated/model/getUserByID200Attributes.ts +13 -0
- package/src/generated/model/getUserByID200Metadata.ts +45 -0
- package/src/generated/model/getUserByID200MetadataLifecycleOwnerTeam.ts +44 -0
- package/src/generated/model/getUserByID200MetadataLifecycleOwnerTeamStatus.ts +21 -0
- package/src/generated/model/getUserByID200MetadataStatus.ts +20 -0
- package/src/generated/model/getUserByID200TeamsItem.ts +33 -0
- package/src/generated/model/getUserByID200TeamsItemMembershipStatus.ts +20 -0
- package/src/generated/model/getUserByID401.ts +2 -2
- package/src/generated/model/getUserByID401Details.ts +1 -1
- package/src/generated/model/getUserByID404.ts +2 -2
- package/src/generated/model/getUserByID404Details.ts +1 -1
- package/src/generated/model/getUserByIDDefault.ts +58 -6
- package/src/generated/model/getUserByIDParams.ts +21 -11
- package/src/generated/model/getUserPasswordState200.ts +16 -0
- package/src/generated/model/getUserPasswordState401.ts +20 -0
- package/src/generated/model/getUserPasswordState401Details.ts +12 -0
- package/src/generated/model/getUserPasswordState403.ts +20 -0
- package/src/generated/model/getUserPasswordState403Details.ts +12 -0
- package/src/generated/model/getUserPasswordState404.ts +20 -0
- package/src/generated/model/getUserPasswordState404Details.ts +12 -0
- package/src/generated/model/getUserPasswordState500.ts +20 -0
- package/src/generated/model/getUserPasswordState500Details.ts +12 -0
- package/src/generated/model/getUserPasswordStateDefault.ts +72 -0
- package/src/generated/model/getVariable200.ts +33 -0
- package/src/generated/model/getVariable200Preview.ts +20 -0
- package/src/generated/model/getVariable200Primary.ts +20 -0
- package/src/generated/model/getVariableDefault.ts +72 -0
- package/src/generated/model/getVariableKind.ts +15 -0
- package/src/generated/model/getVariableParams.ts +21 -0
- package/src/generated/model/getVariables200.ts +35 -0
- package/src/generated/model/getVariables200Preview.ts +20 -0
- package/src/generated/model/getVariables200Primary.ts +20 -0
- package/src/generated/model/getVariablesDefault.ts +72 -0
- package/src/generated/model/getVariablesKind.ts +15 -0
- package/src/generated/model/getVariablesParams.ts +21 -0
- package/src/generated/model/index.ts +1363 -488
- package/src/generated/model/initClaim201.ts +25 -0
- package/src/generated/model/initClaim401.ts +20 -0
- package/src/generated/model/initClaim401Details.ts +12 -0
- package/src/generated/model/initClaim404.ts +23 -0
- package/src/generated/model/initClaim409.ts +25 -0
- package/src/generated/model/initClaim409Details.ts +14 -0
- package/src/generated/model/initClaim410.ts +23 -0
- package/src/generated/model/initClaimDefault.ts +99 -0
- package/src/generated/model/issueChallenge201.ts +26 -22
- package/src/generated/model/issueChallenge201Method.ts +8 -7
- package/src/generated/model/issueChallenge201Payload.ts +24 -26
- package/src/generated/model/issueChallenge201State.ts +9 -10
- package/src/generated/model/issueChallengeBody.ts +13 -11
- package/src/generated/model/issueChallengeBodyMethod.ts +8 -7
- package/src/generated/model/issueChallengeBodyPasskeyOptions.ts +2 -2
- package/src/generated/model/issueChallengeBodyPasskeyOptionsUserVerification.ts +6 -6
- package/src/generated/model/issueChallengeDefault.ts +83 -52
- package/src/generated/model/listBranding200Item.ts +14 -0
- package/src/generated/model/listBrandingDefault.ts +72 -0
- package/src/generated/model/listBrandingParams.ts +15 -0
- package/src/generated/model/listDeployments200.ts +20 -0
- package/src/generated/model/listDeployments200DeploymentsItem.ts +74 -0
- package/src/generated/model/listDeployments200DeploymentsItemKind.ts +18 -0
- package/src/generated/model/listDeployments200DeploymentsItemMetadata.ts +35 -0
- package/src/generated/model/listDeployments200DeploymentsItemMetadataDeployedByType.ts +20 -0
- package/src/generated/model/listDeployments200DeploymentsItemMetadataReason.ts +20 -0
- package/src/generated/model/listDeployments200DeploymentsItemRelease.ts +96 -0
- package/src/generated/model/listDeployments200DeploymentsItemReleaseMetadata.ts +43 -0
- package/src/generated/model/listDeployments200DeploymentsItemReleaseMetadataCreatedByType.ts +20 -0
- package/src/generated/model/listDeployments200DeploymentsItemReleasePointersItem.ts +60 -0
- package/src/generated/model/listDeployments200DeploymentsItemReleasePointersItemKind.ts +28 -0
- package/src/generated/model/listDeployments200DeploymentsItemStatus.ts +22 -0
- package/src/generated/model/listDeployments200DeploymentsItemTargetsItem.ts +28 -0
- package/src/generated/model/listDeploymentsDefault.ts +72 -0
- package/src/generated/model/listDeploymentsExpandItem.ts +25 -0
- package/src/generated/model/listDeploymentsParams.ts +48 -0
- package/src/generated/model/listEvents200.ts +20 -0
- package/src/generated/model/listEvents200DataItem.ts +3705 -0
- package/src/generated/model/listEvents400.ts +20 -0
- package/src/generated/model/listEvents400Details.ts +12 -0
- package/src/generated/model/listEvents401.ts +20 -0
- package/src/generated/model/listEvents401Details.ts +12 -0
- package/src/generated/model/listEvents403.ts +20 -0
- package/src/generated/model/listEvents403Details.ts +12 -0
- package/src/generated/model/listEventsCategoryItem.ts +19 -0
- package/src/generated/model/listEventsDefault.ts +81 -0
- package/src/generated/model/listEventsOrder.ts +15 -0
- package/src/generated/model/listEventsParams.ts +63 -0
- package/src/generated/model/listFlowDefinitions200.ts +5 -2
- package/src/generated/model/listFlowDefinitions200FlowDefinitionsItem.ts +22 -20
- package/src/generated/model/listFlowDefinitions200FlowDefinitionsItemFlowDefinition.ts +74 -0
- package/src/generated/model/listFlowDefinitions200FlowDefinitionsItemFlowDefinitionAudience.ts +20 -0
- package/src/generated/model/listFlowDefinitions200FlowDefinitionsItemFlowDefinitionStatus.ts +23 -0
- package/src/generated/model/listFlowDefinitions200FlowDefinitionsItemFlowDefinitionStepsItem.ts +91 -0
- package/src/generated/model/listFlowDefinitions200FlowDefinitionsItemFlowDefinitionStepsItemActionsItem.ts +47 -0
- package/src/generated/model/listFlowDefinitions200FlowDefinitionsItemFlowDefinitionStepsItemActionsItemKind.ts +29 -0
- package/src/generated/model/listFlowDefinitions200FlowDefinitionsItemFlowDefinitionStepsItemComplete.ts +20 -0
- package/src/generated/model/listFlowDefinitions200FlowDefinitionsItemFlowDefinitionStepsItemGates.ts +35 -0
- package/src/generated/model/listFlowDefinitions200FlowDefinitionsItemFlowDefinitionStepsItemGatesConfig.ts +13 -0
- package/src/generated/model/listFlowDefinitions200FlowDefinitionsItemFlowDefinitionStepsItemGatesKind.ts +19 -0
- package/src/generated/model/listFlowDefinitions200FlowDefinitionsItemFlowDefinitionStepsItemOnSuccess.ts +25 -0
- package/src/generated/model/listFlowDefinitions200FlowDefinitionsItemFlowDefinitionStepsItemTransitions.ts +48 -0
- package/src/generated/model/listFlowDefinitions200FlowDefinitionsItemFlowDefinitionStepsItemTransitionsAction.ts +25 -0
- package/src/generated/model/listFlowDefinitions200FlowDefinitionsItemFlowDefinitionStepsItemTransitionsPurpose.ts +30 -0
- package/src/generated/model/listFlowDefinitions200FlowDefinitionsItemUserSchema.ts +26 -0
- package/src/generated/model/listFlowDefinitions200FlowDefinitionsItemUserSchemaMetadata.ts +12 -0
- package/src/generated/model/listFlowDefinitions200FlowDefinitionsItemUserSchemaSchema.ts +83 -0
- package/src/generated/model/listFlowDefinitions400.ts +2 -2
- package/src/generated/model/listFlowDefinitions400Details.ts +1 -1
- package/src/generated/model/listFlowDefinitionsDefault.ts +94 -6
- package/src/generated/model/listFlowDefinitionsExpandItem.ts +24 -0
- package/src/generated/model/listFlowDefinitionsParams.ts +48 -23
- package/src/generated/model/listFlowDefinitionsPurpose.ts +9 -9
- package/src/generated/model/listFlowDefinitionsRevisions.ts +15 -0
- package/src/generated/model/listIdpRevisions200.ts +21 -0
- package/src/generated/model/listIdpRevisions200RevisionsItem.ts +38 -0
- package/src/generated/model/listIdpRevisions200RevisionsItemDefinition.ts +44 -0
- package/src/generated/model/listIdpRevisions200RevisionsItemDefinitionClaimMapping.ts +12 -0
- package/src/generated/model/listIdpRevisions200RevisionsItemDefinitionOidc.ts +65 -0
- package/src/generated/model/listIdpRevisions200RevisionsItemDefinitionOidcStaticAuthorizeParameters.ts +12 -0
- package/src/generated/model/listIdpRevisions200RevisionsItemDefinitionOidcTokenEndpointAuthMethod.ts +18 -0
- package/src/generated/model/listIdpRevisions200RevisionsItemDefinitionProtocol.ts +17 -0
- package/src/generated/model/listIdpRevisions200RevisionsItemDefinitionProvisioning.ts +15 -0
- package/src/generated/model/listIdpRevisions200RevisionsItemDefinitionProvisioningCreation.ts +15 -0
- package/src/generated/model/listIdpRevisions200RevisionsItemDefinitionVerifiedClaims.ts +12 -0
- package/src/generated/model/listIdpRevisions401.ts +20 -0
- package/src/generated/model/listIdpRevisions401Details.ts +12 -0
- package/src/generated/model/listIdpRevisions403.ts +20 -0
- package/src/generated/model/listIdpRevisions403Details.ts +12 -0
- package/src/generated/model/listIdpRevisions404.ts +20 -0
- package/src/generated/model/listIdpRevisions404Details.ts +12 -0
- package/src/generated/model/listIdpRevisionsDefault.ts +72 -0
- package/src/generated/model/listIdpRevisionsParams.ts +28 -0
- package/src/generated/model/listMyIdentityLinks200.ts +20 -0
- package/src/generated/model/listMyIdentityLinks200IdentityLinksItem.ts +22 -0
- package/src/generated/model/listMyIdentityLinks400.ts +20 -0
- package/src/generated/model/listMyIdentityLinks400Details.ts +12 -0
- package/src/generated/model/listMyIdentityLinks401.ts +23 -0
- package/src/generated/model/listMyIdentityLinks403.ts +23 -0
- package/src/generated/model/listMyIdentityLinksDefault.ts +72 -0
- package/src/generated/model/listMyIdentityLinksParams.ts +39 -0
- package/src/generated/model/listMyPasskeys200.ts +20 -0
- package/src/generated/model/listMyPasskeys200PasskeysItem.ts +16 -0
- package/src/generated/model/listMyPasskeys400.ts +20 -0
- package/src/generated/model/listMyPasskeys400Details.ts +12 -0
- package/src/generated/model/listMyPasskeys401.ts +23 -0
- package/src/generated/model/listMyPasskeys403.ts +23 -0
- package/src/generated/model/listMyPasskeysDefault.ts +72 -0
- package/src/generated/model/listMyPasskeysParams.ts +39 -0
- package/src/generated/model/listMyProjects200.ts +21 -0
- package/src/generated/model/listMyProjects200ProjectsItem.ts +34 -0
- package/src/generated/model/listMyProjects200ProjectsItemOriginsItem.ts +23 -0
- package/src/generated/model/listMyProjects200ProjectsItemOriginsItemKind.ts +15 -0
- package/src/generated/model/listMyProjects200ProjectsItemPasswordHash.ts +42 -0
- package/src/generated/model/listMyProjects200ProjectsItemPasswordHashAlgorithm.ts +24 -0
- package/src/generated/model/listMyProjects200ProjectsItemPasswordHashParams.ts +47 -0
- package/src/generated/model/listMyProjects200ProjectsItemPasswordHashParamsHash.ts +24 -0
- package/src/generated/model/listMyProjects400.ts +20 -0
- package/src/generated/model/listMyProjects400Details.ts +12 -0
- package/src/generated/model/listMyProjects401.ts +23 -0
- package/src/generated/model/listMyProjects403.ts +23 -0
- package/src/generated/model/listMyProjects500.ts +20 -0
- package/src/generated/model/listMyProjects500Details.ts +12 -0
- package/src/generated/model/listMyProjectsDefault.ts +63 -0
- package/src/generated/model/listMyProjectsParams.ts +47 -0
- package/src/generated/model/listMyTeams200.ts +20 -0
- package/src/generated/model/listMyTeams200TeamsItem.ts +33 -0
- package/src/generated/model/listMyTeams200TeamsItemMembershipStatus.ts +20 -0
- package/src/generated/model/listMyTeams400.ts +20 -0
- package/src/generated/model/listMyTeams400Details.ts +12 -0
- package/src/generated/model/listMyTeams401.ts +23 -0
- package/src/generated/model/listMyTeams403.ts +23 -0
- package/src/generated/model/listMyTeamsDefault.ts +72 -0
- package/src/generated/model/listMyTeamsParams.ts +39 -0
- package/src/generated/model/listPolicies200.ts +21 -0
- package/src/generated/model/listPolicies200PoliciesItem.ts +62 -0
- package/src/generated/model/listPoliciesDefault.ts +72 -0
- package/src/generated/model/listPoliciesOperation.ts +14 -0
- package/src/generated/model/listPoliciesParams.ts +33 -0
- package/src/generated/model/listPolicyRevisions200.ts +20 -0
- package/src/generated/model/listPolicyRevisions200RevisionsItem.ts +62 -0
- package/src/generated/model/listPolicyRevisionsDefault.ts +72 -0
- package/src/generated/model/listPolicyRevisionsParams.ts +28 -0
- package/src/generated/model/listPreviews200.ts +20 -0
- package/src/generated/model/listPreviews200PreviewsItem.ts +38 -0
- package/src/generated/model/listPreviewsDefault.ts +72 -0
- package/src/generated/model/listPreviewsParams.ts +23 -0
- package/src/generated/model/listProjectAdmins200.ts +20 -0
- package/src/generated/model/listProjectAdmins200AdminsItem.ts +31 -0
- package/src/generated/model/listProjectAdmins200AdminsItemSourcesItem.ts +57 -0
- package/src/generated/model/listProjectAdmins200AdminsItemUser.ts +40 -0
- package/src/generated/model/listProjectAdmins400.ts +20 -0
- package/src/generated/model/listProjectAdmins400Details.ts +12 -0
- package/src/generated/model/listProjectAdmins401.ts +20 -0
- package/src/generated/model/listProjectAdmins401Details.ts +12 -0
- package/src/generated/model/listProjectAdmins403.ts +20 -0
- package/src/generated/model/listProjectAdmins403Details.ts +12 -0
- package/src/generated/model/listProjectAdmins404.ts +20 -0
- package/src/generated/model/listProjectAdmins404Details.ts +12 -0
- package/src/generated/model/listProjectAdminsDefault.ts +81 -0
- package/src/generated/model/listProjectAdminsParams.ts +23 -0
- package/src/generated/model/listReleases200.ts +20 -0
- package/src/generated/model/listReleases200ReleasesItem.ts +72 -0
- package/src/generated/model/listReleases200ReleasesItemMetadata.ts +43 -0
- package/src/generated/model/listReleases200ReleasesItemMetadataCreatedByType.ts +20 -0
- package/src/generated/model/listReleasesDefault.ts +72 -0
- package/src/generated/model/listReleasesParams.ts +68 -0
- package/src/generated/model/listSchemas200.ts +20 -0
- package/src/generated/model/listSchemas200SchemasItem.ts +31 -0
- package/src/generated/model/listSchemas200SchemasItemMetadata.ts +12 -0
- package/src/generated/model/listSchemas200SchemasItemSchema.ts +83 -0
- package/src/generated/model/listSchemasDefault.ts +72 -0
- package/src/generated/model/listSchemasKind.ts +14 -0
- package/src/generated/model/listSchemasParams.ts +62 -0
- package/src/generated/model/listSchemasRevisions.ts +15 -0
- package/src/generated/model/listUserIdentityLinks200.ts +20 -0
- package/src/generated/model/listUserIdentityLinks200IdentityLinksItem.ts +22 -0
- package/src/generated/model/listUserIdentityLinks400.ts +20 -0
- package/src/generated/model/listUserIdentityLinks400Details.ts +12 -0
- package/src/generated/model/listUserIdentityLinks401.ts +20 -0
- package/src/generated/model/listUserIdentityLinks401Details.ts +12 -0
- package/src/generated/model/listUserIdentityLinks403.ts +20 -0
- package/src/generated/model/listUserIdentityLinks403Details.ts +12 -0
- package/src/generated/model/listUserIdentityLinks404.ts +20 -0
- package/src/generated/model/listUserIdentityLinks404Details.ts +12 -0
- package/src/generated/model/listUserIdentityLinks500.ts +20 -0
- package/src/generated/model/listUserIdentityLinks500Details.ts +12 -0
- package/src/generated/model/listUserIdentityLinksDefault.ts +72 -0
- package/src/generated/model/listUserIdentityLinksParams.ts +23 -0
- package/src/generated/model/listUserPasskeys200.ts +20 -0
- package/src/generated/model/listUserPasskeys200PasskeysItem.ts +16 -0
- package/src/generated/model/listUserPasskeys400.ts +20 -0
- package/src/generated/model/listUserPasskeys400Details.ts +12 -0
- package/src/generated/model/listUserPasskeys401.ts +20 -0
- package/src/generated/model/listUserPasskeys401Details.ts +12 -0
- package/src/generated/model/listUserPasskeys403.ts +20 -0
- package/src/generated/model/listUserPasskeys403Details.ts +12 -0
- package/src/generated/model/listUserPasskeys404.ts +20 -0
- package/src/generated/model/listUserPasskeys404Details.ts +12 -0
- package/src/generated/model/listUserPasskeys500.ts +20 -0
- package/src/generated/model/listUserPasskeys500Details.ts +12 -0
- package/src/generated/model/listUserPasskeysDefault.ts +72 -0
- package/src/generated/model/listUserPasskeysParams.ts +23 -0
- package/src/generated/model/listUserTeams200.ts +20 -0
- package/src/generated/model/listUserTeams200TeamsItem.ts +33 -0
- package/src/generated/model/listUserTeams200TeamsItemMembershipStatus.ts +20 -0
- package/src/generated/model/listUserTeams400.ts +20 -0
- package/src/generated/model/listUserTeams400Details.ts +12 -0
- package/src/generated/model/listUserTeams401.ts +20 -0
- package/src/generated/model/listUserTeams401Details.ts +12 -0
- package/src/generated/model/listUserTeams403.ts +20 -0
- package/src/generated/model/listUserTeams403Details.ts +12 -0
- package/src/generated/model/listUserTeams404.ts +20 -0
- package/src/generated/model/listUserTeams404Details.ts +12 -0
- package/src/generated/model/listUserTeams500.ts +20 -0
- package/src/generated/model/listUserTeams500Details.ts +12 -0
- package/src/generated/model/listUserTeamsDefault.ts +72 -0
- package/src/generated/model/listUserTeamsParams.ts +23 -0
- package/src/generated/model/patchMyUser200.ts +77 -0
- package/src/generated/model/patchMyUser200Attributes.ts +13 -0
- package/src/generated/model/patchMyUser200Metadata.ts +45 -0
- package/src/generated/model/patchMyUser200MetadataLifecycleOwnerTeam.ts +44 -0
- package/src/generated/model/patchMyUser200MetadataLifecycleOwnerTeamStatus.ts +21 -0
- package/src/generated/model/patchMyUser200MetadataStatus.ts +20 -0
- package/src/generated/model/patchMyUser200TeamsItem.ts +33 -0
- package/src/generated/model/patchMyUser200TeamsItemMembershipStatus.ts +20 -0
- package/src/generated/model/patchMyUser400.ts +20 -0
- package/src/generated/model/patchMyUser400Details.ts +12 -0
- package/src/generated/model/patchMyUser401.ts +20 -0
- package/src/generated/model/patchMyUser401Details.ts +12 -0
- package/src/generated/model/patchMyUser403.ts +20 -0
- package/src/generated/model/patchMyUser403Details.ts +12 -0
- package/src/generated/model/patchMyUser404.ts +23 -0
- package/src/generated/model/patchMyUser409.ts +20 -0
- package/src/generated/model/patchMyUser409Details.ts +12 -0
- package/src/generated/model/patchMyUserBody.ts +25 -0
- package/src/generated/model/patchMyUserBodyAttributes.ts +13 -0
- package/src/generated/model/patchMyUserDefault.ts +117 -0
- package/src/generated/model/patchMyUserParams.ts +26 -0
- package/src/generated/model/patchProject200.ts +92 -0
- package/src/generated/model/patchProject400.ts +20 -0
- package/src/generated/model/patchProject400Details.ts +12 -0
- package/src/generated/model/patchProject401.ts +20 -0
- package/src/generated/model/patchProject401Details.ts +12 -0
- package/src/generated/model/patchProject404.ts +20 -0
- package/src/generated/model/patchProject404Details.ts +12 -0
- package/src/generated/model/patchProjectBody.ts +19 -0
- package/src/generated/model/patchProjectBodyPasswordHash.ts +43 -0
- package/src/generated/model/patchProjectBodyPasswordHashAlgorithm.ts +24 -0
- package/src/generated/model/patchProjectBodyPasswordHashParams.ts +47 -0
- package/src/generated/model/patchProjectBodyPasswordHashParamsHash.ts +24 -0
- package/src/generated/model/patchProjectDefault.ts +117 -0
- package/src/generated/model/patchUserByID200.ts +77 -0
- package/src/generated/model/patchUserByID200Attributes.ts +13 -0
- package/src/generated/model/patchUserByID200Metadata.ts +45 -0
- package/src/generated/model/patchUserByID200MetadataLifecycleOwnerTeam.ts +44 -0
- package/src/generated/model/patchUserByID200MetadataLifecycleOwnerTeamStatus.ts +21 -0
- package/src/generated/model/patchUserByID200MetadataStatus.ts +20 -0
- package/src/generated/model/patchUserByID200TeamsItem.ts +33 -0
- package/src/generated/model/patchUserByID200TeamsItemMembershipStatus.ts +20 -0
- package/src/generated/model/patchUserByID400.ts +20 -0
- package/src/generated/model/patchUserByID400Details.ts +12 -0
- package/src/generated/model/patchUserByID401.ts +20 -0
- package/src/generated/model/patchUserByID401Details.ts +12 -0
- package/src/generated/model/patchUserByID403.ts +20 -0
- package/src/generated/model/patchUserByID403Details.ts +12 -0
- package/src/generated/model/patchUserByID404.ts +20 -0
- package/src/generated/model/patchUserByID404Details.ts +12 -0
- package/src/generated/model/patchUserByID409.ts +20 -0
- package/src/generated/model/patchUserByID409Details.ts +12 -0
- package/src/generated/model/patchUserByIDBody.ts +45 -0
- package/src/generated/model/patchUserByIDBodyAttributes.ts +13 -0
- package/src/generated/model/patchUserByIDDefault.ts +117 -0
- package/src/generated/model/publishPolicy201.ts +62 -0
- package/src/generated/model/publishPolicyBody.ts +47 -0
- package/src/generated/model/publishPolicyDefault.ts +99 -0
- package/src/generated/model/publishPolicyParams.ts +15 -0
- package/src/generated/model/queryGrants200.ts +21 -0
- package/src/generated/model/queryGrants200GrantsItem.ts +49 -0
- package/src/generated/model/queryGrants200GrantsItemObjectType.ts +17 -0
- package/src/generated/model/queryGrants200GrantsItemRelation.ts +19 -0
- package/src/generated/model/queryGrants200GrantsItemTeam.ts +36 -0
- package/src/generated/model/queryGrants200GrantsItemTeamStatus.ts +21 -0
- package/src/generated/model/queryGrants200GrantsItemUser.ts +52 -0
- package/src/generated/model/queryGrants200GrantsItemUserAttributes.ts +13 -0
- package/src/generated/model/queryGrants200GrantsItemUserMetadata.ts +45 -0
- package/src/generated/model/queryGrants200GrantsItemUserMetadataLifecycleOwnerTeam.ts +44 -0
- package/src/generated/model/queryGrants200GrantsItemUserMetadataLifecycleOwnerTeamStatus.ts +21 -0
- package/src/generated/model/queryGrants200GrantsItemUserMetadataStatus.ts +20 -0
- package/src/generated/model/queryGrants400.ts +20 -0
- package/src/generated/model/queryGrants400Details.ts +12 -0
- package/src/generated/model/queryGrants401.ts +20 -0
- package/src/generated/model/queryGrants401Details.ts +12 -0
- package/src/generated/model/queryGrants403.ts +20 -0
- package/src/generated/model/queryGrants403Details.ts +12 -0
- package/src/generated/model/queryGrantsBody.ts +36 -0
- package/src/generated/model/queryGrantsBodyExpandItem.ts +29 -0
- package/src/generated/model/queryGrantsBodyFilterItem.ts +36 -0
- package/src/generated/model/queryGrantsBodyFilterItemField.ts +26 -0
- package/src/generated/model/queryGrantsBodyFilterItemOperation.ts +29 -0
- package/src/generated/model/queryGrantsBodySorting.ts +18 -0
- package/src/generated/model/queryGrantsBodySortingDirection.ts +15 -0
- package/src/generated/model/queryGrantsBodySortingField.ts +20 -0
- package/src/generated/model/queryGrantsDefault.ts +108 -0
- package/src/generated/model/queryGrantsParams.ts +15 -0
- package/src/generated/model/queryIdps200.ts +21 -0
- package/src/generated/model/queryIdps200IdpsItem.ts +38 -0
- package/src/generated/model/queryIdps200IdpsItemDefinition.ts +44 -0
- package/src/generated/model/queryIdps200IdpsItemDefinitionClaimMapping.ts +12 -0
- package/src/generated/model/queryIdps200IdpsItemDefinitionOidc.ts +65 -0
- package/src/generated/model/queryIdps200IdpsItemDefinitionOidcStaticAuthorizeParameters.ts +12 -0
- package/src/generated/model/queryIdps200IdpsItemDefinitionOidcTokenEndpointAuthMethod.ts +18 -0
- package/src/generated/model/queryIdps200IdpsItemDefinitionProtocol.ts +17 -0
- package/src/generated/model/queryIdps200IdpsItemDefinitionProvisioning.ts +15 -0
- package/src/generated/model/queryIdps200IdpsItemDefinitionProvisioningCreation.ts +15 -0
- package/src/generated/model/queryIdps200IdpsItemDefinitionVerifiedClaims.ts +12 -0
- package/src/generated/model/queryIdps400.ts +20 -0
- package/src/generated/model/queryIdps400Details.ts +12 -0
- package/src/generated/model/queryIdps401.ts +20 -0
- package/src/generated/model/queryIdps401Details.ts +12 -0
- package/src/generated/model/queryIdps403.ts +20 -0
- package/src/generated/model/queryIdps403Details.ts +12 -0
- package/src/generated/model/queryIdps404.ts +20 -0
- package/src/generated/model/queryIdps404Details.ts +12 -0
- package/src/generated/model/queryIdpsBody.ts +30 -0
- package/src/generated/model/queryIdpsBodyFilterItem.ts +34 -0
- package/src/generated/model/queryIdpsBodyFilterItemField.ts +21 -0
- package/src/generated/model/queryIdpsBodyFilterItemOperation.ts +29 -0
- package/src/generated/model/queryIdpsBodySorting.ts +23 -0
- package/src/generated/model/queryIdpsBodySortingDirection.ts +15 -0
- package/src/generated/model/queryIdpsBodySortingField.ts +21 -0
- package/src/generated/model/queryIdpsDefault.ts +81 -0
- package/src/generated/model/queryIdpsParams.ts +15 -0
- package/src/generated/model/queryProjects200.ts +21 -0
- package/src/generated/model/queryProjects200ProjectsItem.ts +34 -0
- package/src/generated/model/queryProjects200ProjectsItemOriginsItem.ts +23 -0
- package/src/generated/model/queryProjects200ProjectsItemOriginsItemKind.ts +15 -0
- package/src/generated/model/queryProjects200ProjectsItemPasswordHash.ts +42 -0
- package/src/generated/model/queryProjects200ProjectsItemPasswordHashAlgorithm.ts +24 -0
- package/src/generated/model/queryProjects200ProjectsItemPasswordHashParams.ts +47 -0
- package/src/generated/model/queryProjects200ProjectsItemPasswordHashParamsHash.ts +24 -0
- package/src/generated/model/queryProjects400.ts +20 -0
- package/src/generated/model/queryProjects400Details.ts +12 -0
- package/src/generated/model/queryProjects401.ts +20 -0
- package/src/generated/model/queryProjects401Details.ts +12 -0
- package/src/generated/model/queryProjects403.ts +20 -0
- package/src/generated/model/queryProjects403Details.ts +12 -0
- package/src/generated/model/queryProjects429.ts +20 -0
- package/src/generated/model/queryProjects429Details.ts +12 -0
- package/src/generated/model/queryProjectsBody.ts +29 -0
- package/src/generated/model/queryProjectsBodyFilterItem.ts +28 -0
- package/src/generated/model/queryProjectsBodyFilterItemField.ts +14 -0
- package/src/generated/model/queryProjectsBodyFilterItemOperation.ts +29 -0
- package/src/generated/model/queryProjectsBodySorting.ts +14 -0
- package/src/generated/model/queryProjectsBodySortingDirection.ts +15 -0
- package/src/generated/model/queryProjectsBodySortingField.ts +14 -0
- package/src/generated/model/queryProjectsDefault.ts +81 -0
- package/src/generated/model/querySessions200.ts +20 -0
- package/src/generated/model/querySessions200SessionsItem.ts +76 -0
- package/src/generated/model/querySessions200SessionsItemFactorsItem.ts +28 -0
- package/src/generated/model/querySessions200SessionsItemFactorsItemMethod.ts +20 -0
- package/src/generated/model/querySessions200SessionsItemFactorsItemPayload.ts +37 -0
- package/src/generated/model/querySessions200SessionsItemMetadata.ts +12 -0
- package/src/generated/model/querySessions200SessionsItemState.ts +22 -0
- package/src/generated/model/querySessions200SessionsItemUser.ts +40 -0
- package/src/generated/model/querySessions200SessionsItemUserAgent.ts +18 -0
- package/src/generated/model/querySessions400.ts +20 -0
- package/src/generated/model/querySessions400Details.ts +12 -0
- package/src/generated/model/querySessions401.ts +20 -0
- package/src/generated/model/querySessions401Details.ts +12 -0
- package/src/generated/model/querySessions403.ts +20 -0
- package/src/generated/model/querySessions403Details.ts +12 -0
- package/src/generated/model/querySessionsBody.ts +25 -0
- package/src/generated/model/querySessionsBodyFilterItem.ts +43 -0
- package/src/generated/model/querySessionsBodyFilterItemField.ts +32 -0
- package/src/generated/model/querySessionsBodyFilterItemOperation.ts +29 -0
- package/src/generated/model/querySessionsBodySorting.ts +19 -0
- package/src/generated/model/querySessionsBodySortingDirection.ts +15 -0
- package/src/generated/model/querySessionsBodySortingField.ts +20 -0
- package/src/generated/model/querySessionsDefault.ts +81 -0
- package/src/generated/model/querySessionsParams.ts +15 -0
- package/src/generated/model/queryTeams200.ts +21 -0
- package/src/generated/model/queryTeams200TeamsItem.ts +29 -0
- package/src/generated/model/queryTeams200TeamsItemStatus.ts +21 -0
- package/src/generated/model/queryTeams400.ts +20 -0
- package/src/generated/model/queryTeams400Details.ts +12 -0
- package/src/generated/model/queryTeams401.ts +20 -0
- package/src/generated/model/queryTeams401Details.ts +12 -0
- package/src/generated/model/queryTeams403.ts +20 -0
- package/src/generated/model/queryTeams403Details.ts +12 -0
- package/src/generated/model/queryTeams404.ts +20 -0
- package/src/generated/model/queryTeams404Details.ts +12 -0
- package/src/generated/model/queryTeams429.ts +20 -0
- package/src/generated/model/queryTeams429Details.ts +12 -0
- package/src/generated/model/queryTeamsBody.ts +29 -0
- package/src/generated/model/queryTeamsBodyFilterItem.ts +34 -0
- package/src/generated/model/queryTeamsBodyFilterItemField.ts +22 -0
- package/src/generated/model/queryTeamsBodyFilterItemOperation.ts +29 -0
- package/src/generated/model/queryTeamsBodySorting.ts +20 -0
- package/src/generated/model/queryTeamsBodySortingDirection.ts +15 -0
- package/src/generated/model/queryTeamsBodySortingField.ts +22 -0
- package/src/generated/model/queryTeamsDefault.ts +90 -0
- package/src/generated/model/queryTeamsParams.ts +15 -0
- package/src/generated/model/queryUsers200.ts +20 -0
- package/src/generated/model/queryUsers200UsersItem.ts +77 -0
- package/src/generated/model/queryUsers200UsersItemAttributes.ts +13 -0
- package/src/generated/model/queryUsers200UsersItemMetadata.ts +45 -0
- package/src/generated/model/queryUsers200UsersItemMetadataLifecycleOwnerTeam.ts +44 -0
- package/src/generated/model/queryUsers200UsersItemMetadataLifecycleOwnerTeamStatus.ts +21 -0
- package/src/generated/model/queryUsers200UsersItemMetadataStatus.ts +20 -0
- package/src/generated/model/queryUsers200UsersItemTeamsItem.ts +33 -0
- package/src/generated/model/queryUsers200UsersItemTeamsItemMembershipStatus.ts +20 -0
- package/src/generated/model/queryUsers400.ts +20 -0
- package/src/generated/model/queryUsers400Details.ts +12 -0
- package/src/generated/model/queryUsers401.ts +20 -0
- package/src/generated/model/queryUsers401Details.ts +12 -0
- package/src/generated/model/queryUsers403.ts +20 -0
- package/src/generated/model/queryUsers403Details.ts +12 -0
- package/src/generated/model/queryUsersBody.ts +35 -0
- package/src/generated/model/queryUsersBodyExpandItem.ts +48 -0
- package/src/generated/model/queryUsersBodyFilterItem.ts +59 -0
- package/src/generated/model/queryUsersBodyFilterItemField.ts +50 -0
- package/src/generated/model/queryUsersBodyFilterItemOperation.ts +29 -0
- package/src/generated/model/queryUsersBodySorting.ts +22 -0
- package/src/generated/model/queryUsersBodySortingDirection.ts +15 -0
- package/src/generated/model/queryUsersBodySortingField.ts +26 -0
- package/src/generated/model/queryUsersDefault.ts +81 -0
- package/src/generated/model/queryUsersParams.ts +16 -0
- package/src/generated/model/removeOriginBody.ts +15 -0
- package/src/generated/model/removeOriginDefault.ts +108 -0
- package/src/generated/model/removePreviewBody.ts +23 -0
- package/src/generated/model/removePreviewDefault.ts +90 -0
- package/src/generated/model/revokeMySession401.ts +7 -4
- package/src/generated/model/revokeMySession403.ts +20 -0
- package/src/generated/model/revokeMySession403Details.ts +12 -0
- package/src/generated/model/revokeMySessionDefault.ts +76 -6
- package/src/generated/model/revokeMySessionParams.ts +26 -0
- package/src/generated/model/revokeRelease200.ts +96 -0
- package/src/generated/model/revokeRelease200Metadata.ts +43 -0
- package/src/generated/model/revokeRelease200MetadataCreatedByType.ts +20 -0
- package/src/generated/model/revokeRelease200PointersItem.ts +60 -0
- package/src/generated/model/revokeRelease200PointersItemKind.ts +28 -0
- package/src/generated/model/revokeRelease409.ts +19 -0
- package/src/generated/model/revokeRelease409Details.ts +16 -0
- package/src/generated/model/revokeRelease409DetailsOriginsItem.ts +25 -0
- package/src/generated/model/revokeReleaseDefault.ts +108 -0
- package/src/generated/model/revokeReleaseParams.ts +15 -0
- package/src/generated/model/revokeSession401.ts +2 -2
- package/src/generated/model/revokeSession401Details.ts +1 -1
- package/src/generated/model/revokeSession403.ts +20 -0
- package/src/generated/model/revokeSession403Details.ts +12 -0
- package/src/generated/model/revokeSessionDefault.ts +67 -6
- package/src/generated/model/rollbackDeployment200.ts +74 -0
- package/src/generated/model/rollbackDeployment200Kind.ts +18 -0
- package/src/generated/model/rollbackDeployment200Metadata.ts +35 -0
- package/src/generated/model/rollbackDeployment200MetadataDeployedByType.ts +20 -0
- package/src/generated/model/rollbackDeployment200MetadataReason.ts +20 -0
- package/src/generated/model/rollbackDeployment200Release.ts +96 -0
- package/src/generated/model/rollbackDeployment200ReleaseMetadata.ts +43 -0
- package/src/generated/model/rollbackDeployment200ReleaseMetadataCreatedByType.ts +20 -0
- package/src/generated/model/rollbackDeployment200ReleasePointersItem.ts +60 -0
- package/src/generated/model/rollbackDeployment200ReleasePointersItemKind.ts +28 -0
- package/src/generated/model/rollbackDeployment200Status.ts +22 -0
- package/src/generated/model/rollbackDeployment200TargetsItem.ts +28 -0
- package/src/generated/model/rollbackDeployment201.ts +74 -0
- package/src/generated/model/rollbackDeployment201Kind.ts +18 -0
- package/src/generated/model/rollbackDeployment201Metadata.ts +35 -0
- package/src/generated/model/rollbackDeployment201MetadataDeployedByType.ts +20 -0
- package/src/generated/model/rollbackDeployment201MetadataReason.ts +20 -0
- package/src/generated/model/rollbackDeployment201Release.ts +96 -0
- package/src/generated/model/rollbackDeployment201ReleaseMetadata.ts +43 -0
- package/src/generated/model/rollbackDeployment201ReleaseMetadataCreatedByType.ts +20 -0
- package/src/generated/model/rollbackDeployment201ReleasePointersItem.ts +60 -0
- package/src/generated/model/rollbackDeployment201ReleasePointersItemKind.ts +28 -0
- package/src/generated/model/rollbackDeployment201Status.ts +22 -0
- package/src/generated/model/rollbackDeployment201TargetsItem.ts +28 -0
- package/src/generated/model/rollbackDeployment400.ts +20 -0
- package/src/generated/model/rollbackDeployment400Details.ts +12 -0
- package/src/generated/model/rollbackDeployment409.ts +259 -0
- package/src/generated/model/rollbackDeploymentBody.ts +25 -0
- package/src/generated/model/rollbackDeploymentDefault.ts +171 -0
- package/src/generated/model/rollbackDeploymentParams.ts +15 -0
- package/src/generated/model/setUserPassword400.ts +2 -2
- package/src/generated/model/setUserPassword400Details.ts +1 -1
- package/src/generated/model/setUserPassword404.ts +2 -2
- package/src/generated/model/setUserPassword404Details.ts +1 -1
- package/src/generated/model/setUserPassword500.ts +2 -2
- package/src/generated/model/setUserPassword500Details.ts +1 -1
- package/src/generated/model/setUserPasswordBody.ts +1 -5
- package/src/generated/model/setUserPasswordDefault.ts +112 -6
- package/src/generated/model/submitFlowStep200.ts +34 -23
- package/src/generated/model/submitFlowStep200Branding.ts +63 -18
- package/src/generated/model/submitFlowStep200BrandingLayout.ts +14 -9
- package/src/generated/model/submitFlowStep200BrandingShape.ts +30 -0
- package/src/generated/model/submitFlowStep200BrandingShapeDensity.ts +19 -0
- package/src/generated/model/submitFlowStep200BrandingTheme.ts +43 -0
- package/src/generated/model/submitFlowStep200BrandingThemeDark.ts +34 -0
- package/src/generated/model/submitFlowStep200BrandingThemeDarkPalette.ts +209 -0
- package/src/generated/model/submitFlowStep200BrandingThemeLight.ts +34 -0
- package/src/generated/model/submitFlowStep200BrandingThemeLightPalette.ts +209 -0
- package/src/generated/model/submitFlowStep200BrandingThemeMode.ts +19 -0
- package/src/generated/model/submitFlowStep200BrandingTypography.ts +47 -0
- package/src/generated/model/submitFlowStep200Step.ts +112 -40
- package/src/generated/model/submitFlowStep200StepActionsItem.ts +27 -14
- package/src/generated/model/submitFlowStep200StepActionsItemKind.ts +27 -0
- package/src/generated/model/submitFlowStep200StepChallenge.ts +19 -18
- package/src/generated/model/submitFlowStep200StepChallengeMethod.ts +5 -4
- package/src/generated/model/submitFlowStep200StepChallengeOptions.ts +4 -5
- package/src/generated/model/submitFlowStep200StepComplete.ts +7 -8
- package/src/generated/model/submitFlowStep200StepFieldsItem.ts +63 -26
- package/src/generated/model/submitFlowStep200StepFieldsItemType.ts +17 -18
- package/src/generated/model/submitFlowStep200StepFieldsItemValidation.ts +28 -27
- package/src/generated/model/submitFlowStep200StepFieldsItemValidationFormat.ts +11 -12
- package/src/generated/model/submitFlowStep200StepGates.ts +24 -24
- package/src/generated/model/submitFlowStep200StepGatesConfig.ts +2 -3
- package/src/generated/model/submitFlowStep200StepGatesKind.ts +6 -7
- package/src/generated/model/submitFlowStep200StepIdentifier.ts +58 -0
- package/src/generated/model/submitFlowStep200StepPurpose.ts +26 -0
- package/src/generated/model/submitFlowStep200StepSsoProvidersItem.ts +1 -1
- package/src/generated/model/submitFlowStep200StepTexts.ts +8 -4
- package/src/generated/model/submitFlowStep400.ts +34 -23
- package/src/generated/model/submitFlowStep400Branding.ts +63 -18
- package/src/generated/model/submitFlowStep400BrandingLayout.ts +14 -9
- package/src/generated/model/submitFlowStep400BrandingShape.ts +30 -0
- package/src/generated/model/submitFlowStep400BrandingShapeDensity.ts +19 -0
- package/src/generated/model/submitFlowStep400BrandingTheme.ts +43 -0
- package/src/generated/model/submitFlowStep400BrandingThemeDark.ts +34 -0
- package/src/generated/model/submitFlowStep400BrandingThemeDarkPalette.ts +209 -0
- package/src/generated/model/submitFlowStep400BrandingThemeLight.ts +34 -0
- package/src/generated/model/submitFlowStep400BrandingThemeLightPalette.ts +209 -0
- package/src/generated/model/submitFlowStep400BrandingThemeMode.ts +19 -0
- package/src/generated/model/submitFlowStep400BrandingTypography.ts +47 -0
- package/src/generated/model/submitFlowStep400Step.ts +112 -40
- package/src/generated/model/submitFlowStep400StepActionsItem.ts +27 -14
- package/src/generated/model/submitFlowStep400StepActionsItemKind.ts +27 -0
- package/src/generated/model/submitFlowStep400StepChallenge.ts +19 -18
- package/src/generated/model/submitFlowStep400StepChallengeMethod.ts +5 -4
- package/src/generated/model/submitFlowStep400StepChallengeOptions.ts +4 -5
- package/src/generated/model/submitFlowStep400StepComplete.ts +7 -8
- package/src/generated/model/submitFlowStep400StepFieldsItem.ts +63 -26
- package/src/generated/model/submitFlowStep400StepFieldsItemType.ts +17 -18
- package/src/generated/model/submitFlowStep400StepFieldsItemValidation.ts +28 -27
- package/src/generated/model/submitFlowStep400StepFieldsItemValidationFormat.ts +11 -12
- package/src/generated/model/submitFlowStep400StepGates.ts +24 -24
- package/src/generated/model/submitFlowStep400StepGatesConfig.ts +2 -3
- package/src/generated/model/submitFlowStep400StepGatesKind.ts +6 -7
- package/src/generated/model/submitFlowStep400StepIdentifier.ts +58 -0
- package/src/generated/model/submitFlowStep400StepPurpose.ts +26 -0
- package/src/generated/model/submitFlowStep400StepSsoProvidersItem.ts +1 -1
- package/src/generated/model/submitFlowStep400StepTexts.ts +8 -4
- package/src/generated/model/submitFlowStep409.ts +2 -2
- package/src/generated/model/submitFlowStep409Details.ts +1 -1
- package/src/generated/model/submitFlowStepBody.ts +40 -20
- package/src/generated/model/submitFlowStepBodyChallengeResponse.ts +12 -11
- package/src/generated/model/submitFlowStepBodyChallengeResponseProof.ts +2 -3
- package/src/generated/model/submitFlowStepBodyFields.ts +1 -2
- package/src/generated/model/submitFlowStepBodyGateProofs.ts +3 -4
- package/src/generated/model/submitFlowStepDefault.ts +346 -6
- package/src/generated/model/updateTeam200.ts +29 -0
- package/src/generated/model/updateTeam200Status.ts +21 -0
- package/src/generated/model/updateTeam400.ts +20 -0
- package/src/generated/model/updateTeam400Details.ts +12 -0
- package/src/generated/model/updateTeam401.ts +20 -0
- package/src/generated/model/updateTeam401Details.ts +12 -0
- package/src/generated/model/updateTeam403.ts +20 -0
- package/src/generated/model/updateTeam403Details.ts +12 -0
- package/src/generated/model/updateTeam404.ts +20 -0
- package/src/generated/model/updateTeam404Details.ts +12 -0
- package/src/generated/model/updateTeam409.ts +20 -0
- package/src/generated/model/updateTeam409Details.ts +12 -0
- package/src/generated/model/updateTeamBody.ts +16 -0
- package/src/generated/model/updateTeamDefault.ts +117 -0
- package/src/generated/model/updateVariables200.ts +35 -0
- package/src/generated/model/updateVariables200Preview.ts +20 -0
- package/src/generated/model/updateVariables200Primary.ts +20 -0
- package/src/generated/model/updateVariablesBody.ts +48 -0
- package/src/generated/model/updateVariablesDefault.ts +162 -0
- package/src/generated/model/updateVariablesKind.ts +15 -0
- package/src/generated/model/updateVariablesParams.ts +21 -0
- package/src/generated/model/userProperty.ts +39 -0
- package/src/generated/model/userPropertyProperties.ts +14 -0
- package/src/generated/model/userPropertyXUnique.ts +19 -0
- package/src/generated/model/verifyChallengeProof200.ts +49 -44
- package/src/generated/model/verifyChallengeProof200ChallengesItem.ts +26 -22
- package/src/generated/model/verifyChallengeProof200ChallengesItemMethod.ts +8 -7
- package/src/generated/model/verifyChallengeProof200ChallengesItemPayload.ts +24 -26
- package/src/generated/model/verifyChallengeProof200ChallengesItemState.ts +9 -10
- package/src/generated/model/verifyChallengeProof200CompletedFactorsItem.ts +11 -10
- package/src/generated/model/verifyChallengeProof200CompletedFactorsItemMethod.ts +7 -6
- package/src/generated/model/verifyChallengeProof200CompletedFactorsItemPayload.ts +27 -23
- package/src/generated/model/verifyChallengeProof200RequiredFactorsItem.ts +7 -6
- package/src/generated/model/verifyChallengeProof200State.ts +11 -12
- package/src/generated/model/verifyChallengeProof409.ts +20 -0
- package/src/generated/model/verifyChallengeProof409Details.ts +12 -0
- package/src/generated/model/verifyChallengeProofBody.ts +17 -21
- package/src/generated/model/verifyChallengeProofDefault.ts +173 -72
- package/src/generated/operations.ts +2264 -0
- package/src/runtime/api-factory.ts +18 -2
- package/src/runtime/auth.ts +95 -0
- package/src/runtime/base-url.spec.ts +33 -2
- package/src/runtime/config.spec.ts +35 -7
- package/src/runtime/config.ts +22 -3
- package/src/runtime/fetch.spec.ts +370 -0
- package/src/runtime/fetch.ts +252 -8
- package/dist/index-BGnjxx-b.d.mts +0 -9578
- package/dist/index-BGnjxx-b.d.mts.map +0 -1
- package/dist/runtime/fetch.d.mts.map +0 -1
- package/dist/zitadelNextGen-BS4VE7_Y.d.mts +0 -408
- package/dist/zitadelNextGen-BS4VE7_Y.d.mts.map +0 -1
- package/src/generated/model/authorizeDevice200.ts +0 -30
- package/src/generated/model/authorizeDevice400.ts +0 -20
- package/src/generated/model/authorizeDevice400Details.ts +0 -12
- package/src/generated/model/authorizeDeviceDefault.ts +0 -20
- package/src/generated/model/authorizeDeviceDefaultDetails.ts +0 -12
- package/src/generated/model/authorizeDeviceParams.ts +0 -25
- package/src/generated/model/authorizeGet400.ts +0 -20
- package/src/generated/model/authorizeGet400Details.ts +0 -12
- package/src/generated/model/authorizeGetDefault.ts +0 -20
- package/src/generated/model/authorizeGetDefaultDetails.ts +0 -12
- package/src/generated/model/authorizeGetParams.ts +0 -136
- package/src/generated/model/createFlowDefaultDetails.ts +0 -12
- package/src/generated/model/createFlowDefinition201FlowDefinitionStepsItemSsoProvidersItem.ts +0 -19
- package/src/generated/model/createFlowDefinition409.ts +0 -20
- package/src/generated/model/createFlowDefinition409Details.ts +0 -12
- package/src/generated/model/createFlowDefinitionBodyFlowDefinitionStepsItemSsoProvidersItem.ts +0 -19
- package/src/generated/model/createFlowDefinitionDefaultDetails.ts +0 -12
- package/src/generated/model/createProjectDefaultDetails.ts +0 -12
- package/src/generated/model/createSchema400.ts +0 -20
- package/src/generated/model/createSchema400Details.ts +0 -12
- package/src/generated/model/createSchema409.ts +0 -20
- package/src/generated/model/createSchema409Details.ts +0 -12
- package/src/generated/model/createSchemaDefaultDetails.ts +0 -12
- package/src/generated/model/createSessionDefaultDetails.ts +0 -12
- package/src/generated/model/createTeamDefaultDetails.ts +0 -12
- package/src/generated/model/createUserDefaultDetails.ts +0 -12
- package/src/generated/model/deleteFlowDefinitionDefault.ts +0 -20
- package/src/generated/model/deleteFlowDefinitionDefaultDetails.ts +0 -12
- package/src/generated/model/deleteFlowDefinitionParams.ts +0 -15
- package/src/generated/model/endSession400.ts +0 -20
- package/src/generated/model/endSession400Details.ts +0 -12
- package/src/generated/model/endSessionDefault.ts +0 -20
- package/src/generated/model/endSessionDefaultDetails.ts +0 -12
- package/src/generated/model/endSessionParams.ts +0 -57
- package/src/generated/model/exchangeHandoff410.ts +0 -20
- package/src/generated/model/exchangeHandoff410Details.ts +0 -12
- package/src/generated/model/exchangeHandoffDefaultDetails.ts +0 -12
- package/src/generated/model/getFlowDefinition200FlowDefinitionStepsItemSsoProvidersItem.ts +0 -19
- package/src/generated/model/getFlowDefinitionDefaultDetails.ts +0 -12
- package/src/generated/model/getFlowDefinitionParams.ts +0 -15
- package/src/generated/model/getFlowStepDefaultDetails.ts +0 -12
- package/src/generated/model/getHealth4xx.ts +0 -20
- package/src/generated/model/getHealth4xxDetails.ts +0 -12
- package/src/generated/model/getHealthDefault.ts +0 -20
- package/src/generated/model/getHealthDefaultDetails.ts +0 -12
- package/src/generated/model/getKeys200.ts +0 -12
- package/src/generated/model/getKeys200KeysItem.ts +0 -30
- package/src/generated/model/getKeys4xx.ts +0 -20
- package/src/generated/model/getKeys4xxDetails.ts +0 -12
- package/src/generated/model/getKeysDefault.ts +0 -20
- package/src/generated/model/getKeysDefaultDetails.ts +0 -12
- package/src/generated/model/getLiveDefaultDetails.ts +0 -12
- package/src/generated/model/getMySession401Details.ts +0 -12
- package/src/generated/model/getMySession404Details.ts +0 -12
- package/src/generated/model/getMySessionDefaultDetails.ts +0 -12
- package/src/generated/model/getMyUserDefaultDetails.ts +0 -12
- package/src/generated/model/getOpenIDConfiguration200.ts +0 -87
- package/src/generated/model/getOpenIDConfiguration200ClaimTypesSupportedItem.ts +0 -16
- package/src/generated/model/getOpenIDConfiguration200DisplayValuesSupportedItem.ts +0 -17
- package/src/generated/model/getOpenIDConfiguration200SubjectTypesSupportedItem.ts +0 -15
- package/src/generated/model/getOpenIDConfiguration200TokenEndpointAuthMethodsSupportedItem.ts +0 -17
- package/src/generated/model/getOpenIDConfiguration4xx.ts +0 -20
- package/src/generated/model/getOpenIDConfiguration4xxDetails.ts +0 -12
- package/src/generated/model/getOpenIDConfigurationDefault.ts +0 -20
- package/src/generated/model/getOpenIDConfigurationDefaultDetails.ts +0 -12
- package/src/generated/model/getProjectDefaultDetails.ts +0 -12
- package/src/generated/model/getReadyDefaultDetails.ts +0 -12
- package/src/generated/model/getSchemaById400.ts +0 -20
- package/src/generated/model/getSchemaById400Details.ts +0 -12
- package/src/generated/model/getSchemaById404.ts +0 -20
- package/src/generated/model/getSchemaById404Details.ts +0 -12
- package/src/generated/model/getSchemaByIdDefaultDetails.ts +0 -12
- package/src/generated/model/getSessionDefaultDetails.ts +0 -12
- package/src/generated/model/getSessionParams.ts +0 -15
- package/src/generated/model/getTeamDefaultDetails.ts +0 -12
- package/src/generated/model/getTeamParams.ts +0 -15
- package/src/generated/model/getToken200.ts +0 -18
- package/src/generated/model/getToken4xx.ts +0 -20
- package/src/generated/model/getToken4xxDetails.ts +0 -12
- package/src/generated/model/getTokenBody.ts +0 -40
- package/src/generated/model/getTokenBodyGrantType.ts +0 -20
- package/src/generated/model/getTokenDefault.ts +0 -20
- package/src/generated/model/getTokenDefaultDetails.ts +0 -12
- package/src/generated/model/getUserByIDDefaultDetails.ts +0 -12
- package/src/generated/model/getUserInfo200.ts +0 -24
- package/src/generated/model/getUserInfo4xx.ts +0 -20
- package/src/generated/model/getUserInfo4xxDetails.ts +0 -12
- package/src/generated/model/getUserInfoDefault.ts +0 -20
- package/src/generated/model/getUserInfoDefaultDetails.ts +0 -12
- package/src/generated/model/introspect200.ts +0 -34
- package/src/generated/model/introspect400.ts +0 -20
- package/src/generated/model/introspect400Details.ts +0 -12
- package/src/generated/model/introspectBody.ts +0 -14
- package/src/generated/model/introspectDefault.ts +0 -20
- package/src/generated/model/introspectDefaultDetails.ts +0 -12
- package/src/generated/model/listFlowDefinitionsDefaultDetails.ts +0 -12
- package/src/generated/model/listSessions200.ts +0 -19
- package/src/generated/model/listSessions200SessionsItem.ts +0 -63
- package/src/generated/model/listSessions200SessionsItemFactorsItem.ts +0 -27
- package/src/generated/model/listSessions200SessionsItemFactorsItemMethod.ts +0 -19
- package/src/generated/model/listSessions200SessionsItemFactorsItemPayload.ts +0 -33
- package/src/generated/model/listSessions200SessionsItemMetadata.ts +0 -12
- package/src/generated/model/listSessions200SessionsItemState.ts +0 -25
- package/src/generated/model/listSessions200SessionsItemUserAgent.ts +0 -18
- package/src/generated/model/listSessions400.ts +0 -20
- package/src/generated/model/listSessions400Details.ts +0 -12
- package/src/generated/model/listSessions401.ts +0 -20
- package/src/generated/model/listSessions401Details.ts +0 -12
- package/src/generated/model/listSessions403.ts +0 -20
- package/src/generated/model/listSessions403Details.ts +0 -12
- package/src/generated/model/listSessionsDefault.ts +0 -20
- package/src/generated/model/listSessionsDefaultDetails.ts +0 -12
- package/src/generated/model/listSessionsParams.ts +0 -39
- package/src/generated/model/listSessionsState.ts +0 -16
- package/src/generated/model/listUsers200Item.ts +0 -9
- package/src/generated/model/listUsers400.ts +0 -20
- package/src/generated/model/listUsers400Details.ts +0 -12
- package/src/generated/model/listUsers500.ts +0 -20
- package/src/generated/model/listUsers500Details.ts +0 -12
- package/src/generated/model/listUsersDefault.ts +0 -20
- package/src/generated/model/listUsersDefaultDetails.ts +0 -12
- package/src/generated/model/listUsersParams.ts +0 -21
- package/src/generated/model/revokeMySession401Details.ts +0 -12
- package/src/generated/model/revokeMySession404.ts +0 -20
- package/src/generated/model/revokeMySession404Details.ts +0 -12
- package/src/generated/model/revokeMySession409.ts +0 -20
- package/src/generated/model/revokeMySession409Details.ts +0 -12
- package/src/generated/model/revokeMySessionDefaultDetails.ts +0 -12
- package/src/generated/model/revokeSession404.ts +0 -20
- package/src/generated/model/revokeSession404Details.ts +0 -12
- package/src/generated/model/revokeSession409.ts +0 -20
- package/src/generated/model/revokeSession409Details.ts +0 -12
- package/src/generated/model/revokeSessionDefaultDetails.ts +0 -12
- package/src/generated/model/revokeSessionParams.ts +0 -15
- package/src/generated/model/revokeToken4xx.ts +0 -20
- package/src/generated/model/revokeToken4xxDetails.ts +0 -12
- package/src/generated/model/revokeTokenBody.ts +0 -14
- package/src/generated/model/revokeTokenDefault.ts +0 -20
- package/src/generated/model/revokeTokenDefaultDetails.ts +0 -12
- package/src/generated/model/setUserPasswordDefaultDetails.ts +0 -12
- package/src/generated/model/setUserPasswordParams.ts +0 -15
- package/src/generated/model/submitFlowEvent400.ts +0 -20
- package/src/generated/model/submitFlowEvent400Details.ts +0 -12
- package/src/generated/model/submitFlowEvent404.ts +0 -20
- package/src/generated/model/submitFlowEvent404Details.ts +0 -12
- package/src/generated/model/submitFlowEventBody.ts +0 -17
- package/src/generated/model/submitFlowEventBodyPayload.ts +0 -12
- package/src/generated/model/submitFlowEventBodyType.ts +0 -15
- package/src/generated/model/submitFlowEventDefault.ts +0 -20
- package/src/generated/model/submitFlowEventDefaultDetails.ts +0 -12
- package/src/generated/model/submitFlowStepDefaultDetails.ts +0 -12
- package/src/generated/model/updateFlowDefinition200.ts +0 -29
- package/src/generated/model/updateFlowDefinition200FlowDefinition.ts +0 -58
- package/src/generated/model/updateFlowDefinition200FlowDefinitionAudience.ts +0 -21
- package/src/generated/model/updateFlowDefinition200FlowDefinitionStepsItem.ts +0 -71
- package/src/generated/model/updateFlowDefinition200FlowDefinitionStepsItemActionsItem.ts +0 -28
- package/src/generated/model/updateFlowDefinition200FlowDefinitionStepsItemComplete.ts +0 -21
- package/src/generated/model/updateFlowDefinition200FlowDefinitionStepsItemGates.ts +0 -35
- package/src/generated/model/updateFlowDefinition200FlowDefinitionStepsItemGatesConfig.ts +0 -14
- package/src/generated/model/updateFlowDefinition200FlowDefinitionStepsItemGatesKind.ts +0 -20
- package/src/generated/model/updateFlowDefinition200FlowDefinitionStepsItemOnSuccess.ts +0 -21
- package/src/generated/model/updateFlowDefinition200FlowDefinitionStepsItemSsoProvidersItem.ts +0 -19
- package/src/generated/model/updateFlowDefinition200FlowDefinitionStepsItemTransitions.ts +0 -35
- package/src/generated/model/updateFlowDefinition400.ts +0 -20
- package/src/generated/model/updateFlowDefinition400Details.ts +0 -12
- package/src/generated/model/updateFlowDefinition404.ts +0 -20
- package/src/generated/model/updateFlowDefinition404Details.ts +0 -12
- package/src/generated/model/updateFlowDefinitionBody.ts +0 -45
- package/src/generated/model/updateFlowDefinitionBodyAudience.ts +0 -21
- package/src/generated/model/updateFlowDefinitionBodyStepsItem.ts +0 -71
- package/src/generated/model/updateFlowDefinitionBodyStepsItemActionsItem.ts +0 -28
- package/src/generated/model/updateFlowDefinitionBodyStepsItemComplete.ts +0 -21
- package/src/generated/model/updateFlowDefinitionBodyStepsItemGates.ts +0 -35
- package/src/generated/model/updateFlowDefinitionBodyStepsItemGatesConfig.ts +0 -14
- package/src/generated/model/updateFlowDefinitionBodyStepsItemGatesKind.ts +0 -20
- package/src/generated/model/updateFlowDefinitionBodyStepsItemOnSuccess.ts +0 -21
- package/src/generated/model/updateFlowDefinitionBodyStepsItemSsoProvidersItem.ts +0 -19
- package/src/generated/model/updateFlowDefinitionBodyStepsItemTransitions.ts +0 -35
- package/src/generated/model/updateFlowDefinitionDefault.ts +0 -20
- package/src/generated/model/updateFlowDefinitionDefaultDetails.ts +0 -12
- package/src/generated/model/updateFlowDefinitionParams.ts +0 -15
- /package/dist/{chunk-CfYAbeIz.mjs → rolldown-runtime-D7D4PA-g.mjs} +0 -0
|
@@ -1,383 +1,751 @@
|
|
|
1
|
-
import { t as __exportAll } from "../../
|
|
1
|
+
import { t as __exportAll } from "../../rolldown-runtime-D7D4PA-g.mjs";
|
|
2
2
|
import { getProxyPath } from "../../runtime/base-url.mjs";
|
|
3
3
|
import { customFetch } from "../../runtime/fetch.mjs";
|
|
4
4
|
//#region src/generated/endpoints/zitadelNextGen.ts
|
|
5
5
|
/**
|
|
6
|
-
* Generated by orval
|
|
6
|
+
* Generated by orval 🍺
|
|
7
7
|
* Do not edit manually.
|
|
8
8
|
* Zitadel NextGen
|
|
9
9
|
* This is the next generation of the Zitadel identity platform.
|
|
10
10
|
* OpenAPI spec version: 0.0.1
|
|
11
11
|
*/
|
|
12
12
|
var zitadelNextGen_exports = /* @__PURE__ */ __exportAll({
|
|
13
|
-
|
|
14
|
-
|
|
13
|
+
addOrigin: () => addOrigin,
|
|
14
|
+
beginUserPasskeyRegistration: () => beginUserPasskeyRegistration,
|
|
15
|
+
buildRelease: () => buildRelease,
|
|
16
|
+
completeClaim: () => completeClaim,
|
|
15
17
|
createAuthAttempt: () => createAuthAttempt,
|
|
18
|
+
createBranding: () => createBranding,
|
|
19
|
+
createDeployment: () => createDeployment,
|
|
16
20
|
createFlow: () => createFlow,
|
|
17
21
|
createFlowDefinition: () => createFlowDefinition,
|
|
22
|
+
createGrant: () => createGrant,
|
|
18
23
|
createHandoff: () => createHandoff,
|
|
24
|
+
createIdp: () => createIdp,
|
|
19
25
|
createProject: () => createProject,
|
|
26
|
+
createRelease: () => createRelease,
|
|
20
27
|
createSchema: () => createSchema,
|
|
21
28
|
createSession: () => createSession,
|
|
22
29
|
createTeam: () => createTeam,
|
|
23
30
|
createUser: () => createUser,
|
|
24
|
-
|
|
25
|
-
|
|
31
|
+
deleteGrant: () => deleteGrant,
|
|
32
|
+
deleteTeam: () => deleteTeam,
|
|
33
|
+
deleteUserByID: () => deleteUserByID,
|
|
34
|
+
deleteVariable: () => deleteVariable,
|
|
26
35
|
exchangeHandoff: () => exchangeHandoff,
|
|
36
|
+
finishUserPasskeyRegistration: () => finishUserPasskeyRegistration,
|
|
37
|
+
getAddOriginUrl: () => getAddOriginUrl,
|
|
27
38
|
getAuthAttempt: () => getAuthAttempt,
|
|
28
|
-
|
|
29
|
-
|
|
39
|
+
getBeginUserPasskeyRegistrationUrl: () => getBeginUserPasskeyRegistrationUrl,
|
|
40
|
+
getBrandingById: () => getBrandingById,
|
|
41
|
+
getBuildReleaseUrl: () => getBuildReleaseUrl,
|
|
42
|
+
getClaimStatus: () => getClaimStatus,
|
|
43
|
+
getClaimWindow: () => getClaimWindow,
|
|
44
|
+
getCompleteClaimUrl: () => getCompleteClaimUrl,
|
|
30
45
|
getCreateAuthAttemptUrl: () => getCreateAuthAttemptUrl,
|
|
46
|
+
getCreateBrandingUrl: () => getCreateBrandingUrl,
|
|
47
|
+
getCreateDeploymentUrl: () => getCreateDeploymentUrl,
|
|
31
48
|
getCreateFlowDefinitionUrl: () => getCreateFlowDefinitionUrl,
|
|
32
49
|
getCreateFlowUrl: () => getCreateFlowUrl,
|
|
50
|
+
getCreateGrantUrl: () => getCreateGrantUrl,
|
|
33
51
|
getCreateHandoffUrl: () => getCreateHandoffUrl,
|
|
52
|
+
getCreateIdpUrl: () => getCreateIdpUrl,
|
|
34
53
|
getCreateProjectUrl: () => getCreateProjectUrl,
|
|
54
|
+
getCreateReleaseUrl: () => getCreateReleaseUrl,
|
|
35
55
|
getCreateSchemaUrl: () => getCreateSchemaUrl,
|
|
36
56
|
getCreateSessionUrl: () => getCreateSessionUrl,
|
|
37
57
|
getCreateTeamUrl: () => getCreateTeamUrl,
|
|
38
58
|
getCreateUserUrl: () => getCreateUserUrl,
|
|
39
|
-
|
|
40
|
-
|
|
59
|
+
getDeleteGrantUrl: () => getDeleteGrantUrl,
|
|
60
|
+
getDeleteTeamUrl: () => getDeleteTeamUrl,
|
|
61
|
+
getDeleteUserByIDUrl: () => getDeleteUserByIDUrl,
|
|
62
|
+
getDeleteVariableUrl: () => getDeleteVariableUrl,
|
|
63
|
+
getDeploymentById: () => getDeploymentById,
|
|
64
|
+
getDeploymentVariables: () => getDeploymentVariables,
|
|
65
|
+
getEvent: () => getEvent,
|
|
41
66
|
getExchangeHandoffUrl: () => getExchangeHandoffUrl,
|
|
67
|
+
getFinishUserPasskeyRegistrationUrl: () => getFinishUserPasskeyRegistrationUrl,
|
|
42
68
|
getFlowDefinition: () => getFlowDefinition,
|
|
43
69
|
getFlowStep: () => getFlowStep,
|
|
44
70
|
getGetAuthAttemptUrl: () => getGetAuthAttemptUrl,
|
|
71
|
+
getGetBrandingByIdUrl: () => getGetBrandingByIdUrl,
|
|
72
|
+
getGetClaimStatusUrl: () => getGetClaimStatusUrl,
|
|
73
|
+
getGetClaimWindowUrl: () => getGetClaimWindowUrl,
|
|
74
|
+
getGetDeploymentByIdUrl: () => getGetDeploymentByIdUrl,
|
|
75
|
+
getGetDeploymentVariablesUrl: () => getGetDeploymentVariablesUrl,
|
|
76
|
+
getGetEventUrl: () => getGetEventUrl,
|
|
45
77
|
getGetFlowDefinitionUrl: () => getGetFlowDefinitionUrl,
|
|
46
78
|
getGetFlowStepUrl: () => getGetFlowStepUrl,
|
|
47
|
-
|
|
48
|
-
|
|
79
|
+
getGetGrantUrl: () => getGetGrantUrl,
|
|
80
|
+
getGetIdpByIdUrl: () => getGetIdpByIdUrl,
|
|
81
|
+
getGetIdpRevisionByIdUrl: () => getGetIdpRevisionByIdUrl,
|
|
49
82
|
getGetLiveUrl: () => getGetLiveUrl,
|
|
83
|
+
getGetMyPasswordStateUrl: () => getGetMyPasswordStateUrl,
|
|
84
|
+
getGetMySessionCsrfTokenUrl: () => getGetMySessionCsrfTokenUrl,
|
|
50
85
|
getGetMySessionUrl: () => getGetMySessionUrl,
|
|
86
|
+
getGetMyUserSchemaUrl: () => getGetMyUserSchemaUrl,
|
|
51
87
|
getGetMyUserUrl: () => getGetMyUserUrl,
|
|
52
|
-
|
|
88
|
+
getGetPolicyRevisionUrl: () => getGetPolicyRevisionUrl,
|
|
89
|
+
getGetPolicyUrl: () => getGetPolicyUrl,
|
|
53
90
|
getGetProjectUrl: () => getGetProjectUrl,
|
|
54
91
|
getGetReadyUrl: () => getGetReadyUrl,
|
|
92
|
+
getGetReleaseByIdUrl: () => getGetReleaseByIdUrl,
|
|
55
93
|
getGetSchemaByIdUrl: () => getGetSchemaByIdUrl,
|
|
56
94
|
getGetSessionUrl: () => getGetSessionUrl,
|
|
57
95
|
getGetTeamUrl: () => getGetTeamUrl,
|
|
58
|
-
getGetTokenUrl: () => getGetTokenUrl,
|
|
59
96
|
getGetUserByIDUrl: () => getGetUserByIDUrl,
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
97
|
+
getGetUserPasswordStateUrl: () => getGetUserPasswordStateUrl,
|
|
98
|
+
getGetVariableUrl: () => getGetVariableUrl,
|
|
99
|
+
getGetVariablesUrl: () => getGetVariablesUrl,
|
|
100
|
+
getGrant: () => getGrant,
|
|
101
|
+
getIdpById: () => getIdpById,
|
|
102
|
+
getIdpRevisionById: () => getIdpRevisionById,
|
|
103
|
+
getInitClaimUrl: () => getInitClaimUrl,
|
|
63
104
|
getIssueChallengeUrl: () => getIssueChallengeUrl,
|
|
64
|
-
|
|
105
|
+
getListBrandingUrl: () => getListBrandingUrl,
|
|
106
|
+
getListDeploymentsUrl: () => getListDeploymentsUrl,
|
|
107
|
+
getListEventsUrl: () => getListEventsUrl,
|
|
65
108
|
getListFlowDefinitionsUrl: () => getListFlowDefinitionsUrl,
|
|
66
|
-
|
|
67
|
-
|
|
109
|
+
getListIdpRevisionsUrl: () => getListIdpRevisionsUrl,
|
|
110
|
+
getListMyIdentityLinksUrl: () => getListMyIdentityLinksUrl,
|
|
111
|
+
getListMyPasskeysUrl: () => getListMyPasskeysUrl,
|
|
112
|
+
getListMyProjectsUrl: () => getListMyProjectsUrl,
|
|
113
|
+
getListMyTeamsUrl: () => getListMyTeamsUrl,
|
|
114
|
+
getListPoliciesUrl: () => getListPoliciesUrl,
|
|
115
|
+
getListPolicyRevisionsUrl: () => getListPolicyRevisionsUrl,
|
|
116
|
+
getListPreviewsUrl: () => getListPreviewsUrl,
|
|
117
|
+
getListProjectAdminsUrl: () => getListProjectAdminsUrl,
|
|
118
|
+
getListReleasesUrl: () => getListReleasesUrl,
|
|
119
|
+
getListSchemasUrl: () => getListSchemasUrl,
|
|
120
|
+
getListUserIdentityLinksUrl: () => getListUserIdentityLinksUrl,
|
|
121
|
+
getListUserPasskeysUrl: () => getListUserPasskeysUrl,
|
|
122
|
+
getListUserTeamsUrl: () => getListUserTeamsUrl,
|
|
68
123
|
getLive: () => getLive,
|
|
124
|
+
getMyPasswordState: () => getMyPasswordState,
|
|
69
125
|
getMySession: () => getMySession,
|
|
126
|
+
getMySessionCsrfToken: () => getMySessionCsrfToken,
|
|
70
127
|
getMyUser: () => getMyUser,
|
|
71
|
-
|
|
128
|
+
getMyUserSchema: () => getMyUserSchema,
|
|
129
|
+
getPatchMyUserUrl: () => getPatchMyUserUrl,
|
|
130
|
+
getPatchProjectUrl: () => getPatchProjectUrl,
|
|
131
|
+
getPatchUserByIDUrl: () => getPatchUserByIDUrl,
|
|
132
|
+
getPolicy: () => getPolicy,
|
|
133
|
+
getPolicyRevision: () => getPolicyRevision,
|
|
72
134
|
getProject: () => getProject,
|
|
135
|
+
getPublishPolicyUrl: () => getPublishPolicyUrl,
|
|
136
|
+
getQueryGrantsUrl: () => getQueryGrantsUrl,
|
|
137
|
+
getQueryIdpsUrl: () => getQueryIdpsUrl,
|
|
138
|
+
getQueryProjectsUrl: () => getQueryProjectsUrl,
|
|
139
|
+
getQuerySessionsUrl: () => getQuerySessionsUrl,
|
|
140
|
+
getQueryTeamsUrl: () => getQueryTeamsUrl,
|
|
141
|
+
getQueryUsersUrl: () => getQueryUsersUrl,
|
|
73
142
|
getReady: () => getReady,
|
|
143
|
+
getReleaseById: () => getReleaseById,
|
|
144
|
+
getRemoveOriginUrl: () => getRemoveOriginUrl,
|
|
145
|
+
getRemovePreviewUrl: () => getRemovePreviewUrl,
|
|
74
146
|
getRevokeMySessionUrl: () => getRevokeMySessionUrl,
|
|
147
|
+
getRevokeReleaseUrl: () => getRevokeReleaseUrl,
|
|
75
148
|
getRevokeSessionUrl: () => getRevokeSessionUrl,
|
|
76
|
-
|
|
149
|
+
getRollbackDeploymentUrl: () => getRollbackDeploymentUrl,
|
|
77
150
|
getSchemaById: () => getSchemaById,
|
|
78
151
|
getSession: () => getSession,
|
|
79
152
|
getSetUserPasswordUrl: () => getSetUserPasswordUrl,
|
|
80
|
-
getSubmitFlowEventUrl: () => getSubmitFlowEventUrl,
|
|
81
153
|
getSubmitFlowStepUrl: () => getSubmitFlowStepUrl,
|
|
82
154
|
getTeam: () => getTeam,
|
|
83
|
-
|
|
84
|
-
|
|
155
|
+
getUpdateTeamUrl: () => getUpdateTeamUrl,
|
|
156
|
+
getUpdateVariablesUrl: () => getUpdateVariablesUrl,
|
|
85
157
|
getUserByID: () => getUserByID,
|
|
86
|
-
|
|
158
|
+
getUserPasswordState: () => getUserPasswordState,
|
|
159
|
+
getVariable: () => getVariable,
|
|
160
|
+
getVariables: () => getVariables,
|
|
87
161
|
getVerifyChallengeProofUrl: () => getVerifyChallengeProofUrl,
|
|
88
|
-
|
|
162
|
+
initClaim: () => initClaim,
|
|
89
163
|
issueChallenge: () => issueChallenge,
|
|
164
|
+
listBranding: () => listBranding,
|
|
165
|
+
listDeployments: () => listDeployments,
|
|
166
|
+
listEvents: () => listEvents,
|
|
90
167
|
listFlowDefinitions: () => listFlowDefinitions,
|
|
91
|
-
|
|
92
|
-
|
|
168
|
+
listIdpRevisions: () => listIdpRevisions,
|
|
169
|
+
listMyIdentityLinks: () => listMyIdentityLinks,
|
|
170
|
+
listMyPasskeys: () => listMyPasskeys,
|
|
171
|
+
listMyProjects: () => listMyProjects,
|
|
172
|
+
listMyTeams: () => listMyTeams,
|
|
173
|
+
listPolicies: () => listPolicies,
|
|
174
|
+
listPolicyRevisions: () => listPolicyRevisions,
|
|
175
|
+
listPreviews: () => listPreviews,
|
|
176
|
+
listProjectAdmins: () => listProjectAdmins,
|
|
177
|
+
listReleases: () => listReleases,
|
|
178
|
+
listSchemas: () => listSchemas,
|
|
179
|
+
listUserIdentityLinks: () => listUserIdentityLinks,
|
|
180
|
+
listUserPasskeys: () => listUserPasskeys,
|
|
181
|
+
listUserTeams: () => listUserTeams,
|
|
182
|
+
patchMyUser: () => patchMyUser,
|
|
183
|
+
patchProject: () => patchProject,
|
|
184
|
+
patchUserByID: () => patchUserByID,
|
|
185
|
+
publishPolicy: () => publishPolicy,
|
|
186
|
+
queryGrants: () => queryGrants,
|
|
187
|
+
queryIdps: () => queryIdps,
|
|
188
|
+
queryProjects: () => queryProjects,
|
|
189
|
+
querySessions: () => querySessions,
|
|
190
|
+
queryTeams: () => queryTeams,
|
|
191
|
+
queryUsers: () => queryUsers,
|
|
192
|
+
removeOrigin: () => removeOrigin,
|
|
193
|
+
removePreview: () => removePreview,
|
|
93
194
|
revokeMySession: () => revokeMySession,
|
|
195
|
+
revokeRelease: () => revokeRelease,
|
|
94
196
|
revokeSession: () => revokeSession,
|
|
95
|
-
|
|
197
|
+
rollbackDeployment: () => rollbackDeployment,
|
|
96
198
|
setUserPassword: () => setUserPassword,
|
|
97
|
-
submitFlowEvent: () => submitFlowEvent,
|
|
98
199
|
submitFlowStep: () => submitFlowStep,
|
|
99
|
-
|
|
200
|
+
updateTeam: () => updateTeam,
|
|
201
|
+
updateVariables: () => updateVariables,
|
|
100
202
|
verifyChallengeProof: () => verifyChallengeProof
|
|
101
203
|
});
|
|
102
|
-
const
|
|
103
|
-
return `${getProxyPath()}
|
|
204
|
+
const getGetLiveUrl = () => {
|
|
205
|
+
return `${getProxyPath()}/livez`;
|
|
206
|
+
};
|
|
207
|
+
/**
|
|
208
|
+
* Answers `ok` while the server process serves HTTP, and checks nothing behind it.
|
|
209
|
+
*
|
|
210
|
+
* Point a liveness probe here. It never checks the database, so an outage
|
|
211
|
+
* of the database does not restart every instance; `GET /readyz` takes an
|
|
212
|
+
* instance out of rotation instead.
|
|
213
|
+
* @summary Check server liveness
|
|
214
|
+
*/
|
|
215
|
+
const getLive = async (options) => {
|
|
216
|
+
return customFetch(getGetLiveUrl(), {
|
|
217
|
+
...options,
|
|
218
|
+
method: "GET"
|
|
219
|
+
});
|
|
220
|
+
};
|
|
221
|
+
const getGetReadyUrl = () => {
|
|
222
|
+
return `${getProxyPath()}/readyz`;
|
|
104
223
|
};
|
|
105
224
|
/**
|
|
106
|
-
*
|
|
107
|
-
*
|
|
225
|
+
* Answers whether the server can serve requests, which takes its database answering within a second.
|
|
226
|
+
*
|
|
227
|
+
* Point a readiness probe here, so that a server whose database does not
|
|
228
|
+
* answer gets no requests until it does. The check is one round trip to the
|
|
229
|
+
* database.
|
|
230
|
+
* @summary Check server readiness
|
|
108
231
|
*/
|
|
109
|
-
const
|
|
110
|
-
return customFetch(
|
|
232
|
+
const getReady = async (options) => {
|
|
233
|
+
return customFetch(getGetReadyUrl(), {
|
|
111
234
|
...options,
|
|
112
235
|
method: "GET"
|
|
113
236
|
});
|
|
114
237
|
};
|
|
115
|
-
const
|
|
238
|
+
const getCreateUserUrl = (params) => {
|
|
116
239
|
const normalizedParams = new URLSearchParams();
|
|
117
240
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
118
|
-
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : value
|
|
241
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
119
242
|
});
|
|
120
243
|
const stringifiedParams = normalizedParams.toString();
|
|
121
|
-
return stringifiedParams.length > 0 ? `${getProxyPath()}/
|
|
244
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/users?${stringifiedParams}` : `${getProxyPath()}/users`;
|
|
122
245
|
};
|
|
123
246
|
/**
|
|
124
|
-
*
|
|
247
|
+
* Creates a user whose attributes satisfy the user schema the request names.
|
|
248
|
+
*
|
|
249
|
+
* The server assigns the user's id. With `team_id`, the user also becomes an
|
|
250
|
+
* active member of that team. A value the schema marks unique that another
|
|
251
|
+
* user already holds is refused with `409`.
|
|
252
|
+
* @summary Create user
|
|
125
253
|
*/
|
|
126
|
-
const
|
|
127
|
-
|
|
254
|
+
const createUser = async (createUserBody, params, options) => {
|
|
255
|
+
const getHeaders = (h) => {
|
|
256
|
+
if (!h) return {};
|
|
257
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
258
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
259
|
+
const headers = {};
|
|
260
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
261
|
+
return headers;
|
|
262
|
+
};
|
|
263
|
+
return customFetch(getCreateUserUrl(params), {
|
|
128
264
|
...options,
|
|
129
|
-
method: "
|
|
265
|
+
method: "POST",
|
|
266
|
+
headers: {
|
|
267
|
+
"Content-Type": "application/json",
|
|
268
|
+
...getHeaders(options?.headers)
|
|
269
|
+
},
|
|
270
|
+
body: JSON.stringify(createUserBody)
|
|
130
271
|
});
|
|
131
272
|
};
|
|
132
|
-
const
|
|
273
|
+
const getQueryUsersUrl = (params) => {
|
|
133
274
|
const normalizedParams = new URLSearchParams();
|
|
134
275
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
135
|
-
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : value
|
|
276
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
136
277
|
});
|
|
137
278
|
const stringifiedParams = normalizedParams.toString();
|
|
138
|
-
return stringifiedParams.length > 0 ? `${getProxyPath()}/
|
|
279
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/users/query?${stringifiedParams}` : `${getProxyPath()}/users/query`;
|
|
139
280
|
};
|
|
140
281
|
/**
|
|
141
|
-
*
|
|
282
|
+
* Returns the users of a project, paginated with a cursor.
|
|
283
|
+
*
|
|
284
|
+
* `project_id` names the project to list; without it, the credential's own
|
|
285
|
+
* project is listed.
|
|
286
|
+
*
|
|
287
|
+
* Accepts either a project secret (`oauth2`) or a user-bound Console
|
|
288
|
+
* session cookie (`nextgenSession`). Cookie-authenticated requests
|
|
289
|
+
* follow the scheme's CSRF rules (`nextgenSession`).
|
|
290
|
+
* @summary Query users
|
|
142
291
|
*/
|
|
143
|
-
const
|
|
144
|
-
|
|
292
|
+
const queryUsers = async (queryUsersBody, params, options) => {
|
|
293
|
+
const getHeaders = (h) => {
|
|
294
|
+
if (!h) return {};
|
|
295
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
296
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
297
|
+
const headers = {};
|
|
298
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
299
|
+
return headers;
|
|
300
|
+
};
|
|
301
|
+
return customFetch(getQueryUsersUrl(params), {
|
|
145
302
|
...options,
|
|
146
|
-
method: "
|
|
303
|
+
method: "POST",
|
|
304
|
+
headers: {
|
|
305
|
+
"Content-Type": "application/json",
|
|
306
|
+
...getHeaders(options?.headers)
|
|
307
|
+
},
|
|
308
|
+
body: JSON.stringify(queryUsersBody)
|
|
147
309
|
});
|
|
148
310
|
};
|
|
149
|
-
const
|
|
311
|
+
const getGetUserByIDUrl = (userId, params) => {
|
|
150
312
|
const normalizedParams = new URLSearchParams();
|
|
151
313
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
152
|
-
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : value
|
|
314
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
153
315
|
});
|
|
154
316
|
const stringifiedParams = normalizedParams.toString();
|
|
155
|
-
return stringifiedParams.length > 0 ? `${getProxyPath()}/
|
|
317
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/users/${encodeURIComponent(String(userId))}?${stringifiedParams}` : `${getProxyPath()}/users/${encodeURIComponent(String(userId))}`;
|
|
156
318
|
};
|
|
157
319
|
/**
|
|
158
|
-
*
|
|
320
|
+
* Returns a user by its id, with the attributes its schema defines.
|
|
321
|
+
*
|
|
322
|
+
* With `team_id`, the user is returned only while they are an active member of
|
|
323
|
+
* that team.
|
|
324
|
+
* @summary Get user by ID
|
|
159
325
|
*/
|
|
160
|
-
const
|
|
161
|
-
return customFetch(
|
|
326
|
+
const getUserByID = async (userId, params, options) => {
|
|
327
|
+
return customFetch(getGetUserByIDUrl(userId, params), {
|
|
162
328
|
...options,
|
|
163
329
|
method: "GET"
|
|
164
330
|
});
|
|
165
331
|
};
|
|
166
|
-
const
|
|
167
|
-
return `${getProxyPath()}/
|
|
332
|
+
const getPatchUserByIDUrl = (userId) => {
|
|
333
|
+
return `${getProxyPath()}/users/${encodeURIComponent(String(userId))}`;
|
|
168
334
|
};
|
|
169
335
|
/**
|
|
170
|
-
*
|
|
336
|
+
* Partially updates a user's schema-defined attributes, and optionally
|
|
337
|
+
* moves the user to another registered schema. The merged result is
|
|
338
|
+
* validated against the schema before commit. Concurrent writes are
|
|
339
|
+
* last-write-wins.
|
|
340
|
+
* @summary Update user by ID
|
|
171
341
|
*/
|
|
172
|
-
const
|
|
173
|
-
const
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
342
|
+
const patchUserByID = async (userId, patchUserByIDBody, options) => {
|
|
343
|
+
const getHeaders = (h) => {
|
|
344
|
+
if (!h) return {};
|
|
345
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
346
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
347
|
+
const headers = {};
|
|
348
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
349
|
+
return headers;
|
|
350
|
+
};
|
|
351
|
+
return customFetch(getPatchUserByIDUrl(userId), {
|
|
177
352
|
...options,
|
|
178
|
-
method: "
|
|
353
|
+
method: "PATCH",
|
|
179
354
|
headers: {
|
|
180
|
-
"Content-Type": "application/
|
|
181
|
-
...options?.headers
|
|
355
|
+
"Content-Type": "application/json",
|
|
356
|
+
...getHeaders(options?.headers)
|
|
182
357
|
},
|
|
183
|
-
body:
|
|
358
|
+
body: JSON.stringify(patchUserByIDBody)
|
|
359
|
+
});
|
|
360
|
+
};
|
|
361
|
+
const getDeleteUserByIDUrl = (userId) => {
|
|
362
|
+
return `${getProxyPath()}/users/${encodeURIComponent(String(userId))}`;
|
|
363
|
+
};
|
|
364
|
+
/**
|
|
365
|
+
* Deletes a user and removes them from every team they belong to.
|
|
366
|
+
*
|
|
367
|
+
* The user is removed, not deactivated, and the deletion emits `user.deleted`.
|
|
368
|
+
* With a project secret the request is idempotent: deleting a user that exists
|
|
369
|
+
* in no project succeeds without changing anything.
|
|
370
|
+
* @summary Delete user by ID
|
|
371
|
+
*/
|
|
372
|
+
const deleteUserByID = async (userId, options) => {
|
|
373
|
+
return customFetch(getDeleteUserByIDUrl(userId), {
|
|
374
|
+
...options,
|
|
375
|
+
method: "DELETE"
|
|
376
|
+
});
|
|
377
|
+
};
|
|
378
|
+
const getListUserIdentityLinksUrl = (userId, params) => {
|
|
379
|
+
const normalizedParams = new URLSearchParams();
|
|
380
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
381
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
382
|
+
});
|
|
383
|
+
const stringifiedParams = normalizedParams.toString();
|
|
384
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/users/${encodeURIComponent(String(userId))}/identity_links?${stringifiedParams}` : `${getProxyPath()}/users/${encodeURIComponent(String(userId))}/identity_links`;
|
|
385
|
+
};
|
|
386
|
+
/**
|
|
387
|
+
* The identity provider accounts a sign-in linked to the user, oldest first.
|
|
388
|
+
* The provider's subject and claims are never returned.
|
|
389
|
+
* @summary List the provider accounts linked to a user
|
|
390
|
+
*/
|
|
391
|
+
const listUserIdentityLinks = async (userId, params, options) => {
|
|
392
|
+
return customFetch(getListUserIdentityLinksUrl(userId, params), {
|
|
393
|
+
...options,
|
|
394
|
+
method: "GET"
|
|
184
395
|
});
|
|
185
396
|
};
|
|
186
|
-
const
|
|
187
|
-
|
|
397
|
+
const getListUserPasskeysUrl = (userId, params) => {
|
|
398
|
+
const normalizedParams = new URLSearchParams();
|
|
399
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
400
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
401
|
+
});
|
|
402
|
+
const stringifiedParams = normalizedParams.toString();
|
|
403
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/users/${encodeURIComponent(String(userId))}/passkeys?${stringifiedParams}` : `${getProxyPath()}/users/${encodeURIComponent(String(userId))}/passkeys`;
|
|
188
404
|
};
|
|
189
405
|
/**
|
|
190
|
-
*
|
|
406
|
+
* Returns the passkeys registered for a user, newest first, paginated with a
|
|
407
|
+
* cursor.
|
|
408
|
+
*
|
|
409
|
+
* Each passkey carries its id, its name and when it was registered, never the
|
|
410
|
+
* credential itself.
|
|
411
|
+
* @summary List user passkeys
|
|
191
412
|
*/
|
|
192
|
-
const
|
|
193
|
-
return customFetch(
|
|
413
|
+
const listUserPasskeys = async (userId, params, options) => {
|
|
414
|
+
return customFetch(getListUserPasskeysUrl(userId, params), {
|
|
194
415
|
...options,
|
|
195
416
|
method: "GET"
|
|
196
417
|
});
|
|
197
418
|
};
|
|
198
|
-
const
|
|
199
|
-
return `${getProxyPath()}/
|
|
419
|
+
const getBeginUserPasskeyRegistrationUrl = (userId) => {
|
|
420
|
+
return `${getProxyPath()}/users/${encodeURIComponent(String(userId))}/passkeys/registrations`;
|
|
200
421
|
};
|
|
201
422
|
/**
|
|
202
|
-
*
|
|
423
|
+
* Starts a WebAuthn registration ceremony for the user and returns the
|
|
424
|
+
* creation options for `navigator.credentials.create()`. Complete the
|
|
425
|
+
* ceremony with `POST /users/{user_id}/passkeys/registrations/{registration_id}` within
|
|
426
|
+
* five minutes. Credentials already registered for the user are excluded
|
|
427
|
+
* automatically.
|
|
428
|
+
* @summary Begin passkey registration
|
|
203
429
|
*/
|
|
204
|
-
const
|
|
205
|
-
const
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
430
|
+
const beginUserPasskeyRegistration = async (userId, beginUserPasskeyRegistrationBody, options) => {
|
|
431
|
+
const getHeaders = (h) => {
|
|
432
|
+
if (!h) return {};
|
|
433
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
434
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
435
|
+
const headers = {};
|
|
436
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
437
|
+
return headers;
|
|
438
|
+
};
|
|
439
|
+
return customFetch(getBeginUserPasskeyRegistrationUrl(userId), {
|
|
209
440
|
...options,
|
|
210
441
|
method: "POST",
|
|
211
442
|
headers: {
|
|
212
|
-
"Content-Type": "application/
|
|
213
|
-
...options?.headers
|
|
443
|
+
"Content-Type": "application/json",
|
|
444
|
+
...getHeaders(options?.headers)
|
|
214
445
|
},
|
|
215
|
-
body:
|
|
446
|
+
body: JSON.stringify(beginUserPasskeyRegistrationBody)
|
|
216
447
|
});
|
|
217
448
|
};
|
|
218
|
-
const
|
|
219
|
-
return `${getProxyPath()}/
|
|
449
|
+
const getFinishUserPasskeyRegistrationUrl = (userId, registrationId) => {
|
|
450
|
+
return `${getProxyPath()}/users/${encodeURIComponent(String(userId))}/passkeys/registrations/${encodeURIComponent(String(registrationId))}`;
|
|
220
451
|
};
|
|
221
452
|
/**
|
|
222
|
-
*
|
|
453
|
+
* Verifies the attestation against the ceremony started by
|
|
454
|
+
* `POST /users/{user_id}/passkeys/registrations` and persists the new credential. A
|
|
455
|
+
* rejected attestation counts against the ceremony's failure budget and the
|
|
456
|
+
* ceremony stays open for a retry. An expired ceremony surfaces as
|
|
457
|
+
* `att.stale_challenge`; an unknown or already-consumed registration id
|
|
458
|
+
* surfaces as `att.not_found`.
|
|
459
|
+
* @summary Finish passkey registration
|
|
223
460
|
*/
|
|
224
|
-
const
|
|
225
|
-
const
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
return customFetch(getGetTokenUrl(), {
|
|
461
|
+
const finishUserPasskeyRegistration = async (userId, registrationId, finishUserPasskeyRegistrationBody, options) => {
|
|
462
|
+
const getHeaders = (h) => {
|
|
463
|
+
if (!h) return {};
|
|
464
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
465
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
466
|
+
const headers = {};
|
|
467
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
468
|
+
return headers;
|
|
469
|
+
};
|
|
470
|
+
return customFetch(getFinishUserPasskeyRegistrationUrl(userId, registrationId), {
|
|
235
471
|
...options,
|
|
236
472
|
method: "POST",
|
|
237
473
|
headers: {
|
|
238
|
-
"Content-Type": "application/
|
|
239
|
-
...options?.headers
|
|
474
|
+
"Content-Type": "application/json",
|
|
475
|
+
...getHeaders(options?.headers)
|
|
240
476
|
},
|
|
241
|
-
body:
|
|
477
|
+
body: JSON.stringify(finishUserPasskeyRegistrationBody)
|
|
242
478
|
});
|
|
243
479
|
};
|
|
244
|
-
const
|
|
245
|
-
return `${getProxyPath()}/
|
|
480
|
+
const getGetUserPasswordStateUrl = (userId) => {
|
|
481
|
+
return `${getProxyPath()}/users/${encodeURIComponent(String(userId))}/password`;
|
|
246
482
|
};
|
|
247
483
|
/**
|
|
248
|
-
*
|
|
484
|
+
* Reports when the user's current password was set, and leaves `set_at` out
|
|
485
|
+
* when the user has none. The password and its hash are never returned;
|
|
486
|
+
* setting one is `PUT` on the same path.
|
|
487
|
+
* @summary Get user password state
|
|
249
488
|
*/
|
|
250
|
-
const
|
|
251
|
-
return customFetch(
|
|
489
|
+
const getUserPasswordState = async (userId, options) => {
|
|
490
|
+
return customFetch(getGetUserPasswordStateUrl(userId), {
|
|
252
491
|
...options,
|
|
253
492
|
method: "GET"
|
|
254
493
|
});
|
|
255
494
|
};
|
|
256
|
-
const
|
|
257
|
-
return `${getProxyPath()}/
|
|
495
|
+
const getSetUserPasswordUrl = (userId) => {
|
|
496
|
+
return `${getProxyPath()}/users/${encodeURIComponent(String(userId))}/password`;
|
|
258
497
|
};
|
|
259
498
|
/**
|
|
260
|
-
*
|
|
261
|
-
*
|
|
499
|
+
* Sets a user's password, hashed with the project's current password hashing
|
|
500
|
+
* policy.
|
|
501
|
+
*
|
|
502
|
+
* The new password replaces the current one, and setting it emits
|
|
503
|
+
* `auth.factor.password.set`.
|
|
504
|
+
* @summary Set user password
|
|
262
505
|
*/
|
|
263
|
-
const
|
|
264
|
-
|
|
506
|
+
const setUserPassword = async (userId, setUserPasswordBody, options) => {
|
|
507
|
+
const getHeaders = (h) => {
|
|
508
|
+
if (!h) return {};
|
|
509
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
510
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
511
|
+
const headers = {};
|
|
512
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
513
|
+
return headers;
|
|
514
|
+
};
|
|
515
|
+
return customFetch(getSetUserPasswordUrl(userId), {
|
|
265
516
|
...options,
|
|
266
|
-
method: "
|
|
517
|
+
method: "PUT",
|
|
518
|
+
headers: {
|
|
519
|
+
"Content-Type": "application/json",
|
|
520
|
+
...getHeaders(options?.headers)
|
|
521
|
+
},
|
|
522
|
+
body: JSON.stringify(setUserPasswordBody)
|
|
267
523
|
});
|
|
268
524
|
};
|
|
269
|
-
const
|
|
270
|
-
|
|
525
|
+
const getListUserTeamsUrl = (userId, params) => {
|
|
526
|
+
const normalizedParams = new URLSearchParams();
|
|
527
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
528
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
529
|
+
});
|
|
530
|
+
const stringifiedParams = normalizedParams.toString();
|
|
531
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/users/${encodeURIComponent(String(userId))}/teams?${stringifiedParams}` : `${getProxyPath()}/users/${encodeURIComponent(String(userId))}/teams`;
|
|
271
532
|
};
|
|
272
533
|
/**
|
|
273
|
-
*
|
|
274
|
-
*
|
|
534
|
+
* The user's team roster, ordered by team name. Each entry carries the
|
|
535
|
+
* team's name, so a client renders a page without resolving ids one by one.
|
|
536
|
+
*
|
|
537
|
+
* This is the N:N roster and it is not lifecycle ownership: the single team
|
|
538
|
+
* that owns the user's lifecycle is reported as `metadata.lifecycle_owner_team_id`
|
|
539
|
+
* on the user read endpoints. Memberships the user was removed from are not
|
|
540
|
+
* returned.
|
|
541
|
+
* @summary List the teams a user belongs to
|
|
275
542
|
*/
|
|
276
|
-
const
|
|
277
|
-
return customFetch(
|
|
543
|
+
const listUserTeams = async (userId, params, options) => {
|
|
544
|
+
return customFetch(getListUserTeamsUrl(userId, params), {
|
|
278
545
|
...options,
|
|
279
546
|
method: "GET"
|
|
280
547
|
});
|
|
281
548
|
};
|
|
282
|
-
const
|
|
283
|
-
|
|
549
|
+
const getGetMyUserUrl = (params) => {
|
|
550
|
+
const normalizedParams = new URLSearchParams();
|
|
551
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
552
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
553
|
+
});
|
|
554
|
+
const stringifiedParams = normalizedParams.toString();
|
|
555
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/users/me?${stringifiedParams}` : `${getProxyPath()}/users/me`;
|
|
284
556
|
};
|
|
285
557
|
/**
|
|
286
|
-
*
|
|
287
|
-
*
|
|
558
|
+
* Returns the user signed in to the session that authenticates the request.
|
|
559
|
+
*
|
|
560
|
+
* The project and the user both come from the session cookie, so a caller only
|
|
561
|
+
* ever reads their own user.
|
|
562
|
+
*
|
|
563
|
+
* With `project_id`, the user is returned only when the session belongs to
|
|
564
|
+
* that project.
|
|
565
|
+
* @summary Get my user information
|
|
288
566
|
*/
|
|
289
|
-
const
|
|
290
|
-
return customFetch(
|
|
567
|
+
const getMyUser = async (params, options) => {
|
|
568
|
+
return customFetch(getGetMyUserUrl(params), {
|
|
291
569
|
...options,
|
|
292
570
|
method: "GET"
|
|
293
571
|
});
|
|
294
572
|
};
|
|
295
|
-
const
|
|
573
|
+
const getPatchMyUserUrl = (params) => {
|
|
296
574
|
const normalizedParams = new URLSearchParams();
|
|
297
575
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
298
|
-
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : value
|
|
576
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
299
577
|
});
|
|
300
578
|
const stringifiedParams = normalizedParams.toString();
|
|
301
|
-
return stringifiedParams.length > 0 ? `${getProxyPath()}/users?${stringifiedParams}` : `${getProxyPath()}/users`;
|
|
579
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/users/me?${stringifiedParams}` : `${getProxyPath()}/users/me`;
|
|
302
580
|
};
|
|
303
581
|
/**
|
|
304
|
-
*
|
|
582
|
+
* Partially updates the caller's own schema-defined attributes. The merged
|
|
583
|
+
* result is validated against the user's schema before commit. Concurrent
|
|
584
|
+
* writes are last-write-wins.
|
|
585
|
+
*
|
|
586
|
+
* With `project_id`, the user is updated only when the session belongs to
|
|
587
|
+
* that project.
|
|
588
|
+
* @summary Update my user information
|
|
305
589
|
*/
|
|
306
|
-
const
|
|
307
|
-
|
|
590
|
+
const patchMyUser = async (patchMyUserBody, params, options) => {
|
|
591
|
+
const getHeaders = (h) => {
|
|
592
|
+
if (!h) return {};
|
|
593
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
594
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
595
|
+
const headers = {};
|
|
596
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
597
|
+
return headers;
|
|
598
|
+
};
|
|
599
|
+
return customFetch(getPatchMyUserUrl(params), {
|
|
308
600
|
...options,
|
|
309
|
-
method: "
|
|
601
|
+
method: "PATCH",
|
|
310
602
|
headers: {
|
|
311
603
|
"Content-Type": "application/json",
|
|
312
|
-
...options?.headers
|
|
604
|
+
...getHeaders(options?.headers)
|
|
313
605
|
},
|
|
314
|
-
body: JSON.stringify(
|
|
606
|
+
body: JSON.stringify(patchMyUserBody)
|
|
315
607
|
});
|
|
316
608
|
};
|
|
317
|
-
const
|
|
609
|
+
const getListMyIdentityLinksUrl = (params) => {
|
|
318
610
|
const normalizedParams = new URLSearchParams();
|
|
319
611
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
320
|
-
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : value
|
|
612
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
321
613
|
});
|
|
322
614
|
const stringifiedParams = normalizedParams.toString();
|
|
323
|
-
return stringifiedParams.length > 0 ? `${getProxyPath()}/users?${stringifiedParams}` : `${getProxyPath()}/users`;
|
|
615
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/users/me/identity_links?${stringifiedParams}` : `${getProxyPath()}/users/me/identity_links`;
|
|
324
616
|
};
|
|
325
617
|
/**
|
|
326
|
-
*
|
|
618
|
+
* The identity provider accounts a sign-in linked to the signed-in user,
|
|
619
|
+
* oldest first. The provider's subject and claims are never returned.
|
|
620
|
+
*
|
|
621
|
+
* With `project_id`, the links are listed only when the session belongs to
|
|
622
|
+
* that project.
|
|
623
|
+
* @summary List the provider accounts linked to me
|
|
327
624
|
*/
|
|
328
|
-
const
|
|
329
|
-
return customFetch(
|
|
625
|
+
const listMyIdentityLinks = async (params, options) => {
|
|
626
|
+
return customFetch(getListMyIdentityLinksUrl(params), {
|
|
330
627
|
...options,
|
|
331
628
|
method: "GET"
|
|
332
629
|
});
|
|
333
630
|
};
|
|
334
|
-
const
|
|
631
|
+
const getListMyPasskeysUrl = (params) => {
|
|
335
632
|
const normalizedParams = new URLSearchParams();
|
|
336
633
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
337
|
-
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : value
|
|
634
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
338
635
|
});
|
|
339
636
|
const stringifiedParams = normalizedParams.toString();
|
|
340
|
-
return stringifiedParams.length > 0 ? `${getProxyPath()}/users
|
|
637
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/users/me/passkeys?${stringifiedParams}` : `${getProxyPath()}/users/me/passkeys`;
|
|
341
638
|
};
|
|
342
639
|
/**
|
|
343
|
-
*
|
|
640
|
+
* The signed-in user's own passkeys, newest first, paginated with a cursor.
|
|
641
|
+
* Each passkey carries its id, its name and when it was registered, never the
|
|
642
|
+
* credential itself.
|
|
643
|
+
*
|
|
644
|
+
* With `project_id`, the passkeys are listed only when the session belongs to
|
|
645
|
+
* that project.
|
|
646
|
+
* @summary List my passkeys
|
|
344
647
|
*/
|
|
345
|
-
const
|
|
346
|
-
return customFetch(
|
|
648
|
+
const listMyPasskeys = async (params, options) => {
|
|
649
|
+
return customFetch(getListMyPasskeysUrl(params), {
|
|
347
650
|
...options,
|
|
348
651
|
method: "GET"
|
|
349
652
|
});
|
|
350
653
|
};
|
|
351
|
-
const
|
|
654
|
+
const getGetMyPasswordStateUrl = (params) => {
|
|
352
655
|
const normalizedParams = new URLSearchParams();
|
|
353
656
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
354
|
-
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : value
|
|
657
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
355
658
|
});
|
|
356
659
|
const stringifiedParams = normalizedParams.toString();
|
|
357
|
-
return stringifiedParams.length > 0 ? `${getProxyPath()}/users
|
|
660
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/users/me/password?${stringifiedParams}` : `${getProxyPath()}/users/me/password`;
|
|
358
661
|
};
|
|
359
662
|
/**
|
|
360
|
-
*
|
|
663
|
+
* Reports when the signed-in user's current password was set, and leaves
|
|
664
|
+
* `set_at` out when they have none. The password and its hash are never
|
|
665
|
+
* returned.
|
|
666
|
+
*
|
|
667
|
+
* With `project_id`, the state is read only when the session belongs to that
|
|
668
|
+
* project.
|
|
669
|
+
* @summary Get my password state
|
|
361
670
|
*/
|
|
362
|
-
const
|
|
363
|
-
return customFetch(
|
|
671
|
+
const getMyPasswordState = async (params, options) => {
|
|
672
|
+
return customFetch(getGetMyPasswordStateUrl(params), {
|
|
364
673
|
...options,
|
|
365
|
-
method: "
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
674
|
+
method: "GET"
|
|
675
|
+
});
|
|
676
|
+
};
|
|
677
|
+
const getListMyProjectsUrl = (params) => {
|
|
678
|
+
const normalizedParams = new URLSearchParams();
|
|
679
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
680
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
681
|
+
});
|
|
682
|
+
const stringifiedParams = normalizedParams.toString();
|
|
683
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/users/me/projects?${stringifiedParams}` : `${getProxyPath()}/users/me/projects`;
|
|
684
|
+
};
|
|
685
|
+
/**
|
|
686
|
+
* The projects the signed-in user can act on: those they hold an active grant
|
|
687
|
+
* on, either directly or through a team they are a member of. For a platform
|
|
688
|
+
* operator (ADR 075) that is every project of the deployment. Ordered by
|
|
689
|
+
* project id and paged with an opaque cursor.
|
|
690
|
+
*
|
|
691
|
+
* This is not the same question as `queryProjects`, which answers with the one
|
|
692
|
+
* project the calling credential is bound to. Here the session is the caller
|
|
693
|
+
* and the grants are the answer, so the list spans projects.
|
|
694
|
+
*
|
|
695
|
+
* With `name_contains`, only the projects whose name contains that text are
|
|
696
|
+
* listed. The search runs on the server together with the grants, so it
|
|
697
|
+
* reaches every project the user can act on, however many there are, and
|
|
698
|
+
* pages like the full list.
|
|
699
|
+
*
|
|
700
|
+
* With `project_id`, the projects are listed only when the session belongs to
|
|
701
|
+
* that project. It names the project the session was signed in to, not one to
|
|
702
|
+
* list.
|
|
703
|
+
* @summary List the projects I can act on
|
|
704
|
+
*/
|
|
705
|
+
const listMyProjects = async (params, options) => {
|
|
706
|
+
return customFetch(getListMyProjectsUrl(params), {
|
|
707
|
+
...options,
|
|
708
|
+
method: "GET"
|
|
371
709
|
});
|
|
372
710
|
};
|
|
373
|
-
const
|
|
374
|
-
|
|
711
|
+
const getGetMyUserSchemaUrl = (params) => {
|
|
712
|
+
const normalizedParams = new URLSearchParams();
|
|
713
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
714
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
715
|
+
});
|
|
716
|
+
const stringifiedParams = normalizedParams.toString();
|
|
717
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/users/me/schema?${stringifiedParams}` : `${getProxyPath()}/users/me/schema`;
|
|
375
718
|
};
|
|
376
719
|
/**
|
|
377
|
-
*
|
|
720
|
+
* The schema the signed-in user's own record is validated against.
|
|
721
|
+
*
|
|
722
|
+
* With `project_id`, the schema is returned only when the session belongs to
|
|
723
|
+
* that project.
|
|
724
|
+
* @summary Get my user schema
|
|
725
|
+
*/
|
|
726
|
+
const getMyUserSchema = async (params, options) => {
|
|
727
|
+
return customFetch(getGetMyUserSchemaUrl(params), {
|
|
728
|
+
...options,
|
|
729
|
+
method: "GET"
|
|
730
|
+
});
|
|
731
|
+
};
|
|
732
|
+
const getListMyTeamsUrl = (params) => {
|
|
733
|
+
const normalizedParams = new URLSearchParams();
|
|
734
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
735
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
736
|
+
});
|
|
737
|
+
const stringifiedParams = normalizedParams.toString();
|
|
738
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/users/me/teams?${stringifiedParams}` : `${getProxyPath()}/users/me/teams`;
|
|
739
|
+
};
|
|
740
|
+
/**
|
|
741
|
+
* The signed-in user's own team roster, ordered by team name.
|
|
742
|
+
*
|
|
743
|
+
* With `project_id`, the teams are listed only when the session belongs to
|
|
744
|
+
* that project.
|
|
745
|
+
* @summary List the teams I belong to
|
|
378
746
|
*/
|
|
379
|
-
const
|
|
380
|
-
return customFetch(
|
|
747
|
+
const listMyTeams = async (params, options) => {
|
|
748
|
+
return customFetch(getListMyTeamsUrl(params), {
|
|
381
749
|
...options,
|
|
382
750
|
method: "GET"
|
|
383
751
|
});
|
|
@@ -387,37 +755,63 @@ const getCreateFlowUrl = () => {
|
|
|
387
755
|
};
|
|
388
756
|
/**
|
|
389
757
|
* Resolves a flow definition based on purpose + audience context and returns
|
|
390
|
-
the first capability step. Creates a new session implicitly unless
|
|
391
|
-
`session_id` is provided
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
758
|
+
* the first capability step. Creates a new session implicitly unless
|
|
759
|
+
* `session_id` is provided, together with that session's `session_token`
|
|
760
|
+
* (for step-up / reauth on an existing session).
|
|
761
|
+
*
|
|
762
|
+
* The browser `Origin` header selects which deployment serves this attempt:
|
|
763
|
+
* the gate admits the origin against the project's origin patterns and live
|
|
764
|
+
* previews, the newest deployment to that exact origin is the target, and
|
|
765
|
+
* that deployment's release supplies flow definitions, user schemas and
|
|
766
|
+
* branding. The resolved deployment is sealed into the `_zflow` cookie so
|
|
767
|
+
* later steps keep the same configuration. An origin that matches no pattern
|
|
768
|
+
* answers `403` with `proj.origin_not_allowed`; one that matches a preview
|
|
769
|
+
* pattern with no live preview answers `403` with `proj.preview_not_live`;
|
|
770
|
+
* nothing deployed to the target answers `409` with `rel.not_deployed`; a
|
|
771
|
+
* revoked release answers `409` with `rel.revoked`. A request with no
|
|
772
|
+
* `Origin` passes the gate and still needs a deployment target. A loopback
|
|
773
|
+
* origin passes it too, and so does the server's own origin, from which its
|
|
774
|
+
* console previews a project's login; a step submitted from the server's
|
|
775
|
+
* own origin is still refused unless the project lists it.
|
|
776
|
+
*
|
|
777
|
+
* The response contains an `id` field — the flow handle. Use it as the path
|
|
778
|
+
* parameter for all subsequent `/flow/{id}/submit` calls.
|
|
779
|
+
*
|
|
780
|
+
* The response also sets an encrypted `HttpOnly` cookie (`_zflow`) containing
|
|
781
|
+
* the flow's orchestration state (current step, collected data, history).
|
|
782
|
+
* The server is stateless between requests — all flow state lives in this
|
|
783
|
+
* cookie. The browser sends it automatically on subsequent requests.
|
|
401
784
|
* @summary Start a new flow
|
|
402
785
|
*/
|
|
403
786
|
const createFlow = async (createFlowBody, options) => {
|
|
787
|
+
const getHeaders = (h) => {
|
|
788
|
+
if (!h) return {};
|
|
789
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
790
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
791
|
+
const headers = {};
|
|
792
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
793
|
+
return headers;
|
|
794
|
+
};
|
|
404
795
|
return customFetch(getCreateFlowUrl(), {
|
|
405
796
|
...options,
|
|
406
797
|
method: "POST",
|
|
407
798
|
headers: {
|
|
408
799
|
"Content-Type": "application/json",
|
|
409
|
-
...options?.headers
|
|
800
|
+
...getHeaders(options?.headers)
|
|
410
801
|
},
|
|
411
802
|
body: JSON.stringify(createFlowBody)
|
|
412
803
|
});
|
|
413
804
|
};
|
|
414
805
|
const getGetFlowStepUrl = (id) => {
|
|
415
|
-
return `${getProxyPath()}/flow/${id}`;
|
|
806
|
+
return `${getProxyPath()}/flow/${encodeURIComponent(String(id))}`;
|
|
416
807
|
};
|
|
417
808
|
/**
|
|
418
809
|
* Returns the current capability step without advancing the state machine.
|
|
419
|
-
Useful for page reloads or re-rendering after a network error.
|
|
420
|
-
|
|
810
|
+
* Useful for page reloads or re-rendering after a network error.
|
|
811
|
+
*
|
|
812
|
+
* Reuses the deployment sealed into `_zflow` at `createFlow`; it does not
|
|
813
|
+
* re-resolve from `Origin`. If that release was revoked since the attempt
|
|
814
|
+
* started, the response is `409` with `rel.revoked`.
|
|
421
815
|
* @summary Get current step (re-render)
|
|
422
816
|
*/
|
|
423
817
|
const getFlowStep = async (id, options) => {
|
|
@@ -427,107 +821,131 @@ const getFlowStep = async (id, options) => {
|
|
|
427
821
|
});
|
|
428
822
|
};
|
|
429
823
|
const getSubmitFlowStepUrl = (id) => {
|
|
430
|
-
return `${getProxyPath()}/flow/${id}/submit`;
|
|
824
|
+
return `${getProxyPath()}/flow/${encodeURIComponent(String(id))}/submit`;
|
|
431
825
|
};
|
|
432
826
|
/**
|
|
433
827
|
* Submits user input for the current step. The server validates,
|
|
434
|
-
processes (e.g., verifies a credential), advances the state machine
|
|
435
|
-
through any invisible steps, and returns the next visible step.
|
|
436
|
-
|
|
437
|
-
The response sets an updated encrypted `HttpOnly` cookie (`_zflow`)
|
|
438
|
-
with the new flow state. The server is stateless — all orchestration
|
|
439
|
-
state is carried in this cookie between requests.
|
|
440
|
-
|
|
441
|
-
**Important:** The `id` in the response may differ from the `id` used in
|
|
442
|
-
the request. This happens when a flow pivots (pushes a new flow onto the
|
|
443
|
-
stack) or when a stacked flow completes (auto-pops to the parent flow).
|
|
444
|
-
Always use the `id` from the latest response for the next request.
|
|
445
|
-
|
|
446
|
-
## Flow completion
|
|
447
|
-
|
|
448
|
-
When `step.type` is `complete`, the flow is terminal. The `step.behavior`
|
|
449
|
-
field tells the frontend what to do:
|
|
450
|
-
|
|
451
|
-
| `behavior` | Action |
|
|
452
|
-
|------------- |------------------------------------------------------------|
|
|
453
|
-
| `redirect` | Navigate to `redirect_uri` (OIDC/SAML auth request done). |
|
|
454
|
-
| `show` | Render the step as a success screen (e.g., registration). |
|
|
455
|
-
|
|
456
|
-
A `complete` step is only returned when the **entire flow stack** is done.
|
|
457
|
-
If a stacked flow (e.g., recovery pivoted from login) finishes, the server
|
|
458
|
-
auto-pops to the parent flow and returns the parent's next step — the
|
|
459
|
-
frontend never sees a `complete` for intermediate flows.
|
|
460
|
-
|
|
828
|
+
* processes (e.g., verifies a credential), advances the state machine
|
|
829
|
+
* through any invisible steps, and returns the next visible step.
|
|
830
|
+
*
|
|
831
|
+
* The response sets an updated encrypted `HttpOnly` cookie (`_zflow`)
|
|
832
|
+
* with the new flow state. The server is stateless — all orchestration
|
|
833
|
+
* state is carried in this cookie between requests.
|
|
834
|
+
*
|
|
835
|
+
* **Important:** The `id` in the response may differ from the `id` used in
|
|
836
|
+
* the request. This happens when a flow pivots (pushes a new flow onto the
|
|
837
|
+
* stack) or when a stacked flow completes (auto-pops to the parent flow).
|
|
838
|
+
* Always use the `id` from the latest response for the next request.
|
|
839
|
+
*
|
|
840
|
+
* ## Flow completion
|
|
841
|
+
*
|
|
842
|
+
* When `step.type` is `complete`, the flow is terminal. The `step.behavior`
|
|
843
|
+
* field tells the frontend what to do:
|
|
844
|
+
*
|
|
845
|
+
* | `behavior` | Action |
|
|
846
|
+
* |------------- |------------------------------------------------------------|
|
|
847
|
+
* | `redirect` | Navigate to `redirect_uri` (OIDC/SAML auth request done). |
|
|
848
|
+
* | `show` | Render the step as a success screen (e.g., registration). |
|
|
849
|
+
*
|
|
850
|
+
* A `complete` step is only returned when the **entire flow stack** is done.
|
|
851
|
+
* If a stacked flow (e.g., recovery pivoted from login) finishes, the server
|
|
852
|
+
* auto-pops to the parent flow and returns the parent's next step — the
|
|
853
|
+
* frontend never sees a `complete` for intermediate flows.
|
|
854
|
+
*
|
|
855
|
+
* ## External sign-in
|
|
856
|
+
*
|
|
857
|
+
* `{action: "sso", sso_provider_id, return_target}` on a step that offers
|
|
858
|
+
* `sso_providers` returns the engine-emitted `sso-redirect` step, whose
|
|
859
|
+
* `redirect_url` the frontend navigates to.
|
|
860
|
+
*
|
|
861
|
+
* - The flow state does not change, but `_zflow` is re-sealed like on
|
|
862
|
+
* every response, so its ten-minute window restarts at this submission;
|
|
863
|
+
* the external sign-in and the return must complete within it.
|
|
864
|
+
* - A second `Set-Cookie` line carries the browser-binding cookie the
|
|
865
|
+
* callback checks: `HttpOnly`, `Path=/`, `SameSite=Lax`.
|
|
866
|
+
* - On every host except http loopback it is `__Host-_zsso` with `Secure`.
|
|
867
|
+
* - When the request host is http loopback (local development, where
|
|
868
|
+
* Safari rejects `Secure`), it is `_zsso` with no `Secure`; the
|
|
869
|
+
* `__Host-` prefix is dropped because it requires `Secure`.
|
|
870
|
+
*
|
|
871
|
+
* A connection whose `client_id` is a `${{ NAME }}` reference has it filled
|
|
872
|
+
* from the project's variables. A provider the engine cannot start a
|
|
873
|
+
* sign-in with, including a reference with no variable behind it,
|
|
874
|
+
* re-renders the step with `error.sso_unavailable`.
|
|
875
|
+
*
|
|
876
|
+
* Reuses the deployment sealed into `_zflow` at `createFlow`; it does not
|
|
877
|
+
* re-resolve from `Origin`. If that release was revoked since the attempt
|
|
878
|
+
* started, the response is `409` with `rel.revoked`.
|
|
461
879
|
* @summary Submit step data and advance
|
|
462
880
|
*/
|
|
463
881
|
const submitFlowStep = async (id, submitFlowStepBody, options) => {
|
|
882
|
+
const getHeaders = (h) => {
|
|
883
|
+
if (!h) return {};
|
|
884
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
885
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
886
|
+
const headers = {};
|
|
887
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
888
|
+
return headers;
|
|
889
|
+
};
|
|
464
890
|
return customFetch(getSubmitFlowStepUrl(id), {
|
|
465
891
|
...options,
|
|
466
892
|
method: "POST",
|
|
467
893
|
headers: {
|
|
468
894
|
"Content-Type": "application/json",
|
|
469
|
-
...options?.headers
|
|
895
|
+
...getHeaders(options?.headers)
|
|
470
896
|
},
|
|
471
897
|
body: JSON.stringify(submitFlowStepBody)
|
|
472
898
|
});
|
|
473
899
|
};
|
|
474
|
-
const getSubmitFlowEventUrl = (id) => {
|
|
475
|
-
return `${getProxyPath()}/flow/${id}/event`;
|
|
476
|
-
};
|
|
477
|
-
/**
|
|
478
|
-
* Submits telemetry or fingerprint data from the frontend.
|
|
479
|
-
Does not advance the state machine. Used for risk evaluation.
|
|
480
|
-
|
|
481
|
-
* @summary Submit client-side event
|
|
482
|
-
*/
|
|
483
|
-
const submitFlowEvent = async (id, submitFlowEventBody, options) => {
|
|
484
|
-
return customFetch(getSubmitFlowEventUrl(id), {
|
|
485
|
-
...options,
|
|
486
|
-
method: "POST",
|
|
487
|
-
headers: {
|
|
488
|
-
"Content-Type": "application/json",
|
|
489
|
-
...options?.headers
|
|
490
|
-
},
|
|
491
|
-
body: JSON.stringify(submitFlowEventBody)
|
|
492
|
-
});
|
|
493
|
-
};
|
|
494
900
|
const getCreateAuthAttemptUrl = () => {
|
|
495
901
|
return `${getProxyPath()}/auth_attempts`;
|
|
496
902
|
};
|
|
497
903
|
/**
|
|
498
904
|
* Starts a new authentication attempt. This is the entry point for the auth_attempts state machine.
|
|
499
|
-
|
|
500
|
-
An attempt is an ephemeral (15-minute TTL) state machine that drives a single authentication round.
|
|
501
|
-
It accepts factor challenges, verifies proofs, and completes into a session or handoff token.
|
|
502
|
-
|
|
503
|
-
Accepts a project_id and challenge_nonce (from POST /bootstrap/challenge). For step-up re-auth,
|
|
504
|
-
also include session_id to add factors to an existing session.
|
|
505
|
-
|
|
905
|
+
*
|
|
906
|
+
* An attempt is an ephemeral (15-minute TTL) state machine that drives a single authentication round.
|
|
907
|
+
* It accepts factor challenges, verifies proofs, and completes into a session or handoff token.
|
|
908
|
+
*
|
|
909
|
+
* Accepts a project_id and challenge_nonce (from POST /bootstrap/challenge). For step-up re-auth,
|
|
910
|
+
* also include session_id and that session's session_token to add factors to an existing session.
|
|
911
|
+
*
|
|
912
|
+
* The project comes from the project secret. A body `project_id` that disagrees
|
|
913
|
+
* answers `403` with `proj.mismatch`. Sealed `deployment_id` / `release_id` are
|
|
914
|
+
* filled only when create runs with a runtime resolution already on the
|
|
915
|
+
* context (the flow create path); this HTTP entry point does not resolve
|
|
916
|
+
* Origin or refuse a revoked release itself.
|
|
506
917
|
* @summary Create a new authentication attempt
|
|
507
918
|
*/
|
|
508
919
|
const createAuthAttempt = async (createAuthAttemptBody, options) => {
|
|
920
|
+
const getHeaders = (h) => {
|
|
921
|
+
if (!h) return {};
|
|
922
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
923
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
924
|
+
const headers = {};
|
|
925
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
926
|
+
return headers;
|
|
927
|
+
};
|
|
509
928
|
return customFetch(getCreateAuthAttemptUrl(), {
|
|
510
929
|
...options,
|
|
511
930
|
method: "POST",
|
|
512
931
|
headers: {
|
|
513
932
|
"Content-Type": "application/json",
|
|
514
|
-
...options?.headers
|
|
933
|
+
...getHeaders(options?.headers)
|
|
515
934
|
},
|
|
516
935
|
body: JSON.stringify(createAuthAttemptBody)
|
|
517
936
|
});
|
|
518
937
|
};
|
|
519
938
|
const getGetAuthAttemptUrl = (attemptId) => {
|
|
520
|
-
return `${getProxyPath()}/auth_attempts/${attemptId}`;
|
|
939
|
+
return `${getProxyPath()}/auth_attempts/${encodeURIComponent(String(attemptId))}`;
|
|
521
940
|
};
|
|
522
941
|
/**
|
|
523
942
|
* Polls the current state of an authentication attempt.
|
|
524
|
-
|
|
525
|
-
Returns the attempt's state, available factors for the next challenge,
|
|
526
|
-
challenges issued so far, and any errors preventing progress.
|
|
527
|
-
|
|
528
|
-
Use this for polling during long-running factor verifications (e.g., waiting for
|
|
529
|
-
a federated IdP callback or a device flow).
|
|
530
|
-
|
|
943
|
+
*
|
|
944
|
+
* Returns the attempt's state, available factors for the next challenge,
|
|
945
|
+
* challenges issued so far, and any errors preventing progress.
|
|
946
|
+
*
|
|
947
|
+
* Use this for polling during long-running factor verifications (e.g., waiting for
|
|
948
|
+
* a federated IdP callback or a device flow).
|
|
531
949
|
* @summary Get authentication attempt state
|
|
532
950
|
*/
|
|
533
951
|
const getAuthAttempt = async (attemptId, options) => {
|
|
@@ -537,72 +955,87 @@ const getAuthAttempt = async (attemptId, options) => {
|
|
|
537
955
|
});
|
|
538
956
|
};
|
|
539
957
|
const getIssueChallengeUrl = (attemptId) => {
|
|
540
|
-
return `${getProxyPath()}/auth_attempts/${attemptId}/challenges`;
|
|
958
|
+
return `${getProxyPath()}/auth_attempts/${encodeURIComponent(String(attemptId))}/challenges`;
|
|
541
959
|
};
|
|
542
960
|
/**
|
|
543
961
|
* Issues a single-factor verification challenge within an auth attempt.
|
|
544
|
-
|
|
545
|
-
This advances the authentication state machine by requesting a specific factor method
|
|
546
|
-
(password, passkey, TOTP, OTP via SMS, etc.). The server responds with challenge details
|
|
547
|
-
including method, metadata, and any UI hints. The client then verifies the proof
|
|
548
|
-
by calling POST /auth_attempts/{attempt_id}/challenges/{challenge_id}/verify.
|
|
549
|
-
|
|
962
|
+
*
|
|
963
|
+
* This advances the authentication state machine by requesting a specific factor method
|
|
964
|
+
* (password, passkey, TOTP, OTP via SMS, etc.). The server responds with challenge details
|
|
965
|
+
* including method, metadata, and any UI hints. The client then verifies the proof
|
|
966
|
+
* by calling POST /auth_attempts/{attempt_id}/challenges/{challenge_id}/verify.
|
|
550
967
|
* @summary Issue a factor challenge
|
|
551
968
|
*/
|
|
552
969
|
const issueChallenge = async (attemptId, issueChallengeBody, options) => {
|
|
970
|
+
const getHeaders = (h) => {
|
|
971
|
+
if (!h) return {};
|
|
972
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
973
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
974
|
+
const headers = {};
|
|
975
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
976
|
+
return headers;
|
|
977
|
+
};
|
|
553
978
|
return customFetch(getIssueChallengeUrl(attemptId), {
|
|
554
979
|
...options,
|
|
555
980
|
method: "POST",
|
|
556
981
|
headers: {
|
|
557
982
|
"Content-Type": "application/json",
|
|
558
|
-
...options?.headers
|
|
983
|
+
...getHeaders(options?.headers)
|
|
559
984
|
},
|
|
560
985
|
body: JSON.stringify(issueChallengeBody)
|
|
561
986
|
});
|
|
562
987
|
};
|
|
563
988
|
const getVerifyChallengeProofUrl = (attemptId, challengeId) => {
|
|
564
|
-
return `${getProxyPath()}/auth_attempts/${attemptId}/challenges/${challengeId}/verify`;
|
|
989
|
+
return `${getProxyPath()}/auth_attempts/${encodeURIComponent(String(attemptId))}/challenges/${encodeURIComponent(String(challengeId))}/verify`;
|
|
565
990
|
};
|
|
566
991
|
/**
|
|
567
992
|
* Submits a proof (credential, code, assertion) to verify a factor challenge.
|
|
568
|
-
|
|
569
|
-
The proof format depends on the challenge method. For example:
|
|
570
|
-
- `password` method: { password: "…" }
|
|
571
|
-
- `totp` method: { totp: { code: "123456" } }
|
|
572
|
-
- `passkey` method: { passkey: { assertion: "…" } }
|
|
573
|
-
- `recovery_code` method: { recovery_code: "…" }
|
|
574
|
-
|
|
575
|
-
On successful verification, the factor is written to the auth attempt.
|
|
576
|
-
The attempt moves to the next pending challenge or completes if all required factors are verified.
|
|
577
|
-
|
|
993
|
+
*
|
|
994
|
+
* The proof format depends on the challenge method. For example:
|
|
995
|
+
* - `password` method: { password: "…" }
|
|
996
|
+
* - `totp` method: { totp: { code: "123456" } }
|
|
997
|
+
* - `passkey` method: { passkey: { assertion: "…" } }
|
|
998
|
+
* - `recovery_code` method: { recovery_code: "…" }
|
|
999
|
+
*
|
|
1000
|
+
* On successful verification, the factor is written to the auth attempt.
|
|
1001
|
+
* The attempt moves to the next pending challenge or completes if all required factors are verified.
|
|
578
1002
|
* @summary Verify a factor proof
|
|
579
1003
|
*/
|
|
580
1004
|
const verifyChallengeProof = async (attemptId, challengeId, verifyChallengeProofBody, options) => {
|
|
1005
|
+
const getHeaders = (h) => {
|
|
1006
|
+
if (!h) return {};
|
|
1007
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1008
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
1009
|
+
const headers = {};
|
|
1010
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
1011
|
+
return headers;
|
|
1012
|
+
};
|
|
581
1013
|
return customFetch(getVerifyChallengeProofUrl(attemptId, challengeId), {
|
|
582
1014
|
...options,
|
|
583
1015
|
method: "POST",
|
|
584
1016
|
headers: {
|
|
585
1017
|
"Content-Type": "application/json",
|
|
586
|
-
...options?.headers
|
|
1018
|
+
...getHeaders(options?.headers)
|
|
587
1019
|
},
|
|
588
1020
|
body: JSON.stringify(verifyChallengeProofBody)
|
|
589
1021
|
});
|
|
590
1022
|
};
|
|
591
1023
|
const getCreateHandoffUrl = (attemptId) => {
|
|
592
|
-
return `${getProxyPath()}/auth_attempts/${attemptId}/handoff`;
|
|
1024
|
+
return `${getProxyPath()}/auth_attempts/${encodeURIComponent(String(attemptId))}/handoff`;
|
|
593
1025
|
};
|
|
594
1026
|
/**
|
|
595
1027
|
* Completes the authentication attempt and mints a `handoff_token`.
|
|
596
|
-
|
|
597
|
-
Call this after all required factors have been verified and the attempt is in `completed` state.
|
|
598
|
-
The handoff token is short-lived (≤60 seconds) and must be exchanged at
|
|
599
|
-
POST /sessions/exchange to receive the final session and session_token.
|
|
600
|
-
|
|
601
|
-
The handoff token is:
|
|
602
|
-
- Single-use (atomic exchange, no retry)
|
|
603
|
-
- Audience-bound (requires matching project key for exchange)
|
|
604
|
-
- Idempotency-safe within a 5-minute window (see conventions)
|
|
605
|
-
|
|
1028
|
+
*
|
|
1029
|
+
* Call this after all required factors have been verified and the attempt is in `completed` state.
|
|
1030
|
+
* The handoff token is short-lived (≤60 seconds) and must be exchanged at
|
|
1031
|
+
* POST /sessions/exchange to receive the final session and session_token.
|
|
1032
|
+
*
|
|
1033
|
+
* The handoff token is:
|
|
1034
|
+
* - Single-use (atomic exchange, no retry)
|
|
1035
|
+
* - Audience-bound (requires matching project key for exchange)
|
|
1036
|
+
* - Idempotency-safe within a 5-minute window (see conventions)
|
|
1037
|
+
*
|
|
1038
|
+
* Revoke refusal for a sealed release happens at handoff exchange, not here.
|
|
606
1039
|
* @summary Complete authentication and create handoff token
|
|
607
1040
|
*/
|
|
608
1041
|
const createHandoff = async (attemptId, options) => {
|
|
@@ -615,25 +1048,69 @@ const getCreateProjectUrl = () => {
|
|
|
615
1048
|
return `${getProxyPath()}/projects`;
|
|
616
1049
|
};
|
|
617
1050
|
/**
|
|
1051
|
+
* Creates a project and returns its project secret and preview secret, which no
|
|
1052
|
+
* other endpoint returns.
|
|
1053
|
+
*
|
|
1054
|
+
* The request needs no credential and is rate-limited. Unless `seed_defaults` is
|
|
1055
|
+
* `false`, the project starts with a default user schema and flow; the CLI turns
|
|
1056
|
+
* that off and uploads its own from `.zitadel/`.
|
|
618
1057
|
* @summary Create project
|
|
619
1058
|
*/
|
|
620
1059
|
const createProject = async (createProjectBody, options) => {
|
|
1060
|
+
const getHeaders = (h) => {
|
|
1061
|
+
if (!h) return {};
|
|
1062
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1063
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
1064
|
+
const headers = {};
|
|
1065
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
1066
|
+
return headers;
|
|
1067
|
+
};
|
|
621
1068
|
return customFetch(getCreateProjectUrl(), {
|
|
622
1069
|
...options,
|
|
623
1070
|
method: "POST",
|
|
624
1071
|
headers: {
|
|
625
1072
|
"Content-Type": "application/json",
|
|
626
|
-
...options?.headers
|
|
1073
|
+
...getHeaders(options?.headers)
|
|
627
1074
|
},
|
|
628
1075
|
body: JSON.stringify(createProjectBody)
|
|
629
1076
|
});
|
|
630
1077
|
};
|
|
1078
|
+
const getQueryProjectsUrl = () => {
|
|
1079
|
+
return `${getProxyPath()}/projects/query`;
|
|
1080
|
+
};
|
|
1081
|
+
/**
|
|
1082
|
+
* Returns the project the project secret belongs to, as a page of at most one
|
|
1083
|
+
* project.
|
|
1084
|
+
*
|
|
1085
|
+
* A credential is scoped to one project until ADR 036 widens it, so the filters
|
|
1086
|
+
* and sorting apply to that project alone. The projects a signed-in person can
|
|
1087
|
+
* act on are listed by `GET /users/me/projects`.
|
|
1088
|
+
* @summary Query projects
|
|
1089
|
+
*/
|
|
1090
|
+
const queryProjects = async (queryProjectsBody, options) => {
|
|
1091
|
+
const getHeaders = (h) => {
|
|
1092
|
+
if (!h) return {};
|
|
1093
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1094
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
1095
|
+
const headers = {};
|
|
1096
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
1097
|
+
return headers;
|
|
1098
|
+
};
|
|
1099
|
+
return customFetch(getQueryProjectsUrl(), {
|
|
1100
|
+
...options,
|
|
1101
|
+
method: "POST",
|
|
1102
|
+
headers: {
|
|
1103
|
+
"Content-Type": "application/json",
|
|
1104
|
+
...getHeaders(options?.headers)
|
|
1105
|
+
},
|
|
1106
|
+
body: JSON.stringify(queryProjectsBody)
|
|
1107
|
+
});
|
|
1108
|
+
};
|
|
631
1109
|
const getGetProjectUrl = (projectId) => {
|
|
632
|
-
return `${getProxyPath()}/projects/${projectId}`;
|
|
1110
|
+
return `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}`;
|
|
633
1111
|
};
|
|
634
1112
|
/**
|
|
635
1113
|
* Returns the current state of a project.
|
|
636
|
-
|
|
637
1114
|
* @summary Get project
|
|
638
1115
|
*/
|
|
639
1116
|
const getProject = async (projectId, options) => {
|
|
@@ -642,219 +1119,611 @@ const getProject = async (projectId, options) => {
|
|
|
642
1119
|
method: "GET"
|
|
643
1120
|
});
|
|
644
1121
|
};
|
|
645
|
-
const
|
|
646
|
-
return `${getProxyPath()}/
|
|
1122
|
+
const getPatchProjectUrl = (projectId) => {
|
|
1123
|
+
return `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}`;
|
|
647
1124
|
};
|
|
648
1125
|
/**
|
|
649
|
-
*
|
|
650
|
-
|
|
651
|
-
This is optional — an `auth_attempt` will create a session implicitly if none is provided.
|
|
652
|
-
Use this explicitly when you want to:
|
|
653
|
-
- Pre-allocate a `session_id` before the user is known, so device/telemetry signals
|
|
654
|
-
can be correlated with the eventual authenticated session from the start.
|
|
655
|
-
- Track anonymous state (bot detection, device fingerprint) that survives until authentication.
|
|
656
|
-
|
|
657
|
-
The returned `session_token` authorises GET and DELETE on this session.
|
|
658
|
-
It is superseded when a handoff exchange completes — clients must replace it at that point.
|
|
659
|
-
|
|
660
|
-
Anonymous sessions expire aggressively (10-minute TTL). The TTL resets to the configured
|
|
661
|
-
full session TTL when the first authentication factor is written via a completing `auth_attempt`.
|
|
662
|
-
|
|
663
|
-
* @summary Create an anonymous session shell
|
|
1126
|
+
* Updates the state of a project.
|
|
1127
|
+
* @summary Update project
|
|
664
1128
|
*/
|
|
665
|
-
const
|
|
666
|
-
|
|
1129
|
+
const patchProject = async (projectId, patchProjectBody, options) => {
|
|
1130
|
+
const getHeaders = (h) => {
|
|
1131
|
+
if (!h) return {};
|
|
1132
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1133
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
1134
|
+
const headers = {};
|
|
1135
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
1136
|
+
return headers;
|
|
1137
|
+
};
|
|
1138
|
+
return customFetch(getPatchProjectUrl(projectId), {
|
|
667
1139
|
...options,
|
|
668
|
-
method: "
|
|
1140
|
+
method: "PATCH",
|
|
669
1141
|
headers: {
|
|
670
1142
|
"Content-Type": "application/json",
|
|
671
|
-
...options?.headers
|
|
1143
|
+
...getHeaders(options?.headers)
|
|
672
1144
|
},
|
|
673
|
-
body: JSON.stringify(
|
|
1145
|
+
body: JSON.stringify(patchProjectBody)
|
|
674
1146
|
});
|
|
675
1147
|
};
|
|
676
|
-
const
|
|
1148
|
+
const getListProjectAdminsUrl = (projectId, params) => {
|
|
677
1149
|
const normalizedParams = new URLSearchParams();
|
|
678
1150
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
679
|
-
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : value
|
|
1151
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
680
1152
|
});
|
|
681
1153
|
const stringifiedParams = normalizedParams.toString();
|
|
682
|
-
return stringifiedParams.length > 0 ? `${getProxyPath()}/
|
|
1154
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}/admins?${stringifiedParams}` : `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}/admins`;
|
|
683
1155
|
};
|
|
684
1156
|
/**
|
|
685
|
-
*
|
|
686
|
-
|
|
687
|
-
|
|
688
|
-
*
|
|
1157
|
+
* Lists the people who can administer the project, and how each of them
|
|
1158
|
+
* gets that access. A person appears once, with one entry in `sources` per
|
|
1159
|
+
* way they hold it:
|
|
1160
|
+
*
|
|
1161
|
+
* - `owning_team`: an active member of the team that owns the project
|
|
1162
|
+
* (ADR 054 §2). Removing a grant does not remove this access; it ends
|
|
1163
|
+
* only when the person leaves the team or the project changes owner.
|
|
1164
|
+
* - `grant`: an unexpired `admin` grant on the project, either to the
|
|
1165
|
+
* person (`grant_id` only) or to a team they are an active member of
|
|
1166
|
+
* (`grant_id` and `team`). Revoking that grant removes this source.
|
|
1167
|
+
*
|
|
1168
|
+
* The list follows the authorization check: team membership is read from
|
|
1169
|
+
* the same membership projection the check expands, so a person who left a
|
|
1170
|
+
* team, or whose team or user was deactivated, is not listed through it.
|
|
1171
|
+
* Grants that expired or carry a lower role are left out. A person whose
|
|
1172
|
+
* only access is a `viewer` or `editor` grant is not an admin and is not
|
|
1173
|
+
* listed. Like the check, the list does not look at a person's user status
|
|
1174
|
+
* beyond that, so a direct grant to a suspended person is listed.
|
|
1175
|
+
*
|
|
1176
|
+
* A person whose access comes only through teams the caller is not a
|
|
1177
|
+
* member of is left out, and a team the caller is not in is named by
|
|
1178
|
+
* `team_id` only. The grant to such a team still shows in the project's
|
|
1179
|
+
* grants.
|
|
1180
|
+
*
|
|
1181
|
+
* Ordered by `user_id` and paginated with `page_token`.
|
|
1182
|
+
*
|
|
1183
|
+
* Accepts either a project secret (`oauth2`) or a user-bound Console
|
|
1184
|
+
* session cookie (`nextgenSession`) that can read the project.
|
|
1185
|
+
* @summary List project admins
|
|
689
1186
|
*/
|
|
690
|
-
const
|
|
691
|
-
return customFetch(
|
|
1187
|
+
const listProjectAdmins = async (projectId, params, options) => {
|
|
1188
|
+
return customFetch(getListProjectAdminsUrl(projectId, params), {
|
|
692
1189
|
...options,
|
|
693
1190
|
method: "GET"
|
|
694
1191
|
});
|
|
695
1192
|
};
|
|
696
|
-
const
|
|
697
|
-
|
|
698
|
-
Object.entries(params || {}).forEach(([key, value]) => {
|
|
699
|
-
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : value.toString());
|
|
700
|
-
});
|
|
701
|
-
const stringifiedParams = normalizedParams.toString();
|
|
702
|
-
return stringifiedParams.length > 0 ? `${getProxyPath()}/sessions/exchange?${stringifiedParams}` : `${getProxyPath()}/sessions/exchange`;
|
|
1193
|
+
const getInitClaimUrl = (projectId) => {
|
|
1194
|
+
return `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}/claim/init`;
|
|
703
1195
|
};
|
|
704
1196
|
/**
|
|
705
|
-
*
|
|
706
|
-
|
|
707
|
-
|
|
708
|
-
|
|
709
|
-
|
|
710
|
-
|
|
711
|
-
|---|---|
|
|
712
|
-
| No `session_id` | A new authenticated session is **created**. |
|
|
713
|
-
| `session_id` points to an anonymous shell | Existing session is **upgraded** — user and factors written in, TTL reset to full session TTL. |
|
|
714
|
-
| `session_id` points to an active session (step-up) | Existing session is **upgraded** — new factors merged, `assurance_levels[]` expanded. |
|
|
715
|
-
|
|
716
|
-
The response shape is identical in all three cases.
|
|
717
|
-
|
|
718
|
-
The `session_token` supersedes any previously issued `session_token` for the same session.
|
|
719
|
-
Clients must replace their stored token at this point.
|
|
720
|
-
|
|
721
|
-
Requires a project service key (OAuth2 client credentials).
|
|
722
|
-
|
|
723
|
-
* @summary Exchange handoff token for a session
|
|
1197
|
+
* Starts a claim challenge for an unclaimed project. Authenticated by the
|
|
1198
|
+
* project secret, this mints a single-use, short-lived challenge and returns
|
|
1199
|
+
* the `claim_url` the developer opens in a browser to complete the claim,
|
|
1200
|
+
* together with the `challenge_id` the CLI polls with. The exact expiry is
|
|
1201
|
+
* carried by `expires_at` on the response.
|
|
1202
|
+
* @summary Initialize a project claim
|
|
724
1203
|
*/
|
|
725
|
-
const
|
|
726
|
-
return customFetch(
|
|
1204
|
+
const initClaim = async (projectId, options) => {
|
|
1205
|
+
return customFetch(getInitClaimUrl(projectId), {
|
|
727
1206
|
...options,
|
|
728
|
-
method: "POST"
|
|
729
|
-
headers: {
|
|
730
|
-
"Content-Type": "application/json",
|
|
731
|
-
...options?.headers
|
|
732
|
-
},
|
|
733
|
-
body: JSON.stringify(exchangeHandoffBody)
|
|
1207
|
+
method: "POST"
|
|
734
1208
|
});
|
|
735
1209
|
};
|
|
736
|
-
const
|
|
1210
|
+
const getGetClaimStatusUrl = (projectId, params) => {
|
|
737
1211
|
const normalizedParams = new URLSearchParams();
|
|
738
1212
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
739
|
-
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : value
|
|
1213
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
740
1214
|
});
|
|
741
1215
|
const stringifiedParams = normalizedParams.toString();
|
|
742
|
-
return stringifiedParams.length > 0 ? `${getProxyPath()}/
|
|
1216
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}/claim/status?${stringifiedParams}` : `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}/claim/status`;
|
|
743
1217
|
};
|
|
744
1218
|
/**
|
|
745
|
-
*
|
|
746
|
-
|
|
747
|
-
|
|
748
|
-
|
|
749
|
-
|
|
750
|
-
|
|
751
|
-
|
|
752
|
-
*
|
|
1219
|
+
* Polled by the CLI while a browser completes the claim. Authorized by the
|
|
1220
|
+
* project secret that initiated the challenge. Returns `pending`, or
|
|
1221
|
+
* `completed` with the owning team, the claim timestamp, and the dashboard
|
|
1222
|
+
* URL once the project is claimed. The claim grant, not the polled
|
|
1223
|
+
* challenge, is the source of truth: a project claimed through another
|
|
1224
|
+
* concurrent challenge also reports `completed`, and a completed claim
|
|
1225
|
+
* keeps reporting `completed` past this challenge's expiry and past the
|
|
1226
|
+
* project's claim window.
|
|
1227
|
+
* @summary Get claim status
|
|
753
1228
|
*/
|
|
754
|
-
const
|
|
755
|
-
return customFetch(
|
|
1229
|
+
const getClaimStatus = async (projectId, params, options) => {
|
|
1230
|
+
return customFetch(getGetClaimStatusUrl(projectId, params), {
|
|
756
1231
|
...options,
|
|
757
1232
|
method: "GET"
|
|
758
1233
|
});
|
|
759
1234
|
};
|
|
760
|
-
const
|
|
1235
|
+
const getCompleteClaimUrl = (projectId) => {
|
|
1236
|
+
return `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}/claim/complete`;
|
|
1237
|
+
};
|
|
1238
|
+
/**
|
|
1239
|
+
* Called by the browser after the developer authenticates on the claim page.
|
|
1240
|
+
* Authenticated by the `__nextgen_session` cookie, it attaches the project to
|
|
1241
|
+
* the developer's personal team using the `challenge_id` from the claim URL as
|
|
1242
|
+
* its single-use, browser-safe authorization.
|
|
1243
|
+
* @summary Complete a project claim
|
|
1244
|
+
*/
|
|
1245
|
+
const completeClaim = async (projectId, completeClaimBody, options) => {
|
|
1246
|
+
const getHeaders = (h) => {
|
|
1247
|
+
if (!h) return {};
|
|
1248
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1249
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
1250
|
+
const headers = {};
|
|
1251
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
1252
|
+
return headers;
|
|
1253
|
+
};
|
|
1254
|
+
return customFetch(getCompleteClaimUrl(projectId), {
|
|
1255
|
+
...options,
|
|
1256
|
+
method: "POST",
|
|
1257
|
+
headers: {
|
|
1258
|
+
"Content-Type": "application/json",
|
|
1259
|
+
...getHeaders(options?.headers)
|
|
1260
|
+
},
|
|
1261
|
+
body: JSON.stringify(completeClaimBody)
|
|
1262
|
+
});
|
|
1263
|
+
};
|
|
1264
|
+
const getGetClaimWindowUrl = (projectId, params) => {
|
|
761
1265
|
const normalizedParams = new URLSearchParams();
|
|
762
1266
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
763
|
-
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : value
|
|
1267
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
764
1268
|
});
|
|
765
1269
|
const stringifiedParams = normalizedParams.toString();
|
|
766
|
-
return stringifiedParams.length > 0 ? `${getProxyPath()}/
|
|
1270
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}/claim/window?${stringifiedParams}` : `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}/claim/window`;
|
|
767
1271
|
};
|
|
768
1272
|
/**
|
|
769
|
-
*
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
|
|
774
|
-
*
|
|
1273
|
+
* Read by the claim page in the browser to show how long is left to claim the
|
|
1274
|
+
* project. Unauthenticated by design: the claim page runs this before the
|
|
1275
|
+
* developer has signed in, and holding the `challenge_id` from the claim URL
|
|
1276
|
+
* is the authorization — the same capability `claim/complete` accepts. It
|
|
1277
|
+
* reveals only the window, never the project itself, and unlike
|
|
1278
|
+
* `claim/complete` it spends nothing, so a reload is free.
|
|
1279
|
+
* @summary Get the claim window for a project
|
|
775
1280
|
*/
|
|
776
|
-
const
|
|
777
|
-
return customFetch(
|
|
1281
|
+
const getClaimWindow = async (projectId, params, options) => {
|
|
1282
|
+
return customFetch(getGetClaimWindowUrl(projectId, params), {
|
|
778
1283
|
...options,
|
|
779
|
-
method: "
|
|
1284
|
+
method: "GET"
|
|
780
1285
|
});
|
|
781
1286
|
};
|
|
782
|
-
const
|
|
783
|
-
return `${getProxyPath()}/
|
|
1287
|
+
const getAddOriginUrl = (projectId) => {
|
|
1288
|
+
return `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}/origins`;
|
|
784
1289
|
};
|
|
785
1290
|
/**
|
|
786
|
-
*
|
|
787
|
-
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
against the same `session_id`) to restore a dropped assurance level.
|
|
792
|
-
|
|
793
|
-
* @summary Get my session state
|
|
1291
|
+
* Adds one `{pattern, kind}` to the project's origins. A primary pattern
|
|
1292
|
+
* must be an exact URL (no wildcard). Preview patterns may include a single
|
|
1293
|
+
* DNS-label wildcard. Adding a pattern that already exists with the same
|
|
1294
|
+
* kind is idempotent and answers 201 with the stored origin.
|
|
1295
|
+
* @summary Add an origin pattern
|
|
794
1296
|
*/
|
|
795
|
-
const
|
|
796
|
-
|
|
1297
|
+
const addOrigin = async (projectId, addOriginBody, options) => {
|
|
1298
|
+
const getHeaders = (h) => {
|
|
1299
|
+
if (!h) return {};
|
|
1300
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1301
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
1302
|
+
const headers = {};
|
|
1303
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
1304
|
+
return headers;
|
|
1305
|
+
};
|
|
1306
|
+
return customFetch(getAddOriginUrl(projectId), {
|
|
797
1307
|
...options,
|
|
798
|
-
method: "
|
|
1308
|
+
method: "POST",
|
|
1309
|
+
headers: {
|
|
1310
|
+
"Content-Type": "application/json",
|
|
1311
|
+
...getHeaders(options?.headers)
|
|
1312
|
+
},
|
|
1313
|
+
body: JSON.stringify(addOriginBody)
|
|
799
1314
|
});
|
|
800
1315
|
};
|
|
801
|
-
const
|
|
802
|
-
return `${getProxyPath()}/
|
|
1316
|
+
const getRemoveOriginUrl = (projectId) => {
|
|
1317
|
+
return `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}/origins/remove`;
|
|
803
1318
|
};
|
|
804
1319
|
/**
|
|
805
|
-
*
|
|
806
|
-
|
|
807
|
-
|
|
808
|
-
|
|
809
|
-
|
|
810
|
-
* @summary Revoke my session
|
|
1320
|
+
* Removes one pattern from the project's origins. Requests from URLs only
|
|
1321
|
+
* that pattern admitted are refused from then on; live previews and
|
|
1322
|
+
* deployment history are untouched. Removing a pattern that is already
|
|
1323
|
+
* absent is idempotent and answers 204.
|
|
1324
|
+
* @summary Remove an origin pattern
|
|
811
1325
|
*/
|
|
812
|
-
const
|
|
813
|
-
|
|
1326
|
+
const removeOrigin = async (projectId, removeOriginBody, options) => {
|
|
1327
|
+
const getHeaders = (h) => {
|
|
1328
|
+
if (!h) return {};
|
|
1329
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1330
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
1331
|
+
const headers = {};
|
|
1332
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
1333
|
+
return headers;
|
|
1334
|
+
};
|
|
1335
|
+
return customFetch(getRemoveOriginUrl(projectId), {
|
|
814
1336
|
...options,
|
|
815
|
-
method: "
|
|
1337
|
+
method: "POST",
|
|
1338
|
+
headers: {
|
|
1339
|
+
"Content-Type": "application/json",
|
|
1340
|
+
...getHeaders(options?.headers)
|
|
1341
|
+
},
|
|
1342
|
+
body: JSON.stringify(removeOriginBody)
|
|
1343
|
+
});
|
|
1344
|
+
};
|
|
1345
|
+
const getListPreviewsUrl = (projectId, params) => {
|
|
1346
|
+
const normalizedParams = new URLSearchParams();
|
|
1347
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
1348
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
1349
|
+
});
|
|
1350
|
+
const stringifiedParams = normalizedParams.toString();
|
|
1351
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}/previews?${stringifiedParams}` : `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}/previews`;
|
|
1352
|
+
};
|
|
1353
|
+
/**
|
|
1354
|
+
* Lists the project's live previews, newest first by `created_at`. An
|
|
1355
|
+
* expired or removed preview is not listed; what was deployed to it stays
|
|
1356
|
+
* in `GET /deployments`.
|
|
1357
|
+
* @summary List previews
|
|
1358
|
+
*/
|
|
1359
|
+
const listPreviews = async (projectId, params, options) => {
|
|
1360
|
+
return customFetch(getListPreviewsUrl(projectId, params), {
|
|
1361
|
+
...options,
|
|
1362
|
+
method: "GET"
|
|
1363
|
+
});
|
|
1364
|
+
};
|
|
1365
|
+
const getRemovePreviewUrl = (projectId) => {
|
|
1366
|
+
return `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}/previews/remove`;
|
|
1367
|
+
};
|
|
1368
|
+
/**
|
|
1369
|
+
* Ends a preview before it expires: the URL stops being served at once.
|
|
1370
|
+
* The deployments to it stay in the history.
|
|
1371
|
+
*
|
|
1372
|
+
* Idempotent: a URL with no live preview, including one that has already
|
|
1373
|
+
* expired or was removed before, answers `204` too, so a cleanup that
|
|
1374
|
+
* races the expiry still succeeds.
|
|
1375
|
+
*
|
|
1376
|
+
* The URL travels in the body rather than the path because an origin
|
|
1377
|
+
* contains `/`.
|
|
1378
|
+
* @summary Remove a preview
|
|
1379
|
+
*/
|
|
1380
|
+
const removePreview = async (projectId, removePreviewBody, options) => {
|
|
1381
|
+
const getHeaders = (h) => {
|
|
1382
|
+
if (!h) return {};
|
|
1383
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1384
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
1385
|
+
const headers = {};
|
|
1386
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
1387
|
+
return headers;
|
|
1388
|
+
};
|
|
1389
|
+
return customFetch(getRemovePreviewUrl(projectId), {
|
|
1390
|
+
...options,
|
|
1391
|
+
method: "POST",
|
|
1392
|
+
headers: {
|
|
1393
|
+
"Content-Type": "application/json",
|
|
1394
|
+
...getHeaders(options?.headers)
|
|
1395
|
+
},
|
|
1396
|
+
body: JSON.stringify(removePreviewBody)
|
|
1397
|
+
});
|
|
1398
|
+
};
|
|
1399
|
+
const getCreateSessionUrl = () => {
|
|
1400
|
+
return `${getProxyPath()}/sessions`;
|
|
1401
|
+
};
|
|
1402
|
+
/**
|
|
1403
|
+
* Creates an anonymous session shell with no user and no factors (`state: building`).
|
|
1404
|
+
*
|
|
1405
|
+
* This is optional — an `auth_attempt` will create a session implicitly if none is provided.
|
|
1406
|
+
* Use this explicitly when you want to:
|
|
1407
|
+
* - Pre-allocate a `session_id` before the user is known, so device/telemetry signals
|
|
1408
|
+
* can be correlated with the eventual authenticated session from the start.
|
|
1409
|
+
* - Track anonymous state (bot detection, device fingerprint) that survives until authentication.
|
|
1410
|
+
*
|
|
1411
|
+
* Creating a session is an app-plane operation on the project credential
|
|
1412
|
+
* (`session.write`). The returned `session_token` is a session credential for the
|
|
1413
|
+
* end-user client, not a management scope: it is delivered as the
|
|
1414
|
+
* `__nextgen_session` cookie and authorises the self-service operations
|
|
1415
|
+
* `GET /sessions/me` and `DELETE /sessions/me` (`nextgenSession` scheme). The
|
|
1416
|
+
* by-id operations `GET /sessions/{session_id}` and `DELETE /sessions/{session_id}`
|
|
1417
|
+
* are operator endpoints and require `session.read` / `session.delete` instead.
|
|
1418
|
+
*
|
|
1419
|
+
* The `session_token` is superseded when a handoff exchange completes — clients must
|
|
1420
|
+
* replace it at that point.
|
|
1421
|
+
*
|
|
1422
|
+
* Anonymous sessions expire aggressively (10-minute TTL). The TTL resets to the configured
|
|
1423
|
+
* full session TTL when the first authentication factor is written via a completing `auth_attempt`.
|
|
1424
|
+
* @summary Create an anonymous session shell
|
|
1425
|
+
*/
|
|
1426
|
+
const createSession = async (createSessionBody, options) => {
|
|
1427
|
+
const getHeaders = (h) => {
|
|
1428
|
+
if (!h) return {};
|
|
1429
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1430
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
1431
|
+
const headers = {};
|
|
1432
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
1433
|
+
return headers;
|
|
1434
|
+
};
|
|
1435
|
+
return customFetch(getCreateSessionUrl(), {
|
|
1436
|
+
...options,
|
|
1437
|
+
method: "POST",
|
|
1438
|
+
headers: {
|
|
1439
|
+
"Content-Type": "application/json",
|
|
1440
|
+
...getHeaders(options?.headers)
|
|
1441
|
+
},
|
|
1442
|
+
body: JSON.stringify(createSessionBody)
|
|
1443
|
+
});
|
|
1444
|
+
};
|
|
1445
|
+
const getQuerySessionsUrl = (params) => {
|
|
1446
|
+
const normalizedParams = new URLSearchParams();
|
|
1447
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
1448
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
1449
|
+
});
|
|
1450
|
+
const stringifiedParams = normalizedParams.toString();
|
|
1451
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/sessions/query?${stringifiedParams}` : `${getProxyPath()}/sessions/query`;
|
|
1452
|
+
};
|
|
1453
|
+
/**
|
|
1454
|
+
* Returns the sessions of a project, paginated with a cursor.
|
|
1455
|
+
* Sessions of every lifecycle state are returned; each carries its `state`.
|
|
1456
|
+
* Requires `session.read` permission.
|
|
1457
|
+
* @summary Query sessions
|
|
1458
|
+
*/
|
|
1459
|
+
const querySessions = async (querySessionsBody, params, options) => {
|
|
1460
|
+
const getHeaders = (h) => {
|
|
1461
|
+
if (!h) return {};
|
|
1462
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1463
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
1464
|
+
const headers = {};
|
|
1465
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
1466
|
+
return headers;
|
|
1467
|
+
};
|
|
1468
|
+
return customFetch(getQuerySessionsUrl(params), {
|
|
1469
|
+
...options,
|
|
1470
|
+
method: "POST",
|
|
1471
|
+
headers: {
|
|
1472
|
+
"Content-Type": "application/json",
|
|
1473
|
+
...getHeaders(options?.headers)
|
|
1474
|
+
},
|
|
1475
|
+
body: JSON.stringify(querySessionsBody)
|
|
1476
|
+
});
|
|
1477
|
+
};
|
|
1478
|
+
const getExchangeHandoffUrl = (params) => {
|
|
1479
|
+
const normalizedParams = new URLSearchParams();
|
|
1480
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
1481
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
1482
|
+
});
|
|
1483
|
+
const stringifiedParams = normalizedParams.toString();
|
|
1484
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/sessions/exchange?${stringifiedParams}` : `${getProxyPath()}/sessions/exchange`;
|
|
1485
|
+
};
|
|
1486
|
+
/**
|
|
1487
|
+
* Consumes a one-time `handoff_token` minted by `POST /auth_attempts/{id}/handoff`
|
|
1488
|
+
* and returns the resulting session and a `session_token`.
|
|
1489
|
+
*
|
|
1490
|
+
* The server resolves the originating `auth_attempt` from the token and then:
|
|
1491
|
+
*
|
|
1492
|
+
* | Originating auth_attempt | Outcome |
|
|
1493
|
+
* |---|---|
|
|
1494
|
+
* | No `session_id` | A new authenticated session is **created**. |
|
|
1495
|
+
* | `session_id` points to an anonymous shell | Existing session is **upgraded** — user and factors written in, TTL reset to full session TTL. |
|
|
1496
|
+
* | `session_id` points to an active session (step-up) | Existing session is **upgraded** — new factors merged, `assurance_levels[]` expanded. |
|
|
1497
|
+
*
|
|
1498
|
+
* The response shape is identical in all three cases.
|
|
1499
|
+
*
|
|
1500
|
+
* The `session_token` supersedes any previously issued `session_token` for the same session.
|
|
1501
|
+
* Clients must replace their stored token at this point.
|
|
1502
|
+
*
|
|
1503
|
+
* Requires a project service key (OAuth2 client credentials).
|
|
1504
|
+
*
|
|
1505
|
+
* The project comes from the project secret. A query `project_id` that
|
|
1506
|
+
* disagrees answers `403` with `proj.mismatch`. The exchange resolves a
|
|
1507
|
+
* deployment the same way as other runtime operations; with no browser
|
|
1508
|
+
* `Origin` and nothing deployed to the resolved target the response is
|
|
1509
|
+
* `409` with `rel.not_deployed`. A revoked release answers `409` with
|
|
1510
|
+
* `rel.revoked`.
|
|
1511
|
+
* @summary Exchange handoff token for a session
|
|
1512
|
+
*/
|
|
1513
|
+
const exchangeHandoff = async (exchangeHandoffBody, params, options) => {
|
|
1514
|
+
const getHeaders = (h) => {
|
|
1515
|
+
if (!h) return {};
|
|
1516
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1517
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
1518
|
+
const headers = {};
|
|
1519
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
1520
|
+
return headers;
|
|
1521
|
+
};
|
|
1522
|
+
return customFetch(getExchangeHandoffUrl(params), {
|
|
1523
|
+
...options,
|
|
1524
|
+
method: "POST",
|
|
1525
|
+
headers: {
|
|
1526
|
+
"Content-Type": "application/json",
|
|
1527
|
+
...getHeaders(options?.headers)
|
|
1528
|
+
},
|
|
1529
|
+
body: JSON.stringify(exchangeHandoffBody)
|
|
1530
|
+
});
|
|
1531
|
+
};
|
|
1532
|
+
const getGetSessionUrl = (sessionId) => {
|
|
1533
|
+
return `${getProxyPath()}/sessions/${encodeURIComponent(String(sessionId))}`;
|
|
1534
|
+
};
|
|
1535
|
+
/**
|
|
1536
|
+
* Returns the current state of a session including its factors and all currently
|
|
1537
|
+
* satisfied assurance levels.
|
|
1538
|
+
*
|
|
1539
|
+
* `assurance_levels[]` may shrink over time as factor freshness windows expire,
|
|
1540
|
+
* without the session itself expiring. Use step-up authentication (a new `auth_attempt`
|
|
1541
|
+
* against the same `session_id`) to restore a dropped assurance level.
|
|
1542
|
+
* @summary Get session state
|
|
1543
|
+
*/
|
|
1544
|
+
const getSession = async (sessionId, options) => {
|
|
1545
|
+
return customFetch(getGetSessionUrl(sessionId), {
|
|
1546
|
+
...options,
|
|
1547
|
+
method: "GET"
|
|
1548
|
+
});
|
|
1549
|
+
};
|
|
1550
|
+
const getRevokeSessionUrl = (sessionId) => {
|
|
1551
|
+
return `${getProxyPath()}/sessions/${encodeURIComponent(String(sessionId))}`;
|
|
1552
|
+
};
|
|
1553
|
+
/**
|
|
1554
|
+
* Permanently deletes the session, terminating it immediately.
|
|
1555
|
+
*
|
|
1556
|
+
* This is the operator revoke path and requires the `session.delete` scope on a
|
|
1557
|
+
* project-bound credential. End-user logout with the `__nextgen_session` cookie is
|
|
1558
|
+
* `DELETE /sessions/me` (`nextgenSession` scheme).
|
|
1559
|
+
*
|
|
1560
|
+
* Idempotent: deleting a session that does not exist (or was already deleted)
|
|
1561
|
+
* still returns 204. After deletion, any tokens derived from the session are
|
|
1562
|
+
* invalidated.
|
|
1563
|
+
* @summary Revoke session
|
|
1564
|
+
*/
|
|
1565
|
+
const revokeSession = async (sessionId, options) => {
|
|
1566
|
+
return customFetch(getRevokeSessionUrl(sessionId), {
|
|
1567
|
+
...options,
|
|
1568
|
+
method: "DELETE"
|
|
1569
|
+
});
|
|
1570
|
+
};
|
|
1571
|
+
const getGetMySessionUrl = (params) => {
|
|
1572
|
+
const normalizedParams = new URLSearchParams();
|
|
1573
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
1574
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
1575
|
+
});
|
|
1576
|
+
const stringifiedParams = normalizedParams.toString();
|
|
1577
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/sessions/me?${stringifiedParams}` : `${getProxyPath()}/sessions/me`;
|
|
1578
|
+
};
|
|
1579
|
+
/**
|
|
1580
|
+
* Returns the current state of the current session including its factors and all currently
|
|
1581
|
+
* satisfied assurance levels.
|
|
1582
|
+
*
|
|
1583
|
+
* With `project_id`, the session is returned only when it belongs to that project.
|
|
1584
|
+
*
|
|
1585
|
+
* `assurance_levels[]` may shrink over time as factor freshness windows expire,
|
|
1586
|
+
* without the session itself expiring. Use step-up authentication (a new `auth_attempt`
|
|
1587
|
+
* against the same `session_id`) to restore a dropped assurance level.
|
|
1588
|
+
* @summary Get my session state
|
|
1589
|
+
*/
|
|
1590
|
+
const getMySession = async (params, options) => {
|
|
1591
|
+
return customFetch(getGetMySessionUrl(params), {
|
|
1592
|
+
...options,
|
|
1593
|
+
method: "GET"
|
|
1594
|
+
});
|
|
1595
|
+
};
|
|
1596
|
+
const getRevokeMySessionUrl = (params) => {
|
|
1597
|
+
const normalizedParams = new URLSearchParams();
|
|
1598
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
1599
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
1600
|
+
});
|
|
1601
|
+
const stringifiedParams = normalizedParams.toString();
|
|
1602
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/sessions/me?${stringifiedParams}` : `${getProxyPath()}/sessions/me`;
|
|
1603
|
+
};
|
|
1604
|
+
/**
|
|
1605
|
+
* Logs out by permanently deleting the session.
|
|
1606
|
+
*
|
|
1607
|
+
* The `__nextgen_session` cookie issued at creation (or superseded by a handoff
|
|
1608
|
+
* exchange) is required, with the session's token from `GET /sessions/me/csrf`
|
|
1609
|
+
* in the `X-Zitadel-CSRF` header. Idempotent: if the session is already gone
|
|
1610
|
+
* this still returns 204. Any tokens derived from the session are invalidated,
|
|
1611
|
+
* and the cookie itself is cleared in the response.
|
|
1612
|
+
*
|
|
1613
|
+
* With `project_id`, only a session of that project is deleted. A session of
|
|
1614
|
+
* another project is left alone, and so is its cookie.
|
|
1615
|
+
* @summary Revoke my session
|
|
1616
|
+
*/
|
|
1617
|
+
const revokeMySession = async (params, options) => {
|
|
1618
|
+
return customFetch(getRevokeMySessionUrl(params), {
|
|
1619
|
+
...options,
|
|
1620
|
+
method: "DELETE"
|
|
1621
|
+
});
|
|
1622
|
+
};
|
|
1623
|
+
const getGetMySessionCsrfTokenUrl = (params) => {
|
|
1624
|
+
const normalizedParams = new URLSearchParams();
|
|
1625
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
1626
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
1627
|
+
});
|
|
1628
|
+
const stringifiedParams = normalizedParams.toString();
|
|
1629
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/sessions/me/csrf?${stringifiedParams}` : `${getProxyPath()}/sessions/me/csrf`;
|
|
1630
|
+
};
|
|
1631
|
+
/**
|
|
1632
|
+
* Returns the session-bound token for cross-site request forgery protection
|
|
1633
|
+
* (ADR 053 §5). Browser code sends it in the `X-Zitadel-CSRF` header on the
|
|
1634
|
+
* state-changing requests the session cookie authenticates that require it
|
|
1635
|
+
* — see the `nextgenSession` scheme. It authorizes nothing on its own: the
|
|
1636
|
+
* HttpOnly cookie is still the credential, and a cross-site page cannot
|
|
1637
|
+
* read this response. It stays the same for the life of the session, so a
|
|
1638
|
+
* client fetches it once per session.
|
|
1639
|
+
*
|
|
1640
|
+
* With `project_id`, the token is returned only when the session belongs to
|
|
1641
|
+
* that project.
|
|
1642
|
+
* @summary Get my session's CSRF token
|
|
1643
|
+
*/
|
|
1644
|
+
const getMySessionCsrfToken = async (params, options) => {
|
|
1645
|
+
return customFetch(getGetMySessionCsrfTokenUrl(params), {
|
|
1646
|
+
...options,
|
|
1647
|
+
method: "GET"
|
|
816
1648
|
});
|
|
817
1649
|
};
|
|
818
1650
|
const getCreateSchemaUrl = (params) => {
|
|
819
1651
|
const normalizedParams = new URLSearchParams();
|
|
820
1652
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
821
|
-
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : value
|
|
1653
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
822
1654
|
});
|
|
823
1655
|
const stringifiedParams = normalizedParams.toString();
|
|
824
1656
|
return stringifiedParams.length > 0 ? `${getProxyPath()}/schemas?${stringifiedParams}` : `${getProxyPath()}/schemas`;
|
|
825
1657
|
};
|
|
826
1658
|
/**
|
|
827
|
-
* Create a new schema. The
|
|
828
|
-
|
|
829
|
-
|
|
830
|
-
|
|
831
|
-
|
|
832
|
-
|
|
833
|
-
|
|
834
|
-
|
|
1659
|
+
* Create a new schema. The optional `$id` field is the JSON Schema document
|
|
1660
|
+
* URI used to identify the schema in future requests (GitOps-stable identity,
|
|
1661
|
+
* not a free-form resource primary key). When `$id` is omitted, the server
|
|
1662
|
+
* generates a `sch_*` URL. When provided, `$id` must be unique within the
|
|
1663
|
+
* project and should ideally be a valid URI pointing at where the schema can
|
|
1664
|
+
* be accessed.
|
|
1665
|
+
*
|
|
1666
|
+
* The schema can either be a concrete schema, e.g. a user schema, or a
|
|
1667
|
+
* schema-url which will be resolved by the server.
|
|
835
1668
|
* @summary Create new schema
|
|
836
1669
|
*/
|
|
837
1670
|
const createSchema = async (createSchemaBody, params, options) => {
|
|
1671
|
+
const getHeaders = (h) => {
|
|
1672
|
+
if (!h) return {};
|
|
1673
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1674
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
1675
|
+
const headers = {};
|
|
1676
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
1677
|
+
return headers;
|
|
1678
|
+
};
|
|
838
1679
|
return customFetch(getCreateSchemaUrl(params), {
|
|
839
1680
|
...options,
|
|
840
1681
|
method: "POST",
|
|
841
1682
|
headers: {
|
|
842
1683
|
"Content-Type": "application/json",
|
|
843
|
-
...options?.headers
|
|
1684
|
+
...getHeaders(options?.headers)
|
|
844
1685
|
},
|
|
845
1686
|
body: JSON.stringify(createSchemaBody)
|
|
846
1687
|
});
|
|
847
1688
|
};
|
|
1689
|
+
const getListSchemasUrl = (params) => {
|
|
1690
|
+
const normalizedParams = new URLSearchParams();
|
|
1691
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
1692
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
1693
|
+
});
|
|
1694
|
+
const stringifiedParams = normalizedParams.toString();
|
|
1695
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/schemas?${stringifiedParams}` : `${getProxyPath()}/schemas`;
|
|
1696
|
+
};
|
|
1697
|
+
/**
|
|
1698
|
+
* Retrieve a list of all schemas available in the system. This endpoint
|
|
1699
|
+
* supports pagination and filtering based on schema attributes.
|
|
1700
|
+
* @summary List all schemas
|
|
1701
|
+
*/
|
|
1702
|
+
const listSchemas = async (params, options) => {
|
|
1703
|
+
return customFetch(getListSchemasUrl(params), {
|
|
1704
|
+
...options,
|
|
1705
|
+
method: "GET"
|
|
1706
|
+
});
|
|
1707
|
+
};
|
|
848
1708
|
const getGetSchemaByIdUrl = (id, params) => {
|
|
849
1709
|
const normalizedParams = new URLSearchParams();
|
|
850
1710
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
851
|
-
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : value
|
|
1711
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
852
1712
|
});
|
|
853
1713
|
const stringifiedParams = normalizedParams.toString();
|
|
854
|
-
return stringifiedParams.length > 0 ? `${getProxyPath()}/schemas/${id}?${stringifiedParams}` : `${getProxyPath()}/schemas/${id}`;
|
|
1714
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/schemas/${encodeURIComponent(String(id))}?${stringifiedParams}` : `${getProxyPath()}/schemas/${encodeURIComponent(String(id))}`;
|
|
855
1715
|
};
|
|
856
1716
|
/**
|
|
857
|
-
* Get a schema by its ID.
|
|
1717
|
+
* Get a schema by its ID. A schema ID identifies one immutable revision, so
|
|
1718
|
+
* this returns exactly that revision. To find the current revision of an
|
|
1719
|
+
* object type, list with `revisions=latest`.
|
|
1720
|
+
*
|
|
1721
|
+
* Schema IDs are unique within a project, not across projects (the seeded
|
|
1722
|
+
* default schema carries the same `$id` in every project). A Console
|
|
1723
|
+
* session that manages more than one project names the project with
|
|
1724
|
+
* `project_id`; without it, the ID is resolved in the credential's own
|
|
1725
|
+
* project when it is ambiguous. A project secret always resolves in its
|
|
1726
|
+
* own project and ignores `project_id`.
|
|
858
1727
|
* @summary Get schema by ID
|
|
859
1728
|
*/
|
|
860
1729
|
const getSchemaById = async (id, params, options) => {
|
|
@@ -867,21 +1736,33 @@ const getCreateFlowDefinitionUrl = () => {
|
|
|
867
1736
|
return `${getProxyPath()}/flow_definitions`;
|
|
868
1737
|
};
|
|
869
1738
|
/**
|
|
870
|
-
*
|
|
871
|
-
Flow definitions are templates that define the sequence of steps (capabilities)
|
|
872
|
-
for a particular user journey (e.g., registration, login, password reset).
|
|
873
|
-
|
|
874
|
-
Flow definitions are created based on the flow
|
|
875
|
-
|
|
1739
|
+
* Publishes a new flow definition revision.
|
|
1740
|
+
* Flow definitions are templates that define the sequence of steps (capabilities)
|
|
1741
|
+
* for a particular user journey (e.g., registration, login, password reset).
|
|
1742
|
+
*
|
|
1743
|
+
* Flow definitions are created based on the flow definition schema, which includes the flow's purpose, audience, and the steps involved.
|
|
1744
|
+
*
|
|
1745
|
+
* Every call allocates a new opaque id. Revisions of one flow share its
|
|
1746
|
+
* `name`; posting a definition under an existing `name` publishes a new
|
|
1747
|
+
* revision of that flow, it is not a conflict. List with `name` to see a
|
|
1748
|
+
* flow's revisions, newest by creation time first.
|
|
876
1749
|
* @summary Create a new flow definition
|
|
877
1750
|
*/
|
|
878
1751
|
const createFlowDefinition = async (createFlowDefinitionBody, options) => {
|
|
1752
|
+
const getHeaders = (h) => {
|
|
1753
|
+
if (!h) return {};
|
|
1754
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1755
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
1756
|
+
const headers = {};
|
|
1757
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
1758
|
+
return headers;
|
|
1759
|
+
};
|
|
879
1760
|
return customFetch(getCreateFlowDefinitionUrl(), {
|
|
880
1761
|
...options,
|
|
881
1762
|
method: "POST",
|
|
882
1763
|
headers: {
|
|
883
1764
|
"Content-Type": "application/json",
|
|
884
|
-
...options?.headers
|
|
1765
|
+
...getHeaders(options?.headers)
|
|
885
1766
|
},
|
|
886
1767
|
body: JSON.stringify(createFlowDefinitionBody)
|
|
887
1768
|
});
|
|
@@ -889,15 +1770,21 @@ const createFlowDefinition = async (createFlowDefinitionBody, options) => {
|
|
|
889
1770
|
const getListFlowDefinitionsUrl = (params) => {
|
|
890
1771
|
const normalizedParams = new URLSearchParams();
|
|
891
1772
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
892
|
-
if (
|
|
1773
|
+
if (Array.isArray(value) && ["expand"].includes(key)) {
|
|
1774
|
+
value.forEach((v) => {
|
|
1775
|
+
normalizedParams.append(key, v === null ? "null" : String(v));
|
|
1776
|
+
});
|
|
1777
|
+
return;
|
|
1778
|
+
}
|
|
1779
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
893
1780
|
});
|
|
894
1781
|
const stringifiedParams = normalizedParams.toString();
|
|
895
1782
|
return stringifiedParams.length > 0 ? `${getProxyPath()}/flow_definitions?${stringifiedParams}` : `${getProxyPath()}/flow_definitions`;
|
|
896
1783
|
};
|
|
897
1784
|
/**
|
|
898
|
-
* Retrieves a list of all flow definitions.
|
|
899
|
-
This endpoint can be used to view existing flow definitions and their configurations.
|
|
900
|
-
|
|
1785
|
+
* Retrieves a list of all flow definitions, newest by creation time first.
|
|
1786
|
+
* This endpoint can be used to view existing flow definitions and their configurations.
|
|
1787
|
+
* Filter by `name` to list the revisions of one flow.
|
|
901
1788
|
* @summary List flow definitions
|
|
902
1789
|
*/
|
|
903
1790
|
const listFlowDefinitions = async (params, options) => {
|
|
@@ -906,107 +1793,1227 @@ const listFlowDefinitions = async (params, options) => {
|
|
|
906
1793
|
method: "GET"
|
|
907
1794
|
});
|
|
908
1795
|
};
|
|
909
|
-
const getGetFlowDefinitionUrl = (id
|
|
1796
|
+
const getGetFlowDefinitionUrl = (id) => {
|
|
1797
|
+
return `${getProxyPath()}/flow_definitions/${encodeURIComponent(String(id))}`;
|
|
1798
|
+
};
|
|
1799
|
+
/**
|
|
1800
|
+
* Get a flow definition by id
|
|
1801
|
+
* @summary Get a flow definition by id
|
|
1802
|
+
*/
|
|
1803
|
+
const getFlowDefinition = async (id, options) => {
|
|
1804
|
+
return customFetch(getGetFlowDefinitionUrl(id), {
|
|
1805
|
+
...options,
|
|
1806
|
+
method: "GET"
|
|
1807
|
+
});
|
|
1808
|
+
};
|
|
1809
|
+
const getCreateTeamUrl = (params) => {
|
|
910
1810
|
const normalizedParams = new URLSearchParams();
|
|
911
1811
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
912
|
-
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : value
|
|
1812
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
913
1813
|
});
|
|
914
1814
|
const stringifiedParams = normalizedParams.toString();
|
|
915
|
-
return stringifiedParams.length > 0 ? `${getProxyPath()}/
|
|
1815
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/teams?${stringifiedParams}` : `${getProxyPath()}/teams`;
|
|
916
1816
|
};
|
|
917
1817
|
/**
|
|
918
|
-
*
|
|
919
|
-
*
|
|
1818
|
+
* Creates a team in the project, with a name no other team in the project has.
|
|
1819
|
+
*
|
|
1820
|
+
* A taken name is refused with `409 team.already_exists`. The new team has no
|
|
1821
|
+
* members yet.
|
|
1822
|
+
* @summary Create team
|
|
920
1823
|
*/
|
|
921
|
-
const
|
|
922
|
-
|
|
1824
|
+
const createTeam = async (createTeamBody, params, options) => {
|
|
1825
|
+
const getHeaders = (h) => {
|
|
1826
|
+
if (!h) return {};
|
|
1827
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1828
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
1829
|
+
const headers = {};
|
|
1830
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
1831
|
+
return headers;
|
|
1832
|
+
};
|
|
1833
|
+
return customFetch(getCreateTeamUrl(params), {
|
|
923
1834
|
...options,
|
|
924
|
-
method: "
|
|
1835
|
+
method: "POST",
|
|
1836
|
+
headers: {
|
|
1837
|
+
"Content-Type": "application/json",
|
|
1838
|
+
...getHeaders(options?.headers)
|
|
1839
|
+
},
|
|
1840
|
+
body: JSON.stringify(createTeamBody)
|
|
925
1841
|
});
|
|
926
1842
|
};
|
|
927
|
-
const
|
|
1843
|
+
const getQueryTeamsUrl = (params) => {
|
|
928
1844
|
const normalizedParams = new URLSearchParams();
|
|
929
1845
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
930
|
-
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : value
|
|
1846
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
931
1847
|
});
|
|
932
1848
|
const stringifiedParams = normalizedParams.toString();
|
|
933
|
-
return stringifiedParams.length > 0 ? `${getProxyPath()}/
|
|
1849
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/teams/query?${stringifiedParams}` : `${getProxyPath()}/teams/query`;
|
|
1850
|
+
};
|
|
1851
|
+
/**
|
|
1852
|
+
* Returns the teams of a project, paginated with a cursor.
|
|
1853
|
+
* @summary Query teams
|
|
1854
|
+
*/
|
|
1855
|
+
const queryTeams = async (queryTeamsBody, params, options) => {
|
|
1856
|
+
const getHeaders = (h) => {
|
|
1857
|
+
if (!h) return {};
|
|
1858
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1859
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
1860
|
+
const headers = {};
|
|
1861
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
1862
|
+
return headers;
|
|
1863
|
+
};
|
|
1864
|
+
return customFetch(getQueryTeamsUrl(params), {
|
|
1865
|
+
...options,
|
|
1866
|
+
method: "POST",
|
|
1867
|
+
headers: {
|
|
1868
|
+
"Content-Type": "application/json",
|
|
1869
|
+
...getHeaders(options?.headers)
|
|
1870
|
+
},
|
|
1871
|
+
body: JSON.stringify(queryTeamsBody)
|
|
1872
|
+
});
|
|
1873
|
+
};
|
|
1874
|
+
const getGetTeamUrl = (teamId) => {
|
|
1875
|
+
return `${getProxyPath()}/teams/${encodeURIComponent(String(teamId))}`;
|
|
1876
|
+
};
|
|
1877
|
+
/**
|
|
1878
|
+
* Returns a Team by its id.
|
|
1879
|
+
* @summary Get team
|
|
1880
|
+
*/
|
|
1881
|
+
const getTeam = async (teamId, options) => {
|
|
1882
|
+
return customFetch(getGetTeamUrl(teamId), {
|
|
1883
|
+
...options,
|
|
1884
|
+
method: "GET"
|
|
1885
|
+
});
|
|
1886
|
+
};
|
|
1887
|
+
const getDeleteTeamUrl = (teamId) => {
|
|
1888
|
+
return `${getProxyPath()}/teams/${encodeURIComponent(String(teamId))}`;
|
|
1889
|
+
};
|
|
1890
|
+
/**
|
|
1891
|
+
* Deactivates the team.
|
|
1892
|
+
*
|
|
1893
|
+
* The team is tombstoned rather than erased: it stays readable through
|
|
1894
|
+
* getTeam with status `deactivated`. Its memberships are removed and the
|
|
1895
|
+
* users whose lifecycle it owns are deactivated with it.
|
|
1896
|
+
*
|
|
1897
|
+
* The request is idempotent. Deleting a team that is already deactivated
|
|
1898
|
+
* or doesn't exist succeeds without changing anything.
|
|
1899
|
+
*
|
|
1900
|
+
* A team that still owns a project is refused with `409
|
|
1901
|
+
* team.owns_project`: deactivating it would leave the project owned by a
|
|
1902
|
+
* dead team and so unmanageable. No endpoint releases that ownership yet,
|
|
1903
|
+
* so such a team cannot currently be deactivated through the API.
|
|
1904
|
+
* @summary Delete team
|
|
1905
|
+
*/
|
|
1906
|
+
const deleteTeam = async (teamId, options) => {
|
|
1907
|
+
return customFetch(getDeleteTeamUrl(teamId), {
|
|
1908
|
+
...options,
|
|
1909
|
+
method: "DELETE"
|
|
1910
|
+
});
|
|
1911
|
+
};
|
|
1912
|
+
const getUpdateTeamUrl = (teamId) => {
|
|
1913
|
+
return `${getProxyPath()}/teams/${encodeURIComponent(String(teamId))}`;
|
|
934
1914
|
};
|
|
935
1915
|
/**
|
|
936
|
-
* Update
|
|
937
|
-
* @summary Update
|
|
1916
|
+
* Update team. Only active teams can be updated.
|
|
1917
|
+
* @summary Update team
|
|
938
1918
|
*/
|
|
939
|
-
const
|
|
940
|
-
|
|
1919
|
+
const updateTeam = async (teamId, updateTeamBody, options) => {
|
|
1920
|
+
const getHeaders = (h) => {
|
|
1921
|
+
if (!h) return {};
|
|
1922
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1923
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
1924
|
+
const headers = {};
|
|
1925
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
1926
|
+
return headers;
|
|
1927
|
+
};
|
|
1928
|
+
return customFetch(getUpdateTeamUrl(teamId), {
|
|
941
1929
|
...options,
|
|
942
1930
|
method: "PATCH",
|
|
943
1931
|
headers: {
|
|
944
1932
|
"Content-Type": "application/json",
|
|
945
|
-
...options?.headers
|
|
1933
|
+
...getHeaders(options?.headers)
|
|
946
1934
|
},
|
|
947
|
-
body: JSON.stringify(
|
|
1935
|
+
body: JSON.stringify(updateTeamBody)
|
|
948
1936
|
});
|
|
949
1937
|
};
|
|
950
|
-
const
|
|
1938
|
+
const getCreateBrandingUrl = (params) => {
|
|
951
1939
|
const normalizedParams = new URLSearchParams();
|
|
952
1940
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
953
|
-
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : value
|
|
1941
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
954
1942
|
});
|
|
955
1943
|
const stringifiedParams = normalizedParams.toString();
|
|
956
|
-
return stringifiedParams.length > 0 ? `${getProxyPath()}/
|
|
1944
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/branding?${stringifiedParams}` : `${getProxyPath()}/branding`;
|
|
957
1945
|
};
|
|
958
1946
|
/**
|
|
959
|
-
*
|
|
960
|
-
*
|
|
1947
|
+
* Publishes a new immutable branding revision for the project. Branding
|
|
1948
|
+
* revisions cannot be updated or deleted; every edit publishes a new
|
|
1949
|
+
* revision, and flow responses resolve the latest revision per project.
|
|
1950
|
+
*
|
|
1951
|
+
* The `liquid_template` is validated lexically on save (size, encoding,
|
|
1952
|
+
* banned patterns such as `<script>` tags, inline event handlers, and the
|
|
1953
|
+
* `| raw` filter). Authoritative LiquidJS validation runs at authoring
|
|
1954
|
+
* time via `zitadel plan` / `zitadel apply`.
|
|
1955
|
+
* @summary Publish a new branding revision
|
|
961
1956
|
*/
|
|
962
|
-
const
|
|
963
|
-
|
|
1957
|
+
const createBranding = async (createBrandingBody, params, options) => {
|
|
1958
|
+
const getHeaders = (h) => {
|
|
1959
|
+
if (!h) return {};
|
|
1960
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1961
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
1962
|
+
const headers = {};
|
|
1963
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
1964
|
+
return headers;
|
|
1965
|
+
};
|
|
1966
|
+
return customFetch(getCreateBrandingUrl(params), {
|
|
964
1967
|
...options,
|
|
965
|
-
method: "
|
|
1968
|
+
method: "POST",
|
|
1969
|
+
headers: {
|
|
1970
|
+
"Content-Type": "application/json",
|
|
1971
|
+
...getHeaders(options?.headers)
|
|
1972
|
+
},
|
|
1973
|
+
body: JSON.stringify(createBrandingBody)
|
|
966
1974
|
});
|
|
967
1975
|
};
|
|
968
|
-
const
|
|
1976
|
+
const getListBrandingUrl = (params) => {
|
|
969
1977
|
const normalizedParams = new URLSearchParams();
|
|
970
1978
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
971
|
-
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : value
|
|
1979
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
972
1980
|
});
|
|
973
1981
|
const stringifiedParams = normalizedParams.toString();
|
|
974
|
-
return stringifiedParams.length > 0 ? `${getProxyPath()}/
|
|
1982
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/branding?${stringifiedParams}` : `${getProxyPath()}/branding`;
|
|
975
1983
|
};
|
|
976
1984
|
/**
|
|
977
|
-
*
|
|
1985
|
+
* Lists branding revisions for the project, newest first, capped at the
|
|
1986
|
+
* 100 most recent. The first entry is the revision flow responses
|
|
1987
|
+
* currently resolve. Deliberately unpaginated in v1 — list endpoints gain a
|
|
1988
|
+
* real query mechanism together; advertising pagination parameters the
|
|
1989
|
+
* server ignores would be worse than none.
|
|
1990
|
+
* @summary List branding revisions
|
|
978
1991
|
*/
|
|
979
|
-
const
|
|
980
|
-
return customFetch(
|
|
1992
|
+
const listBranding = async (params, options) => {
|
|
1993
|
+
return customFetch(getListBrandingUrl(params), {
|
|
1994
|
+
...options,
|
|
1995
|
+
method: "GET"
|
|
1996
|
+
});
|
|
1997
|
+
};
|
|
1998
|
+
const getGetBrandingByIdUrl = (id) => {
|
|
1999
|
+
return `${getProxyPath()}/branding/${encodeURIComponent(String(id))}`;
|
|
2000
|
+
};
|
|
2001
|
+
/**
|
|
2002
|
+
* Retrieves a single branding revision, including its stored configuration.
|
|
2003
|
+
* @summary Get a branding revision by ID
|
|
2004
|
+
*/
|
|
2005
|
+
const getBrandingById = async (id, options) => {
|
|
2006
|
+
return customFetch(getGetBrandingByIdUrl(id), {
|
|
2007
|
+
...options,
|
|
2008
|
+
method: "GET"
|
|
2009
|
+
});
|
|
2010
|
+
};
|
|
2011
|
+
const getCreateIdpUrl = (params) => {
|
|
2012
|
+
const normalizedParams = new URLSearchParams();
|
|
2013
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2014
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2015
|
+
});
|
|
2016
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2017
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/idps?${stringifiedParams}` : `${getProxyPath()}/idps`;
|
|
2018
|
+
};
|
|
2019
|
+
/**
|
|
2020
|
+
* Creates or revises a connection document. If the slug does not already
|
|
2021
|
+
* exist, a new connection is created. If a connection with that slug already
|
|
2022
|
+
* exists, a revision is created.
|
|
2023
|
+
*
|
|
2024
|
+
* A revision gets a new `revision_id` and does not modify the connection
|
|
2025
|
+
* `id`, so identity links that reference the connection keep resolving while
|
|
2026
|
+
* releases and auth attempts stay pinned to the revision they captured.
|
|
2027
|
+
*
|
|
2028
|
+
* Identity fields are fixed for the life of the connection and a revision
|
|
2029
|
+
* that changes one is rejected: `protocol`, `subject_claim`, and `issuer`,
|
|
2030
|
+
* the field that names the authority. Their values decide which provider
|
|
2031
|
+
* account a stored subject belongs to, so changing one would silently
|
|
2032
|
+
* repoint existing identities at a different provider.
|
|
2033
|
+
*
|
|
2034
|
+
* `subject_claim` is optional, and `sub` is used as the default value. If a
|
|
2035
|
+
* revision updates `subject_claim` to a different value than the one set
|
|
2036
|
+
* during creation, the request is rejected.
|
|
2037
|
+
*
|
|
2038
|
+
* OIDC is the only protocol.
|
|
2039
|
+
*
|
|
2040
|
+
* The document is validated against the `idp-connection.json` schema before
|
|
2041
|
+
* anything is stored. The rules the engine applies when it starts a sign-in
|
|
2042
|
+
* then run on the document, so a connection that could never start one is
|
|
2043
|
+
* refused here instead with `idp.endpoints_partial`: the OIDC block sets an
|
|
2044
|
+
* endpoint without the others. It either sets no endpoint, and discovery
|
|
2045
|
+
* fills them, or sets `authorization_endpoint`, `token_endpoint`, `jwks_uri`,
|
|
2046
|
+
* and `userinfo_endpoint`. `userinfo_endpoint` may be left out when
|
|
2047
|
+
* `id_token_mapping` is on, but setting it alone still counts as setting an
|
|
2048
|
+
* endpoint. The details list the missing endpoints.
|
|
2049
|
+
*
|
|
2050
|
+
* A refused document stores nothing, and on a revise the current revision
|
|
2051
|
+
* stays unchanged.
|
|
2052
|
+
* @summary Create or revise an identity provider connection
|
|
2053
|
+
*/
|
|
2054
|
+
const createIdp = async (createIdpBody, params, options) => {
|
|
2055
|
+
const getHeaders = (h) => {
|
|
2056
|
+
if (!h) return {};
|
|
2057
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
2058
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
2059
|
+
const headers = {};
|
|
2060
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
2061
|
+
return headers;
|
|
2062
|
+
};
|
|
2063
|
+
return customFetch(getCreateIdpUrl(params), {
|
|
981
2064
|
...options,
|
|
982
2065
|
method: "POST",
|
|
983
2066
|
headers: {
|
|
984
2067
|
"Content-Type": "application/json",
|
|
985
|
-
...options?.headers
|
|
2068
|
+
...getHeaders(options?.headers)
|
|
986
2069
|
},
|
|
987
|
-
body: JSON.stringify(
|
|
2070
|
+
body: JSON.stringify(createIdpBody)
|
|
988
2071
|
});
|
|
989
2072
|
};
|
|
990
|
-
const
|
|
2073
|
+
const getQueryIdpsUrl = (params) => {
|
|
991
2074
|
const normalizedParams = new URLSearchParams();
|
|
992
2075
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
993
|
-
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : value
|
|
2076
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
994
2077
|
});
|
|
995
2078
|
const stringifiedParams = normalizedParams.toString();
|
|
996
|
-
return stringifiedParams.length > 0 ? `${getProxyPath()}/
|
|
2079
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/idps/query?${stringifiedParams}` : `${getProxyPath()}/idps/query`;
|
|
997
2080
|
};
|
|
998
2081
|
/**
|
|
999
|
-
* Returns the
|
|
1000
|
-
|
|
1001
|
-
* @summary
|
|
2082
|
+
* Returns the identity provider connections of a project, paginated with a
|
|
2083
|
+
* cursor. One row per connection, carrying its newest revision.
|
|
2084
|
+
* @summary Query identity provider connections
|
|
2085
|
+
*/
|
|
2086
|
+
const queryIdps = async (queryIdpsBody, params, options) => {
|
|
2087
|
+
const getHeaders = (h) => {
|
|
2088
|
+
if (!h) return {};
|
|
2089
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
2090
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
2091
|
+
const headers = {};
|
|
2092
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
2093
|
+
return headers;
|
|
2094
|
+
};
|
|
2095
|
+
return customFetch(getQueryIdpsUrl(params), {
|
|
2096
|
+
...options,
|
|
2097
|
+
method: "POST",
|
|
2098
|
+
headers: {
|
|
2099
|
+
"Content-Type": "application/json",
|
|
2100
|
+
...getHeaders(options?.headers)
|
|
2101
|
+
},
|
|
2102
|
+
body: JSON.stringify(queryIdpsBody)
|
|
2103
|
+
});
|
|
2104
|
+
};
|
|
2105
|
+
const getGetIdpByIdUrl = (id, params) => {
|
|
2106
|
+
const normalizedParams = new URLSearchParams();
|
|
2107
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2108
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2109
|
+
});
|
|
2110
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2111
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/idps/${encodeURIComponent(String(id))}?${stringifiedParams}` : `${getProxyPath()}/idps/${encodeURIComponent(String(id))}`;
|
|
2112
|
+
};
|
|
2113
|
+
/**
|
|
2114
|
+
* Reads a connection by its id, at its newest revision.
|
|
2115
|
+
* `GET /idps/{id}/revisions` lists every revision of the connection.
|
|
2116
|
+
*
|
|
2117
|
+
* The lookup is scoped to the project in `project_id`.
|
|
2118
|
+
* @summary Get an identity provider connection by id
|
|
2119
|
+
*/
|
|
2120
|
+
const getIdpById = async (id, params, options) => {
|
|
2121
|
+
return customFetch(getGetIdpByIdUrl(id, params), {
|
|
2122
|
+
...options,
|
|
2123
|
+
method: "GET"
|
|
2124
|
+
});
|
|
2125
|
+
};
|
|
2126
|
+
const getListIdpRevisionsUrl = (id, params) => {
|
|
2127
|
+
const normalizedParams = new URLSearchParams();
|
|
2128
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2129
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2130
|
+
});
|
|
2131
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2132
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/idps/${encodeURIComponent(String(id))}/revisions?${stringifiedParams}` : `${getProxyPath()}/idps/${encodeURIComponent(String(id))}/revisions`;
|
|
2133
|
+
};
|
|
2134
|
+
/**
|
|
2135
|
+
* Returns every revision of one connection, newest first, paginated with a
|
|
2136
|
+
* cursor. The order is fixed, so there is no `sorting`.
|
|
2137
|
+
*
|
|
2138
|
+
* The lookup is scoped to the project in `project_id`.
|
|
2139
|
+
* @summary List the revisions of an identity provider connection
|
|
2140
|
+
*/
|
|
2141
|
+
const listIdpRevisions = async (id, params, options) => {
|
|
2142
|
+
return customFetch(getListIdpRevisionsUrl(id, params), {
|
|
2143
|
+
...options,
|
|
2144
|
+
method: "GET"
|
|
2145
|
+
});
|
|
2146
|
+
};
|
|
2147
|
+
const getGetIdpRevisionByIdUrl = (revisionId, params) => {
|
|
2148
|
+
const normalizedParams = new URLSearchParams();
|
|
2149
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2150
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2151
|
+
});
|
|
2152
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2153
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/idps/revisions/${encodeURIComponent(String(revisionId))}?${stringifiedParams}` : `${getProxyPath()}/idps/revisions/${encodeURIComponent(String(revisionId))}`;
|
|
2154
|
+
};
|
|
2155
|
+
/**
|
|
2156
|
+
* Reads one revision of a connection by its `revision_id`, the value an auth
|
|
2157
|
+
* attempt or a release pins.
|
|
2158
|
+
*
|
|
2159
|
+
* The lookup is scoped to the project in `project_id`.
|
|
2160
|
+
* @summary Get one revision of an identity provider connection
|
|
2161
|
+
*/
|
|
2162
|
+
const getIdpRevisionById = async (revisionId, params, options) => {
|
|
2163
|
+
return customFetch(getGetIdpRevisionByIdUrl(revisionId, params), {
|
|
2164
|
+
...options,
|
|
2165
|
+
method: "GET"
|
|
2166
|
+
});
|
|
2167
|
+
};
|
|
2168
|
+
const getListPoliciesUrl = (params) => {
|
|
2169
|
+
const normalizedParams = new URLSearchParams();
|
|
2170
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2171
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2172
|
+
});
|
|
2173
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2174
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/policies?${stringifiedParams}` : `${getProxyPath()}/policies`;
|
|
2175
|
+
};
|
|
2176
|
+
/**
|
|
2177
|
+
* Lists the project's policies, one per operation, each as its newest
|
|
2178
|
+
* revision, ordered by `created_at` (first publish) and then `id`. Filter
|
|
2179
|
+
* by `operation` to read the policy of one operation; a project that never
|
|
2180
|
+
* published one gets an empty list.
|
|
2181
|
+
*
|
|
2182
|
+
* The lookup is scoped to the project in `project_id`.
|
|
2183
|
+
* @summary List policies
|
|
2184
|
+
*/
|
|
2185
|
+
const listPolicies = async (params, options) => {
|
|
2186
|
+
return customFetch(getListPoliciesUrl(params), {
|
|
2187
|
+
...options,
|
|
2188
|
+
method: "GET"
|
|
2189
|
+
});
|
|
2190
|
+
};
|
|
2191
|
+
const getPublishPolicyUrl = (params) => {
|
|
2192
|
+
const normalizedParams = new URLSearchParams();
|
|
2193
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2194
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2195
|
+
});
|
|
2196
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2197
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/policies?${stringifiedParams}` : `${getProxyPath()}/policies`;
|
|
2198
|
+
};
|
|
2199
|
+
/**
|
|
2200
|
+
* Publishes the project's policy for an operation as a new immutable
|
|
2201
|
+
* revision, creating the policy on its first publish. The newest revision
|
|
2202
|
+
* applies to the next time the operation runs; nothing already stored is
|
|
2203
|
+
* re-evaluated, so a stricter password policy applies the next time a
|
|
2204
|
+
* password is set.
|
|
2205
|
+
*
|
|
2206
|
+
* The request is typed by `operation`: an unknown operation or setting, or
|
|
2207
|
+
* a value of the wrong type or outside its bounds, answers `req.invalid`
|
|
2208
|
+
* like any malformed request. The operation's template then checks the
|
|
2209
|
+
* config again, together with the rules that relate settings to each other
|
|
2210
|
+
* (a `min_length` above `max_length`), and answers `pol.invalid`. Its
|
|
2211
|
+
* `details.details.violations` lists everything that failed, settings
|
|
2212
|
+
* first, then rules: `{"setting": "min_length"}` for one setting, or
|
|
2213
|
+
* `{"config_rule": "min_length_not_above_max_length", "settings":
|
|
2214
|
+
* ["min_length", "max_length"]}` for a rule across settings, with the
|
|
2215
|
+
* settings it reads. A setting left out is off, and `{}` switches every
|
|
2216
|
+
* rule off; there are no defaults.
|
|
2217
|
+
* @summary Publish a policy
|
|
2218
|
+
*/
|
|
2219
|
+
const publishPolicy = async (publishPolicyBody, params, options) => {
|
|
2220
|
+
const getHeaders = (h) => {
|
|
2221
|
+
if (!h) return {};
|
|
2222
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
2223
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
2224
|
+
const headers = {};
|
|
2225
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
2226
|
+
return headers;
|
|
2227
|
+
};
|
|
2228
|
+
return customFetch(getPublishPolicyUrl(params), {
|
|
2229
|
+
...options,
|
|
2230
|
+
method: "POST",
|
|
2231
|
+
headers: {
|
|
2232
|
+
"Content-Type": "application/json",
|
|
2233
|
+
...getHeaders(options?.headers)
|
|
2234
|
+
},
|
|
2235
|
+
body: JSON.stringify(publishPolicyBody)
|
|
2236
|
+
});
|
|
2237
|
+
};
|
|
2238
|
+
const getGetPolicyUrl = (policyId, params) => {
|
|
2239
|
+
const normalizedParams = new URLSearchParams();
|
|
2240
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2241
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2242
|
+
});
|
|
2243
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2244
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/policies/${encodeURIComponent(String(policyId))}?${stringifiedParams}` : `${getProxyPath()}/policies/${encodeURIComponent(String(policyId))}`;
|
|
2245
|
+
};
|
|
2246
|
+
/**
|
|
2247
|
+
* Reads a policy as its newest revision, the one that applies the next time
|
|
2248
|
+
* its operation runs.
|
|
2249
|
+
*
|
|
2250
|
+
* The lookup is scoped to the project in `project_id`: a policy of another
|
|
2251
|
+
* project answers not found exactly as an unknown id does.
|
|
2252
|
+
* @summary Get a policy
|
|
2253
|
+
*/
|
|
2254
|
+
const getPolicy = async (policyId, params, options) => {
|
|
2255
|
+
return customFetch(getGetPolicyUrl(policyId, params), {
|
|
2256
|
+
...options,
|
|
2257
|
+
method: "GET"
|
|
2258
|
+
});
|
|
2259
|
+
};
|
|
2260
|
+
const getListPolicyRevisionsUrl = (policyId, params) => {
|
|
2261
|
+
const normalizedParams = new URLSearchParams();
|
|
2262
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2263
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2264
|
+
});
|
|
2265
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2266
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/policies/${encodeURIComponent(String(policyId))}/revisions?${stringifiedParams}` : `${getProxyPath()}/policies/${encodeURIComponent(String(policyId))}/revisions`;
|
|
2267
|
+
};
|
|
2268
|
+
/**
|
|
2269
|
+
* Returns every revision of one policy, newest first, paginated with a
|
|
2270
|
+
* cursor. The order is fixed, so there is no `sorting`.
|
|
2271
|
+
*
|
|
2272
|
+
* The lookup is scoped to the project in `project_id`: a policy of another
|
|
2273
|
+
* project answers not found exactly as an unknown id does.
|
|
2274
|
+
* @summary List the revisions of a policy
|
|
2275
|
+
*/
|
|
2276
|
+
const listPolicyRevisions = async (policyId, params, options) => {
|
|
2277
|
+
return customFetch(getListPolicyRevisionsUrl(policyId, params), {
|
|
2278
|
+
...options,
|
|
2279
|
+
method: "GET"
|
|
2280
|
+
});
|
|
2281
|
+
};
|
|
2282
|
+
const getGetPolicyRevisionUrl = (revisionId, params) => {
|
|
2283
|
+
const normalizedParams = new URLSearchParams();
|
|
2284
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2285
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2286
|
+
});
|
|
2287
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2288
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/policies/revisions/${encodeURIComponent(String(revisionId))}?${stringifiedParams}` : `${getProxyPath()}/policies/revisions/${encodeURIComponent(String(revisionId))}`;
|
|
2289
|
+
};
|
|
2290
|
+
/**
|
|
2291
|
+
* Reads one revision of a policy, newest or not.
|
|
2292
|
+
*
|
|
2293
|
+
* The lookup is scoped to the project in `project_id`: a revision of another
|
|
2294
|
+
* project answers not found exactly as an unknown id does.
|
|
2295
|
+
* @summary Get a policy revision
|
|
2296
|
+
*/
|
|
2297
|
+
const getPolicyRevision = async (revisionId, params, options) => {
|
|
2298
|
+
return customFetch(getGetPolicyRevisionUrl(revisionId, params), {
|
|
2299
|
+
...options,
|
|
2300
|
+
method: "GET"
|
|
2301
|
+
});
|
|
2302
|
+
};
|
|
2303
|
+
const getCreateReleaseUrl = (params) => {
|
|
2304
|
+
const normalizedParams = new URLSearchParams();
|
|
2305
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2306
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2307
|
+
});
|
|
2308
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2309
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/releases?${stringifiedParams}` : `${getProxyPath()}/releases`;
|
|
2310
|
+
};
|
|
2311
|
+
/**
|
|
2312
|
+
* Assembles a release from existing revisions, given as
|
|
2313
|
+
* `(kind, revision_id)` pairs. To build one from files on disk, use
|
|
2314
|
+
* `POST /releases/build`.
|
|
2315
|
+
*
|
|
2316
|
+
* Each revision must exist in the project and is recorded under the handle
|
|
2317
|
+
* it declares. The release must be complete and consistent:
|
|
2318
|
+
*
|
|
2319
|
+
* - Every handle its revisions name must be in the release: a flow's
|
|
2320
|
+
* `user_schema`, and the IDP connections named by a flow step's
|
|
2321
|
+
* `sso_providers` or a schema's `x-auth-methods.sso.providers`. A missing
|
|
2322
|
+
* one answers `rel.unresolved_reference`, naming the resource and the
|
|
2323
|
+
* handle, e.g. `flow_definition default-login: user_schema human-user not found`.
|
|
2324
|
+
* - Every flow is validated as on save, against the user schema revision
|
|
2325
|
+
* in the release. A flow that fails answers `rel.invalid`, with the
|
|
2326
|
+
* reason in `details`.
|
|
2327
|
+
*
|
|
2328
|
+
* Idempotent on the set of revisions: the same revisions with a different
|
|
2329
|
+
* `message` answer `200` with the existing release. A new release answers
|
|
2330
|
+
* `201`. Creating a release does not deploy it.
|
|
2331
|
+
* @summary Create a release
|
|
2332
|
+
*/
|
|
2333
|
+
const createRelease = async (createReleaseBody, params, options) => {
|
|
2334
|
+
const getHeaders = (h) => {
|
|
2335
|
+
if (!h) return {};
|
|
2336
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
2337
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
2338
|
+
const headers = {};
|
|
2339
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
2340
|
+
return headers;
|
|
2341
|
+
};
|
|
2342
|
+
return customFetch(getCreateReleaseUrl(params), {
|
|
2343
|
+
...options,
|
|
2344
|
+
method: "POST",
|
|
2345
|
+
headers: {
|
|
2346
|
+
"Content-Type": "application/json",
|
|
2347
|
+
...getHeaders(options?.headers)
|
|
2348
|
+
},
|
|
2349
|
+
body: JSON.stringify(createReleaseBody)
|
|
2350
|
+
});
|
|
2351
|
+
};
|
|
2352
|
+
const getListReleasesUrl = (params) => {
|
|
2353
|
+
const normalizedParams = new URLSearchParams();
|
|
2354
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2355
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2356
|
+
});
|
|
2357
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2358
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/releases?${stringifiedParams}` : `${getProxyPath()}/releases`;
|
|
2359
|
+
};
|
|
2360
|
+
/**
|
|
2361
|
+
* Lists the project's releases, newest first.
|
|
2362
|
+
*
|
|
2363
|
+
* Entries carry the digest, the metadata and `revoked_at` — the pinned set
|
|
2364
|
+
* is omitted.
|
|
2365
|
+
* Read one release with `GET /releases/{release_id}` to get its pointers.
|
|
2366
|
+
*
|
|
2367
|
+
* `content_hash` looks a release up by its content, as the CLI does when a
|
|
2368
|
+
* person types the digest a transcript printed. The project holds at most
|
|
2369
|
+
* one release per digest, so the filtered list has one entry or none, and
|
|
2370
|
+
* an unknown digest is an empty list rather than an error. Paths take the
|
|
2371
|
+
* `rel_` id only; the matched entry's `id` is what to use there.
|
|
2372
|
+
* @summary List releases
|
|
2373
|
+
*/
|
|
2374
|
+
const listReleases = async (params, options) => {
|
|
2375
|
+
return customFetch(getListReleasesUrl(params), {
|
|
2376
|
+
...options,
|
|
2377
|
+
method: "GET"
|
|
2378
|
+
});
|
|
2379
|
+
};
|
|
2380
|
+
const getBuildReleaseUrl = (params) => {
|
|
2381
|
+
const normalizedParams = new URLSearchParams();
|
|
2382
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2383
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2384
|
+
});
|
|
2385
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2386
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/releases/build?${stringifiedParams}` : `${getProxyPath()}/releases/build`;
|
|
2387
|
+
};
|
|
2388
|
+
/**
|
|
2389
|
+
* Builds a release from the resources of `.zitadel/` as authored on disk,
|
|
2390
|
+
* grouped by kind, in one transaction: a failure anywhere leaves no
|
|
2391
|
+
* revision and no release. The caller records nothing.
|
|
2392
|
+
*
|
|
2393
|
+
* If the project already holds a release with the same content, the same
|
|
2394
|
+
* `content_hash`, the request answers `200` with that release and
|
|
2395
|
+
* allocates nothing, however long ago it was built. Otherwise every resource is compared against the
|
|
2396
|
+
* project's newest revision of the same handle: unchanged content reuses
|
|
2397
|
+
* that revision, changed content allocates a new one, and the request
|
|
2398
|
+
* answers `201` with the new release. A policy whose config matches only an
|
|
2399
|
+
* older revision allocates a new one too, so a request that resolves no
|
|
2400
|
+
* release, which reads the newest revision, applies it as well. Metadata is excluded from the
|
|
2401
|
+
* comparison, so the same content under a different `message` is the same
|
|
2402
|
+
* release.
|
|
2403
|
+
*
|
|
2404
|
+
* A structurally malformed request is refused while decoding with
|
|
2405
|
+
* `req.invalid`, naming the offending fields. A well-formed bundle is then
|
|
2406
|
+
* checked resource by resource, as each kind's create endpoint checks it,
|
|
2407
|
+
* and every failure is reported at once: the request answers `400` with
|
|
2408
|
+
* `rel.invalid`, and `details.resources` lists each resource that failed.
|
|
2409
|
+
* A handle that resolves neither in the bundle nor in the project answers
|
|
2410
|
+
* `rel.unresolved_reference`, naming the pointer and the handle.
|
|
2411
|
+
*
|
|
2412
|
+
* Building writes revisions, so besides `release.write` it needs the write
|
|
2413
|
+
* scope of every kind the bundle carries a resource of: `schema.write`,
|
|
2414
|
+
* `flow_definition.write`, `branding.write`, `idp.write` and
|
|
2415
|
+
* `policy.write`, as the per-kind create endpoints do. A missing scope answers `403` with `rel.permission_denied`,
|
|
2416
|
+
* naming the kind. An empty kind needs no scope.
|
|
2417
|
+
*
|
|
2418
|
+
* Building a release does not deploy it. A release is not tied to an
|
|
2419
|
+
* origin, and the same release can later be deployed to any number of
|
|
2420
|
+
* origins unchanged.
|
|
2421
|
+
* @summary Build a release from files
|
|
2422
|
+
*/
|
|
2423
|
+
const buildRelease = async (buildReleaseBody, params, options) => {
|
|
2424
|
+
const getHeaders = (h) => {
|
|
2425
|
+
if (!h) return {};
|
|
2426
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
2427
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
2428
|
+
const headers = {};
|
|
2429
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
2430
|
+
return headers;
|
|
2431
|
+
};
|
|
2432
|
+
return customFetch(getBuildReleaseUrl(params), {
|
|
2433
|
+
...options,
|
|
2434
|
+
method: "POST",
|
|
2435
|
+
headers: {
|
|
2436
|
+
"Content-Type": "application/json",
|
|
2437
|
+
...getHeaders(options?.headers)
|
|
2438
|
+
},
|
|
2439
|
+
body: JSON.stringify(buildReleaseBody)
|
|
2440
|
+
});
|
|
2441
|
+
};
|
|
2442
|
+
const getGetReleaseByIdUrl = (releaseId, params) => {
|
|
2443
|
+
const normalizedParams = new URLSearchParams();
|
|
2444
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2445
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2446
|
+
});
|
|
2447
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2448
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/releases/${encodeURIComponent(String(releaseId))}?${stringifiedParams}` : `${getProxyPath()}/releases/${encodeURIComponent(String(releaseId))}`;
|
|
2449
|
+
};
|
|
2450
|
+
/**
|
|
2451
|
+
* Reads one release: its digest, its metadata, whether it was revoked, and
|
|
2452
|
+
* the `(kind, handle, revision_id)` tuples it pins.
|
|
2453
|
+
*
|
|
2454
|
+
* The path takes the `rel_` id only. To find a release from its digest,
|
|
2455
|
+
* list with the `content_hash` filter and read the matched entry's `id`.
|
|
2456
|
+
*
|
|
2457
|
+
* Does not embed resource content. Resolve each `revision_id` through the
|
|
2458
|
+
* per-kind read endpoints when the bytes are needed.
|
|
2459
|
+
*
|
|
2460
|
+
* The lookup is scoped to the project in `project_id`: a release id belonging
|
|
2461
|
+
* to another project answers not found exactly as an unknown id does, so the
|
|
2462
|
+
* endpoint cannot be used to probe for releases in projects the caller cannot
|
|
2463
|
+
* read.
|
|
2464
|
+
* @summary Get a release by id
|
|
2465
|
+
*/
|
|
2466
|
+
const getReleaseById = async (releaseId, params, options) => {
|
|
2467
|
+
return customFetch(getGetReleaseByIdUrl(releaseId, params), {
|
|
2468
|
+
...options,
|
|
2469
|
+
method: "GET"
|
|
2470
|
+
});
|
|
2471
|
+
};
|
|
2472
|
+
const getRevokeReleaseUrl = (releaseId, params) => {
|
|
2473
|
+
const normalizedParams = new URLSearchParams();
|
|
2474
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2475
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2476
|
+
});
|
|
2477
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2478
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/releases/${encodeURIComponent(String(releaseId))}/revoke?${stringifiedParams}` : `${getProxyPath()}/releases/${encodeURIComponent(String(releaseId))}/revoke`;
|
|
2479
|
+
};
|
|
2480
|
+
/**
|
|
2481
|
+
* Marks the release revoked, so that its content is never served again.
|
|
2482
|
+
* From then on the release cannot be deployed and is refused on every path
|
|
2483
|
+
* that would serve it, including to a build that pins its digest, with
|
|
2484
|
+
* `rel.revoked`.
|
|
2485
|
+
*
|
|
2486
|
+
* A release that any origin still serves cannot be revoked. An origin
|
|
2487
|
+
* serves the release of the newest deployment to it, so the call answers
|
|
2488
|
+
* `409` with `rel.in_use`, naming each such origin and that deployment.
|
|
2489
|
+
* Deploy another release there or roll back first, then revoke. Revoking
|
|
2490
|
+
* therefore never takes an origin down. Deployments that named the release
|
|
2491
|
+
* earlier stay in the history.
|
|
2492
|
+
*
|
|
2493
|
+
* Idempotent: revoking a release that is already revoked answers `200`
|
|
2494
|
+
* with the release unchanged, `revoked_at` still naming the first
|
|
2495
|
+
* revocation. There is no un-revoke; build a new release instead.
|
|
2496
|
+
*
|
|
2497
|
+
* Takes no body. The lookup is scoped to the project in `project_id`, so a
|
|
2498
|
+
* release id of another project answers not found exactly as an unknown id
|
|
2499
|
+
* does.
|
|
2500
|
+
* @summary Revoke a release
|
|
2501
|
+
*/
|
|
2502
|
+
const revokeRelease = async (releaseId, params, options) => {
|
|
2503
|
+
return customFetch(getRevokeReleaseUrl(releaseId, params), {
|
|
2504
|
+
...options,
|
|
2505
|
+
method: "POST"
|
|
2506
|
+
});
|
|
2507
|
+
};
|
|
2508
|
+
const getCreateGrantUrl = (params) => {
|
|
2509
|
+
const normalizedParams = new URLSearchParams();
|
|
2510
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2511
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2512
|
+
});
|
|
2513
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2514
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/grants?${stringifiedParams}` : `${getProxyPath()}/grants`;
|
|
2515
|
+
};
|
|
2516
|
+
/**
|
|
2517
|
+
* Bind a user or team to `project.viewer`, `project.editor`, or
|
|
2518
|
+
* `project.admin` on the project identified by the `project-id` header.
|
|
2519
|
+
* Name the principal with `user` (`user_id` or `identifier`) or `team`
|
|
2520
|
+
* (`team_id` or `name`). IDs are `asgn_<opaque>`. Owning-team
|
|
2521
|
+
* (`project.team`) grants are not created here — claim owns that path. An
|
|
2522
|
+
* unrevoked grant with the same principal and relation occupies the unique
|
|
2523
|
+
* key even after `expires_at`; DELETE it before re-creating.
|
|
2524
|
+
* Create does not accept `expand`. The `user_id` and team locators
|
|
2525
|
+
* return 201, whose `user` / `team` carry only `user_id` / `team_id`,
|
|
2526
|
+
* and still 404 / 409 when the principal is missing or the tuple
|
|
2527
|
+
* already exists. Creating by `user.identifier` answers 202 with no
|
|
2528
|
+
* body on every outcome. Granting the session caller's own user is
|
|
2529
|
+
* `grant.invalid` on either user locator. Read the grant back for
|
|
2530
|
+
* identifier and display.
|
|
2531
|
+
*
|
|
2532
|
+
* Accepts either a project secret (`oauth2`) or a user-bound Console
|
|
2533
|
+
* session cookie (`nextgenSession`). Session callers are authorized as
|
|
2534
|
+
* the human against the target project (home may differ). Cookie-authenticated
|
|
2535
|
+
* requests follow the scheme's CSRF rules (`nextgenSession`).
|
|
2536
|
+
* @summary Create grant
|
|
2537
|
+
*/
|
|
2538
|
+
const createGrant = async (createGrantBody, params, options) => {
|
|
2539
|
+
const getHeaders = (h) => {
|
|
2540
|
+
if (!h) return {};
|
|
2541
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
2542
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
2543
|
+
const headers = {};
|
|
2544
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
2545
|
+
return headers;
|
|
2546
|
+
};
|
|
2547
|
+
return customFetch(getCreateGrantUrl(params), {
|
|
2548
|
+
...options,
|
|
2549
|
+
method: "POST",
|
|
2550
|
+
headers: {
|
|
2551
|
+
"Content-Type": "application/json",
|
|
2552
|
+
...getHeaders(options?.headers)
|
|
2553
|
+
},
|
|
2554
|
+
body: JSON.stringify(createGrantBody)
|
|
2555
|
+
});
|
|
2556
|
+
};
|
|
2557
|
+
const getQueryGrantsUrl = (params) => {
|
|
2558
|
+
const normalizedParams = new URLSearchParams();
|
|
2559
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2560
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2561
|
+
});
|
|
2562
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2563
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/grants/query?${stringifiedParams}` : `${getProxyPath()}/grants/query`;
|
|
2564
|
+
};
|
|
2565
|
+
/**
|
|
2566
|
+
* Returns the collaboration grants of a project, paginated with a cursor.
|
|
2567
|
+
* Only unrevoked grants this API manages are listed (user or team bound to
|
|
2568
|
+
* viewer, editor, or admin), including expired grants so a client can
|
|
2569
|
+
* DELETE before re-granting. Project-secret setup (`sk_proj`) and
|
|
2570
|
+
* owning-team (`relation=team`) rows are not returned. Grants are not in
|
|
2571
|
+
* `resource_scope_index`; project scope is required on the query (same as
|
|
2572
|
+
* get). Requires `project.read`. `expand: ["principal"]` adds envelope
|
|
2573
|
+
* fields on `user` / `team` and additionally requires `user.read` and
|
|
2574
|
+
* `team.read` for project secrets (documented on the expand enum; those
|
|
2575
|
+
* scopes cannot be ANDed onto this security block because they are
|
|
2576
|
+
* body-conditional). A user-bound Console session that already passed
|
|
2577
|
+
* the project Check may expand without those scopes.
|
|
2578
|
+
*
|
|
2579
|
+
* Accepts either a project secret (`oauth2`) or a user-bound Console
|
|
2580
|
+
* session cookie (`nextgenSession`). Cookie-authenticated requests
|
|
2581
|
+
* follow the scheme's CSRF rules (`nextgenSession`).
|
|
2582
|
+
* @summary Query grants
|
|
2583
|
+
*/
|
|
2584
|
+
const queryGrants = async (queryGrantsBody, params, options) => {
|
|
2585
|
+
const getHeaders = (h) => {
|
|
2586
|
+
if (!h) return {};
|
|
2587
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
2588
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
2589
|
+
const headers = {};
|
|
2590
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
2591
|
+
return headers;
|
|
2592
|
+
};
|
|
2593
|
+
return customFetch(getQueryGrantsUrl(params), {
|
|
2594
|
+
...options,
|
|
2595
|
+
method: "POST",
|
|
2596
|
+
headers: {
|
|
2597
|
+
"Content-Type": "application/json",
|
|
2598
|
+
...getHeaders(options?.headers)
|
|
2599
|
+
},
|
|
2600
|
+
body: JSON.stringify(queryGrantsBody)
|
|
2601
|
+
});
|
|
2602
|
+
};
|
|
2603
|
+
const getGetGrantUrl = (id, params) => {
|
|
2604
|
+
const normalizedParams = new URLSearchParams();
|
|
2605
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2606
|
+
if (Array.isArray(value) && ["expand"].includes(key)) {
|
|
2607
|
+
value.forEach((v) => {
|
|
2608
|
+
normalizedParams.append(key, v === null ? "null" : String(v));
|
|
2609
|
+
});
|
|
2610
|
+
return;
|
|
2611
|
+
}
|
|
2612
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2613
|
+
});
|
|
2614
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2615
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/grants/${encodeURIComponent(String(id))}?${stringifiedParams}` : `${getProxyPath()}/grants/${encodeURIComponent(String(id))}`;
|
|
2616
|
+
};
|
|
2617
|
+
/**
|
|
2618
|
+
* Loads a grant by `(project_id, id)` that this API manages (user or team
|
|
2619
|
+
* bound to viewer, editor, or admin) and that has not been revoked.
|
|
2620
|
+
* "Active" here means not revoked: expired grants stay visible so the
|
|
2621
|
+
* client can DELETE before re-granting the same binding. Authorization
|
|
2622
|
+
* still ignores expired grants. Grants are not registered in
|
|
2623
|
+
* `resource_scope_index`; project scope is required on the query (same as
|
|
2624
|
+
* events). Misses, revoked rows, project-secret setup (`sk_proj`),
|
|
2625
|
+
* owning-team (`relation=team`) rows, and cross-project ids return 404.
|
|
2626
|
+
* `expand=principal` adds envelope fields on `user` or `team` and requires
|
|
2627
|
+
* `user.read` and `team.read` in addition to `project.read` for project
|
|
2628
|
+
* secrets. A user-bound Console session that already passed the project
|
|
2629
|
+
* Check may expand without those scopes.
|
|
2630
|
+
*
|
|
2631
|
+
* Accepts either a project secret (`oauth2`) or a user-bound Console
|
|
2632
|
+
* session cookie (`nextgenSession`). Cookie-authenticated requests
|
|
2633
|
+
* follow the scheme's CSRF rules (`nextgenSession`).
|
|
2634
|
+
* @summary Get grant
|
|
2635
|
+
*/
|
|
2636
|
+
const getGrant = async (id, params, options) => {
|
|
2637
|
+
return customFetch(getGetGrantUrl(id, params), {
|
|
2638
|
+
...options,
|
|
2639
|
+
method: "GET"
|
|
2640
|
+
});
|
|
2641
|
+
};
|
|
2642
|
+
const getDeleteGrantUrl = (id, params) => {
|
|
2643
|
+
const normalizedParams = new URLSearchParams();
|
|
2644
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2645
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2646
|
+
});
|
|
2647
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2648
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/grants/${encodeURIComponent(String(id))}?${stringifiedParams}` : `${getProxyPath()}/grants/${encodeURIComponent(String(id))}`;
|
|
2649
|
+
};
|
|
2650
|
+
/**
|
|
2651
|
+
* Soft-revokes a grant this API manages and emits `authz.revoked`.
|
|
2652
|
+
* Already-revoked, missing, project-secret setup, and owning-team grants
|
|
2653
|
+
* return 404. The row is not un-revoked. Expired grants can still be
|
|
2654
|
+
* revoked so the unique binding can be reused.
|
|
2655
|
+
*
|
|
2656
|
+
* Accepts either a project secret (`oauth2`) or a user-bound Console
|
|
2657
|
+
* session cookie (`nextgenSession`). Cookie-authenticated requests
|
|
2658
|
+
* follow the scheme's CSRF rules (`nextgenSession`).
|
|
2659
|
+
* @summary Revoke grant
|
|
2660
|
+
*/
|
|
2661
|
+
const deleteGrant = async (id, params, options) => {
|
|
2662
|
+
return customFetch(getDeleteGrantUrl(id, params), {
|
|
2663
|
+
...options,
|
|
2664
|
+
method: "DELETE"
|
|
2665
|
+
});
|
|
2666
|
+
};
|
|
2667
|
+
const getListEventsUrl = (params) => {
|
|
2668
|
+
const normalizedParams = new URLSearchParams();
|
|
2669
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2670
|
+
if (Array.isArray(value) && ["category", "event_type"].includes(key)) {
|
|
2671
|
+
value.forEach((v) => {
|
|
2672
|
+
normalizedParams.append(key, v === null ? "null" : String(v));
|
|
2673
|
+
});
|
|
2674
|
+
return;
|
|
2675
|
+
}
|
|
2676
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2677
|
+
});
|
|
2678
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2679
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/events?${stringifiedParams}` : `${getProxyPath()}/events`;
|
|
2680
|
+
};
|
|
2681
|
+
/**
|
|
2682
|
+
* Returns project-scoped audit events, newest-first by keyset on
|
|
2683
|
+
* `(created_at, id)` (ADR 027 / ADR 049). Pass `order=asc` for oldest-first.
|
|
2684
|
+
* Requires `events.read`.
|
|
2685
|
+
*
|
|
2686
|
+
* Pre-claim projects return an empty list (events are stored but not
|
|
2687
|
+
* visible until claim succeeds). Team-scoped credentials see only events
|
|
2688
|
+
* whose emit-time `team_id` matches the credential team (enforced when
|
|
2689
|
+
* team-scoped tokens exist).
|
|
2690
|
+
*
|
|
2691
|
+
* Clients discriminate each item via `event_type` (OpenAPI Event oneOf) —
|
|
2692
|
+
* see docs/design/api/events-catalog.md.
|
|
2693
|
+
* @summary List events
|
|
2694
|
+
*/
|
|
2695
|
+
const listEvents = async (params, options) => {
|
|
2696
|
+
return customFetch(getListEventsUrl(params), {
|
|
2697
|
+
...options,
|
|
2698
|
+
method: "GET"
|
|
2699
|
+
});
|
|
2700
|
+
};
|
|
2701
|
+
const getGetEventUrl = (id, params) => {
|
|
2702
|
+
const normalizedParams = new URLSearchParams();
|
|
2703
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2704
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2705
|
+
});
|
|
2706
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2707
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/events/${encodeURIComponent(String(id))}?${stringifiedParams}` : `${getProxyPath()}/events/${encodeURIComponent(String(id))}`;
|
|
2708
|
+
};
|
|
2709
|
+
/**
|
|
2710
|
+
* Loads a single event by `(project_id, id)`. Requires `events.read`.
|
|
2711
|
+
* Events are not registered in `resource_scope_index`; project scope is
|
|
2712
|
+
* required on the query (ADR 049). Misses and cross-project ids return 404.
|
|
2713
|
+
*
|
|
2714
|
+
* Pre-claim projects return 404 (stored events stay invisible until claim).
|
|
2715
|
+
* @summary Get event by ID
|
|
2716
|
+
*/
|
|
2717
|
+
const getEvent = async (id, params, options) => {
|
|
2718
|
+
return customFetch(getGetEventUrl(id, params), {
|
|
2719
|
+
...options,
|
|
2720
|
+
method: "GET"
|
|
2721
|
+
});
|
|
2722
|
+
};
|
|
2723
|
+
const getGetVariablesUrl = (params) => {
|
|
2724
|
+
const normalizedParams = new URLSearchParams();
|
|
2725
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2726
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2727
|
+
});
|
|
2728
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2729
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/variables?${stringifiedParams}` : `${getProxyPath()}/variables`;
|
|
2730
|
+
};
|
|
2731
|
+
/**
|
|
2732
|
+
* Returns the project's variables, keyed by name, each with its value per
|
|
2733
|
+
* kind. With `kind`, only that kind's values are returned.
|
|
2734
|
+
*
|
|
2735
|
+
* Secret values are not returned. A secret appears as `{"secret": true}`,
|
|
2736
|
+
* which says a value is held without disclosing it.
|
|
2737
|
+
* @summary Get variables
|
|
2738
|
+
*/
|
|
2739
|
+
const getVariables = async (params, options) => {
|
|
2740
|
+
return customFetch(getGetVariablesUrl(params), {
|
|
2741
|
+
...options,
|
|
2742
|
+
method: "GET"
|
|
2743
|
+
});
|
|
2744
|
+
};
|
|
2745
|
+
const getUpdateVariablesUrl = (params) => {
|
|
2746
|
+
const normalizedParams = new URLSearchParams();
|
|
2747
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2748
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2749
|
+
});
|
|
2750
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2751
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/variables?${stringifiedParams}` : `${getProxyPath()}/variables`;
|
|
2752
|
+
};
|
|
2753
|
+
/**
|
|
2754
|
+
* Enters, replaces and removes the project's variables for the requested
|
|
2755
|
+
* kind. Names not in the body are untouched. Existing deployments keep the
|
|
2756
|
+
* values they froze.
|
|
2757
|
+
*
|
|
2758
|
+
* Without `kind`, a plain value is written for both kinds. A secret is
|
|
2759
|
+
* written for `primary` only and removes the name's `preview` value, so a
|
|
2760
|
+
* preview never keeps a plaintext copy; set a preview secret with
|
|
2761
|
+
* `kind=preview`. `null` removes the name from both.
|
|
2762
|
+
*
|
|
2763
|
+
* A bare scalar enters a non-secret value. `{"value": …, "secret": true}`
|
|
2764
|
+
* stores the value encrypted under the project's active `secret` key, after
|
|
2765
|
+
* which it can be referenced but not read back. `null` removes the name
|
|
2766
|
+
* (RFC 7386), which is how several variables are removed in one request;
|
|
2767
|
+
* removing a name the project does not hold is a no-op rather than an error.
|
|
2768
|
+
*
|
|
2769
|
+
* The body is applied whole or not at all, so a rejected request leaves the
|
|
2770
|
+
* project's variables exactly as they were. Writing the same name twice
|
|
2771
|
+
* replaces the value rather than duplicating it, which makes a retry safe.
|
|
2772
|
+
* @summary Update variables
|
|
2773
|
+
*/
|
|
2774
|
+
const updateVariables = async (updateVariablesBody, params, options) => {
|
|
2775
|
+
const getHeaders = (h) => {
|
|
2776
|
+
if (!h) return {};
|
|
2777
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
2778
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
2779
|
+
const headers = {};
|
|
2780
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
2781
|
+
return headers;
|
|
2782
|
+
};
|
|
2783
|
+
return customFetch(getUpdateVariablesUrl(params), {
|
|
2784
|
+
...options,
|
|
2785
|
+
method: "PATCH",
|
|
2786
|
+
headers: {
|
|
2787
|
+
"Content-Type": "application/json",
|
|
2788
|
+
...getHeaders(options?.headers)
|
|
2789
|
+
},
|
|
2790
|
+
body: JSON.stringify(updateVariablesBody)
|
|
2791
|
+
});
|
|
2792
|
+
};
|
|
2793
|
+
const getGetVariableUrl = (variableName, params) => {
|
|
2794
|
+
const normalizedParams = new URLSearchParams();
|
|
2795
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2796
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2797
|
+
});
|
|
2798
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2799
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/variables/${encodeURIComponent(String(variableName))}?${stringifiedParams}` : `${getProxyPath()}/variables/${encodeURIComponent(String(variableName))}`;
|
|
2800
|
+
};
|
|
2801
|
+
/**
|
|
2802
|
+
* Reads one variable by name, with its value per kind. A name with no
|
|
2803
|
+
* value for the requested kind answers `var.not_found`. A secret reads
|
|
2804
|
+
* back as `{"secret": true}`.
|
|
2805
|
+
* @summary Get a variable
|
|
2806
|
+
*/
|
|
2807
|
+
const getVariable = async (variableName, params, options) => {
|
|
2808
|
+
return customFetch(getGetVariableUrl(variableName, params), {
|
|
2809
|
+
...options,
|
|
2810
|
+
method: "GET"
|
|
2811
|
+
});
|
|
2812
|
+
};
|
|
2813
|
+
const getDeleteVariableUrl = (variableName, params) => {
|
|
2814
|
+
const normalizedParams = new URLSearchParams();
|
|
2815
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2816
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2817
|
+
});
|
|
2818
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2819
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/variables/${encodeURIComponent(String(variableName))}?${stringifiedParams}` : `${getProxyPath()}/variables/${encodeURIComponent(String(variableName))}`;
|
|
2820
|
+
};
|
|
2821
|
+
/**
|
|
2822
|
+
* Removes a variable for the requested kind, or for both kinds without
|
|
2823
|
+
* `kind`. A name with no value for that kind answers `var.not_found`.
|
|
2824
|
+
* Existing deployments keep the values they froze.
|
|
2825
|
+
* @summary Delete a variable
|
|
2826
|
+
*/
|
|
2827
|
+
const deleteVariable = async (variableName, params, options) => {
|
|
2828
|
+
return customFetch(getDeleteVariableUrl(variableName, params), {
|
|
2829
|
+
...options,
|
|
2830
|
+
method: "DELETE"
|
|
2831
|
+
});
|
|
2832
|
+
};
|
|
2833
|
+
const getCreateDeploymentUrl = (params) => {
|
|
2834
|
+
const normalizedParams = new URLSearchParams();
|
|
2835
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2836
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2837
|
+
});
|
|
2838
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2839
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/deployments?${stringifiedParams}` : `${getProxyPath()}/deployments`;
|
|
2840
|
+
};
|
|
2841
|
+
/**
|
|
2842
|
+
* Makes a release live on its targets by recording a deployment,
|
|
2843
|
+
* atomically: on success every target serves the release and the record
|
|
2844
|
+
* exists; on failure nothing changes and no record is written.
|
|
2845
|
+
*
|
|
2846
|
+
* Name the release by exactly one of `release_id` or `content_hash`; it
|
|
2847
|
+
* must already exist in the project. `targets` is `primary` or preview
|
|
2848
|
+
* URLs. The deployment freezes the project's variable values for its kind,
|
|
2849
|
+
* with no fallback between primary and preview values.
|
|
2850
|
+
*
|
|
2851
|
+
* A deployment to `primary` changes nothing when the project's newest
|
|
2852
|
+
* primary deployment has the same release and frozen values and covers
|
|
2853
|
+
* exactly the current primary origins: the call answers `200` with that
|
|
2854
|
+
* deployment. Any other request writes a new deployment and answers `201`;
|
|
2855
|
+
* for preview URLs that record renews their previews.
|
|
2856
|
+
*
|
|
2857
|
+
* Failures:
|
|
2858
|
+
* - `400 dep.invalid`: both or neither of `release_id` and `content_hash`;
|
|
2859
|
+
* a primary origin named exactly; `primary` mixed with preview URLs;
|
|
2860
|
+
* `primary` on a project with no primary origin; `ttl` with `primary`;
|
|
2861
|
+
* `ttl` above 365 days (`P365D`).
|
|
2862
|
+
* - `400 dep.variables_missing`: a referenced variable has no value for
|
|
2863
|
+
* the kind; `details` names the kind and every missing variable.
|
|
2864
|
+
* - `403 proj.origin_not_allowed`: a preview URL matches no preview
|
|
2865
|
+
* pattern, or is a loopback URL.
|
|
2866
|
+
* - `404 rel.not_found`: the release id or digest names no release here.
|
|
2867
|
+
* - `409 dep.conflict`: `expected_deployment_id` is not the deployment
|
|
2868
|
+
* this write replaces; `details.deployment` is that deployment.
|
|
2869
|
+
* - `409 rel.revoked`: the release is revoked.
|
|
2870
|
+
* @summary Create a deployment
|
|
2871
|
+
*/
|
|
2872
|
+
const createDeployment = async (createDeploymentBody, params, options) => {
|
|
2873
|
+
const getHeaders = (h) => {
|
|
2874
|
+
if (!h) return {};
|
|
2875
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
2876
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
2877
|
+
const headers = {};
|
|
2878
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
2879
|
+
return headers;
|
|
2880
|
+
};
|
|
2881
|
+
return customFetch(getCreateDeploymentUrl(params), {
|
|
2882
|
+
...options,
|
|
2883
|
+
method: "POST",
|
|
2884
|
+
headers: {
|
|
2885
|
+
"Content-Type": "application/json",
|
|
2886
|
+
...getHeaders(options?.headers)
|
|
2887
|
+
},
|
|
2888
|
+
body: JSON.stringify(createDeploymentBody)
|
|
2889
|
+
});
|
|
2890
|
+
};
|
|
2891
|
+
const getListDeploymentsUrl = (params) => {
|
|
2892
|
+
const normalizedParams = new URLSearchParams();
|
|
2893
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2894
|
+
if (Array.isArray(value) && ["expand"].includes(key)) {
|
|
2895
|
+
value.forEach((v) => {
|
|
2896
|
+
normalizedParams.append(key, v === null ? "null" : String(v));
|
|
2897
|
+
});
|
|
2898
|
+
return;
|
|
2899
|
+
}
|
|
2900
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2901
|
+
});
|
|
2902
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2903
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/deployments?${stringifiedParams}` : `${getProxyPath()}/deployments`;
|
|
2904
|
+
};
|
|
2905
|
+
/**
|
|
2906
|
+
* Lists what ran where, and when.
|
|
2907
|
+
*
|
|
2908
|
+
* By default the list is the history, newest first: every deployment of
|
|
2909
|
+
* the project with every target it made the release live on. With
|
|
2910
|
+
* `origin`, the history of that origin alone.
|
|
2911
|
+
*
|
|
2912
|
+
* With `live=true`, the list is what is served now, newest first: the
|
|
2913
|
+
* project's newest primary deployment, narrowed to origins that are still
|
|
2914
|
+
* primary, and the newest deployment to each live preview URL, narrowed to
|
|
2915
|
+
* the URLs it still serves. Combined with `origin`, it is the one
|
|
2916
|
+
* deployment that origin serves, or empty.
|
|
2917
|
+
*
|
|
2918
|
+
* `expand: ["release"]` embeds the release each deployment made live; it
|
|
2919
|
+
* requires `release.read` and does not change the ordering or the page
|
|
2920
|
+
* tokens.
|
|
2921
|
+
* @summary List deployments
|
|
2922
|
+
*/
|
|
2923
|
+
const listDeployments = async (params, options) => {
|
|
2924
|
+
return customFetch(getListDeploymentsUrl(params), {
|
|
2925
|
+
...options,
|
|
2926
|
+
method: "GET"
|
|
2927
|
+
});
|
|
2928
|
+
};
|
|
2929
|
+
const getGetDeploymentByIdUrl = (deploymentId, params) => {
|
|
2930
|
+
const normalizedParams = new URLSearchParams();
|
|
2931
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2932
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2933
|
+
});
|
|
2934
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2935
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/deployments/${encodeURIComponent(String(deploymentId))}?${stringifiedParams}` : `${getProxyPath()}/deployments/${encodeURIComponent(String(deploymentId))}`;
|
|
2936
|
+
};
|
|
2937
|
+
/**
|
|
2938
|
+
* Reads one deployment record.
|
|
2939
|
+
*
|
|
2940
|
+
* The lookup is scoped to the project in `project_id`: a deployment id
|
|
2941
|
+
* belonging to another project answers not found exactly as an unknown id
|
|
2942
|
+
* does, so the endpoint cannot be used to probe for deployments in projects
|
|
2943
|
+
* the caller cannot read.
|
|
2944
|
+
* @summary Get a deployment by id
|
|
2945
|
+
*/
|
|
2946
|
+
const getDeploymentById = async (deploymentId, params, options) => {
|
|
2947
|
+
return customFetch(getGetDeploymentByIdUrl(deploymentId, params), {
|
|
2948
|
+
...options,
|
|
2949
|
+
method: "GET"
|
|
2950
|
+
});
|
|
2951
|
+
};
|
|
2952
|
+
const getRollbackDeploymentUrl = (deploymentId, params) => {
|
|
2953
|
+
const normalizedParams = new URLSearchParams();
|
|
2954
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2955
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2956
|
+
});
|
|
2957
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2958
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/deployments/${encodeURIComponent(String(deploymentId))}/rollback?${stringifiedParams}` : `${getProxyPath()}/deployments/${encodeURIComponent(String(deploymentId))}/rollback`;
|
|
2959
|
+
};
|
|
2960
|
+
/**
|
|
2961
|
+
* Re-deploys the release of the deployment named in the path to `primary`,
|
|
2962
|
+
* with the variable values it froze: a new deployment with `reason:
|
|
2963
|
+
* rollback` and `rollback_to` naming it. Like any deployment to `primary`,
|
|
2964
|
+
* it covers every current primary origin. Idempotent like a deployment to
|
|
2965
|
+
* `primary`: when nothing would change it answers `200` with the newest
|
|
2966
|
+
* primary deployment.
|
|
2967
|
+
*
|
|
2968
|
+
* Failures:
|
|
2969
|
+
* - `400 dep.invalid`: the deployment went to preview URLs (deploy to the
|
|
2970
|
+
* preview again instead), or the project has no primary origin.
|
|
2971
|
+
* - `404 dep.not_found`: no deployment of the project has that id.
|
|
2972
|
+
* - `409 dep.conflict`: `expected_deployment_id` is not the project's
|
|
2973
|
+
* newest primary deployment; `details.deployment` is that deployment.
|
|
2974
|
+
* - `409 rel.revoked`: the release is revoked.
|
|
2975
|
+
* @summary Roll back to a deployment
|
|
2976
|
+
*/
|
|
2977
|
+
const rollbackDeployment = async (deploymentId, params, rollbackDeploymentBody, options) => {
|
|
2978
|
+
const getHeaders = (h) => {
|
|
2979
|
+
if (!h) return {};
|
|
2980
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
2981
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
2982
|
+
const headers = {};
|
|
2983
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
2984
|
+
return headers;
|
|
2985
|
+
};
|
|
2986
|
+
return customFetch(getRollbackDeploymentUrl(deploymentId, params), {
|
|
2987
|
+
...options,
|
|
2988
|
+
method: "POST",
|
|
2989
|
+
headers: {
|
|
2990
|
+
"Content-Type": "application/json",
|
|
2991
|
+
...getHeaders(options?.headers)
|
|
2992
|
+
},
|
|
2993
|
+
body: JSON.stringify(rollbackDeploymentBody)
|
|
2994
|
+
});
|
|
2995
|
+
};
|
|
2996
|
+
const getGetDeploymentVariablesUrl = (deploymentId, params) => {
|
|
2997
|
+
const normalizedParams = new URLSearchParams();
|
|
2998
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2999
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
3000
|
+
});
|
|
3001
|
+
const stringifiedParams = normalizedParams.toString();
|
|
3002
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/deployments/${encodeURIComponent(String(deploymentId))}/variables?${stringifiedParams}` : `${getProxyPath()}/deployments/${encodeURIComponent(String(deploymentId))}/variables`;
|
|
3003
|
+
};
|
|
3004
|
+
/**
|
|
3005
|
+
* Returns the variable values the deployment froze when it was made. Later
|
|
3006
|
+
* changes to the project's variables do not affect them. A secret reads
|
|
3007
|
+
* back as `{"secret": true}`.
|
|
3008
|
+
* @summary Get a deployment's variables
|
|
1002
3009
|
*/
|
|
1003
|
-
const
|
|
1004
|
-
return customFetch(
|
|
3010
|
+
const getDeploymentVariables = async (deploymentId, params, options) => {
|
|
3011
|
+
return customFetch(getGetDeploymentVariablesUrl(deploymentId, params), {
|
|
1005
3012
|
...options,
|
|
1006
3013
|
method: "GET"
|
|
1007
3014
|
});
|
|
1008
3015
|
};
|
|
1009
3016
|
//#endregion
|
|
1010
|
-
export {
|
|
3017
|
+
export { addOrigin, beginUserPasskeyRegistration, buildRelease, completeClaim, createAuthAttempt, createBranding, createDeployment, createFlow, createFlowDefinition, createGrant, createHandoff, createIdp, createProject, createRelease, createSchema, createSession, createTeam, createUser, deleteGrant, deleteTeam, deleteUserByID, deleteVariable, exchangeHandoff, finishUserPasskeyRegistration, getAddOriginUrl, getAuthAttempt, getBeginUserPasskeyRegistrationUrl, getBrandingById, getBuildReleaseUrl, getClaimStatus, getClaimWindow, getCompleteClaimUrl, getCreateAuthAttemptUrl, getCreateBrandingUrl, getCreateDeploymentUrl, getCreateFlowDefinitionUrl, getCreateFlowUrl, getCreateGrantUrl, getCreateHandoffUrl, getCreateIdpUrl, getCreateProjectUrl, getCreateReleaseUrl, getCreateSchemaUrl, getCreateSessionUrl, getCreateTeamUrl, getCreateUserUrl, getDeleteGrantUrl, getDeleteTeamUrl, getDeleteUserByIDUrl, getDeleteVariableUrl, getDeploymentById, getDeploymentVariables, getEvent, getExchangeHandoffUrl, getFinishUserPasskeyRegistrationUrl, getFlowDefinition, getFlowStep, getGetAuthAttemptUrl, getGetBrandingByIdUrl, getGetClaimStatusUrl, getGetClaimWindowUrl, getGetDeploymentByIdUrl, getGetDeploymentVariablesUrl, getGetEventUrl, getGetFlowDefinitionUrl, getGetFlowStepUrl, getGetGrantUrl, getGetIdpByIdUrl, getGetIdpRevisionByIdUrl, getGetLiveUrl, getGetMyPasswordStateUrl, getGetMySessionCsrfTokenUrl, getGetMySessionUrl, getGetMyUserSchemaUrl, getGetMyUserUrl, getGetPolicyRevisionUrl, getGetPolicyUrl, getGetProjectUrl, getGetReadyUrl, getGetReleaseByIdUrl, getGetSchemaByIdUrl, getGetSessionUrl, getGetTeamUrl, getGetUserByIDUrl, getGetUserPasswordStateUrl, getGetVariableUrl, getGetVariablesUrl, getGrant, getIdpById, getIdpRevisionById, getInitClaimUrl, getIssueChallengeUrl, getListBrandingUrl, getListDeploymentsUrl, getListEventsUrl, getListFlowDefinitionsUrl, getListIdpRevisionsUrl, getListMyIdentityLinksUrl, getListMyPasskeysUrl, getListMyProjectsUrl, getListMyTeamsUrl, getListPoliciesUrl, getListPolicyRevisionsUrl, getListPreviewsUrl, getListProjectAdminsUrl, getListReleasesUrl, getListSchemasUrl, getListUserIdentityLinksUrl, getListUserPasskeysUrl, getListUserTeamsUrl, getLive, getMyPasswordState, getMySession, getMySessionCsrfToken, getMyUser, getMyUserSchema, getPatchMyUserUrl, getPatchProjectUrl, getPatchUserByIDUrl, getPolicy, getPolicyRevision, getProject, getPublishPolicyUrl, getQueryGrantsUrl, getQueryIdpsUrl, getQueryProjectsUrl, getQuerySessionsUrl, getQueryTeamsUrl, getQueryUsersUrl, getReady, getReleaseById, getRemoveOriginUrl, getRemovePreviewUrl, getRevokeMySessionUrl, getRevokeReleaseUrl, getRevokeSessionUrl, getRollbackDeploymentUrl, getSchemaById, getSession, getSetUserPasswordUrl, getSubmitFlowStepUrl, getTeam, getUpdateTeamUrl, getUpdateVariablesUrl, getUserByID, getUserPasswordState, getVariable, getVariables, getVerifyChallengeProofUrl, initClaim, issueChallenge, listBranding, listDeployments, listEvents, listFlowDefinitions, listIdpRevisions, listMyIdentityLinks, listMyPasskeys, listMyProjects, listMyTeams, listPolicies, listPolicyRevisions, listPreviews, listProjectAdmins, listReleases, listSchemas, listUserIdentityLinks, listUserPasskeys, listUserTeams, patchMyUser, patchProject, patchUserByID, publishPolicy, queryGrants, queryIdps, queryProjects, querySessions, queryTeams, queryUsers, removeOrigin, removePreview, revokeMySession, revokeRelease, revokeSession, rollbackDeployment, setUserPassword, submitFlowStep, zitadelNextGen_exports as t, updateTeam, updateVariables, verifyChallengeProof };
|
|
1011
3018
|
|
|
1012
3019
|
//# sourceMappingURL=zitadelNextGen.mjs.map
|