@zitadel/api 0.1.0-alpha.9 → 0.1.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-DD3lSbnp.d.mts +107 -0
- package/dist/fetch-DD3lSbnp.d.mts.map +1 -0
- package/dist/generated/endpoints/zitadelNextGen.d.mts +2 -2
- package/dist/generated/endpoints/zitadelNextGen.mjs +2270 -449
- package/dist/generated/endpoints/zitadelNextGen.mjs.map +1 -1
- package/dist/generated/endpoints/zitadelNextGen.msw.d.mts +172 -82
- package/dist/generated/endpoints/zitadelNextGen.msw.d.mts.map +1 -1
- package/dist/generated/endpoints/zitadelNextGen.msw.mjs +12766 -731
- package/dist/generated/endpoints/zitadelNextGen.msw.mjs.map +1 -1
- package/dist/generated/endpoints/zitadelNextGen.zod.d.mts +10138 -921
- package/dist/generated/endpoints/zitadelNextGen.zod.d.mts.map +1 -1
- package/dist/generated/endpoints/zitadelNextGen.zod.mjs +9620 -1029
- 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 +1571 -96
- 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 +1926 -0
- package/dist/generated/operations.mjs.map +1 -0
- package/dist/index-DuuFQkA8.d.mts +48961 -0
- package/dist/index-DuuFQkA8.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 +178 -11
- package/dist/runtime/fetch.mjs.map +1 -1
- package/dist/zitadelNextGen-BdUDEEuX.d.mts +1234 -0
- package/dist/zitadelNextGen-BdUDEEuX.d.mts.map +1 -0
- package/package.json +43 -9
- package/src/generated/endpoints/zitadelNextGen.faker.ts +340 -0
- package/src/generated/endpoints/zitadelNextGen.msw.ts +1269 -2836
- package/src/generated/endpoints/zitadelNextGen.ts +3701 -867
- package/src/generated/endpoints/zitadelNextGen.zod.ts +9412 -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 +108 -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 +108 -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 +58 -0
- package/src/generated/model/buildRelease200PointersItemKind.ts +27 -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 +58 -0
- package/src/generated/model/buildRelease201PointersItemKind.ts +27 -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 +27 -0
- package/src/generated/model/buildReleaseBody.ts +62 -0
- package/src/generated/model/buildReleaseBodyBundle.ts +82 -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/buildReleaseBodyBundleSchemasItem.ts +85 -0
- package/src/generated/model/buildReleaseDefault.ts +189 -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/createAuthAttempt409.ts +20 -0
- package/src/generated/model/createAuthAttempt409Details.ts +12 -0
- package/src/generated/model/createAuthAttemptBody.ts +21 -8
- package/src/generated/model/createAuthAttemptDefault.ts +65 -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 +81 -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 +58 -0
- package/src/generated/model/createDeployment200ReleasePointersItemKind.ts +27 -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 +58 -0
- package/src/generated/model/createDeployment201ReleasePointersItemKind.ts +27 -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 +257 -0
- package/src/generated/model/createDeploymentBody.ts +95 -0
- package/src/generated/model/createDeploymentBodyReason.ts +20 -0
- package/src/generated/model/createDeploymentDefault.ts +117 -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 +93 -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/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 +175 -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 +85 -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 +33 -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 +99 -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 +74 -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 +90 -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 +58 -0
- package/src/generated/model/createRelease200PointersItemKind.ts +27 -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 +58 -0
- package/src/generated/model/createRelease201PointersItemKind.ts +27 -0
- package/src/generated/model/createReleaseBody.ts +54 -0
- package/src/generated/model/createReleaseBodyPointersItem.ts +38 -0
- package/src/generated/model/createReleaseBodyPointersItemKind.ts +27 -0
- package/src/generated/model/createReleaseDefault.ts +108 -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 +121 -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 +85 -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 +85 -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 +76 -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 +72 -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 +72 -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 +72 -0
- package/src/generated/model/deleteVariableDefault.ts +63 -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 +130 -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 +162 -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/getAuthAttempt409.ts +20 -0
- package/src/generated/model/getAuthAttempt409Details.ts +12 -0
- package/src/generated/model/getAuthAttemptDefault.ts +38 -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 +54 -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 +81 -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 +58 -0
- package/src/generated/model/getDeploymentById200ReleasePointersItemKind.ts +27 -0
- package/src/generated/model/getDeploymentById200Status.ts +22 -0
- package/src/generated/model/getDeploymentById200TargetsItem.ts +28 -0
- package/src/generated/model/getDeploymentByIdDefault.ts +54 -0
- package/src/generated/model/getDeploymentByIdParams.ts +15 -0
- package/src/generated/model/getDeploymentVariables200.ts +17 -0
- package/src/generated/model/getDeploymentVariablesDefault.ts +81 -0
- package/src/generated/model/getDeploymentVariablesParams.ts +15 -0
- package/src/generated/model/getEvent200.ts +2917 -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 +63 -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 +58 -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 +93 -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/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 +292 -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 +33 -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 +72 -0
- package/src/generated/model/getGrantExpandItem.ts +29 -0
- package/src/generated/model/getGrantParams.ts +21 -0
- package/src/generated/model/getHealth4xx.ts +2 -2
- package/src/generated/model/getHealth4xxDetails.ts +1 -1
- package/src/generated/model/getHealthDefault.ts +13 -6
- 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 +54 -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 +54 -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 +54 -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 +54 -0
- package/src/generated/model/getMySessionCsrfTokenParams.ts +26 -0
- package/src/generated/model/getMySessionDefault.ts +40 -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 +40 -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 +54 -0
- package/src/generated/model/getMyUserSchemaParams.ts +26 -0
- package/src/generated/model/getProject200.ts +18 -3
- package/src/generated/model/getProject200OriginsItem.ts +23 -0
- package/src/generated/model/getProject200OriginsItemKind.ts +15 -0
- package/src/generated/model/getProject200PasswordHash.ts +42 -0
- package/src/generated/model/getProject200PasswordHashAlgorithm.ts +24 -0
- package/src/generated/model/getProject200PasswordHashParams.ts +47 -0
- package/src/generated/model/getProject200PasswordHashParamsHash.ts +24 -0
- 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 +58 -0
- package/src/generated/model/getReleaseById200PointersItemKind.ts +27 -0
- package/src/generated/model/getReleaseByIdDefault.ts +54 -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 +40 -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 +40 -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 +40 -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 +40 -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 +54 -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 +54 -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 +54 -0
- package/src/generated/model/getVariablesKind.ts +15 -0
- package/src/generated/model/getVariablesParams.ts +21 -0
- package/src/generated/model/index.ts +1346 -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 +81 -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/issueChallenge409.ts +20 -0
- package/src/generated/model/issueChallenge409Details.ts +12 -0
- 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 +65 -52
- package/src/generated/model/listBranding200Item.ts +14 -0
- package/src/generated/model/listBrandingDefault.ts +54 -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 +58 -0
- package/src/generated/model/listDeployments200DeploymentsItemReleasePointersItemKind.ts +27 -0
- package/src/generated/model/listDeployments200DeploymentsItemStatus.ts +22 -0
- package/src/generated/model/listDeployments200DeploymentsItemTargetsItem.ts +28 -0
- package/src/generated/model/listDeploymentsDefault.ts +54 -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 +2917 -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 +63 -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 +76 -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 +54 -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 +54 -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 +54 -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 +45 -0
- package/src/generated/model/listMyProjectsParams.ts +39 -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 +54 -0
- package/src/generated/model/listMyTeamsParams.ts +39 -0
- package/src/generated/model/listPreviews200.ts +20 -0
- package/src/generated/model/listPreviews200PreviewsItem.ts +38 -0
- package/src/generated/model/listPreviewsDefault.ts +63 -0
- package/src/generated/model/listPreviewsParams.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 +54 -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 +54 -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 +54 -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 +54 -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 +54 -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 +99 -0
- package/src/generated/model/patchMyUserParams.ts +26 -0
- package/src/generated/model/patchProject200.ts +34 -0
- package/src/generated/model/patchProject200OriginsItem.ts +23 -0
- package/src/generated/model/patchProject200OriginsItemKind.ts +15 -0
- package/src/generated/model/patchProject200PasswordHash.ts +42 -0
- package/src/generated/model/patchProject200PasswordHashAlgorithm.ts +24 -0
- package/src/generated/model/patchProject200PasswordHashParams.ts +47 -0
- package/src/generated/model/patchProject200PasswordHashParamsHash.ts +24 -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 +99 -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 +99 -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 +33 -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 +99 -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 +72 -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 +72 -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 +72 -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 +81 -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 +72 -0
- package/src/generated/model/queryUsersParams.ts +16 -0
- package/src/generated/model/removeOriginBody.ts +15 -0
- package/src/generated/model/removeOriginDefault.ts +81 -0
- package/src/generated/model/removePreviewBody.ts +23 -0
- package/src/generated/model/removePreviewDefault.ts +72 -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 +58 -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 +58 -0
- package/src/generated/model/revokeRelease200PointersItemKind.ts +27 -0
- package/src/generated/model/revokeRelease409.ts +19 -0
- package/src/generated/model/revokeRelease409Details.ts +16 -0
- package/src/generated/model/revokeRelease409DetailsOriginsItem.ts +17 -0
- package/src/generated/model/revokeReleaseDefault.ts +45 -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 +49 -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 +58 -0
- package/src/generated/model/rollbackDeployment200ReleasePointersItemKind.ts +27 -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 +58 -0
- package/src/generated/model/rollbackDeployment201ReleasePointersItemKind.ts +27 -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 +257 -0
- package/src/generated/model/rollbackDeploymentBody.ts +25 -0
- package/src/generated/model/rollbackDeploymentDefault.ts +72 -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 +94 -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 +93 -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/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 +93 -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/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 +310 -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 +99 -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 +144 -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 +155 -72
- package/src/generated/operations.ts +2104 -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 +358 -0
- package/src/runtime/fetch.ts +237 -6
- 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/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,740 @@
|
|
|
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,
|
|
79
|
+
getGetGrantUrl: () => getGetGrantUrl,
|
|
47
80
|
getGetHealthUrl: () => getGetHealthUrl,
|
|
48
|
-
|
|
81
|
+
getGetIdpByIdUrl: () => getGetIdpByIdUrl,
|
|
82
|
+
getGetIdpRevisionByIdUrl: () => getGetIdpRevisionByIdUrl,
|
|
49
83
|
getGetLiveUrl: () => getGetLiveUrl,
|
|
84
|
+
getGetMyPasswordStateUrl: () => getGetMyPasswordStateUrl,
|
|
85
|
+
getGetMySessionCsrfTokenUrl: () => getGetMySessionCsrfTokenUrl,
|
|
50
86
|
getGetMySessionUrl: () => getGetMySessionUrl,
|
|
87
|
+
getGetMyUserSchemaUrl: () => getGetMyUserSchemaUrl,
|
|
51
88
|
getGetMyUserUrl: () => getGetMyUserUrl,
|
|
52
|
-
getGetOpenIDConfigurationUrl: () => getGetOpenIDConfigurationUrl,
|
|
53
89
|
getGetProjectUrl: () => getGetProjectUrl,
|
|
54
90
|
getGetReadyUrl: () => getGetReadyUrl,
|
|
91
|
+
getGetReleaseByIdUrl: () => getGetReleaseByIdUrl,
|
|
55
92
|
getGetSchemaByIdUrl: () => getGetSchemaByIdUrl,
|
|
56
93
|
getGetSessionUrl: () => getGetSessionUrl,
|
|
57
94
|
getGetTeamUrl: () => getGetTeamUrl,
|
|
58
|
-
getGetTokenUrl: () => getGetTokenUrl,
|
|
59
95
|
getGetUserByIDUrl: () => getGetUserByIDUrl,
|
|
60
|
-
|
|
96
|
+
getGetUserPasswordStateUrl: () => getGetUserPasswordStateUrl,
|
|
97
|
+
getGetVariableUrl: () => getGetVariableUrl,
|
|
98
|
+
getGetVariablesUrl: () => getGetVariablesUrl,
|
|
99
|
+
getGrant: () => getGrant,
|
|
61
100
|
getHealth: () => getHealth,
|
|
62
|
-
|
|
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
|
+
getListPreviewsUrl: () => getListPreviewsUrl,
|
|
115
|
+
getListReleasesUrl: () => getListReleasesUrl,
|
|
116
|
+
getListSchemasUrl: () => getListSchemasUrl,
|
|
117
|
+
getListUserIdentityLinksUrl: () => getListUserIdentityLinksUrl,
|
|
118
|
+
getListUserPasskeysUrl: () => getListUserPasskeysUrl,
|
|
119
|
+
getListUserTeamsUrl: () => getListUserTeamsUrl,
|
|
68
120
|
getLive: () => getLive,
|
|
121
|
+
getMyPasswordState: () => getMyPasswordState,
|
|
69
122
|
getMySession: () => getMySession,
|
|
123
|
+
getMySessionCsrfToken: () => getMySessionCsrfToken,
|
|
70
124
|
getMyUser: () => getMyUser,
|
|
71
|
-
|
|
125
|
+
getMyUserSchema: () => getMyUserSchema,
|
|
126
|
+
getPatchMyUserUrl: () => getPatchMyUserUrl,
|
|
127
|
+
getPatchProjectUrl: () => getPatchProjectUrl,
|
|
128
|
+
getPatchUserByIDUrl: () => getPatchUserByIDUrl,
|
|
72
129
|
getProject: () => getProject,
|
|
130
|
+
getQueryGrantsUrl: () => getQueryGrantsUrl,
|
|
131
|
+
getQueryIdpsUrl: () => getQueryIdpsUrl,
|
|
132
|
+
getQueryProjectsUrl: () => getQueryProjectsUrl,
|
|
133
|
+
getQuerySessionsUrl: () => getQuerySessionsUrl,
|
|
134
|
+
getQueryTeamsUrl: () => getQueryTeamsUrl,
|
|
135
|
+
getQueryUsersUrl: () => getQueryUsersUrl,
|
|
73
136
|
getReady: () => getReady,
|
|
137
|
+
getReleaseById: () => getReleaseById,
|
|
138
|
+
getRemoveOriginUrl: () => getRemoveOriginUrl,
|
|
139
|
+
getRemovePreviewUrl: () => getRemovePreviewUrl,
|
|
74
140
|
getRevokeMySessionUrl: () => getRevokeMySessionUrl,
|
|
141
|
+
getRevokeReleaseUrl: () => getRevokeReleaseUrl,
|
|
75
142
|
getRevokeSessionUrl: () => getRevokeSessionUrl,
|
|
76
|
-
|
|
143
|
+
getRollbackDeploymentUrl: () => getRollbackDeploymentUrl,
|
|
77
144
|
getSchemaById: () => getSchemaById,
|
|
78
145
|
getSession: () => getSession,
|
|
79
146
|
getSetUserPasswordUrl: () => getSetUserPasswordUrl,
|
|
80
|
-
getSubmitFlowEventUrl: () => getSubmitFlowEventUrl,
|
|
81
147
|
getSubmitFlowStepUrl: () => getSubmitFlowStepUrl,
|
|
82
148
|
getTeam: () => getTeam,
|
|
83
|
-
|
|
84
|
-
|
|
149
|
+
getUpdateTeamUrl: () => getUpdateTeamUrl,
|
|
150
|
+
getUpdateVariablesUrl: () => getUpdateVariablesUrl,
|
|
85
151
|
getUserByID: () => getUserByID,
|
|
86
|
-
|
|
152
|
+
getUserPasswordState: () => getUserPasswordState,
|
|
153
|
+
getVariable: () => getVariable,
|
|
154
|
+
getVariables: () => getVariables,
|
|
87
155
|
getVerifyChallengeProofUrl: () => getVerifyChallengeProofUrl,
|
|
88
|
-
|
|
156
|
+
initClaim: () => initClaim,
|
|
89
157
|
issueChallenge: () => issueChallenge,
|
|
158
|
+
listBranding: () => listBranding,
|
|
159
|
+
listDeployments: () => listDeployments,
|
|
160
|
+
listEvents: () => listEvents,
|
|
90
161
|
listFlowDefinitions: () => listFlowDefinitions,
|
|
91
|
-
|
|
92
|
-
|
|
162
|
+
listIdpRevisions: () => listIdpRevisions,
|
|
163
|
+
listMyIdentityLinks: () => listMyIdentityLinks,
|
|
164
|
+
listMyPasskeys: () => listMyPasskeys,
|
|
165
|
+
listMyProjects: () => listMyProjects,
|
|
166
|
+
listMyTeams: () => listMyTeams,
|
|
167
|
+
listPreviews: () => listPreviews,
|
|
168
|
+
listReleases: () => listReleases,
|
|
169
|
+
listSchemas: () => listSchemas,
|
|
170
|
+
listUserIdentityLinks: () => listUserIdentityLinks,
|
|
171
|
+
listUserPasskeys: () => listUserPasskeys,
|
|
172
|
+
listUserTeams: () => listUserTeams,
|
|
173
|
+
patchMyUser: () => patchMyUser,
|
|
174
|
+
patchProject: () => patchProject,
|
|
175
|
+
patchUserByID: () => patchUserByID,
|
|
176
|
+
queryGrants: () => queryGrants,
|
|
177
|
+
queryIdps: () => queryIdps,
|
|
178
|
+
queryProjects: () => queryProjects,
|
|
179
|
+
querySessions: () => querySessions,
|
|
180
|
+
queryTeams: () => queryTeams,
|
|
181
|
+
queryUsers: () => queryUsers,
|
|
182
|
+
removeOrigin: () => removeOrigin,
|
|
183
|
+
removePreview: () => removePreview,
|
|
93
184
|
revokeMySession: () => revokeMySession,
|
|
185
|
+
revokeRelease: () => revokeRelease,
|
|
94
186
|
revokeSession: () => revokeSession,
|
|
95
|
-
|
|
187
|
+
rollbackDeployment: () => rollbackDeployment,
|
|
96
188
|
setUserPassword: () => setUserPassword,
|
|
97
|
-
submitFlowEvent: () => submitFlowEvent,
|
|
98
189
|
submitFlowStep: () => submitFlowStep,
|
|
99
|
-
|
|
190
|
+
updateTeam: () => updateTeam,
|
|
191
|
+
updateVariables: () => updateVariables,
|
|
100
192
|
verifyChallengeProof: () => verifyChallengeProof
|
|
101
193
|
});
|
|
102
|
-
const
|
|
103
|
-
return `${getProxyPath()}
|
|
194
|
+
const getGetHealthUrl = () => {
|
|
195
|
+
return `${getProxyPath()}/healthz`;
|
|
196
|
+
};
|
|
197
|
+
/**
|
|
198
|
+
* Check whether the server is healthy
|
|
199
|
+
* @summary Check server health
|
|
200
|
+
*/
|
|
201
|
+
const getHealth = async (options) => {
|
|
202
|
+
return customFetch(getGetHealthUrl(), {
|
|
203
|
+
...options,
|
|
204
|
+
method: "GET"
|
|
205
|
+
});
|
|
206
|
+
};
|
|
207
|
+
const getGetLiveUrl = () => {
|
|
208
|
+
return `${getProxyPath()}/livez`;
|
|
209
|
+
};
|
|
210
|
+
/**
|
|
211
|
+
* Check whether the server is started
|
|
212
|
+
* @summary Check server liveness
|
|
213
|
+
*/
|
|
214
|
+
const getLive = async (options) => {
|
|
215
|
+
return customFetch(getGetLiveUrl(), {
|
|
216
|
+
...options,
|
|
217
|
+
method: "GET"
|
|
218
|
+
});
|
|
219
|
+
};
|
|
220
|
+
const getGetReadyUrl = () => {
|
|
221
|
+
return `${getProxyPath()}/readyz`;
|
|
104
222
|
};
|
|
105
223
|
/**
|
|
106
|
-
*
|
|
107
|
-
* @summary
|
|
224
|
+
* Check whether the server is ready to accept requests
|
|
225
|
+
* @summary Check server readiness
|
|
108
226
|
*/
|
|
109
|
-
const
|
|
110
|
-
return customFetch(
|
|
227
|
+
const getReady = async (options) => {
|
|
228
|
+
return customFetch(getGetReadyUrl(), {
|
|
111
229
|
...options,
|
|
112
230
|
method: "GET"
|
|
113
231
|
});
|
|
114
232
|
};
|
|
115
|
-
const
|
|
233
|
+
const getCreateUserUrl = (params) => {
|
|
116
234
|
const normalizedParams = new URLSearchParams();
|
|
117
235
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
118
|
-
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : value
|
|
236
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
119
237
|
});
|
|
120
238
|
const stringifiedParams = normalizedParams.toString();
|
|
121
|
-
return stringifiedParams.length > 0 ? `${getProxyPath()}/
|
|
239
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/users?${stringifiedParams}` : `${getProxyPath()}/users`;
|
|
122
240
|
};
|
|
123
241
|
/**
|
|
124
|
-
*
|
|
242
|
+
* Creates a user whose attributes satisfy the user schema the request names.
|
|
243
|
+
*
|
|
244
|
+
* The server assigns the user's id. With `team_id`, the user also becomes an
|
|
245
|
+
* active member of that team. A value the schema marks unique that another
|
|
246
|
+
* user already holds is refused with `409`.
|
|
247
|
+
* @summary Create user
|
|
125
248
|
*/
|
|
126
|
-
const
|
|
127
|
-
|
|
249
|
+
const createUser = async (createUserBody, params, options) => {
|
|
250
|
+
const getHeaders = (h) => {
|
|
251
|
+
if (!h) return {};
|
|
252
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
253
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
254
|
+
const headers = {};
|
|
255
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
256
|
+
return headers;
|
|
257
|
+
};
|
|
258
|
+
return customFetch(getCreateUserUrl(params), {
|
|
128
259
|
...options,
|
|
129
|
-
method: "
|
|
260
|
+
method: "POST",
|
|
261
|
+
headers: {
|
|
262
|
+
"Content-Type": "application/json",
|
|
263
|
+
...getHeaders(options?.headers)
|
|
264
|
+
},
|
|
265
|
+
body: JSON.stringify(createUserBody)
|
|
130
266
|
});
|
|
131
267
|
};
|
|
132
|
-
const
|
|
268
|
+
const getQueryUsersUrl = (params) => {
|
|
133
269
|
const normalizedParams = new URLSearchParams();
|
|
134
270
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
135
|
-
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : value
|
|
271
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
136
272
|
});
|
|
137
273
|
const stringifiedParams = normalizedParams.toString();
|
|
138
|
-
return stringifiedParams.length > 0 ? `${getProxyPath()}/
|
|
274
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/users/query?${stringifiedParams}` : `${getProxyPath()}/users/query`;
|
|
139
275
|
};
|
|
140
276
|
/**
|
|
141
|
-
*
|
|
277
|
+
* Returns the users of a project, paginated with a cursor.
|
|
278
|
+
*
|
|
279
|
+
* `project_id` names the project to list; without it, the credential's own
|
|
280
|
+
* project is listed.
|
|
281
|
+
*
|
|
282
|
+
* Accepts either a project secret (`oauth2`) or a user-bound Console
|
|
283
|
+
* session cookie (`nextgenSession`). Cookie-authenticated requests
|
|
284
|
+
* follow the scheme's CSRF rules (`nextgenSession`).
|
|
285
|
+
* @summary Query users
|
|
142
286
|
*/
|
|
143
|
-
const
|
|
144
|
-
|
|
287
|
+
const queryUsers = async (queryUsersBody, params, options) => {
|
|
288
|
+
const getHeaders = (h) => {
|
|
289
|
+
if (!h) return {};
|
|
290
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
291
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
292
|
+
const headers = {};
|
|
293
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
294
|
+
return headers;
|
|
295
|
+
};
|
|
296
|
+
return customFetch(getQueryUsersUrl(params), {
|
|
145
297
|
...options,
|
|
146
|
-
method: "
|
|
298
|
+
method: "POST",
|
|
299
|
+
headers: {
|
|
300
|
+
"Content-Type": "application/json",
|
|
301
|
+
...getHeaders(options?.headers)
|
|
302
|
+
},
|
|
303
|
+
body: JSON.stringify(queryUsersBody)
|
|
147
304
|
});
|
|
148
305
|
};
|
|
149
|
-
const
|
|
306
|
+
const getGetUserByIDUrl = (userId, params) => {
|
|
150
307
|
const normalizedParams = new URLSearchParams();
|
|
151
308
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
152
|
-
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : value
|
|
309
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
153
310
|
});
|
|
154
311
|
const stringifiedParams = normalizedParams.toString();
|
|
155
|
-
return stringifiedParams.length > 0 ? `${getProxyPath()}/
|
|
312
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/users/${encodeURIComponent(String(userId))}?${stringifiedParams}` : `${getProxyPath()}/users/${encodeURIComponent(String(userId))}`;
|
|
156
313
|
};
|
|
157
314
|
/**
|
|
158
|
-
*
|
|
315
|
+
* Returns a user by its id, with the attributes its schema defines.
|
|
316
|
+
*
|
|
317
|
+
* With `team_id`, the user is returned only while they are an active member of
|
|
318
|
+
* that team.
|
|
319
|
+
* @summary Get user by ID
|
|
159
320
|
*/
|
|
160
|
-
const
|
|
161
|
-
return customFetch(
|
|
321
|
+
const getUserByID = async (userId, params, options) => {
|
|
322
|
+
return customFetch(getGetUserByIDUrl(userId, params), {
|
|
162
323
|
...options,
|
|
163
324
|
method: "GET"
|
|
164
325
|
});
|
|
165
326
|
};
|
|
166
|
-
const
|
|
167
|
-
return `${getProxyPath()}/
|
|
327
|
+
const getPatchUserByIDUrl = (userId) => {
|
|
328
|
+
return `${getProxyPath()}/users/${encodeURIComponent(String(userId))}`;
|
|
168
329
|
};
|
|
169
330
|
/**
|
|
170
|
-
*
|
|
331
|
+
* Partially updates a user's schema-defined attributes, and optionally
|
|
332
|
+
* moves the user to another registered schema. The merged result is
|
|
333
|
+
* validated against the schema before commit. Concurrent writes are
|
|
334
|
+
* last-write-wins.
|
|
335
|
+
* @summary Update user by ID
|
|
171
336
|
*/
|
|
172
|
-
const
|
|
173
|
-
const
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
337
|
+
const patchUserByID = async (userId, patchUserByIDBody, options) => {
|
|
338
|
+
const getHeaders = (h) => {
|
|
339
|
+
if (!h) return {};
|
|
340
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
341
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
342
|
+
const headers = {};
|
|
343
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
344
|
+
return headers;
|
|
345
|
+
};
|
|
346
|
+
return customFetch(getPatchUserByIDUrl(userId), {
|
|
177
347
|
...options,
|
|
178
|
-
method: "
|
|
348
|
+
method: "PATCH",
|
|
179
349
|
headers: {
|
|
180
|
-
"Content-Type": "application/
|
|
181
|
-
...options?.headers
|
|
350
|
+
"Content-Type": "application/json",
|
|
351
|
+
...getHeaders(options?.headers)
|
|
182
352
|
},
|
|
183
|
-
body:
|
|
353
|
+
body: JSON.stringify(patchUserByIDBody)
|
|
354
|
+
});
|
|
355
|
+
};
|
|
356
|
+
const getDeleteUserByIDUrl = (userId) => {
|
|
357
|
+
return `${getProxyPath()}/users/${encodeURIComponent(String(userId))}`;
|
|
358
|
+
};
|
|
359
|
+
/**
|
|
360
|
+
* Deletes a user and removes them from every team they belong to.
|
|
361
|
+
*
|
|
362
|
+
* The user is removed, not deactivated, and the deletion emits `user.deleted`.
|
|
363
|
+
* With a project secret the request is idempotent: deleting a user that exists
|
|
364
|
+
* in no project succeeds without changing anything.
|
|
365
|
+
* @summary Delete user by ID
|
|
366
|
+
*/
|
|
367
|
+
const deleteUserByID = async (userId, options) => {
|
|
368
|
+
return customFetch(getDeleteUserByIDUrl(userId), {
|
|
369
|
+
...options,
|
|
370
|
+
method: "DELETE"
|
|
371
|
+
});
|
|
372
|
+
};
|
|
373
|
+
const getListUserIdentityLinksUrl = (userId, params) => {
|
|
374
|
+
const normalizedParams = new URLSearchParams();
|
|
375
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
376
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
377
|
+
});
|
|
378
|
+
const stringifiedParams = normalizedParams.toString();
|
|
379
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/users/${encodeURIComponent(String(userId))}/identity_links?${stringifiedParams}` : `${getProxyPath()}/users/${encodeURIComponent(String(userId))}/identity_links`;
|
|
380
|
+
};
|
|
381
|
+
/**
|
|
382
|
+
* The identity provider accounts a sign-in linked to the user, oldest first.
|
|
383
|
+
* The provider's subject and claims are never returned.
|
|
384
|
+
* @summary List the provider accounts linked to a user
|
|
385
|
+
*/
|
|
386
|
+
const listUserIdentityLinks = async (userId, params, options) => {
|
|
387
|
+
return customFetch(getListUserIdentityLinksUrl(userId, params), {
|
|
388
|
+
...options,
|
|
389
|
+
method: "GET"
|
|
184
390
|
});
|
|
185
391
|
};
|
|
186
|
-
const
|
|
187
|
-
|
|
392
|
+
const getListUserPasskeysUrl = (userId, params) => {
|
|
393
|
+
const normalizedParams = new URLSearchParams();
|
|
394
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
395
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
396
|
+
});
|
|
397
|
+
const stringifiedParams = normalizedParams.toString();
|
|
398
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/users/${encodeURIComponent(String(userId))}/passkeys?${stringifiedParams}` : `${getProxyPath()}/users/${encodeURIComponent(String(userId))}/passkeys`;
|
|
188
399
|
};
|
|
189
400
|
/**
|
|
190
|
-
*
|
|
401
|
+
* Returns the passkeys registered for a user, newest first, paginated with a
|
|
402
|
+
* cursor.
|
|
403
|
+
*
|
|
404
|
+
* Each passkey carries its id, its name and when it was registered, never the
|
|
405
|
+
* credential itself.
|
|
406
|
+
* @summary List user passkeys
|
|
191
407
|
*/
|
|
192
|
-
const
|
|
193
|
-
return customFetch(
|
|
408
|
+
const listUserPasskeys = async (userId, params, options) => {
|
|
409
|
+
return customFetch(getListUserPasskeysUrl(userId, params), {
|
|
194
410
|
...options,
|
|
195
411
|
method: "GET"
|
|
196
412
|
});
|
|
197
413
|
};
|
|
198
|
-
const
|
|
199
|
-
return `${getProxyPath()}/
|
|
414
|
+
const getBeginUserPasskeyRegistrationUrl = (userId) => {
|
|
415
|
+
return `${getProxyPath()}/users/${encodeURIComponent(String(userId))}/passkeys/registrations`;
|
|
200
416
|
};
|
|
201
417
|
/**
|
|
202
|
-
*
|
|
418
|
+
* Starts a WebAuthn registration ceremony for the user and returns the
|
|
419
|
+
* creation options for `navigator.credentials.create()`. Complete the
|
|
420
|
+
* ceremony with `POST /users/{user_id}/passkeys/registrations/{registration_id}` within
|
|
421
|
+
* five minutes. Credentials already registered for the user are excluded
|
|
422
|
+
* automatically.
|
|
423
|
+
* @summary Begin passkey registration
|
|
203
424
|
*/
|
|
204
|
-
const
|
|
205
|
-
const
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
425
|
+
const beginUserPasskeyRegistration = async (userId, beginUserPasskeyRegistrationBody, options) => {
|
|
426
|
+
const getHeaders = (h) => {
|
|
427
|
+
if (!h) return {};
|
|
428
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
429
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
430
|
+
const headers = {};
|
|
431
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
432
|
+
return headers;
|
|
433
|
+
};
|
|
434
|
+
return customFetch(getBeginUserPasskeyRegistrationUrl(userId), {
|
|
209
435
|
...options,
|
|
210
436
|
method: "POST",
|
|
211
437
|
headers: {
|
|
212
|
-
"Content-Type": "application/
|
|
213
|
-
...options?.headers
|
|
438
|
+
"Content-Type": "application/json",
|
|
439
|
+
...getHeaders(options?.headers)
|
|
214
440
|
},
|
|
215
|
-
body:
|
|
441
|
+
body: JSON.stringify(beginUserPasskeyRegistrationBody)
|
|
216
442
|
});
|
|
217
443
|
};
|
|
218
|
-
const
|
|
219
|
-
return `${getProxyPath()}/
|
|
444
|
+
const getFinishUserPasskeyRegistrationUrl = (userId, registrationId) => {
|
|
445
|
+
return `${getProxyPath()}/users/${encodeURIComponent(String(userId))}/passkeys/registrations/${encodeURIComponent(String(registrationId))}`;
|
|
220
446
|
};
|
|
221
447
|
/**
|
|
222
|
-
*
|
|
448
|
+
* Verifies the attestation against the ceremony started by
|
|
449
|
+
* `POST /users/{user_id}/passkeys/registrations` and persists the new credential. A
|
|
450
|
+
* rejected attestation counts against the ceremony's failure budget and the
|
|
451
|
+
* ceremony stays open for a retry. An expired ceremony surfaces as
|
|
452
|
+
* `att.stale_challenge`; an unknown or already-consumed registration id
|
|
453
|
+
* surfaces as `att.not_found`.
|
|
454
|
+
* @summary Finish passkey registration
|
|
223
455
|
*/
|
|
224
|
-
const
|
|
225
|
-
const
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
return customFetch(getGetTokenUrl(), {
|
|
456
|
+
const finishUserPasskeyRegistration = async (userId, registrationId, finishUserPasskeyRegistrationBody, options) => {
|
|
457
|
+
const getHeaders = (h) => {
|
|
458
|
+
if (!h) return {};
|
|
459
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
460
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
461
|
+
const headers = {};
|
|
462
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
463
|
+
return headers;
|
|
464
|
+
};
|
|
465
|
+
return customFetch(getFinishUserPasskeyRegistrationUrl(userId, registrationId), {
|
|
235
466
|
...options,
|
|
236
467
|
method: "POST",
|
|
237
468
|
headers: {
|
|
238
|
-
"Content-Type": "application/
|
|
239
|
-
...options?.headers
|
|
469
|
+
"Content-Type": "application/json",
|
|
470
|
+
...getHeaders(options?.headers)
|
|
240
471
|
},
|
|
241
|
-
body:
|
|
472
|
+
body: JSON.stringify(finishUserPasskeyRegistrationBody)
|
|
242
473
|
});
|
|
243
474
|
};
|
|
244
|
-
const
|
|
245
|
-
return `${getProxyPath()}/
|
|
475
|
+
const getGetUserPasswordStateUrl = (userId) => {
|
|
476
|
+
return `${getProxyPath()}/users/${encodeURIComponent(String(userId))}/password`;
|
|
246
477
|
};
|
|
247
478
|
/**
|
|
248
|
-
*
|
|
479
|
+
* Reports when the user's current password was set, and leaves `set_at` out
|
|
480
|
+
* when the user has none. The password and its hash are never returned;
|
|
481
|
+
* setting one is `PUT` on the same path.
|
|
482
|
+
* @summary Get user password state
|
|
249
483
|
*/
|
|
250
|
-
const
|
|
251
|
-
return customFetch(
|
|
484
|
+
const getUserPasswordState = async (userId, options) => {
|
|
485
|
+
return customFetch(getGetUserPasswordStateUrl(userId), {
|
|
252
486
|
...options,
|
|
253
487
|
method: "GET"
|
|
254
488
|
});
|
|
255
489
|
};
|
|
256
|
-
const
|
|
257
|
-
return `${getProxyPath()}/
|
|
490
|
+
const getSetUserPasswordUrl = (userId) => {
|
|
491
|
+
return `${getProxyPath()}/users/${encodeURIComponent(String(userId))}/password`;
|
|
258
492
|
};
|
|
259
493
|
/**
|
|
260
|
-
*
|
|
261
|
-
*
|
|
494
|
+
* Sets a user's password, hashed with the project's current password hashing
|
|
495
|
+
* policy.
|
|
496
|
+
*
|
|
497
|
+
* The new password replaces the current one, and setting it emits
|
|
498
|
+
* `auth.factor.password.set`.
|
|
499
|
+
* @summary Set user password
|
|
262
500
|
*/
|
|
263
|
-
const
|
|
264
|
-
|
|
501
|
+
const setUserPassword = async (userId, setUserPasswordBody, options) => {
|
|
502
|
+
const getHeaders = (h) => {
|
|
503
|
+
if (!h) return {};
|
|
504
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
505
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
506
|
+
const headers = {};
|
|
507
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
508
|
+
return headers;
|
|
509
|
+
};
|
|
510
|
+
return customFetch(getSetUserPasswordUrl(userId), {
|
|
265
511
|
...options,
|
|
266
|
-
method: "
|
|
512
|
+
method: "PUT",
|
|
513
|
+
headers: {
|
|
514
|
+
"Content-Type": "application/json",
|
|
515
|
+
...getHeaders(options?.headers)
|
|
516
|
+
},
|
|
517
|
+
body: JSON.stringify(setUserPasswordBody)
|
|
267
518
|
});
|
|
268
519
|
};
|
|
269
|
-
const
|
|
270
|
-
|
|
520
|
+
const getListUserTeamsUrl = (userId, params) => {
|
|
521
|
+
const normalizedParams = new URLSearchParams();
|
|
522
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
523
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
524
|
+
});
|
|
525
|
+
const stringifiedParams = normalizedParams.toString();
|
|
526
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/users/${encodeURIComponent(String(userId))}/teams?${stringifiedParams}` : `${getProxyPath()}/users/${encodeURIComponent(String(userId))}/teams`;
|
|
271
527
|
};
|
|
272
528
|
/**
|
|
273
|
-
*
|
|
274
|
-
*
|
|
529
|
+
* The user's team roster, ordered by team name. Each entry carries the
|
|
530
|
+
* team's name, so a client renders a page without resolving ids one by one.
|
|
531
|
+
*
|
|
532
|
+
* This is the N:N roster and it is not lifecycle ownership: the single team
|
|
533
|
+
* that owns the user's lifecycle is reported as `metadata.lifecycle_owner_team_id`
|
|
534
|
+
* on the user read endpoints. Memberships the user was removed from are not
|
|
535
|
+
* returned.
|
|
536
|
+
* @summary List the teams a user belongs to
|
|
275
537
|
*/
|
|
276
|
-
const
|
|
277
|
-
return customFetch(
|
|
538
|
+
const listUserTeams = async (userId, params, options) => {
|
|
539
|
+
return customFetch(getListUserTeamsUrl(userId, params), {
|
|
278
540
|
...options,
|
|
279
541
|
method: "GET"
|
|
280
542
|
});
|
|
281
543
|
};
|
|
282
|
-
const
|
|
283
|
-
|
|
544
|
+
const getGetMyUserUrl = (params) => {
|
|
545
|
+
const normalizedParams = new URLSearchParams();
|
|
546
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
547
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
548
|
+
});
|
|
549
|
+
const stringifiedParams = normalizedParams.toString();
|
|
550
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/users/me?${stringifiedParams}` : `${getProxyPath()}/users/me`;
|
|
284
551
|
};
|
|
285
552
|
/**
|
|
286
|
-
*
|
|
287
|
-
*
|
|
553
|
+
* Returns the user signed in to the session that authenticates the request.
|
|
554
|
+
*
|
|
555
|
+
* The project and the user both come from the session cookie, so a caller only
|
|
556
|
+
* ever reads their own user.
|
|
557
|
+
*
|
|
558
|
+
* With `project_id`, the user is returned only when the session belongs to
|
|
559
|
+
* that project.
|
|
560
|
+
* @summary Get my user information
|
|
288
561
|
*/
|
|
289
|
-
const
|
|
290
|
-
return customFetch(
|
|
562
|
+
const getMyUser = async (params, options) => {
|
|
563
|
+
return customFetch(getGetMyUserUrl(params), {
|
|
291
564
|
...options,
|
|
292
565
|
method: "GET"
|
|
293
566
|
});
|
|
294
567
|
};
|
|
295
|
-
const
|
|
568
|
+
const getPatchMyUserUrl = (params) => {
|
|
296
569
|
const normalizedParams = new URLSearchParams();
|
|
297
570
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
298
|
-
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : value
|
|
571
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
299
572
|
});
|
|
300
573
|
const stringifiedParams = normalizedParams.toString();
|
|
301
|
-
return stringifiedParams.length > 0 ? `${getProxyPath()}/users?${stringifiedParams}` : `${getProxyPath()}/users`;
|
|
574
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/users/me?${stringifiedParams}` : `${getProxyPath()}/users/me`;
|
|
302
575
|
};
|
|
303
576
|
/**
|
|
304
|
-
*
|
|
577
|
+
* Partially updates the caller's own schema-defined attributes. The merged
|
|
578
|
+
* result is validated against the user's schema before commit. Concurrent
|
|
579
|
+
* writes are last-write-wins.
|
|
580
|
+
*
|
|
581
|
+
* With `project_id`, the user is updated only when the session belongs to
|
|
582
|
+
* that project.
|
|
583
|
+
* @summary Update my user information
|
|
305
584
|
*/
|
|
306
|
-
const
|
|
307
|
-
|
|
585
|
+
const patchMyUser = async (patchMyUserBody, params, options) => {
|
|
586
|
+
const getHeaders = (h) => {
|
|
587
|
+
if (!h) return {};
|
|
588
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
589
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
590
|
+
const headers = {};
|
|
591
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
592
|
+
return headers;
|
|
593
|
+
};
|
|
594
|
+
return customFetch(getPatchMyUserUrl(params), {
|
|
308
595
|
...options,
|
|
309
|
-
method: "
|
|
596
|
+
method: "PATCH",
|
|
310
597
|
headers: {
|
|
311
598
|
"Content-Type": "application/json",
|
|
312
|
-
...options?.headers
|
|
599
|
+
...getHeaders(options?.headers)
|
|
313
600
|
},
|
|
314
|
-
body: JSON.stringify(
|
|
601
|
+
body: JSON.stringify(patchMyUserBody)
|
|
315
602
|
});
|
|
316
603
|
};
|
|
317
|
-
const
|
|
604
|
+
const getListMyIdentityLinksUrl = (params) => {
|
|
318
605
|
const normalizedParams = new URLSearchParams();
|
|
319
606
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
320
|
-
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : value
|
|
607
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
321
608
|
});
|
|
322
609
|
const stringifiedParams = normalizedParams.toString();
|
|
323
|
-
return stringifiedParams.length > 0 ? `${getProxyPath()}/users?${stringifiedParams}` : `${getProxyPath()}/users`;
|
|
610
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/users/me/identity_links?${stringifiedParams}` : `${getProxyPath()}/users/me/identity_links`;
|
|
324
611
|
};
|
|
325
612
|
/**
|
|
326
|
-
*
|
|
613
|
+
* The identity provider accounts a sign-in linked to the signed-in user,
|
|
614
|
+
* oldest first. The provider's subject and claims are never returned.
|
|
615
|
+
*
|
|
616
|
+
* With `project_id`, the links are listed only when the session belongs to
|
|
617
|
+
* that project.
|
|
618
|
+
* @summary List the provider accounts linked to me
|
|
327
619
|
*/
|
|
328
|
-
const
|
|
329
|
-
return customFetch(
|
|
620
|
+
const listMyIdentityLinks = async (params, options) => {
|
|
621
|
+
return customFetch(getListMyIdentityLinksUrl(params), {
|
|
330
622
|
...options,
|
|
331
623
|
method: "GET"
|
|
332
624
|
});
|
|
333
625
|
};
|
|
334
|
-
const
|
|
626
|
+
const getListMyPasskeysUrl = (params) => {
|
|
335
627
|
const normalizedParams = new URLSearchParams();
|
|
336
628
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
337
|
-
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : value
|
|
629
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
338
630
|
});
|
|
339
631
|
const stringifiedParams = normalizedParams.toString();
|
|
340
|
-
return stringifiedParams.length > 0 ? `${getProxyPath()}/users
|
|
632
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/users/me/passkeys?${stringifiedParams}` : `${getProxyPath()}/users/me/passkeys`;
|
|
341
633
|
};
|
|
342
634
|
/**
|
|
343
|
-
*
|
|
635
|
+
* The signed-in user's own passkeys, newest first, paginated with a cursor.
|
|
636
|
+
* Each passkey carries its id, its name and when it was registered, never the
|
|
637
|
+
* credential itself.
|
|
638
|
+
*
|
|
639
|
+
* With `project_id`, the passkeys are listed only when the session belongs to
|
|
640
|
+
* that project.
|
|
641
|
+
* @summary List my passkeys
|
|
344
642
|
*/
|
|
345
|
-
const
|
|
346
|
-
return customFetch(
|
|
643
|
+
const listMyPasskeys = async (params, options) => {
|
|
644
|
+
return customFetch(getListMyPasskeysUrl(params), {
|
|
347
645
|
...options,
|
|
348
646
|
method: "GET"
|
|
349
647
|
});
|
|
350
648
|
};
|
|
351
|
-
const
|
|
649
|
+
const getGetMyPasswordStateUrl = (params) => {
|
|
352
650
|
const normalizedParams = new URLSearchParams();
|
|
353
651
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
354
|
-
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : value
|
|
652
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
355
653
|
});
|
|
356
654
|
const stringifiedParams = normalizedParams.toString();
|
|
357
|
-
return stringifiedParams.length > 0 ? `${getProxyPath()}/users
|
|
655
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/users/me/password?${stringifiedParams}` : `${getProxyPath()}/users/me/password`;
|
|
358
656
|
};
|
|
359
657
|
/**
|
|
360
|
-
*
|
|
658
|
+
* Reports when the signed-in user's current password was set, and leaves
|
|
659
|
+
* `set_at` out when they have none. The password and its hash are never
|
|
660
|
+
* returned.
|
|
661
|
+
*
|
|
662
|
+
* With `project_id`, the state is read only when the session belongs to that
|
|
663
|
+
* project.
|
|
664
|
+
* @summary Get my password state
|
|
361
665
|
*/
|
|
362
|
-
const
|
|
363
|
-
return customFetch(
|
|
666
|
+
const getMyPasswordState = async (params, options) => {
|
|
667
|
+
return customFetch(getGetMyPasswordStateUrl(params), {
|
|
364
668
|
...options,
|
|
365
|
-
method: "
|
|
366
|
-
headers: {
|
|
367
|
-
"Content-Type": "application/json",
|
|
368
|
-
...options?.headers
|
|
369
|
-
},
|
|
370
|
-
body: JSON.stringify(setUserPasswordBody)
|
|
669
|
+
method: "GET"
|
|
371
670
|
});
|
|
372
671
|
};
|
|
373
|
-
const
|
|
374
|
-
|
|
672
|
+
const getListMyProjectsUrl = (params) => {
|
|
673
|
+
const normalizedParams = new URLSearchParams();
|
|
674
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
675
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
676
|
+
});
|
|
677
|
+
const stringifiedParams = normalizedParams.toString();
|
|
678
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/users/me/projects?${stringifiedParams}` : `${getProxyPath()}/users/me/projects`;
|
|
375
679
|
};
|
|
376
680
|
/**
|
|
377
|
-
*
|
|
681
|
+
* The projects the signed-in user holds an active grant on, either directly or
|
|
682
|
+
* through a team they are a member of. Ordered by project id and paged with an
|
|
683
|
+
* opaque cursor.
|
|
684
|
+
*
|
|
685
|
+
* This is not the same question as `queryProjects`, which answers with the one
|
|
686
|
+
* project the calling credential is bound to. Here the session is the caller
|
|
687
|
+
* and the grants are the answer, so the list spans projects.
|
|
688
|
+
*
|
|
689
|
+
* With `project_id`, the projects are listed only when the session belongs to
|
|
690
|
+
* that project. It names the project the session was signed in to, not one to
|
|
691
|
+
* list.
|
|
692
|
+
* @summary List the projects I can act on
|
|
693
|
+
*/
|
|
694
|
+
const listMyProjects = async (params, options) => {
|
|
695
|
+
return customFetch(getListMyProjectsUrl(params), {
|
|
696
|
+
...options,
|
|
697
|
+
method: "GET"
|
|
698
|
+
});
|
|
699
|
+
};
|
|
700
|
+
const getGetMyUserSchemaUrl = (params) => {
|
|
701
|
+
const normalizedParams = new URLSearchParams();
|
|
702
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
703
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
704
|
+
});
|
|
705
|
+
const stringifiedParams = normalizedParams.toString();
|
|
706
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/users/me/schema?${stringifiedParams}` : `${getProxyPath()}/users/me/schema`;
|
|
707
|
+
};
|
|
708
|
+
/**
|
|
709
|
+
* The schema the signed-in user's own record is validated against.
|
|
710
|
+
*
|
|
711
|
+
* With `project_id`, the schema is returned only when the session belongs to
|
|
712
|
+
* that project.
|
|
713
|
+
* @summary Get my user schema
|
|
714
|
+
*/
|
|
715
|
+
const getMyUserSchema = async (params, options) => {
|
|
716
|
+
return customFetch(getGetMyUserSchemaUrl(params), {
|
|
717
|
+
...options,
|
|
718
|
+
method: "GET"
|
|
719
|
+
});
|
|
720
|
+
};
|
|
721
|
+
const getListMyTeamsUrl = (params) => {
|
|
722
|
+
const normalizedParams = new URLSearchParams();
|
|
723
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
724
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
725
|
+
});
|
|
726
|
+
const stringifiedParams = normalizedParams.toString();
|
|
727
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/users/me/teams?${stringifiedParams}` : `${getProxyPath()}/users/me/teams`;
|
|
728
|
+
};
|
|
729
|
+
/**
|
|
730
|
+
* The signed-in user's own team roster, ordered by team name.
|
|
731
|
+
*
|
|
732
|
+
* With `project_id`, the teams are listed only when the session belongs to
|
|
733
|
+
* that project.
|
|
734
|
+
* @summary List the teams I belong to
|
|
378
735
|
*/
|
|
379
|
-
const
|
|
380
|
-
return customFetch(
|
|
736
|
+
const listMyTeams = async (params, options) => {
|
|
737
|
+
return customFetch(getListMyTeamsUrl(params), {
|
|
381
738
|
...options,
|
|
382
739
|
method: "GET"
|
|
383
740
|
});
|
|
@@ -387,37 +744,60 @@ const getCreateFlowUrl = () => {
|
|
|
387
744
|
};
|
|
388
745
|
/**
|
|
389
746
|
* 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
|
-
|
|
747
|
+
* the first capability step. Creates a new session implicitly unless
|
|
748
|
+
* `session_id` is provided, together with that session's `session_token`
|
|
749
|
+
* (for step-up / reauth on an existing session).
|
|
750
|
+
*
|
|
751
|
+
* The browser `Origin` header selects which deployment serves this attempt:
|
|
752
|
+
* the gate admits the origin against the project's origin patterns and live
|
|
753
|
+
* previews, the newest deployment to that exact origin is the target, and
|
|
754
|
+
* that deployment's release supplies flow definitions, user schemas and
|
|
755
|
+
* branding. The resolved deployment is sealed into the `_zflow` cookie so
|
|
756
|
+
* later steps keep the same configuration. An origin that matches no pattern
|
|
757
|
+
* answers `403` with `proj.origin_not_allowed`; one that matches a preview
|
|
758
|
+
* pattern with no live preview answers `403` with `proj.preview_not_live`;
|
|
759
|
+
* nothing deployed to the target answers `409` with `rel.not_deployed`; a
|
|
760
|
+
* revoked release answers `409` with `rel.revoked`. A request with no
|
|
761
|
+
* `Origin` passes the gate and still needs a deployment target.
|
|
762
|
+
*
|
|
763
|
+
* The response contains an `id` field — the flow handle. Use it as the path
|
|
764
|
+
* parameter for all subsequent `/flow/{id}/submit` calls.
|
|
765
|
+
*
|
|
766
|
+
* The response also sets an encrypted `HttpOnly` cookie (`_zflow`) containing
|
|
767
|
+
* the flow's orchestration state (current step, collected data, history).
|
|
768
|
+
* The server is stateless between requests — all flow state lives in this
|
|
769
|
+
* cookie. The browser sends it automatically on subsequent requests.
|
|
401
770
|
* @summary Start a new flow
|
|
402
771
|
*/
|
|
403
772
|
const createFlow = async (createFlowBody, options) => {
|
|
773
|
+
const getHeaders = (h) => {
|
|
774
|
+
if (!h) return {};
|
|
775
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
776
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
777
|
+
const headers = {};
|
|
778
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
779
|
+
return headers;
|
|
780
|
+
};
|
|
404
781
|
return customFetch(getCreateFlowUrl(), {
|
|
405
782
|
...options,
|
|
406
783
|
method: "POST",
|
|
407
784
|
headers: {
|
|
408
785
|
"Content-Type": "application/json",
|
|
409
|
-
...options?.headers
|
|
786
|
+
...getHeaders(options?.headers)
|
|
410
787
|
},
|
|
411
788
|
body: JSON.stringify(createFlowBody)
|
|
412
789
|
});
|
|
413
790
|
};
|
|
414
791
|
const getGetFlowStepUrl = (id) => {
|
|
415
|
-
return `${getProxyPath()}/flow/${id}`;
|
|
792
|
+
return `${getProxyPath()}/flow/${encodeURIComponent(String(id))}`;
|
|
416
793
|
};
|
|
417
794
|
/**
|
|
418
795
|
* Returns the current capability step without advancing the state machine.
|
|
419
|
-
Useful for page reloads or re-rendering after a network error.
|
|
420
|
-
|
|
796
|
+
* Useful for page reloads or re-rendering after a network error.
|
|
797
|
+
*
|
|
798
|
+
* Reuses the deployment sealed into `_zflow` at `createFlow`; it does not
|
|
799
|
+
* re-resolve from `Origin`. If that release was revoked since the attempt
|
|
800
|
+
* started, the response is `409` with `rel.revoked`.
|
|
421
801
|
* @summary Get current step (re-render)
|
|
422
802
|
*/
|
|
423
803
|
const getFlowStep = async (id, options) => {
|
|
@@ -427,107 +807,134 @@ const getFlowStep = async (id, options) => {
|
|
|
427
807
|
});
|
|
428
808
|
};
|
|
429
809
|
const getSubmitFlowStepUrl = (id) => {
|
|
430
|
-
return `${getProxyPath()}/flow/${id}/submit`;
|
|
810
|
+
return `${getProxyPath()}/flow/${encodeURIComponent(String(id))}/submit`;
|
|
431
811
|
};
|
|
432
812
|
/**
|
|
433
813
|
* 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
|
-
|
|
814
|
+
* processes (e.g., verifies a credential), advances the state machine
|
|
815
|
+
* through any invisible steps, and returns the next visible step.
|
|
816
|
+
*
|
|
817
|
+
* The response sets an updated encrypted `HttpOnly` cookie (`_zflow`)
|
|
818
|
+
* with the new flow state. The server is stateless — all orchestration
|
|
819
|
+
* state is carried in this cookie between requests.
|
|
820
|
+
*
|
|
821
|
+
* **Important:** The `id` in the response may differ from the `id` used in
|
|
822
|
+
* the request. This happens when a flow pivots (pushes a new flow onto the
|
|
823
|
+
* stack) or when a stacked flow completes (auto-pops to the parent flow).
|
|
824
|
+
* Always use the `id` from the latest response for the next request.
|
|
825
|
+
*
|
|
826
|
+
* ## Flow completion
|
|
827
|
+
*
|
|
828
|
+
* When `step.type` is `complete`, the flow is terminal. The `step.behavior`
|
|
829
|
+
* field tells the frontend what to do:
|
|
830
|
+
*
|
|
831
|
+
* | `behavior` | Action |
|
|
832
|
+
* |------------- |------------------------------------------------------------|
|
|
833
|
+
* | `redirect` | Navigate to `redirect_uri` (OIDC/SAML auth request done). |
|
|
834
|
+
* | `show` | Render the step as a success screen (e.g., registration). |
|
|
835
|
+
*
|
|
836
|
+
* A `complete` step is only returned when the **entire flow stack** is done.
|
|
837
|
+
* If a stacked flow (e.g., recovery pivoted from login) finishes, the server
|
|
838
|
+
* auto-pops to the parent flow and returns the parent's next step — the
|
|
839
|
+
* frontend never sees a `complete` for intermediate flows.
|
|
840
|
+
*
|
|
841
|
+
* ## External sign-in
|
|
842
|
+
*
|
|
843
|
+
* `{action: "sso", sso_provider_id, return_target}` on a step that offers
|
|
844
|
+
* `sso_providers` returns the engine-emitted `sso-redirect` step, whose
|
|
845
|
+
* `redirect_url` the frontend navigates to.
|
|
846
|
+
*
|
|
847
|
+
* - The flow state does not change, but `_zflow` is re-sealed like on
|
|
848
|
+
* every response, so its ten-minute window restarts at this submission;
|
|
849
|
+
* the external sign-in and the return must complete within it.
|
|
850
|
+
* - A second `Set-Cookie` line carries the browser-binding cookie the
|
|
851
|
+
* callback checks: `HttpOnly`, `Path=/`, `SameSite=Lax`.
|
|
852
|
+
* - On every host except http loopback it is `__Host-_zsso` with `Secure`.
|
|
853
|
+
* - When the request host is http loopback (local development, where
|
|
854
|
+
* Safari rejects `Secure`), it is `_zsso` with no `Secure`; the
|
|
855
|
+
* `__Host-` prefix is dropped because it requires `Secure`.
|
|
856
|
+
*
|
|
857
|
+
* A connection whose `client_id` is a `${{ NAME }}` reference has it filled
|
|
858
|
+
* from the project's variables. A provider the engine cannot start a
|
|
859
|
+
* sign-in with, including a reference with no variable behind it,
|
|
860
|
+
* re-renders the step with `error.sso_unavailable`.
|
|
861
|
+
*
|
|
862
|
+
* Reuses the deployment sealed into `_zflow` at `createFlow`; it does not
|
|
863
|
+
* re-resolve from `Origin`. If that release was revoked since the attempt
|
|
864
|
+
* started, the response is `409` with `rel.revoked`.
|
|
461
865
|
* @summary Submit step data and advance
|
|
462
866
|
*/
|
|
463
867
|
const submitFlowStep = async (id, submitFlowStepBody, options) => {
|
|
868
|
+
const getHeaders = (h) => {
|
|
869
|
+
if (!h) return {};
|
|
870
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
871
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
872
|
+
const headers = {};
|
|
873
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
874
|
+
return headers;
|
|
875
|
+
};
|
|
464
876
|
return customFetch(getSubmitFlowStepUrl(id), {
|
|
465
877
|
...options,
|
|
466
878
|
method: "POST",
|
|
467
879
|
headers: {
|
|
468
880
|
"Content-Type": "application/json",
|
|
469
|
-
...options?.headers
|
|
881
|
+
...getHeaders(options?.headers)
|
|
470
882
|
},
|
|
471
883
|
body: JSON.stringify(submitFlowStepBody)
|
|
472
884
|
});
|
|
473
885
|
};
|
|
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
886
|
const getCreateAuthAttemptUrl = () => {
|
|
495
887
|
return `${getProxyPath()}/auth_attempts`;
|
|
496
888
|
};
|
|
497
889
|
/**
|
|
498
890
|
* 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
|
-
|
|
891
|
+
*
|
|
892
|
+
* An attempt is an ephemeral (15-minute TTL) state machine that drives a single authentication round.
|
|
893
|
+
* It accepts factor challenges, verifies proofs, and completes into a session or handoff token.
|
|
894
|
+
*
|
|
895
|
+
* Accepts a project_id and challenge_nonce (from POST /bootstrap/challenge). For step-up re-auth,
|
|
896
|
+
* also include session_id and that session's session_token to add factors to an existing session.
|
|
897
|
+
*
|
|
898
|
+
* The project comes from the project secret. A body `project_id` that disagrees
|
|
899
|
+
* answers `403` with `proj.mismatch`. The attempt resolves a deployment the
|
|
900
|
+
* same way as other runtime operations and seals it; with no browser `Origin`
|
|
901
|
+
* and nothing deployed to the resolved target the response is `409` with
|
|
902
|
+
* `rel.not_deployed`. A revoked release answers `409` with `rel.revoked`.
|
|
506
903
|
* @summary Create a new authentication attempt
|
|
507
904
|
*/
|
|
508
905
|
const createAuthAttempt = async (createAuthAttemptBody, options) => {
|
|
906
|
+
const getHeaders = (h) => {
|
|
907
|
+
if (!h) return {};
|
|
908
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
909
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
910
|
+
const headers = {};
|
|
911
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
912
|
+
return headers;
|
|
913
|
+
};
|
|
509
914
|
return customFetch(getCreateAuthAttemptUrl(), {
|
|
510
915
|
...options,
|
|
511
916
|
method: "POST",
|
|
512
917
|
headers: {
|
|
513
918
|
"Content-Type": "application/json",
|
|
514
|
-
...options?.headers
|
|
919
|
+
...getHeaders(options?.headers)
|
|
515
920
|
},
|
|
516
921
|
body: JSON.stringify(createAuthAttemptBody)
|
|
517
922
|
});
|
|
518
923
|
};
|
|
519
924
|
const getGetAuthAttemptUrl = (attemptId) => {
|
|
520
|
-
return `${getProxyPath()}/auth_attempts/${attemptId}`;
|
|
925
|
+
return `${getProxyPath()}/auth_attempts/${encodeURIComponent(String(attemptId))}`;
|
|
521
926
|
};
|
|
522
927
|
/**
|
|
523
928
|
* 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
|
-
|
|
929
|
+
*
|
|
930
|
+
* Returns the attempt's state, available factors for the next challenge,
|
|
931
|
+
* challenges issued so far, and any errors preventing progress.
|
|
932
|
+
*
|
|
933
|
+
* Use this for polling during long-running factor verifications (e.g., waiting for
|
|
934
|
+
* a federated IdP callback or a device flow).
|
|
935
|
+
*
|
|
936
|
+
* Reuses the deployment sealed when the attempt was created. If that release
|
|
937
|
+
* was revoked since, the response is `409` with `rel.revoked`.
|
|
531
938
|
* @summary Get authentication attempt state
|
|
532
939
|
*/
|
|
533
940
|
const getAuthAttempt = async (attemptId, options) => {
|
|
@@ -537,72 +944,94 @@ const getAuthAttempt = async (attemptId, options) => {
|
|
|
537
944
|
});
|
|
538
945
|
};
|
|
539
946
|
const getIssueChallengeUrl = (attemptId) => {
|
|
540
|
-
return `${getProxyPath()}/auth_attempts/${attemptId}/challenges`;
|
|
947
|
+
return `${getProxyPath()}/auth_attempts/${encodeURIComponent(String(attemptId))}/challenges`;
|
|
541
948
|
};
|
|
542
949
|
/**
|
|
543
950
|
* 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
|
-
|
|
951
|
+
*
|
|
952
|
+
* This advances the authentication state machine by requesting a specific factor method
|
|
953
|
+
* (password, passkey, TOTP, OTP via SMS, etc.). The server responds with challenge details
|
|
954
|
+
* including method, metadata, and any UI hints. The client then verifies the proof
|
|
955
|
+
* by calling POST /auth_attempts/{attempt_id}/challenges/{challenge_id}/verify.
|
|
956
|
+
*
|
|
957
|
+
* Reuses the deployment sealed when the attempt was created. If that release
|
|
958
|
+
* was revoked since, the response is `409` with `rel.revoked`.
|
|
550
959
|
* @summary Issue a factor challenge
|
|
551
960
|
*/
|
|
552
961
|
const issueChallenge = async (attemptId, issueChallengeBody, options) => {
|
|
962
|
+
const getHeaders = (h) => {
|
|
963
|
+
if (!h) return {};
|
|
964
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
965
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
966
|
+
const headers = {};
|
|
967
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
968
|
+
return headers;
|
|
969
|
+
};
|
|
553
970
|
return customFetch(getIssueChallengeUrl(attemptId), {
|
|
554
971
|
...options,
|
|
555
972
|
method: "POST",
|
|
556
973
|
headers: {
|
|
557
974
|
"Content-Type": "application/json",
|
|
558
|
-
...options?.headers
|
|
975
|
+
...getHeaders(options?.headers)
|
|
559
976
|
},
|
|
560
977
|
body: JSON.stringify(issueChallengeBody)
|
|
561
978
|
});
|
|
562
979
|
};
|
|
563
980
|
const getVerifyChallengeProofUrl = (attemptId, challengeId) => {
|
|
564
|
-
return `${getProxyPath()}/auth_attempts/${attemptId}/challenges/${challengeId}/verify`;
|
|
981
|
+
return `${getProxyPath()}/auth_attempts/${encodeURIComponent(String(attemptId))}/challenges/${encodeURIComponent(String(challengeId))}/verify`;
|
|
565
982
|
};
|
|
566
983
|
/**
|
|
567
984
|
* 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
|
-
|
|
985
|
+
*
|
|
986
|
+
* The proof format depends on the challenge method. For example:
|
|
987
|
+
* - `password` method: { password: "…" }
|
|
988
|
+
* - `totp` method: { totp: { code: "123456" } }
|
|
989
|
+
* - `passkey` method: { passkey: { assertion: "…" } }
|
|
990
|
+
* - `recovery_code` method: { recovery_code: "…" }
|
|
991
|
+
*
|
|
992
|
+
* On successful verification, the factor is written to the auth attempt.
|
|
993
|
+
* The attempt moves to the next pending challenge or completes if all required factors are verified.
|
|
994
|
+
*
|
|
995
|
+
* Reuses the deployment sealed when the attempt was created. If that release
|
|
996
|
+
* was revoked since, the response is `409` with `rel.revoked`.
|
|
578
997
|
* @summary Verify a factor proof
|
|
579
998
|
*/
|
|
580
999
|
const verifyChallengeProof = async (attemptId, challengeId, verifyChallengeProofBody, options) => {
|
|
1000
|
+
const getHeaders = (h) => {
|
|
1001
|
+
if (!h) return {};
|
|
1002
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1003
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
1004
|
+
const headers = {};
|
|
1005
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
1006
|
+
return headers;
|
|
1007
|
+
};
|
|
581
1008
|
return customFetch(getVerifyChallengeProofUrl(attemptId, challengeId), {
|
|
582
1009
|
...options,
|
|
583
1010
|
method: "POST",
|
|
584
1011
|
headers: {
|
|
585
1012
|
"Content-Type": "application/json",
|
|
586
|
-
...options?.headers
|
|
1013
|
+
...getHeaders(options?.headers)
|
|
587
1014
|
},
|
|
588
1015
|
body: JSON.stringify(verifyChallengeProofBody)
|
|
589
1016
|
});
|
|
590
1017
|
};
|
|
591
1018
|
const getCreateHandoffUrl = (attemptId) => {
|
|
592
|
-
return `${getProxyPath()}/auth_attempts/${attemptId}/handoff`;
|
|
1019
|
+
return `${getProxyPath()}/auth_attempts/${encodeURIComponent(String(attemptId))}/handoff`;
|
|
593
1020
|
};
|
|
594
1021
|
/**
|
|
595
1022
|
* 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
|
-
|
|
1023
|
+
*
|
|
1024
|
+
* Call this after all required factors have been verified and the attempt is in `completed` state.
|
|
1025
|
+
* The handoff token is short-lived (≤60 seconds) and must be exchanged at
|
|
1026
|
+
* POST /sessions/exchange to receive the final session and session_token.
|
|
1027
|
+
*
|
|
1028
|
+
* The handoff token is:
|
|
1029
|
+
* - Single-use (atomic exchange, no retry)
|
|
1030
|
+
* - Audience-bound (requires matching project key for exchange)
|
|
1031
|
+
* - Idempotency-safe within a 5-minute window (see conventions)
|
|
1032
|
+
*
|
|
1033
|
+
* Reuses the deployment sealed when the attempt was created. If that release
|
|
1034
|
+
* was revoked since, the response is `409` with `rel.revoked`.
|
|
606
1035
|
* @summary Complete authentication and create handoff token
|
|
607
1036
|
*/
|
|
608
1037
|
const createHandoff = async (attemptId, options) => {
|
|
@@ -615,25 +1044,69 @@ const getCreateProjectUrl = () => {
|
|
|
615
1044
|
return `${getProxyPath()}/projects`;
|
|
616
1045
|
};
|
|
617
1046
|
/**
|
|
1047
|
+
* Creates a project and returns its project secret and preview secret, which no
|
|
1048
|
+
* other endpoint returns.
|
|
1049
|
+
*
|
|
1050
|
+
* The request needs no credential and is rate-limited. Unless `seed_defaults` is
|
|
1051
|
+
* `false`, the project starts with a default user schema and flow; the CLI turns
|
|
1052
|
+
* that off and uploads its own from `.zitadel/`.
|
|
618
1053
|
* @summary Create project
|
|
619
1054
|
*/
|
|
620
1055
|
const createProject = async (createProjectBody, options) => {
|
|
1056
|
+
const getHeaders = (h) => {
|
|
1057
|
+
if (!h) return {};
|
|
1058
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1059
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
1060
|
+
const headers = {};
|
|
1061
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
1062
|
+
return headers;
|
|
1063
|
+
};
|
|
621
1064
|
return customFetch(getCreateProjectUrl(), {
|
|
622
1065
|
...options,
|
|
623
1066
|
method: "POST",
|
|
624
1067
|
headers: {
|
|
625
1068
|
"Content-Type": "application/json",
|
|
626
|
-
...options?.headers
|
|
1069
|
+
...getHeaders(options?.headers)
|
|
627
1070
|
},
|
|
628
1071
|
body: JSON.stringify(createProjectBody)
|
|
629
1072
|
});
|
|
630
1073
|
};
|
|
1074
|
+
const getQueryProjectsUrl = () => {
|
|
1075
|
+
return `${getProxyPath()}/projects/query`;
|
|
1076
|
+
};
|
|
1077
|
+
/**
|
|
1078
|
+
* Returns the project the project secret belongs to, as a page of at most one
|
|
1079
|
+
* project.
|
|
1080
|
+
*
|
|
1081
|
+
* A credential is scoped to one project until ADR 036 widens it, so the filters
|
|
1082
|
+
* and sorting apply to that project alone. The projects a signed-in person can
|
|
1083
|
+
* act on are listed by `GET /users/me/projects`.
|
|
1084
|
+
* @summary Query projects
|
|
1085
|
+
*/
|
|
1086
|
+
const queryProjects = async (queryProjectsBody, options) => {
|
|
1087
|
+
const getHeaders = (h) => {
|
|
1088
|
+
if (!h) return {};
|
|
1089
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1090
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
1091
|
+
const headers = {};
|
|
1092
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
1093
|
+
return headers;
|
|
1094
|
+
};
|
|
1095
|
+
return customFetch(getQueryProjectsUrl(), {
|
|
1096
|
+
...options,
|
|
1097
|
+
method: "POST",
|
|
1098
|
+
headers: {
|
|
1099
|
+
"Content-Type": "application/json",
|
|
1100
|
+
...getHeaders(options?.headers)
|
|
1101
|
+
},
|
|
1102
|
+
body: JSON.stringify(queryProjectsBody)
|
|
1103
|
+
});
|
|
1104
|
+
};
|
|
631
1105
|
const getGetProjectUrl = (projectId) => {
|
|
632
|
-
return `${getProxyPath()}/projects/${projectId}`;
|
|
1106
|
+
return `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}`;
|
|
633
1107
|
};
|
|
634
1108
|
/**
|
|
635
1109
|
* Returns the current state of a project.
|
|
636
|
-
|
|
637
1110
|
* @summary Get project
|
|
638
1111
|
*/
|
|
639
1112
|
const getProject = async (projectId, options) => {
|
|
@@ -642,219 +1115,566 @@ const getProject = async (projectId, options) => {
|
|
|
642
1115
|
method: "GET"
|
|
643
1116
|
});
|
|
644
1117
|
};
|
|
645
|
-
const
|
|
646
|
-
return `${getProxyPath()}/
|
|
1118
|
+
const getPatchProjectUrl = (projectId) => {
|
|
1119
|
+
return `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}`;
|
|
647
1120
|
};
|
|
648
1121
|
/**
|
|
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
|
|
1122
|
+
* Updates the state of a project.
|
|
1123
|
+
* @summary Update project
|
|
664
1124
|
*/
|
|
665
|
-
const
|
|
666
|
-
|
|
1125
|
+
const patchProject = async (projectId, patchProjectBody, options) => {
|
|
1126
|
+
const getHeaders = (h) => {
|
|
1127
|
+
if (!h) return {};
|
|
1128
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1129
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
1130
|
+
const headers = {};
|
|
1131
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
1132
|
+
return headers;
|
|
1133
|
+
};
|
|
1134
|
+
return customFetch(getPatchProjectUrl(projectId), {
|
|
667
1135
|
...options,
|
|
668
|
-
method: "
|
|
1136
|
+
method: "PATCH",
|
|
669
1137
|
headers: {
|
|
670
1138
|
"Content-Type": "application/json",
|
|
671
|
-
...options?.headers
|
|
1139
|
+
...getHeaders(options?.headers)
|
|
672
1140
|
},
|
|
673
|
-
body: JSON.stringify(
|
|
1141
|
+
body: JSON.stringify(patchProjectBody)
|
|
1142
|
+
});
|
|
1143
|
+
};
|
|
1144
|
+
const getInitClaimUrl = (projectId) => {
|
|
1145
|
+
return `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}/claim/init`;
|
|
1146
|
+
};
|
|
1147
|
+
/**
|
|
1148
|
+
* Starts a claim challenge for an unclaimed project. Authenticated by the
|
|
1149
|
+
* project secret, this mints a single-use, short-lived challenge and returns
|
|
1150
|
+
* the `claim_url` the developer opens in a browser to complete the claim,
|
|
1151
|
+
* together with the `challenge_id` the CLI polls with. The exact expiry is
|
|
1152
|
+
* carried by `expires_at` on the response.
|
|
1153
|
+
* @summary Initialize a project claim
|
|
1154
|
+
*/
|
|
1155
|
+
const initClaim = async (projectId, options) => {
|
|
1156
|
+
return customFetch(getInitClaimUrl(projectId), {
|
|
1157
|
+
...options,
|
|
1158
|
+
method: "POST"
|
|
674
1159
|
});
|
|
675
1160
|
};
|
|
676
|
-
const
|
|
1161
|
+
const getGetClaimStatusUrl = (projectId, params) => {
|
|
677
1162
|
const normalizedParams = new URLSearchParams();
|
|
678
1163
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
679
|
-
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : value
|
|
1164
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
680
1165
|
});
|
|
681
1166
|
const stringifiedParams = normalizedParams.toString();
|
|
682
|
-
return stringifiedParams.length > 0 ? `${getProxyPath()}/
|
|
1167
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}/claim/status?${stringifiedParams}` : `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}/claim/status`;
|
|
683
1168
|
};
|
|
684
1169
|
/**
|
|
685
|
-
*
|
|
686
|
-
|
|
687
|
-
|
|
688
|
-
*
|
|
1170
|
+
* Polled by the CLI while a browser completes the claim. Authorized by the
|
|
1171
|
+
* project secret that initiated the challenge. Returns `pending`, or
|
|
1172
|
+
* `completed` with the owning team, the claim timestamp, and the dashboard
|
|
1173
|
+
* URL once the project is claimed. The claim grant, not the polled
|
|
1174
|
+
* challenge, is the source of truth: a project claimed through another
|
|
1175
|
+
* concurrent challenge also reports `completed`, and a completed claim
|
|
1176
|
+
* keeps reporting `completed` past this challenge's expiry and past the
|
|
1177
|
+
* project's claim window.
|
|
1178
|
+
* @summary Get claim status
|
|
689
1179
|
*/
|
|
690
|
-
const
|
|
691
|
-
return customFetch(
|
|
1180
|
+
const getClaimStatus = async (projectId, params, options) => {
|
|
1181
|
+
return customFetch(getGetClaimStatusUrl(projectId, params), {
|
|
692
1182
|
...options,
|
|
693
1183
|
method: "GET"
|
|
694
1184
|
});
|
|
695
1185
|
};
|
|
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`;
|
|
1186
|
+
const getCompleteClaimUrl = (projectId) => {
|
|
1187
|
+
return `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}/claim/complete`;
|
|
703
1188
|
};
|
|
704
1189
|
/**
|
|
705
|
-
*
|
|
706
|
-
|
|
707
|
-
|
|
708
|
-
|
|
709
|
-
|
|
710
|
-
| Originating auth_attempt | Outcome |
|
|
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
|
|
1190
|
+
* Called by the browser after the developer authenticates on the claim page.
|
|
1191
|
+
* Authenticated by the `__nextgen_session` cookie, it attaches the project to
|
|
1192
|
+
* the developer's personal team using the `challenge_id` from the claim URL as
|
|
1193
|
+
* its single-use, browser-safe authorization.
|
|
1194
|
+
* @summary Complete a project claim
|
|
724
1195
|
*/
|
|
725
|
-
const
|
|
726
|
-
|
|
1196
|
+
const completeClaim = async (projectId, completeClaimBody, options) => {
|
|
1197
|
+
const getHeaders = (h) => {
|
|
1198
|
+
if (!h) return {};
|
|
1199
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1200
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
1201
|
+
const headers = {};
|
|
1202
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
1203
|
+
return headers;
|
|
1204
|
+
};
|
|
1205
|
+
return customFetch(getCompleteClaimUrl(projectId), {
|
|
727
1206
|
...options,
|
|
728
1207
|
method: "POST",
|
|
729
1208
|
headers: {
|
|
730
1209
|
"Content-Type": "application/json",
|
|
731
|
-
...options?.headers
|
|
1210
|
+
...getHeaders(options?.headers)
|
|
732
1211
|
},
|
|
733
|
-
body: JSON.stringify(
|
|
1212
|
+
body: JSON.stringify(completeClaimBody)
|
|
734
1213
|
});
|
|
735
1214
|
};
|
|
736
|
-
const
|
|
1215
|
+
const getGetClaimWindowUrl = (projectId, params) => {
|
|
737
1216
|
const normalizedParams = new URLSearchParams();
|
|
738
1217
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
739
|
-
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : value
|
|
1218
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
740
1219
|
});
|
|
741
1220
|
const stringifiedParams = normalizedParams.toString();
|
|
742
|
-
return stringifiedParams.length > 0 ? `${getProxyPath()}/
|
|
1221
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}/claim/window?${stringifiedParams}` : `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}/claim/window`;
|
|
743
1222
|
};
|
|
744
1223
|
/**
|
|
745
|
-
*
|
|
746
|
-
|
|
747
|
-
|
|
748
|
-
|
|
749
|
-
|
|
750
|
-
|
|
751
|
-
|
|
752
|
-
* @summary Get session state
|
|
1224
|
+
* Read by the claim page in the browser to show how long is left to claim the
|
|
1225
|
+
* project. Unauthenticated by design: the claim page runs this before the
|
|
1226
|
+
* developer has signed in, and holding the `challenge_id` from the claim URL
|
|
1227
|
+
* is the authorization — the same capability `claim/complete` accepts. It
|
|
1228
|
+
* reveals only the window, never the project itself, and unlike
|
|
1229
|
+
* `claim/complete` it spends nothing, so a reload is free.
|
|
1230
|
+
* @summary Get the claim window for a project
|
|
753
1231
|
*/
|
|
754
|
-
const
|
|
755
|
-
return customFetch(
|
|
1232
|
+
const getClaimWindow = async (projectId, params, options) => {
|
|
1233
|
+
return customFetch(getGetClaimWindowUrl(projectId, params), {
|
|
756
1234
|
...options,
|
|
757
1235
|
method: "GET"
|
|
758
1236
|
});
|
|
759
1237
|
};
|
|
760
|
-
const
|
|
761
|
-
|
|
762
|
-
Object.entries(params || {}).forEach(([key, value]) => {
|
|
763
|
-
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : value.toString());
|
|
764
|
-
});
|
|
765
|
-
const stringifiedParams = normalizedParams.toString();
|
|
766
|
-
return stringifiedParams.length > 0 ? `${getProxyPath()}/sessions/${sessionId}?${stringifiedParams}` : `${getProxyPath()}/sessions/${sessionId}`;
|
|
1238
|
+
const getAddOriginUrl = (projectId) => {
|
|
1239
|
+
return `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}/origins`;
|
|
767
1240
|
};
|
|
768
1241
|
/**
|
|
769
|
-
*
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
|
|
774
|
-
* @summary Revoke session
|
|
1242
|
+
* Adds one `{pattern, kind}` to the project's origins. A primary pattern
|
|
1243
|
+
* must be an exact URL (no wildcard). Preview patterns may include a single
|
|
1244
|
+
* DNS-label wildcard. Adding a pattern that already exists with the same
|
|
1245
|
+
* kind is idempotent and answers 201 with the stored origin.
|
|
1246
|
+
* @summary Add an origin pattern
|
|
775
1247
|
*/
|
|
776
|
-
const
|
|
777
|
-
|
|
1248
|
+
const addOrigin = async (projectId, addOriginBody, options) => {
|
|
1249
|
+
const getHeaders = (h) => {
|
|
1250
|
+
if (!h) return {};
|
|
1251
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1252
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
1253
|
+
const headers = {};
|
|
1254
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
1255
|
+
return headers;
|
|
1256
|
+
};
|
|
1257
|
+
return customFetch(getAddOriginUrl(projectId), {
|
|
1258
|
+
...options,
|
|
1259
|
+
method: "POST",
|
|
1260
|
+
headers: {
|
|
1261
|
+
"Content-Type": "application/json",
|
|
1262
|
+
...getHeaders(options?.headers)
|
|
1263
|
+
},
|
|
1264
|
+
body: JSON.stringify(addOriginBody)
|
|
1265
|
+
});
|
|
1266
|
+
};
|
|
1267
|
+
const getRemoveOriginUrl = (projectId) => {
|
|
1268
|
+
return `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}/origins/remove`;
|
|
1269
|
+
};
|
|
1270
|
+
/**
|
|
1271
|
+
* Removes one pattern from the project's origins. Requests from URLs only
|
|
1272
|
+
* that pattern admitted are refused from then on; live previews and
|
|
1273
|
+
* deployment history are untouched. Removing a pattern that is already
|
|
1274
|
+
* absent is idempotent and answers 204.
|
|
1275
|
+
* @summary Remove an origin pattern
|
|
1276
|
+
*/
|
|
1277
|
+
const removeOrigin = async (projectId, removeOriginBody, options) => {
|
|
1278
|
+
const getHeaders = (h) => {
|
|
1279
|
+
if (!h) return {};
|
|
1280
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1281
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
1282
|
+
const headers = {};
|
|
1283
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
1284
|
+
return headers;
|
|
1285
|
+
};
|
|
1286
|
+
return customFetch(getRemoveOriginUrl(projectId), {
|
|
1287
|
+
...options,
|
|
1288
|
+
method: "POST",
|
|
1289
|
+
headers: {
|
|
1290
|
+
"Content-Type": "application/json",
|
|
1291
|
+
...getHeaders(options?.headers)
|
|
1292
|
+
},
|
|
1293
|
+
body: JSON.stringify(removeOriginBody)
|
|
1294
|
+
});
|
|
1295
|
+
};
|
|
1296
|
+
const getListPreviewsUrl = (projectId, params) => {
|
|
1297
|
+
const normalizedParams = new URLSearchParams();
|
|
1298
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
1299
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
1300
|
+
});
|
|
1301
|
+
const stringifiedParams = normalizedParams.toString();
|
|
1302
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}/previews?${stringifiedParams}` : `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}/previews`;
|
|
1303
|
+
};
|
|
1304
|
+
/**
|
|
1305
|
+
* Lists the project's live previews, newest first by `created_at`. An
|
|
1306
|
+
* expired or removed preview is not listed; what was deployed to it stays
|
|
1307
|
+
* in `GET /deployments`.
|
|
1308
|
+
* @summary List previews
|
|
1309
|
+
*/
|
|
1310
|
+
const listPreviews = async (projectId, params, options) => {
|
|
1311
|
+
return customFetch(getListPreviewsUrl(projectId, params), {
|
|
1312
|
+
...options,
|
|
1313
|
+
method: "GET"
|
|
1314
|
+
});
|
|
1315
|
+
};
|
|
1316
|
+
const getRemovePreviewUrl = (projectId) => {
|
|
1317
|
+
return `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}/previews/remove`;
|
|
1318
|
+
};
|
|
1319
|
+
/**
|
|
1320
|
+
* Ends a preview before it expires: the URL stops being served at once.
|
|
1321
|
+
* The deployments to it stay in the history.
|
|
1322
|
+
*
|
|
1323
|
+
* Idempotent: a URL with no live preview, including one that has already
|
|
1324
|
+
* expired or was removed before, answers `204` too, so a cleanup that
|
|
1325
|
+
* races the expiry still succeeds.
|
|
1326
|
+
*
|
|
1327
|
+
* The URL travels in the body rather than the path because an origin
|
|
1328
|
+
* contains `/`.
|
|
1329
|
+
* @summary Remove a preview
|
|
1330
|
+
*/
|
|
1331
|
+
const removePreview = async (projectId, removePreviewBody, options) => {
|
|
1332
|
+
const getHeaders = (h) => {
|
|
1333
|
+
if (!h) return {};
|
|
1334
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1335
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
1336
|
+
const headers = {};
|
|
1337
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
1338
|
+
return headers;
|
|
1339
|
+
};
|
|
1340
|
+
return customFetch(getRemovePreviewUrl(projectId), {
|
|
1341
|
+
...options,
|
|
1342
|
+
method: "POST",
|
|
1343
|
+
headers: {
|
|
1344
|
+
"Content-Type": "application/json",
|
|
1345
|
+
...getHeaders(options?.headers)
|
|
1346
|
+
},
|
|
1347
|
+
body: JSON.stringify(removePreviewBody)
|
|
1348
|
+
});
|
|
1349
|
+
};
|
|
1350
|
+
const getCreateSessionUrl = () => {
|
|
1351
|
+
return `${getProxyPath()}/sessions`;
|
|
1352
|
+
};
|
|
1353
|
+
/**
|
|
1354
|
+
* Creates an anonymous session shell with no user and no factors (`state: building`).
|
|
1355
|
+
*
|
|
1356
|
+
* This is optional — an `auth_attempt` will create a session implicitly if none is provided.
|
|
1357
|
+
* Use this explicitly when you want to:
|
|
1358
|
+
* - Pre-allocate a `session_id` before the user is known, so device/telemetry signals
|
|
1359
|
+
* can be correlated with the eventual authenticated session from the start.
|
|
1360
|
+
* - Track anonymous state (bot detection, device fingerprint) that survives until authentication.
|
|
1361
|
+
*
|
|
1362
|
+
* Creating a session is an app-plane operation on the project credential
|
|
1363
|
+
* (`session.write`). The returned `session_token` is a session credential for the
|
|
1364
|
+
* end-user client, not a management scope: it is delivered as the
|
|
1365
|
+
* `__nextgen_session` cookie and authorises the self-service operations
|
|
1366
|
+
* `GET /sessions/me` and `DELETE /sessions/me` (`nextgenSession` scheme). The
|
|
1367
|
+
* by-id operations `GET /sessions/{session_id}` and `DELETE /sessions/{session_id}`
|
|
1368
|
+
* are operator endpoints and require `session.read` / `session.delete` instead.
|
|
1369
|
+
*
|
|
1370
|
+
* The `session_token` is superseded when a handoff exchange completes — clients must
|
|
1371
|
+
* replace it at that point.
|
|
1372
|
+
*
|
|
1373
|
+
* Anonymous sessions expire aggressively (10-minute TTL). The TTL resets to the configured
|
|
1374
|
+
* full session TTL when the first authentication factor is written via a completing `auth_attempt`.
|
|
1375
|
+
* @summary Create an anonymous session shell
|
|
1376
|
+
*/
|
|
1377
|
+
const createSession = async (createSessionBody, options) => {
|
|
1378
|
+
const getHeaders = (h) => {
|
|
1379
|
+
if (!h) return {};
|
|
1380
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1381
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
1382
|
+
const headers = {};
|
|
1383
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
1384
|
+
return headers;
|
|
1385
|
+
};
|
|
1386
|
+
return customFetch(getCreateSessionUrl(), {
|
|
1387
|
+
...options,
|
|
1388
|
+
method: "POST",
|
|
1389
|
+
headers: {
|
|
1390
|
+
"Content-Type": "application/json",
|
|
1391
|
+
...getHeaders(options?.headers)
|
|
1392
|
+
},
|
|
1393
|
+
body: JSON.stringify(createSessionBody)
|
|
1394
|
+
});
|
|
1395
|
+
};
|
|
1396
|
+
const getQuerySessionsUrl = (params) => {
|
|
1397
|
+
const normalizedParams = new URLSearchParams();
|
|
1398
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
1399
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
1400
|
+
});
|
|
1401
|
+
const stringifiedParams = normalizedParams.toString();
|
|
1402
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/sessions/query?${stringifiedParams}` : `${getProxyPath()}/sessions/query`;
|
|
1403
|
+
};
|
|
1404
|
+
/**
|
|
1405
|
+
* Returns the sessions of a project, paginated with a cursor.
|
|
1406
|
+
* Sessions of every lifecycle state are returned; each carries its `state`.
|
|
1407
|
+
* Requires `session.read` permission.
|
|
1408
|
+
* @summary Query sessions
|
|
1409
|
+
*/
|
|
1410
|
+
const querySessions = async (querySessionsBody, params, options) => {
|
|
1411
|
+
const getHeaders = (h) => {
|
|
1412
|
+
if (!h) return {};
|
|
1413
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1414
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
1415
|
+
const headers = {};
|
|
1416
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
1417
|
+
return headers;
|
|
1418
|
+
};
|
|
1419
|
+
return customFetch(getQuerySessionsUrl(params), {
|
|
1420
|
+
...options,
|
|
1421
|
+
method: "POST",
|
|
1422
|
+
headers: {
|
|
1423
|
+
"Content-Type": "application/json",
|
|
1424
|
+
...getHeaders(options?.headers)
|
|
1425
|
+
},
|
|
1426
|
+
body: JSON.stringify(querySessionsBody)
|
|
1427
|
+
});
|
|
1428
|
+
};
|
|
1429
|
+
const getExchangeHandoffUrl = (params) => {
|
|
1430
|
+
const normalizedParams = new URLSearchParams();
|
|
1431
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
1432
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
1433
|
+
});
|
|
1434
|
+
const stringifiedParams = normalizedParams.toString();
|
|
1435
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/sessions/exchange?${stringifiedParams}` : `${getProxyPath()}/sessions/exchange`;
|
|
1436
|
+
};
|
|
1437
|
+
/**
|
|
1438
|
+
* Consumes a one-time `handoff_token` minted by `POST /auth_attempts/{id}/handoff`
|
|
1439
|
+
* and returns the resulting session and a `session_token`.
|
|
1440
|
+
*
|
|
1441
|
+
* The server resolves the originating `auth_attempt` from the token and then:
|
|
1442
|
+
*
|
|
1443
|
+
* | Originating auth_attempt | Outcome |
|
|
1444
|
+
* |---|---|
|
|
1445
|
+
* | No `session_id` | A new authenticated session is **created**. |
|
|
1446
|
+
* | `session_id` points to an anonymous shell | Existing session is **upgraded** — user and factors written in, TTL reset to full session TTL. |
|
|
1447
|
+
* | `session_id` points to an active session (step-up) | Existing session is **upgraded** — new factors merged, `assurance_levels[]` expanded. |
|
|
1448
|
+
*
|
|
1449
|
+
* The response shape is identical in all three cases.
|
|
1450
|
+
*
|
|
1451
|
+
* The `session_token` supersedes any previously issued `session_token` for the same session.
|
|
1452
|
+
* Clients must replace their stored token at this point.
|
|
1453
|
+
*
|
|
1454
|
+
* Requires a project service key (OAuth2 client credentials).
|
|
1455
|
+
*
|
|
1456
|
+
* The project comes from the project secret. A query `project_id` that
|
|
1457
|
+
* disagrees answers `403` with `proj.mismatch`. The exchange resolves a
|
|
1458
|
+
* deployment the same way as other runtime operations; with no browser
|
|
1459
|
+
* `Origin` and nothing deployed to the resolved target the response is
|
|
1460
|
+
* `409` with `rel.not_deployed`. A revoked release answers `409` with
|
|
1461
|
+
* `rel.revoked`.
|
|
1462
|
+
* @summary Exchange handoff token for a session
|
|
1463
|
+
*/
|
|
1464
|
+
const exchangeHandoff = async (exchangeHandoffBody, params, options) => {
|
|
1465
|
+
const getHeaders = (h) => {
|
|
1466
|
+
if (!h) return {};
|
|
1467
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1468
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
1469
|
+
const headers = {};
|
|
1470
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
1471
|
+
return headers;
|
|
1472
|
+
};
|
|
1473
|
+
return customFetch(getExchangeHandoffUrl(params), {
|
|
1474
|
+
...options,
|
|
1475
|
+
method: "POST",
|
|
1476
|
+
headers: {
|
|
1477
|
+
"Content-Type": "application/json",
|
|
1478
|
+
...getHeaders(options?.headers)
|
|
1479
|
+
},
|
|
1480
|
+
body: JSON.stringify(exchangeHandoffBody)
|
|
1481
|
+
});
|
|
1482
|
+
};
|
|
1483
|
+
const getGetSessionUrl = (sessionId) => {
|
|
1484
|
+
return `${getProxyPath()}/sessions/${encodeURIComponent(String(sessionId))}`;
|
|
1485
|
+
};
|
|
1486
|
+
/**
|
|
1487
|
+
* Returns the current state of a session including its factors and all currently
|
|
1488
|
+
* satisfied assurance levels.
|
|
1489
|
+
*
|
|
1490
|
+
* `assurance_levels[]` may shrink over time as factor freshness windows expire,
|
|
1491
|
+
* without the session itself expiring. Use step-up authentication (a new `auth_attempt`
|
|
1492
|
+
* against the same `session_id`) to restore a dropped assurance level.
|
|
1493
|
+
* @summary Get session state
|
|
1494
|
+
*/
|
|
1495
|
+
const getSession = async (sessionId, options) => {
|
|
1496
|
+
return customFetch(getGetSessionUrl(sessionId), {
|
|
1497
|
+
...options,
|
|
1498
|
+
method: "GET"
|
|
1499
|
+
});
|
|
1500
|
+
};
|
|
1501
|
+
const getRevokeSessionUrl = (sessionId) => {
|
|
1502
|
+
return `${getProxyPath()}/sessions/${encodeURIComponent(String(sessionId))}`;
|
|
1503
|
+
};
|
|
1504
|
+
/**
|
|
1505
|
+
* Permanently deletes the session, terminating it immediately.
|
|
1506
|
+
*
|
|
1507
|
+
* This is the operator revoke path and requires the `session.delete` scope on a
|
|
1508
|
+
* project-bound credential. End-user logout with the `__nextgen_session` cookie is
|
|
1509
|
+
* `DELETE /sessions/me` (`nextgenSession` scheme).
|
|
1510
|
+
*
|
|
1511
|
+
* Idempotent: deleting a session that does not exist (or was already deleted)
|
|
1512
|
+
* still returns 204. After deletion, any tokens derived from the session are
|
|
1513
|
+
* invalidated.
|
|
1514
|
+
* @summary Revoke session
|
|
1515
|
+
*/
|
|
1516
|
+
const revokeSession = async (sessionId, options) => {
|
|
1517
|
+
return customFetch(getRevokeSessionUrl(sessionId), {
|
|
778
1518
|
...options,
|
|
779
1519
|
method: "DELETE"
|
|
780
1520
|
});
|
|
781
1521
|
};
|
|
782
|
-
const getGetMySessionUrl = () => {
|
|
783
|
-
|
|
1522
|
+
const getGetMySessionUrl = (params) => {
|
|
1523
|
+
const normalizedParams = new URLSearchParams();
|
|
1524
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
1525
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
1526
|
+
});
|
|
1527
|
+
const stringifiedParams = normalizedParams.toString();
|
|
1528
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/sessions/me?${stringifiedParams}` : `${getProxyPath()}/sessions/me`;
|
|
784
1529
|
};
|
|
785
1530
|
/**
|
|
786
1531
|
* Returns the current state of the current session including its factors and all currently
|
|
787
|
-
satisfied assurance levels.
|
|
788
|
-
|
|
789
|
-
`
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
1532
|
+
* satisfied assurance levels.
|
|
1533
|
+
*
|
|
1534
|
+
* With `project_id`, the session is returned only when it belongs to that project.
|
|
1535
|
+
*
|
|
1536
|
+
* `assurance_levels[]` may shrink over time as factor freshness windows expire,
|
|
1537
|
+
* without the session itself expiring. Use step-up authentication (a new `auth_attempt`
|
|
1538
|
+
* against the same `session_id`) to restore a dropped assurance level.
|
|
793
1539
|
* @summary Get my session state
|
|
794
1540
|
*/
|
|
795
|
-
const getMySession = async (options) => {
|
|
796
|
-
return customFetch(getGetMySessionUrl(), {
|
|
1541
|
+
const getMySession = async (params, options) => {
|
|
1542
|
+
return customFetch(getGetMySessionUrl(params), {
|
|
797
1543
|
...options,
|
|
798
1544
|
method: "GET"
|
|
799
1545
|
});
|
|
800
1546
|
};
|
|
801
|
-
const getRevokeMySessionUrl = () => {
|
|
802
|
-
|
|
1547
|
+
const getRevokeMySessionUrl = (params) => {
|
|
1548
|
+
const normalizedParams = new URLSearchParams();
|
|
1549
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
1550
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
1551
|
+
});
|
|
1552
|
+
const stringifiedParams = normalizedParams.toString();
|
|
1553
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/sessions/me?${stringifiedParams}` : `${getProxyPath()}/sessions/me`;
|
|
803
1554
|
};
|
|
804
1555
|
/**
|
|
805
|
-
*
|
|
806
|
-
|
|
807
|
-
The __nextgen_session cookie issued at creation (or superseded by a handoff
|
|
808
|
-
|
|
809
|
-
|
|
1556
|
+
* Logs out by permanently deleting the session.
|
|
1557
|
+
*
|
|
1558
|
+
* The `__nextgen_session` cookie issued at creation (or superseded by a handoff
|
|
1559
|
+
* exchange) is required, with the session's token from `GET /sessions/me/csrf`
|
|
1560
|
+
* in the `X-Zitadel-CSRF` header. Idempotent: if the session is already gone
|
|
1561
|
+
* this still returns 204. Any tokens derived from the session are invalidated,
|
|
1562
|
+
* and the cookie itself is cleared in the response.
|
|
1563
|
+
*
|
|
1564
|
+
* With `project_id`, only a session of that project is deleted. A session of
|
|
1565
|
+
* another project is left alone, and so is its cookie.
|
|
810
1566
|
* @summary Revoke my session
|
|
811
1567
|
*/
|
|
812
|
-
const revokeMySession = async (options) => {
|
|
813
|
-
return customFetch(getRevokeMySessionUrl(), {
|
|
1568
|
+
const revokeMySession = async (params, options) => {
|
|
1569
|
+
return customFetch(getRevokeMySessionUrl(params), {
|
|
814
1570
|
...options,
|
|
815
1571
|
method: "DELETE"
|
|
816
1572
|
});
|
|
817
1573
|
};
|
|
1574
|
+
const getGetMySessionCsrfTokenUrl = (params) => {
|
|
1575
|
+
const normalizedParams = new URLSearchParams();
|
|
1576
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
1577
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
1578
|
+
});
|
|
1579
|
+
const stringifiedParams = normalizedParams.toString();
|
|
1580
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/sessions/me/csrf?${stringifiedParams}` : `${getProxyPath()}/sessions/me/csrf`;
|
|
1581
|
+
};
|
|
1582
|
+
/**
|
|
1583
|
+
* Returns the session-bound token for cross-site request forgery protection
|
|
1584
|
+
* (ADR 053 §5). Browser code sends it in the `X-Zitadel-CSRF` header on the
|
|
1585
|
+
* state-changing requests the session cookie authenticates that require it
|
|
1586
|
+
* — see the `nextgenSession` scheme. It authorizes nothing on its own: the
|
|
1587
|
+
* HttpOnly cookie is still the credential, and a cross-site page cannot
|
|
1588
|
+
* read this response. It stays the same for the life of the session, so a
|
|
1589
|
+
* client fetches it once per session.
|
|
1590
|
+
*
|
|
1591
|
+
* With `project_id`, the token is returned only when the session belongs to
|
|
1592
|
+
* that project.
|
|
1593
|
+
* @summary Get my session's CSRF token
|
|
1594
|
+
*/
|
|
1595
|
+
const getMySessionCsrfToken = async (params, options) => {
|
|
1596
|
+
return customFetch(getGetMySessionCsrfTokenUrl(params), {
|
|
1597
|
+
...options,
|
|
1598
|
+
method: "GET"
|
|
1599
|
+
});
|
|
1600
|
+
};
|
|
818
1601
|
const getCreateSchemaUrl = (params) => {
|
|
819
1602
|
const normalizedParams = new URLSearchParams();
|
|
820
1603
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
821
|
-
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : value
|
|
1604
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
822
1605
|
});
|
|
823
1606
|
const stringifiedParams = normalizedParams.toString();
|
|
824
1607
|
return stringifiedParams.length > 0 ? `${getProxyPath()}/schemas?${stringifiedParams}` : `${getProxyPath()}/schemas`;
|
|
825
1608
|
};
|
|
826
1609
|
/**
|
|
827
|
-
* Create a new schema. The
|
|
828
|
-
|
|
829
|
-
|
|
830
|
-
|
|
831
|
-
|
|
832
|
-
|
|
833
|
-
|
|
834
|
-
|
|
1610
|
+
* Create a new schema. The optional `$id` field is the JSON Schema document
|
|
1611
|
+
* URI used to identify the schema in future requests (GitOps-stable identity,
|
|
1612
|
+
* not a free-form resource primary key). When `$id` is omitted, the server
|
|
1613
|
+
* generates a `sch_*` URL. When provided, `$id` must be unique within the
|
|
1614
|
+
* project and should ideally be a valid URI pointing at where the schema can
|
|
1615
|
+
* be accessed.
|
|
1616
|
+
*
|
|
1617
|
+
* The schema can either be a concrete schema, e.g. a user schema, or a
|
|
1618
|
+
* schema-url which will be resolved by the server.
|
|
835
1619
|
* @summary Create new schema
|
|
836
1620
|
*/
|
|
837
1621
|
const createSchema = async (createSchemaBody, params, options) => {
|
|
1622
|
+
const getHeaders = (h) => {
|
|
1623
|
+
if (!h) return {};
|
|
1624
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1625
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
1626
|
+
const headers = {};
|
|
1627
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
1628
|
+
return headers;
|
|
1629
|
+
};
|
|
838
1630
|
return customFetch(getCreateSchemaUrl(params), {
|
|
839
1631
|
...options,
|
|
840
1632
|
method: "POST",
|
|
841
1633
|
headers: {
|
|
842
1634
|
"Content-Type": "application/json",
|
|
843
|
-
...options?.headers
|
|
1635
|
+
...getHeaders(options?.headers)
|
|
844
1636
|
},
|
|
845
1637
|
body: JSON.stringify(createSchemaBody)
|
|
846
1638
|
});
|
|
847
1639
|
};
|
|
1640
|
+
const getListSchemasUrl = (params) => {
|
|
1641
|
+
const normalizedParams = new URLSearchParams();
|
|
1642
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
1643
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
1644
|
+
});
|
|
1645
|
+
const stringifiedParams = normalizedParams.toString();
|
|
1646
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/schemas?${stringifiedParams}` : `${getProxyPath()}/schemas`;
|
|
1647
|
+
};
|
|
1648
|
+
/**
|
|
1649
|
+
* Retrieve a list of all schemas available in the system. This endpoint
|
|
1650
|
+
* supports pagination and filtering based on schema attributes.
|
|
1651
|
+
* @summary List all schemas
|
|
1652
|
+
*/
|
|
1653
|
+
const listSchemas = async (params, options) => {
|
|
1654
|
+
return customFetch(getListSchemasUrl(params), {
|
|
1655
|
+
...options,
|
|
1656
|
+
method: "GET"
|
|
1657
|
+
});
|
|
1658
|
+
};
|
|
848
1659
|
const getGetSchemaByIdUrl = (id, params) => {
|
|
849
1660
|
const normalizedParams = new URLSearchParams();
|
|
850
1661
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
851
|
-
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : value
|
|
1662
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
852
1663
|
});
|
|
853
1664
|
const stringifiedParams = normalizedParams.toString();
|
|
854
|
-
return stringifiedParams.length > 0 ? `${getProxyPath()}/schemas/${id}?${stringifiedParams}` : `${getProxyPath()}/schemas/${id}`;
|
|
1665
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/schemas/${encodeURIComponent(String(id))}?${stringifiedParams}` : `${getProxyPath()}/schemas/${encodeURIComponent(String(id))}`;
|
|
855
1666
|
};
|
|
856
1667
|
/**
|
|
857
|
-
* Get a schema by its ID.
|
|
1668
|
+
* Get a schema by its ID. A schema ID identifies one immutable revision, so
|
|
1669
|
+
* this returns exactly that revision. To find the current revision of an
|
|
1670
|
+
* object type, list with `revisions=latest`.
|
|
1671
|
+
*
|
|
1672
|
+
* Schema IDs are unique within a project, not across projects (the seeded
|
|
1673
|
+
* default schema carries the same `$id` in every project). A Console
|
|
1674
|
+
* session that manages more than one project names the project with
|
|
1675
|
+
* `project_id`; without it, the ID is resolved in the credential's own
|
|
1676
|
+
* project when it is ambiguous. A project secret always resolves in its
|
|
1677
|
+
* own project and ignores `project_id`.
|
|
858
1678
|
* @summary Get schema by ID
|
|
859
1679
|
*/
|
|
860
1680
|
const getSchemaById = async (id, params, options) => {
|
|
@@ -867,21 +1687,33 @@ const getCreateFlowDefinitionUrl = () => {
|
|
|
867
1687
|
return `${getProxyPath()}/flow_definitions`;
|
|
868
1688
|
};
|
|
869
1689
|
/**
|
|
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
|
-
|
|
1690
|
+
* Publishes a new flow definition revision.
|
|
1691
|
+
* Flow definitions are templates that define the sequence of steps (capabilities)
|
|
1692
|
+
* for a particular user journey (e.g., registration, login, password reset).
|
|
1693
|
+
*
|
|
1694
|
+
* Flow definitions are created based on the flow definition schema, which includes the flow's purpose, audience, and the steps involved.
|
|
1695
|
+
*
|
|
1696
|
+
* Every call allocates a new opaque id. Revisions of one flow share its
|
|
1697
|
+
* `name`; posting a definition under an existing `name` publishes a new
|
|
1698
|
+
* revision of that flow, it is not a conflict. List with `name` to see a
|
|
1699
|
+
* flow's revisions, newest by creation time first.
|
|
876
1700
|
* @summary Create a new flow definition
|
|
877
1701
|
*/
|
|
878
1702
|
const createFlowDefinition = async (createFlowDefinitionBody, options) => {
|
|
1703
|
+
const getHeaders = (h) => {
|
|
1704
|
+
if (!h) return {};
|
|
1705
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1706
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
1707
|
+
const headers = {};
|
|
1708
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
1709
|
+
return headers;
|
|
1710
|
+
};
|
|
879
1711
|
return customFetch(getCreateFlowDefinitionUrl(), {
|
|
880
1712
|
...options,
|
|
881
1713
|
method: "POST",
|
|
882
1714
|
headers: {
|
|
883
1715
|
"Content-Type": "application/json",
|
|
884
|
-
...options?.headers
|
|
1716
|
+
...getHeaders(options?.headers)
|
|
885
1717
|
},
|
|
886
1718
|
body: JSON.stringify(createFlowDefinitionBody)
|
|
887
1719
|
});
|
|
@@ -889,15 +1721,21 @@ const createFlowDefinition = async (createFlowDefinitionBody, options) => {
|
|
|
889
1721
|
const getListFlowDefinitionsUrl = (params) => {
|
|
890
1722
|
const normalizedParams = new URLSearchParams();
|
|
891
1723
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
892
|
-
if (
|
|
1724
|
+
if (Array.isArray(value) && ["expand"].includes(key)) {
|
|
1725
|
+
value.forEach((v) => {
|
|
1726
|
+
normalizedParams.append(key, v === null ? "null" : String(v));
|
|
1727
|
+
});
|
|
1728
|
+
return;
|
|
1729
|
+
}
|
|
1730
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
893
1731
|
});
|
|
894
1732
|
const stringifiedParams = normalizedParams.toString();
|
|
895
1733
|
return stringifiedParams.length > 0 ? `${getProxyPath()}/flow_definitions?${stringifiedParams}` : `${getProxyPath()}/flow_definitions`;
|
|
896
1734
|
};
|
|
897
1735
|
/**
|
|
898
|
-
* Retrieves a list of all flow definitions.
|
|
899
|
-
This endpoint can be used to view existing flow definitions and their configurations.
|
|
900
|
-
|
|
1736
|
+
* Retrieves a list of all flow definitions, newest by creation time first.
|
|
1737
|
+
* This endpoint can be used to view existing flow definitions and their configurations.
|
|
1738
|
+
* Filter by `name` to list the revisions of one flow.
|
|
901
1739
|
* @summary List flow definitions
|
|
902
1740
|
*/
|
|
903
1741
|
const listFlowDefinitions = async (params, options) => {
|
|
@@ -906,107 +1744,1090 @@ const listFlowDefinitions = async (params, options) => {
|
|
|
906
1744
|
method: "GET"
|
|
907
1745
|
});
|
|
908
1746
|
};
|
|
909
|
-
const getGetFlowDefinitionUrl = (id
|
|
1747
|
+
const getGetFlowDefinitionUrl = (id) => {
|
|
1748
|
+
return `${getProxyPath()}/flow_definitions/${encodeURIComponent(String(id))}`;
|
|
1749
|
+
};
|
|
1750
|
+
/**
|
|
1751
|
+
* Get a flow definition by id
|
|
1752
|
+
* @summary Get a flow definition by id
|
|
1753
|
+
*/
|
|
1754
|
+
const getFlowDefinition = async (id, options) => {
|
|
1755
|
+
return customFetch(getGetFlowDefinitionUrl(id), {
|
|
1756
|
+
...options,
|
|
1757
|
+
method: "GET"
|
|
1758
|
+
});
|
|
1759
|
+
};
|
|
1760
|
+
const getCreateTeamUrl = (params) => {
|
|
1761
|
+
const normalizedParams = new URLSearchParams();
|
|
1762
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
1763
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
1764
|
+
});
|
|
1765
|
+
const stringifiedParams = normalizedParams.toString();
|
|
1766
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/teams?${stringifiedParams}` : `${getProxyPath()}/teams`;
|
|
1767
|
+
};
|
|
1768
|
+
/**
|
|
1769
|
+
* Creates a team in the project, with a name no other team in the project has.
|
|
1770
|
+
*
|
|
1771
|
+
* A taken name is refused with `409 team.already_exists`. The new team has no
|
|
1772
|
+
* members yet.
|
|
1773
|
+
* @summary Create team
|
|
1774
|
+
*/
|
|
1775
|
+
const createTeam = async (createTeamBody, params, options) => {
|
|
1776
|
+
const getHeaders = (h) => {
|
|
1777
|
+
if (!h) return {};
|
|
1778
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1779
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
1780
|
+
const headers = {};
|
|
1781
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
1782
|
+
return headers;
|
|
1783
|
+
};
|
|
1784
|
+
return customFetch(getCreateTeamUrl(params), {
|
|
1785
|
+
...options,
|
|
1786
|
+
method: "POST",
|
|
1787
|
+
headers: {
|
|
1788
|
+
"Content-Type": "application/json",
|
|
1789
|
+
...getHeaders(options?.headers)
|
|
1790
|
+
},
|
|
1791
|
+
body: JSON.stringify(createTeamBody)
|
|
1792
|
+
});
|
|
1793
|
+
};
|
|
1794
|
+
const getQueryTeamsUrl = (params) => {
|
|
910
1795
|
const normalizedParams = new URLSearchParams();
|
|
911
1796
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
912
|
-
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : value
|
|
1797
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
913
1798
|
});
|
|
914
1799
|
const stringifiedParams = normalizedParams.toString();
|
|
915
|
-
return stringifiedParams.length > 0 ? `${getProxyPath()}/
|
|
1800
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/teams/query?${stringifiedParams}` : `${getProxyPath()}/teams/query`;
|
|
916
1801
|
};
|
|
917
1802
|
/**
|
|
918
|
-
*
|
|
919
|
-
* @summary
|
|
1803
|
+
* Returns the teams of a project, paginated with a cursor.
|
|
1804
|
+
* @summary Query teams
|
|
1805
|
+
*/
|
|
1806
|
+
const queryTeams = async (queryTeamsBody, params, options) => {
|
|
1807
|
+
const getHeaders = (h) => {
|
|
1808
|
+
if (!h) return {};
|
|
1809
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1810
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
1811
|
+
const headers = {};
|
|
1812
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
1813
|
+
return headers;
|
|
1814
|
+
};
|
|
1815
|
+
return customFetch(getQueryTeamsUrl(params), {
|
|
1816
|
+
...options,
|
|
1817
|
+
method: "POST",
|
|
1818
|
+
headers: {
|
|
1819
|
+
"Content-Type": "application/json",
|
|
1820
|
+
...getHeaders(options?.headers)
|
|
1821
|
+
},
|
|
1822
|
+
body: JSON.stringify(queryTeamsBody)
|
|
1823
|
+
});
|
|
1824
|
+
};
|
|
1825
|
+
const getGetTeamUrl = (teamId) => {
|
|
1826
|
+
return `${getProxyPath()}/teams/${encodeURIComponent(String(teamId))}`;
|
|
1827
|
+
};
|
|
1828
|
+
/**
|
|
1829
|
+
* Returns a Team by its id.
|
|
1830
|
+
* @summary Get team
|
|
1831
|
+
*/
|
|
1832
|
+
const getTeam = async (teamId, options) => {
|
|
1833
|
+
return customFetch(getGetTeamUrl(teamId), {
|
|
1834
|
+
...options,
|
|
1835
|
+
method: "GET"
|
|
1836
|
+
});
|
|
1837
|
+
};
|
|
1838
|
+
const getDeleteTeamUrl = (teamId) => {
|
|
1839
|
+
return `${getProxyPath()}/teams/${encodeURIComponent(String(teamId))}`;
|
|
1840
|
+
};
|
|
1841
|
+
/**
|
|
1842
|
+
* Deactivates the team.
|
|
1843
|
+
*
|
|
1844
|
+
* The team is tombstoned rather than erased: it stays readable through
|
|
1845
|
+
* getTeam with status `deactivated`. Its memberships are removed and the
|
|
1846
|
+
* users whose lifecycle it owns are deactivated with it.
|
|
1847
|
+
*
|
|
1848
|
+
* The request is idempotent. Deleting a team that is already deactivated
|
|
1849
|
+
* or doesn't exist succeeds without changing anything.
|
|
1850
|
+
*
|
|
1851
|
+
* A team that still owns a project is refused with `409
|
|
1852
|
+
* team.owns_project`: deactivating it would leave the project owned by a
|
|
1853
|
+
* dead team and so unmanageable. No endpoint releases that ownership yet,
|
|
1854
|
+
* so such a team cannot currently be deactivated through the API.
|
|
1855
|
+
* @summary Delete team
|
|
1856
|
+
*/
|
|
1857
|
+
const deleteTeam = async (teamId, options) => {
|
|
1858
|
+
return customFetch(getDeleteTeamUrl(teamId), {
|
|
1859
|
+
...options,
|
|
1860
|
+
method: "DELETE"
|
|
1861
|
+
});
|
|
1862
|
+
};
|
|
1863
|
+
const getUpdateTeamUrl = (teamId) => {
|
|
1864
|
+
return `${getProxyPath()}/teams/${encodeURIComponent(String(teamId))}`;
|
|
1865
|
+
};
|
|
1866
|
+
/**
|
|
1867
|
+
* Update team. Only active teams can be updated.
|
|
1868
|
+
* @summary Update team
|
|
1869
|
+
*/
|
|
1870
|
+
const updateTeam = async (teamId, updateTeamBody, options) => {
|
|
1871
|
+
const getHeaders = (h) => {
|
|
1872
|
+
if (!h) return {};
|
|
1873
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1874
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
1875
|
+
const headers = {};
|
|
1876
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
1877
|
+
return headers;
|
|
1878
|
+
};
|
|
1879
|
+
return customFetch(getUpdateTeamUrl(teamId), {
|
|
1880
|
+
...options,
|
|
1881
|
+
method: "PATCH",
|
|
1882
|
+
headers: {
|
|
1883
|
+
"Content-Type": "application/json",
|
|
1884
|
+
...getHeaders(options?.headers)
|
|
1885
|
+
},
|
|
1886
|
+
body: JSON.stringify(updateTeamBody)
|
|
1887
|
+
});
|
|
1888
|
+
};
|
|
1889
|
+
const getCreateBrandingUrl = (params) => {
|
|
1890
|
+
const normalizedParams = new URLSearchParams();
|
|
1891
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
1892
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
1893
|
+
});
|
|
1894
|
+
const stringifiedParams = normalizedParams.toString();
|
|
1895
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/branding?${stringifiedParams}` : `${getProxyPath()}/branding`;
|
|
1896
|
+
};
|
|
1897
|
+
/**
|
|
1898
|
+
* Publishes a new immutable branding revision for the project. Branding
|
|
1899
|
+
* revisions cannot be updated or deleted; every edit publishes a new
|
|
1900
|
+
* revision, and flow responses resolve the latest revision per project.
|
|
1901
|
+
*
|
|
1902
|
+
* The `liquid_template` is validated lexically on save (size, encoding,
|
|
1903
|
+
* banned patterns such as `<script>` tags, inline event handlers, and the
|
|
1904
|
+
* `| raw` filter). Authoritative LiquidJS validation runs at authoring
|
|
1905
|
+
* time via `zitadel plan` / `zitadel apply`.
|
|
1906
|
+
* @summary Publish a new branding revision
|
|
1907
|
+
*/
|
|
1908
|
+
const createBranding = async (createBrandingBody, params, options) => {
|
|
1909
|
+
const getHeaders = (h) => {
|
|
1910
|
+
if (!h) return {};
|
|
1911
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1912
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
1913
|
+
const headers = {};
|
|
1914
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
1915
|
+
return headers;
|
|
1916
|
+
};
|
|
1917
|
+
return customFetch(getCreateBrandingUrl(params), {
|
|
1918
|
+
...options,
|
|
1919
|
+
method: "POST",
|
|
1920
|
+
headers: {
|
|
1921
|
+
"Content-Type": "application/json",
|
|
1922
|
+
...getHeaders(options?.headers)
|
|
1923
|
+
},
|
|
1924
|
+
body: JSON.stringify(createBrandingBody)
|
|
1925
|
+
});
|
|
1926
|
+
};
|
|
1927
|
+
const getListBrandingUrl = (params) => {
|
|
1928
|
+
const normalizedParams = new URLSearchParams();
|
|
1929
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
1930
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
1931
|
+
});
|
|
1932
|
+
const stringifiedParams = normalizedParams.toString();
|
|
1933
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/branding?${stringifiedParams}` : `${getProxyPath()}/branding`;
|
|
1934
|
+
};
|
|
1935
|
+
/**
|
|
1936
|
+
* Lists branding revisions for the project, newest first, capped at the
|
|
1937
|
+
* 100 most recent. The first entry is the revision flow responses
|
|
1938
|
+
* currently resolve. Deliberately unpaginated in v1 — list endpoints gain a
|
|
1939
|
+
* real query mechanism together; advertising pagination parameters the
|
|
1940
|
+
* server ignores would be worse than none.
|
|
1941
|
+
* @summary List branding revisions
|
|
1942
|
+
*/
|
|
1943
|
+
const listBranding = async (params, options) => {
|
|
1944
|
+
return customFetch(getListBrandingUrl(params), {
|
|
1945
|
+
...options,
|
|
1946
|
+
method: "GET"
|
|
1947
|
+
});
|
|
1948
|
+
};
|
|
1949
|
+
const getGetBrandingByIdUrl = (id) => {
|
|
1950
|
+
return `${getProxyPath()}/branding/${encodeURIComponent(String(id))}`;
|
|
1951
|
+
};
|
|
1952
|
+
/**
|
|
1953
|
+
* Retrieves a single branding revision, including its stored configuration.
|
|
1954
|
+
* @summary Get a branding revision by ID
|
|
1955
|
+
*/
|
|
1956
|
+
const getBrandingById = async (id, options) => {
|
|
1957
|
+
return customFetch(getGetBrandingByIdUrl(id), {
|
|
1958
|
+
...options,
|
|
1959
|
+
method: "GET"
|
|
1960
|
+
});
|
|
1961
|
+
};
|
|
1962
|
+
const getCreateIdpUrl = (params) => {
|
|
1963
|
+
const normalizedParams = new URLSearchParams();
|
|
1964
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
1965
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
1966
|
+
});
|
|
1967
|
+
const stringifiedParams = normalizedParams.toString();
|
|
1968
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/idps?${stringifiedParams}` : `${getProxyPath()}/idps`;
|
|
1969
|
+
};
|
|
1970
|
+
/**
|
|
1971
|
+
* Creates or revises a connection document. If the slug does not already
|
|
1972
|
+
* exist, a new connection is created. If a connection with that slug already
|
|
1973
|
+
* exists, a revision is created.
|
|
1974
|
+
*
|
|
1975
|
+
* A revision gets a new `revision_id` and does not modify the connection
|
|
1976
|
+
* `id`, so identity links that reference the connection keep resolving while
|
|
1977
|
+
* releases and auth attempts stay pinned to the revision they captured.
|
|
1978
|
+
*
|
|
1979
|
+
* Identity fields are fixed for the life of the connection and a revision
|
|
1980
|
+
* that changes one is rejected: `protocol`, `subject_claim`, and `issuer`,
|
|
1981
|
+
* the field that names the authority. Their values decide which provider
|
|
1982
|
+
* account a stored subject belongs to, so changing one would silently
|
|
1983
|
+
* repoint existing identities at a different provider.
|
|
1984
|
+
*
|
|
1985
|
+
* `subject_claim` is optional, and `sub` is used as the default value. If a
|
|
1986
|
+
* revision updates `subject_claim` to a different value than the one set
|
|
1987
|
+
* during creation, the request is rejected.
|
|
1988
|
+
*
|
|
1989
|
+
* OIDC is the only protocol.
|
|
1990
|
+
*
|
|
1991
|
+
* The document is validated against the `idp-connection.json` schema before
|
|
1992
|
+
* anything is stored. The rules the engine applies when it starts a sign-in
|
|
1993
|
+
* then run on the document, so a connection that could never start one is
|
|
1994
|
+
* refused here instead with `idp.endpoints_partial`: the OIDC block sets an
|
|
1995
|
+
* endpoint without the others. It either sets no endpoint, and discovery
|
|
1996
|
+
* fills them, or sets `authorization_endpoint`, `token_endpoint`, `jwks_uri`,
|
|
1997
|
+
* and `userinfo_endpoint`. `userinfo_endpoint` may be left out when
|
|
1998
|
+
* `id_token_mapping` is on, but setting it alone still counts as setting an
|
|
1999
|
+
* endpoint. The details list the missing endpoints.
|
|
2000
|
+
*
|
|
2001
|
+
* A refused document stores nothing, and on a revise the current revision
|
|
2002
|
+
* stays unchanged.
|
|
2003
|
+
* @summary Create or revise an identity provider connection
|
|
2004
|
+
*/
|
|
2005
|
+
const createIdp = async (createIdpBody, params, options) => {
|
|
2006
|
+
const getHeaders = (h) => {
|
|
2007
|
+
if (!h) return {};
|
|
2008
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
2009
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
2010
|
+
const headers = {};
|
|
2011
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
2012
|
+
return headers;
|
|
2013
|
+
};
|
|
2014
|
+
return customFetch(getCreateIdpUrl(params), {
|
|
2015
|
+
...options,
|
|
2016
|
+
method: "POST",
|
|
2017
|
+
headers: {
|
|
2018
|
+
"Content-Type": "application/json",
|
|
2019
|
+
...getHeaders(options?.headers)
|
|
2020
|
+
},
|
|
2021
|
+
body: JSON.stringify(createIdpBody)
|
|
2022
|
+
});
|
|
2023
|
+
};
|
|
2024
|
+
const getQueryIdpsUrl = (params) => {
|
|
2025
|
+
const normalizedParams = new URLSearchParams();
|
|
2026
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2027
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2028
|
+
});
|
|
2029
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2030
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/idps/query?${stringifiedParams}` : `${getProxyPath()}/idps/query`;
|
|
2031
|
+
};
|
|
2032
|
+
/**
|
|
2033
|
+
* Returns the identity provider connections of a project, paginated with a
|
|
2034
|
+
* cursor. One row per connection, carrying its newest revision.
|
|
2035
|
+
* @summary Query identity provider connections
|
|
2036
|
+
*/
|
|
2037
|
+
const queryIdps = async (queryIdpsBody, params, options) => {
|
|
2038
|
+
const getHeaders = (h) => {
|
|
2039
|
+
if (!h) return {};
|
|
2040
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
2041
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
2042
|
+
const headers = {};
|
|
2043
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
2044
|
+
return headers;
|
|
2045
|
+
};
|
|
2046
|
+
return customFetch(getQueryIdpsUrl(params), {
|
|
2047
|
+
...options,
|
|
2048
|
+
method: "POST",
|
|
2049
|
+
headers: {
|
|
2050
|
+
"Content-Type": "application/json",
|
|
2051
|
+
...getHeaders(options?.headers)
|
|
2052
|
+
},
|
|
2053
|
+
body: JSON.stringify(queryIdpsBody)
|
|
2054
|
+
});
|
|
2055
|
+
};
|
|
2056
|
+
const getGetIdpByIdUrl = (id, params) => {
|
|
2057
|
+
const normalizedParams = new URLSearchParams();
|
|
2058
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2059
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2060
|
+
});
|
|
2061
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2062
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/idps/${encodeURIComponent(String(id))}?${stringifiedParams}` : `${getProxyPath()}/idps/${encodeURIComponent(String(id))}`;
|
|
2063
|
+
};
|
|
2064
|
+
/**
|
|
2065
|
+
* Reads a connection by its id, at its newest revision.
|
|
2066
|
+
* `GET /idps/{id}/revisions` lists every revision of the connection.
|
|
2067
|
+
*
|
|
2068
|
+
* The lookup is scoped to the project in `project_id`.
|
|
2069
|
+
* @summary Get an identity provider connection by id
|
|
2070
|
+
*/
|
|
2071
|
+
const getIdpById = async (id, params, options) => {
|
|
2072
|
+
return customFetch(getGetIdpByIdUrl(id, params), {
|
|
2073
|
+
...options,
|
|
2074
|
+
method: "GET"
|
|
2075
|
+
});
|
|
2076
|
+
};
|
|
2077
|
+
const getListIdpRevisionsUrl = (id, params) => {
|
|
2078
|
+
const normalizedParams = new URLSearchParams();
|
|
2079
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2080
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2081
|
+
});
|
|
2082
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2083
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/idps/${encodeURIComponent(String(id))}/revisions?${stringifiedParams}` : `${getProxyPath()}/idps/${encodeURIComponent(String(id))}/revisions`;
|
|
2084
|
+
};
|
|
2085
|
+
/**
|
|
2086
|
+
* Returns every revision of one connection, newest first, paginated with a
|
|
2087
|
+
* cursor. The order is fixed, so there is no `sorting`.
|
|
2088
|
+
*
|
|
2089
|
+
* The lookup is scoped to the project in `project_id`.
|
|
2090
|
+
* @summary List the revisions of an identity provider connection
|
|
2091
|
+
*/
|
|
2092
|
+
const listIdpRevisions = async (id, params, options) => {
|
|
2093
|
+
return customFetch(getListIdpRevisionsUrl(id, params), {
|
|
2094
|
+
...options,
|
|
2095
|
+
method: "GET"
|
|
2096
|
+
});
|
|
2097
|
+
};
|
|
2098
|
+
const getGetIdpRevisionByIdUrl = (revisionId, params) => {
|
|
2099
|
+
const normalizedParams = new URLSearchParams();
|
|
2100
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2101
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2102
|
+
});
|
|
2103
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2104
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/idps/revisions/${encodeURIComponent(String(revisionId))}?${stringifiedParams}` : `${getProxyPath()}/idps/revisions/${encodeURIComponent(String(revisionId))}`;
|
|
2105
|
+
};
|
|
2106
|
+
/**
|
|
2107
|
+
* Reads one revision of a connection by its `revision_id`, the value an auth
|
|
2108
|
+
* attempt or a release pins.
|
|
2109
|
+
*
|
|
2110
|
+
* The lookup is scoped to the project in `project_id`.
|
|
2111
|
+
* @summary Get one revision of an identity provider connection
|
|
2112
|
+
*/
|
|
2113
|
+
const getIdpRevisionById = async (revisionId, params, options) => {
|
|
2114
|
+
return customFetch(getGetIdpRevisionByIdUrl(revisionId, params), {
|
|
2115
|
+
...options,
|
|
2116
|
+
method: "GET"
|
|
2117
|
+
});
|
|
2118
|
+
};
|
|
2119
|
+
const getCreateReleaseUrl = (params) => {
|
|
2120
|
+
const normalizedParams = new URLSearchParams();
|
|
2121
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2122
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2123
|
+
});
|
|
2124
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2125
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/releases?${stringifiedParams}` : `${getProxyPath()}/releases`;
|
|
2126
|
+
};
|
|
2127
|
+
/**
|
|
2128
|
+
* Assembles a release from existing revisions, given as
|
|
2129
|
+
* `(kind, revision_id)` pairs. To build one from files on disk, use
|
|
2130
|
+
* `POST /releases/build`.
|
|
2131
|
+
*
|
|
2132
|
+
* Each revision must exist in the project and is recorded under the handle
|
|
2133
|
+
* it declares. The release must be complete and consistent:
|
|
2134
|
+
*
|
|
2135
|
+
* - Every handle its revisions name must be in the release: a flow's
|
|
2136
|
+
* `user_schema`, and the IDP connections named by a flow step's
|
|
2137
|
+
* `sso_providers` or a schema's `x-auth-methods.sso.providers`. A missing
|
|
2138
|
+
* one answers `rel.unresolved_reference`, naming the resource and the
|
|
2139
|
+
* handle, e.g. `flow_definition default-login: user_schema human-user not found`.
|
|
2140
|
+
* - Every flow is validated as on save, against the user schema revision
|
|
2141
|
+
* in the release. A flow that fails answers `rel.invalid`, with the
|
|
2142
|
+
* reason in `details`.
|
|
2143
|
+
*
|
|
2144
|
+
* Idempotent on the set of revisions: the same revisions with a different
|
|
2145
|
+
* `message` answer `200` with the existing release. A new release answers
|
|
2146
|
+
* `201`. Creating a release does not deploy it.
|
|
2147
|
+
* @summary Create a release
|
|
2148
|
+
*/
|
|
2149
|
+
const createRelease = async (createReleaseBody, params, options) => {
|
|
2150
|
+
const getHeaders = (h) => {
|
|
2151
|
+
if (!h) return {};
|
|
2152
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
2153
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
2154
|
+
const headers = {};
|
|
2155
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
2156
|
+
return headers;
|
|
2157
|
+
};
|
|
2158
|
+
return customFetch(getCreateReleaseUrl(params), {
|
|
2159
|
+
...options,
|
|
2160
|
+
method: "POST",
|
|
2161
|
+
headers: {
|
|
2162
|
+
"Content-Type": "application/json",
|
|
2163
|
+
...getHeaders(options?.headers)
|
|
2164
|
+
},
|
|
2165
|
+
body: JSON.stringify(createReleaseBody)
|
|
2166
|
+
});
|
|
2167
|
+
};
|
|
2168
|
+
const getListReleasesUrl = (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()}/releases?${stringifiedParams}` : `${getProxyPath()}/releases`;
|
|
2175
|
+
};
|
|
2176
|
+
/**
|
|
2177
|
+
* Lists the project's releases, newest first.
|
|
2178
|
+
*
|
|
2179
|
+
* Entries carry the digest, the metadata and `revoked_at` — the pinned set
|
|
2180
|
+
* is omitted.
|
|
2181
|
+
* Read one release with `GET /releases/{release_id}` to get its pointers.
|
|
2182
|
+
*
|
|
2183
|
+
* `content_hash` looks a release up by its content, as the CLI does when a
|
|
2184
|
+
* person types the digest a transcript printed. The project holds at most
|
|
2185
|
+
* one release per digest, so the filtered list has one entry or none, and
|
|
2186
|
+
* an unknown digest is an empty list rather than an error. Paths take the
|
|
2187
|
+
* `rel_` id only; the matched entry's `id` is what to use there.
|
|
2188
|
+
* @summary List releases
|
|
2189
|
+
*/
|
|
2190
|
+
const listReleases = async (params, options) => {
|
|
2191
|
+
return customFetch(getListReleasesUrl(params), {
|
|
2192
|
+
...options,
|
|
2193
|
+
method: "GET"
|
|
2194
|
+
});
|
|
2195
|
+
};
|
|
2196
|
+
const getBuildReleaseUrl = (params) => {
|
|
2197
|
+
const normalizedParams = new URLSearchParams();
|
|
2198
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2199
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2200
|
+
});
|
|
2201
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2202
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/releases/build?${stringifiedParams}` : `${getProxyPath()}/releases/build`;
|
|
2203
|
+
};
|
|
2204
|
+
/**
|
|
2205
|
+
* Builds a release from the resources of `.zitadel/` as authored on disk,
|
|
2206
|
+
* grouped by kind, in one transaction: a failure anywhere leaves no
|
|
2207
|
+
* revision and no release. The caller records nothing.
|
|
2208
|
+
*
|
|
2209
|
+
* If the project already holds a release with the same content, the same
|
|
2210
|
+
* `content_hash`, the request answers `200` with that release and
|
|
2211
|
+
* allocates nothing, however long ago it was built. Otherwise every resource is compared against the
|
|
2212
|
+
* project's newest revision of the same handle: unchanged content reuses
|
|
2213
|
+
* that revision, changed content allocates a new one, and the request
|
|
2214
|
+
* answers `201` with the new release. Metadata is excluded from the
|
|
2215
|
+
* comparison, so the same content under a different `message` is the same
|
|
2216
|
+
* release.
|
|
2217
|
+
*
|
|
2218
|
+
* A structurally malformed request is refused while decoding with
|
|
2219
|
+
* `req.invalid`, naming the offending fields. A well-formed bundle is then
|
|
2220
|
+
* checked resource by resource, as each kind's create endpoint checks it,
|
|
2221
|
+
* and every failure is reported at once: the request answers `400` with
|
|
2222
|
+
* `rel.invalid`, and `details.resources` lists each resource that failed.
|
|
2223
|
+
* A handle that resolves neither in the bundle nor in the project answers
|
|
2224
|
+
* `rel.unresolved_reference`, naming the pointer and the handle.
|
|
2225
|
+
*
|
|
2226
|
+
* Building writes revisions, so besides `release.write` it needs the write
|
|
2227
|
+
* scope of every kind the bundle carries a resource of: `schema.write`,
|
|
2228
|
+
* `flow_definition.write`, `branding.write` and `idp.write`, as the
|
|
2229
|
+
* per-kind create endpoints do. A missing scope answers `403` with `rel.permission_denied`,
|
|
2230
|
+
* naming the kind. An empty kind needs no scope.
|
|
2231
|
+
*
|
|
2232
|
+
* Building a release does not deploy it. A release is not tied to an
|
|
2233
|
+
* origin, and the same release can later be deployed to any number of
|
|
2234
|
+
* origins unchanged.
|
|
2235
|
+
* @summary Build a release from files
|
|
2236
|
+
*/
|
|
2237
|
+
const buildRelease = async (buildReleaseBody, params, options) => {
|
|
2238
|
+
const getHeaders = (h) => {
|
|
2239
|
+
if (!h) return {};
|
|
2240
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
2241
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
2242
|
+
const headers = {};
|
|
2243
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
2244
|
+
return headers;
|
|
2245
|
+
};
|
|
2246
|
+
return customFetch(getBuildReleaseUrl(params), {
|
|
2247
|
+
...options,
|
|
2248
|
+
method: "POST",
|
|
2249
|
+
headers: {
|
|
2250
|
+
"Content-Type": "application/json",
|
|
2251
|
+
...getHeaders(options?.headers)
|
|
2252
|
+
},
|
|
2253
|
+
body: JSON.stringify(buildReleaseBody)
|
|
2254
|
+
});
|
|
2255
|
+
};
|
|
2256
|
+
const getGetReleaseByIdUrl = (releaseId, params) => {
|
|
2257
|
+
const normalizedParams = new URLSearchParams();
|
|
2258
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2259
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2260
|
+
});
|
|
2261
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2262
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/releases/${encodeURIComponent(String(releaseId))}?${stringifiedParams}` : `${getProxyPath()}/releases/${encodeURIComponent(String(releaseId))}`;
|
|
2263
|
+
};
|
|
2264
|
+
/**
|
|
2265
|
+
* Reads one release: its digest, its metadata, whether it was revoked, and
|
|
2266
|
+
* the `(kind, handle, revision_id)` tuples it pins.
|
|
2267
|
+
*
|
|
2268
|
+
* The path takes the `rel_` id only. To find a release from its digest,
|
|
2269
|
+
* list with the `content_hash` filter and read the matched entry's `id`.
|
|
2270
|
+
*
|
|
2271
|
+
* Does not embed resource content. Resolve each `revision_id` through the
|
|
2272
|
+
* per-kind read endpoints when the bytes are needed.
|
|
2273
|
+
*
|
|
2274
|
+
* The lookup is scoped to the project in `project_id`: a release id belonging
|
|
2275
|
+
* to another project answers not found exactly as an unknown id does, so the
|
|
2276
|
+
* endpoint cannot be used to probe for releases in projects the caller cannot
|
|
2277
|
+
* read.
|
|
2278
|
+
* @summary Get a release by id
|
|
2279
|
+
*/
|
|
2280
|
+
const getReleaseById = async (releaseId, params, options) => {
|
|
2281
|
+
return customFetch(getGetReleaseByIdUrl(releaseId, params), {
|
|
2282
|
+
...options,
|
|
2283
|
+
method: "GET"
|
|
2284
|
+
});
|
|
2285
|
+
};
|
|
2286
|
+
const getRevokeReleaseUrl = (releaseId, params) => {
|
|
2287
|
+
const normalizedParams = new URLSearchParams();
|
|
2288
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2289
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2290
|
+
});
|
|
2291
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2292
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/releases/${encodeURIComponent(String(releaseId))}/revoke?${stringifiedParams}` : `${getProxyPath()}/releases/${encodeURIComponent(String(releaseId))}/revoke`;
|
|
2293
|
+
};
|
|
2294
|
+
/**
|
|
2295
|
+
* Marks the release revoked, so that its content is never served again.
|
|
2296
|
+
* From then on the release cannot be deployed and is refused on every path
|
|
2297
|
+
* that would serve it, including to a build that pins its digest, with
|
|
2298
|
+
* `rel.revoked`.
|
|
2299
|
+
*
|
|
2300
|
+
* A release that any origin still serves cannot be revoked. An origin
|
|
2301
|
+
* serves the release of the newest deployment to it, so the call answers
|
|
2302
|
+
* `409` with `rel.in_use`, naming each such origin and that deployment.
|
|
2303
|
+
* Deploy another release there or roll back first, then revoke. Revoking
|
|
2304
|
+
* therefore never takes an origin down. Deployments that named the release
|
|
2305
|
+
* earlier stay in the history.
|
|
2306
|
+
*
|
|
2307
|
+
* Idempotent: revoking a release that is already revoked answers `200`
|
|
2308
|
+
* with the release unchanged, `revoked_at` still naming the first
|
|
2309
|
+
* revocation. There is no un-revoke; build a new release instead.
|
|
2310
|
+
*
|
|
2311
|
+
* Takes no body. The lookup is scoped to the project in `project_id`, so a
|
|
2312
|
+
* release id of another project answers not found exactly as an unknown id
|
|
2313
|
+
* does.
|
|
2314
|
+
* @summary Revoke a release
|
|
2315
|
+
*/
|
|
2316
|
+
const revokeRelease = async (releaseId, params, options) => {
|
|
2317
|
+
return customFetch(getRevokeReleaseUrl(releaseId, params), {
|
|
2318
|
+
...options,
|
|
2319
|
+
method: "POST"
|
|
2320
|
+
});
|
|
2321
|
+
};
|
|
2322
|
+
const getCreateGrantUrl = (params) => {
|
|
2323
|
+
const normalizedParams = new URLSearchParams();
|
|
2324
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2325
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2326
|
+
});
|
|
2327
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2328
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/grants?${stringifiedParams}` : `${getProxyPath()}/grants`;
|
|
2329
|
+
};
|
|
2330
|
+
/**
|
|
2331
|
+
* Bind a user or team to `project.viewer`, `project.editor`, or
|
|
2332
|
+
* `project.admin` on the project identified by the `project-id` header.
|
|
2333
|
+
* Name the principal with `user` (`user_id` or `identifier`) or `team`
|
|
2334
|
+
* (`team_id` or `name`). IDs are `asgn_<opaque>`. Owning-team
|
|
2335
|
+
* (`project.team`) grants are not created here — claim owns that path. An
|
|
2336
|
+
* unrevoked grant with the same principal and relation occupies the unique
|
|
2337
|
+
* key even after `expires_at`; DELETE it before re-creating.
|
|
2338
|
+
* Create does not accept `expand`. The `user_id` and team locators
|
|
2339
|
+
* return 201, whose `user` / `team` carry only `user_id` / `team_id`,
|
|
2340
|
+
* and still 404 / 409 when the principal is missing or the tuple
|
|
2341
|
+
* already exists. Creating by `user.identifier` answers 202 with no
|
|
2342
|
+
* body on every outcome. Granting the session caller's own user is
|
|
2343
|
+
* `grant.invalid` on either user locator. Read the grant back for
|
|
2344
|
+
* identifier and display.
|
|
2345
|
+
*
|
|
2346
|
+
* Accepts either a project secret (`oauth2`) or a user-bound Console
|
|
2347
|
+
* session cookie (`nextgenSession`). Session callers are authorized as
|
|
2348
|
+
* the human against the target project (home may differ). Cookie-authenticated
|
|
2349
|
+
* requests follow the scheme's CSRF rules (`nextgenSession`).
|
|
2350
|
+
* @summary Create grant
|
|
2351
|
+
*/
|
|
2352
|
+
const createGrant = async (createGrantBody, params, options) => {
|
|
2353
|
+
const getHeaders = (h) => {
|
|
2354
|
+
if (!h) return {};
|
|
2355
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
2356
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
2357
|
+
const headers = {};
|
|
2358
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
2359
|
+
return headers;
|
|
2360
|
+
};
|
|
2361
|
+
return customFetch(getCreateGrantUrl(params), {
|
|
2362
|
+
...options,
|
|
2363
|
+
method: "POST",
|
|
2364
|
+
headers: {
|
|
2365
|
+
"Content-Type": "application/json",
|
|
2366
|
+
...getHeaders(options?.headers)
|
|
2367
|
+
},
|
|
2368
|
+
body: JSON.stringify(createGrantBody)
|
|
2369
|
+
});
|
|
2370
|
+
};
|
|
2371
|
+
const getQueryGrantsUrl = (params) => {
|
|
2372
|
+
const normalizedParams = new URLSearchParams();
|
|
2373
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2374
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2375
|
+
});
|
|
2376
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2377
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/grants/query?${stringifiedParams}` : `${getProxyPath()}/grants/query`;
|
|
2378
|
+
};
|
|
2379
|
+
/**
|
|
2380
|
+
* Returns the collaboration grants of a project, paginated with a cursor.
|
|
2381
|
+
* Only unrevoked grants this API manages are listed (user or team bound to
|
|
2382
|
+
* viewer, editor, or admin), including expired grants so a client can
|
|
2383
|
+
* DELETE before re-granting. Project-secret setup (`sk_proj`) and
|
|
2384
|
+
* owning-team (`relation=team`) rows are not returned. Grants are not in
|
|
2385
|
+
* `resource_scope_index`; project scope is required on the query (same as
|
|
2386
|
+
* get). Requires `project.read`. `expand: ["principal"]` adds envelope
|
|
2387
|
+
* fields on `user` / `team` and additionally requires `user.read` and
|
|
2388
|
+
* `team.read` for project secrets (documented on the expand enum; those
|
|
2389
|
+
* scopes cannot be ANDed onto this security block because they are
|
|
2390
|
+
* body-conditional). A user-bound Console session that already passed
|
|
2391
|
+
* the project Check may expand without those scopes.
|
|
2392
|
+
*
|
|
2393
|
+
* Accepts either a project secret (`oauth2`) or a user-bound Console
|
|
2394
|
+
* session cookie (`nextgenSession`). Cookie-authenticated requests
|
|
2395
|
+
* follow the scheme's CSRF rules (`nextgenSession`).
|
|
2396
|
+
* @summary Query grants
|
|
2397
|
+
*/
|
|
2398
|
+
const queryGrants = async (queryGrantsBody, params, options) => {
|
|
2399
|
+
const getHeaders = (h) => {
|
|
2400
|
+
if (!h) return {};
|
|
2401
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
2402
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
2403
|
+
const headers = {};
|
|
2404
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
2405
|
+
return headers;
|
|
2406
|
+
};
|
|
2407
|
+
return customFetch(getQueryGrantsUrl(params), {
|
|
2408
|
+
...options,
|
|
2409
|
+
method: "POST",
|
|
2410
|
+
headers: {
|
|
2411
|
+
"Content-Type": "application/json",
|
|
2412
|
+
...getHeaders(options?.headers)
|
|
2413
|
+
},
|
|
2414
|
+
body: JSON.stringify(queryGrantsBody)
|
|
2415
|
+
});
|
|
2416
|
+
};
|
|
2417
|
+
const getGetGrantUrl = (id, params) => {
|
|
2418
|
+
const normalizedParams = new URLSearchParams();
|
|
2419
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2420
|
+
if (Array.isArray(value) && ["expand"].includes(key)) {
|
|
2421
|
+
value.forEach((v) => {
|
|
2422
|
+
normalizedParams.append(key, v === null ? "null" : String(v));
|
|
2423
|
+
});
|
|
2424
|
+
return;
|
|
2425
|
+
}
|
|
2426
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2427
|
+
});
|
|
2428
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2429
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/grants/${encodeURIComponent(String(id))}?${stringifiedParams}` : `${getProxyPath()}/grants/${encodeURIComponent(String(id))}`;
|
|
2430
|
+
};
|
|
2431
|
+
/**
|
|
2432
|
+
* Loads a grant by `(project_id, id)` that this API manages (user or team
|
|
2433
|
+
* bound to viewer, editor, or admin) and that has not been revoked.
|
|
2434
|
+
* "Active" here means not revoked: expired grants stay visible so the
|
|
2435
|
+
* client can DELETE before re-granting the same binding. Authorization
|
|
2436
|
+
* still ignores expired grants. Grants are not registered in
|
|
2437
|
+
* `resource_scope_index`; project scope is required on the query (same as
|
|
2438
|
+
* events). Misses, revoked rows, project-secret setup (`sk_proj`),
|
|
2439
|
+
* owning-team (`relation=team`) rows, and cross-project ids return 404.
|
|
2440
|
+
* `expand=principal` adds envelope fields on `user` or `team` and requires
|
|
2441
|
+
* `user.read` and `team.read` in addition to `project.read` for project
|
|
2442
|
+
* secrets. A user-bound Console session that already passed the project
|
|
2443
|
+
* Check may expand without those scopes.
|
|
2444
|
+
*
|
|
2445
|
+
* Accepts either a project secret (`oauth2`) or a user-bound Console
|
|
2446
|
+
* session cookie (`nextgenSession`). Cookie-authenticated requests
|
|
2447
|
+
* follow the scheme's CSRF rules (`nextgenSession`).
|
|
2448
|
+
* @summary Get grant
|
|
2449
|
+
*/
|
|
2450
|
+
const getGrant = async (id, params, options) => {
|
|
2451
|
+
return customFetch(getGetGrantUrl(id, params), {
|
|
2452
|
+
...options,
|
|
2453
|
+
method: "GET"
|
|
2454
|
+
});
|
|
2455
|
+
};
|
|
2456
|
+
const getDeleteGrantUrl = (id, params) => {
|
|
2457
|
+
const normalizedParams = new URLSearchParams();
|
|
2458
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2459
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2460
|
+
});
|
|
2461
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2462
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/grants/${encodeURIComponent(String(id))}?${stringifiedParams}` : `${getProxyPath()}/grants/${encodeURIComponent(String(id))}`;
|
|
2463
|
+
};
|
|
2464
|
+
/**
|
|
2465
|
+
* Soft-revokes a grant this API manages and emits `authz.revoked`.
|
|
2466
|
+
* Already-revoked, missing, project-secret setup, and owning-team grants
|
|
2467
|
+
* return 404. The row is not un-revoked. Expired grants can still be
|
|
2468
|
+
* revoked so the unique binding can be reused.
|
|
2469
|
+
*
|
|
2470
|
+
* Accepts either a project secret (`oauth2`) or a user-bound Console
|
|
2471
|
+
* session cookie (`nextgenSession`). Cookie-authenticated requests
|
|
2472
|
+
* follow the scheme's CSRF rules (`nextgenSession`).
|
|
2473
|
+
* @summary Revoke grant
|
|
2474
|
+
*/
|
|
2475
|
+
const deleteGrant = async (id, params, options) => {
|
|
2476
|
+
return customFetch(getDeleteGrantUrl(id, params), {
|
|
2477
|
+
...options,
|
|
2478
|
+
method: "DELETE"
|
|
2479
|
+
});
|
|
2480
|
+
};
|
|
2481
|
+
const getListEventsUrl = (params) => {
|
|
2482
|
+
const normalizedParams = new URLSearchParams();
|
|
2483
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2484
|
+
if (Array.isArray(value) && ["category", "event_type"].includes(key)) {
|
|
2485
|
+
value.forEach((v) => {
|
|
2486
|
+
normalizedParams.append(key, v === null ? "null" : String(v));
|
|
2487
|
+
});
|
|
2488
|
+
return;
|
|
2489
|
+
}
|
|
2490
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2491
|
+
});
|
|
2492
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2493
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/events?${stringifiedParams}` : `${getProxyPath()}/events`;
|
|
2494
|
+
};
|
|
2495
|
+
/**
|
|
2496
|
+
* Returns project-scoped audit events, newest-first by keyset on
|
|
2497
|
+
* `(created_at, id)` (ADR 027 / ADR 049). Pass `order=asc` for oldest-first.
|
|
2498
|
+
* Requires `events.read`.
|
|
2499
|
+
*
|
|
2500
|
+
* Pre-claim projects return an empty list (events are stored but not
|
|
2501
|
+
* visible until claim succeeds). Team-scoped credentials see only events
|
|
2502
|
+
* whose emit-time `team_id` matches the credential team (enforced when
|
|
2503
|
+
* team-scoped tokens exist).
|
|
2504
|
+
*
|
|
2505
|
+
* Clients discriminate each item via `event_type` (OpenAPI Event oneOf) —
|
|
2506
|
+
* see docs/design/api/events-catalog.md.
|
|
2507
|
+
* @summary List events
|
|
920
2508
|
*/
|
|
921
|
-
const
|
|
922
|
-
return customFetch(
|
|
2509
|
+
const listEvents = async (params, options) => {
|
|
2510
|
+
return customFetch(getListEventsUrl(params), {
|
|
923
2511
|
...options,
|
|
924
2512
|
method: "GET"
|
|
925
2513
|
});
|
|
926
2514
|
};
|
|
927
|
-
const
|
|
2515
|
+
const getGetEventUrl = (id, params) => {
|
|
928
2516
|
const normalizedParams = new URLSearchParams();
|
|
929
2517
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
930
|
-
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : value
|
|
2518
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
931
2519
|
});
|
|
932
2520
|
const stringifiedParams = normalizedParams.toString();
|
|
933
|
-
return stringifiedParams.length > 0 ? `${getProxyPath()}/
|
|
2521
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/events/${encodeURIComponent(String(id))}?${stringifiedParams}` : `${getProxyPath()}/events/${encodeURIComponent(String(id))}`;
|
|
934
2522
|
};
|
|
935
2523
|
/**
|
|
936
|
-
*
|
|
937
|
-
*
|
|
2524
|
+
* Loads a single event by `(project_id, id)`. Requires `events.read`.
|
|
2525
|
+
* Events are not registered in `resource_scope_index`; project scope is
|
|
2526
|
+
* required on the query (ADR 049). Misses and cross-project ids return 404.
|
|
2527
|
+
*
|
|
2528
|
+
* Pre-claim projects return 404 (stored events stay invisible until claim).
|
|
2529
|
+
* @summary Get event by ID
|
|
938
2530
|
*/
|
|
939
|
-
const
|
|
940
|
-
return customFetch(
|
|
2531
|
+
const getEvent = async (id, params, options) => {
|
|
2532
|
+
return customFetch(getGetEventUrl(id, params), {
|
|
2533
|
+
...options,
|
|
2534
|
+
method: "GET"
|
|
2535
|
+
});
|
|
2536
|
+
};
|
|
2537
|
+
const getGetVariablesUrl = (params) => {
|
|
2538
|
+
const normalizedParams = new URLSearchParams();
|
|
2539
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2540
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2541
|
+
});
|
|
2542
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2543
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/variables?${stringifiedParams}` : `${getProxyPath()}/variables`;
|
|
2544
|
+
};
|
|
2545
|
+
/**
|
|
2546
|
+
* Returns the project's variables, keyed by name, each with its value per
|
|
2547
|
+
* kind. With `kind`, only that kind's values are returned.
|
|
2548
|
+
*
|
|
2549
|
+
* Secret values are not returned. A secret appears as `{"secret": true}`,
|
|
2550
|
+
* which says a value is held without disclosing it.
|
|
2551
|
+
* @summary Get variables
|
|
2552
|
+
*/
|
|
2553
|
+
const getVariables = async (params, options) => {
|
|
2554
|
+
return customFetch(getGetVariablesUrl(params), {
|
|
2555
|
+
...options,
|
|
2556
|
+
method: "GET"
|
|
2557
|
+
});
|
|
2558
|
+
};
|
|
2559
|
+
const getUpdateVariablesUrl = (params) => {
|
|
2560
|
+
const normalizedParams = new URLSearchParams();
|
|
2561
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2562
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2563
|
+
});
|
|
2564
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2565
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/variables?${stringifiedParams}` : `${getProxyPath()}/variables`;
|
|
2566
|
+
};
|
|
2567
|
+
/**
|
|
2568
|
+
* Enters, replaces and removes the project's variables for the requested
|
|
2569
|
+
* kind. Names not in the body are untouched. Existing deployments keep the
|
|
2570
|
+
* values they froze.
|
|
2571
|
+
*
|
|
2572
|
+
* Without `kind`, a plain value is written for both kinds. A secret is
|
|
2573
|
+
* written for `primary` only and removes the name's `preview` value, so a
|
|
2574
|
+
* preview never keeps a plaintext copy; set a preview secret with
|
|
2575
|
+
* `kind=preview`. `null` removes the name from both.
|
|
2576
|
+
*
|
|
2577
|
+
* A bare scalar enters a non-secret value. `{"value": …, "secret": true}`
|
|
2578
|
+
* stores the value encrypted under the project's active `secret` key, after
|
|
2579
|
+
* which it can be referenced but not read back. `null` removes the name
|
|
2580
|
+
* (RFC 7386), which is how several variables are removed in one request;
|
|
2581
|
+
* removing a name the project does not hold is a no-op rather than an error.
|
|
2582
|
+
*
|
|
2583
|
+
* The body is applied whole or not at all, so a rejected request leaves the
|
|
2584
|
+
* project's variables exactly as they were. Writing the same name twice
|
|
2585
|
+
* replaces the value rather than duplicating it, which makes a retry safe.
|
|
2586
|
+
* @summary Update variables
|
|
2587
|
+
*/
|
|
2588
|
+
const updateVariables = async (updateVariablesBody, params, options) => {
|
|
2589
|
+
const getHeaders = (h) => {
|
|
2590
|
+
if (!h) return {};
|
|
2591
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
2592
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
2593
|
+
const headers = {};
|
|
2594
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
2595
|
+
return headers;
|
|
2596
|
+
};
|
|
2597
|
+
return customFetch(getUpdateVariablesUrl(params), {
|
|
941
2598
|
...options,
|
|
942
2599
|
method: "PATCH",
|
|
943
2600
|
headers: {
|
|
944
2601
|
"Content-Type": "application/json",
|
|
945
|
-
...options?.headers
|
|
2602
|
+
...getHeaders(options?.headers)
|
|
946
2603
|
},
|
|
947
|
-
body: JSON.stringify(
|
|
2604
|
+
body: JSON.stringify(updateVariablesBody)
|
|
948
2605
|
});
|
|
949
2606
|
};
|
|
950
|
-
const
|
|
2607
|
+
const getGetVariableUrl = (variableName, params) => {
|
|
951
2608
|
const normalizedParams = new URLSearchParams();
|
|
952
2609
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
953
|
-
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : value
|
|
2610
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
954
2611
|
});
|
|
955
2612
|
const stringifiedParams = normalizedParams.toString();
|
|
956
|
-
return stringifiedParams.length > 0 ? `${getProxyPath()}/
|
|
2613
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/variables/${encodeURIComponent(String(variableName))}?${stringifiedParams}` : `${getProxyPath()}/variables/${encodeURIComponent(String(variableName))}`;
|
|
957
2614
|
};
|
|
958
2615
|
/**
|
|
959
|
-
*
|
|
960
|
-
*
|
|
2616
|
+
* Reads one variable by name, with its value per kind. A name with no
|
|
2617
|
+
* value for the requested kind answers `var.not_found`. A secret reads
|
|
2618
|
+
* back as `{"secret": true}`.
|
|
2619
|
+
* @summary Get a variable
|
|
961
2620
|
*/
|
|
962
|
-
const
|
|
963
|
-
return customFetch(
|
|
2621
|
+
const getVariable = async (variableName, params, options) => {
|
|
2622
|
+
return customFetch(getGetVariableUrl(variableName, params), {
|
|
2623
|
+
...options,
|
|
2624
|
+
method: "GET"
|
|
2625
|
+
});
|
|
2626
|
+
};
|
|
2627
|
+
const getDeleteVariableUrl = (variableName, params) => {
|
|
2628
|
+
const normalizedParams = new URLSearchParams();
|
|
2629
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2630
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2631
|
+
});
|
|
2632
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2633
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/variables/${encodeURIComponent(String(variableName))}?${stringifiedParams}` : `${getProxyPath()}/variables/${encodeURIComponent(String(variableName))}`;
|
|
2634
|
+
};
|
|
2635
|
+
/**
|
|
2636
|
+
* Removes a variable for the requested kind, or for both kinds without
|
|
2637
|
+
* `kind`. A name with no value for that kind answers `var.not_found`.
|
|
2638
|
+
* Existing deployments keep the values they froze.
|
|
2639
|
+
* @summary Delete a variable
|
|
2640
|
+
*/
|
|
2641
|
+
const deleteVariable = async (variableName, params, options) => {
|
|
2642
|
+
return customFetch(getDeleteVariableUrl(variableName, params), {
|
|
964
2643
|
...options,
|
|
965
2644
|
method: "DELETE"
|
|
966
2645
|
});
|
|
967
2646
|
};
|
|
968
|
-
const
|
|
2647
|
+
const getCreateDeploymentUrl = (params) => {
|
|
969
2648
|
const normalizedParams = new URLSearchParams();
|
|
970
2649
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
971
|
-
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : value
|
|
2650
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
972
2651
|
});
|
|
973
2652
|
const stringifiedParams = normalizedParams.toString();
|
|
974
|
-
return stringifiedParams.length > 0 ? `${getProxyPath()}/
|
|
2653
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/deployments?${stringifiedParams}` : `${getProxyPath()}/deployments`;
|
|
975
2654
|
};
|
|
976
2655
|
/**
|
|
977
|
-
*
|
|
2656
|
+
* Makes a release live on its targets by recording a deployment,
|
|
2657
|
+
* atomically: on success every target serves the release and the record
|
|
2658
|
+
* exists; on failure nothing changes and no record is written.
|
|
2659
|
+
*
|
|
2660
|
+
* Name the release by exactly one of `release_id` or `content_hash`; it
|
|
2661
|
+
* must already exist in the project. `targets` is `primary` or preview
|
|
2662
|
+
* URLs. The deployment freezes the project's variable values for its kind,
|
|
2663
|
+
* with no fallback between primary and preview values.
|
|
2664
|
+
*
|
|
2665
|
+
* A deployment to `primary` changes nothing when the project's newest
|
|
2666
|
+
* primary deployment has the same release and frozen values and covers
|
|
2667
|
+
* exactly the current primary origins: the call answers `200` with that
|
|
2668
|
+
* deployment. Any other request writes a new deployment and answers `201`;
|
|
2669
|
+
* for preview URLs that record renews their previews.
|
|
2670
|
+
*
|
|
2671
|
+
* Failures:
|
|
2672
|
+
* - `400 dep.invalid`: both or neither of `release_id` and `content_hash`;
|
|
2673
|
+
* a primary origin named exactly; `primary` mixed with preview URLs;
|
|
2674
|
+
* `primary` on a project with no primary origin; `ttl` with `primary`;
|
|
2675
|
+
* `ttl` above the project's maximum.
|
|
2676
|
+
* - `400 dep.variables_missing`: a referenced variable has no value for
|
|
2677
|
+
* the kind; `details` names the kind and every missing variable.
|
|
2678
|
+
* - `403 proj.origin_not_allowed`: a preview URL matches no preview
|
|
2679
|
+
* pattern.
|
|
2680
|
+
* - `404 rel.not_found`: the release id or digest names no release here.
|
|
2681
|
+
* - `409 dep.conflict`: `expected_deployment_id` is not the deployment
|
|
2682
|
+
* this write replaces; `details.deployment` is that deployment.
|
|
2683
|
+
* - `409 rel.revoked`: the release is revoked.
|
|
2684
|
+
* @summary Create a deployment
|
|
978
2685
|
*/
|
|
979
|
-
const
|
|
980
|
-
|
|
2686
|
+
const createDeployment = async (createDeploymentBody, params, options) => {
|
|
2687
|
+
const getHeaders = (h) => {
|
|
2688
|
+
if (!h) return {};
|
|
2689
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
2690
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
2691
|
+
const headers = {};
|
|
2692
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
2693
|
+
return headers;
|
|
2694
|
+
};
|
|
2695
|
+
return customFetch(getCreateDeploymentUrl(params), {
|
|
981
2696
|
...options,
|
|
982
2697
|
method: "POST",
|
|
983
2698
|
headers: {
|
|
984
2699
|
"Content-Type": "application/json",
|
|
985
|
-
...options?.headers
|
|
2700
|
+
...getHeaders(options?.headers)
|
|
986
2701
|
},
|
|
987
|
-
body: JSON.stringify(
|
|
2702
|
+
body: JSON.stringify(createDeploymentBody)
|
|
988
2703
|
});
|
|
989
2704
|
};
|
|
990
|
-
const
|
|
2705
|
+
const getListDeploymentsUrl = (params) => {
|
|
991
2706
|
const normalizedParams = new URLSearchParams();
|
|
992
2707
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
993
|
-
if (
|
|
2708
|
+
if (Array.isArray(value) && ["expand"].includes(key)) {
|
|
2709
|
+
value.forEach((v) => {
|
|
2710
|
+
normalizedParams.append(key, v === null ? "null" : String(v));
|
|
2711
|
+
});
|
|
2712
|
+
return;
|
|
2713
|
+
}
|
|
2714
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
994
2715
|
});
|
|
995
2716
|
const stringifiedParams = normalizedParams.toString();
|
|
996
|
-
return stringifiedParams.length > 0 ? `${getProxyPath()}/
|
|
2717
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/deployments?${stringifiedParams}` : `${getProxyPath()}/deployments`;
|
|
997
2718
|
};
|
|
998
2719
|
/**
|
|
999
|
-
*
|
|
1000
|
-
|
|
1001
|
-
*
|
|
2720
|
+
* Lists what ran where, and when.
|
|
2721
|
+
*
|
|
2722
|
+
* By default the list is the history, newest first: every deployment of
|
|
2723
|
+
* the project with every target it made the release live on. With
|
|
2724
|
+
* `origin`, the history of that origin alone.
|
|
2725
|
+
*
|
|
2726
|
+
* With `live=true`, the list is what is served now, newest first: the
|
|
2727
|
+
* project's newest primary deployment, narrowed to origins that are still
|
|
2728
|
+
* primary, and the newest deployment to each live preview URL, narrowed to
|
|
2729
|
+
* the URLs it still serves. Combined with `origin`, it is the one
|
|
2730
|
+
* deployment that origin serves, or empty.
|
|
2731
|
+
*
|
|
2732
|
+
* `expand: ["release"]` embeds the release each deployment made live; it
|
|
2733
|
+
* requires `release.read` and does not change the ordering or the page
|
|
2734
|
+
* tokens.
|
|
2735
|
+
* @summary List deployments
|
|
2736
|
+
*/
|
|
2737
|
+
const listDeployments = async (params, options) => {
|
|
2738
|
+
return customFetch(getListDeploymentsUrl(params), {
|
|
2739
|
+
...options,
|
|
2740
|
+
method: "GET"
|
|
2741
|
+
});
|
|
2742
|
+
};
|
|
2743
|
+
const getGetDeploymentByIdUrl = (deploymentId, params) => {
|
|
2744
|
+
const normalizedParams = new URLSearchParams();
|
|
2745
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2746
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2747
|
+
});
|
|
2748
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2749
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/deployments/${encodeURIComponent(String(deploymentId))}?${stringifiedParams}` : `${getProxyPath()}/deployments/${encodeURIComponent(String(deploymentId))}`;
|
|
2750
|
+
};
|
|
2751
|
+
/**
|
|
2752
|
+
* Reads one deployment record.
|
|
2753
|
+
*
|
|
2754
|
+
* The lookup is scoped to the project in `project_id`: a deployment id
|
|
2755
|
+
* belonging to another project answers not found exactly as an unknown id
|
|
2756
|
+
* does, so the endpoint cannot be used to probe for deployments in projects
|
|
2757
|
+
* the caller cannot read.
|
|
2758
|
+
* @summary Get a deployment by id
|
|
2759
|
+
*/
|
|
2760
|
+
const getDeploymentById = async (deploymentId, params, options) => {
|
|
2761
|
+
return customFetch(getGetDeploymentByIdUrl(deploymentId, params), {
|
|
2762
|
+
...options,
|
|
2763
|
+
method: "GET"
|
|
2764
|
+
});
|
|
2765
|
+
};
|
|
2766
|
+
const getRollbackDeploymentUrl = (deploymentId, params) => {
|
|
2767
|
+
const normalizedParams = new URLSearchParams();
|
|
2768
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2769
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2770
|
+
});
|
|
2771
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2772
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/deployments/${encodeURIComponent(String(deploymentId))}/rollback?${stringifiedParams}` : `${getProxyPath()}/deployments/${encodeURIComponent(String(deploymentId))}/rollback`;
|
|
2773
|
+
};
|
|
2774
|
+
/**
|
|
2775
|
+
* Re-deploys the release of the deployment named in the path to `primary`,
|
|
2776
|
+
* with the variable values it froze: a new deployment with `reason:
|
|
2777
|
+
* rollback` and `rollback_to` naming it. Like any deployment to `primary`,
|
|
2778
|
+
* it covers every current primary origin. Idempotent like a deployment to
|
|
2779
|
+
* `primary`: when nothing would change it answers `200` with the newest
|
|
2780
|
+
* primary deployment.
|
|
2781
|
+
*
|
|
2782
|
+
* Failures:
|
|
2783
|
+
* - `400 dep.invalid`: the deployment went to preview URLs (deploy to the
|
|
2784
|
+
* preview again instead), or the project has no primary origin.
|
|
2785
|
+
* - `404 dep.not_found`: no deployment of the project has that id.
|
|
2786
|
+
* - `409 dep.conflict`: `expected_deployment_id` is not the project's
|
|
2787
|
+
* newest primary deployment; `details.deployment` is that deployment.
|
|
2788
|
+
* - `409 rel.revoked`: the release is revoked.
|
|
2789
|
+
* @summary Roll back to a deployment
|
|
2790
|
+
*/
|
|
2791
|
+
const rollbackDeployment = async (deploymentId, params, rollbackDeploymentBody, options) => {
|
|
2792
|
+
const getHeaders = (h) => {
|
|
2793
|
+
if (!h) return {};
|
|
2794
|
+
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
2795
|
+
if (Symbol.iterator in h) return Object.fromEntries(Array.from(h, (entry) => Array.from(entry)));
|
|
2796
|
+
const headers = {};
|
|
2797
|
+
for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
|
|
2798
|
+
return headers;
|
|
2799
|
+
};
|
|
2800
|
+
return customFetch(getRollbackDeploymentUrl(deploymentId, params), {
|
|
2801
|
+
...options,
|
|
2802
|
+
method: "POST",
|
|
2803
|
+
headers: {
|
|
2804
|
+
"Content-Type": "application/json",
|
|
2805
|
+
...getHeaders(options?.headers)
|
|
2806
|
+
},
|
|
2807
|
+
body: JSON.stringify(rollbackDeploymentBody)
|
|
2808
|
+
});
|
|
2809
|
+
};
|
|
2810
|
+
const getGetDeploymentVariablesUrl = (deploymentId, params) => {
|
|
2811
|
+
const normalizedParams = new URLSearchParams();
|
|
2812
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2813
|
+
if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2814
|
+
});
|
|
2815
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2816
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/deployments/${encodeURIComponent(String(deploymentId))}/variables?${stringifiedParams}` : `${getProxyPath()}/deployments/${encodeURIComponent(String(deploymentId))}/variables`;
|
|
2817
|
+
};
|
|
2818
|
+
/**
|
|
2819
|
+
* Returns the variable values the deployment froze when it was made. Later
|
|
2820
|
+
* changes to the project's variables do not affect them. A secret reads
|
|
2821
|
+
* back as `{"secret": true}`.
|
|
2822
|
+
* @summary Get a deployment's variables
|
|
1002
2823
|
*/
|
|
1003
|
-
const
|
|
1004
|
-
return customFetch(
|
|
2824
|
+
const getDeploymentVariables = async (deploymentId, params, options) => {
|
|
2825
|
+
return customFetch(getGetDeploymentVariablesUrl(deploymentId, params), {
|
|
1005
2826
|
...options,
|
|
1006
2827
|
method: "GET"
|
|
1007
2828
|
});
|
|
1008
2829
|
};
|
|
1009
2830
|
//#endregion
|
|
1010
|
-
export {
|
|
2831
|
+
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, getGetHealthUrl, getGetIdpByIdUrl, getGetIdpRevisionByIdUrl, getGetLiveUrl, getGetMyPasswordStateUrl, getGetMySessionCsrfTokenUrl, getGetMySessionUrl, getGetMyUserSchemaUrl, getGetMyUserUrl, getGetProjectUrl, getGetReadyUrl, getGetReleaseByIdUrl, getGetSchemaByIdUrl, getGetSessionUrl, getGetTeamUrl, getGetUserByIDUrl, getGetUserPasswordStateUrl, getGetVariableUrl, getGetVariablesUrl, getGrant, getHealth, getIdpById, getIdpRevisionById, getInitClaimUrl, getIssueChallengeUrl, getListBrandingUrl, getListDeploymentsUrl, getListEventsUrl, getListFlowDefinitionsUrl, getListIdpRevisionsUrl, getListMyIdentityLinksUrl, getListMyPasskeysUrl, getListMyProjectsUrl, getListMyTeamsUrl, getListPreviewsUrl, getListReleasesUrl, getListSchemasUrl, getListUserIdentityLinksUrl, getListUserPasskeysUrl, getListUserTeamsUrl, getLive, getMyPasswordState, getMySession, getMySessionCsrfToken, getMyUser, getMyUserSchema, getPatchMyUserUrl, getPatchProjectUrl, getPatchUserByIDUrl, getProject, 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, listPreviews, listReleases, listSchemas, listUserIdentityLinks, listUserPasskeys, listUserTeams, patchMyUser, patchProject, patchUserByID, queryGrants, queryIdps, queryProjects, querySessions, queryTeams, queryUsers, removeOrigin, removePreview, revokeMySession, revokeRelease, revokeSession, rollbackDeployment, setUserPassword, submitFlowStep, zitadelNextGen_exports as t, updateTeam, updateVariables, verifyChallengeProof };
|
|
1011
2832
|
|
|
1012
2833
|
//# sourceMappingURL=zitadelNextGen.mjs.map
|