@zitadel/api 1.0.0-alpha.24 → 1.0.0-alpha.25
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 +26 -1
- 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 +54 -12
- package/dist/generated/endpoints/zitadelNextGen.mjs.map +1 -1
- package/dist/generated/endpoints/zitadelNextGen.msw.d.mts +146 -147
- package/dist/generated/endpoints/zitadelNextGen.msw.d.mts.map +1 -1
- package/dist/generated/endpoints/zitadelNextGen.msw.mjs +1285 -347
- package/dist/generated/endpoints/zitadelNextGen.msw.mjs.map +1 -1
- package/dist/generated/endpoints/zitadelNextGen.zod.d.mts +1809 -1320
- package/dist/generated/endpoints/zitadelNextGen.zod.d.mts.map +1 -1
- package/dist/generated/endpoints/zitadelNextGen.zod.mjs +4287 -3812
- 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 +38 -15
- package/dist/generated/model/index.mjs.map +1 -1
- package/dist/{index-DCCtHY7q.d.mts → index-C1weUrQx.d.mts} +10024 -4295
- package/dist/index-C1weUrQx.d.mts.map +1 -0
- package/dist/runtime/api-factory.d.mts +19 -9
- package/dist/runtime/api-factory.d.mts.map +1 -1
- package/dist/runtime/api-factory.mjs +5 -0
- 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 +7 -8
- package/dist/runtime/config.d.mts.map +1 -1
- package/dist/runtime/config.mjs.map +1 -1
- package/dist/runtime/fetch.d.mts +2 -2
- package/dist/runtime/fetch.mjs +147 -11
- package/dist/runtime/fetch.mjs.map +1 -1
- package/dist/{zitadelNextGen-NzRGHVHl.d.mts → zitadelNextGen-KWjI2Uyj.d.mts} +48 -17
- package/dist/zitadelNextGen-KWjI2Uyj.d.mts.map +1 -0
- package/package.json +8 -4
- package/src/generated/endpoints/zitadelNextGen.faker.ts +188 -12162
- package/src/generated/endpoints/zitadelNextGen.msw.ts +923 -1858
- package/src/generated/endpoints/zitadelNextGen.ts +1475 -1296
- package/src/generated/endpoints/zitadelNextGen.zod.ts +6354 -19118
- package/src/generated/model/beginUserPasskeyRegistration201.ts +8 -8
- package/src/generated/model/beginUserPasskeyRegistration400.ts +1 -1
- package/src/generated/model/beginUserPasskeyRegistration401.ts +1 -1
- package/src/generated/model/beginUserPasskeyRegistration403.ts +1 -1
- package/src/generated/model/beginUserPasskeyRegistration404.ts +1 -1
- package/src/generated/model/beginUserPasskeyRegistration500.ts +1 -1
- package/src/generated/model/beginUserPasskeyRegistrationBody.ts +9 -9
- package/src/generated/model/beginUserPasskeyRegistrationDefault.ts +100 -111
- package/src/generated/model/completeClaim400.ts +1 -1
- package/src/generated/model/completeClaim401.ts +1 -1
- package/src/generated/model/completeClaim403.ts +28 -21
- package/src/generated/model/completeClaim404.ts +1 -1
- package/src/generated/model/completeClaim409.ts +2 -2
- package/src/generated/model/completeClaim410.ts +19 -21
- package/src/generated/model/completeClaim429.ts +1 -1
- package/src/generated/model/completeClaimBody.ts +3 -3
- package/src/generated/model/completeClaimDefault.ts +1 -1
- package/src/generated/model/createAuthAttempt201.ts +35 -35
- package/src/generated/model/createAuthAttempt201ChallengesItem.ts +20 -17
- package/src/generated/model/createAuthAttempt201ChallengesItemMethod.ts +7 -6
- package/src/generated/model/createAuthAttempt201ChallengesItemPayload.ts +20 -22
- package/src/generated/model/createAuthAttempt201ChallengesItemState.ts +5 -5
- package/src/generated/model/createAuthAttempt201CompletedFactorsItem.ts +8 -7
- package/src/generated/model/createAuthAttempt201CompletedFactorsItemMethod.ts +6 -5
- package/src/generated/model/createAuthAttempt201CompletedFactorsItemPayload.ts +23 -25
- package/src/generated/model/createAuthAttempt201RequiredFactorsItem.ts +6 -5
- package/src/generated/model/createAuthAttempt201State.ts +6 -6
- package/src/generated/model/createAuthAttemptBody.ts +7 -7
- package/src/generated/model/createAuthAttemptDefault.ts +46 -51
- package/src/generated/model/createBranding201.ts +11 -11
- package/src/generated/model/createBranding201Branding.ts +43 -43
- package/src/generated/model/createBranding201BrandingLayout.ts +4 -4
- package/src/generated/model/createBranding201BrandingShape.ts +12 -12
- package/src/generated/model/createBranding201BrandingShapeDensity.ts +5 -5
- package/src/generated/model/createBranding201BrandingTheme.ts +15 -15
- package/src/generated/model/createBranding201BrandingThemeDark.ts +13 -13
- package/src/generated/model/createBranding201BrandingThemeDarkPalette.ts +168 -168
- package/src/generated/model/createBranding201BrandingThemeLight.ts +13 -13
- package/src/generated/model/createBranding201BrandingThemeLightPalette.ts +168 -168
- package/src/generated/model/createBranding201BrandingThemeMode.ts +5 -5
- package/src/generated/model/createBranding201BrandingTypography.ts +27 -27
- package/src/generated/model/createBranding400.ts +1 -1
- package/src/generated/model/createBrandingBody.ts +43 -43
- package/src/generated/model/createBrandingBodyLayout.ts +4 -4
- package/src/generated/model/createBrandingBodyShape.ts +12 -12
- package/src/generated/model/createBrandingBodyShapeDensity.ts +5 -5
- package/src/generated/model/createBrandingBodyTheme.ts +15 -15
- package/src/generated/model/createBrandingBodyThemeDark.ts +13 -13
- package/src/generated/model/createBrandingBodyThemeDarkPalette.ts +168 -168
- package/src/generated/model/createBrandingBodyThemeLight.ts +13 -13
- package/src/generated/model/createBrandingBodyThemeLightPalette.ts +168 -168
- package/src/generated/model/createBrandingBodyThemeMode.ts +5 -5
- package/src/generated/model/createBrandingBodyTypography.ts +27 -27
- package/src/generated/model/createBrandingDefault.ts +1 -1
- package/src/generated/model/createBrandingParams.ts +5 -5
- package/src/generated/model/createDeployment200.ts +25 -25
- package/src/generated/model/createDeployment200Metadata.ts +29 -29
- package/src/generated/model/createDeployment200MetadataDeployedByType.ts +6 -7
- package/src/generated/model/createDeployment200MetadataReason.ts +5 -5
- package/src/generated/model/createDeployment200Release.ts +14 -14
- package/src/generated/model/createDeployment200ReleaseMetadata.ts +17 -17
- package/src/generated/model/createDeployment200ReleaseMetadataCreatedByType.ts +6 -7
- package/src/generated/model/createDeployment200ReleasePointersItem.ts +36 -36
- package/src/generated/model/createDeployment200ReleasePointersItemKind.ts +5 -5
- package/src/generated/model/createDeployment201.ts +25 -25
- package/src/generated/model/createDeployment201Metadata.ts +29 -29
- package/src/generated/model/createDeployment201MetadataDeployedByType.ts +6 -7
- package/src/generated/model/createDeployment201MetadataReason.ts +5 -5
- package/src/generated/model/createDeployment201Release.ts +14 -14
- package/src/generated/model/createDeployment201ReleaseMetadata.ts +17 -17
- package/src/generated/model/createDeployment201ReleaseMetadataCreatedByType.ts +6 -7
- package/src/generated/model/createDeployment201ReleasePointersItem.ts +36 -36
- package/src/generated/model/createDeployment201ReleasePointersItemKind.ts +5 -5
- package/src/generated/model/createDeploymentBody.ts +39 -39
- package/src/generated/model/createDeploymentBodyReason.ts +5 -5
- package/src/generated/model/createDeploymentDefault.ts +91 -101
- package/src/generated/model/createDeploymentParams.ts +5 -5
- package/src/generated/model/createFlow201.ts +28 -28
- package/src/generated/model/createFlow201Branding.ts +43 -43
- package/src/generated/model/createFlow201BrandingLayout.ts +4 -4
- package/src/generated/model/createFlow201BrandingShape.ts +12 -12
- package/src/generated/model/createFlow201BrandingShapeDensity.ts +5 -5
- package/src/generated/model/createFlow201BrandingTheme.ts +15 -15
- package/src/generated/model/createFlow201BrandingThemeDark.ts +13 -13
- package/src/generated/model/createFlow201BrandingThemeDarkPalette.ts +168 -168
- package/src/generated/model/createFlow201BrandingThemeLight.ts +13 -13
- package/src/generated/model/createFlow201BrandingThemeLightPalette.ts +168 -168
- package/src/generated/model/createFlow201BrandingThemeMode.ts +5 -5
- package/src/generated/model/createFlow201BrandingTypography.ts +27 -27
- package/src/generated/model/createFlow201Step.ts +79 -45
- package/src/generated/model/createFlow201StepActionsItem.ts +18 -18
- package/src/generated/model/createFlow201StepActionsItemKind.ts +7 -7
- package/src/generated/model/createFlow201StepChallenge.ts +10 -10
- package/src/generated/model/createFlow201StepChallengeMethod.ts +4 -4
- package/src/generated/model/createFlow201StepComplete.ts +4 -4
- package/src/generated/model/createFlow201StepFieldsItem.ts +48 -23
- package/src/generated/model/createFlow201StepFieldsItemType.ts +12 -12
- package/src/generated/model/createFlow201StepFieldsItemValidation.ts +18 -18
- package/src/generated/model/createFlow201StepFieldsItemValidationFormat.ts +6 -6
- package/src/generated/model/createFlow201StepGates.ts +10 -12
- package/src/generated/model/createFlow201StepGatesKind.ts +3 -3
- package/src/generated/model/createFlow201StepIdentifier.ts +53 -0
- package/src/generated/model/createFlow400.ts +1 -1
- package/src/generated/model/createFlowBody.ts +22 -22
- package/src/generated/model/createFlowBodyPurpose.ts +8 -8
- package/src/generated/model/createFlowDefault.ts +127 -141
- package/src/generated/model/createFlowDefinition201.ts +16 -16
- package/src/generated/model/createFlowDefinition201FlowDefinition.ts +39 -41
- package/src/generated/model/createFlowDefinition201FlowDefinitionStatus.ts +4 -4
- package/src/generated/model/createFlowDefinition201FlowDefinitionStepsItem.ts +55 -48
- package/src/generated/model/createFlowDefinition201FlowDefinitionStepsItemActionsItem.ts +24 -24
- package/src/generated/model/createFlowDefinition201FlowDefinitionStepsItemActionsItemKind.ts +6 -6
- package/src/generated/model/createFlowDefinition201FlowDefinitionStepsItemComplete.ts +4 -4
- package/src/generated/model/createFlowDefinition201FlowDefinitionStepsItemGates.ts +10 -12
- package/src/generated/model/createFlowDefinition201FlowDefinitionStepsItemGatesKind.ts +3 -3
- package/src/generated/model/createFlowDefinition201FlowDefinitionStepsItemOnSuccess.ts +9 -3
- package/src/generated/model/createFlowDefinition201FlowDefinitionStepsItemTransitions.ts +11 -13
- package/src/generated/model/createFlowDefinition201FlowDefinitionStepsItemTransitionsAction.ts +4 -5
- package/src/generated/model/createFlowDefinition201FlowDefinitionStepsItemTransitionsPurpose.ts +8 -9
- package/src/generated/model/createFlowDefinition201UserSchema.ts +5 -5
- package/src/generated/model/createFlowDefinition201UserSchemaSchema.ts +75 -77
- package/src/generated/model/createFlowDefinition400.ts +1 -1
- package/src/generated/model/createFlowDefinitionBody.ts +14 -14
- package/src/generated/model/createFlowDefinitionBodyFlowDefinition.ts +39 -41
- package/src/generated/model/createFlowDefinitionBodyFlowDefinitionStatus.ts +4 -4
- package/src/generated/model/createFlowDefinitionBodyFlowDefinitionStepsItem.ts +55 -48
- package/src/generated/model/createFlowDefinitionBodyFlowDefinitionStepsItemActionsItem.ts +24 -24
- package/src/generated/model/createFlowDefinitionBodyFlowDefinitionStepsItemActionsItemKind.ts +6 -6
- package/src/generated/model/createFlowDefinitionBodyFlowDefinitionStepsItemComplete.ts +4 -4
- package/src/generated/model/createFlowDefinitionBodyFlowDefinitionStepsItemGates.ts +10 -12
- package/src/generated/model/createFlowDefinitionBodyFlowDefinitionStepsItemGatesKind.ts +3 -3
- package/src/generated/model/createFlowDefinitionBodyFlowDefinitionStepsItemOnSuccess.ts +9 -3
- package/src/generated/model/createFlowDefinitionBodyFlowDefinitionStepsItemTransitions.ts +11 -13
- package/src/generated/model/createFlowDefinitionBodyFlowDefinitionStepsItemTransitionsAction.ts +4 -5
- package/src/generated/model/createFlowDefinitionBodyFlowDefinitionStepsItemTransitionsPurpose.ts +8 -9
- package/src/generated/model/createFlowDefinitionDefault.ts +91 -101
- package/src/generated/model/createGrant201.ts +17 -17
- package/src/generated/model/createGrant201ObjectType.ts +3 -3
- package/src/generated/model/createGrant201Relation.ts +5 -5
- package/src/generated/model/createGrant201Team.ts +6 -6
- package/src/generated/model/createGrant201TeamStatus.ts +4 -4
- package/src/generated/model/createGrant201User.ts +22 -22
- package/src/generated/model/createGrant201UserMetadata.ts +25 -25
- package/src/generated/model/createGrant201UserMetadataLifecycleOwnerTeam.ts +6 -6
- package/src/generated/model/createGrant201UserMetadataLifecycleOwnerTeamStatus.ts +4 -4
- package/src/generated/model/createGrant201UserMetadataStatus.ts +6 -6
- package/src/generated/model/createGrant400.ts +1 -1
- package/src/generated/model/createGrant401.ts +1 -1
- package/src/generated/model/createGrant403.ts +1 -1
- package/src/generated/model/createGrant404.ts +1 -1
- package/src/generated/model/createGrant409.ts +1 -1
- package/src/generated/model/createGrant429.ts +1 -1
- package/src/generated/model/createGrantBody.ts +15 -15
- package/src/generated/model/createGrantBodyRelation.ts +5 -5
- package/src/generated/model/createGrantBodyTeam.ts +4 -4
- package/src/generated/model/createGrantBodyUser.ts +8 -8
- package/src/generated/model/createGrantDefault.ts +91 -91
- package/src/generated/model/createGrantParams.ts +5 -5
- package/src/generated/model/createHandoff200.ts +10 -10
- package/src/generated/model/createHandoffDefault.ts +73 -81
- package/src/generated/model/createIdp200.ts +14 -14
- package/src/generated/model/createIdp200Definition.ts +17 -17
- package/src/generated/model/createIdp200DefinitionClaimMapping.ts +1 -1
- package/src/generated/model/createIdp200DefinitionOauth2.ts +22 -22
- package/src/generated/model/createIdp200DefinitionOauth2StaticAuthorizeParameters.ts +1 -1
- package/src/generated/model/createIdp200DefinitionOauth2SupplementaryFetch.ts +3 -3
- package/src/generated/model/createIdp200DefinitionOauth2TokenEndpointAuthMethod.ts +4 -4
- package/src/generated/model/createIdp200DefinitionOidc.ts +28 -28
- package/src/generated/model/createIdp200DefinitionOidcStaticAuthorizeParameters.ts +1 -1
- package/src/generated/model/createIdp200DefinitionOidcTokenEndpointAuthMethod.ts +4 -4
- package/src/generated/model/createIdp200DefinitionProtocol.ts +4 -4
- package/src/generated/model/createIdp200DefinitionProvisioning.ts +1 -1
- package/src/generated/model/createIdp200DefinitionProvisioningCreation.ts +4 -4
- package/src/generated/model/createIdp200DefinitionVerifiedClaims.ts +1 -1
- package/src/generated/model/createIdp201.ts +14 -14
- package/src/generated/model/createIdp201Definition.ts +17 -17
- package/src/generated/model/createIdp201DefinitionClaimMapping.ts +1 -1
- package/src/generated/model/createIdp201DefinitionOauth2.ts +22 -22
- package/src/generated/model/createIdp201DefinitionOauth2StaticAuthorizeParameters.ts +1 -1
- package/src/generated/model/createIdp201DefinitionOauth2SupplementaryFetch.ts +3 -3
- package/src/generated/model/createIdp201DefinitionOauth2TokenEndpointAuthMethod.ts +4 -4
- package/src/generated/model/createIdp201DefinitionOidc.ts +28 -28
- package/src/generated/model/createIdp201DefinitionOidcStaticAuthorizeParameters.ts +1 -1
- package/src/generated/model/createIdp201DefinitionOidcTokenEndpointAuthMethod.ts +4 -4
- package/src/generated/model/createIdp201DefinitionProtocol.ts +4 -4
- package/src/generated/model/createIdp201DefinitionProvisioning.ts +1 -1
- package/src/generated/model/createIdp201DefinitionProvisioningCreation.ts +4 -4
- package/src/generated/model/createIdp201DefinitionVerifiedClaims.ts +1 -1
- package/src/generated/model/createIdp400.ts +1 -1
- package/src/generated/model/createIdp401.ts +1 -1
- package/src/generated/model/createIdp403.ts +1 -1
- package/src/generated/model/createIdp404.ts +1 -1
- package/src/generated/model/createIdpBody.ts +1 -1
- package/src/generated/model/createIdpBodyIdp.ts +17 -17
- package/src/generated/model/createIdpBodyIdpClaimMapping.ts +1 -1
- package/src/generated/model/createIdpBodyIdpOauth2.ts +22 -22
- package/src/generated/model/createIdpBodyIdpOauth2StaticAuthorizeParameters.ts +1 -1
- package/src/generated/model/createIdpBodyIdpOauth2SupplementaryFetch.ts +3 -3
- package/src/generated/model/createIdpBodyIdpOauth2TokenEndpointAuthMethod.ts +4 -4
- package/src/generated/model/createIdpBodyIdpOidc.ts +28 -28
- package/src/generated/model/createIdpBodyIdpOidcStaticAuthorizeParameters.ts +1 -1
- package/src/generated/model/createIdpBodyIdpOidcTokenEndpointAuthMethod.ts +4 -4
- package/src/generated/model/createIdpBodyIdpProtocol.ts +4 -4
- package/src/generated/model/createIdpBodyIdpProvisioning.ts +1 -1
- package/src/generated/model/createIdpBodyIdpProvisioningCreation.ts +4 -4
- package/src/generated/model/createIdpBodyIdpVerifiedClaims.ts +1 -1
- package/src/generated/model/createIdpDefault.ts +73 -81
- package/src/generated/model/createIdpParams.ts +5 -5
- package/src/generated/model/createProject429.ts +1 -1
- package/src/generated/model/createProjectBody.ts +4 -4
- package/src/generated/model/createProjectDefault.ts +109 -121
- package/src/generated/model/createRelease200.ts +14 -14
- package/src/generated/model/createRelease200Metadata.ts +17 -17
- package/src/generated/model/createRelease200MetadataCreatedByType.ts +6 -7
- package/src/generated/model/createRelease200PointersItem.ts +36 -36
- package/src/generated/model/createRelease200PointersItemKind.ts +5 -5
- package/src/generated/model/createRelease201.ts +14 -14
- package/src/generated/model/createRelease201Metadata.ts +17 -17
- package/src/generated/model/createRelease201MetadataCreatedByType.ts +6 -7
- package/src/generated/model/createRelease201PointersItem.ts +36 -36
- package/src/generated/model/createRelease201PointersItemKind.ts +5 -5
- package/src/generated/model/createReleaseBody.ts +29 -29
- package/src/generated/model/createReleaseBodyPointersItem.ts +19 -19
- package/src/generated/model/createReleaseBodyPointersItemKind.ts +5 -5
- package/src/generated/model/createReleaseDefault.ts +91 -101
- package/src/generated/model/createReleaseParams.ts +5 -5
- package/src/generated/model/createSchemaBody.ts +91 -95
- package/src/generated/model/createSchemaDefault.ts +127 -141
- package/src/generated/model/createSchemaParams.ts +10 -10
- package/src/generated/model/createSession201.ts +12 -12
- package/src/generated/model/createSession201Session.ts +36 -36
- package/src/generated/model/createSession201SessionFactorsItem.ts +8 -7
- package/src/generated/model/createSession201SessionFactorsItemMethod.ts +6 -5
- package/src/generated/model/createSession201SessionFactorsItemPayload.ts +23 -25
- package/src/generated/model/createSession201SessionState.ts +5 -5
- package/src/generated/model/createSession201SessionUser.ts +14 -14
- package/src/generated/model/createSession201SessionUserAgent.ts +1 -1
- package/src/generated/model/createSession400.ts +1 -1
- package/src/generated/model/createSessionBody.ts +5 -5
- package/src/generated/model/createSessionBodyUserAgent.ts +1 -1
- package/src/generated/model/createSessionDefault.ts +91 -101
- package/src/generated/model/createTeam201.ts +6 -6
- package/src/generated/model/createTeam201Status.ts +4 -3
- package/src/generated/model/createTeam400.ts +1 -1
- package/src/generated/model/createTeam401.ts +1 -1
- package/src/generated/model/createTeam403.ts +1 -1
- package/src/generated/model/createTeam404.ts +1 -1
- package/src/generated/model/createTeam409.ts +1 -1
- package/src/generated/model/createTeam429.ts +1 -1
- package/src/generated/model/createTeamBody.ts +4 -4
- package/src/generated/model/createTeamDefault.ts +1 -1
- package/src/generated/model/createTeamParams.ts +5 -5
- package/src/generated/model/createUser201.ts +37 -37
- package/src/generated/model/createUser201Metadata.ts +25 -25
- package/src/generated/model/createUser201MetadataLifecycleOwnerTeam.ts +6 -6
- package/src/generated/model/createUser201MetadataLifecycleOwnerTeamStatus.ts +4 -4
- package/src/generated/model/createUser201MetadataStatus.ts +6 -6
- package/src/generated/model/createUser201TeamsItem.ts +4 -4
- package/src/generated/model/createUser201TeamsItemMembershipStatus.ts +5 -5
- package/src/generated/model/createUser400.ts +1 -1
- package/src/generated/model/createUser401.ts +1 -1
- package/src/generated/model/createUser403.ts +1 -1
- package/src/generated/model/createUser409.ts +1 -1
- package/src/generated/model/createUser500.ts +1 -1
- package/src/generated/model/createUserBody.ts +8 -8
- package/src/generated/model/createUserDefault.ts +82 -81
- package/src/generated/model/createUserParams.ts +21 -21
- package/src/generated/model/deleteGrant401.ts +1 -1
- package/src/generated/model/deleteGrant403.ts +1 -1
- package/src/generated/model/deleteGrant404.ts +1 -1
- package/src/generated/model/deleteGrantDefault.ts +64 -61
- package/src/generated/model/deleteGrantParams.ts +5 -5
- package/src/generated/model/deleteTeam400.ts +1 -1
- package/src/generated/model/deleteTeam401.ts +1 -1
- package/src/generated/model/deleteTeam403.ts +1 -1
- package/src/generated/model/deleteTeam409.ts +1 -1
- package/src/generated/model/deleteTeamDefault.ts +1 -1
- package/src/generated/model/deleteUserByID401.ts +1 -1
- package/src/generated/model/deleteUserByID404.ts +1 -1
- package/src/generated/model/deleteUserByIDDefault.ts +64 -61
- package/src/generated/model/deleteVariableDefault.ts +55 -61
- package/src/generated/model/deleteVariableParams.ts +15 -15
- package/src/generated/model/exchangeHandoff200.ts +12 -12
- package/src/generated/model/exchangeHandoff200Session.ts +36 -36
- package/src/generated/model/exchangeHandoff200SessionFactorsItem.ts +8 -7
- package/src/generated/model/exchangeHandoff200SessionFactorsItemMethod.ts +6 -5
- package/src/generated/model/exchangeHandoff200SessionFactorsItemPayload.ts +23 -25
- package/src/generated/model/exchangeHandoff200SessionState.ts +5 -5
- package/src/generated/model/exchangeHandoff200SessionUser.ts +14 -14
- package/src/generated/model/exchangeHandoff200SessionUserAgent.ts +1 -1
- package/src/generated/model/exchangeHandoff400.ts +1 -1
- package/src/generated/model/exchangeHandoff401.ts +1 -1
- package/src/generated/model/exchangeHandoff410.ts +1 -1
- package/src/generated/model/exchangeHandoffBody.ts +6 -6
- package/src/generated/model/exchangeHandoffDefault.ts +136 -151
- package/src/generated/model/exchangeHandoffParams.ts +5 -5
- package/src/generated/model/finishUserPasskeyRegistration400.ts +1 -1
- package/src/generated/model/finishUserPasskeyRegistration401.ts +1 -1
- package/src/generated/model/finishUserPasskeyRegistration403.ts +1 -1
- package/src/generated/model/finishUserPasskeyRegistration404.ts +1 -1
- package/src/generated/model/finishUserPasskeyRegistration500.ts +1 -1
- package/src/generated/model/finishUserPasskeyRegistrationBody.ts +4 -4
- package/src/generated/model/finishUserPasskeyRegistrationDefault.ts +145 -141
- package/src/generated/model/getAuthAttempt200.ts +35 -35
- package/src/generated/model/getAuthAttempt200ChallengesItem.ts +20 -17
- package/src/generated/model/getAuthAttempt200ChallengesItemMethod.ts +7 -6
- package/src/generated/model/getAuthAttempt200ChallengesItemPayload.ts +20 -22
- package/src/generated/model/getAuthAttempt200ChallengesItemState.ts +5 -5
- package/src/generated/model/getAuthAttempt200CompletedFactorsItem.ts +8 -7
- package/src/generated/model/getAuthAttempt200CompletedFactorsItemMethod.ts +6 -5
- package/src/generated/model/getAuthAttempt200CompletedFactorsItemPayload.ts +23 -25
- package/src/generated/model/getAuthAttempt200RequiredFactorsItem.ts +6 -5
- package/src/generated/model/getAuthAttempt200State.ts +6 -6
- package/src/generated/model/getAuthAttemptDefault.ts +37 -41
- package/src/generated/model/getBrandingById200.ts +11 -11
- package/src/generated/model/getBrandingById200Branding.ts +43 -43
- package/src/generated/model/getBrandingById200BrandingLayout.ts +4 -4
- package/src/generated/model/getBrandingById200BrandingShape.ts +12 -12
- package/src/generated/model/getBrandingById200BrandingShapeDensity.ts +5 -5
- package/src/generated/model/getBrandingById200BrandingTheme.ts +15 -15
- package/src/generated/model/getBrandingById200BrandingThemeDark.ts +13 -13
- package/src/generated/model/getBrandingById200BrandingThemeDarkPalette.ts +168 -168
- package/src/generated/model/getBrandingById200BrandingThemeLight.ts +13 -13
- package/src/generated/model/getBrandingById200BrandingThemeLightPalette.ts +168 -168
- package/src/generated/model/getBrandingById200BrandingThemeMode.ts +5 -5
- package/src/generated/model/getBrandingById200BrandingTypography.ts +27 -27
- package/src/generated/model/getBrandingById404.ts +1 -1
- package/src/generated/model/getBrandingByIdDefault.ts +1 -1
- package/src/generated/model/getClaimStatus200.ts +13 -15
- package/src/generated/model/getClaimStatus401.ts +1 -1
- package/src/generated/model/getClaimStatus403.ts +1 -1
- package/src/generated/model/getClaimStatus404.ts +1 -1
- package/src/generated/model/getClaimStatus410.ts +19 -21
- package/src/generated/model/getClaimStatus429.ts +1 -1
- package/src/generated/model/getClaimStatusDefault.ts +1 -1
- package/src/generated/model/getClaimStatusParams.ts +5 -5
- package/src/generated/model/getClaimWindow200.ts +4 -4
- package/src/generated/model/getClaimWindow404.ts +1 -1
- package/src/generated/model/getClaimWindow429.ts +1 -1
- package/src/generated/model/getClaimWindowDefault.ts +1 -1
- package/src/generated/model/getClaimWindowParams.ts +5 -5
- package/src/generated/model/getDeploymentById200.ts +25 -25
- package/src/generated/model/getDeploymentById200Metadata.ts +29 -29
- package/src/generated/model/getDeploymentById200MetadataDeployedByType.ts +6 -7
- package/src/generated/model/getDeploymentById200MetadataReason.ts +5 -5
- package/src/generated/model/getDeploymentById200Release.ts +14 -14
- package/src/generated/model/getDeploymentById200ReleaseMetadata.ts +17 -17
- package/src/generated/model/getDeploymentById200ReleaseMetadataCreatedByType.ts +6 -7
- package/src/generated/model/getDeploymentById200ReleasePointersItem.ts +36 -36
- package/src/generated/model/getDeploymentById200ReleasePointersItemKind.ts +5 -5
- package/src/generated/model/getDeploymentByIdDefault.ts +46 -51
- package/src/generated/model/getDeploymentByIdParams.ts +5 -5
- package/src/generated/model/getEnvironmentByName200.ts +12 -12
- package/src/generated/model/getEnvironmentByName200CurrentDeployment.ts +16 -16
- package/src/generated/model/getEnvironmentByName200CurrentDeploymentReason.ts +5 -5
- package/src/generated/model/getEnvironmentByNameDefault.ts +46 -51
- package/src/generated/model/getEnvironmentByNameParams.ts +5 -5
- package/src/generated/model/getEvent200.ts +2594 -2335
- package/src/generated/model/getEvent401.ts +1 -1
- package/src/generated/model/getEvent403.ts +1 -1
- package/src/generated/model/getEvent404.ts +1 -1
- package/src/generated/model/getEventDefault.ts +1 -1
- package/src/generated/model/getEventParams.ts +5 -5
- package/src/generated/model/getFlowDefinition200.ts +16 -16
- package/src/generated/model/getFlowDefinition200FlowDefinition.ts +39 -41
- package/src/generated/model/getFlowDefinition200FlowDefinitionStatus.ts +4 -4
- package/src/generated/model/getFlowDefinition200FlowDefinitionStepsItem.ts +55 -48
- package/src/generated/model/getFlowDefinition200FlowDefinitionStepsItemActionsItem.ts +24 -24
- package/src/generated/model/getFlowDefinition200FlowDefinitionStepsItemActionsItemKind.ts +6 -6
- package/src/generated/model/getFlowDefinition200FlowDefinitionStepsItemComplete.ts +4 -4
- package/src/generated/model/getFlowDefinition200FlowDefinitionStepsItemGates.ts +10 -12
- package/src/generated/model/getFlowDefinition200FlowDefinitionStepsItemGatesKind.ts +3 -3
- package/src/generated/model/getFlowDefinition200FlowDefinitionStepsItemOnSuccess.ts +9 -3
- package/src/generated/model/getFlowDefinition200FlowDefinitionStepsItemTransitions.ts +11 -13
- package/src/generated/model/getFlowDefinition200FlowDefinitionStepsItemTransitionsAction.ts +4 -5
- package/src/generated/model/getFlowDefinition200FlowDefinitionStepsItemTransitionsPurpose.ts +8 -9
- package/src/generated/model/getFlowDefinition200UserSchema.ts +5 -5
- package/src/generated/model/getFlowDefinition200UserSchemaSchema.ts +75 -77
- package/src/generated/model/getFlowDefinitionDefault.ts +64 -71
- package/src/generated/model/getFlowStep200.ts +28 -28
- package/src/generated/model/getFlowStep200Branding.ts +43 -43
- package/src/generated/model/getFlowStep200BrandingLayout.ts +4 -4
- package/src/generated/model/getFlowStep200BrandingShape.ts +12 -12
- package/src/generated/model/getFlowStep200BrandingShapeDensity.ts +5 -5
- package/src/generated/model/getFlowStep200BrandingTheme.ts +15 -15
- package/src/generated/model/getFlowStep200BrandingThemeDark.ts +13 -13
- package/src/generated/model/getFlowStep200BrandingThemeDarkPalette.ts +168 -168
- package/src/generated/model/getFlowStep200BrandingThemeLight.ts +13 -13
- package/src/generated/model/getFlowStep200BrandingThemeLightPalette.ts +168 -168
- package/src/generated/model/getFlowStep200BrandingThemeMode.ts +5 -5
- package/src/generated/model/getFlowStep200BrandingTypography.ts +27 -27
- package/src/generated/model/getFlowStep200Step.ts +79 -45
- package/src/generated/model/getFlowStep200StepActionsItem.ts +18 -18
- package/src/generated/model/getFlowStep200StepActionsItemKind.ts +7 -7
- package/src/generated/model/getFlowStep200StepChallenge.ts +10 -10
- package/src/generated/model/getFlowStep200StepChallengeMethod.ts +4 -4
- package/src/generated/model/getFlowStep200StepComplete.ts +4 -4
- package/src/generated/model/getFlowStep200StepFieldsItem.ts +48 -23
- package/src/generated/model/getFlowStep200StepFieldsItemType.ts +12 -12
- package/src/generated/model/getFlowStep200StepFieldsItemValidation.ts +18 -18
- package/src/generated/model/getFlowStep200StepFieldsItemValidationFormat.ts +6 -6
- package/src/generated/model/getFlowStep200StepGates.ts +10 -12
- package/src/generated/model/getFlowStep200StepGatesKind.ts +3 -3
- package/src/generated/model/getFlowStep200StepIdentifier.ts +53 -0
- package/src/generated/model/getFlowStep404.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 +1 -1
- package/src/generated/model/getFlowStepDefault.ts +271 -111
- package/src/generated/model/getGrant200.ts +17 -17
- package/src/generated/model/getGrant200ObjectType.ts +3 -3
- package/src/generated/model/getGrant200Relation.ts +5 -4
- package/src/generated/model/getGrant200Team.ts +6 -6
- package/src/generated/model/getGrant200TeamStatus.ts +4 -4
- package/src/generated/model/getGrant200User.ts +22 -22
- package/src/generated/model/getGrant200UserMetadata.ts +25 -25
- package/src/generated/model/getGrant200UserMetadataLifecycleOwnerTeam.ts +6 -6
- package/src/generated/model/getGrant200UserMetadataLifecycleOwnerTeamStatus.ts +4 -4
- package/src/generated/model/getGrant200UserMetadataStatus.ts +6 -6
- package/src/generated/model/getGrant401.ts +1 -1
- package/src/generated/model/getGrant403.ts +1 -1
- package/src/generated/model/getGrant404.ts +1 -1
- package/src/generated/model/getGrantDefault.ts +64 -71
- package/src/generated/model/getGrantExpandItem.ts +3 -2
- package/src/generated/model/getGrantParams.ts +11 -11
- package/src/generated/model/getHealth4xx.ts +1 -1
- package/src/generated/model/getHealthDefault.ts +1 -1
- package/src/generated/model/getIdpById200.ts +14 -14
- package/src/generated/model/getIdpById200Definition.ts +17 -17
- package/src/generated/model/getIdpById200DefinitionClaimMapping.ts +1 -1
- package/src/generated/model/getIdpById200DefinitionOauth2.ts +22 -22
- package/src/generated/model/getIdpById200DefinitionOauth2StaticAuthorizeParameters.ts +1 -1
- package/src/generated/model/getIdpById200DefinitionOauth2SupplementaryFetch.ts +3 -3
- package/src/generated/model/getIdpById200DefinitionOauth2TokenEndpointAuthMethod.ts +4 -4
- package/src/generated/model/getIdpById200DefinitionOidc.ts +28 -28
- package/src/generated/model/getIdpById200DefinitionOidcStaticAuthorizeParameters.ts +1 -1
- package/src/generated/model/getIdpById200DefinitionOidcTokenEndpointAuthMethod.ts +4 -4
- package/src/generated/model/getIdpById200DefinitionProtocol.ts +4 -4
- package/src/generated/model/getIdpById200DefinitionProvisioning.ts +1 -1
- package/src/generated/model/getIdpById200DefinitionProvisioningCreation.ts +4 -4
- package/src/generated/model/getIdpById200DefinitionVerifiedClaims.ts +1 -1
- package/src/generated/model/getIdpById401.ts +1 -1
- package/src/generated/model/getIdpById403.ts +1 -1
- package/src/generated/model/getIdpById404.ts +1 -1
- package/src/generated/model/getIdpByIdDefault.ts +46 -51
- package/src/generated/model/getIdpByIdParams.ts +5 -5
- package/src/generated/model/getIdpRevisionById200.ts +14 -14
- package/src/generated/model/getIdpRevisionById200Definition.ts +17 -17
- package/src/generated/model/getIdpRevisionById200DefinitionClaimMapping.ts +1 -1
- package/src/generated/model/getIdpRevisionById200DefinitionOauth2.ts +22 -22
- package/src/generated/model/getIdpRevisionById200DefinitionOauth2StaticAuthorizeParameters.ts +1 -3
- package/src/generated/model/getIdpRevisionById200DefinitionOauth2SupplementaryFetch.ts +3 -3
- package/src/generated/model/getIdpRevisionById200DefinitionOauth2TokenEndpointAuthMethod.ts +4 -4
- package/src/generated/model/getIdpRevisionById200DefinitionOidc.ts +28 -28
- package/src/generated/model/getIdpRevisionById200DefinitionOidcStaticAuthorizeParameters.ts +1 -3
- package/src/generated/model/getIdpRevisionById200DefinitionOidcTokenEndpointAuthMethod.ts +4 -4
- package/src/generated/model/getIdpRevisionById200DefinitionProtocol.ts +4 -4
- package/src/generated/model/getIdpRevisionById200DefinitionProvisioning.ts +1 -1
- package/src/generated/model/getIdpRevisionById200DefinitionProvisioningCreation.ts +4 -4
- package/src/generated/model/getIdpRevisionById200DefinitionVerifiedClaims.ts +1 -1
- package/src/generated/model/getIdpRevisionById401.ts +1 -1
- package/src/generated/model/getIdpRevisionById403.ts +1 -1
- package/src/generated/model/getIdpRevisionById404.ts +1 -1
- package/src/generated/model/getIdpRevisionByIdDefault.ts +46 -51
- package/src/generated/model/getIdpRevisionByIdParams.ts +5 -5
- package/src/generated/model/getLive4xx.ts +1 -1
- package/src/generated/model/getLiveDefault.ts +1 -1
- package/src/generated/model/getMySession200.ts +36 -36
- package/src/generated/model/getMySession200FactorsItem.ts +8 -7
- package/src/generated/model/getMySession200FactorsItemMethod.ts +6 -5
- package/src/generated/model/getMySession200FactorsItemPayload.ts +23 -25
- package/src/generated/model/getMySession200State.ts +5 -4
- package/src/generated/model/getMySession200User.ts +14 -14
- package/src/generated/model/getMySession200UserAgent.ts +1 -1
- package/src/generated/model/getMySession401.ts +1 -1
- package/src/generated/model/getMySession404.ts +1 -1
- package/src/generated/model/getMySessionCsrfToken200.ts +18 -0
- package/src/generated/model/getMySessionCsrfToken401.ts +23 -0
- package/src/generated/model/getMySessionDefault.ts +37 -41
- package/src/generated/model/getMyUser200.ts +37 -37
- package/src/generated/model/getMyUser200Metadata.ts +25 -25
- package/src/generated/model/getMyUser200MetadataLifecycleOwnerTeam.ts +6 -6
- package/src/generated/model/getMyUser200MetadataLifecycleOwnerTeamStatus.ts +4 -4
- package/src/generated/model/getMyUser200MetadataStatus.ts +6 -6
- package/src/generated/model/getMyUser200TeamsItem.ts +4 -4
- package/src/generated/model/getMyUser200TeamsItemMembershipStatus.ts +5 -5
- package/src/generated/model/getMyUser401.ts +1 -1
- package/src/generated/model/getMyUser404.ts +1 -1
- package/src/generated/model/getMyUserDefault.ts +46 -51
- package/src/generated/model/getProject200.ts +4 -4
- package/src/generated/model/getProject200PasswordHash.ts +24 -24
- package/src/generated/model/getProject200PasswordHashAlgorithm.ts +8 -8
- package/src/generated/model/getProject200PasswordHashParams.ts +6 -6
- package/src/generated/model/getProject200PasswordHashParamsHash.ts +7 -7
- package/src/generated/model/getProject401.ts +1 -1
- package/src/generated/model/getProject404.ts +1 -1
- package/src/generated/model/getProjectDefault.ts +64 -71
- package/src/generated/model/getReady4xx.ts +1 -1
- package/src/generated/model/getReadyDefault.ts +1 -1
- package/src/generated/model/getReleaseById200.ts +14 -14
- package/src/generated/model/getReleaseById200Metadata.ts +17 -17
- package/src/generated/model/getReleaseById200MetadataCreatedByType.ts +6 -7
- package/src/generated/model/getReleaseById200PointersItem.ts +36 -36
- package/src/generated/model/getReleaseById200PointersItemKind.ts +5 -5
- package/src/generated/model/getReleaseByIdDefault.ts +46 -51
- package/src/generated/model/getReleaseByIdParams.ts +5 -5
- package/src/generated/model/getSchemaById200.ts +5 -5
- package/src/generated/model/getSchemaById200Schema.ts +75 -77
- package/src/generated/model/getSchemaByIdDefault.ts +46 -51
- package/src/generated/model/getSchemaByIdParams.ts +11 -11
- package/src/generated/model/getSession200.ts +36 -36
- package/src/generated/model/getSession200FactorsItem.ts +8 -7
- package/src/generated/model/getSession200FactorsItemMethod.ts +6 -5
- package/src/generated/model/getSession200FactorsItemPayload.ts +23 -25
- package/src/generated/model/getSession200State.ts +5 -4
- package/src/generated/model/getSession200User.ts +14 -14
- package/src/generated/model/getSession200UserAgent.ts +1 -1
- package/src/generated/model/getSession401.ts +1 -1
- package/src/generated/model/getSession403.ts +1 -1
- package/src/generated/model/getSession404.ts +1 -1
- package/src/generated/model/getSessionDefault.ts +46 -51
- package/src/generated/model/getTeam200.ts +6 -6
- package/src/generated/model/getTeam200Status.ts +4 -3
- package/src/generated/model/getTeam401.ts +1 -1
- package/src/generated/model/getTeam404.ts +1 -1
- package/src/generated/model/getTeamDefault.ts +1 -1
- package/src/generated/model/getUserByID200.ts +37 -37
- package/src/generated/model/getUserByID200Metadata.ts +25 -25
- package/src/generated/model/getUserByID200MetadataLifecycleOwnerTeam.ts +6 -6
- package/src/generated/model/getUserByID200MetadataLifecycleOwnerTeamStatus.ts +4 -4
- package/src/generated/model/getUserByID200MetadataStatus.ts +6 -6
- package/src/generated/model/getUserByID200TeamsItem.ts +4 -4
- package/src/generated/model/getUserByID200TeamsItemMembershipStatus.ts +5 -5
- package/src/generated/model/getUserByID401.ts +1 -1
- package/src/generated/model/getUserByID404.ts +1 -1
- package/src/generated/model/getUserByIDDefault.ts +46 -51
- package/src/generated/model/getUserByIDParams.ts +20 -15
- package/src/generated/model/getVariable200.ts +4 -8
- package/src/generated/model/getVariableDefault.ts +55 -61
- package/src/generated/model/getVariableParams.ts +15 -15
- package/src/generated/model/getVariables200.ts +4 -10
- package/src/generated/model/getVariablesDefault.ts +55 -61
- package/src/generated/model/getVariablesParams.ts +15 -15
- package/src/generated/model/index.ts +1155 -1147
- package/src/generated/model/initClaim201.ts +6 -6
- package/src/generated/model/initClaim401.ts +1 -1
- package/src/generated/model/initClaim404.ts +1 -1
- package/src/generated/model/initClaim409.ts +2 -2
- package/src/generated/model/initClaim410.ts +1 -1
- package/src/generated/model/initClaimDefault.ts +1 -1
- package/src/generated/model/issueChallenge201.ts +20 -17
- package/src/generated/model/issueChallenge201Method.ts +7 -6
- package/src/generated/model/issueChallenge201Payload.ts +20 -22
- package/src/generated/model/issueChallenge201State.ts +5 -5
- package/src/generated/model/issueChallengeBody.ts +6 -3
- package/src/generated/model/issueChallengeBodyMethod.ts +7 -6
- package/src/generated/model/issueChallengeBodyPasskeyOptions.ts +1 -1
- package/src/generated/model/issueChallengeBodyPasskeyOptionsUserVerification.ts +5 -5
- package/src/generated/model/issueChallengeDefault.ts +64 -71
- package/src/generated/model/listBrandingDefault.ts +1 -1
- package/src/generated/model/listBrandingParams.ts +5 -5
- package/src/generated/model/listDeployments200.ts +4 -4
- package/src/generated/model/listDeployments200DeploymentsItem.ts +25 -25
- package/src/generated/model/listDeployments200DeploymentsItemMetadata.ts +29 -29
- package/src/generated/model/listDeployments200DeploymentsItemMetadataDeployedByType.ts +6 -7
- package/src/generated/model/listDeployments200DeploymentsItemMetadataReason.ts +5 -5
- package/src/generated/model/listDeployments200DeploymentsItemRelease.ts +14 -14
- package/src/generated/model/listDeployments200DeploymentsItemReleaseMetadata.ts +17 -17
- package/src/generated/model/listDeployments200DeploymentsItemReleaseMetadataCreatedByType.ts +6 -7
- package/src/generated/model/listDeployments200DeploymentsItemReleasePointersItem.ts +36 -36
- package/src/generated/model/listDeployments200DeploymentsItemReleasePointersItemKind.ts +5 -5
- package/src/generated/model/listDeploymentsDefault.ts +55 -61
- package/src/generated/model/listDeploymentsExpandItem.ts +3 -3
- package/src/generated/model/listDeploymentsParams.ts +33 -33
- package/src/generated/model/listEnvironments200.ts +4 -4
- package/src/generated/model/listEnvironments200EnvironmentsItem.ts +12 -12
- package/src/generated/model/listEnvironments200EnvironmentsItemCurrentDeployment.ts +16 -16
- package/src/generated/model/listEnvironments200EnvironmentsItemCurrentDeploymentReason.ts +5 -5
- package/src/generated/model/listEnvironmentsDefault.ts +46 -51
- package/src/generated/model/listEnvironmentsParams.ts +18 -18
- package/src/generated/model/listEvents200.ts +4 -4
- package/src/generated/model/listEvents200DataItem.ts +2594 -2335
- package/src/generated/model/listEvents400.ts +1 -1
- package/src/generated/model/listEvents401.ts +1 -1
- package/src/generated/model/listEvents403.ts +1 -1
- package/src/generated/model/listEventsCategoryItem.ts +8 -8
- package/src/generated/model/listEventsDefault.ts +1 -1
- package/src/generated/model/listEventsOrder.ts +4 -3
- package/src/generated/model/listEventsParams.ts +53 -53
- package/src/generated/model/listFlowDefinitions200.ts +1 -1
- package/src/generated/model/listFlowDefinitions200FlowDefinitionsItem.ts +16 -16
- package/src/generated/model/listFlowDefinitions200FlowDefinitionsItemFlowDefinition.ts +39 -41
- package/src/generated/model/listFlowDefinitions200FlowDefinitionsItemFlowDefinitionStatus.ts +4 -4
- package/src/generated/model/listFlowDefinitions200FlowDefinitionsItemFlowDefinitionStepsItem.ts +55 -48
- package/src/generated/model/listFlowDefinitions200FlowDefinitionsItemFlowDefinitionStepsItemActionsItem.ts +24 -24
- package/src/generated/model/listFlowDefinitions200FlowDefinitionsItemFlowDefinitionStepsItemActionsItemKind.ts +6 -6
- package/src/generated/model/listFlowDefinitions200FlowDefinitionsItemFlowDefinitionStepsItemComplete.ts +4 -4
- package/src/generated/model/listFlowDefinitions200FlowDefinitionsItemFlowDefinitionStepsItemGates.ts +10 -12
- package/src/generated/model/listFlowDefinitions200FlowDefinitionsItemFlowDefinitionStepsItemGatesConfig.ts +1 -3
- package/src/generated/model/listFlowDefinitions200FlowDefinitionsItemFlowDefinitionStepsItemGatesKind.ts +3 -3
- package/src/generated/model/listFlowDefinitions200FlowDefinitionsItemFlowDefinitionStepsItemOnSuccess.ts +9 -3
- package/src/generated/model/listFlowDefinitions200FlowDefinitionsItemFlowDefinitionStepsItemTransitions.ts +11 -13
- package/src/generated/model/listFlowDefinitions200FlowDefinitionsItemFlowDefinitionStepsItemTransitionsAction.ts +4 -5
- package/src/generated/model/listFlowDefinitions200FlowDefinitionsItemFlowDefinitionStepsItemTransitionsPurpose.ts +8 -9
- package/src/generated/model/listFlowDefinitions200FlowDefinitionsItemUserSchema.ts +5 -5
- package/src/generated/model/listFlowDefinitions200FlowDefinitionsItemUserSchemaSchema.ts +75 -77
- package/src/generated/model/listFlowDefinitions400.ts +1 -1
- package/src/generated/model/listFlowDefinitionsDefault.ts +82 -91
- package/src/generated/model/listFlowDefinitionsExpandItem.ts +3 -3
- package/src/generated/model/listFlowDefinitionsParams.ts +49 -49
- package/src/generated/model/listFlowDefinitionsPurpose.ts +8 -8
- package/src/generated/model/listFlowDefinitionsRevisions.ts +4 -4
- package/src/generated/model/listIdpRevisions200.ts +4 -4
- package/src/generated/model/listIdpRevisions200RevisionsItem.ts +14 -14
- package/src/generated/model/listIdpRevisions200RevisionsItemDefinition.ts +17 -17
- package/src/generated/model/listIdpRevisions200RevisionsItemDefinitionClaimMapping.ts +1 -1
- package/src/generated/model/listIdpRevisions200RevisionsItemDefinitionOauth2.ts +22 -22
- package/src/generated/model/listIdpRevisions200RevisionsItemDefinitionOauth2StaticAuthorizeParameters.ts +1 -3
- package/src/generated/model/listIdpRevisions200RevisionsItemDefinitionOauth2SupplementaryFetch.ts +3 -3
- package/src/generated/model/listIdpRevisions200RevisionsItemDefinitionOauth2TokenEndpointAuthMethod.ts +4 -4
- package/src/generated/model/listIdpRevisions200RevisionsItemDefinitionOidc.ts +28 -28
- package/src/generated/model/listIdpRevisions200RevisionsItemDefinitionOidcStaticAuthorizeParameters.ts +1 -3
- package/src/generated/model/listIdpRevisions200RevisionsItemDefinitionOidcTokenEndpointAuthMethod.ts +4 -4
- package/src/generated/model/listIdpRevisions200RevisionsItemDefinitionProtocol.ts +4 -4
- package/src/generated/model/listIdpRevisions200RevisionsItemDefinitionProvisioning.ts +1 -1
- package/src/generated/model/listIdpRevisions200RevisionsItemDefinitionProvisioningCreation.ts +4 -4
- package/src/generated/model/listIdpRevisions200RevisionsItemDefinitionVerifiedClaims.ts +1 -3
- package/src/generated/model/listIdpRevisions401.ts +1 -1
- package/src/generated/model/listIdpRevisions403.ts +1 -1
- package/src/generated/model/listIdpRevisions404.ts +1 -1
- package/src/generated/model/listIdpRevisionsDefault.ts +46 -51
- package/src/generated/model/listIdpRevisionsParams.ts +18 -18
- package/src/generated/model/listMyProjects200.ts +5 -5
- package/src/generated/model/listMyProjects200ProjectsItem.ts +4 -4
- package/src/generated/model/listMyProjects200ProjectsItemPasswordHash.ts +24 -24
- package/src/generated/model/listMyProjects200ProjectsItemPasswordHashAlgorithm.ts +8 -8
- package/src/generated/model/listMyProjects200ProjectsItemPasswordHashParams.ts +6 -6
- package/src/generated/model/listMyProjects200ProjectsItemPasswordHashParamsHash.ts +7 -7
- package/src/generated/model/listMyProjects400.ts +1 -1
- package/src/generated/model/listMyProjects401.ts +1 -1
- package/src/generated/model/listMyProjects500.ts +1 -1
- package/src/generated/model/listMyProjectsDefault.ts +28 -31
- package/src/generated/model/listMyProjectsParams.ts +13 -13
- package/src/generated/model/listReleases200.ts +4 -4
- package/src/generated/model/listReleases200ReleasesItem.ts +7 -7
- package/src/generated/model/listReleases200ReleasesItemMetadata.ts +17 -17
- package/src/generated/model/listReleases200ReleasesItemMetadataCreatedByType.ts +6 -7
- package/src/generated/model/listReleasesDefault.ts +46 -51
- package/src/generated/model/listReleasesParams.ts +18 -18
- package/src/generated/model/listSchemas200.ts +4 -4
- package/src/generated/model/listSchemas200SchemasItem.ts +5 -5
- package/src/generated/model/listSchemas200SchemasItemSchema.ts +75 -77
- package/src/generated/model/listSchemasDefault.ts +46 -51
- package/src/generated/model/listSchemasKind.ts +3 -2
- package/src/generated/model/listSchemasParams.ts +52 -52
- package/src/generated/model/listSchemasRevisions.ts +4 -3
- package/src/generated/model/listUserPasskeys200.ts +4 -4
- package/src/generated/model/listUserPasskeys400.ts +1 -1
- package/src/generated/model/listUserPasskeys401.ts +1 -1
- package/src/generated/model/listUserPasskeys403.ts +1 -1
- package/src/generated/model/listUserPasskeys404.ts +1 -1
- package/src/generated/model/listUserPasskeys500.ts +1 -1
- package/src/generated/model/listUserPasskeysDefault.ts +46 -51
- package/src/generated/model/listUserPasskeysParams.ts +13 -13
- package/src/generated/model/listUserTeams200.ts +4 -4
- package/src/generated/model/listUserTeams200TeamsItem.ts +4 -4
- package/src/generated/model/listUserTeams200TeamsItemMembershipStatus.ts +5 -5
- package/src/generated/model/listUserTeams400.ts +1 -1
- package/src/generated/model/listUserTeams401.ts +1 -1
- package/src/generated/model/listUserTeams403.ts +1 -1
- package/src/generated/model/listUserTeams404.ts +1 -1
- package/src/generated/model/listUserTeams500.ts +1 -1
- package/src/generated/model/listUserTeamsDefault.ts +46 -51
- package/src/generated/model/listUserTeamsParams.ts +13 -13
- package/src/generated/model/patchMyUser200.ts +37 -37
- package/src/generated/model/patchMyUser200Metadata.ts +25 -25
- package/src/generated/model/patchMyUser200MetadataLifecycleOwnerTeam.ts +6 -6
- package/src/generated/model/patchMyUser200MetadataLifecycleOwnerTeamStatus.ts +4 -4
- package/src/generated/model/patchMyUser200MetadataStatus.ts +6 -6
- package/src/generated/model/patchMyUser200TeamsItem.ts +4 -4
- package/src/generated/model/patchMyUser200TeamsItemMembershipStatus.ts +5 -5
- package/src/generated/model/patchMyUser400.ts +1 -1
- package/src/generated/model/patchMyUser401.ts +1 -1
- package/src/generated/model/patchMyUser404.ts +1 -1
- package/src/generated/model/patchMyUser409.ts +1 -1
- package/src/generated/model/patchMyUserBody.ts +4 -4
- package/src/generated/model/patchMyUserDefault.ts +91 -91
- package/src/generated/model/patchProject200.ts +4 -4
- package/src/generated/model/patchProject200PasswordHash.ts +24 -24
- package/src/generated/model/patchProject200PasswordHashAlgorithm.ts +8 -8
- package/src/generated/model/patchProject200PasswordHashParams.ts +6 -6
- package/src/generated/model/patchProject200PasswordHashParamsHash.ts +7 -7
- package/src/generated/model/patchProject400.ts +1 -1
- package/src/generated/model/patchProject401.ts +1 -1
- package/src/generated/model/patchProject404.ts +1 -1
- package/src/generated/model/patchProjectBody.ts +5 -5
- package/src/generated/model/patchProjectBodyPasswordHash.ts +24 -24
- package/src/generated/model/patchProjectBodyPasswordHashAlgorithm.ts +8 -8
- package/src/generated/model/patchProjectBodyPasswordHashParams.ts +6 -6
- package/src/generated/model/patchProjectBodyPasswordHashParamsHash.ts +7 -7
- package/src/generated/model/patchProjectDefault.ts +91 -91
- package/src/generated/model/patchUserByID200.ts +37 -37
- package/src/generated/model/patchUserByID200Metadata.ts +25 -25
- package/src/generated/model/patchUserByID200MetadataLifecycleOwnerTeam.ts +6 -6
- package/src/generated/model/patchUserByID200MetadataLifecycleOwnerTeamStatus.ts +4 -4
- package/src/generated/model/patchUserByID200MetadataStatus.ts +6 -6
- package/src/generated/model/patchUserByID200TeamsItem.ts +4 -4
- package/src/generated/model/patchUserByID200TeamsItemMembershipStatus.ts +5 -5
- package/src/generated/model/patchUserByID400.ts +1 -1
- package/src/generated/model/patchUserByID401.ts +1 -1
- package/src/generated/model/patchUserByID403.ts +1 -1
- package/src/generated/model/patchUserByID404.ts +1 -1
- package/src/generated/model/patchUserByID409.ts +1 -1
- package/src/generated/model/patchUserByIDBody.ts +8 -8
- package/src/generated/model/patchUserByIDDefault.ts +82 -91
- package/src/generated/model/queryGrants200.ts +5 -5
- package/src/generated/model/queryGrants200GrantsItem.ts +17 -17
- package/src/generated/model/queryGrants200GrantsItemObjectType.ts +3 -3
- package/src/generated/model/queryGrants200GrantsItemRelation.ts +5 -5
- package/src/generated/model/queryGrants200GrantsItemTeam.ts +6 -6
- package/src/generated/model/queryGrants200GrantsItemTeamStatus.ts +4 -4
- package/src/generated/model/queryGrants200GrantsItemUser.ts +22 -22
- package/src/generated/model/queryGrants200GrantsItemUserMetadata.ts +25 -25
- package/src/generated/model/queryGrants200GrantsItemUserMetadataLifecycleOwnerTeam.ts +6 -6
- package/src/generated/model/queryGrants200GrantsItemUserMetadataLifecycleOwnerTeamStatus.ts +4 -4
- package/src/generated/model/queryGrants200GrantsItemUserMetadataStatus.ts +6 -6
- package/src/generated/model/queryGrants400.ts +1 -1
- package/src/generated/model/queryGrants401.ts +1 -1
- package/src/generated/model/queryGrants403.ts +1 -1
- package/src/generated/model/queryGrantsBody.ts +14 -14
- package/src/generated/model/queryGrantsBodyExpandItem.ts +3 -3
- package/src/generated/model/queryGrantsBodyFilterItem.ts +20 -20
- package/src/generated/model/queryGrantsBodyFilterItemField.ts +7 -7
- package/src/generated/model/queryGrantsBodyFilterItemOperation.ts +10 -10
- package/src/generated/model/queryGrantsBodySorting.ts +5 -5
- package/src/generated/model/queryGrantsBodySortingDirection.ts +4 -4
- package/src/generated/model/queryGrantsBodySortingField.ts +5 -5
- package/src/generated/model/queryGrantsDefault.ts +91 -91
- package/src/generated/model/queryGrantsParams.ts +5 -5
- package/src/generated/model/queryIdps200.ts +5 -5
- package/src/generated/model/queryIdps200IdpsItem.ts +14 -14
- package/src/generated/model/queryIdps200IdpsItemDefinition.ts +17 -17
- package/src/generated/model/queryIdps200IdpsItemDefinitionClaimMapping.ts +1 -1
- package/src/generated/model/queryIdps200IdpsItemDefinitionOauth2.ts +22 -22
- package/src/generated/model/queryIdps200IdpsItemDefinitionOauth2StaticAuthorizeParameters.ts +1 -3
- package/src/generated/model/queryIdps200IdpsItemDefinitionOauth2SupplementaryFetch.ts +3 -3
- package/src/generated/model/queryIdps200IdpsItemDefinitionOauth2TokenEndpointAuthMethod.ts +4 -4
- package/src/generated/model/queryIdps200IdpsItemDefinitionOidc.ts +28 -28
- package/src/generated/model/queryIdps200IdpsItemDefinitionOidcStaticAuthorizeParameters.ts +1 -1
- package/src/generated/model/queryIdps200IdpsItemDefinitionOidcTokenEndpointAuthMethod.ts +4 -4
- package/src/generated/model/queryIdps200IdpsItemDefinitionProtocol.ts +4 -4
- package/src/generated/model/queryIdps200IdpsItemDefinitionProvisioning.ts +1 -1
- package/src/generated/model/queryIdps200IdpsItemDefinitionProvisioningCreation.ts +4 -4
- package/src/generated/model/queryIdps200IdpsItemDefinitionVerifiedClaims.ts +1 -1
- package/src/generated/model/queryIdps400.ts +1 -1
- package/src/generated/model/queryIdps401.ts +1 -1
- package/src/generated/model/queryIdps403.ts +1 -1
- package/src/generated/model/queryIdps404.ts +1 -1
- package/src/generated/model/queryIdpsBody.ts +9 -9
- package/src/generated/model/queryIdpsBodyFilterItem.ts +18 -18
- package/src/generated/model/queryIdpsBodyFilterItemField.ts +4 -4
- package/src/generated/model/queryIdpsBodyFilterItemOperation.ts +10 -10
- package/src/generated/model/queryIdpsBodySorting.ts +7 -7
- package/src/generated/model/queryIdpsBodySortingDirection.ts +4 -4
- package/src/generated/model/queryIdpsBodySortingField.ts +4 -4
- package/src/generated/model/queryIdpsDefault.ts +55 -61
- package/src/generated/model/queryIdpsParams.ts +5 -5
- package/src/generated/model/queryProjects200.ts +5 -5
- package/src/generated/model/queryProjects200ProjectsItem.ts +4 -4
- package/src/generated/model/queryProjects200ProjectsItemPasswordHash.ts +24 -24
- package/src/generated/model/queryProjects200ProjectsItemPasswordHashAlgorithm.ts +8 -8
- package/src/generated/model/queryProjects200ProjectsItemPasswordHashParams.ts +6 -6
- package/src/generated/model/queryProjects200ProjectsItemPasswordHashParamsHash.ts +7 -7
- package/src/generated/model/queryProjects400.ts +1 -1
- package/src/generated/model/queryProjects401.ts +1 -1
- package/src/generated/model/queryProjects403.ts +1 -1
- package/src/generated/model/queryProjects429.ts +1 -1
- package/src/generated/model/queryProjectsBody.ts +9 -9
- package/src/generated/model/queryProjectsBodyFilterItem.ts +13 -13
- package/src/generated/model/queryProjectsBodyFilterItemField.ts +3 -3
- package/src/generated/model/queryProjectsBodyFilterItemOperation.ts +10 -10
- package/src/generated/model/queryProjectsBodySorting.ts +2 -2
- package/src/generated/model/queryProjectsBodySortingDirection.ts +4 -4
- package/src/generated/model/queryProjectsBodySortingField.ts +3 -3
- package/src/generated/model/queryProjectsDefault.ts +64 -71
- package/src/generated/model/querySessions200.ts +4 -4
- package/src/generated/model/querySessions200SessionsItem.ts +36 -36
- package/src/generated/model/querySessions200SessionsItemFactorsItem.ts +8 -7
- package/src/generated/model/querySessions200SessionsItemFactorsItemMethod.ts +6 -5
- package/src/generated/model/querySessions200SessionsItemFactorsItemPayload.ts +23 -25
- package/src/generated/model/querySessions200SessionsItemState.ts +5 -5
- package/src/generated/model/querySessions200SessionsItemUser.ts +14 -14
- package/src/generated/model/querySessions200SessionsItemUserAgent.ts +1 -1
- package/src/generated/model/querySessions400.ts +1 -1
- package/src/generated/model/querySessions401.ts +1 -1
- package/src/generated/model/querySessions403.ts +1 -1
- package/src/generated/model/querySessionsBody.ts +5 -5
- package/src/generated/model/querySessionsBodyFilterItem.ts +27 -27
- package/src/generated/model/querySessionsBodyFilterItemField.ts +6 -6
- package/src/generated/model/querySessionsBodyFilterItemOperation.ts +10 -10
- package/src/generated/model/querySessionsBodySorting.ts +6 -6
- package/src/generated/model/querySessionsBodySortingDirection.ts +4 -4
- package/src/generated/model/querySessionsBodySortingField.ts +4 -4
- package/src/generated/model/querySessionsDefault.ts +64 -71
- package/src/generated/model/querySessionsParams.ts +5 -5
- package/src/generated/model/queryTeams200.ts +5 -5
- package/src/generated/model/queryTeams200TeamsItem.ts +6 -6
- package/src/generated/model/queryTeams200TeamsItemStatus.ts +4 -4
- package/src/generated/model/queryTeams400.ts +1 -1
- package/src/generated/model/queryTeams401.ts +1 -1
- package/src/generated/model/queryTeams403.ts +1 -1
- package/src/generated/model/queryTeams404.ts +1 -1
- package/src/generated/model/queryTeams429.ts +1 -1
- package/src/generated/model/queryTeamsBody.ts +9 -9
- package/src/generated/model/queryTeamsBodyFilterItem.ts +18 -18
- package/src/generated/model/queryTeamsBodyFilterItemField.ts +5 -5
- package/src/generated/model/queryTeamsBodyFilterItemOperation.ts +10 -10
- package/src/generated/model/queryTeamsBodySorting.ts +7 -7
- package/src/generated/model/queryTeamsBodySortingDirection.ts +4 -4
- package/src/generated/model/queryTeamsBodySortingField.ts +5 -5
- package/src/generated/model/queryTeamsDefault.ts +1 -1
- package/src/generated/model/queryTeamsParams.ts +5 -5
- package/src/generated/model/queryUsers200.ts +4 -4
- package/src/generated/model/queryUsers200UsersItem.ts +37 -37
- package/src/generated/model/queryUsers200UsersItemMetadata.ts +25 -25
- package/src/generated/model/queryUsers200UsersItemMetadataLifecycleOwnerTeam.ts +6 -6
- package/src/generated/model/queryUsers200UsersItemMetadataLifecycleOwnerTeamStatus.ts +4 -4
- package/src/generated/model/queryUsers200UsersItemMetadataStatus.ts +6 -6
- package/src/generated/model/queryUsers200UsersItemTeamsItem.ts +4 -4
- package/src/generated/model/queryUsers200UsersItemTeamsItemMembershipStatus.ts +5 -5
- package/src/generated/model/queryUsers400.ts +1 -1
- package/src/generated/model/queryUsers401.ts +1 -1
- package/src/generated/model/queryUsers403.ts +1 -1
- package/src/generated/model/queryUsersBody.ts +13 -13
- package/src/generated/model/queryUsersBodyExpandItem.ts +8 -6
- package/src/generated/model/queryUsersBodyFilterItem.ts +43 -42
- package/src/generated/model/queryUsersBodyFilterItemField.ts +11 -10
- package/src/generated/model/queryUsersBodyFilterItemOperation.ts +10 -10
- package/src/generated/model/queryUsersBodySorting.ts +9 -9
- package/src/generated/model/queryUsersBodySortingDirection.ts +4 -4
- package/src/generated/model/queryUsersBodySortingField.ts +7 -7
- package/src/generated/model/queryUsersDefault.ts +64 -61
- package/src/generated/model/queryUsersParams.ts +6 -6
- package/src/generated/model/revokeMySession401.ts +1 -1
- package/src/generated/model/revokeMySessionDefault.ts +55 -51
- package/src/generated/model/revokeSession401.ts +1 -1
- package/src/generated/model/revokeSession403.ts +1 -1
- package/src/generated/model/revokeSessionDefault.ts +55 -61
- package/src/generated/model/setUserPassword400.ts +1 -1
- package/src/generated/model/setUserPassword404.ts +1 -1
- package/src/generated/model/setUserPassword500.ts +1 -1
- package/src/generated/model/setUserPasswordBody.ts +0 -5
- package/src/generated/model/setUserPasswordDefault.ts +82 -71
- package/src/generated/model/submitFlowStep200.ts +28 -28
- package/src/generated/model/submitFlowStep200Branding.ts +43 -43
- package/src/generated/model/submitFlowStep200BrandingLayout.ts +4 -4
- package/src/generated/model/submitFlowStep200BrandingShape.ts +12 -12
- package/src/generated/model/submitFlowStep200BrandingShapeDensity.ts +5 -5
- package/src/generated/model/submitFlowStep200BrandingTheme.ts +15 -15
- package/src/generated/model/submitFlowStep200BrandingThemeDark.ts +13 -13
- package/src/generated/model/submitFlowStep200BrandingThemeDarkPalette.ts +168 -168
- package/src/generated/model/submitFlowStep200BrandingThemeLight.ts +13 -13
- package/src/generated/model/submitFlowStep200BrandingThemeLightPalette.ts +168 -168
- package/src/generated/model/submitFlowStep200BrandingThemeMode.ts +5 -5
- package/src/generated/model/submitFlowStep200BrandingTypography.ts +27 -27
- package/src/generated/model/submitFlowStep200Step.ts +79 -45
- package/src/generated/model/submitFlowStep200StepActionsItem.ts +18 -18
- package/src/generated/model/submitFlowStep200StepActionsItemKind.ts +7 -7
- package/src/generated/model/submitFlowStep200StepChallenge.ts +10 -10
- package/src/generated/model/submitFlowStep200StepChallengeMethod.ts +4 -4
- package/src/generated/model/submitFlowStep200StepComplete.ts +4 -4
- package/src/generated/model/submitFlowStep200StepFieldsItem.ts +48 -23
- package/src/generated/model/submitFlowStep200StepFieldsItemType.ts +12 -12
- package/src/generated/model/submitFlowStep200StepFieldsItemValidation.ts +18 -18
- package/src/generated/model/submitFlowStep200StepFieldsItemValidationFormat.ts +6 -6
- package/src/generated/model/submitFlowStep200StepGates.ts +10 -12
- package/src/generated/model/submitFlowStep200StepGatesKind.ts +3 -3
- package/src/generated/model/submitFlowStep200StepIdentifier.ts +53 -0
- package/src/generated/model/submitFlowStep400.ts +28 -28
- package/src/generated/model/submitFlowStep400Branding.ts +43 -43
- package/src/generated/model/submitFlowStep400BrandingLayout.ts +4 -4
- package/src/generated/model/submitFlowStep400BrandingShape.ts +12 -12
- package/src/generated/model/submitFlowStep400BrandingShapeDensity.ts +5 -5
- package/src/generated/model/submitFlowStep400BrandingTheme.ts +15 -15
- package/src/generated/model/submitFlowStep400BrandingThemeDark.ts +13 -13
- package/src/generated/model/submitFlowStep400BrandingThemeDarkPalette.ts +168 -168
- package/src/generated/model/submitFlowStep400BrandingThemeLight.ts +13 -13
- package/src/generated/model/submitFlowStep400BrandingThemeLightPalette.ts +168 -168
- package/src/generated/model/submitFlowStep400BrandingThemeMode.ts +5 -5
- package/src/generated/model/submitFlowStep400BrandingTypography.ts +27 -27
- package/src/generated/model/submitFlowStep400Step.ts +79 -45
- package/src/generated/model/submitFlowStep400StepActionsItem.ts +18 -18
- package/src/generated/model/submitFlowStep400StepActionsItemKind.ts +7 -7
- package/src/generated/model/submitFlowStep400StepChallenge.ts +10 -10
- package/src/generated/model/submitFlowStep400StepChallengeMethod.ts +4 -4
- package/src/generated/model/submitFlowStep400StepComplete.ts +4 -4
- package/src/generated/model/submitFlowStep400StepFieldsItem.ts +48 -23
- package/src/generated/model/submitFlowStep400StepFieldsItemType.ts +12 -12
- package/src/generated/model/submitFlowStep400StepFieldsItemValidation.ts +18 -18
- package/src/generated/model/submitFlowStep400StepFieldsItemValidationFormat.ts +6 -6
- package/src/generated/model/submitFlowStep400StepGates.ts +10 -12
- package/src/generated/model/submitFlowStep400StepGatesKind.ts +3 -3
- package/src/generated/model/submitFlowStep400StepIdentifier.ts +53 -0
- package/src/generated/model/submitFlowStep409.ts +1 -1
- package/src/generated/model/submitFlowStepBody.ts +29 -17
- package/src/generated/model/submitFlowStepBodyChallengeResponse.ts +7 -7
- package/src/generated/model/submitFlowStepBodyGateProofs.ts +1 -1
- package/src/generated/model/submitFlowStepDefault.ts +262 -261
- package/src/generated/model/updateTeam200.ts +6 -6
- package/src/generated/model/updateTeam200Status.ts +4 -3
- package/src/generated/model/updateTeam400.ts +1 -1
- package/src/generated/model/updateTeam401.ts +1 -1
- package/src/generated/model/updateTeam403.ts +1 -1
- package/src/generated/model/updateTeam404.ts +1 -1
- package/src/generated/model/updateTeam409.ts +1 -1
- package/src/generated/model/updateTeamBody.ts +4 -4
- package/src/generated/model/updateTeamDefault.ts +1 -1
- package/src/generated/model/updateVariables200.ts +4 -10
- package/src/generated/model/updateVariablesBody.ts +20 -27
- package/src/generated/model/updateVariablesDefault.ts +118 -131
- package/src/generated/model/updateVariablesParams.ts +15 -15
- package/src/generated/model/verifyChallengeProof200.ts +35 -35
- package/src/generated/model/verifyChallengeProof200ChallengesItem.ts +20 -17
- package/src/generated/model/verifyChallengeProof200ChallengesItemMethod.ts +7 -6
- package/src/generated/model/verifyChallengeProof200ChallengesItemPayload.ts +20 -22
- package/src/generated/model/verifyChallengeProof200ChallengesItemState.ts +5 -5
- package/src/generated/model/verifyChallengeProof200CompletedFactorsItem.ts +8 -7
- package/src/generated/model/verifyChallengeProof200CompletedFactorsItemMethod.ts +6 -5
- package/src/generated/model/verifyChallengeProof200CompletedFactorsItemPayload.ts +23 -25
- package/src/generated/model/verifyChallengeProof200RequiredFactorsItem.ts +6 -5
- package/src/generated/model/verifyChallengeProof200State.ts +6 -6
- package/src/generated/model/verifyChallengeProofBody.ts +13 -16
- package/src/generated/model/verifyChallengeProofDefault.ts +145 -141
- package/src/runtime/api-factory.ts +13 -0
- package/src/runtime/auth.ts +95 -0
- package/src/runtime/config.spec.ts +5 -7
- package/src/runtime/fetch.spec.ts +358 -0
- package/src/runtime/fetch.ts +192 -6
- package/dist/fetch-DEQBdRAE.d.mts +0 -44
- package/dist/fetch-DEQBdRAE.d.mts.map +0 -1
- package/dist/index-DCCtHY7q.d.mts.map +0 -1
- package/dist/zitadelNextGen-NzRGHVHl.d.mts.map +0 -1
- /package/dist/{chunk-CfYAbeIz.mjs → rolldown-runtime-D7D4PA-g.mjs} +0 -0
|
@@ -5,8 +5,10 @@
|
|
|
5
5
|
* This is the next generation of the Zitadel identity platform.
|
|
6
6
|
* OpenAPI spec version: 0.0.1
|
|
7
7
|
*/
|
|
8
|
-
import {
|
|
9
|
-
|
|
8
|
+
import {
|
|
9
|
+
getProxyPath
|
|
10
|
+
} from '../../runtime/base-url';
|
|
11
|
+
|
|
10
12
|
import type {
|
|
11
13
|
BeginUserPasskeyRegistration201,
|
|
12
14
|
BeginUserPasskeyRegistrationBody,
|
|
@@ -80,6 +82,7 @@ import type {
|
|
|
80
82
|
GetIdpRevisionByIdParams,
|
|
81
83
|
GetLiveDefault,
|
|
82
84
|
GetMySession200,
|
|
85
|
+
GetMySessionCsrfToken200,
|
|
83
86
|
GetMyUser200,
|
|
84
87
|
GetProject200,
|
|
85
88
|
GetReadyDefault,
|
|
@@ -152,95 +155,113 @@ import type {
|
|
|
152
155
|
UpdateVariablesBody,
|
|
153
156
|
UpdateVariablesParams,
|
|
154
157
|
VerifyChallengeProof200,
|
|
155
|
-
VerifyChallengeProofBody
|
|
156
|
-
} from
|
|
158
|
+
VerifyChallengeProofBody
|
|
159
|
+
} from '../model';
|
|
160
|
+
|
|
161
|
+
import { customFetch } from '../../runtime/fetch';
|
|
157
162
|
|
|
158
163
|
export const getGetHealthUrl = () => {
|
|
159
|
-
|
|
160
|
-
|
|
164
|
+
|
|
165
|
+
|
|
166
|
+
|
|
167
|
+
|
|
168
|
+
return `${getProxyPath()}/healthz`
|
|
169
|
+
}
|
|
161
170
|
|
|
162
171
|
/**
|
|
163
172
|
* Check whether the server is healthy
|
|
164
173
|
* @summary Check server health
|
|
165
174
|
*/
|
|
166
|
-
export const getHealth = async (
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
175
|
+
export const getHealth = async ( options?: Parameters<typeof customFetch>[1]): Promise<GetHealthDefault> => {
|
|
176
|
+
|
|
177
|
+
return customFetch<GetHealthDefault>(getGetHealthUrl(),
|
|
178
|
+
{
|
|
170
179
|
...options,
|
|
171
|
-
method:
|
|
172
|
-
|
|
173
|
-
|
|
180
|
+
method: 'GET'
|
|
181
|
+
|
|
182
|
+
|
|
183
|
+
}
|
|
184
|
+
);}
|
|
185
|
+
|
|
186
|
+
|
|
174
187
|
|
|
175
188
|
export const getGetLiveUrl = () => {
|
|
176
|
-
|
|
177
|
-
|
|
189
|
+
|
|
190
|
+
|
|
191
|
+
|
|
192
|
+
|
|
193
|
+
return `${getProxyPath()}/livez`
|
|
194
|
+
}
|
|
178
195
|
|
|
179
196
|
/**
|
|
180
197
|
* Check whether the server is started
|
|
181
198
|
* @summary Check server liveness
|
|
182
199
|
*/
|
|
183
|
-
export const getLive = async (
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
200
|
+
export const getLive = async ( options?: Parameters<typeof customFetch>[1]): Promise<GetLiveDefault> => {
|
|
201
|
+
|
|
202
|
+
return customFetch<GetLiveDefault>(getGetLiveUrl(),
|
|
203
|
+
{
|
|
187
204
|
...options,
|
|
188
|
-
method:
|
|
189
|
-
|
|
190
|
-
|
|
205
|
+
method: 'GET'
|
|
206
|
+
|
|
207
|
+
|
|
208
|
+
}
|
|
209
|
+
);}
|
|
210
|
+
|
|
211
|
+
|
|
191
212
|
|
|
192
213
|
export const getGetReadyUrl = () => {
|
|
193
|
-
|
|
194
|
-
|
|
214
|
+
|
|
215
|
+
|
|
216
|
+
|
|
217
|
+
|
|
218
|
+
return `${getProxyPath()}/readyz`
|
|
219
|
+
}
|
|
195
220
|
|
|
196
221
|
/**
|
|
197
222
|
* Check whether the server is ready to accept requests
|
|
198
223
|
* @summary Check server readiness
|
|
199
224
|
*/
|
|
200
|
-
export const getReady = async (
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
225
|
+
export const getReady = async ( options?: Parameters<typeof customFetch>[1]): Promise<GetReadyDefault> => {
|
|
226
|
+
|
|
227
|
+
return customFetch<GetReadyDefault>(getGetReadyUrl(),
|
|
228
|
+
{
|
|
204
229
|
...options,
|
|
205
|
-
method:
|
|
206
|
-
|
|
207
|
-
|
|
230
|
+
method: 'GET'
|
|
231
|
+
|
|
232
|
+
|
|
233
|
+
}
|
|
234
|
+
);}
|
|
235
|
+
|
|
236
|
+
|
|
208
237
|
|
|
209
|
-
export const getCreateUserUrl = (params: CreateUserParams) => {
|
|
238
|
+
export const getCreateUserUrl = (params: CreateUserParams,) => {
|
|
210
239
|
const normalizedParams = new URLSearchParams();
|
|
211
240
|
|
|
212
241
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
242
|
+
|
|
213
243
|
if (value !== undefined) {
|
|
214
|
-
normalizedParams.append(key, value === null ?
|
|
244
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
215
245
|
}
|
|
216
246
|
});
|
|
217
247
|
|
|
218
248
|
const stringifiedParams = normalizedParams.toString();
|
|
219
249
|
|
|
220
|
-
return stringifiedParams.length > 0
|
|
221
|
-
|
|
222
|
-
: `${getProxyPath()}/users`;
|
|
223
|
-
};
|
|
250
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/users?${stringifiedParams}` : `${getProxyPath()}/users`
|
|
251
|
+
}
|
|
224
252
|
|
|
225
253
|
/**
|
|
226
254
|
* @summary Create user
|
|
227
255
|
*/
|
|
228
|
-
export const createUser = async (
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
): Promise<CreateUser201> => {
|
|
233
|
-
const getHeaders = (
|
|
234
|
-
h?: NonNullable<RequestInit["headers"]>,
|
|
235
|
-
): Record<string, string | readonly string[]> => {
|
|
256
|
+
export const createUser = async (createUserBody: CreateUserBody,
|
|
257
|
+
params: CreateUserParams, options?: Parameters<typeof customFetch>[1]): Promise<CreateUser201> => {
|
|
258
|
+
|
|
259
|
+
const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {
|
|
236
260
|
if (!h) return {};
|
|
237
261
|
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
238
262
|
if (Symbol.iterator in h) {
|
|
239
263
|
return Object.fromEntries(
|
|
240
|
-
Array.from(
|
|
241
|
-
h as Iterable<Iterable<string>>,
|
|
242
|
-
(entry) => Array.from(entry) as [string, string],
|
|
243
|
-
),
|
|
264
|
+
Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),
|
|
244
265
|
);
|
|
245
266
|
}
|
|
246
267
|
const headers: Record<string, string | readonly string[]> = {};
|
|
@@ -249,29 +270,31 @@ export const createUser = async (
|
|
|
249
270
|
}
|
|
250
271
|
return headers;
|
|
251
272
|
};
|
|
252
|
-
|
|
273
|
+
return customFetch<CreateUser201>(getCreateUserUrl(params),
|
|
274
|
+
{
|
|
253
275
|
...options,
|
|
254
|
-
method:
|
|
255
|
-
headers: {
|
|
256
|
-
body: JSON.stringify(createUserBody)
|
|
257
|
-
}
|
|
258
|
-
}
|
|
276
|
+
method: 'POST',
|
|
277
|
+
headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },
|
|
278
|
+
body: JSON.stringify(createUserBody)
|
|
279
|
+
}
|
|
280
|
+
);}
|
|
281
|
+
|
|
282
|
+
|
|
259
283
|
|
|
260
|
-
export const getQueryUsersUrl = (params?: QueryUsersParams) => {
|
|
284
|
+
export const getQueryUsersUrl = (params?: QueryUsersParams,) => {
|
|
261
285
|
const normalizedParams = new URLSearchParams();
|
|
262
286
|
|
|
263
287
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
288
|
+
|
|
264
289
|
if (value !== undefined) {
|
|
265
|
-
normalizedParams.append(key, value === null ?
|
|
290
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
266
291
|
}
|
|
267
292
|
});
|
|
268
293
|
|
|
269
294
|
const stringifiedParams = normalizedParams.toString();
|
|
270
295
|
|
|
271
|
-
return stringifiedParams.length > 0
|
|
272
|
-
|
|
273
|
-
: `${getProxyPath()}/users/query`;
|
|
274
|
-
};
|
|
296
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/users/query?${stringifiedParams}` : `${getProxyPath()}/users/query`
|
|
297
|
+
}
|
|
275
298
|
|
|
276
299
|
/**
|
|
277
300
|
* Returns the users of a project, paginated with a cursor.
|
|
@@ -280,26 +303,19 @@ export const getQueryUsersUrl = (params?: QueryUsersParams) => {
|
|
|
280
303
|
* project is listed.
|
|
281
304
|
*
|
|
282
305
|
* Accepts either a project secret (`oauth2`) or a user-bound Console
|
|
283
|
-
* session cookie (`nextgenSession`).
|
|
284
|
-
*
|
|
306
|
+
* session cookie (`nextgenSession`). Cookie-authenticated requests
|
|
307
|
+
* follow the scheme's CSRF rules (`nextgenSession`).
|
|
285
308
|
* @summary Query users
|
|
286
309
|
*/
|
|
287
|
-
export const queryUsers = async (
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
): Promise<QueryUsers200> => {
|
|
292
|
-
const getHeaders = (
|
|
293
|
-
h?: NonNullable<RequestInit["headers"]>,
|
|
294
|
-
): Record<string, string | readonly string[]> => {
|
|
310
|
+
export const queryUsers = async (queryUsersBody: QueryUsersBody,
|
|
311
|
+
params?: QueryUsersParams, options?: Parameters<typeof customFetch>[1]): Promise<QueryUsers200> => {
|
|
312
|
+
|
|
313
|
+
const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {
|
|
295
314
|
if (!h) return {};
|
|
296
315
|
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
297
316
|
if (Symbol.iterator in h) {
|
|
298
317
|
return Object.fromEntries(
|
|
299
|
-
Array.from(
|
|
300
|
-
h as Iterable<Iterable<string>>,
|
|
301
|
-
(entry) => Array.from(entry) as [string, string],
|
|
302
|
-
),
|
|
318
|
+
Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),
|
|
303
319
|
);
|
|
304
320
|
}
|
|
305
321
|
const headers: Record<string, string | readonly string[]> = {};
|
|
@@ -308,47 +324,57 @@ export const queryUsers = async (
|
|
|
308
324
|
}
|
|
309
325
|
return headers;
|
|
310
326
|
};
|
|
311
|
-
|
|
327
|
+
return customFetch<QueryUsers200>(getQueryUsersUrl(params),
|
|
328
|
+
{
|
|
312
329
|
...options,
|
|
313
|
-
method:
|
|
314
|
-
headers: {
|
|
315
|
-
body: JSON.stringify(queryUsersBody)
|
|
316
|
-
}
|
|
317
|
-
}
|
|
330
|
+
method: 'POST',
|
|
331
|
+
headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },
|
|
332
|
+
body: JSON.stringify(queryUsersBody)
|
|
333
|
+
}
|
|
334
|
+
);}
|
|
335
|
+
|
|
336
|
+
|
|
318
337
|
|
|
319
|
-
export const getGetUserByIDUrl = (userId: string,
|
|
338
|
+
export const getGetUserByIDUrl = (userId: string,
|
|
339
|
+
params?: GetUserByIDParams,) => {
|
|
320
340
|
const normalizedParams = new URLSearchParams();
|
|
321
341
|
|
|
322
342
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
343
|
+
|
|
323
344
|
if (value !== undefined) {
|
|
324
|
-
normalizedParams.append(key, value === null ?
|
|
345
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
325
346
|
}
|
|
326
347
|
});
|
|
327
348
|
|
|
328
349
|
const stringifiedParams = normalizedParams.toString();
|
|
329
350
|
|
|
330
|
-
return stringifiedParams.length > 0
|
|
331
|
-
|
|
332
|
-
: `${getProxyPath()}/users/${encodeURIComponent(String(userId))}`;
|
|
333
|
-
};
|
|
351
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/users/${encodeURIComponent(String(userId))}?${stringifiedParams}` : `${getProxyPath()}/users/${encodeURIComponent(String(userId))}`
|
|
352
|
+
}
|
|
334
353
|
|
|
335
354
|
/**
|
|
336
355
|
* @summary Get user by ID
|
|
337
356
|
*/
|
|
338
|
-
export const getUserByID = async (
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
return customFetch<GetUserByID200>(getGetUserByIDUrl(userId, params), {
|
|
357
|
+
export const getUserByID = async (userId: string,
|
|
358
|
+
params?: GetUserByIDParams, options?: Parameters<typeof customFetch>[1]): Promise<GetUserByID200> => {
|
|
359
|
+
|
|
360
|
+
return customFetch<GetUserByID200>(getGetUserByIDUrl(userId,params),
|
|
361
|
+
{
|
|
344
362
|
...options,
|
|
345
|
-
method:
|
|
346
|
-
|
|
347
|
-
|
|
363
|
+
method: 'GET'
|
|
364
|
+
|
|
365
|
+
|
|
366
|
+
}
|
|
367
|
+
);}
|
|
368
|
+
|
|
369
|
+
|
|
370
|
+
|
|
371
|
+
export const getPatchUserByIDUrl = (userId: string,) => {
|
|
372
|
+
|
|
373
|
+
|
|
374
|
+
|
|
348
375
|
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
};
|
|
376
|
+
return `${getProxyPath()}/users/${encodeURIComponent(String(userId))}`
|
|
377
|
+
}
|
|
352
378
|
|
|
353
379
|
/**
|
|
354
380
|
* Partially updates a user's schema-defined attributes, and optionally
|
|
@@ -357,22 +383,15 @@ export const getPatchUserByIDUrl = (userId: string) => {
|
|
|
357
383
|
* last-write-wins.
|
|
358
384
|
* @summary Update user by ID
|
|
359
385
|
*/
|
|
360
|
-
export const patchUserByID = async (
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
): Promise<PatchUserByID200> => {
|
|
365
|
-
const getHeaders = (
|
|
366
|
-
h?: NonNullable<RequestInit["headers"]>,
|
|
367
|
-
): Record<string, string | readonly string[]> => {
|
|
386
|
+
export const patchUserByID = async (userId: string,
|
|
387
|
+
patchUserByIDBody: PatchUserByIDBody, options?: Parameters<typeof customFetch>[1]): Promise<PatchUserByID200> => {
|
|
388
|
+
|
|
389
|
+
const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {
|
|
368
390
|
if (!h) return {};
|
|
369
391
|
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
370
392
|
if (Symbol.iterator in h) {
|
|
371
393
|
return Object.fromEntries(
|
|
372
|
-
Array.from(
|
|
373
|
-
h as Iterable<Iterable<string>>,
|
|
374
|
-
(entry) => Array.from(entry) as [string, string],
|
|
375
|
-
),
|
|
394
|
+
Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),
|
|
376
395
|
);
|
|
377
396
|
}
|
|
378
397
|
const headers: Record<string, string | readonly string[]> = {};
|
|
@@ -381,64 +400,81 @@ export const patchUserByID = async (
|
|
|
381
400
|
}
|
|
382
401
|
return headers;
|
|
383
402
|
};
|
|
384
|
-
|
|
403
|
+
return customFetch<PatchUserByID200>(getPatchUserByIDUrl(userId),
|
|
404
|
+
{
|
|
385
405
|
...options,
|
|
386
|
-
method:
|
|
387
|
-
headers: {
|
|
388
|
-
body: JSON.stringify(patchUserByIDBody)
|
|
389
|
-
}
|
|
390
|
-
}
|
|
406
|
+
method: 'PATCH',
|
|
407
|
+
headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },
|
|
408
|
+
body: JSON.stringify(patchUserByIDBody)
|
|
409
|
+
}
|
|
410
|
+
);}
|
|
411
|
+
|
|
412
|
+
|
|
413
|
+
|
|
414
|
+
export const getDeleteUserByIDUrl = (userId: string,) => {
|
|
391
415
|
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
416
|
+
|
|
417
|
+
|
|
418
|
+
|
|
419
|
+
return `${getProxyPath()}/users/${encodeURIComponent(String(userId))}`
|
|
420
|
+
}
|
|
395
421
|
|
|
396
422
|
/**
|
|
397
423
|
* @summary Delete user by ID
|
|
398
424
|
*/
|
|
399
|
-
export const deleteUserByID = async (
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
return customFetch<void>(getDeleteUserByIDUrl(userId), {
|
|
425
|
+
export const deleteUserByID = async (userId: string, options?: Parameters<typeof customFetch>[1]): Promise<void> => {
|
|
426
|
+
|
|
427
|
+
return customFetch<void>(getDeleteUserByIDUrl(userId),
|
|
428
|
+
{
|
|
404
429
|
...options,
|
|
405
|
-
method:
|
|
406
|
-
});
|
|
407
|
-
};
|
|
430
|
+
method: 'DELETE'
|
|
408
431
|
|
|
409
|
-
|
|
432
|
+
|
|
433
|
+
}
|
|
434
|
+
);}
|
|
435
|
+
|
|
436
|
+
|
|
437
|
+
|
|
438
|
+
export const getListUserPasskeysUrl = (userId: string,
|
|
439
|
+
params?: ListUserPasskeysParams,) => {
|
|
410
440
|
const normalizedParams = new URLSearchParams();
|
|
411
441
|
|
|
412
442
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
443
|
+
|
|
413
444
|
if (value !== undefined) {
|
|
414
|
-
normalizedParams.append(key, value === null ?
|
|
445
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
415
446
|
}
|
|
416
447
|
});
|
|
417
448
|
|
|
418
449
|
const stringifiedParams = normalizedParams.toString();
|
|
419
450
|
|
|
420
|
-
return stringifiedParams.length > 0
|
|
421
|
-
|
|
422
|
-
: `${getProxyPath()}/users/${encodeURIComponent(String(userId))}/passkeys`;
|
|
423
|
-
};
|
|
451
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/users/${encodeURIComponent(String(userId))}/passkeys?${stringifiedParams}` : `${getProxyPath()}/users/${encodeURIComponent(String(userId))}/passkeys`
|
|
452
|
+
}
|
|
424
453
|
|
|
425
454
|
/**
|
|
426
455
|
* @summary List user passkeys
|
|
427
456
|
*/
|
|
428
|
-
export const listUserPasskeys = async (
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
return customFetch<ListUserPasskeys200>(getListUserPasskeysUrl(userId, params), {
|
|
457
|
+
export const listUserPasskeys = async (userId: string,
|
|
458
|
+
params?: ListUserPasskeysParams, options?: Parameters<typeof customFetch>[1]): Promise<ListUserPasskeys200> => {
|
|
459
|
+
|
|
460
|
+
return customFetch<ListUserPasskeys200>(getListUserPasskeysUrl(userId,params),
|
|
461
|
+
{
|
|
434
462
|
...options,
|
|
435
|
-
method:
|
|
436
|
-
|
|
437
|
-
|
|
463
|
+
method: 'GET'
|
|
464
|
+
|
|
465
|
+
|
|
466
|
+
}
|
|
467
|
+
);}
|
|
468
|
+
|
|
438
469
|
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
470
|
+
|
|
471
|
+
export const getBeginUserPasskeyRegistrationUrl = (userId: string,) => {
|
|
472
|
+
|
|
473
|
+
|
|
474
|
+
|
|
475
|
+
|
|
476
|
+
return `${getProxyPath()}/users/${encodeURIComponent(String(userId))}/passkeys/registrations`
|
|
477
|
+
}
|
|
442
478
|
|
|
443
479
|
/**
|
|
444
480
|
* Starts a WebAuthn registration ceremony for the user and returns the
|
|
@@ -448,22 +484,15 @@ export const getBeginUserPasskeyRegistrationUrl = (userId: string) => {
|
|
|
448
484
|
* automatically.
|
|
449
485
|
* @summary Begin passkey registration
|
|
450
486
|
*/
|
|
451
|
-
export const beginUserPasskeyRegistration = async (
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
): Promise<BeginUserPasskeyRegistration201> => {
|
|
456
|
-
const getHeaders = (
|
|
457
|
-
h?: NonNullable<RequestInit["headers"]>,
|
|
458
|
-
): Record<string, string | readonly string[]> => {
|
|
487
|
+
export const beginUserPasskeyRegistration = async (userId: string,
|
|
488
|
+
beginUserPasskeyRegistrationBody: BeginUserPasskeyRegistrationBody, options?: Parameters<typeof customFetch>[1]): Promise<BeginUserPasskeyRegistration201> => {
|
|
489
|
+
|
|
490
|
+
const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {
|
|
459
491
|
if (!h) return {};
|
|
460
492
|
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
461
493
|
if (Symbol.iterator in h) {
|
|
462
494
|
return Object.fromEntries(
|
|
463
|
-
Array.from(
|
|
464
|
-
h as Iterable<Iterable<string>>,
|
|
465
|
-
(entry) => Array.from(entry) as [string, string],
|
|
466
|
-
),
|
|
495
|
+
Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),
|
|
467
496
|
);
|
|
468
497
|
}
|
|
469
498
|
const headers: Record<string, string | readonly string[]> = {};
|
|
@@ -472,17 +501,25 @@ export const beginUserPasskeyRegistration = async (
|
|
|
472
501
|
}
|
|
473
502
|
return headers;
|
|
474
503
|
};
|
|
475
|
-
|
|
504
|
+
return customFetch<BeginUserPasskeyRegistration201>(getBeginUserPasskeyRegistrationUrl(userId),
|
|
505
|
+
{
|
|
476
506
|
...options,
|
|
477
|
-
method:
|
|
478
|
-
headers: {
|
|
479
|
-
body: JSON.stringify(beginUserPasskeyRegistrationBody)
|
|
480
|
-
}
|
|
481
|
-
}
|
|
507
|
+
method: 'POST',
|
|
508
|
+
headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },
|
|
509
|
+
body: JSON.stringify(beginUserPasskeyRegistrationBody)
|
|
510
|
+
}
|
|
511
|
+
);}
|
|
512
|
+
|
|
513
|
+
|
|
514
|
+
|
|
515
|
+
export const getFinishUserPasskeyRegistrationUrl = (userId: string,
|
|
516
|
+
registrationId: string,) => {
|
|
482
517
|
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
518
|
+
|
|
519
|
+
|
|
520
|
+
|
|
521
|
+
return `${getProxyPath()}/users/${encodeURIComponent(String(userId))}/passkeys/registrations/${encodeURIComponent(String(registrationId))}`
|
|
522
|
+
}
|
|
486
523
|
|
|
487
524
|
/**
|
|
488
525
|
* Verifies the attestation against the ceremony started by
|
|
@@ -493,23 +530,16 @@ export const getFinishUserPasskeyRegistrationUrl = (userId: string, registration
|
|
|
493
530
|
* surfaces as `att.not_found`.
|
|
494
531
|
* @summary Finish passkey registration
|
|
495
532
|
*/
|
|
496
|
-
export const finishUserPasskeyRegistration = async (
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
): Promise<FinishUserPasskeyRegistration201> => {
|
|
502
|
-
const getHeaders = (
|
|
503
|
-
h?: NonNullable<RequestInit["headers"]>,
|
|
504
|
-
): Record<string, string | readonly string[]> => {
|
|
533
|
+
export const finishUserPasskeyRegistration = async (userId: string,
|
|
534
|
+
registrationId: string,
|
|
535
|
+
finishUserPasskeyRegistrationBody: FinishUserPasskeyRegistrationBody, options?: Parameters<typeof customFetch>[1]): Promise<FinishUserPasskeyRegistration201> => {
|
|
536
|
+
|
|
537
|
+
const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {
|
|
505
538
|
if (!h) return {};
|
|
506
539
|
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
507
540
|
if (Symbol.iterator in h) {
|
|
508
541
|
return Object.fromEntries(
|
|
509
|
-
Array.from(
|
|
510
|
-
h as Iterable<Iterable<string>>,
|
|
511
|
-
(entry) => Array.from(entry) as [string, string],
|
|
512
|
-
),
|
|
542
|
+
Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),
|
|
513
543
|
);
|
|
514
544
|
}
|
|
515
545
|
const headers: Record<string, string | readonly string[]> = {};
|
|
@@ -518,40 +548,37 @@ export const finishUserPasskeyRegistration = async (
|
|
|
518
548
|
}
|
|
519
549
|
return headers;
|
|
520
550
|
};
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
|
|
532
|
-
export const getSetUserPasswordUrl = (userId: string) => {
|
|
533
|
-
|
|
534
|
-
|
|
551
|
+
return customFetch<FinishUserPasskeyRegistration201>(getFinishUserPasskeyRegistrationUrl(userId,registrationId),
|
|
552
|
+
{
|
|
553
|
+
...options,
|
|
554
|
+
method: 'POST',
|
|
555
|
+
headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },
|
|
556
|
+
body: JSON.stringify(finishUserPasskeyRegistrationBody)
|
|
557
|
+
}
|
|
558
|
+
);}
|
|
559
|
+
|
|
560
|
+
|
|
561
|
+
|
|
562
|
+
export const getSetUserPasswordUrl = (userId: string,) => {
|
|
563
|
+
|
|
564
|
+
|
|
565
|
+
|
|
566
|
+
|
|
567
|
+
return `${getProxyPath()}/users/${encodeURIComponent(String(userId))}/password`
|
|
568
|
+
}
|
|
535
569
|
|
|
536
570
|
/**
|
|
537
571
|
* @summary Set user password
|
|
538
572
|
*/
|
|
539
|
-
export const setUserPassword = async (
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
): Promise<void> => {
|
|
544
|
-
const getHeaders = (
|
|
545
|
-
h?: NonNullable<RequestInit["headers"]>,
|
|
546
|
-
): Record<string, string | readonly string[]> => {
|
|
573
|
+
export const setUserPassword = async (userId: string,
|
|
574
|
+
setUserPasswordBody: SetUserPasswordBody, options?: Parameters<typeof customFetch>[1]): Promise<void> => {
|
|
575
|
+
|
|
576
|
+
const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {
|
|
547
577
|
if (!h) return {};
|
|
548
578
|
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
549
579
|
if (Symbol.iterator in h) {
|
|
550
580
|
return Object.fromEntries(
|
|
551
|
-
Array.from(
|
|
552
|
-
h as Iterable<Iterable<string>>,
|
|
553
|
-
(entry) => Array.from(entry) as [string, string],
|
|
554
|
-
),
|
|
581
|
+
Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),
|
|
555
582
|
);
|
|
556
583
|
}
|
|
557
584
|
const headers: Record<string, string | readonly string[]> = {};
|
|
@@ -560,29 +587,32 @@ export const setUserPassword = async (
|
|
|
560
587
|
}
|
|
561
588
|
return headers;
|
|
562
589
|
};
|
|
563
|
-
|
|
590
|
+
return customFetch<void>(getSetUserPasswordUrl(userId),
|
|
591
|
+
{
|
|
564
592
|
...options,
|
|
565
|
-
method:
|
|
566
|
-
headers: {
|
|
567
|
-
body: JSON.stringify(setUserPasswordBody)
|
|
568
|
-
}
|
|
569
|
-
}
|
|
593
|
+
method: 'PUT',
|
|
594
|
+
headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },
|
|
595
|
+
body: JSON.stringify(setUserPasswordBody)
|
|
596
|
+
}
|
|
597
|
+
);}
|
|
598
|
+
|
|
599
|
+
|
|
570
600
|
|
|
571
|
-
export const getListUserTeamsUrl = (userId: string,
|
|
601
|
+
export const getListUserTeamsUrl = (userId: string,
|
|
602
|
+
params?: ListUserTeamsParams,) => {
|
|
572
603
|
const normalizedParams = new URLSearchParams();
|
|
573
604
|
|
|
574
605
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
606
|
+
|
|
575
607
|
if (value !== undefined) {
|
|
576
|
-
normalizedParams.append(key, value === null ?
|
|
608
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
577
609
|
}
|
|
578
610
|
});
|
|
579
611
|
|
|
580
612
|
const stringifiedParams = normalizedParams.toString();
|
|
581
613
|
|
|
582
|
-
return stringifiedParams.length > 0
|
|
583
|
-
|
|
584
|
-
: `${getProxyPath()}/users/${encodeURIComponent(String(userId))}/teams`;
|
|
585
|
-
};
|
|
614
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/users/${encodeURIComponent(String(userId))}/teams?${stringifiedParams}` : `${getProxyPath()}/users/${encodeURIComponent(String(userId))}/teams`
|
|
615
|
+
}
|
|
586
616
|
|
|
587
617
|
/**
|
|
588
618
|
* The user's team roster, ordered by team name. Each entry carries the
|
|
@@ -594,36 +624,51 @@ export const getListUserTeamsUrl = (userId: string, params?: ListUserTeamsParams
|
|
|
594
624
|
* returned.
|
|
595
625
|
* @summary List the teams a user belongs to
|
|
596
626
|
*/
|
|
597
|
-
export const listUserTeams = async (
|
|
598
|
-
|
|
599
|
-
|
|
600
|
-
|
|
601
|
-
|
|
602
|
-
return customFetch<ListUserTeams200>(getListUserTeamsUrl(userId, params), {
|
|
627
|
+
export const listUserTeams = async (userId: string,
|
|
628
|
+
params?: ListUserTeamsParams, options?: Parameters<typeof customFetch>[1]): Promise<ListUserTeams200> => {
|
|
629
|
+
|
|
630
|
+
return customFetch<ListUserTeams200>(getListUserTeamsUrl(userId,params),
|
|
631
|
+
{
|
|
603
632
|
...options,
|
|
604
|
-
method:
|
|
605
|
-
|
|
606
|
-
|
|
633
|
+
method: 'GET'
|
|
634
|
+
|
|
635
|
+
|
|
636
|
+
}
|
|
637
|
+
);}
|
|
638
|
+
|
|
639
|
+
|
|
607
640
|
|
|
608
641
|
export const getGetMyUserUrl = () => {
|
|
609
|
-
|
|
610
|
-
|
|
642
|
+
|
|
643
|
+
|
|
644
|
+
|
|
645
|
+
|
|
646
|
+
return `${getProxyPath()}/users/me`
|
|
647
|
+
}
|
|
611
648
|
|
|
612
649
|
/**
|
|
613
650
|
* @summary Get my user information
|
|
614
651
|
*/
|
|
615
|
-
export const getMyUser = async (
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
|
|
652
|
+
export const getMyUser = async ( options?: Parameters<typeof customFetch>[1]): Promise<GetMyUser200> => {
|
|
653
|
+
|
|
654
|
+
return customFetch<GetMyUser200>(getGetMyUserUrl(),
|
|
655
|
+
{
|
|
619
656
|
...options,
|
|
620
|
-
method:
|
|
621
|
-
|
|
622
|
-
|
|
657
|
+
method: 'GET'
|
|
658
|
+
|
|
659
|
+
|
|
660
|
+
}
|
|
661
|
+
);}
|
|
662
|
+
|
|
663
|
+
|
|
623
664
|
|
|
624
665
|
export const getPatchMyUserUrl = () => {
|
|
625
|
-
|
|
626
|
-
|
|
666
|
+
|
|
667
|
+
|
|
668
|
+
|
|
669
|
+
|
|
670
|
+
return `${getProxyPath()}/users/me`
|
|
671
|
+
}
|
|
627
672
|
|
|
628
673
|
/**
|
|
629
674
|
* Partially updates the caller's own schema-defined attributes. The merged
|
|
@@ -631,21 +676,14 @@ export const getPatchMyUserUrl = () => {
|
|
|
631
676
|
* writes are last-write-wins.
|
|
632
677
|
* @summary Update my user information
|
|
633
678
|
*/
|
|
634
|
-
export const patchMyUser = async (
|
|
635
|
-
|
|
636
|
-
|
|
637
|
-
): Promise<PatchMyUser200> => {
|
|
638
|
-
const getHeaders = (
|
|
639
|
-
h?: NonNullable<RequestInit["headers"]>,
|
|
640
|
-
): Record<string, string | readonly string[]> => {
|
|
679
|
+
export const patchMyUser = async (patchMyUserBody: PatchMyUserBody, options?: Parameters<typeof customFetch>[1]): Promise<PatchMyUser200> => {
|
|
680
|
+
|
|
681
|
+
const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {
|
|
641
682
|
if (!h) return {};
|
|
642
683
|
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
643
684
|
if (Symbol.iterator in h) {
|
|
644
685
|
return Object.fromEntries(
|
|
645
|
-
Array.from(
|
|
646
|
-
h as Iterable<Iterable<string>>,
|
|
647
|
-
(entry) => Array.from(entry) as [string, string],
|
|
648
|
-
),
|
|
686
|
+
Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),
|
|
649
687
|
);
|
|
650
688
|
}
|
|
651
689
|
const headers: Record<string, string | readonly string[]> = {};
|
|
@@ -654,29 +692,31 @@ export const patchMyUser = async (
|
|
|
654
692
|
}
|
|
655
693
|
return headers;
|
|
656
694
|
};
|
|
657
|
-
|
|
695
|
+
return customFetch<PatchMyUser200>(getPatchMyUserUrl(),
|
|
696
|
+
{
|
|
658
697
|
...options,
|
|
659
|
-
method:
|
|
660
|
-
headers: {
|
|
661
|
-
body: JSON.stringify(patchMyUserBody)
|
|
662
|
-
}
|
|
663
|
-
}
|
|
698
|
+
method: 'PATCH',
|
|
699
|
+
headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },
|
|
700
|
+
body: JSON.stringify(patchMyUserBody)
|
|
701
|
+
}
|
|
702
|
+
);}
|
|
703
|
+
|
|
664
704
|
|
|
665
|
-
|
|
705
|
+
|
|
706
|
+
export const getListMyProjectsUrl = (params?: ListMyProjectsParams,) => {
|
|
666
707
|
const normalizedParams = new URLSearchParams();
|
|
667
708
|
|
|
668
709
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
710
|
+
|
|
669
711
|
if (value !== undefined) {
|
|
670
|
-
normalizedParams.append(key, value === null ?
|
|
712
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
671
713
|
}
|
|
672
714
|
});
|
|
673
715
|
|
|
674
716
|
const stringifiedParams = normalizedParams.toString();
|
|
675
717
|
|
|
676
|
-
return stringifiedParams.length > 0
|
|
677
|
-
|
|
678
|
-
: `${getProxyPath()}/users/me/projects`;
|
|
679
|
-
};
|
|
718
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/users/me/projects?${stringifiedParams}` : `${getProxyPath()}/users/me/projects`
|
|
719
|
+
}
|
|
680
720
|
|
|
681
721
|
/**
|
|
682
722
|
* The projects the signed-in user holds an active grant on, either directly or
|
|
@@ -688,19 +728,26 @@ export const getListMyProjectsUrl = (params?: ListMyProjectsParams) => {
|
|
|
688
728
|
* and the grants are the answer, so the list spans projects.
|
|
689
729
|
* @summary List the projects I can act on
|
|
690
730
|
*/
|
|
691
|
-
export const listMyProjects = async (
|
|
692
|
-
|
|
693
|
-
|
|
694
|
-
|
|
695
|
-
return customFetch<ListMyProjects200>(getListMyProjectsUrl(params), {
|
|
731
|
+
export const listMyProjects = async (params?: ListMyProjectsParams, options?: Parameters<typeof customFetch>[1]): Promise<ListMyProjects200> => {
|
|
732
|
+
|
|
733
|
+
return customFetch<ListMyProjects200>(getListMyProjectsUrl(params),
|
|
734
|
+
{
|
|
696
735
|
...options,
|
|
697
|
-
method:
|
|
698
|
-
|
|
699
|
-
|
|
736
|
+
method: 'GET'
|
|
737
|
+
|
|
738
|
+
|
|
739
|
+
}
|
|
740
|
+
);}
|
|
741
|
+
|
|
742
|
+
|
|
700
743
|
|
|
701
744
|
export const getCreateFlowUrl = () => {
|
|
702
|
-
|
|
703
|
-
|
|
745
|
+
|
|
746
|
+
|
|
747
|
+
|
|
748
|
+
|
|
749
|
+
return `${getProxyPath()}/flow`
|
|
750
|
+
}
|
|
704
751
|
|
|
705
752
|
/**
|
|
706
753
|
* Resolves a flow definition based on purpose + audience context and returns
|
|
@@ -716,21 +763,14 @@ export const getCreateFlowUrl = () => {
|
|
|
716
763
|
* cookie. The browser sends it automatically on subsequent requests.
|
|
717
764
|
* @summary Start a new flow
|
|
718
765
|
*/
|
|
719
|
-
export const createFlow = async (
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
): Promise<CreateFlow201> => {
|
|
723
|
-
const getHeaders = (
|
|
724
|
-
h?: NonNullable<RequestInit["headers"]>,
|
|
725
|
-
): Record<string, string | readonly string[]> => {
|
|
766
|
+
export const createFlow = async (createFlowBody: CreateFlowBody, options?: Parameters<typeof customFetch>[1]): Promise<CreateFlow201> => {
|
|
767
|
+
|
|
768
|
+
const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {
|
|
726
769
|
if (!h) return {};
|
|
727
770
|
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
728
771
|
if (Symbol.iterator in h) {
|
|
729
772
|
return Object.fromEntries(
|
|
730
|
-
Array.from(
|
|
731
|
-
h as Iterable<Iterable<string>>,
|
|
732
|
-
(entry) => Array.from(entry) as [string, string],
|
|
733
|
-
),
|
|
773
|
+
Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),
|
|
734
774
|
);
|
|
735
775
|
}
|
|
736
776
|
const headers: Record<string, string | readonly string[]> = {};
|
|
@@ -739,36 +779,50 @@ export const createFlow = async (
|
|
|
739
779
|
}
|
|
740
780
|
return headers;
|
|
741
781
|
};
|
|
742
|
-
|
|
782
|
+
return customFetch<CreateFlow201>(getCreateFlowUrl(),
|
|
783
|
+
{
|
|
743
784
|
...options,
|
|
744
|
-
method:
|
|
745
|
-
headers: {
|
|
746
|
-
body: JSON.stringify(createFlowBody)
|
|
747
|
-
}
|
|
748
|
-
}
|
|
785
|
+
method: 'POST',
|
|
786
|
+
headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },
|
|
787
|
+
body: JSON.stringify(createFlowBody)
|
|
788
|
+
}
|
|
789
|
+
);}
|
|
790
|
+
|
|
791
|
+
|
|
792
|
+
|
|
793
|
+
export const getGetFlowStepUrl = (id: string,) => {
|
|
794
|
+
|
|
749
795
|
|
|
750
|
-
|
|
751
|
-
|
|
752
|
-
}
|
|
796
|
+
|
|
797
|
+
|
|
798
|
+
return `${getProxyPath()}/flow/${encodeURIComponent(String(id))}`
|
|
799
|
+
}
|
|
753
800
|
|
|
754
801
|
/**
|
|
755
802
|
* Returns the current capability step without advancing the state machine.
|
|
756
803
|
* Useful for page reloads or re-rendering after a network error.
|
|
757
804
|
* @summary Get current step (re-render)
|
|
758
805
|
*/
|
|
759
|
-
export const getFlowStep = async (
|
|
760
|
-
|
|
761
|
-
|
|
762
|
-
|
|
763
|
-
return customFetch<GetFlowStep200>(getGetFlowStepUrl(id), {
|
|
806
|
+
export const getFlowStep = async (id: string, options?: Parameters<typeof customFetch>[1]): Promise<GetFlowStep200> => {
|
|
807
|
+
|
|
808
|
+
return customFetch<GetFlowStep200>(getGetFlowStepUrl(id),
|
|
809
|
+
{
|
|
764
810
|
...options,
|
|
765
|
-
method:
|
|
766
|
-
|
|
767
|
-
};
|
|
811
|
+
method: 'GET'
|
|
812
|
+
|
|
768
813
|
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
814
|
+
}
|
|
815
|
+
);}
|
|
816
|
+
|
|
817
|
+
|
|
818
|
+
|
|
819
|
+
export const getSubmitFlowStepUrl = (id: string,) => {
|
|
820
|
+
|
|
821
|
+
|
|
822
|
+
|
|
823
|
+
|
|
824
|
+
return `${getProxyPath()}/flow/${encodeURIComponent(String(id))}/submit`
|
|
825
|
+
}
|
|
772
826
|
|
|
773
827
|
/**
|
|
774
828
|
* Submits user input for the current step. The server validates,
|
|
@@ -798,24 +852,38 @@ export const getSubmitFlowStepUrl = (id: string) => {
|
|
|
798
852
|
* If a stacked flow (e.g., recovery pivoted from login) finishes, the server
|
|
799
853
|
* auto-pops to the parent flow and returns the parent's next step — the
|
|
800
854
|
* frontend never sees a `complete` for intermediate flows.
|
|
855
|
+
*
|
|
856
|
+
* ## External sign-in
|
|
857
|
+
*
|
|
858
|
+
* `{action: "sso", sso_provider_id, return_target}` on a step that offers
|
|
859
|
+
* `sso_providers` returns the engine-emitted `sso-redirect` step, whose
|
|
860
|
+
* `redirect_url` the frontend navigates to.
|
|
861
|
+
*
|
|
862
|
+
* - The flow state does not change, but `_zflow` is re-sealed like on
|
|
863
|
+
* every response, so its ten-minute window restarts at this submission;
|
|
864
|
+
* the external sign-in and the return must complete within it.
|
|
865
|
+
* - A second `Set-Cookie` line carries the browser-binding cookie the
|
|
866
|
+
* callback checks: `HttpOnly`, `Path=/`, `SameSite=Lax`.
|
|
867
|
+
* - On every host except http loopback it is `__Host-_zsso` with `Secure`.
|
|
868
|
+
* - When the request host is http loopback (local development, where
|
|
869
|
+
* Safari rejects `Secure`), it is `_zsso` with no `Secure`; the
|
|
870
|
+
* `__Host-` prefix is dropped because it requires `Secure`.
|
|
871
|
+
*
|
|
872
|
+
* A connection whose `client_id` is a `${{ NAME }}` reference has it filled
|
|
873
|
+
* from the project's variables. A provider the engine cannot start a
|
|
874
|
+
* sign-in with, including a reference with no variable behind it,
|
|
875
|
+
* re-renders the step with `error.sso_unavailable`.
|
|
801
876
|
* @summary Submit step data and advance
|
|
802
877
|
*/
|
|
803
|
-
export const submitFlowStep = async (
|
|
804
|
-
|
|
805
|
-
|
|
806
|
-
|
|
807
|
-
): Promise<SubmitFlowStep200> => {
|
|
808
|
-
const getHeaders = (
|
|
809
|
-
h?: NonNullable<RequestInit["headers"]>,
|
|
810
|
-
): Record<string, string | readonly string[]> => {
|
|
878
|
+
export const submitFlowStep = async (id: string,
|
|
879
|
+
submitFlowStepBody: SubmitFlowStepBody, options?: Parameters<typeof customFetch>[1]): Promise<SubmitFlowStep200> => {
|
|
880
|
+
|
|
881
|
+
const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {
|
|
811
882
|
if (!h) return {};
|
|
812
883
|
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
813
884
|
if (Symbol.iterator in h) {
|
|
814
885
|
return Object.fromEntries(
|
|
815
|
-
Array.from(
|
|
816
|
-
h as Iterable<Iterable<string>>,
|
|
817
|
-
(entry) => Array.from(entry) as [string, string],
|
|
818
|
-
),
|
|
886
|
+
Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),
|
|
819
887
|
);
|
|
820
888
|
}
|
|
821
889
|
const headers: Record<string, string | readonly string[]> = {};
|
|
@@ -824,17 +892,24 @@ export const submitFlowStep = async (
|
|
|
824
892
|
}
|
|
825
893
|
return headers;
|
|
826
894
|
};
|
|
827
|
-
|
|
895
|
+
return customFetch<SubmitFlowStep200>(getSubmitFlowStepUrl(id),
|
|
896
|
+
{
|
|
828
897
|
...options,
|
|
829
|
-
method:
|
|
830
|
-
headers: {
|
|
831
|
-
body: JSON.stringify(submitFlowStepBody)
|
|
832
|
-
}
|
|
833
|
-
}
|
|
898
|
+
method: 'POST',
|
|
899
|
+
headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },
|
|
900
|
+
body: JSON.stringify(submitFlowStepBody)
|
|
901
|
+
}
|
|
902
|
+
);}
|
|
903
|
+
|
|
904
|
+
|
|
834
905
|
|
|
835
906
|
export const getCreateAuthAttemptUrl = () => {
|
|
836
|
-
|
|
837
|
-
|
|
907
|
+
|
|
908
|
+
|
|
909
|
+
|
|
910
|
+
|
|
911
|
+
return `${getProxyPath()}/auth_attempts`
|
|
912
|
+
}
|
|
838
913
|
|
|
839
914
|
/**
|
|
840
915
|
* Starts a new authentication attempt. This is the entry point for the auth_attempts state machine.
|
|
@@ -846,21 +921,14 @@ export const getCreateAuthAttemptUrl = () => {
|
|
|
846
921
|
* also include session_id to add factors to an existing session.
|
|
847
922
|
* @summary Create a new authentication attempt
|
|
848
923
|
*/
|
|
849
|
-
export const createAuthAttempt = async (
|
|
850
|
-
|
|
851
|
-
|
|
852
|
-
): Promise<CreateAuthAttempt201> => {
|
|
853
|
-
const getHeaders = (
|
|
854
|
-
h?: NonNullable<RequestInit["headers"]>,
|
|
855
|
-
): Record<string, string | readonly string[]> => {
|
|
924
|
+
export const createAuthAttempt = async (createAuthAttemptBody: CreateAuthAttemptBody, options?: Parameters<typeof customFetch>[1]): Promise<CreateAuthAttempt201> => {
|
|
925
|
+
|
|
926
|
+
const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {
|
|
856
927
|
if (!h) return {};
|
|
857
928
|
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
858
929
|
if (Symbol.iterator in h) {
|
|
859
930
|
return Object.fromEntries(
|
|
860
|
-
Array.from(
|
|
861
|
-
h as Iterable<Iterable<string>>,
|
|
862
|
-
(entry) => Array.from(entry) as [string, string],
|
|
863
|
-
),
|
|
931
|
+
Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),
|
|
864
932
|
);
|
|
865
933
|
}
|
|
866
934
|
const headers: Record<string, string | readonly string[]> = {};
|
|
@@ -869,17 +937,24 @@ export const createAuthAttempt = async (
|
|
|
869
937
|
}
|
|
870
938
|
return headers;
|
|
871
939
|
};
|
|
872
|
-
|
|
940
|
+
return customFetch<CreateAuthAttempt201>(getCreateAuthAttemptUrl(),
|
|
941
|
+
{
|
|
873
942
|
...options,
|
|
874
|
-
method:
|
|
875
|
-
headers: {
|
|
876
|
-
body: JSON.stringify(createAuthAttemptBody)
|
|
877
|
-
}
|
|
878
|
-
}
|
|
943
|
+
method: 'POST',
|
|
944
|
+
headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },
|
|
945
|
+
body: JSON.stringify(createAuthAttemptBody)
|
|
946
|
+
}
|
|
947
|
+
);}
|
|
948
|
+
|
|
949
|
+
|
|
879
950
|
|
|
880
|
-
export const getGetAuthAttemptUrl = (attemptId: string) => {
|
|
881
|
-
|
|
882
|
-
|
|
951
|
+
export const getGetAuthAttemptUrl = (attemptId: string,) => {
|
|
952
|
+
|
|
953
|
+
|
|
954
|
+
|
|
955
|
+
|
|
956
|
+
return `${getProxyPath()}/auth_attempts/${encodeURIComponent(String(attemptId))}`
|
|
957
|
+
}
|
|
883
958
|
|
|
884
959
|
/**
|
|
885
960
|
* Polls the current state of an authentication attempt.
|
|
@@ -891,19 +966,26 @@ export const getGetAuthAttemptUrl = (attemptId: string) => {
|
|
|
891
966
|
* a federated IdP callback or a device flow).
|
|
892
967
|
* @summary Get authentication attempt state
|
|
893
968
|
*/
|
|
894
|
-
export const getAuthAttempt = async (
|
|
895
|
-
|
|
896
|
-
|
|
897
|
-
|
|
898
|
-
return customFetch<GetAuthAttempt200>(getGetAuthAttemptUrl(attemptId), {
|
|
969
|
+
export const getAuthAttempt = async (attemptId: string, options?: Parameters<typeof customFetch>[1]): Promise<GetAuthAttempt200> => {
|
|
970
|
+
|
|
971
|
+
return customFetch<GetAuthAttempt200>(getGetAuthAttemptUrl(attemptId),
|
|
972
|
+
{
|
|
899
973
|
...options,
|
|
900
|
-
method:
|
|
901
|
-
|
|
902
|
-
|
|
974
|
+
method: 'GET'
|
|
975
|
+
|
|
976
|
+
|
|
977
|
+
}
|
|
978
|
+
);}
|
|
979
|
+
|
|
980
|
+
|
|
981
|
+
|
|
982
|
+
export const getIssueChallengeUrl = (attemptId: string,) => {
|
|
903
983
|
|
|
904
|
-
|
|
905
|
-
|
|
906
|
-
|
|
984
|
+
|
|
985
|
+
|
|
986
|
+
|
|
987
|
+
return `${getProxyPath()}/auth_attempts/${encodeURIComponent(String(attemptId))}/challenges`
|
|
988
|
+
}
|
|
907
989
|
|
|
908
990
|
/**
|
|
909
991
|
* Issues a single-factor verification challenge within an auth attempt.
|
|
@@ -914,22 +996,15 @@ export const getIssueChallengeUrl = (attemptId: string) => {
|
|
|
914
996
|
* by calling POST /auth_attempts/{attempt_id}/challenges/{challenge_id}/verify.
|
|
915
997
|
* @summary Issue a factor challenge
|
|
916
998
|
*/
|
|
917
|
-
export const issueChallenge = async (
|
|
918
|
-
|
|
919
|
-
|
|
920
|
-
|
|
921
|
-
): Promise<IssueChallenge201> => {
|
|
922
|
-
const getHeaders = (
|
|
923
|
-
h?: NonNullable<RequestInit["headers"]>,
|
|
924
|
-
): Record<string, string | readonly string[]> => {
|
|
999
|
+
export const issueChallenge = async (attemptId: string,
|
|
1000
|
+
issueChallengeBody: IssueChallengeBody, options?: Parameters<typeof customFetch>[1]): Promise<IssueChallenge201> => {
|
|
1001
|
+
|
|
1002
|
+
const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {
|
|
925
1003
|
if (!h) return {};
|
|
926
1004
|
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
927
1005
|
if (Symbol.iterator in h) {
|
|
928
1006
|
return Object.fromEntries(
|
|
929
|
-
Array.from(
|
|
930
|
-
h as Iterable<Iterable<string>>,
|
|
931
|
-
(entry) => Array.from(entry) as [string, string],
|
|
932
|
-
),
|
|
1007
|
+
Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),
|
|
933
1008
|
);
|
|
934
1009
|
}
|
|
935
1010
|
const headers: Record<string, string | readonly string[]> = {};
|
|
@@ -938,17 +1013,25 @@ export const issueChallenge = async (
|
|
|
938
1013
|
}
|
|
939
1014
|
return headers;
|
|
940
1015
|
};
|
|
941
|
-
|
|
1016
|
+
return customFetch<IssueChallenge201>(getIssueChallengeUrl(attemptId),
|
|
1017
|
+
{
|
|
942
1018
|
...options,
|
|
943
|
-
method:
|
|
944
|
-
headers: {
|
|
945
|
-
body: JSON.stringify(issueChallengeBody)
|
|
946
|
-
}
|
|
947
|
-
}
|
|
1019
|
+
method: 'POST',
|
|
1020
|
+
headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },
|
|
1021
|
+
body: JSON.stringify(issueChallengeBody)
|
|
1022
|
+
}
|
|
1023
|
+
);}
|
|
1024
|
+
|
|
1025
|
+
|
|
1026
|
+
|
|
1027
|
+
export const getVerifyChallengeProofUrl = (attemptId: string,
|
|
1028
|
+
challengeId: string,) => {
|
|
1029
|
+
|
|
1030
|
+
|
|
948
1031
|
|
|
949
|
-
|
|
950
|
-
return `${getProxyPath()}/auth_attempts/${encodeURIComponent(String(attemptId))}/challenges/${encodeURIComponent(String(challengeId))}/verify
|
|
951
|
-
}
|
|
1032
|
+
|
|
1033
|
+
return `${getProxyPath()}/auth_attempts/${encodeURIComponent(String(attemptId))}/challenges/${encodeURIComponent(String(challengeId))}/verify`
|
|
1034
|
+
}
|
|
952
1035
|
|
|
953
1036
|
/**
|
|
954
1037
|
* Submits a proof (credential, code, assertion) to verify a factor challenge.
|
|
@@ -963,23 +1046,16 @@ export const getVerifyChallengeProofUrl = (attemptId: string, challengeId: strin
|
|
|
963
1046
|
* The attempt moves to the next pending challenge or completes if all required factors are verified.
|
|
964
1047
|
* @summary Verify a factor proof
|
|
965
1048
|
*/
|
|
966
|
-
export const verifyChallengeProof = async (
|
|
967
|
-
|
|
968
|
-
|
|
969
|
-
|
|
970
|
-
|
|
971
|
-
): Promise<VerifyChallengeProof200> => {
|
|
972
|
-
const getHeaders = (
|
|
973
|
-
h?: NonNullable<RequestInit["headers"]>,
|
|
974
|
-
): Record<string, string | readonly string[]> => {
|
|
1049
|
+
export const verifyChallengeProof = async (attemptId: string,
|
|
1050
|
+
challengeId: string,
|
|
1051
|
+
verifyChallengeProofBody: VerifyChallengeProofBody, options?: Parameters<typeof customFetch>[1]): Promise<VerifyChallengeProof200> => {
|
|
1052
|
+
|
|
1053
|
+
const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {
|
|
975
1054
|
if (!h) return {};
|
|
976
1055
|
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
977
1056
|
if (Symbol.iterator in h) {
|
|
978
1057
|
return Object.fromEntries(
|
|
979
|
-
Array.from(
|
|
980
|
-
h as Iterable<Iterable<string>>,
|
|
981
|
-
(entry) => Array.from(entry) as [string, string],
|
|
982
|
-
),
|
|
1058
|
+
Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),
|
|
983
1059
|
);
|
|
984
1060
|
}
|
|
985
1061
|
const headers: Record<string, string | readonly string[]> = {};
|
|
@@ -988,17 +1064,24 @@ export const verifyChallengeProof = async (
|
|
|
988
1064
|
}
|
|
989
1065
|
return headers;
|
|
990
1066
|
};
|
|
991
|
-
|
|
1067
|
+
return customFetch<VerifyChallengeProof200>(getVerifyChallengeProofUrl(attemptId,challengeId),
|
|
1068
|
+
{
|
|
992
1069
|
...options,
|
|
993
|
-
method:
|
|
994
|
-
headers: {
|
|
995
|
-
body: JSON.stringify(verifyChallengeProofBody)
|
|
996
|
-
}
|
|
997
|
-
}
|
|
1070
|
+
method: 'POST',
|
|
1071
|
+
headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },
|
|
1072
|
+
body: JSON.stringify(verifyChallengeProofBody)
|
|
1073
|
+
}
|
|
1074
|
+
);}
|
|
1075
|
+
|
|
1076
|
+
|
|
1077
|
+
|
|
1078
|
+
export const getCreateHandoffUrl = (attemptId: string,) => {
|
|
998
1079
|
|
|
999
|
-
|
|
1000
|
-
|
|
1001
|
-
|
|
1080
|
+
|
|
1081
|
+
|
|
1082
|
+
|
|
1083
|
+
return `${getProxyPath()}/auth_attempts/${encodeURIComponent(String(attemptId))}/handoff`
|
|
1084
|
+
}
|
|
1002
1085
|
|
|
1003
1086
|
/**
|
|
1004
1087
|
* Completes the authentication attempt and mints a `handoff_token`.
|
|
@@ -1013,38 +1096,38 @@ export const getCreateHandoffUrl = (attemptId: string) => {
|
|
|
1013
1096
|
* - Idempotency-safe within a 5-minute window (see conventions)
|
|
1014
1097
|
* @summary Complete authentication and create handoff token
|
|
1015
1098
|
*/
|
|
1016
|
-
export const createHandoff = async (
|
|
1017
|
-
|
|
1018
|
-
|
|
1019
|
-
|
|
1020
|
-
return customFetch<CreateHandoff200>(getCreateHandoffUrl(attemptId), {
|
|
1099
|
+
export const createHandoff = async (attemptId: string, options?: Parameters<typeof customFetch>[1]): Promise<CreateHandoff200> => {
|
|
1100
|
+
|
|
1101
|
+
return customFetch<CreateHandoff200>(getCreateHandoffUrl(attemptId),
|
|
1102
|
+
{
|
|
1021
1103
|
...options,
|
|
1022
|
-
method:
|
|
1023
|
-
|
|
1024
|
-
|
|
1104
|
+
method: 'POST'
|
|
1105
|
+
|
|
1106
|
+
|
|
1107
|
+
}
|
|
1108
|
+
);}
|
|
1109
|
+
|
|
1110
|
+
|
|
1025
1111
|
|
|
1026
1112
|
export const getCreateProjectUrl = () => {
|
|
1027
|
-
|
|
1028
|
-
|
|
1113
|
+
|
|
1114
|
+
|
|
1115
|
+
|
|
1116
|
+
|
|
1117
|
+
return `${getProxyPath()}/projects`
|
|
1118
|
+
}
|
|
1029
1119
|
|
|
1030
1120
|
/**
|
|
1031
1121
|
* @summary Create project
|
|
1032
1122
|
*/
|
|
1033
|
-
export const createProject = async (
|
|
1034
|
-
|
|
1035
|
-
|
|
1036
|
-
): Promise<CreateProject201> => {
|
|
1037
|
-
const getHeaders = (
|
|
1038
|
-
h?: NonNullable<RequestInit["headers"]>,
|
|
1039
|
-
): Record<string, string | readonly string[]> => {
|
|
1123
|
+
export const createProject = async (createProjectBody: CreateProjectBody, options?: Parameters<typeof customFetch>[1]): Promise<CreateProject201> => {
|
|
1124
|
+
|
|
1125
|
+
const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {
|
|
1040
1126
|
if (!h) return {};
|
|
1041
1127
|
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1042
1128
|
if (Symbol.iterator in h) {
|
|
1043
1129
|
return Object.fromEntries(
|
|
1044
|
-
Array.from(
|
|
1045
|
-
h as Iterable<Iterable<string>>,
|
|
1046
|
-
(entry) => Array.from(entry) as [string, string],
|
|
1047
|
-
),
|
|
1130
|
+
Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),
|
|
1048
1131
|
);
|
|
1049
1132
|
}
|
|
1050
1133
|
const headers: Record<string, string | readonly string[]> = {};
|
|
@@ -1053,36 +1136,36 @@ export const createProject = async (
|
|
|
1053
1136
|
}
|
|
1054
1137
|
return headers;
|
|
1055
1138
|
};
|
|
1056
|
-
|
|
1139
|
+
return customFetch<CreateProject201>(getCreateProjectUrl(),
|
|
1140
|
+
{
|
|
1057
1141
|
...options,
|
|
1058
|
-
method:
|
|
1059
|
-
headers: {
|
|
1060
|
-
body: JSON.stringify(createProjectBody)
|
|
1061
|
-
}
|
|
1062
|
-
}
|
|
1142
|
+
method: 'POST',
|
|
1143
|
+
headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },
|
|
1144
|
+
body: JSON.stringify(createProjectBody)
|
|
1145
|
+
}
|
|
1146
|
+
);}
|
|
1147
|
+
|
|
1148
|
+
|
|
1063
1149
|
|
|
1064
1150
|
export const getQueryProjectsUrl = () => {
|
|
1065
|
-
|
|
1066
|
-
|
|
1151
|
+
|
|
1152
|
+
|
|
1153
|
+
|
|
1154
|
+
|
|
1155
|
+
return `${getProxyPath()}/projects/query`
|
|
1156
|
+
}
|
|
1067
1157
|
|
|
1068
1158
|
/**
|
|
1069
1159
|
* @summary Query projects
|
|
1070
1160
|
*/
|
|
1071
|
-
export const queryProjects = async (
|
|
1072
|
-
|
|
1073
|
-
|
|
1074
|
-
): Promise<QueryProjects200> => {
|
|
1075
|
-
const getHeaders = (
|
|
1076
|
-
h?: NonNullable<RequestInit["headers"]>,
|
|
1077
|
-
): Record<string, string | readonly string[]> => {
|
|
1161
|
+
export const queryProjects = async (queryProjectsBody: QueryProjectsBody, options?: Parameters<typeof customFetch>[1]): Promise<QueryProjects200> => {
|
|
1162
|
+
|
|
1163
|
+
const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {
|
|
1078
1164
|
if (!h) return {};
|
|
1079
1165
|
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1080
1166
|
if (Symbol.iterator in h) {
|
|
1081
1167
|
return Object.fromEntries(
|
|
1082
|
-
Array.from(
|
|
1083
|
-
h as Iterable<Iterable<string>>,
|
|
1084
|
-
(entry) => Array.from(entry) as [string, string],
|
|
1085
|
-
),
|
|
1168
|
+
Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),
|
|
1086
1169
|
);
|
|
1087
1170
|
}
|
|
1088
1171
|
const headers: Record<string, string | readonly string[]> = {};
|
|
@@ -1091,56 +1174,63 @@ export const queryProjects = async (
|
|
|
1091
1174
|
}
|
|
1092
1175
|
return headers;
|
|
1093
1176
|
};
|
|
1094
|
-
|
|
1177
|
+
return customFetch<QueryProjects200>(getQueryProjectsUrl(),
|
|
1178
|
+
{
|
|
1095
1179
|
...options,
|
|
1096
|
-
method:
|
|
1097
|
-
headers: {
|
|
1098
|
-
body: JSON.stringify(queryProjectsBody)
|
|
1099
|
-
}
|
|
1100
|
-
}
|
|
1180
|
+
method: 'POST',
|
|
1181
|
+
headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },
|
|
1182
|
+
body: JSON.stringify(queryProjectsBody)
|
|
1183
|
+
}
|
|
1184
|
+
);}
|
|
1185
|
+
|
|
1186
|
+
|
|
1187
|
+
|
|
1188
|
+
export const getGetProjectUrl = (projectId: string,) => {
|
|
1101
1189
|
|
|
1102
|
-
|
|
1103
|
-
|
|
1104
|
-
|
|
1190
|
+
|
|
1191
|
+
|
|
1192
|
+
|
|
1193
|
+
return `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}`
|
|
1194
|
+
}
|
|
1105
1195
|
|
|
1106
1196
|
/**
|
|
1107
1197
|
* Returns the current state of a project.
|
|
1108
1198
|
* @summary Get project
|
|
1109
1199
|
*/
|
|
1110
|
-
export const getProject = async (
|
|
1111
|
-
|
|
1112
|
-
|
|
1113
|
-
|
|
1114
|
-
return customFetch<GetProject200>(getGetProjectUrl(projectId), {
|
|
1200
|
+
export const getProject = async (projectId: string, options?: Parameters<typeof customFetch>[1]): Promise<GetProject200> => {
|
|
1201
|
+
|
|
1202
|
+
return customFetch<GetProject200>(getGetProjectUrl(projectId),
|
|
1203
|
+
{
|
|
1115
1204
|
...options,
|
|
1116
|
-
method:
|
|
1117
|
-
|
|
1118
|
-
|
|
1205
|
+
method: 'GET'
|
|
1206
|
+
|
|
1207
|
+
|
|
1208
|
+
}
|
|
1209
|
+
);}
|
|
1210
|
+
|
|
1211
|
+
|
|
1212
|
+
|
|
1213
|
+
export const getPatchProjectUrl = (projectId: string,) => {
|
|
1119
1214
|
|
|
1120
|
-
|
|
1121
|
-
|
|
1122
|
-
|
|
1215
|
+
|
|
1216
|
+
|
|
1217
|
+
|
|
1218
|
+
return `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}`
|
|
1219
|
+
}
|
|
1123
1220
|
|
|
1124
1221
|
/**
|
|
1125
1222
|
* Updates the state of a project.
|
|
1126
1223
|
* @summary Update project
|
|
1127
1224
|
*/
|
|
1128
|
-
export const patchProject = async (
|
|
1129
|
-
|
|
1130
|
-
|
|
1131
|
-
|
|
1132
|
-
): Promise<PatchProject200> => {
|
|
1133
|
-
const getHeaders = (
|
|
1134
|
-
h?: NonNullable<RequestInit["headers"]>,
|
|
1135
|
-
): Record<string, string | readonly string[]> => {
|
|
1225
|
+
export const patchProject = async (projectId: string,
|
|
1226
|
+
patchProjectBody: PatchProjectBody, options?: Parameters<typeof customFetch>[1]): Promise<PatchProject200> => {
|
|
1227
|
+
|
|
1228
|
+
const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {
|
|
1136
1229
|
if (!h) return {};
|
|
1137
1230
|
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1138
1231
|
if (Symbol.iterator in h) {
|
|
1139
1232
|
return Object.fromEntries(
|
|
1140
|
-
Array.from(
|
|
1141
|
-
h as Iterable<Iterable<string>>,
|
|
1142
|
-
(entry) => Array.from(entry) as [string, string],
|
|
1143
|
-
),
|
|
1233
|
+
Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),
|
|
1144
1234
|
);
|
|
1145
1235
|
}
|
|
1146
1236
|
const headers: Record<string, string | readonly string[]> = {};
|
|
@@ -1149,17 +1239,24 @@ export const patchProject = async (
|
|
|
1149
1239
|
}
|
|
1150
1240
|
return headers;
|
|
1151
1241
|
};
|
|
1152
|
-
|
|
1242
|
+
return customFetch<PatchProject200>(getPatchProjectUrl(projectId),
|
|
1243
|
+
{
|
|
1153
1244
|
...options,
|
|
1154
|
-
method:
|
|
1155
|
-
headers: {
|
|
1156
|
-
body: JSON.stringify(patchProjectBody)
|
|
1157
|
-
}
|
|
1158
|
-
}
|
|
1245
|
+
method: 'PATCH',
|
|
1246
|
+
headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },
|
|
1247
|
+
body: JSON.stringify(patchProjectBody)
|
|
1248
|
+
}
|
|
1249
|
+
);}
|
|
1250
|
+
|
|
1251
|
+
|
|
1252
|
+
|
|
1253
|
+
export const getInitClaimUrl = (projectId: string,) => {
|
|
1254
|
+
|
|
1255
|
+
|
|
1159
1256
|
|
|
1160
|
-
|
|
1161
|
-
return `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}/claim/init
|
|
1162
|
-
}
|
|
1257
|
+
|
|
1258
|
+
return `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}/claim/init`
|
|
1259
|
+
}
|
|
1163
1260
|
|
|
1164
1261
|
/**
|
|
1165
1262
|
* Starts a claim challenge for an unclaimed project. Authenticated by the
|
|
@@ -1169,31 +1266,34 @@ export const getInitClaimUrl = (projectId: string) => {
|
|
|
1169
1266
|
* carried by `expires_at` on the response.
|
|
1170
1267
|
* @summary Initialize a project claim
|
|
1171
1268
|
*/
|
|
1172
|
-
export const initClaim = async (
|
|
1173
|
-
|
|
1174
|
-
|
|
1175
|
-
|
|
1176
|
-
return customFetch<InitClaim201>(getInitClaimUrl(projectId), {
|
|
1269
|
+
export const initClaim = async (projectId: string, options?: Parameters<typeof customFetch>[1]): Promise<InitClaim201> => {
|
|
1270
|
+
|
|
1271
|
+
return customFetch<InitClaim201>(getInitClaimUrl(projectId),
|
|
1272
|
+
{
|
|
1177
1273
|
...options,
|
|
1178
|
-
method:
|
|
1179
|
-
|
|
1180
|
-
|
|
1274
|
+
method: 'POST'
|
|
1275
|
+
|
|
1276
|
+
|
|
1277
|
+
}
|
|
1278
|
+
);}
|
|
1181
1279
|
|
|
1182
|
-
|
|
1280
|
+
|
|
1281
|
+
|
|
1282
|
+
export const getGetClaimStatusUrl = (projectId: string,
|
|
1283
|
+
params: GetClaimStatusParams,) => {
|
|
1183
1284
|
const normalizedParams = new URLSearchParams();
|
|
1184
1285
|
|
|
1185
1286
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
1287
|
+
|
|
1186
1288
|
if (value !== undefined) {
|
|
1187
|
-
normalizedParams.append(key, value === null ?
|
|
1289
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
1188
1290
|
}
|
|
1189
1291
|
});
|
|
1190
1292
|
|
|
1191
1293
|
const stringifiedParams = normalizedParams.toString();
|
|
1192
1294
|
|
|
1193
|
-
return stringifiedParams.length > 0
|
|
1194
|
-
|
|
1195
|
-
: `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}/claim/status`;
|
|
1196
|
-
};
|
|
1295
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}/claim/status?${stringifiedParams}` : `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}/claim/status`
|
|
1296
|
+
}
|
|
1197
1297
|
|
|
1198
1298
|
/**
|
|
1199
1299
|
* Polled by the CLI while a browser completes the claim. Authorized by the
|
|
@@ -1206,20 +1306,27 @@ export const getGetClaimStatusUrl = (projectId: string, params: GetClaimStatusPa
|
|
|
1206
1306
|
* project's claim window.
|
|
1207
1307
|
* @summary Get claim status
|
|
1208
1308
|
*/
|
|
1209
|
-
export const getClaimStatus = async (
|
|
1210
|
-
|
|
1211
|
-
|
|
1212
|
-
|
|
1213
|
-
|
|
1214
|
-
return customFetch<GetClaimStatus200>(getGetClaimStatusUrl(projectId, params), {
|
|
1309
|
+
export const getClaimStatus = async (projectId: string,
|
|
1310
|
+
params: GetClaimStatusParams, options?: Parameters<typeof customFetch>[1]): Promise<GetClaimStatus200> => {
|
|
1311
|
+
|
|
1312
|
+
return customFetch<GetClaimStatus200>(getGetClaimStatusUrl(projectId,params),
|
|
1313
|
+
{
|
|
1215
1314
|
...options,
|
|
1216
|
-
method:
|
|
1217
|
-
});
|
|
1218
|
-
};
|
|
1315
|
+
method: 'GET'
|
|
1219
1316
|
|
|
1220
|
-
|
|
1221
|
-
|
|
1222
|
-
}
|
|
1317
|
+
|
|
1318
|
+
}
|
|
1319
|
+
);}
|
|
1320
|
+
|
|
1321
|
+
|
|
1322
|
+
|
|
1323
|
+
export const getCompleteClaimUrl = (projectId: string,) => {
|
|
1324
|
+
|
|
1325
|
+
|
|
1326
|
+
|
|
1327
|
+
|
|
1328
|
+
return `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}/claim/complete`
|
|
1329
|
+
}
|
|
1223
1330
|
|
|
1224
1331
|
/**
|
|
1225
1332
|
* Called by the browser after the developer authenticates on the claim page.
|
|
@@ -1228,22 +1335,15 @@ export const getCompleteClaimUrl = (projectId: string) => {
|
|
|
1228
1335
|
* its single-use, browser-safe authorization.
|
|
1229
1336
|
* @summary Complete a project claim
|
|
1230
1337
|
*/
|
|
1231
|
-
export const completeClaim = async (
|
|
1232
|
-
|
|
1233
|
-
|
|
1234
|
-
|
|
1235
|
-
): Promise<CompleteClaim200> => {
|
|
1236
|
-
const getHeaders = (
|
|
1237
|
-
h?: NonNullable<RequestInit["headers"]>,
|
|
1238
|
-
): Record<string, string | readonly string[]> => {
|
|
1338
|
+
export const completeClaim = async (projectId: string,
|
|
1339
|
+
completeClaimBody: CompleteClaimBody, options?: Parameters<typeof customFetch>[1]): Promise<CompleteClaim200> => {
|
|
1340
|
+
|
|
1341
|
+
const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {
|
|
1239
1342
|
if (!h) return {};
|
|
1240
1343
|
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1241
1344
|
if (Symbol.iterator in h) {
|
|
1242
1345
|
return Object.fromEntries(
|
|
1243
|
-
Array.from(
|
|
1244
|
-
h as Iterable<Iterable<string>>,
|
|
1245
|
-
(entry) => Array.from(entry) as [string, string],
|
|
1246
|
-
),
|
|
1346
|
+
Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),
|
|
1247
1347
|
);
|
|
1248
1348
|
}
|
|
1249
1349
|
const headers: Record<string, string | readonly string[]> = {};
|
|
@@ -1252,29 +1352,32 @@ export const completeClaim = async (
|
|
|
1252
1352
|
}
|
|
1253
1353
|
return headers;
|
|
1254
1354
|
};
|
|
1255
|
-
|
|
1355
|
+
return customFetch<CompleteClaim200>(getCompleteClaimUrl(projectId),
|
|
1356
|
+
{
|
|
1256
1357
|
...options,
|
|
1257
|
-
method:
|
|
1258
|
-
headers: {
|
|
1259
|
-
body: JSON.stringify(completeClaimBody)
|
|
1260
|
-
}
|
|
1261
|
-
}
|
|
1358
|
+
method: 'POST',
|
|
1359
|
+
headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },
|
|
1360
|
+
body: JSON.stringify(completeClaimBody)
|
|
1361
|
+
}
|
|
1362
|
+
);}
|
|
1363
|
+
|
|
1262
1364
|
|
|
1263
|
-
|
|
1365
|
+
|
|
1366
|
+
export const getGetClaimWindowUrl = (projectId: string,
|
|
1367
|
+
params: GetClaimWindowParams,) => {
|
|
1264
1368
|
const normalizedParams = new URLSearchParams();
|
|
1265
1369
|
|
|
1266
1370
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
1371
|
+
|
|
1267
1372
|
if (value !== undefined) {
|
|
1268
|
-
normalizedParams.append(key, value === null ?
|
|
1373
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
1269
1374
|
}
|
|
1270
1375
|
});
|
|
1271
1376
|
|
|
1272
1377
|
const stringifiedParams = normalizedParams.toString();
|
|
1273
1378
|
|
|
1274
|
-
return stringifiedParams.length > 0
|
|
1275
|
-
|
|
1276
|
-
: `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}/claim/window`;
|
|
1277
|
-
};
|
|
1379
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}/claim/window?${stringifiedParams}` : `${getProxyPath()}/projects/${encodeURIComponent(String(projectId))}/claim/window`
|
|
1380
|
+
}
|
|
1278
1381
|
|
|
1279
1382
|
/**
|
|
1280
1383
|
* Read by the claim page in the browser to show how long is left to claim the
|
|
@@ -1285,20 +1388,27 @@ export const getGetClaimWindowUrl = (projectId: string, params: GetClaimWindowPa
|
|
|
1285
1388
|
* `claim/complete` it spends nothing, so a reload is free.
|
|
1286
1389
|
* @summary Get the claim window for a project
|
|
1287
1390
|
*/
|
|
1288
|
-
export const getClaimWindow = async (
|
|
1289
|
-
|
|
1290
|
-
|
|
1291
|
-
|
|
1292
|
-
|
|
1293
|
-
return customFetch<GetClaimWindow200>(getGetClaimWindowUrl(projectId, params), {
|
|
1391
|
+
export const getClaimWindow = async (projectId: string,
|
|
1392
|
+
params: GetClaimWindowParams, options?: Parameters<typeof customFetch>[1]): Promise<GetClaimWindow200> => {
|
|
1393
|
+
|
|
1394
|
+
return customFetch<GetClaimWindow200>(getGetClaimWindowUrl(projectId,params),
|
|
1395
|
+
{
|
|
1294
1396
|
...options,
|
|
1295
|
-
method:
|
|
1296
|
-
|
|
1297
|
-
|
|
1397
|
+
method: 'GET'
|
|
1398
|
+
|
|
1399
|
+
|
|
1400
|
+
}
|
|
1401
|
+
);}
|
|
1402
|
+
|
|
1403
|
+
|
|
1298
1404
|
|
|
1299
1405
|
export const getCreateSessionUrl = () => {
|
|
1300
|
-
|
|
1301
|
-
|
|
1406
|
+
|
|
1407
|
+
|
|
1408
|
+
|
|
1409
|
+
|
|
1410
|
+
return `${getProxyPath()}/sessions`
|
|
1411
|
+
}
|
|
1302
1412
|
|
|
1303
1413
|
/**
|
|
1304
1414
|
* Creates an anonymous session shell with no user and no factors (`state: building`).
|
|
@@ -1324,21 +1434,14 @@ export const getCreateSessionUrl = () => {
|
|
|
1324
1434
|
* full session TTL when the first authentication factor is written via a completing `auth_attempt`.
|
|
1325
1435
|
* @summary Create an anonymous session shell
|
|
1326
1436
|
*/
|
|
1327
|
-
export const createSession = async (
|
|
1328
|
-
|
|
1329
|
-
|
|
1330
|
-
): Promise<CreateSession201> => {
|
|
1331
|
-
const getHeaders = (
|
|
1332
|
-
h?: NonNullable<RequestInit["headers"]>,
|
|
1333
|
-
): Record<string, string | readonly string[]> => {
|
|
1437
|
+
export const createSession = async (createSessionBody: CreateSessionBody, options?: Parameters<typeof customFetch>[1]): Promise<CreateSession201> => {
|
|
1438
|
+
|
|
1439
|
+
const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {
|
|
1334
1440
|
if (!h) return {};
|
|
1335
1441
|
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1336
1442
|
if (Symbol.iterator in h) {
|
|
1337
1443
|
return Object.fromEntries(
|
|
1338
|
-
Array.from(
|
|
1339
|
-
h as Iterable<Iterable<string>>,
|
|
1340
|
-
(entry) => Array.from(entry) as [string, string],
|
|
1341
|
-
),
|
|
1444
|
+
Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),
|
|
1342
1445
|
);
|
|
1343
1446
|
}
|
|
1344
1447
|
const headers: Record<string, string | readonly string[]> = {};
|
|
@@ -1347,29 +1450,31 @@ export const createSession = async (
|
|
|
1347
1450
|
}
|
|
1348
1451
|
return headers;
|
|
1349
1452
|
};
|
|
1350
|
-
|
|
1453
|
+
return customFetch<CreateSession201>(getCreateSessionUrl(),
|
|
1454
|
+
{
|
|
1351
1455
|
...options,
|
|
1352
|
-
method:
|
|
1353
|
-
headers: {
|
|
1354
|
-
body: JSON.stringify(createSessionBody)
|
|
1355
|
-
}
|
|
1356
|
-
}
|
|
1456
|
+
method: 'POST',
|
|
1457
|
+
headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },
|
|
1458
|
+
body: JSON.stringify(createSessionBody)
|
|
1459
|
+
}
|
|
1460
|
+
);}
|
|
1461
|
+
|
|
1462
|
+
|
|
1357
1463
|
|
|
1358
|
-
export const getQuerySessionsUrl = (params: QuerySessionsParams) => {
|
|
1464
|
+
export const getQuerySessionsUrl = (params: QuerySessionsParams,) => {
|
|
1359
1465
|
const normalizedParams = new URLSearchParams();
|
|
1360
1466
|
|
|
1361
1467
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
1468
|
+
|
|
1362
1469
|
if (value !== undefined) {
|
|
1363
|
-
normalizedParams.append(key, value === null ?
|
|
1470
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
1364
1471
|
}
|
|
1365
1472
|
});
|
|
1366
1473
|
|
|
1367
1474
|
const stringifiedParams = normalizedParams.toString();
|
|
1368
1475
|
|
|
1369
|
-
return stringifiedParams.length > 0
|
|
1370
|
-
|
|
1371
|
-
: `${getProxyPath()}/sessions/query`;
|
|
1372
|
-
};
|
|
1476
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/sessions/query?${stringifiedParams}` : `${getProxyPath()}/sessions/query`
|
|
1477
|
+
}
|
|
1373
1478
|
|
|
1374
1479
|
/**
|
|
1375
1480
|
* Returns the sessions of a project, paginated with a cursor.
|
|
@@ -1377,22 +1482,15 @@ export const getQuerySessionsUrl = (params: QuerySessionsParams) => {
|
|
|
1377
1482
|
* Requires `session.read` permission.
|
|
1378
1483
|
* @summary Query sessions
|
|
1379
1484
|
*/
|
|
1380
|
-
export const querySessions = async (
|
|
1381
|
-
|
|
1382
|
-
|
|
1383
|
-
|
|
1384
|
-
): Promise<QuerySessions200> => {
|
|
1385
|
-
const getHeaders = (
|
|
1386
|
-
h?: NonNullable<RequestInit["headers"]>,
|
|
1387
|
-
): Record<string, string | readonly string[]> => {
|
|
1485
|
+
export const querySessions = async (querySessionsBody: QuerySessionsBody,
|
|
1486
|
+
params: QuerySessionsParams, options?: Parameters<typeof customFetch>[1]): Promise<QuerySessions200> => {
|
|
1487
|
+
|
|
1488
|
+
const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {
|
|
1388
1489
|
if (!h) return {};
|
|
1389
1490
|
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1390
1491
|
if (Symbol.iterator in h) {
|
|
1391
1492
|
return Object.fromEntries(
|
|
1392
|
-
Array.from(
|
|
1393
|
-
h as Iterable<Iterable<string>>,
|
|
1394
|
-
(entry) => Array.from(entry) as [string, string],
|
|
1395
|
-
),
|
|
1493
|
+
Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),
|
|
1396
1494
|
);
|
|
1397
1495
|
}
|
|
1398
1496
|
const headers: Record<string, string | readonly string[]> = {};
|
|
@@ -1401,29 +1499,31 @@ export const querySessions = async (
|
|
|
1401
1499
|
}
|
|
1402
1500
|
return headers;
|
|
1403
1501
|
};
|
|
1404
|
-
|
|
1502
|
+
return customFetch<QuerySessions200>(getQuerySessionsUrl(params),
|
|
1503
|
+
{
|
|
1405
1504
|
...options,
|
|
1406
|
-
method:
|
|
1407
|
-
headers: {
|
|
1408
|
-
body: JSON.stringify(querySessionsBody)
|
|
1409
|
-
}
|
|
1410
|
-
}
|
|
1505
|
+
method: 'POST',
|
|
1506
|
+
headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },
|
|
1507
|
+
body: JSON.stringify(querySessionsBody)
|
|
1508
|
+
}
|
|
1509
|
+
);}
|
|
1510
|
+
|
|
1511
|
+
|
|
1411
1512
|
|
|
1412
|
-
export const getExchangeHandoffUrl = (params: ExchangeHandoffParams) => {
|
|
1513
|
+
export const getExchangeHandoffUrl = (params: ExchangeHandoffParams,) => {
|
|
1413
1514
|
const normalizedParams = new URLSearchParams();
|
|
1414
1515
|
|
|
1415
1516
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
1517
|
+
|
|
1416
1518
|
if (value !== undefined) {
|
|
1417
|
-
normalizedParams.append(key, value === null ?
|
|
1519
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
1418
1520
|
}
|
|
1419
1521
|
});
|
|
1420
1522
|
|
|
1421
1523
|
const stringifiedParams = normalizedParams.toString();
|
|
1422
1524
|
|
|
1423
|
-
return stringifiedParams.length > 0
|
|
1424
|
-
|
|
1425
|
-
: `${getProxyPath()}/sessions/exchange`;
|
|
1426
|
-
};
|
|
1525
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/sessions/exchange?${stringifiedParams}` : `${getProxyPath()}/sessions/exchange`
|
|
1526
|
+
}
|
|
1427
1527
|
|
|
1428
1528
|
/**
|
|
1429
1529
|
* Consumes a one-time `handoff_token` minted by `POST /auth_attempts/{id}/handoff`
|
|
@@ -1445,22 +1545,15 @@ export const getExchangeHandoffUrl = (params: ExchangeHandoffParams) => {
|
|
|
1445
1545
|
* Requires a project service key (OAuth2 client credentials).
|
|
1446
1546
|
* @summary Exchange handoff token for a session
|
|
1447
1547
|
*/
|
|
1448
|
-
export const exchangeHandoff = async (
|
|
1449
|
-
|
|
1450
|
-
|
|
1451
|
-
|
|
1452
|
-
): Promise<ExchangeHandoff200> => {
|
|
1453
|
-
const getHeaders = (
|
|
1454
|
-
h?: NonNullable<RequestInit["headers"]>,
|
|
1455
|
-
): Record<string, string | readonly string[]> => {
|
|
1548
|
+
export const exchangeHandoff = async (exchangeHandoffBody: ExchangeHandoffBody,
|
|
1549
|
+
params: ExchangeHandoffParams, options?: Parameters<typeof customFetch>[1]): Promise<ExchangeHandoff200> => {
|
|
1550
|
+
|
|
1551
|
+
const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {
|
|
1456
1552
|
if (!h) return {};
|
|
1457
1553
|
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1458
1554
|
if (Symbol.iterator in h) {
|
|
1459
1555
|
return Object.fromEntries(
|
|
1460
|
-
Array.from(
|
|
1461
|
-
h as Iterable<Iterable<string>>,
|
|
1462
|
-
(entry) => Array.from(entry) as [string, string],
|
|
1463
|
-
),
|
|
1556
|
+
Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),
|
|
1464
1557
|
);
|
|
1465
1558
|
}
|
|
1466
1559
|
const headers: Record<string, string | readonly string[]> = {};
|
|
@@ -1469,17 +1562,24 @@ export const exchangeHandoff = async (
|
|
|
1469
1562
|
}
|
|
1470
1563
|
return headers;
|
|
1471
1564
|
};
|
|
1472
|
-
|
|
1565
|
+
return customFetch<ExchangeHandoff200>(getExchangeHandoffUrl(params),
|
|
1566
|
+
{
|
|
1473
1567
|
...options,
|
|
1474
|
-
method:
|
|
1475
|
-
headers: {
|
|
1476
|
-
body: JSON.stringify(exchangeHandoffBody)
|
|
1477
|
-
}
|
|
1478
|
-
}
|
|
1568
|
+
method: 'POST',
|
|
1569
|
+
headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },
|
|
1570
|
+
body: JSON.stringify(exchangeHandoffBody)
|
|
1571
|
+
}
|
|
1572
|
+
);}
|
|
1573
|
+
|
|
1574
|
+
|
|
1479
1575
|
|
|
1480
|
-
export const getGetSessionUrl = (sessionId: string) => {
|
|
1481
|
-
|
|
1482
|
-
|
|
1576
|
+
export const getGetSessionUrl = (sessionId: string,) => {
|
|
1577
|
+
|
|
1578
|
+
|
|
1579
|
+
|
|
1580
|
+
|
|
1581
|
+
return `${getProxyPath()}/sessions/${encodeURIComponent(String(sessionId))}`
|
|
1582
|
+
}
|
|
1483
1583
|
|
|
1484
1584
|
/**
|
|
1485
1585
|
* Returns the current state of a session including its factors and all currently
|
|
@@ -1490,19 +1590,26 @@ export const getGetSessionUrl = (sessionId: string) => {
|
|
|
1490
1590
|
* against the same `session_id`) to restore a dropped assurance level.
|
|
1491
1591
|
* @summary Get session state
|
|
1492
1592
|
*/
|
|
1493
|
-
export const getSession = async (
|
|
1494
|
-
|
|
1495
|
-
|
|
1496
|
-
|
|
1497
|
-
return customFetch<GetSession200>(getGetSessionUrl(sessionId), {
|
|
1593
|
+
export const getSession = async (sessionId: string, options?: Parameters<typeof customFetch>[1]): Promise<GetSession200> => {
|
|
1594
|
+
|
|
1595
|
+
return customFetch<GetSession200>(getGetSessionUrl(sessionId),
|
|
1596
|
+
{
|
|
1498
1597
|
...options,
|
|
1499
|
-
method:
|
|
1500
|
-
|
|
1501
|
-
|
|
1598
|
+
method: 'GET'
|
|
1599
|
+
|
|
1600
|
+
|
|
1601
|
+
}
|
|
1602
|
+
);}
|
|
1603
|
+
|
|
1604
|
+
|
|
1605
|
+
|
|
1606
|
+
export const getRevokeSessionUrl = (sessionId: string,) => {
|
|
1502
1607
|
|
|
1503
|
-
|
|
1504
|
-
|
|
1505
|
-
|
|
1608
|
+
|
|
1609
|
+
|
|
1610
|
+
|
|
1611
|
+
return `${getProxyPath()}/sessions/${encodeURIComponent(String(sessionId))}`
|
|
1612
|
+
}
|
|
1506
1613
|
|
|
1507
1614
|
/**
|
|
1508
1615
|
* Permanently deletes the session, terminating it immediately.
|
|
@@ -1516,19 +1623,26 @@ export const getRevokeSessionUrl = (sessionId: string) => {
|
|
|
1516
1623
|
* invalidated.
|
|
1517
1624
|
* @summary Revoke session
|
|
1518
1625
|
*/
|
|
1519
|
-
export const revokeSession = async (
|
|
1520
|
-
|
|
1521
|
-
|
|
1522
|
-
|
|
1523
|
-
return customFetch<void>(getRevokeSessionUrl(sessionId), {
|
|
1626
|
+
export const revokeSession = async (sessionId: string, options?: Parameters<typeof customFetch>[1]): Promise<void> => {
|
|
1627
|
+
|
|
1628
|
+
return customFetch<void>(getRevokeSessionUrl(sessionId),
|
|
1629
|
+
{
|
|
1524
1630
|
...options,
|
|
1525
|
-
method:
|
|
1526
|
-
|
|
1527
|
-
|
|
1631
|
+
method: 'DELETE'
|
|
1632
|
+
|
|
1633
|
+
|
|
1634
|
+
}
|
|
1635
|
+
);}
|
|
1636
|
+
|
|
1637
|
+
|
|
1528
1638
|
|
|
1529
1639
|
export const getGetMySessionUrl = () => {
|
|
1530
|
-
|
|
1531
|
-
|
|
1640
|
+
|
|
1641
|
+
|
|
1642
|
+
|
|
1643
|
+
|
|
1644
|
+
return `${getProxyPath()}/sessions/me`
|
|
1645
|
+
}
|
|
1532
1646
|
|
|
1533
1647
|
/**
|
|
1534
1648
|
* Returns the current state of the current session including its factors and all currently
|
|
@@ -1539,18 +1653,26 @@ export const getGetMySessionUrl = () => {
|
|
|
1539
1653
|
* against the same `session_id`) to restore a dropped assurance level.
|
|
1540
1654
|
* @summary Get my session state
|
|
1541
1655
|
*/
|
|
1542
|
-
export const getMySession = async (
|
|
1543
|
-
|
|
1544
|
-
|
|
1545
|
-
|
|
1656
|
+
export const getMySession = async ( options?: Parameters<typeof customFetch>[1]): Promise<GetMySession200> => {
|
|
1657
|
+
|
|
1658
|
+
return customFetch<GetMySession200>(getGetMySessionUrl(),
|
|
1659
|
+
{
|
|
1546
1660
|
...options,
|
|
1547
|
-
method:
|
|
1548
|
-
|
|
1549
|
-
|
|
1661
|
+
method: 'GET'
|
|
1662
|
+
|
|
1663
|
+
|
|
1664
|
+
}
|
|
1665
|
+
);}
|
|
1666
|
+
|
|
1667
|
+
|
|
1550
1668
|
|
|
1551
1669
|
export const getRevokeMySessionUrl = () => {
|
|
1552
|
-
|
|
1553
|
-
|
|
1670
|
+
|
|
1671
|
+
|
|
1672
|
+
|
|
1673
|
+
|
|
1674
|
+
return `${getProxyPath()}/sessions/me`
|
|
1675
|
+
}
|
|
1554
1676
|
|
|
1555
1677
|
/**
|
|
1556
1678
|
* Logs out by permanently deleting the session.
|
|
@@ -1561,30 +1683,64 @@ export const getRevokeMySessionUrl = () => {
|
|
|
1561
1683
|
* cookie itself is cleared in the response.
|
|
1562
1684
|
* @summary Revoke my session
|
|
1563
1685
|
*/
|
|
1564
|
-
export const revokeMySession = async (
|
|
1565
|
-
|
|
1566
|
-
|
|
1567
|
-
|
|
1686
|
+
export const revokeMySession = async ( options?: Parameters<typeof customFetch>[1]): Promise<void> => {
|
|
1687
|
+
|
|
1688
|
+
return customFetch<void>(getRevokeMySessionUrl(),
|
|
1689
|
+
{
|
|
1690
|
+
...options,
|
|
1691
|
+
method: 'DELETE'
|
|
1692
|
+
|
|
1693
|
+
|
|
1694
|
+
}
|
|
1695
|
+
);}
|
|
1696
|
+
|
|
1697
|
+
|
|
1698
|
+
|
|
1699
|
+
export const getGetMySessionCsrfTokenUrl = () => {
|
|
1700
|
+
|
|
1701
|
+
|
|
1702
|
+
|
|
1703
|
+
|
|
1704
|
+
return `${getProxyPath()}/sessions/me/csrf`
|
|
1705
|
+
}
|
|
1706
|
+
|
|
1707
|
+
/**
|
|
1708
|
+
* Returns the session-bound token for cross-site request forgery protection
|
|
1709
|
+
* (ADR 053 §5). Browser code sends it in the `X-Zitadel-CSRF` header on the
|
|
1710
|
+
* state-changing requests the session cookie authenticates that require it
|
|
1711
|
+
* — see the `nextgenSession` scheme. It authorizes nothing on its own: the
|
|
1712
|
+
* HttpOnly cookie is still the credential, and a cross-site page cannot
|
|
1713
|
+
* read this response. It stays the same for the life of the session, so a
|
|
1714
|
+
* client fetches it once per session.
|
|
1715
|
+
* @summary Get my session's CSRF token
|
|
1716
|
+
*/
|
|
1717
|
+
export const getMySessionCsrfToken = async ( options?: Parameters<typeof customFetch>[1]): Promise<GetMySessionCsrfToken200> => {
|
|
1718
|
+
|
|
1719
|
+
return customFetch<GetMySessionCsrfToken200>(getGetMySessionCsrfTokenUrl(),
|
|
1720
|
+
{
|
|
1568
1721
|
...options,
|
|
1569
|
-
method:
|
|
1570
|
-
|
|
1571
|
-
|
|
1722
|
+
method: 'GET'
|
|
1723
|
+
|
|
1724
|
+
|
|
1725
|
+
}
|
|
1726
|
+
);}
|
|
1727
|
+
|
|
1728
|
+
|
|
1572
1729
|
|
|
1573
|
-
export const getCreateSchemaUrl = (params: CreateSchemaParams) => {
|
|
1730
|
+
export const getCreateSchemaUrl = (params: CreateSchemaParams,) => {
|
|
1574
1731
|
const normalizedParams = new URLSearchParams();
|
|
1575
1732
|
|
|
1576
1733
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
1734
|
+
|
|
1577
1735
|
if (value !== undefined) {
|
|
1578
|
-
normalizedParams.append(key, value === null ?
|
|
1736
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
1579
1737
|
}
|
|
1580
1738
|
});
|
|
1581
1739
|
|
|
1582
1740
|
const stringifiedParams = normalizedParams.toString();
|
|
1583
1741
|
|
|
1584
|
-
return stringifiedParams.length > 0
|
|
1585
|
-
|
|
1586
|
-
: `${getProxyPath()}/schemas`;
|
|
1587
|
-
};
|
|
1742
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/schemas?${stringifiedParams}` : `${getProxyPath()}/schemas`
|
|
1743
|
+
}
|
|
1588
1744
|
|
|
1589
1745
|
/**
|
|
1590
1746
|
* Create a new schema. The optional `$id` field is the JSON Schema document
|
|
@@ -1598,22 +1754,15 @@ export const getCreateSchemaUrl = (params: CreateSchemaParams) => {
|
|
|
1598
1754
|
* schema-url which will be resolved by the server.
|
|
1599
1755
|
* @summary Create new schema
|
|
1600
1756
|
*/
|
|
1601
|
-
export const createSchema = async (
|
|
1602
|
-
|
|
1603
|
-
|
|
1604
|
-
|
|
1605
|
-
): Promise<CreateSchema201> => {
|
|
1606
|
-
const getHeaders = (
|
|
1607
|
-
h?: NonNullable<RequestInit["headers"]>,
|
|
1608
|
-
): Record<string, string | readonly string[]> => {
|
|
1757
|
+
export const createSchema = async (createSchemaBody: CreateSchemaBody,
|
|
1758
|
+
params: CreateSchemaParams, options?: Parameters<typeof customFetch>[1]): Promise<CreateSchema201> => {
|
|
1759
|
+
|
|
1760
|
+
const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {
|
|
1609
1761
|
if (!h) return {};
|
|
1610
1762
|
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1611
1763
|
if (Symbol.iterator in h) {
|
|
1612
1764
|
return Object.fromEntries(
|
|
1613
|
-
Array.from(
|
|
1614
|
-
h as Iterable<Iterable<string>>,
|
|
1615
|
-
(entry) => Array.from(entry) as [string, string],
|
|
1616
|
-
),
|
|
1765
|
+
Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),
|
|
1617
1766
|
);
|
|
1618
1767
|
}
|
|
1619
1768
|
const headers: Record<string, string | readonly string[]> = {};
|
|
@@ -1622,60 +1771,65 @@ export const createSchema = async (
|
|
|
1622
1771
|
}
|
|
1623
1772
|
return headers;
|
|
1624
1773
|
};
|
|
1625
|
-
|
|
1774
|
+
return customFetch<CreateSchema201>(getCreateSchemaUrl(params),
|
|
1775
|
+
{
|
|
1626
1776
|
...options,
|
|
1627
|
-
method:
|
|
1628
|
-
headers: {
|
|
1629
|
-
body: JSON.stringify(createSchemaBody)
|
|
1630
|
-
}
|
|
1631
|
-
}
|
|
1777
|
+
method: 'POST',
|
|
1778
|
+
headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },
|
|
1779
|
+
body: JSON.stringify(createSchemaBody)
|
|
1780
|
+
}
|
|
1781
|
+
);}
|
|
1782
|
+
|
|
1632
1783
|
|
|
1633
|
-
|
|
1784
|
+
|
|
1785
|
+
export const getListSchemasUrl = (params: ListSchemasParams,) => {
|
|
1634
1786
|
const normalizedParams = new URLSearchParams();
|
|
1635
1787
|
|
|
1636
1788
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
1789
|
+
|
|
1637
1790
|
if (value !== undefined) {
|
|
1638
|
-
normalizedParams.append(key, value === null ?
|
|
1791
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
1639
1792
|
}
|
|
1640
1793
|
});
|
|
1641
1794
|
|
|
1642
1795
|
const stringifiedParams = normalizedParams.toString();
|
|
1643
1796
|
|
|
1644
|
-
return stringifiedParams.length > 0
|
|
1645
|
-
|
|
1646
|
-
: `${getProxyPath()}/schemas`;
|
|
1647
|
-
};
|
|
1797
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/schemas?${stringifiedParams}` : `${getProxyPath()}/schemas`
|
|
1798
|
+
}
|
|
1648
1799
|
|
|
1649
1800
|
/**
|
|
1650
1801
|
* Retrieve a list of all schemas available in the system. This endpoint
|
|
1651
1802
|
* supports pagination and filtering based on schema attributes.
|
|
1652
1803
|
* @summary List all schemas
|
|
1653
1804
|
*/
|
|
1654
|
-
export const listSchemas = async (
|
|
1655
|
-
|
|
1656
|
-
|
|
1657
|
-
|
|
1658
|
-
return customFetch<ListSchemas200>(getListSchemasUrl(params), {
|
|
1805
|
+
export const listSchemas = async (params: ListSchemasParams, options?: Parameters<typeof customFetch>[1]): Promise<ListSchemas200> => {
|
|
1806
|
+
|
|
1807
|
+
return customFetch<ListSchemas200>(getListSchemasUrl(params),
|
|
1808
|
+
{
|
|
1659
1809
|
...options,
|
|
1660
|
-
method:
|
|
1661
|
-
});
|
|
1662
|
-
};
|
|
1810
|
+
method: 'GET'
|
|
1663
1811
|
|
|
1664
|
-
|
|
1812
|
+
|
|
1813
|
+
}
|
|
1814
|
+
);}
|
|
1815
|
+
|
|
1816
|
+
|
|
1817
|
+
|
|
1818
|
+
export const getGetSchemaByIdUrl = (id: string,
|
|
1819
|
+
params?: GetSchemaByIdParams,) => {
|
|
1665
1820
|
const normalizedParams = new URLSearchParams();
|
|
1666
1821
|
|
|
1667
1822
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
1823
|
+
|
|
1668
1824
|
if (value !== undefined) {
|
|
1669
|
-
normalizedParams.append(key, value === null ?
|
|
1825
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
1670
1826
|
}
|
|
1671
1827
|
});
|
|
1672
1828
|
|
|
1673
1829
|
const stringifiedParams = normalizedParams.toString();
|
|
1674
1830
|
|
|
1675
|
-
return stringifiedParams.length > 0
|
|
1676
|
-
|
|
1677
|
-
: `${getProxyPath()}/schemas/${encodeURIComponent(String(id))}`;
|
|
1678
|
-
};
|
|
1831
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/schemas/${encodeURIComponent(String(id))}?${stringifiedParams}` : `${getProxyPath()}/schemas/${encodeURIComponent(String(id))}`
|
|
1832
|
+
}
|
|
1679
1833
|
|
|
1680
1834
|
/**
|
|
1681
1835
|
* Get a schema by its ID. A schema ID identifies one immutable revision, so
|
|
@@ -1690,20 +1844,27 @@ export const getGetSchemaByIdUrl = (id: string, params?: GetSchemaByIdParams) =>
|
|
|
1690
1844
|
* own project and ignores `project_id`.
|
|
1691
1845
|
* @summary Get schema by ID
|
|
1692
1846
|
*/
|
|
1693
|
-
export const getSchemaById = async (
|
|
1694
|
-
|
|
1695
|
-
|
|
1696
|
-
|
|
1697
|
-
|
|
1698
|
-
return customFetch<GetSchemaById200>(getGetSchemaByIdUrl(id, params), {
|
|
1847
|
+
export const getSchemaById = async (id: string,
|
|
1848
|
+
params?: GetSchemaByIdParams, options?: Parameters<typeof customFetch>[1]): Promise<GetSchemaById200> => {
|
|
1849
|
+
|
|
1850
|
+
return customFetch<GetSchemaById200>(getGetSchemaByIdUrl(id,params),
|
|
1851
|
+
{
|
|
1699
1852
|
...options,
|
|
1700
|
-
method:
|
|
1701
|
-
|
|
1702
|
-
|
|
1853
|
+
method: 'GET'
|
|
1854
|
+
|
|
1855
|
+
|
|
1856
|
+
}
|
|
1857
|
+
);}
|
|
1858
|
+
|
|
1859
|
+
|
|
1703
1860
|
|
|
1704
1861
|
export const getCreateFlowDefinitionUrl = () => {
|
|
1705
|
-
|
|
1706
|
-
|
|
1862
|
+
|
|
1863
|
+
|
|
1864
|
+
|
|
1865
|
+
|
|
1866
|
+
return `${getProxyPath()}/flow_definitions`
|
|
1867
|
+
}
|
|
1707
1868
|
|
|
1708
1869
|
/**
|
|
1709
1870
|
* Publishes a new flow definition revision.
|
|
@@ -1718,21 +1879,14 @@ export const getCreateFlowDefinitionUrl = () => {
|
|
|
1718
1879
|
* flow's revisions, newest by creation time first.
|
|
1719
1880
|
* @summary Create a new flow definition
|
|
1720
1881
|
*/
|
|
1721
|
-
export const createFlowDefinition = async (
|
|
1722
|
-
|
|
1723
|
-
|
|
1724
|
-
): Promise<CreateFlowDefinition201> => {
|
|
1725
|
-
const getHeaders = (
|
|
1726
|
-
h?: NonNullable<RequestInit["headers"]>,
|
|
1727
|
-
): Record<string, string | readonly string[]> => {
|
|
1882
|
+
export const createFlowDefinition = async (createFlowDefinitionBody: CreateFlowDefinitionBody, options?: Parameters<typeof customFetch>[1]): Promise<CreateFlowDefinition201> => {
|
|
1883
|
+
|
|
1884
|
+
const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {
|
|
1728
1885
|
if (!h) return {};
|
|
1729
1886
|
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1730
1887
|
if (Symbol.iterator in h) {
|
|
1731
1888
|
return Object.fromEntries(
|
|
1732
|
-
Array.from(
|
|
1733
|
-
h as Iterable<Iterable<string>>,
|
|
1734
|
-
(entry) => Array.from(entry) as [string, string],
|
|
1735
|
-
),
|
|
1889
|
+
Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),
|
|
1736
1890
|
);
|
|
1737
1891
|
}
|
|
1738
1892
|
const headers: Record<string, string | readonly string[]> = {};
|
|
@@ -1741,15 +1895,18 @@ export const createFlowDefinition = async (
|
|
|
1741
1895
|
}
|
|
1742
1896
|
return headers;
|
|
1743
1897
|
};
|
|
1744
|
-
|
|
1898
|
+
return customFetch<CreateFlowDefinition201>(getCreateFlowDefinitionUrl(),
|
|
1899
|
+
{
|
|
1745
1900
|
...options,
|
|
1746
|
-
method:
|
|
1747
|
-
headers: {
|
|
1748
|
-
body: JSON.stringify(createFlowDefinitionBody)
|
|
1749
|
-
}
|
|
1750
|
-
}
|
|
1901
|
+
method: 'POST',
|
|
1902
|
+
headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },
|
|
1903
|
+
body: JSON.stringify(createFlowDefinitionBody)
|
|
1904
|
+
}
|
|
1905
|
+
);}
|
|
1906
|
+
|
|
1751
1907
|
|
|
1752
|
-
|
|
1908
|
+
|
|
1909
|
+
export const getListFlowDefinitionsUrl = (params: ListFlowDefinitionsParams,) => {
|
|
1753
1910
|
const normalizedParams = new URLSearchParams();
|
|
1754
1911
|
|
|
1755
1912
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
@@ -1757,22 +1914,20 @@ export const getListFlowDefinitionsUrl = (params: ListFlowDefinitionsParams) =>
|
|
|
1757
1914
|
|
|
1758
1915
|
if (Array.isArray(value) && explodeParameters.includes(key)) {
|
|
1759
1916
|
value.forEach((v) => {
|
|
1760
|
-
normalizedParams.append(key, v === null ?
|
|
1917
|
+
normalizedParams.append(key, v === null ? 'null' : String(v));
|
|
1761
1918
|
});
|
|
1762
1919
|
return;
|
|
1763
1920
|
}
|
|
1764
1921
|
|
|
1765
1922
|
if (value !== undefined) {
|
|
1766
|
-
normalizedParams.append(key, value === null ?
|
|
1923
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
1767
1924
|
}
|
|
1768
1925
|
});
|
|
1769
1926
|
|
|
1770
1927
|
const stringifiedParams = normalizedParams.toString();
|
|
1771
1928
|
|
|
1772
|
-
return stringifiedParams.length > 0
|
|
1773
|
-
|
|
1774
|
-
: `${getProxyPath()}/flow_definitions`;
|
|
1775
|
-
};
|
|
1929
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/flow_definitions?${stringifiedParams}` : `${getProxyPath()}/flow_definitions`
|
|
1930
|
+
}
|
|
1776
1931
|
|
|
1777
1932
|
/**
|
|
1778
1933
|
* Retrieves a list of all flow definitions, newest by creation time first.
|
|
@@ -1780,69 +1935,71 @@ export const getListFlowDefinitionsUrl = (params: ListFlowDefinitionsParams) =>
|
|
|
1780
1935
|
* Filter by `name` to list the revisions of one flow.
|
|
1781
1936
|
* @summary List flow definitions
|
|
1782
1937
|
*/
|
|
1783
|
-
export const listFlowDefinitions = async (
|
|
1784
|
-
|
|
1785
|
-
|
|
1786
|
-
|
|
1787
|
-
return customFetch<ListFlowDefinitions200>(getListFlowDefinitionsUrl(params), {
|
|
1938
|
+
export const listFlowDefinitions = async (params: ListFlowDefinitionsParams, options?: Parameters<typeof customFetch>[1]): Promise<ListFlowDefinitions200> => {
|
|
1939
|
+
|
|
1940
|
+
return customFetch<ListFlowDefinitions200>(getListFlowDefinitionsUrl(params),
|
|
1941
|
+
{
|
|
1788
1942
|
...options,
|
|
1789
|
-
method:
|
|
1790
|
-
|
|
1791
|
-
|
|
1943
|
+
method: 'GET'
|
|
1944
|
+
|
|
1945
|
+
|
|
1946
|
+
}
|
|
1947
|
+
);}
|
|
1948
|
+
|
|
1792
1949
|
|
|
1793
|
-
|
|
1794
|
-
|
|
1795
|
-
|
|
1950
|
+
|
|
1951
|
+
export const getGetFlowDefinitionUrl = (id: string,) => {
|
|
1952
|
+
|
|
1953
|
+
|
|
1954
|
+
|
|
1955
|
+
|
|
1956
|
+
return `${getProxyPath()}/flow_definitions/${encodeURIComponent(String(id))}`
|
|
1957
|
+
}
|
|
1796
1958
|
|
|
1797
1959
|
/**
|
|
1798
1960
|
* Get a flow definition by id
|
|
1799
1961
|
* @summary Get a flow definition by id
|
|
1800
1962
|
*/
|
|
1801
|
-
export const getFlowDefinition = async (
|
|
1802
|
-
|
|
1803
|
-
|
|
1804
|
-
|
|
1805
|
-
return customFetch<GetFlowDefinition200>(getGetFlowDefinitionUrl(id), {
|
|
1963
|
+
export const getFlowDefinition = async (id: string, options?: Parameters<typeof customFetch>[1]): Promise<GetFlowDefinition200> => {
|
|
1964
|
+
|
|
1965
|
+
return customFetch<GetFlowDefinition200>(getGetFlowDefinitionUrl(id),
|
|
1966
|
+
{
|
|
1806
1967
|
...options,
|
|
1807
|
-
method:
|
|
1808
|
-
|
|
1809
|
-
};
|
|
1968
|
+
method: 'GET'
|
|
1969
|
+
|
|
1810
1970
|
|
|
1811
|
-
|
|
1971
|
+
}
|
|
1972
|
+
);}
|
|
1973
|
+
|
|
1974
|
+
|
|
1975
|
+
|
|
1976
|
+
export const getCreateTeamUrl = (params: CreateTeamParams,) => {
|
|
1812
1977
|
const normalizedParams = new URLSearchParams();
|
|
1813
1978
|
|
|
1814
1979
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
1980
|
+
|
|
1815
1981
|
if (value !== undefined) {
|
|
1816
|
-
normalizedParams.append(key, value === null ?
|
|
1982
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
1817
1983
|
}
|
|
1818
1984
|
});
|
|
1819
1985
|
|
|
1820
1986
|
const stringifiedParams = normalizedParams.toString();
|
|
1821
1987
|
|
|
1822
|
-
return stringifiedParams.length > 0
|
|
1823
|
-
|
|
1824
|
-
: `${getProxyPath()}/teams`;
|
|
1825
|
-
};
|
|
1988
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/teams?${stringifiedParams}` : `${getProxyPath()}/teams`
|
|
1989
|
+
}
|
|
1826
1990
|
|
|
1827
1991
|
/**
|
|
1828
1992
|
* @summary Create team
|
|
1829
1993
|
*/
|
|
1830
|
-
export const createTeam = async (
|
|
1831
|
-
|
|
1832
|
-
|
|
1833
|
-
|
|
1834
|
-
): Promise<CreateTeam201> => {
|
|
1835
|
-
const getHeaders = (
|
|
1836
|
-
h?: NonNullable<RequestInit["headers"]>,
|
|
1837
|
-
): Record<string, string | readonly string[]> => {
|
|
1994
|
+
export const createTeam = async (createTeamBody: CreateTeamBody,
|
|
1995
|
+
params: CreateTeamParams, options?: Parameters<typeof customFetch>[1]): Promise<CreateTeam201> => {
|
|
1996
|
+
|
|
1997
|
+
const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {
|
|
1838
1998
|
if (!h) return {};
|
|
1839
1999
|
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1840
2000
|
if (Symbol.iterator in h) {
|
|
1841
2001
|
return Object.fromEntries(
|
|
1842
|
-
Array.from(
|
|
1843
|
-
h as Iterable<Iterable<string>>,
|
|
1844
|
-
(entry) => Array.from(entry) as [string, string],
|
|
1845
|
-
),
|
|
2002
|
+
Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),
|
|
1846
2003
|
);
|
|
1847
2004
|
}
|
|
1848
2005
|
const headers: Record<string, string | readonly string[]> = {};
|
|
@@ -1851,50 +2008,45 @@ export const createTeam = async (
|
|
|
1851
2008
|
}
|
|
1852
2009
|
return headers;
|
|
1853
2010
|
};
|
|
1854
|
-
|
|
2011
|
+
return customFetch<CreateTeam201>(getCreateTeamUrl(params),
|
|
2012
|
+
{
|
|
1855
2013
|
...options,
|
|
1856
|
-
method:
|
|
1857
|
-
headers: {
|
|
1858
|
-
body: JSON.stringify(createTeamBody)
|
|
1859
|
-
}
|
|
1860
|
-
}
|
|
2014
|
+
method: 'POST',
|
|
2015
|
+
headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },
|
|
2016
|
+
body: JSON.stringify(createTeamBody)
|
|
2017
|
+
}
|
|
2018
|
+
);}
|
|
2019
|
+
|
|
2020
|
+
|
|
1861
2021
|
|
|
1862
|
-
export const getQueryTeamsUrl = (params: QueryTeamsParams) => {
|
|
2022
|
+
export const getQueryTeamsUrl = (params: QueryTeamsParams,) => {
|
|
1863
2023
|
const normalizedParams = new URLSearchParams();
|
|
1864
2024
|
|
|
1865
2025
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2026
|
+
|
|
1866
2027
|
if (value !== undefined) {
|
|
1867
|
-
normalizedParams.append(key, value === null ?
|
|
2028
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
1868
2029
|
}
|
|
1869
2030
|
});
|
|
1870
2031
|
|
|
1871
2032
|
const stringifiedParams = normalizedParams.toString();
|
|
1872
2033
|
|
|
1873
|
-
return stringifiedParams.length > 0
|
|
1874
|
-
|
|
1875
|
-
: `${getProxyPath()}/teams/query`;
|
|
1876
|
-
};
|
|
2034
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/teams/query?${stringifiedParams}` : `${getProxyPath()}/teams/query`
|
|
2035
|
+
}
|
|
1877
2036
|
|
|
1878
2037
|
/**
|
|
1879
2038
|
* Returns the teams of a project, paginated with a cursor.
|
|
1880
2039
|
* @summary Query teams
|
|
1881
2040
|
*/
|
|
1882
|
-
export const queryTeams = async (
|
|
1883
|
-
|
|
1884
|
-
|
|
1885
|
-
|
|
1886
|
-
): Promise<QueryTeams200> => {
|
|
1887
|
-
const getHeaders = (
|
|
1888
|
-
h?: NonNullable<RequestInit["headers"]>,
|
|
1889
|
-
): Record<string, string | readonly string[]> => {
|
|
2041
|
+
export const queryTeams = async (queryTeamsBody: QueryTeamsBody,
|
|
2042
|
+
params: QueryTeamsParams, options?: Parameters<typeof customFetch>[1]): Promise<QueryTeams200> => {
|
|
2043
|
+
|
|
2044
|
+
const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {
|
|
1890
2045
|
if (!h) return {};
|
|
1891
2046
|
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1892
2047
|
if (Symbol.iterator in h) {
|
|
1893
2048
|
return Object.fromEntries(
|
|
1894
|
-
Array.from(
|
|
1895
|
-
h as Iterable<Iterable<string>>,
|
|
1896
|
-
(entry) => Array.from(entry) as [string, string],
|
|
1897
|
-
),
|
|
2049
|
+
Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),
|
|
1898
2050
|
);
|
|
1899
2051
|
}
|
|
1900
2052
|
const headers: Record<string, string | readonly string[]> = {};
|
|
@@ -1903,35 +2055,49 @@ export const queryTeams = async (
|
|
|
1903
2055
|
}
|
|
1904
2056
|
return headers;
|
|
1905
2057
|
};
|
|
1906
|
-
|
|
2058
|
+
return customFetch<QueryTeams200>(getQueryTeamsUrl(params),
|
|
2059
|
+
{
|
|
1907
2060
|
...options,
|
|
1908
|
-
method:
|
|
1909
|
-
headers: {
|
|
1910
|
-
body: JSON.stringify(queryTeamsBody)
|
|
1911
|
-
}
|
|
1912
|
-
}
|
|
2061
|
+
method: 'POST',
|
|
2062
|
+
headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },
|
|
2063
|
+
body: JSON.stringify(queryTeamsBody)
|
|
2064
|
+
}
|
|
2065
|
+
);}
|
|
2066
|
+
|
|
2067
|
+
|
|
2068
|
+
|
|
2069
|
+
export const getGetTeamUrl = (teamId: string,) => {
|
|
2070
|
+
|
|
2071
|
+
|
|
1913
2072
|
|
|
1914
|
-
|
|
1915
|
-
return `${getProxyPath()}/teams/${encodeURIComponent(String(teamId))}
|
|
1916
|
-
}
|
|
2073
|
+
|
|
2074
|
+
return `${getProxyPath()}/teams/${encodeURIComponent(String(teamId))}`
|
|
2075
|
+
}
|
|
1917
2076
|
|
|
1918
2077
|
/**
|
|
1919
2078
|
* Returns a Team by its id.
|
|
1920
2079
|
* @summary Get team
|
|
1921
2080
|
*/
|
|
1922
|
-
export const getTeam = async (
|
|
1923
|
-
|
|
1924
|
-
|
|
1925
|
-
|
|
1926
|
-
return customFetch<GetTeam200>(getGetTeamUrl(teamId), {
|
|
2081
|
+
export const getTeam = async (teamId: string, options?: Parameters<typeof customFetch>[1]): Promise<GetTeam200> => {
|
|
2082
|
+
|
|
2083
|
+
return customFetch<GetTeam200>(getGetTeamUrl(teamId),
|
|
2084
|
+
{
|
|
1927
2085
|
...options,
|
|
1928
|
-
method:
|
|
1929
|
-
|
|
1930
|
-
|
|
2086
|
+
method: 'GET'
|
|
2087
|
+
|
|
2088
|
+
|
|
2089
|
+
}
|
|
2090
|
+
);}
|
|
2091
|
+
|
|
2092
|
+
|
|
2093
|
+
|
|
2094
|
+
export const getDeleteTeamUrl = (teamId: string,) => {
|
|
1931
2095
|
|
|
1932
|
-
|
|
1933
|
-
|
|
1934
|
-
|
|
2096
|
+
|
|
2097
|
+
|
|
2098
|
+
|
|
2099
|
+
return `${getProxyPath()}/teams/${encodeURIComponent(String(teamId))}`
|
|
2100
|
+
}
|
|
1935
2101
|
|
|
1936
2102
|
/**
|
|
1937
2103
|
* Deactivates the team.
|
|
@@ -1949,40 +2115,40 @@ export const getDeleteTeamUrl = (teamId: string) => {
|
|
|
1949
2115
|
* so such a team cannot currently be deactivated through the API.
|
|
1950
2116
|
* @summary Delete team
|
|
1951
2117
|
*/
|
|
1952
|
-
export const deleteTeam = async (
|
|
1953
|
-
|
|
1954
|
-
|
|
1955
|
-
|
|
1956
|
-
return customFetch<void>(getDeleteTeamUrl(teamId), {
|
|
2118
|
+
export const deleteTeam = async (teamId: string, options?: Parameters<typeof customFetch>[1]): Promise<void> => {
|
|
2119
|
+
|
|
2120
|
+
return customFetch<void>(getDeleteTeamUrl(teamId),
|
|
2121
|
+
{
|
|
1957
2122
|
...options,
|
|
1958
|
-
method:
|
|
1959
|
-
|
|
1960
|
-
|
|
2123
|
+
method: 'DELETE'
|
|
2124
|
+
|
|
2125
|
+
|
|
2126
|
+
}
|
|
2127
|
+
);}
|
|
2128
|
+
|
|
1961
2129
|
|
|
1962
|
-
|
|
1963
|
-
|
|
1964
|
-
|
|
2130
|
+
|
|
2131
|
+
export const getUpdateTeamUrl = (teamId: string,) => {
|
|
2132
|
+
|
|
2133
|
+
|
|
2134
|
+
|
|
2135
|
+
|
|
2136
|
+
return `${getProxyPath()}/teams/${encodeURIComponent(String(teamId))}`
|
|
2137
|
+
}
|
|
1965
2138
|
|
|
1966
2139
|
/**
|
|
1967
2140
|
* Update team. Only active teams can be updated.
|
|
1968
2141
|
* @summary Update team
|
|
1969
2142
|
*/
|
|
1970
|
-
export const updateTeam = async (
|
|
1971
|
-
|
|
1972
|
-
|
|
1973
|
-
|
|
1974
|
-
): Promise<UpdateTeam200> => {
|
|
1975
|
-
const getHeaders = (
|
|
1976
|
-
h?: NonNullable<RequestInit["headers"]>,
|
|
1977
|
-
): Record<string, string | readonly string[]> => {
|
|
2143
|
+
export const updateTeam = async (teamId: string,
|
|
2144
|
+
updateTeamBody: UpdateTeamBody, options?: Parameters<typeof customFetch>[1]): Promise<UpdateTeam200> => {
|
|
2145
|
+
|
|
2146
|
+
const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {
|
|
1978
2147
|
if (!h) return {};
|
|
1979
2148
|
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
1980
2149
|
if (Symbol.iterator in h) {
|
|
1981
2150
|
return Object.fromEntries(
|
|
1982
|
-
Array.from(
|
|
1983
|
-
h as Iterable<Iterable<string>>,
|
|
1984
|
-
(entry) => Array.from(entry) as [string, string],
|
|
1985
|
-
),
|
|
2151
|
+
Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),
|
|
1986
2152
|
);
|
|
1987
2153
|
}
|
|
1988
2154
|
const headers: Record<string, string | readonly string[]> = {};
|
|
@@ -1991,59 +2157,64 @@ export const updateTeam = async (
|
|
|
1991
2157
|
}
|
|
1992
2158
|
return headers;
|
|
1993
2159
|
};
|
|
1994
|
-
|
|
2160
|
+
return customFetch<UpdateTeam200>(getUpdateTeamUrl(teamId),
|
|
2161
|
+
{
|
|
1995
2162
|
...options,
|
|
1996
|
-
method:
|
|
1997
|
-
headers: {
|
|
1998
|
-
body: JSON.stringify(updateTeamBody)
|
|
1999
|
-
}
|
|
2000
|
-
}
|
|
2163
|
+
method: 'PATCH',
|
|
2164
|
+
headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },
|
|
2165
|
+
body: JSON.stringify(updateTeamBody)
|
|
2166
|
+
}
|
|
2167
|
+
);}
|
|
2168
|
+
|
|
2001
2169
|
|
|
2002
|
-
|
|
2170
|
+
|
|
2171
|
+
export const getListEnvironmentsUrl = (params: ListEnvironmentsParams,) => {
|
|
2003
2172
|
const normalizedParams = new URLSearchParams();
|
|
2004
2173
|
|
|
2005
2174
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2175
|
+
|
|
2006
2176
|
if (value !== undefined) {
|
|
2007
|
-
normalizedParams.append(key, value === null ?
|
|
2177
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
2008
2178
|
}
|
|
2009
2179
|
});
|
|
2010
2180
|
|
|
2011
2181
|
const stringifiedParams = normalizedParams.toString();
|
|
2012
2182
|
|
|
2013
|
-
return stringifiedParams.length > 0
|
|
2014
|
-
|
|
2015
|
-
: `${getProxyPath()}/environments`;
|
|
2016
|
-
};
|
|
2183
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/environments?${stringifiedParams}` : `${getProxyPath()}/environments`
|
|
2184
|
+
}
|
|
2017
2185
|
|
|
2018
2186
|
/**
|
|
2019
2187
|
* Lists the project's environments ordered by name.
|
|
2020
2188
|
* @summary List environments
|
|
2021
2189
|
*/
|
|
2022
|
-
export const listEnvironments = async (
|
|
2023
|
-
|
|
2024
|
-
|
|
2025
|
-
|
|
2026
|
-
return customFetch<ListEnvironments200>(getListEnvironmentsUrl(params), {
|
|
2190
|
+
export const listEnvironments = async (params: ListEnvironmentsParams, options?: Parameters<typeof customFetch>[1]): Promise<ListEnvironments200> => {
|
|
2191
|
+
|
|
2192
|
+
return customFetch<ListEnvironments200>(getListEnvironmentsUrl(params),
|
|
2193
|
+
{
|
|
2027
2194
|
...options,
|
|
2028
|
-
method:
|
|
2029
|
-
|
|
2030
|
-
|
|
2195
|
+
method: 'GET'
|
|
2196
|
+
|
|
2197
|
+
|
|
2198
|
+
}
|
|
2199
|
+
);}
|
|
2200
|
+
|
|
2201
|
+
|
|
2031
2202
|
|
|
2032
|
-
export const getGetEnvironmentByNameUrl = (name: string,
|
|
2203
|
+
export const getGetEnvironmentByNameUrl = (name: string,
|
|
2204
|
+
params: GetEnvironmentByNameParams,) => {
|
|
2033
2205
|
const normalizedParams = new URLSearchParams();
|
|
2034
2206
|
|
|
2035
2207
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2208
|
+
|
|
2036
2209
|
if (value !== undefined) {
|
|
2037
|
-
normalizedParams.append(key, value === null ?
|
|
2210
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
2038
2211
|
}
|
|
2039
2212
|
});
|
|
2040
2213
|
|
|
2041
2214
|
const stringifiedParams = normalizedParams.toString();
|
|
2042
2215
|
|
|
2043
|
-
return stringifiedParams.length > 0
|
|
2044
|
-
|
|
2045
|
-
: `${getProxyPath()}/environments/${encodeURIComponent(String(name))}`;
|
|
2046
|
-
};
|
|
2216
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/environments/${encodeURIComponent(String(name))}?${stringifiedParams}` : `${getProxyPath()}/environments/${encodeURIComponent(String(name))}`
|
|
2217
|
+
}
|
|
2047
2218
|
|
|
2048
2219
|
/**
|
|
2049
2220
|
* Reads one environment of the project by its name.
|
|
@@ -2052,32 +2223,34 @@ export const getGetEnvironmentByNameUrl = (name: string, params: GetEnvironmentB
|
|
|
2052
2223
|
* another project answers `env.not_found` exactly as an unused name does.
|
|
2053
2224
|
* @summary Get an environment by name
|
|
2054
2225
|
*/
|
|
2055
|
-
export const getEnvironmentByName = async (
|
|
2056
|
-
|
|
2057
|
-
|
|
2058
|
-
|
|
2059
|
-
|
|
2060
|
-
return customFetch<GetEnvironmentByName200>(getGetEnvironmentByNameUrl(name, params), {
|
|
2226
|
+
export const getEnvironmentByName = async (name: string,
|
|
2227
|
+
params: GetEnvironmentByNameParams, options?: Parameters<typeof customFetch>[1]): Promise<GetEnvironmentByName200> => {
|
|
2228
|
+
|
|
2229
|
+
return customFetch<GetEnvironmentByName200>(getGetEnvironmentByNameUrl(name,params),
|
|
2230
|
+
{
|
|
2061
2231
|
...options,
|
|
2062
|
-
method:
|
|
2063
|
-
|
|
2064
|
-
};
|
|
2232
|
+
method: 'GET'
|
|
2233
|
+
|
|
2065
2234
|
|
|
2066
|
-
|
|
2235
|
+
}
|
|
2236
|
+
);}
|
|
2237
|
+
|
|
2238
|
+
|
|
2239
|
+
|
|
2240
|
+
export const getCreateBrandingUrl = (params: CreateBrandingParams,) => {
|
|
2067
2241
|
const normalizedParams = new URLSearchParams();
|
|
2068
2242
|
|
|
2069
2243
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2244
|
+
|
|
2070
2245
|
if (value !== undefined) {
|
|
2071
|
-
normalizedParams.append(key, value === null ?
|
|
2246
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
2072
2247
|
}
|
|
2073
2248
|
});
|
|
2074
2249
|
|
|
2075
2250
|
const stringifiedParams = normalizedParams.toString();
|
|
2076
2251
|
|
|
2077
|
-
return stringifiedParams.length > 0
|
|
2078
|
-
|
|
2079
|
-
: `${getProxyPath()}/branding`;
|
|
2080
|
-
};
|
|
2252
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/branding?${stringifiedParams}` : `${getProxyPath()}/branding`
|
|
2253
|
+
}
|
|
2081
2254
|
|
|
2082
2255
|
/**
|
|
2083
2256
|
* Publishes a new immutable branding revision for the project. Branding
|
|
@@ -2090,22 +2263,15 @@ export const getCreateBrandingUrl = (params: CreateBrandingParams) => {
|
|
|
2090
2263
|
* time via `zitadel plan` / `zitadel apply`.
|
|
2091
2264
|
* @summary Publish a new branding revision
|
|
2092
2265
|
*/
|
|
2093
|
-
export const createBranding = async (
|
|
2094
|
-
|
|
2095
|
-
|
|
2096
|
-
|
|
2097
|
-
): Promise<CreateBranding201> => {
|
|
2098
|
-
const getHeaders = (
|
|
2099
|
-
h?: NonNullable<RequestInit["headers"]>,
|
|
2100
|
-
): Record<string, string | readonly string[]> => {
|
|
2266
|
+
export const createBranding = async (createBrandingBody: CreateBrandingBody,
|
|
2267
|
+
params: CreateBrandingParams, options?: Parameters<typeof customFetch>[1]): Promise<CreateBranding201> => {
|
|
2268
|
+
|
|
2269
|
+
const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {
|
|
2101
2270
|
if (!h) return {};
|
|
2102
2271
|
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
2103
2272
|
if (Symbol.iterator in h) {
|
|
2104
2273
|
return Object.fromEntries(
|
|
2105
|
-
Array.from(
|
|
2106
|
-
h as Iterable<Iterable<string>>,
|
|
2107
|
-
(entry) => Array.from(entry) as [string, string],
|
|
2108
|
-
),
|
|
2274
|
+
Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),
|
|
2109
2275
|
);
|
|
2110
2276
|
}
|
|
2111
2277
|
const headers: Record<string, string | readonly string[]> = {};
|
|
@@ -2114,29 +2280,31 @@ export const createBranding = async (
|
|
|
2114
2280
|
}
|
|
2115
2281
|
return headers;
|
|
2116
2282
|
};
|
|
2117
|
-
|
|
2283
|
+
return customFetch<CreateBranding201>(getCreateBrandingUrl(params),
|
|
2284
|
+
{
|
|
2118
2285
|
...options,
|
|
2119
|
-
method:
|
|
2120
|
-
headers: {
|
|
2121
|
-
body: JSON.stringify(createBrandingBody)
|
|
2122
|
-
}
|
|
2123
|
-
}
|
|
2286
|
+
method: 'POST',
|
|
2287
|
+
headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },
|
|
2288
|
+
body: JSON.stringify(createBrandingBody)
|
|
2289
|
+
}
|
|
2290
|
+
);}
|
|
2291
|
+
|
|
2292
|
+
|
|
2124
2293
|
|
|
2125
|
-
export const getListBrandingUrl = (params: ListBrandingParams) => {
|
|
2294
|
+
export const getListBrandingUrl = (params: ListBrandingParams,) => {
|
|
2126
2295
|
const normalizedParams = new URLSearchParams();
|
|
2127
2296
|
|
|
2128
2297
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2298
|
+
|
|
2129
2299
|
if (value !== undefined) {
|
|
2130
|
-
normalizedParams.append(key, value === null ?
|
|
2300
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
2131
2301
|
}
|
|
2132
2302
|
});
|
|
2133
2303
|
|
|
2134
2304
|
const stringifiedParams = normalizedParams.toString();
|
|
2135
2305
|
|
|
2136
|
-
return stringifiedParams.length > 0
|
|
2137
|
-
|
|
2138
|
-
: `${getProxyPath()}/branding`;
|
|
2139
|
-
};
|
|
2306
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/branding?${stringifiedParams}` : `${getProxyPath()}/branding`
|
|
2307
|
+
}
|
|
2140
2308
|
|
|
2141
2309
|
/**
|
|
2142
2310
|
* Lists branding revisions for the project, newest first, capped at the
|
|
@@ -2146,49 +2314,58 @@ export const getListBrandingUrl = (params: ListBrandingParams) => {
|
|
|
2146
2314
|
* server ignores would be worse than none.
|
|
2147
2315
|
* @summary List branding revisions
|
|
2148
2316
|
*/
|
|
2149
|
-
export const listBranding = async (
|
|
2150
|
-
|
|
2151
|
-
|
|
2152
|
-
|
|
2153
|
-
return customFetch<ListBranding200Item[]>(getListBrandingUrl(params), {
|
|
2317
|
+
export const listBranding = async (params: ListBrandingParams, options?: Parameters<typeof customFetch>[1]): Promise<ListBranding200Item[]> => {
|
|
2318
|
+
|
|
2319
|
+
return customFetch<ListBranding200Item[]>(getListBrandingUrl(params),
|
|
2320
|
+
{
|
|
2154
2321
|
...options,
|
|
2155
|
-
method:
|
|
2156
|
-
|
|
2157
|
-
};
|
|
2322
|
+
method: 'GET'
|
|
2323
|
+
|
|
2158
2324
|
|
|
2159
|
-
|
|
2160
|
-
|
|
2161
|
-
|
|
2325
|
+
}
|
|
2326
|
+
);}
|
|
2327
|
+
|
|
2328
|
+
|
|
2329
|
+
|
|
2330
|
+
export const getGetBrandingByIdUrl = (id: string,) => {
|
|
2331
|
+
|
|
2332
|
+
|
|
2333
|
+
|
|
2334
|
+
|
|
2335
|
+
return `${getProxyPath()}/branding/${encodeURIComponent(String(id))}`
|
|
2336
|
+
}
|
|
2162
2337
|
|
|
2163
2338
|
/**
|
|
2164
2339
|
* Retrieves a single branding revision, including its stored configuration.
|
|
2165
2340
|
* @summary Get a branding revision by ID
|
|
2166
2341
|
*/
|
|
2167
|
-
export const getBrandingById = async (
|
|
2168
|
-
|
|
2169
|
-
|
|
2170
|
-
|
|
2171
|
-
return customFetch<GetBrandingById200>(getGetBrandingByIdUrl(id), {
|
|
2342
|
+
export const getBrandingById = async (id: string, options?: Parameters<typeof customFetch>[1]): Promise<GetBrandingById200> => {
|
|
2343
|
+
|
|
2344
|
+
return customFetch<GetBrandingById200>(getGetBrandingByIdUrl(id),
|
|
2345
|
+
{
|
|
2172
2346
|
...options,
|
|
2173
|
-
method:
|
|
2174
|
-
|
|
2175
|
-
|
|
2347
|
+
method: 'GET'
|
|
2348
|
+
|
|
2349
|
+
|
|
2350
|
+
}
|
|
2351
|
+
);}
|
|
2352
|
+
|
|
2176
2353
|
|
|
2177
|
-
|
|
2354
|
+
|
|
2355
|
+
export const getCreateIdpUrl = (params: CreateIdpParams,) => {
|
|
2178
2356
|
const normalizedParams = new URLSearchParams();
|
|
2179
2357
|
|
|
2180
2358
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2359
|
+
|
|
2181
2360
|
if (value !== undefined) {
|
|
2182
|
-
normalizedParams.append(key, value === null ?
|
|
2361
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
2183
2362
|
}
|
|
2184
2363
|
});
|
|
2185
2364
|
|
|
2186
2365
|
const stringifiedParams = normalizedParams.toString();
|
|
2187
2366
|
|
|
2188
|
-
return stringifiedParams.length > 0
|
|
2189
|
-
|
|
2190
|
-
: `${getProxyPath()}/idps`;
|
|
2191
|
-
};
|
|
2367
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/idps?${stringifiedParams}` : `${getProxyPath()}/idps`
|
|
2368
|
+
}
|
|
2192
2369
|
|
|
2193
2370
|
/**
|
|
2194
2371
|
* Creates or revises a connection document. If the slug does not already
|
|
@@ -2215,22 +2392,15 @@ export const getCreateIdpUrl = (params: CreateIdpParams) => {
|
|
|
2215
2392
|
* anything is stored.
|
|
2216
2393
|
* @summary Create or revise an identity provider connection
|
|
2217
2394
|
*/
|
|
2218
|
-
export const createIdp = async (
|
|
2219
|
-
|
|
2220
|
-
|
|
2221
|
-
|
|
2222
|
-
): Promise<CreateIdp200 | CreateIdp201> => {
|
|
2223
|
-
const getHeaders = (
|
|
2224
|
-
h?: NonNullable<RequestInit["headers"]>,
|
|
2225
|
-
): Record<string, string | readonly string[]> => {
|
|
2395
|
+
export const createIdp = async (createIdpBody: CreateIdpBody,
|
|
2396
|
+
params: CreateIdpParams, options?: Parameters<typeof customFetch>[1]): Promise<CreateIdp200 | CreateIdp201> => {
|
|
2397
|
+
|
|
2398
|
+
const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {
|
|
2226
2399
|
if (!h) return {};
|
|
2227
2400
|
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
2228
2401
|
if (Symbol.iterator in h) {
|
|
2229
2402
|
return Object.fromEntries(
|
|
2230
|
-
Array.from(
|
|
2231
|
-
h as Iterable<Iterable<string>>,
|
|
2232
|
-
(entry) => Array.from(entry) as [string, string],
|
|
2233
|
-
),
|
|
2403
|
+
Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),
|
|
2234
2404
|
);
|
|
2235
2405
|
}
|
|
2236
2406
|
const headers: Record<string, string | readonly string[]> = {};
|
|
@@ -2239,51 +2409,46 @@ export const createIdp = async (
|
|
|
2239
2409
|
}
|
|
2240
2410
|
return headers;
|
|
2241
2411
|
};
|
|
2242
|
-
|
|
2412
|
+
return customFetch<CreateIdp200 | CreateIdp201>(getCreateIdpUrl(params),
|
|
2413
|
+
{
|
|
2243
2414
|
...options,
|
|
2244
|
-
method:
|
|
2245
|
-
headers: {
|
|
2246
|
-
body: JSON.stringify(createIdpBody)
|
|
2247
|
-
}
|
|
2248
|
-
}
|
|
2415
|
+
method: 'POST',
|
|
2416
|
+
headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },
|
|
2417
|
+
body: JSON.stringify(createIdpBody)
|
|
2418
|
+
}
|
|
2419
|
+
);}
|
|
2249
2420
|
|
|
2250
|
-
|
|
2421
|
+
|
|
2422
|
+
|
|
2423
|
+
export const getQueryIdpsUrl = (params: QueryIdpsParams,) => {
|
|
2251
2424
|
const normalizedParams = new URLSearchParams();
|
|
2252
2425
|
|
|
2253
2426
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2427
|
+
|
|
2254
2428
|
if (value !== undefined) {
|
|
2255
|
-
normalizedParams.append(key, value === null ?
|
|
2429
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
2256
2430
|
}
|
|
2257
2431
|
});
|
|
2258
2432
|
|
|
2259
2433
|
const stringifiedParams = normalizedParams.toString();
|
|
2260
2434
|
|
|
2261
|
-
return stringifiedParams.length > 0
|
|
2262
|
-
|
|
2263
|
-
: `${getProxyPath()}/idps/query`;
|
|
2264
|
-
};
|
|
2435
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/idps/query?${stringifiedParams}` : `${getProxyPath()}/idps/query`
|
|
2436
|
+
}
|
|
2265
2437
|
|
|
2266
2438
|
/**
|
|
2267
2439
|
* Returns the identity provider connections of a project, paginated with a
|
|
2268
2440
|
* cursor. One row per connection, carrying its newest revision.
|
|
2269
2441
|
* @summary Query identity provider connections
|
|
2270
2442
|
*/
|
|
2271
|
-
export const queryIdps = async (
|
|
2272
|
-
|
|
2273
|
-
|
|
2274
|
-
|
|
2275
|
-
): Promise<QueryIdps200> => {
|
|
2276
|
-
const getHeaders = (
|
|
2277
|
-
h?: NonNullable<RequestInit["headers"]>,
|
|
2278
|
-
): Record<string, string | readonly string[]> => {
|
|
2443
|
+
export const queryIdps = async (queryIdpsBody: QueryIdpsBody,
|
|
2444
|
+
params: QueryIdpsParams, options?: Parameters<typeof customFetch>[1]): Promise<QueryIdps200> => {
|
|
2445
|
+
|
|
2446
|
+
const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {
|
|
2279
2447
|
if (!h) return {};
|
|
2280
2448
|
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
2281
2449
|
if (Symbol.iterator in h) {
|
|
2282
2450
|
return Object.fromEntries(
|
|
2283
|
-
Array.from(
|
|
2284
|
-
h as Iterable<Iterable<string>>,
|
|
2285
|
-
(entry) => Array.from(entry) as [string, string],
|
|
2286
|
-
),
|
|
2451
|
+
Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),
|
|
2287
2452
|
);
|
|
2288
2453
|
}
|
|
2289
2454
|
const headers: Record<string, string | readonly string[]> = {};
|
|
@@ -2292,29 +2457,32 @@ export const queryIdps = async (
|
|
|
2292
2457
|
}
|
|
2293
2458
|
return headers;
|
|
2294
2459
|
};
|
|
2295
|
-
|
|
2460
|
+
return customFetch<QueryIdps200>(getQueryIdpsUrl(params),
|
|
2461
|
+
{
|
|
2296
2462
|
...options,
|
|
2297
|
-
method:
|
|
2298
|
-
headers: {
|
|
2299
|
-
body: JSON.stringify(queryIdpsBody)
|
|
2300
|
-
}
|
|
2301
|
-
}
|
|
2463
|
+
method: 'POST',
|
|
2464
|
+
headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },
|
|
2465
|
+
body: JSON.stringify(queryIdpsBody)
|
|
2466
|
+
}
|
|
2467
|
+
);}
|
|
2468
|
+
|
|
2302
2469
|
|
|
2303
|
-
|
|
2470
|
+
|
|
2471
|
+
export const getGetIdpByIdUrl = (id: string,
|
|
2472
|
+
params: GetIdpByIdParams,) => {
|
|
2304
2473
|
const normalizedParams = new URLSearchParams();
|
|
2305
2474
|
|
|
2306
2475
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2476
|
+
|
|
2307
2477
|
if (value !== undefined) {
|
|
2308
|
-
normalizedParams.append(key, value === null ?
|
|
2478
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
2309
2479
|
}
|
|
2310
2480
|
});
|
|
2311
2481
|
|
|
2312
2482
|
const stringifiedParams = normalizedParams.toString();
|
|
2313
2483
|
|
|
2314
|
-
return stringifiedParams.length > 0
|
|
2315
|
-
|
|
2316
|
-
: `${getProxyPath()}/idps/${encodeURIComponent(String(id))}`;
|
|
2317
|
-
};
|
|
2484
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/idps/${encodeURIComponent(String(id))}?${stringifiedParams}` : `${getProxyPath()}/idps/${encodeURIComponent(String(id))}`
|
|
2485
|
+
}
|
|
2318
2486
|
|
|
2319
2487
|
/**
|
|
2320
2488
|
* Reads a connection by its id, at its newest revision.
|
|
@@ -2323,32 +2491,35 @@ export const getGetIdpByIdUrl = (id: string, params: GetIdpByIdParams) => {
|
|
|
2323
2491
|
* The lookup is scoped to the project in `project_id`.
|
|
2324
2492
|
* @summary Get an identity provider connection by id
|
|
2325
2493
|
*/
|
|
2326
|
-
export const getIdpById = async (
|
|
2327
|
-
|
|
2328
|
-
|
|
2329
|
-
|
|
2330
|
-
|
|
2331
|
-
return customFetch<GetIdpById200>(getGetIdpByIdUrl(id, params), {
|
|
2494
|
+
export const getIdpById = async (id: string,
|
|
2495
|
+
params: GetIdpByIdParams, options?: Parameters<typeof customFetch>[1]): Promise<GetIdpById200> => {
|
|
2496
|
+
|
|
2497
|
+
return customFetch<GetIdpById200>(getGetIdpByIdUrl(id,params),
|
|
2498
|
+
{
|
|
2332
2499
|
...options,
|
|
2333
|
-
method:
|
|
2334
|
-
|
|
2335
|
-
|
|
2500
|
+
method: 'GET'
|
|
2501
|
+
|
|
2502
|
+
|
|
2503
|
+
}
|
|
2504
|
+
);}
|
|
2336
2505
|
|
|
2337
|
-
|
|
2506
|
+
|
|
2507
|
+
|
|
2508
|
+
export const getListIdpRevisionsUrl = (id: string,
|
|
2509
|
+
params: ListIdpRevisionsParams,) => {
|
|
2338
2510
|
const normalizedParams = new URLSearchParams();
|
|
2339
2511
|
|
|
2340
2512
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2513
|
+
|
|
2341
2514
|
if (value !== undefined) {
|
|
2342
|
-
normalizedParams.append(key, value === null ?
|
|
2515
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
2343
2516
|
}
|
|
2344
2517
|
});
|
|
2345
2518
|
|
|
2346
2519
|
const stringifiedParams = normalizedParams.toString();
|
|
2347
2520
|
|
|
2348
|
-
return stringifiedParams.length > 0
|
|
2349
|
-
|
|
2350
|
-
: `${getProxyPath()}/idps/${encodeURIComponent(String(id))}/revisions`;
|
|
2351
|
-
};
|
|
2521
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/idps/${encodeURIComponent(String(id))}/revisions?${stringifiedParams}` : `${getProxyPath()}/idps/${encodeURIComponent(String(id))}/revisions`
|
|
2522
|
+
}
|
|
2352
2523
|
|
|
2353
2524
|
/**
|
|
2354
2525
|
* Returns every revision of one connection, newest first, paginated with a
|
|
@@ -2357,32 +2528,35 @@ export const getListIdpRevisionsUrl = (id: string, params: ListIdpRevisionsParam
|
|
|
2357
2528
|
* The lookup is scoped to the project in `project_id`.
|
|
2358
2529
|
* @summary List the revisions of an identity provider connection
|
|
2359
2530
|
*/
|
|
2360
|
-
export const listIdpRevisions = async (
|
|
2361
|
-
|
|
2362
|
-
|
|
2363
|
-
|
|
2364
|
-
|
|
2365
|
-
return customFetch<ListIdpRevisions200>(getListIdpRevisionsUrl(id, params), {
|
|
2531
|
+
export const listIdpRevisions = async (id: string,
|
|
2532
|
+
params: ListIdpRevisionsParams, options?: Parameters<typeof customFetch>[1]): Promise<ListIdpRevisions200> => {
|
|
2533
|
+
|
|
2534
|
+
return customFetch<ListIdpRevisions200>(getListIdpRevisionsUrl(id,params),
|
|
2535
|
+
{
|
|
2366
2536
|
...options,
|
|
2367
|
-
method:
|
|
2368
|
-
|
|
2369
|
-
|
|
2537
|
+
method: 'GET'
|
|
2538
|
+
|
|
2539
|
+
|
|
2540
|
+
}
|
|
2541
|
+
);}
|
|
2542
|
+
|
|
2370
2543
|
|
|
2371
|
-
|
|
2544
|
+
|
|
2545
|
+
export const getGetIdpRevisionByIdUrl = (revisionId: string,
|
|
2546
|
+
params: GetIdpRevisionByIdParams,) => {
|
|
2372
2547
|
const normalizedParams = new URLSearchParams();
|
|
2373
2548
|
|
|
2374
2549
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2550
|
+
|
|
2375
2551
|
if (value !== undefined) {
|
|
2376
|
-
normalizedParams.append(key, value === null ?
|
|
2552
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
2377
2553
|
}
|
|
2378
2554
|
});
|
|
2379
2555
|
|
|
2380
2556
|
const stringifiedParams = normalizedParams.toString();
|
|
2381
2557
|
|
|
2382
|
-
return stringifiedParams.length > 0
|
|
2383
|
-
|
|
2384
|
-
: `${getProxyPath()}/idps/revisions/${encodeURIComponent(String(revisionId))}`;
|
|
2385
|
-
};
|
|
2558
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/idps/revisions/${encodeURIComponent(String(revisionId))}?${stringifiedParams}` : `${getProxyPath()}/idps/revisions/${encodeURIComponent(String(revisionId))}`
|
|
2559
|
+
}
|
|
2386
2560
|
|
|
2387
2561
|
/**
|
|
2388
2562
|
* Reads one revision of a connection by its `revision_id`, the value an auth
|
|
@@ -2391,32 +2565,34 @@ export const getGetIdpRevisionByIdUrl = (revisionId: string, params: GetIdpRevis
|
|
|
2391
2565
|
* The lookup is scoped to the project in `project_id`.
|
|
2392
2566
|
* @summary Get one revision of an identity provider connection
|
|
2393
2567
|
*/
|
|
2394
|
-
export const getIdpRevisionById = async (
|
|
2395
|
-
|
|
2396
|
-
|
|
2397
|
-
|
|
2398
|
-
|
|
2399
|
-
return customFetch<GetIdpRevisionById200>(getGetIdpRevisionByIdUrl(revisionId, params), {
|
|
2568
|
+
export const getIdpRevisionById = async (revisionId: string,
|
|
2569
|
+
params: GetIdpRevisionByIdParams, options?: Parameters<typeof customFetch>[1]): Promise<GetIdpRevisionById200> => {
|
|
2570
|
+
|
|
2571
|
+
return customFetch<GetIdpRevisionById200>(getGetIdpRevisionByIdUrl(revisionId,params),
|
|
2572
|
+
{
|
|
2400
2573
|
...options,
|
|
2401
|
-
method:
|
|
2402
|
-
});
|
|
2403
|
-
};
|
|
2574
|
+
method: 'GET'
|
|
2404
2575
|
|
|
2405
|
-
|
|
2576
|
+
|
|
2577
|
+
}
|
|
2578
|
+
);}
|
|
2579
|
+
|
|
2580
|
+
|
|
2581
|
+
|
|
2582
|
+
export const getCreateReleaseUrl = (params: CreateReleaseParams,) => {
|
|
2406
2583
|
const normalizedParams = new URLSearchParams();
|
|
2407
2584
|
|
|
2408
2585
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2586
|
+
|
|
2409
2587
|
if (value !== undefined) {
|
|
2410
|
-
normalizedParams.append(key, value === null ?
|
|
2588
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
2411
2589
|
}
|
|
2412
2590
|
});
|
|
2413
2591
|
|
|
2414
2592
|
const stringifiedParams = normalizedParams.toString();
|
|
2415
2593
|
|
|
2416
|
-
return stringifiedParams.length > 0
|
|
2417
|
-
|
|
2418
|
-
: `${getProxyPath()}/releases`;
|
|
2419
|
-
};
|
|
2594
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/releases?${stringifiedParams}` : `${getProxyPath()}/releases`
|
|
2595
|
+
}
|
|
2420
2596
|
|
|
2421
2597
|
/**
|
|
2422
2598
|
* Bundles a release from revisions that already exist, supplied as
|
|
@@ -2436,22 +2612,15 @@ export const getCreateReleaseUrl = (params: CreateReleaseParams) => {
|
|
|
2436
2612
|
* release that already pins them rather than creating a second one.
|
|
2437
2613
|
* @summary Create a release
|
|
2438
2614
|
*/
|
|
2439
|
-
export const createRelease = async (
|
|
2440
|
-
|
|
2441
|
-
|
|
2442
|
-
|
|
2443
|
-
): Promise<CreateRelease200 | CreateRelease201> => {
|
|
2444
|
-
const getHeaders = (
|
|
2445
|
-
h?: NonNullable<RequestInit["headers"]>,
|
|
2446
|
-
): Record<string, string | readonly string[]> => {
|
|
2615
|
+
export const createRelease = async (createReleaseBody: CreateReleaseBody,
|
|
2616
|
+
params: CreateReleaseParams, options?: Parameters<typeof customFetch>[1]): Promise<CreateRelease200 | CreateRelease201> => {
|
|
2617
|
+
|
|
2618
|
+
const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {
|
|
2447
2619
|
if (!h) return {};
|
|
2448
2620
|
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
2449
2621
|
if (Symbol.iterator in h) {
|
|
2450
2622
|
return Object.fromEntries(
|
|
2451
|
-
Array.from(
|
|
2452
|
-
h as Iterable<Iterable<string>>,
|
|
2453
|
-
(entry) => Array.from(entry) as [string, string],
|
|
2454
|
-
),
|
|
2623
|
+
Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),
|
|
2455
2624
|
);
|
|
2456
2625
|
}
|
|
2457
2626
|
const headers: Record<string, string | readonly string[]> = {};
|
|
@@ -2460,29 +2629,31 @@ export const createRelease = async (
|
|
|
2460
2629
|
}
|
|
2461
2630
|
return headers;
|
|
2462
2631
|
};
|
|
2463
|
-
|
|
2632
|
+
return customFetch<CreateRelease200 | CreateRelease201>(getCreateReleaseUrl(params),
|
|
2633
|
+
{
|
|
2464
2634
|
...options,
|
|
2465
|
-
method:
|
|
2466
|
-
headers: {
|
|
2467
|
-
body: JSON.stringify(createReleaseBody)
|
|
2468
|
-
}
|
|
2469
|
-
}
|
|
2635
|
+
method: 'POST',
|
|
2636
|
+
headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },
|
|
2637
|
+
body: JSON.stringify(createReleaseBody)
|
|
2638
|
+
}
|
|
2639
|
+
);}
|
|
2640
|
+
|
|
2470
2641
|
|
|
2471
|
-
|
|
2642
|
+
|
|
2643
|
+
export const getListReleasesUrl = (params: ListReleasesParams,) => {
|
|
2472
2644
|
const normalizedParams = new URLSearchParams();
|
|
2473
2645
|
|
|
2474
2646
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2647
|
+
|
|
2475
2648
|
if (value !== undefined) {
|
|
2476
|
-
normalizedParams.append(key, value === null ?
|
|
2649
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
2477
2650
|
}
|
|
2478
2651
|
});
|
|
2479
2652
|
|
|
2480
2653
|
const stringifiedParams = normalizedParams.toString();
|
|
2481
2654
|
|
|
2482
|
-
return stringifiedParams.length > 0
|
|
2483
|
-
|
|
2484
|
-
: `${getProxyPath()}/releases`;
|
|
2485
|
-
};
|
|
2655
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/releases?${stringifiedParams}` : `${getProxyPath()}/releases`
|
|
2656
|
+
}
|
|
2486
2657
|
|
|
2487
2658
|
/**
|
|
2488
2659
|
* Lists the project's releases, newest first.
|
|
@@ -2491,31 +2662,34 @@ export const getListReleasesUrl = (params: ListReleasesParams) => {
|
|
|
2491
2662
|
* with `GET /releases/{release_id}` to get its pointers.
|
|
2492
2663
|
* @summary List releases
|
|
2493
2664
|
*/
|
|
2494
|
-
export const listReleases = async (
|
|
2495
|
-
|
|
2496
|
-
|
|
2497
|
-
|
|
2498
|
-
return customFetch<ListReleases200>(getListReleasesUrl(params), {
|
|
2665
|
+
export const listReleases = async (params: ListReleasesParams, options?: Parameters<typeof customFetch>[1]): Promise<ListReleases200> => {
|
|
2666
|
+
|
|
2667
|
+
return customFetch<ListReleases200>(getListReleasesUrl(params),
|
|
2668
|
+
{
|
|
2499
2669
|
...options,
|
|
2500
|
-
method:
|
|
2501
|
-
|
|
2502
|
-
|
|
2670
|
+
method: 'GET'
|
|
2671
|
+
|
|
2672
|
+
|
|
2673
|
+
}
|
|
2674
|
+
);}
|
|
2675
|
+
|
|
2676
|
+
|
|
2503
2677
|
|
|
2504
|
-
export const getGetReleaseByIdUrl = (releaseId: string,
|
|
2678
|
+
export const getGetReleaseByIdUrl = (releaseId: string,
|
|
2679
|
+
params: GetReleaseByIdParams,) => {
|
|
2505
2680
|
const normalizedParams = new URLSearchParams();
|
|
2506
2681
|
|
|
2507
2682
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2683
|
+
|
|
2508
2684
|
if (value !== undefined) {
|
|
2509
|
-
normalizedParams.append(key, value === null ?
|
|
2685
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
2510
2686
|
}
|
|
2511
2687
|
});
|
|
2512
2688
|
|
|
2513
2689
|
const stringifiedParams = normalizedParams.toString();
|
|
2514
2690
|
|
|
2515
|
-
return stringifiedParams.length > 0
|
|
2516
|
-
|
|
2517
|
-
: `${getProxyPath()}/releases/${encodeURIComponent(String(releaseId))}`;
|
|
2518
|
-
};
|
|
2691
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/releases/${encodeURIComponent(String(releaseId))}?${stringifiedParams}` : `${getProxyPath()}/releases/${encodeURIComponent(String(releaseId))}`
|
|
2692
|
+
}
|
|
2519
2693
|
|
|
2520
2694
|
/**
|
|
2521
2695
|
* Reads one release: its metadata and the `(kind, handle, revision_id)`
|
|
@@ -2530,32 +2704,34 @@ export const getGetReleaseByIdUrl = (releaseId: string, params: GetReleaseByIdPa
|
|
|
2530
2704
|
* read.
|
|
2531
2705
|
* @summary Get a release by id
|
|
2532
2706
|
*/
|
|
2533
|
-
export const getReleaseById = async (
|
|
2534
|
-
|
|
2535
|
-
|
|
2536
|
-
|
|
2537
|
-
|
|
2538
|
-
return customFetch<GetReleaseById200>(getGetReleaseByIdUrl(releaseId, params), {
|
|
2707
|
+
export const getReleaseById = async (releaseId: string,
|
|
2708
|
+
params: GetReleaseByIdParams, options?: Parameters<typeof customFetch>[1]): Promise<GetReleaseById200> => {
|
|
2709
|
+
|
|
2710
|
+
return customFetch<GetReleaseById200>(getGetReleaseByIdUrl(releaseId,params),
|
|
2711
|
+
{
|
|
2539
2712
|
...options,
|
|
2540
|
-
method:
|
|
2541
|
-
|
|
2542
|
-
};
|
|
2713
|
+
method: 'GET'
|
|
2714
|
+
|
|
2543
2715
|
|
|
2544
|
-
|
|
2716
|
+
}
|
|
2717
|
+
);}
|
|
2718
|
+
|
|
2719
|
+
|
|
2720
|
+
|
|
2721
|
+
export const getCreateGrantUrl = (params: CreateGrantParams,) => {
|
|
2545
2722
|
const normalizedParams = new URLSearchParams();
|
|
2546
2723
|
|
|
2547
2724
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2725
|
+
|
|
2548
2726
|
if (value !== undefined) {
|
|
2549
|
-
normalizedParams.append(key, value === null ?
|
|
2727
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
2550
2728
|
}
|
|
2551
2729
|
});
|
|
2552
2730
|
|
|
2553
2731
|
const stringifiedParams = normalizedParams.toString();
|
|
2554
2732
|
|
|
2555
|
-
return stringifiedParams.length > 0
|
|
2556
|
-
|
|
2557
|
-
: `${getProxyPath()}/grants`;
|
|
2558
|
-
};
|
|
2733
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/grants?${stringifiedParams}` : `${getProxyPath()}/grants`
|
|
2734
|
+
}
|
|
2559
2735
|
|
|
2560
2736
|
/**
|
|
2561
2737
|
* Bind a user or team to `project.viewer`, `project.editor`, or
|
|
@@ -2575,26 +2751,19 @@ export const getCreateGrantUrl = (params: CreateGrantParams) => {
|
|
|
2575
2751
|
*
|
|
2576
2752
|
* Accepts either a project secret (`oauth2`) or a user-bound Console
|
|
2577
2753
|
* session cookie (`nextgenSession`). Session callers are authorized as
|
|
2578
|
-
* the human against the target project (home may differ).
|
|
2579
|
-
*
|
|
2754
|
+
* the human against the target project (home may differ). Cookie-authenticated
|
|
2755
|
+
* requests follow the scheme's CSRF rules (`nextgenSession`).
|
|
2580
2756
|
* @summary Create grant
|
|
2581
2757
|
*/
|
|
2582
|
-
export const createGrant = async (
|
|
2583
|
-
|
|
2584
|
-
|
|
2585
|
-
|
|
2586
|
-
): Promise<CreateGrant201 | void> => {
|
|
2587
|
-
const getHeaders = (
|
|
2588
|
-
h?: NonNullable<RequestInit["headers"]>,
|
|
2589
|
-
): Record<string, string | readonly string[]> => {
|
|
2758
|
+
export const createGrant = async (createGrantBody: CreateGrantBody,
|
|
2759
|
+
params: CreateGrantParams, options?: Parameters<typeof customFetch>[1]): Promise<CreateGrant201 | void> => {
|
|
2760
|
+
|
|
2761
|
+
const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {
|
|
2590
2762
|
if (!h) return {};
|
|
2591
2763
|
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
2592
2764
|
if (Symbol.iterator in h) {
|
|
2593
2765
|
return Object.fromEntries(
|
|
2594
|
-
Array.from(
|
|
2595
|
-
h as Iterable<Iterable<string>>,
|
|
2596
|
-
(entry) => Array.from(entry) as [string, string],
|
|
2597
|
-
),
|
|
2766
|
+
Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),
|
|
2598
2767
|
);
|
|
2599
2768
|
}
|
|
2600
2769
|
const headers: Record<string, string | readonly string[]> = {};
|
|
@@ -2603,29 +2772,31 @@ export const createGrant = async (
|
|
|
2603
2772
|
}
|
|
2604
2773
|
return headers;
|
|
2605
2774
|
};
|
|
2606
|
-
|
|
2775
|
+
return customFetch<CreateGrant201 | void>(getCreateGrantUrl(params),
|
|
2776
|
+
{
|
|
2607
2777
|
...options,
|
|
2608
|
-
method:
|
|
2609
|
-
headers: {
|
|
2610
|
-
body: JSON.stringify(createGrantBody)
|
|
2611
|
-
}
|
|
2612
|
-
}
|
|
2778
|
+
method: 'POST',
|
|
2779
|
+
headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },
|
|
2780
|
+
body: JSON.stringify(createGrantBody)
|
|
2781
|
+
}
|
|
2782
|
+
);}
|
|
2783
|
+
|
|
2784
|
+
|
|
2613
2785
|
|
|
2614
|
-
export const getQueryGrantsUrl = (params: QueryGrantsParams) => {
|
|
2786
|
+
export const getQueryGrantsUrl = (params: QueryGrantsParams,) => {
|
|
2615
2787
|
const normalizedParams = new URLSearchParams();
|
|
2616
2788
|
|
|
2617
2789
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2790
|
+
|
|
2618
2791
|
if (value !== undefined) {
|
|
2619
|
-
normalizedParams.append(key, value === null ?
|
|
2792
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
2620
2793
|
}
|
|
2621
2794
|
});
|
|
2622
2795
|
|
|
2623
2796
|
const stringifiedParams = normalizedParams.toString();
|
|
2624
2797
|
|
|
2625
|
-
return stringifiedParams.length > 0
|
|
2626
|
-
|
|
2627
|
-
: `${getProxyPath()}/grants/query`;
|
|
2628
|
-
};
|
|
2798
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/grants/query?${stringifiedParams}` : `${getProxyPath()}/grants/query`
|
|
2799
|
+
}
|
|
2629
2800
|
|
|
2630
2801
|
/**
|
|
2631
2802
|
* Returns the collaboration grants of a project, paginated with a cursor.
|
|
@@ -2642,26 +2813,19 @@ export const getQueryGrantsUrl = (params: QueryGrantsParams) => {
|
|
|
2642
2813
|
* the project Check may expand without those scopes.
|
|
2643
2814
|
*
|
|
2644
2815
|
* Accepts either a project secret (`oauth2`) or a user-bound Console
|
|
2645
|
-
* session cookie (`nextgenSession`).
|
|
2646
|
-
*
|
|
2816
|
+
* session cookie (`nextgenSession`). Cookie-authenticated requests
|
|
2817
|
+
* follow the scheme's CSRF rules (`nextgenSession`).
|
|
2647
2818
|
* @summary Query grants
|
|
2648
2819
|
*/
|
|
2649
|
-
export const queryGrants = async (
|
|
2650
|
-
|
|
2651
|
-
|
|
2652
|
-
|
|
2653
|
-
): Promise<QueryGrants200> => {
|
|
2654
|
-
const getHeaders = (
|
|
2655
|
-
h?: NonNullable<RequestInit["headers"]>,
|
|
2656
|
-
): Record<string, string | readonly string[]> => {
|
|
2820
|
+
export const queryGrants = async (queryGrantsBody: QueryGrantsBody,
|
|
2821
|
+
params: QueryGrantsParams, options?: Parameters<typeof customFetch>[1]): Promise<QueryGrants200> => {
|
|
2822
|
+
|
|
2823
|
+
const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {
|
|
2657
2824
|
if (!h) return {};
|
|
2658
2825
|
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
2659
2826
|
if (Symbol.iterator in h) {
|
|
2660
2827
|
return Object.fromEntries(
|
|
2661
|
-
Array.from(
|
|
2662
|
-
h as Iterable<Iterable<string>>,
|
|
2663
|
-
(entry) => Array.from(entry) as [string, string],
|
|
2664
|
-
),
|
|
2828
|
+
Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),
|
|
2665
2829
|
);
|
|
2666
2830
|
}
|
|
2667
2831
|
const headers: Record<string, string | readonly string[]> = {};
|
|
@@ -2670,15 +2834,19 @@ export const queryGrants = async (
|
|
|
2670
2834
|
}
|
|
2671
2835
|
return headers;
|
|
2672
2836
|
};
|
|
2673
|
-
|
|
2837
|
+
return customFetch<QueryGrants200>(getQueryGrantsUrl(params),
|
|
2838
|
+
{
|
|
2674
2839
|
...options,
|
|
2675
|
-
method:
|
|
2676
|
-
headers: {
|
|
2677
|
-
body: JSON.stringify(queryGrantsBody)
|
|
2678
|
-
}
|
|
2679
|
-
}
|
|
2840
|
+
method: 'POST',
|
|
2841
|
+
headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },
|
|
2842
|
+
body: JSON.stringify(queryGrantsBody)
|
|
2843
|
+
}
|
|
2844
|
+
);}
|
|
2845
|
+
|
|
2680
2846
|
|
|
2681
|
-
|
|
2847
|
+
|
|
2848
|
+
export const getGetGrantUrl = (id: string,
|
|
2849
|
+
params: GetGrantParams,) => {
|
|
2682
2850
|
const normalizedParams = new URLSearchParams();
|
|
2683
2851
|
|
|
2684
2852
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
@@ -2686,22 +2854,20 @@ export const getGetGrantUrl = (id: string, params: GetGrantParams) => {
|
|
|
2686
2854
|
|
|
2687
2855
|
if (Array.isArray(value) && explodeParameters.includes(key)) {
|
|
2688
2856
|
value.forEach((v) => {
|
|
2689
|
-
normalizedParams.append(key, v === null ?
|
|
2857
|
+
normalizedParams.append(key, v === null ? 'null' : String(v));
|
|
2690
2858
|
});
|
|
2691
2859
|
return;
|
|
2692
2860
|
}
|
|
2693
2861
|
|
|
2694
2862
|
if (value !== undefined) {
|
|
2695
|
-
normalizedParams.append(key, value === null ?
|
|
2863
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
2696
2864
|
}
|
|
2697
2865
|
});
|
|
2698
2866
|
|
|
2699
2867
|
const stringifiedParams = normalizedParams.toString();
|
|
2700
2868
|
|
|
2701
|
-
return stringifiedParams.length > 0
|
|
2702
|
-
|
|
2703
|
-
: `${getProxyPath()}/grants/${encodeURIComponent(String(id))}`;
|
|
2704
|
-
};
|
|
2869
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/grants/${encodeURIComponent(String(id))}?${stringifiedParams}` : `${getProxyPath()}/grants/${encodeURIComponent(String(id))}`
|
|
2870
|
+
}
|
|
2705
2871
|
|
|
2706
2872
|
/**
|
|
2707
2873
|
* Loads a grant by `(project_id, id)` that this API manages (user or team
|
|
@@ -2718,36 +2884,39 @@ export const getGetGrantUrl = (id: string, params: GetGrantParams) => {
|
|
|
2718
2884
|
* Check may expand without those scopes.
|
|
2719
2885
|
*
|
|
2720
2886
|
* Accepts either a project secret (`oauth2`) or a user-bound Console
|
|
2721
|
-
* session cookie (`nextgenSession`).
|
|
2722
|
-
*
|
|
2887
|
+
* session cookie (`nextgenSession`). Cookie-authenticated requests
|
|
2888
|
+
* follow the scheme's CSRF rules (`nextgenSession`).
|
|
2723
2889
|
* @summary Get grant
|
|
2724
2890
|
*/
|
|
2725
|
-
export const getGrant = async (
|
|
2726
|
-
|
|
2727
|
-
|
|
2728
|
-
|
|
2729
|
-
|
|
2730
|
-
return customFetch<GetGrant200>(getGetGrantUrl(id, params), {
|
|
2891
|
+
export const getGrant = async (id: string,
|
|
2892
|
+
params: GetGrantParams, options?: Parameters<typeof customFetch>[1]): Promise<GetGrant200> => {
|
|
2893
|
+
|
|
2894
|
+
return customFetch<GetGrant200>(getGetGrantUrl(id,params),
|
|
2895
|
+
{
|
|
2731
2896
|
...options,
|
|
2732
|
-
method:
|
|
2733
|
-
|
|
2734
|
-
};
|
|
2897
|
+
method: 'GET'
|
|
2898
|
+
|
|
2735
2899
|
|
|
2736
|
-
|
|
2900
|
+
}
|
|
2901
|
+
);}
|
|
2902
|
+
|
|
2903
|
+
|
|
2904
|
+
|
|
2905
|
+
export const getDeleteGrantUrl = (id: string,
|
|
2906
|
+
params: DeleteGrantParams,) => {
|
|
2737
2907
|
const normalizedParams = new URLSearchParams();
|
|
2738
2908
|
|
|
2739
2909
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2910
|
+
|
|
2740
2911
|
if (value !== undefined) {
|
|
2741
|
-
normalizedParams.append(key, value === null ?
|
|
2912
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
2742
2913
|
}
|
|
2743
2914
|
});
|
|
2744
2915
|
|
|
2745
2916
|
const stringifiedParams = normalizedParams.toString();
|
|
2746
2917
|
|
|
2747
|
-
return stringifiedParams.length > 0
|
|
2748
|
-
|
|
2749
|
-
: `${getProxyPath()}/grants/${encodeURIComponent(String(id))}`;
|
|
2750
|
-
};
|
|
2918
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/grants/${encodeURIComponent(String(id))}?${stringifiedParams}` : `${getProxyPath()}/grants/${encodeURIComponent(String(id))}`
|
|
2919
|
+
}
|
|
2751
2920
|
|
|
2752
2921
|
/**
|
|
2753
2922
|
* Soft-revokes a grant this API manages and emits `authz.revoked`.
|
|
@@ -2756,45 +2925,46 @@ export const getDeleteGrantUrl = (id: string, params: DeleteGrantParams) => {
|
|
|
2756
2925
|
* revoked so the unique binding can be reused.
|
|
2757
2926
|
*
|
|
2758
2927
|
* Accepts either a project secret (`oauth2`) or a user-bound Console
|
|
2759
|
-
* session cookie (`nextgenSession`).
|
|
2760
|
-
*
|
|
2928
|
+
* session cookie (`nextgenSession`). Cookie-authenticated requests
|
|
2929
|
+
* follow the scheme's CSRF rules (`nextgenSession`).
|
|
2761
2930
|
* @summary Revoke grant
|
|
2762
2931
|
*/
|
|
2763
|
-
export const deleteGrant = async (
|
|
2764
|
-
|
|
2765
|
-
|
|
2766
|
-
|
|
2767
|
-
|
|
2768
|
-
return customFetch<void>(getDeleteGrantUrl(id, params), {
|
|
2932
|
+
export const deleteGrant = async (id: string,
|
|
2933
|
+
params: DeleteGrantParams, options?: Parameters<typeof customFetch>[1]): Promise<void> => {
|
|
2934
|
+
|
|
2935
|
+
return customFetch<void>(getDeleteGrantUrl(id,params),
|
|
2936
|
+
{
|
|
2769
2937
|
...options,
|
|
2770
|
-
method:
|
|
2771
|
-
|
|
2772
|
-
|
|
2938
|
+
method: 'DELETE'
|
|
2939
|
+
|
|
2940
|
+
|
|
2941
|
+
}
|
|
2942
|
+
);}
|
|
2773
2943
|
|
|
2774
|
-
|
|
2944
|
+
|
|
2945
|
+
|
|
2946
|
+
export const getListEventsUrl = (params: ListEventsParams,) => {
|
|
2775
2947
|
const normalizedParams = new URLSearchParams();
|
|
2776
2948
|
|
|
2777
2949
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2778
|
-
const explodeParameters = ["category",
|
|
2950
|
+
const explodeParameters = ["category","event_type"];
|
|
2779
2951
|
|
|
2780
2952
|
if (Array.isArray(value) && explodeParameters.includes(key)) {
|
|
2781
2953
|
value.forEach((v) => {
|
|
2782
|
-
normalizedParams.append(key, v === null ?
|
|
2954
|
+
normalizedParams.append(key, v === null ? 'null' : String(v));
|
|
2783
2955
|
});
|
|
2784
2956
|
return;
|
|
2785
2957
|
}
|
|
2786
2958
|
|
|
2787
2959
|
if (value !== undefined) {
|
|
2788
|
-
normalizedParams.append(key, value === null ?
|
|
2960
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
2789
2961
|
}
|
|
2790
2962
|
});
|
|
2791
2963
|
|
|
2792
2964
|
const stringifiedParams = normalizedParams.toString();
|
|
2793
2965
|
|
|
2794
|
-
return stringifiedParams.length > 0
|
|
2795
|
-
|
|
2796
|
-
: `${getProxyPath()}/events`;
|
|
2797
|
-
};
|
|
2966
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/events?${stringifiedParams}` : `${getProxyPath()}/events`
|
|
2967
|
+
}
|
|
2798
2968
|
|
|
2799
2969
|
/**
|
|
2800
2970
|
* Returns project-scoped audit events, newest-first by keyset on
|
|
@@ -2810,31 +2980,34 @@ export const getListEventsUrl = (params: ListEventsParams) => {
|
|
|
2810
2980
|
* see docs/design/api/events-catalog.md.
|
|
2811
2981
|
* @summary List events
|
|
2812
2982
|
*/
|
|
2813
|
-
export const listEvents = async (
|
|
2814
|
-
|
|
2815
|
-
|
|
2816
|
-
|
|
2817
|
-
return customFetch<ListEvents200>(getListEventsUrl(params), {
|
|
2983
|
+
export const listEvents = async (params: ListEventsParams, options?: Parameters<typeof customFetch>[1]): Promise<ListEvents200> => {
|
|
2984
|
+
|
|
2985
|
+
return customFetch<ListEvents200>(getListEventsUrl(params),
|
|
2986
|
+
{
|
|
2818
2987
|
...options,
|
|
2819
|
-
method:
|
|
2820
|
-
});
|
|
2821
|
-
};
|
|
2988
|
+
method: 'GET'
|
|
2822
2989
|
|
|
2823
|
-
|
|
2990
|
+
|
|
2991
|
+
}
|
|
2992
|
+
);}
|
|
2993
|
+
|
|
2994
|
+
|
|
2995
|
+
|
|
2996
|
+
export const getGetEventUrl = (id: string,
|
|
2997
|
+
params: GetEventParams,) => {
|
|
2824
2998
|
const normalizedParams = new URLSearchParams();
|
|
2825
2999
|
|
|
2826
3000
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
3001
|
+
|
|
2827
3002
|
if (value !== undefined) {
|
|
2828
|
-
normalizedParams.append(key, value === null ?
|
|
3003
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
2829
3004
|
}
|
|
2830
3005
|
});
|
|
2831
3006
|
|
|
2832
3007
|
const stringifiedParams = normalizedParams.toString();
|
|
2833
3008
|
|
|
2834
|
-
return stringifiedParams.length > 0
|
|
2835
|
-
|
|
2836
|
-
: `${getProxyPath()}/events/${encodeURIComponent(String(id))}`;
|
|
2837
|
-
};
|
|
3009
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/events/${encodeURIComponent(String(id))}?${stringifiedParams}` : `${getProxyPath()}/events/${encodeURIComponent(String(id))}`
|
|
3010
|
+
}
|
|
2838
3011
|
|
|
2839
3012
|
/**
|
|
2840
3013
|
* Loads a single event by `(project_id, id)`. Requires `events.read`.
|
|
@@ -2844,32 +3017,34 @@ export const getGetEventUrl = (id: string, params: GetEventParams) => {
|
|
|
2844
3017
|
* Pre-claim projects return 404 (stored events stay invisible until claim).
|
|
2845
3018
|
* @summary Get event by ID
|
|
2846
3019
|
*/
|
|
2847
|
-
export const getEvent = async (
|
|
2848
|
-
|
|
2849
|
-
|
|
2850
|
-
|
|
2851
|
-
|
|
2852
|
-
return customFetch<GetEvent200>(getGetEventUrl(id, params), {
|
|
3020
|
+
export const getEvent = async (id: string,
|
|
3021
|
+
params: GetEventParams, options?: Parameters<typeof customFetch>[1]): Promise<GetEvent200> => {
|
|
3022
|
+
|
|
3023
|
+
return customFetch<GetEvent200>(getGetEventUrl(id,params),
|
|
3024
|
+
{
|
|
2853
3025
|
...options,
|
|
2854
|
-
method:
|
|
2855
|
-
|
|
2856
|
-
};
|
|
3026
|
+
method: 'GET'
|
|
3027
|
+
|
|
2857
3028
|
|
|
2858
|
-
|
|
3029
|
+
}
|
|
3030
|
+
);}
|
|
3031
|
+
|
|
3032
|
+
|
|
3033
|
+
|
|
3034
|
+
export const getGetVariablesUrl = (params: GetVariablesParams,) => {
|
|
2859
3035
|
const normalizedParams = new URLSearchParams();
|
|
2860
3036
|
|
|
2861
3037
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
3038
|
+
|
|
2862
3039
|
if (value !== undefined) {
|
|
2863
|
-
normalizedParams.append(key, value === null ?
|
|
3040
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
2864
3041
|
}
|
|
2865
3042
|
});
|
|
2866
3043
|
|
|
2867
3044
|
const stringifiedParams = normalizedParams.toString();
|
|
2868
3045
|
|
|
2869
|
-
return stringifiedParams.length > 0
|
|
2870
|
-
|
|
2871
|
-
: `${getProxyPath()}/variables`;
|
|
2872
|
-
};
|
|
3046
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/variables?${stringifiedParams}` : `${getProxyPath()}/variables`
|
|
3047
|
+
}
|
|
2873
3048
|
|
|
2874
3049
|
/**
|
|
2875
3050
|
* Returns the variables entered at the owner this request addresses, keyed by
|
|
@@ -2884,31 +3059,33 @@ export const getGetVariablesUrl = (params: GetVariablesParams) => {
|
|
|
2884
3059
|
* which says a value is held without disclosing it.
|
|
2885
3060
|
* @summary Get variables
|
|
2886
3061
|
*/
|
|
2887
|
-
export const getVariables = async (
|
|
2888
|
-
|
|
2889
|
-
|
|
2890
|
-
|
|
2891
|
-
return customFetch<GetVariables200>(getGetVariablesUrl(params), {
|
|
3062
|
+
export const getVariables = async (params: GetVariablesParams, options?: Parameters<typeof customFetch>[1]): Promise<GetVariables200> => {
|
|
3063
|
+
|
|
3064
|
+
return customFetch<GetVariables200>(getGetVariablesUrl(params),
|
|
3065
|
+
{
|
|
2892
3066
|
...options,
|
|
2893
|
-
method:
|
|
2894
|
-
|
|
2895
|
-
|
|
3067
|
+
method: 'GET'
|
|
3068
|
+
|
|
3069
|
+
|
|
3070
|
+
}
|
|
3071
|
+
);}
|
|
2896
3072
|
|
|
2897
|
-
|
|
3073
|
+
|
|
3074
|
+
|
|
3075
|
+
export const getUpdateVariablesUrl = (params: UpdateVariablesParams,) => {
|
|
2898
3076
|
const normalizedParams = new URLSearchParams();
|
|
2899
3077
|
|
|
2900
3078
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
3079
|
+
|
|
2901
3080
|
if (value !== undefined) {
|
|
2902
|
-
normalizedParams.append(key, value === null ?
|
|
3081
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
2903
3082
|
}
|
|
2904
3083
|
});
|
|
2905
3084
|
|
|
2906
3085
|
const stringifiedParams = normalizedParams.toString();
|
|
2907
3086
|
|
|
2908
|
-
return stringifiedParams.length > 0
|
|
2909
|
-
|
|
2910
|
-
: `${getProxyPath()}/variables`;
|
|
2911
|
-
};
|
|
3087
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/variables?${stringifiedParams}` : `${getProxyPath()}/variables`
|
|
3088
|
+
}
|
|
2912
3089
|
|
|
2913
3090
|
/**
|
|
2914
3091
|
* Enters, replaces and removes variables at the owner this request
|
|
@@ -2930,22 +3107,15 @@ export const getUpdateVariablesUrl = (params: UpdateVariablesParams) => {
|
|
|
2930
3107
|
* value rather than duplicating it, which makes a retry safe.
|
|
2931
3108
|
* @summary Update variables
|
|
2932
3109
|
*/
|
|
2933
|
-
export const updateVariables = async (
|
|
2934
|
-
|
|
2935
|
-
|
|
2936
|
-
|
|
2937
|
-
): Promise<UpdateVariables200> => {
|
|
2938
|
-
const getHeaders = (
|
|
2939
|
-
h?: NonNullable<RequestInit["headers"]>,
|
|
2940
|
-
): Record<string, string | readonly string[]> => {
|
|
3110
|
+
export const updateVariables = async (updateVariablesBody: UpdateVariablesBody,
|
|
3111
|
+
params: UpdateVariablesParams, options?: Parameters<typeof customFetch>[1]): Promise<UpdateVariables200> => {
|
|
3112
|
+
|
|
3113
|
+
const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {
|
|
2941
3114
|
if (!h) return {};
|
|
2942
3115
|
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
2943
3116
|
if (Symbol.iterator in h) {
|
|
2944
3117
|
return Object.fromEntries(
|
|
2945
|
-
Array.from(
|
|
2946
|
-
h as Iterable<Iterable<string>>,
|
|
2947
|
-
(entry) => Array.from(entry) as [string, string],
|
|
2948
|
-
),
|
|
3118
|
+
Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),
|
|
2949
3119
|
);
|
|
2950
3120
|
}
|
|
2951
3121
|
const headers: Record<string, string | readonly string[]> = {};
|
|
@@ -2954,29 +3124,32 @@ export const updateVariables = async (
|
|
|
2954
3124
|
}
|
|
2955
3125
|
return headers;
|
|
2956
3126
|
};
|
|
2957
|
-
|
|
3127
|
+
return customFetch<UpdateVariables200>(getUpdateVariablesUrl(params),
|
|
3128
|
+
{
|
|
2958
3129
|
...options,
|
|
2959
|
-
method:
|
|
2960
|
-
headers: {
|
|
2961
|
-
body: JSON.stringify(updateVariablesBody)
|
|
2962
|
-
}
|
|
2963
|
-
}
|
|
3130
|
+
method: 'PATCH',
|
|
3131
|
+
headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },
|
|
3132
|
+
body: JSON.stringify(updateVariablesBody)
|
|
3133
|
+
}
|
|
3134
|
+
);}
|
|
3135
|
+
|
|
2964
3136
|
|
|
2965
|
-
|
|
3137
|
+
|
|
3138
|
+
export const getGetVariableUrl = (variableName: string,
|
|
3139
|
+
params: GetVariableParams,) => {
|
|
2966
3140
|
const normalizedParams = new URLSearchParams();
|
|
2967
3141
|
|
|
2968
3142
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
3143
|
+
|
|
2969
3144
|
if (value !== undefined) {
|
|
2970
|
-
normalizedParams.append(key, value === null ?
|
|
3145
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
2971
3146
|
}
|
|
2972
3147
|
});
|
|
2973
3148
|
|
|
2974
3149
|
const stringifiedParams = normalizedParams.toString();
|
|
2975
3150
|
|
|
2976
|
-
return stringifiedParams.length > 0
|
|
2977
|
-
|
|
2978
|
-
: `${getProxyPath()}/variables/${encodeURIComponent(String(variableName))}`;
|
|
2979
|
-
};
|
|
3151
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/variables/${encodeURIComponent(String(variableName))}?${stringifiedParams}` : `${getProxyPath()}/variables/${encodeURIComponent(String(variableName))}`
|
|
3152
|
+
}
|
|
2980
3153
|
|
|
2981
3154
|
/**
|
|
2982
3155
|
* Reads one variable by name from the owner this request addresses — one
|
|
@@ -2988,32 +3161,35 @@ export const getGetVariableUrl = (variableName: string, params: GetVariableParam
|
|
|
2988
3161
|
* is found but not disclosed: the response is `{"secret": true}`.
|
|
2989
3162
|
* @summary Get a variable
|
|
2990
3163
|
*/
|
|
2991
|
-
export const getVariable = async (
|
|
2992
|
-
|
|
2993
|
-
|
|
2994
|
-
|
|
2995
|
-
|
|
2996
|
-
return customFetch<GetVariable200>(getGetVariableUrl(variableName, params), {
|
|
3164
|
+
export const getVariable = async (variableName: string,
|
|
3165
|
+
params: GetVariableParams, options?: Parameters<typeof customFetch>[1]): Promise<GetVariable200> => {
|
|
3166
|
+
|
|
3167
|
+
return customFetch<GetVariable200>(getGetVariableUrl(variableName,params),
|
|
3168
|
+
{
|
|
2997
3169
|
...options,
|
|
2998
|
-
method:
|
|
2999
|
-
|
|
3000
|
-
|
|
3170
|
+
method: 'GET'
|
|
3171
|
+
|
|
3172
|
+
|
|
3173
|
+
}
|
|
3174
|
+
);}
|
|
3001
3175
|
|
|
3002
|
-
|
|
3176
|
+
|
|
3177
|
+
|
|
3178
|
+
export const getDeleteVariableUrl = (variableName: string,
|
|
3179
|
+
params: DeleteVariableParams,) => {
|
|
3003
3180
|
const normalizedParams = new URLSearchParams();
|
|
3004
3181
|
|
|
3005
3182
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
3183
|
+
|
|
3006
3184
|
if (value !== undefined) {
|
|
3007
|
-
normalizedParams.append(key, value === null ?
|
|
3185
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
3008
3186
|
}
|
|
3009
3187
|
});
|
|
3010
3188
|
|
|
3011
3189
|
const stringifiedParams = normalizedParams.toString();
|
|
3012
3190
|
|
|
3013
|
-
return stringifiedParams.length > 0
|
|
3014
|
-
|
|
3015
|
-
: `${getProxyPath()}/variables/${encodeURIComponent(String(variableName))}`;
|
|
3016
|
-
};
|
|
3191
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/variables/${encodeURIComponent(String(variableName))}?${stringifiedParams}` : `${getProxyPath()}/variables/${encodeURIComponent(String(variableName))}`
|
|
3192
|
+
}
|
|
3017
3193
|
|
|
3018
3194
|
/**
|
|
3019
3195
|
* Removes the variable this owner entered under this name.
|
|
@@ -3023,32 +3199,34 @@ export const getDeleteVariableUrl = (variableName: string, params: DeleteVariabl
|
|
|
3023
3199
|
* that owner's value standing.
|
|
3024
3200
|
* @summary Delete a variable
|
|
3025
3201
|
*/
|
|
3026
|
-
export const deleteVariable = async (
|
|
3027
|
-
|
|
3028
|
-
|
|
3029
|
-
|
|
3030
|
-
|
|
3031
|
-
return customFetch<void>(getDeleteVariableUrl(variableName, params), {
|
|
3202
|
+
export const deleteVariable = async (variableName: string,
|
|
3203
|
+
params: DeleteVariableParams, options?: Parameters<typeof customFetch>[1]): Promise<void> => {
|
|
3204
|
+
|
|
3205
|
+
return customFetch<void>(getDeleteVariableUrl(variableName,params),
|
|
3206
|
+
{
|
|
3032
3207
|
...options,
|
|
3033
|
-
method:
|
|
3034
|
-
|
|
3035
|
-
|
|
3208
|
+
method: 'DELETE'
|
|
3209
|
+
|
|
3210
|
+
|
|
3211
|
+
}
|
|
3212
|
+
);}
|
|
3213
|
+
|
|
3036
3214
|
|
|
3037
|
-
|
|
3215
|
+
|
|
3216
|
+
export const getCreateDeploymentUrl = (params: CreateDeploymentParams,) => {
|
|
3038
3217
|
const normalizedParams = new URLSearchParams();
|
|
3039
3218
|
|
|
3040
3219
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
3220
|
+
|
|
3041
3221
|
if (value !== undefined) {
|
|
3042
|
-
normalizedParams.append(key, value === null ?
|
|
3222
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
3043
3223
|
}
|
|
3044
3224
|
});
|
|
3045
3225
|
|
|
3046
3226
|
const stringifiedParams = normalizedParams.toString();
|
|
3047
3227
|
|
|
3048
|
-
return stringifiedParams.length > 0
|
|
3049
|
-
|
|
3050
|
-
: `${getProxyPath()}/deployments`;
|
|
3051
|
-
};
|
|
3228
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/deployments?${stringifiedParams}` : `${getProxyPath()}/deployments`
|
|
3229
|
+
}
|
|
3052
3230
|
|
|
3053
3231
|
/**
|
|
3054
3232
|
* Makes a release live on an environment by recording a deployment. The two
|
|
@@ -3075,22 +3253,15 @@ export const getCreateDeploymentUrl = (params: CreateDeploymentParams) => {
|
|
|
3075
3253
|
* actual `current_deployment_id` and `current_release_id` in the details.
|
|
3076
3254
|
* @summary Create a deployment
|
|
3077
3255
|
*/
|
|
3078
|
-
export const createDeployment = async (
|
|
3079
|
-
|
|
3080
|
-
|
|
3081
|
-
|
|
3082
|
-
): Promise<CreateDeployment200 | CreateDeployment201> => {
|
|
3083
|
-
const getHeaders = (
|
|
3084
|
-
h?: NonNullable<RequestInit["headers"]>,
|
|
3085
|
-
): Record<string, string | readonly string[]> => {
|
|
3256
|
+
export const createDeployment = async (createDeploymentBody: CreateDeploymentBody,
|
|
3257
|
+
params: CreateDeploymentParams, options?: Parameters<typeof customFetch>[1]): Promise<CreateDeployment200 | CreateDeployment201> => {
|
|
3258
|
+
|
|
3259
|
+
const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {
|
|
3086
3260
|
if (!h) return {};
|
|
3087
3261
|
if (h instanceof Headers) return Object.fromEntries(h.entries());
|
|
3088
3262
|
if (Symbol.iterator in h) {
|
|
3089
3263
|
return Object.fromEntries(
|
|
3090
|
-
Array.from(
|
|
3091
|
-
h as Iterable<Iterable<string>>,
|
|
3092
|
-
(entry) => Array.from(entry) as [string, string],
|
|
3093
|
-
),
|
|
3264
|
+
Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),
|
|
3094
3265
|
);
|
|
3095
3266
|
}
|
|
3096
3267
|
const headers: Record<string, string | readonly string[]> = {};
|
|
@@ -3099,15 +3270,18 @@ export const createDeployment = async (
|
|
|
3099
3270
|
}
|
|
3100
3271
|
return headers;
|
|
3101
3272
|
};
|
|
3102
|
-
|
|
3273
|
+
return customFetch<CreateDeployment200 | CreateDeployment201>(getCreateDeploymentUrl(params),
|
|
3274
|
+
{
|
|
3103
3275
|
...options,
|
|
3104
|
-
method:
|
|
3105
|
-
headers: {
|
|
3106
|
-
body: JSON.stringify(createDeploymentBody)
|
|
3107
|
-
}
|
|
3108
|
-
}
|
|
3276
|
+
method: 'POST',
|
|
3277
|
+
headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },
|
|
3278
|
+
body: JSON.stringify(createDeploymentBody)
|
|
3279
|
+
}
|
|
3280
|
+
);}
|
|
3109
3281
|
|
|
3110
|
-
|
|
3282
|
+
|
|
3283
|
+
|
|
3284
|
+
export const getListDeploymentsUrl = (params: ListDeploymentsParams,) => {
|
|
3111
3285
|
const normalizedParams = new URLSearchParams();
|
|
3112
3286
|
|
|
3113
3287
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
@@ -3115,22 +3289,20 @@ export const getListDeploymentsUrl = (params: ListDeploymentsParams) => {
|
|
|
3115
3289
|
|
|
3116
3290
|
if (Array.isArray(value) && explodeParameters.includes(key)) {
|
|
3117
3291
|
value.forEach((v) => {
|
|
3118
|
-
normalizedParams.append(key, v === null ?
|
|
3292
|
+
normalizedParams.append(key, v === null ? 'null' : String(v));
|
|
3119
3293
|
});
|
|
3120
3294
|
return;
|
|
3121
3295
|
}
|
|
3122
3296
|
|
|
3123
3297
|
if (value !== undefined) {
|
|
3124
|
-
normalizedParams.append(key, value === null ?
|
|
3298
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
3125
3299
|
}
|
|
3126
3300
|
});
|
|
3127
3301
|
|
|
3128
3302
|
const stringifiedParams = normalizedParams.toString();
|
|
3129
3303
|
|
|
3130
|
-
return stringifiedParams.length > 0
|
|
3131
|
-
|
|
3132
|
-
: `${getProxyPath()}/deployments`;
|
|
3133
|
-
};
|
|
3304
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/deployments?${stringifiedParams}` : `${getProxyPath()}/deployments`
|
|
3305
|
+
}
|
|
3134
3306
|
|
|
3135
3307
|
/**
|
|
3136
3308
|
* Lists deployments newest first: what ran where, and when.
|
|
@@ -3146,31 +3318,34 @@ export const getListDeploymentsUrl = (params: ListDeploymentsParams) => {
|
|
|
3146
3318
|
* ordering or the page tokens.
|
|
3147
3319
|
* @summary List deployments
|
|
3148
3320
|
*/
|
|
3149
|
-
export const listDeployments = async (
|
|
3150
|
-
|
|
3151
|
-
|
|
3152
|
-
|
|
3153
|
-
return customFetch<ListDeployments200>(getListDeploymentsUrl(params), {
|
|
3321
|
+
export const listDeployments = async (params: ListDeploymentsParams, options?: Parameters<typeof customFetch>[1]): Promise<ListDeployments200> => {
|
|
3322
|
+
|
|
3323
|
+
return customFetch<ListDeployments200>(getListDeploymentsUrl(params),
|
|
3324
|
+
{
|
|
3154
3325
|
...options,
|
|
3155
|
-
method:
|
|
3156
|
-
|
|
3157
|
-
|
|
3326
|
+
method: 'GET'
|
|
3327
|
+
|
|
3328
|
+
|
|
3329
|
+
}
|
|
3330
|
+
);}
|
|
3331
|
+
|
|
3332
|
+
|
|
3158
3333
|
|
|
3159
|
-
export const getGetDeploymentByIdUrl = (deploymentId: string,
|
|
3334
|
+
export const getGetDeploymentByIdUrl = (deploymentId: string,
|
|
3335
|
+
params: GetDeploymentByIdParams,) => {
|
|
3160
3336
|
const normalizedParams = new URLSearchParams();
|
|
3161
3337
|
|
|
3162
3338
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
3339
|
+
|
|
3163
3340
|
if (value !== undefined) {
|
|
3164
|
-
normalizedParams.append(key, value === null ?
|
|
3341
|
+
normalizedParams.append(key, value === null ? 'null' : String(value))
|
|
3165
3342
|
}
|
|
3166
3343
|
});
|
|
3167
3344
|
|
|
3168
3345
|
const stringifiedParams = normalizedParams.toString();
|
|
3169
3346
|
|
|
3170
|
-
return stringifiedParams.length > 0
|
|
3171
|
-
|
|
3172
|
-
: `${getProxyPath()}/deployments/${encodeURIComponent(String(deploymentId))}`;
|
|
3173
|
-
};
|
|
3347
|
+
return stringifiedParams.length > 0 ? `${getProxyPath()}/deployments/${encodeURIComponent(String(deploymentId))}?${stringifiedParams}` : `${getProxyPath()}/deployments/${encodeURIComponent(String(deploymentId))}`
|
|
3348
|
+
}
|
|
3174
3349
|
|
|
3175
3350
|
/**
|
|
3176
3351
|
* Reads one deployment record.
|
|
@@ -3181,13 +3356,17 @@ export const getGetDeploymentByIdUrl = (deploymentId: string, params: GetDeploym
|
|
|
3181
3356
|
* the caller cannot read.
|
|
3182
3357
|
* @summary Get a deployment by id
|
|
3183
3358
|
*/
|
|
3184
|
-
export const getDeploymentById = async (
|
|
3185
|
-
|
|
3186
|
-
|
|
3187
|
-
|
|
3188
|
-
|
|
3189
|
-
return customFetch<GetDeploymentById200>(getGetDeploymentByIdUrl(deploymentId, params), {
|
|
3359
|
+
export const getDeploymentById = async (deploymentId: string,
|
|
3360
|
+
params: GetDeploymentByIdParams, options?: Parameters<typeof customFetch>[1]): Promise<GetDeploymentById200> => {
|
|
3361
|
+
|
|
3362
|
+
return customFetch<GetDeploymentById200>(getGetDeploymentByIdUrl(deploymentId,params),
|
|
3363
|
+
{
|
|
3190
3364
|
...options,
|
|
3191
|
-
method:
|
|
3192
|
-
|
|
3193
|
-
|
|
3365
|
+
method: 'GET'
|
|
3366
|
+
|
|
3367
|
+
|
|
3368
|
+
}
|
|
3369
|
+
);}
|
|
3370
|
+
|
|
3371
|
+
|
|
3372
|
+
|