UNPKG

@docusign/iam-sdk

Version:

Developer-friendly & type-safe Typescript SDK specifically catered to leverage *@docusign/iam-sdk* API.

70 lines 3.02 kB
import * as z from "zod"; import { ClosedEnum } from "../../types/enums.js"; import { Result as SafeParseResult } from "../../types/fp.js"; import { SDKValidationError } from "../errors/sdkvalidationerror.js"; export declare const GetTokenFromJWTGrantServerList: readonly ["https://account-d.docusign.com", "https://account.docusign.com"]; /** * The grant type. */ export declare const GetTokenFromJWTGrantGrantType: { readonly UrnIetfParamsOauthGrantTypeJwtBearer: "urn:ietf:params:oauth:grant-type:jwt-bearer"; }; /** * The grant type. */ export type GetTokenFromJWTGrantGrantType = ClosedEnum<typeof GetTokenFromJWTGrantGrantType>; /** * JSON Web Token (JWT) Grant is an OAuth 2.0 flow that is used to grant an access token to service integrations */ export type JWTGrant = { /** * The grant type. */ grantType?: GetTokenFromJWTGrantGrantType | undefined; /** * Your JWT */ assertion: string; }; /** @internal */ export declare const GetTokenFromJWTGrantGrantType$inboundSchema: z.ZodNativeEnum<typeof GetTokenFromJWTGrantGrantType>; /** @internal */ export declare const GetTokenFromJWTGrantGrantType$outboundSchema: z.ZodNativeEnum<typeof GetTokenFromJWTGrantGrantType>; /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ export declare namespace GetTokenFromJWTGrantGrantType$ { /** @deprecated use `GetTokenFromJWTGrantGrantType$inboundSchema` instead. */ const inboundSchema: z.ZodNativeEnum<{ readonly UrnIetfParamsOauthGrantTypeJwtBearer: "urn:ietf:params:oauth:grant-type:jwt-bearer"; }>; /** @deprecated use `GetTokenFromJWTGrantGrantType$outboundSchema` instead. */ const outboundSchema: z.ZodNativeEnum<{ readonly UrnIetfParamsOauthGrantTypeJwtBearer: "urn:ietf:params:oauth:grant-type:jwt-bearer"; }>; } /** @internal */ export declare const JWTGrant$inboundSchema: z.ZodType<JWTGrant, z.ZodTypeDef, unknown>; /** @internal */ export type JWTGrant$Outbound = { grant_type: string; assertion: string; }; /** @internal */ export declare const JWTGrant$outboundSchema: z.ZodType<JWTGrant$Outbound, z.ZodTypeDef, JWTGrant>; /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ export declare namespace JWTGrant$ { /** @deprecated use `JWTGrant$inboundSchema` instead. */ const inboundSchema: z.ZodType<JWTGrant, z.ZodTypeDef, unknown>; /** @deprecated use `JWTGrant$outboundSchema` instead. */ const outboundSchema: z.ZodType<JWTGrant$Outbound, z.ZodTypeDef, JWTGrant>; /** @deprecated use `JWTGrant$Outbound` instead. */ type Outbound = JWTGrant$Outbound; } export declare function jwtGrantToJSON(jwtGrant: JWTGrant): string; export declare function jwtGrantFromJSON(jsonString: string): SafeParseResult<JWTGrant, SDKValidationError>; //# sourceMappingURL=gettokenfromjwtgrant.d.ts.map