diff --git a/src/transform/schema.ts b/src/transform/schema.ts index 14913b3fe..f54e6b806 100644 --- a/src/transform/schema.ts +++ b/src/transform/schema.ts @@ -8,6 +8,8 @@ import { tsReadonly, tsTupleOf, tsUnionOf, + parseSingleSimpleValue, + ParsedSimpleValue, } from "../utils.js"; interface TransformSchemaObjOptions extends GlobalContext { @@ -112,12 +114,15 @@ export function transformSchemaObj(node: any, options: TransformSchemaObjOptions output += nodeType(node); break; } + case "const": { + output += parseSingleSimpleValue(node.const, node.nullable); + break; + } case "enum": { - const items: Array = []; + const items: Array = []; (node.enum as unknown[]).forEach((item) => { - if (typeof item === "string") items.push(`'${item.replace(/'/g, "\\'")}'`); - else if (typeof item === "number" || typeof item === "boolean") items.push(item); - else if (item === null && !node.nullable) items.push("null"); + const value = parseSingleSimpleValue(item, node.nullable); + items.push(value); }); output += tsUnionOf(items); break; diff --git a/src/utils.ts b/src/utils.ts index bcb9d21a7..31239bc82 100644 --- a/src/utils.ts +++ b/src/utils.ts @@ -1,12 +1,16 @@ import { OpenAPI2, OpenAPI3, ReferenceObject } from "./types"; type CommentObject = { - title?: string; // not jsdoc - format?: string; // not jsdoc + const?: boolean; // jsdoc without value + default?: string; // jsdoc with value deprecated?: boolean; // jsdoc without value description?: string; // jsdoc with value - default?: string; // jsdoc with value + enum?: boolean; // jsdoc without value example?: string; // jsdoc with value + format?: string; // not jsdoc + nullable?: boolean; // Node information + title?: string; // not jsdoc + type: string; // Type of node }; /** @@ -32,6 +36,15 @@ export function prepareComment(v: CommentObject): string | void { if (v[field]) commentsArray.push(`@${field} ${v[field]} `); } + // * JSDOC 'Constant' without value + if (v.const) commentsArray.push(`@constant `); + + // * JSDOC 'Enum' with type + if (v.enum) { + const canBeNull = v.nullable ? `|${null}` : ""; + commentsArray.push(`@enum {${v.type}${canBeNull}}`); + } + if (!commentsArray.length) return; return comment(commentsArray.join("\n")); @@ -68,6 +81,25 @@ export function isRef(obj: any): obj is ReferenceObject { return !!obj.$ref; } +export type ParsedSimpleValue = string | number | boolean; + +/** + * For parsing CONST / ENUM single values + * @param value - node.const or node.enum[I] for parsing + * @param isNodeNullable - node.nullable + * @returns parsed value + */ +export function parseSingleSimpleValue(value: unknown, isNodeNullable = false): ParsedSimpleValue { + if (typeof value === "string") return `'${value.replace(/'/g, "\\'")}'`; + + if (typeof value === "number" || typeof value === "boolean") return value; + + if (value === null && !isNodeNullable) return "null"; + + // Edge case + return `${value}`; +} + /** Return type of node (works for v2 or v3, as there are no conflicting types) */ type SchemaObjectType = | "anyOf" @@ -79,6 +111,7 @@ type SchemaObjectType = | "oneOf" | "ref" | "string" + | "const" | "unknown"; export function nodeType(obj: any): SchemaObjectType { if (!obj || typeof obj !== "object") { @@ -89,6 +122,11 @@ export function nodeType(obj: any): SchemaObjectType { return "ref"; } + // const + if (obj.const) { + return "const"; + } + // enum if (Array.isArray(obj.enum) && obj.enum.length) { return "enum"; diff --git a/test/bin/expected/prettier-js.ts b/test/bin/expected/prettier-js.ts index 381a546db..733c95a71 100644 --- a/test/bin/expected/prettier-js.ts +++ b/test/bin/expected/prettier-js.ts @@ -74,7 +74,10 @@ export interface components { quantity?: number /** Format: date-time */ shipDate?: string - /** @description Order Status */ + /** + * @description Order Status + * @enum {string} + */ status?: 'placed' | 'approved' | 'delivered' complete?: boolean } @@ -111,7 +114,10 @@ export interface components { name: string photoUrls: string[] tags?: components['schemas']['Tag'][] - /** @description pet status in the store */ + /** + * @description pet status in the store + * @enum {string} + */ status?: 'available' | 'pending' | 'sold' } ApiResponse: { diff --git a/test/bin/expected/prettier-json.ts b/test/bin/expected/prettier-json.ts index 381a546db..733c95a71 100644 --- a/test/bin/expected/prettier-json.ts +++ b/test/bin/expected/prettier-json.ts @@ -74,7 +74,10 @@ export interface components { quantity?: number /** Format: date-time */ shipDate?: string - /** @description Order Status */ + /** + * @description Order Status + * @enum {string} + */ status?: 'placed' | 'approved' | 'delivered' complete?: boolean } @@ -111,7 +114,10 @@ export interface components { name: string photoUrls: string[] tags?: components['schemas']['Tag'][] - /** @description pet status in the store */ + /** + * @description pet status in the store + * @enum {string} + */ status?: 'available' | 'pending' | 'sold' } ApiResponse: { diff --git a/test/bin/expected/specs/manifold.ts b/test/bin/expected/specs/manifold.ts index b7624c540..b6ea325a3 100644 --- a/test/bin/expected/specs/manifold.ts +++ b/test/bin/expected/specs/manifold.ts @@ -556,7 +556,9 @@ export interface definitions { }; Region: { id: definitions["ID"]; + /** @enum {string} */ type: "region"; + /** @enum {integer} */ version: 1; body: definitions["RegionBody"]; }; @@ -590,7 +592,9 @@ export interface definitions { }; Provider: { id: definitions["ID"]; + /** @enum {integer} */ version: 1; + /** @enum {string} */ type: "provider"; body: definitions["ProviderBody"]; }; @@ -633,13 +637,17 @@ export interface definitions { base_url?: string; /** Format: url */ sso_url?: string; + /** @enum {string} */ version?: "v1"; /** @default [object Object] */ features?: { access_code?: boolean; sso?: boolean; plan_change?: boolean; - /** @default multiple */ + /** + * @default multiple + * @enum {string} + */ credential?: "none" | "single" | "multiple" | "unknown"; }; }; @@ -678,6 +686,7 @@ export interface definitions { FeatureType: { label: definitions["Label"]; name: definitions["Name"]; + /** @enum {string} */ type: "boolean" | "string" | "number"; /** @description This sets whether or not the feature can be customized by a consumer. */ customizable?: boolean; @@ -803,6 +812,7 @@ export interface definitions { ProductImageURL: string; /** @description List of tags for product categorization and search */ ProductTags: definitions["Label"][]; + /** @enum {string} */ ProductState: "available" | "hidden" | "grandfathered" | "new" | "upcoming"; /** @default [object Object] */ ProductListing: { @@ -854,6 +864,8 @@ export interface definitions { * Pre-Order, should not be used yet. But in the future it should allow people to * pre-provision a resource for when it does go live. * Public, means the resource is live and everyone should be able to provision it. + * + * @enum {string} */ ProductProvisioning: "provider-only" | "pre-order" | "public"; /** @default [object Object] */ @@ -877,6 +889,8 @@ export interface definitions { * @description Describes how the region for a resource is specified, if * unspecified, then regions have no impact on this * resource. + * + * @enum {string} */ region?: "user-specified" | "unspecified"; /** @@ -888,6 +902,7 @@ export interface definitions { * * `unknown`: The credential type is unknown. * * @default multiple + * @enum {string} */ credential?: "none" | "single" | "multiple" | "unknown"; }; @@ -921,7 +936,9 @@ export interface definitions { }; feature_types: definitions["FeatureType"][]; billing: { + /** @enum {string} */ type: "monthly-prorated" | "monthly-anniversary" | "annual-anniversary"; + /** @enum {string} */ currency: "usd"; }; integration: { @@ -930,6 +947,7 @@ export interface definitions { base_url: string; /** Format: url */ sso_url?: string; + /** @enum {string} */ version: "v1"; features: definitions["ProductIntegrationFeatures"]; }; @@ -937,7 +955,9 @@ export interface definitions { }; Product: { id: definitions["ID"]; + /** @enum {integer} */ version: 1; + /** @enum {string} */ type: "product"; body: definitions["ProductBody"]; }; @@ -966,6 +986,7 @@ export interface definitions { /** @description Dollar value in cents. */ cost: number; }; + /** @enum {string} */ PlanState: "hidden" | "available" | "grandfathered" | "unlisted"; ExpandedPlanBody: definitions["PlanBody"] & { /** @description An array of feature definitions for the plan, as defined on the Product. */ @@ -984,13 +1005,17 @@ export interface definitions { }; Plan: { id: definitions["ID"]; + /** @enum {integer} */ version: 1; + /** @enum {string} */ type: "plan"; body: definitions["PlanBody"]; }; ExpandedPlan: { id: definitions["ID"]; + /** @enum {integer} */ version: 1; + /** @enum {string} */ type: "plan"; body: definitions["ExpandedPlanBody"]; }; @@ -1030,7 +1055,9 @@ export interface definitions { PriceFormula: string; ExpandedProduct: { id: definitions["ID"]; + /** @enum {integer} */ version: 1; + /** @enum {string} */ type: "product"; body: definitions["ProductBody"]; plans?: definitions["ExpandedPlan"][]; diff --git a/test/bin/expected/specs/petstore.ts b/test/bin/expected/specs/petstore.ts index 6e9dda83f..9199645c1 100644 --- a/test/bin/expected/specs/petstore.ts +++ b/test/bin/expected/specs/petstore.ts @@ -74,7 +74,10 @@ export interface components { quantity?: number; /** Format: date-time */ shipDate?: string; - /** @description Order Status */ + /** + * @description Order Status + * @enum {string} + */ status?: "placed" | "approved" | "delivered"; complete?: boolean; }; @@ -111,7 +114,10 @@ export interface components { name: string; photoUrls: string[]; tags?: components["schemas"]["Tag"][]; - /** @description pet status in the store */ + /** + * @description pet status in the store + * @enum {string} + */ status?: "available" | "pending" | "sold"; }; ApiResponse: { diff --git a/test/bin/expected/stdout.ts b/test/bin/expected/stdout.ts index 6e9dda83f..9199645c1 100644 --- a/test/bin/expected/stdout.ts +++ b/test/bin/expected/stdout.ts @@ -74,7 +74,10 @@ export interface components { quantity?: number; /** Format: date-time */ shipDate?: string; - /** @description Order Status */ + /** + * @description Order Status + * @enum {string} + */ status?: "placed" | "approved" | "delivered"; complete?: boolean; }; @@ -111,7 +114,10 @@ export interface components { name: string; photoUrls: string[]; tags?: components["schemas"]["Tag"][]; - /** @description pet status in the store */ + /** + * @description pet status in the store + * @enum {string} + */ status?: "available" | "pending" | "sold"; }; ApiResponse: { diff --git a/test/core/schema.test.js b/test/core/schema.test.js index dd4f4c4e9..6a140f872 100644 --- a/test/core/schema.test.js +++ b/test/core/schema.test.js @@ -155,6 +155,7 @@ describe("SchemaObject", () => { expect( transform({ properties: { string: { type: "string", enum: enumBasic } }, type: "object" }, { ...defaults }) ).to.equal(`{ +/** @enum {string} */ "string"?: ('Totoro') | ('Sats\\'uki') | ('Mei'); }`); @@ -162,6 +163,7 @@ describe("SchemaObject", () => { const enumNull = ["Totoro", "Sats'uki", "Mei", null]; expect(transform({ properties: { string: { type: "string", enum: enumNull } }, type: "object" }, { ...defaults })) .to.equal(`{ +/** @enum {string} */ "string"?: ('Totoro') | ('Sats\\'uki') | ('Mei') | (null); }`); @@ -170,6 +172,7 @@ describe("SchemaObject", () => { expect( transform({ properties: { string: { type: "string", enum: enumMixed } }, type: "object" }, { ...defaults }) ).to.equal(`{ +/** @enum {string} */ "string"?: ('Totoro') | (2) | (false) | (null); }`); @@ -181,7 +184,8 @@ describe("SchemaObject", () => { { ...defaults } ) ).to.equal(`{ -"string"?: (('Totoro') | (2) | (false)) | null; +/** @enum {string|null} */ +"string"?: (('Totoro') | (2) | (false) | (null)) | null; }`); @@ -193,6 +197,7 @@ describe("SchemaObject", () => { { ...defaults } ) ).to.equal(`{ +/** @enum {string|null} */ "string"?: (('Totoro') | (2) | (false)) | null; }`); @@ -202,12 +207,15 @@ describe("SchemaObject", () => { transform({ properties: { string: { type: "string", enum: [] } }, type: "object" }, { ...defaults }) ).to.equal( `{ +/** @enum {string} */ "string"?: string; }` ); }); + console.log("ASD LAST"); + it("$ref", () => { expect(transform({ $ref: 'components["parameters"]["ReferenceObject"]' }, { ...defaults })).to.equal( `components["parameters"]["ReferenceObject"]` diff --git a/test/opts/expected/remote-schema.ts b/test/opts/expected/remote-schema.ts index 7b51a6229..683794a51 100644 --- a/test/opts/expected/remote-schema.ts +++ b/test/opts/expected/remote-schema.ts @@ -88,7 +88,10 @@ export interface external { quantity?: number; /** Format: date-time */ shipDate?: string; - /** @description Order Status */ + /** + * @description Order Status + * @enum {string} + */ status?: "placed" | "approved" | "delivered"; complete?: boolean; }; @@ -125,7 +128,10 @@ export interface external { name: string; photoUrls: string[]; tags?: external["https://raw.githubusercontent.com/drwpow/openapi-typescript/main/test/v3/specs/petstore.yaml"]["components"]["schemas"]["Tag"][]; - /** @description pet status in the store */ + /** + * @description pet status in the store + * @enum {string} + */ status?: "available" | "pending" | "sold"; }; ApiResponse: { diff --git a/test/opts/remote-schema.test.js b/test/opts/remote-schema.test.js index 18819dad7..07a6a03cc 100644 --- a/test/opts/remote-schema.test.js +++ b/test/opts/remote-schema.test.js @@ -7,6 +7,7 @@ describe("remote $refs", () => { it("resolves remote $refs", async () => { const generated = await openapiTS(new URL("./fixtures/remote-schema/spec.yml", import.meta.url)); const expected = eol.lf(fs.readFileSync(new URL("./expected/remote-schema.ts", import.meta.url), "utf8")); + expect(generated).to.equal(expected); }); }); diff --git a/test/v2/expected/http.ts b/test/v2/expected/http.ts index b7624c540..b6ea325a3 100644 --- a/test/v2/expected/http.ts +++ b/test/v2/expected/http.ts @@ -556,7 +556,9 @@ export interface definitions { }; Region: { id: definitions["ID"]; + /** @enum {string} */ type: "region"; + /** @enum {integer} */ version: 1; body: definitions["RegionBody"]; }; @@ -590,7 +592,9 @@ export interface definitions { }; Provider: { id: definitions["ID"]; + /** @enum {integer} */ version: 1; + /** @enum {string} */ type: "provider"; body: definitions["ProviderBody"]; }; @@ -633,13 +637,17 @@ export interface definitions { base_url?: string; /** Format: url */ sso_url?: string; + /** @enum {string} */ version?: "v1"; /** @default [object Object] */ features?: { access_code?: boolean; sso?: boolean; plan_change?: boolean; - /** @default multiple */ + /** + * @default multiple + * @enum {string} + */ credential?: "none" | "single" | "multiple" | "unknown"; }; }; @@ -678,6 +686,7 @@ export interface definitions { FeatureType: { label: definitions["Label"]; name: definitions["Name"]; + /** @enum {string} */ type: "boolean" | "string" | "number"; /** @description This sets whether or not the feature can be customized by a consumer. */ customizable?: boolean; @@ -803,6 +812,7 @@ export interface definitions { ProductImageURL: string; /** @description List of tags for product categorization and search */ ProductTags: definitions["Label"][]; + /** @enum {string} */ ProductState: "available" | "hidden" | "grandfathered" | "new" | "upcoming"; /** @default [object Object] */ ProductListing: { @@ -854,6 +864,8 @@ export interface definitions { * Pre-Order, should not be used yet. But in the future it should allow people to * pre-provision a resource for when it does go live. * Public, means the resource is live and everyone should be able to provision it. + * + * @enum {string} */ ProductProvisioning: "provider-only" | "pre-order" | "public"; /** @default [object Object] */ @@ -877,6 +889,8 @@ export interface definitions { * @description Describes how the region for a resource is specified, if * unspecified, then regions have no impact on this * resource. + * + * @enum {string} */ region?: "user-specified" | "unspecified"; /** @@ -888,6 +902,7 @@ export interface definitions { * * `unknown`: The credential type is unknown. * * @default multiple + * @enum {string} */ credential?: "none" | "single" | "multiple" | "unknown"; }; @@ -921,7 +936,9 @@ export interface definitions { }; feature_types: definitions["FeatureType"][]; billing: { + /** @enum {string} */ type: "monthly-prorated" | "monthly-anniversary" | "annual-anniversary"; + /** @enum {string} */ currency: "usd"; }; integration: { @@ -930,6 +947,7 @@ export interface definitions { base_url: string; /** Format: url */ sso_url?: string; + /** @enum {string} */ version: "v1"; features: definitions["ProductIntegrationFeatures"]; }; @@ -937,7 +955,9 @@ export interface definitions { }; Product: { id: definitions["ID"]; + /** @enum {integer} */ version: 1; + /** @enum {string} */ type: "product"; body: definitions["ProductBody"]; }; @@ -966,6 +986,7 @@ export interface definitions { /** @description Dollar value in cents. */ cost: number; }; + /** @enum {string} */ PlanState: "hidden" | "available" | "grandfathered" | "unlisted"; ExpandedPlanBody: definitions["PlanBody"] & { /** @description An array of feature definitions for the plan, as defined on the Product. */ @@ -984,13 +1005,17 @@ export interface definitions { }; Plan: { id: definitions["ID"]; + /** @enum {integer} */ version: 1; + /** @enum {string} */ type: "plan"; body: definitions["PlanBody"]; }; ExpandedPlan: { id: definitions["ID"]; + /** @enum {integer} */ version: 1; + /** @enum {string} */ type: "plan"; body: definitions["ExpandedPlanBody"]; }; @@ -1030,7 +1055,9 @@ export interface definitions { PriceFormula: string; ExpandedProduct: { id: definitions["ID"]; + /** @enum {integer} */ version: 1; + /** @enum {string} */ type: "product"; body: definitions["ProductBody"]; plans?: definitions["ExpandedPlan"][]; diff --git a/test/v2/expected/manifold.immutable.ts b/test/v2/expected/manifold.immutable.ts index a31303509..16c385573 100644 --- a/test/v2/expected/manifold.immutable.ts +++ b/test/v2/expected/manifold.immutable.ts @@ -556,7 +556,9 @@ export interface definitions { }; readonly Region: { readonly id: definitions["ID"]; + /** @enum {string} */ readonly type: "region"; + /** @enum {integer} */ readonly version: 1; readonly body: definitions["RegionBody"]; }; @@ -590,7 +592,9 @@ export interface definitions { }; readonly Provider: { readonly id: definitions["ID"]; + /** @enum {integer} */ readonly version: 1; + /** @enum {string} */ readonly type: "provider"; readonly body: definitions["ProviderBody"]; }; @@ -633,13 +637,17 @@ export interface definitions { readonly base_url?: string; /** Format: url */ readonly sso_url?: string; + /** @enum {string} */ readonly version?: "v1"; /** @default [object Object] */ readonly features?: { readonly access_code?: boolean; readonly sso?: boolean; readonly plan_change?: boolean; - /** @default multiple */ + /** + * @default multiple + * @enum {string} + */ readonly credential?: "none" | "single" | "multiple" | "unknown"; }; }; @@ -678,6 +686,7 @@ export interface definitions { readonly FeatureType: { readonly label: definitions["Label"]; readonly name: definitions["Name"]; + /** @enum {string} */ readonly type: "boolean" | "string" | "number"; /** @description This sets whether or not the feature can be customized by a consumer. */ readonly customizable?: boolean; @@ -803,6 +812,7 @@ export interface definitions { readonly ProductImageURL: string; /** @description List of tags for product categorization and search */ readonly ProductTags: readonly definitions["Label"][]; + /** @enum {string} */ readonly ProductState: "available" | "hidden" | "grandfathered" | "new" | "upcoming"; /** @default [object Object] */ readonly ProductListing: { @@ -854,6 +864,8 @@ export interface definitions { * Pre-Order, should not be used yet. But in the future it should allow people to * pre-provision a resource for when it does go live. * Public, means the resource is live and everyone should be able to provision it. + * + * @enum {string} */ readonly ProductProvisioning: "provider-only" | "pre-order" | "public"; /** @default [object Object] */ @@ -877,6 +889,8 @@ export interface definitions { * @description Describes how the region for a resource is specified, if * unspecified, then regions have no impact on this * resource. + * + * @enum {string} */ readonly region?: "user-specified" | "unspecified"; /** @@ -888,6 +902,7 @@ export interface definitions { * * `unknown`: The credential type is unknown. * * @default multiple + * @enum {string} */ readonly credential?: "none" | "single" | "multiple" | "unknown"; }; @@ -921,7 +936,9 @@ export interface definitions { }; readonly feature_types: readonly definitions["FeatureType"][]; readonly billing: { + /** @enum {string} */ readonly type: "monthly-prorated" | "monthly-anniversary" | "annual-anniversary"; + /** @enum {string} */ readonly currency: "usd"; }; readonly integration: { @@ -930,6 +947,7 @@ export interface definitions { readonly base_url: string; /** Format: url */ readonly sso_url?: string; + /** @enum {string} */ readonly version: "v1"; readonly features: definitions["ProductIntegrationFeatures"]; }; @@ -937,7 +955,9 @@ export interface definitions { }; readonly Product: { readonly id: definitions["ID"]; + /** @enum {integer} */ readonly version: 1; + /** @enum {string} */ readonly type: "product"; readonly body: definitions["ProductBody"]; }; @@ -966,6 +986,7 @@ export interface definitions { /** @description Dollar value in cents. */ readonly cost: number; }; + /** @enum {string} */ readonly PlanState: "hidden" | "available" | "grandfathered" | "unlisted"; readonly ExpandedPlanBody: definitions["PlanBody"] & { /** @description An array of feature definitions for the plan, as defined on the Product. */ @@ -984,13 +1005,17 @@ export interface definitions { }; readonly Plan: { readonly id: definitions["ID"]; + /** @enum {integer} */ readonly version: 1; + /** @enum {string} */ readonly type: "plan"; readonly body: definitions["PlanBody"]; }; readonly ExpandedPlan: { readonly id: definitions["ID"]; + /** @enum {integer} */ readonly version: 1; + /** @enum {string} */ readonly type: "plan"; readonly body: definitions["ExpandedPlanBody"]; }; @@ -1030,7 +1055,9 @@ export interface definitions { readonly PriceFormula: string; readonly ExpandedProduct: { readonly id: definitions["ID"]; + /** @enum {integer} */ readonly version: 1; + /** @enum {string} */ readonly type: "product"; readonly body: definitions["ProductBody"]; readonly plans?: readonly definitions["ExpandedPlan"][]; diff --git a/test/v2/expected/manifold.ts b/test/v2/expected/manifold.ts index b7624c540..b6ea325a3 100644 --- a/test/v2/expected/manifold.ts +++ b/test/v2/expected/manifold.ts @@ -556,7 +556,9 @@ export interface definitions { }; Region: { id: definitions["ID"]; + /** @enum {string} */ type: "region"; + /** @enum {integer} */ version: 1; body: definitions["RegionBody"]; }; @@ -590,7 +592,9 @@ export interface definitions { }; Provider: { id: definitions["ID"]; + /** @enum {integer} */ version: 1; + /** @enum {string} */ type: "provider"; body: definitions["ProviderBody"]; }; @@ -633,13 +637,17 @@ export interface definitions { base_url?: string; /** Format: url */ sso_url?: string; + /** @enum {string} */ version?: "v1"; /** @default [object Object] */ features?: { access_code?: boolean; sso?: boolean; plan_change?: boolean; - /** @default multiple */ + /** + * @default multiple + * @enum {string} + */ credential?: "none" | "single" | "multiple" | "unknown"; }; }; @@ -678,6 +686,7 @@ export interface definitions { FeatureType: { label: definitions["Label"]; name: definitions["Name"]; + /** @enum {string} */ type: "boolean" | "string" | "number"; /** @description This sets whether or not the feature can be customized by a consumer. */ customizable?: boolean; @@ -803,6 +812,7 @@ export interface definitions { ProductImageURL: string; /** @description List of tags for product categorization and search */ ProductTags: definitions["Label"][]; + /** @enum {string} */ ProductState: "available" | "hidden" | "grandfathered" | "new" | "upcoming"; /** @default [object Object] */ ProductListing: { @@ -854,6 +864,8 @@ export interface definitions { * Pre-Order, should not be used yet. But in the future it should allow people to * pre-provision a resource for when it does go live. * Public, means the resource is live and everyone should be able to provision it. + * + * @enum {string} */ ProductProvisioning: "provider-only" | "pre-order" | "public"; /** @default [object Object] */ @@ -877,6 +889,8 @@ export interface definitions { * @description Describes how the region for a resource is specified, if * unspecified, then regions have no impact on this * resource. + * + * @enum {string} */ region?: "user-specified" | "unspecified"; /** @@ -888,6 +902,7 @@ export interface definitions { * * `unknown`: The credential type is unknown. * * @default multiple + * @enum {string} */ credential?: "none" | "single" | "multiple" | "unknown"; }; @@ -921,7 +936,9 @@ export interface definitions { }; feature_types: definitions["FeatureType"][]; billing: { + /** @enum {string} */ type: "monthly-prorated" | "monthly-anniversary" | "annual-anniversary"; + /** @enum {string} */ currency: "usd"; }; integration: { @@ -930,6 +947,7 @@ export interface definitions { base_url: string; /** Format: url */ sso_url?: string; + /** @enum {string} */ version: "v1"; features: definitions["ProductIntegrationFeatures"]; }; @@ -937,7 +955,9 @@ export interface definitions { }; Product: { id: definitions["ID"]; + /** @enum {integer} */ version: 1; + /** @enum {string} */ type: "product"; body: definitions["ProductBody"]; }; @@ -966,6 +986,7 @@ export interface definitions { /** @description Dollar value in cents. */ cost: number; }; + /** @enum {string} */ PlanState: "hidden" | "available" | "grandfathered" | "unlisted"; ExpandedPlanBody: definitions["PlanBody"] & { /** @description An array of feature definitions for the plan, as defined on the Product. */ @@ -984,13 +1005,17 @@ export interface definitions { }; Plan: { id: definitions["ID"]; + /** @enum {integer} */ version: 1; + /** @enum {string} */ type: "plan"; body: definitions["PlanBody"]; }; ExpandedPlan: { id: definitions["ID"]; + /** @enum {integer} */ version: 1; + /** @enum {string} */ type: "plan"; body: definitions["ExpandedPlanBody"]; }; @@ -1030,7 +1055,9 @@ export interface definitions { PriceFormula: string; ExpandedProduct: { id: definitions["ID"]; + /** @enum {integer} */ version: 1; + /** @enum {string} */ type: "product"; body: definitions["ProductBody"]; plans?: definitions["ExpandedPlan"][]; diff --git a/test/v2/expected/null-in-enum.immutable.ts b/test/v2/expected/null-in-enum.immutable.ts index 706abd69c..25e168011 100644 --- a/test/v2/expected/null-in-enum.immutable.ts +++ b/test/v2/expected/null-in-enum.immutable.ts @@ -12,18 +12,22 @@ export interface paths { export interface definitions { /** @description Enum with null and nullable */ readonly MyType: { - readonly myField?: ("foo" | "bar") | null; + /** @enum {string|null} */ + readonly myField?: ("foo" | "bar" | null) | null; }; /** @description Enum with null */ readonly MyTypeNotNullable: { + /** @enum {string} */ readonly myField?: "foo" | "bar" | null; }; /** @description Enum with null */ readonly MyTypeNotNullableNotNull: { + /** @enum {string} */ readonly myField?: "foo" | "bar"; }; /** @description Enum with null */ readonly MyTypeMixed: { + /** @enum {string} */ readonly myField?: "foo" | 2 | false | null; }; } diff --git a/test/v2/expected/null-in-enum.ts b/test/v2/expected/null-in-enum.ts index 71ae8a2f9..1173795f1 100644 --- a/test/v2/expected/null-in-enum.ts +++ b/test/v2/expected/null-in-enum.ts @@ -12,18 +12,22 @@ export interface paths { export interface definitions { /** @description Enum with null and nullable */ MyType: { - myField?: ("foo" | "bar") | null; + /** @enum {string|null} */ + myField?: ("foo" | "bar" | null) | null; }; /** @description Enum with null */ MyTypeNotNullable: { + /** @enum {string} */ myField?: "foo" | "bar" | null; }; /** @description Enum with null */ MyTypeNotNullableNotNull: { + /** @enum {string} */ myField?: "foo" | "bar"; }; /** @description Enum with null */ MyTypeMixed: { + /** @enum {string} */ myField?: "foo" | 2 | false | null; }; } diff --git a/test/v2/expected/petstore.immutable.ts b/test/v2/expected/petstore.immutable.ts index a49b1bc9f..6f66eae0e 100644 --- a/test/v2/expected/petstore.immutable.ts +++ b/test/v2/expected/petstore.immutable.ts @@ -73,7 +73,10 @@ export interface definitions { readonly quantity?: number; /** Format: date-time */ readonly shipDate?: string; - /** @description Order Status */ + /** + * @description Order Status + * @enum {string} + */ readonly status?: "placed" | "approved" | "delivered"; readonly complete?: boolean; }; @@ -110,7 +113,10 @@ export interface definitions { readonly name: string; readonly photoUrls: readonly string[]; readonly tags?: readonly definitions["Tag"][]; - /** @description pet status in the store */ + /** + * @description pet status in the store + * @enum {string} + */ readonly status?: "available" | "pending" | "sold"; }; readonly ApiResponse: { diff --git a/test/v2/expected/petstore.ts b/test/v2/expected/petstore.ts index e2769212c..313827642 100644 --- a/test/v2/expected/petstore.ts +++ b/test/v2/expected/petstore.ts @@ -73,7 +73,10 @@ export interface definitions { quantity?: number; /** Format: date-time */ shipDate?: string; - /** @description Order Status */ + /** + * @description Order Status + * @enum {string} + */ status?: "placed" | "approved" | "delivered"; complete?: boolean; }; @@ -110,7 +113,10 @@ export interface definitions { name: string; photoUrls: string[]; tags?: definitions["Tag"][]; - /** @description pet status in the store */ + /** + * @description pet status in the store + * @enum {string} + */ status?: "available" | "pending" | "sold"; }; ApiResponse: { diff --git a/test/v2/expected/stripe.immutable.ts b/test/v2/expected/stripe.immutable.ts index d95142ce3..d5a668596 100644 --- a/test/v2/expected/stripe.immutable.ts +++ b/test/v2/expected/stripe.immutable.ts @@ -1492,7 +1492,10 @@ export interface definitions { */ readonly account: { readonly business_profile?: definitions["account_business_profile"]; - /** @description The business type. */ + /** + * @description The business type. + * @enum {string} + */ readonly business_type?: "company" | "government_entity" | "individual" | "non_profit"; readonly capabilities?: definitions["account_capabilities"]; /** @description Whether the account can create live charges. */ @@ -1517,7 +1520,10 @@ export interface definitions { readonly data: readonly definitions["bank_account"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -1527,14 +1533,20 @@ export interface definitions { readonly individual?: definitions["person"]; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata?: { readonly [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "account"; /** @description Whether Stripe can send payouts to this account. */ readonly payouts_enabled?: boolean; readonly requirements?: definitions["account_requirements"]; readonly settings?: definitions["account_settings"]; readonly tos_acceptance?: definitions["account_tos_acceptance"]; - /** @description The Stripe account type. Can be `standard`, `express`, or `custom`. */ + /** + * @description The Stripe account type. Can be `standard`, `express`, or `custom`. + * @enum {string} + */ readonly type?: "custom" | "express" | "standard"; }; /** AccountBrandingSettings */ @@ -1568,19 +1580,40 @@ export interface definitions { }; /** AccountCapabilities */ readonly account_capabilities: { - /** @description The status of the BECS Direct Debit (AU) payments capability of the account, or whether the account can directly process BECS Direct Debit (AU) charges. */ + /** + * @description The status of the BECS Direct Debit (AU) payments capability of the account, or whether the account can directly process BECS Direct Debit (AU) charges. + * @enum {string} + */ readonly au_becs_debit_payments?: "active" | "inactive" | "pending"; - /** @description The status of the card issuing capability of the account, or whether you can use Issuing to distribute funds on cards */ + /** + * @description The status of the card issuing capability of the account, or whether you can use Issuing to distribute funds on cards + * @enum {string} + */ readonly card_issuing?: "active" | "inactive" | "pending"; - /** @description The status of the card payments capability of the account, or whether the account can directly process credit and debit card charges. */ + /** + * @description The status of the card payments capability of the account, or whether the account can directly process credit and debit card charges. + * @enum {string} + */ readonly card_payments?: "active" | "inactive" | "pending"; - /** @description The status of the legacy payments capability of the account. */ + /** + * @description The status of the legacy payments capability of the account. + * @enum {string} + */ readonly legacy_payments?: "active" | "inactive" | "pending"; - /** @description The status of the tax reporting 1099-K (US) capability of the account. */ + /** + * @description The status of the tax reporting 1099-K (US) capability of the account. + * @enum {string} + */ readonly tax_reporting_us_1099_k?: "active" | "inactive" | "pending"; - /** @description The status of the tax reporting 1099-MISC (US) capability of the account. */ + /** + * @description The status of the tax reporting 1099-MISC (US) capability of the account. + * @enum {string} + */ readonly tax_reporting_us_1099_misc?: "active" | "inactive" | "pending"; - /** @description The status of the transfers capability of the account, or whether your platform can transfer funds to the account. */ + /** + * @description The status of the transfers capability of the account, or whether your platform can transfer funds to the account. + * @enum {string} + */ readonly transfers?: "active" | "inactive" | "pending"; }; /** AccountCapabilityRequirements */ @@ -1632,7 +1665,10 @@ export interface definitions { readonly created: number; /** @description The timestamp at which this account link will expire. */ readonly expires_at: number; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "account_link"; /** @description The URL for the account link. */ readonly url: string; @@ -1673,7 +1709,10 @@ export interface definitions { }; /** AccountRequirementsError */ readonly account_requirements_error: { - /** @description The code for the type of error. */ + /** + * @description The code for the type of error. + * @enum {string} + */ readonly code: | "invalid_address_city_state_postal_code" | "invalid_street_address" @@ -1764,7 +1803,10 @@ export interface definitions { readonly livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata?: { readonly [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "alipay_account"; /** @description If the Alipay account object is not reusable, the exact amount that you can create a charge for. */ readonly payment_amount?: number; @@ -1795,7 +1837,10 @@ export interface definitions { readonly payment_method?: definitions["payment_method"]; readonly setup_intent?: definitions["setup_intent"]; readonly source?: definitions["bank_account"]; - /** @description The type of error returned. One of `api_connection_error`, `api_error`, `authentication_error`, `card_error`, `idempotency_error`, `invalid_request_error`, or `rate_limit_error` */ + /** + * @description The type of error returned. One of `api_connection_error`, `api_error`, `authentication_error`, `card_error`, `idempotency_error`, `invalid_request_error`, or `rate_limit_error` + * @enum {string} + */ readonly type: | "api_connection_error" | "api_error" @@ -1814,7 +1859,10 @@ export interface definitions { readonly id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "apple_pay_domain"; }; /** Application */ @@ -1823,7 +1871,10 @@ export interface definitions { readonly id: string; /** @description The name of the application. */ readonly name?: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "application"; }; /** PlatformFee */ @@ -1848,7 +1899,10 @@ export interface definitions { readonly id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "application_fee"; /** @description ID of the corresponding charge on the platform account, if this fee was the result of a charge using the `destination` parameter. */ readonly originating_transaction?: string; @@ -1863,7 +1917,10 @@ export interface definitions { readonly data: readonly definitions["fee_refund"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -1890,7 +1947,10 @@ export interface definitions { readonly connect_reserved?: readonly definitions["balance_amount"][]; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "balance"; /** @description Funds that are not yet available in the balance, due to the 7-day rolling pay cycle. The pending balance for each currency, and for each payment type, can be found in the `source_types` property. */ readonly pending: readonly definitions["balance_amount"][]; @@ -1940,7 +2000,10 @@ export interface definitions { readonly id: string; /** @description Net amount of the transaction, in %s. */ readonly net: number; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "balance_transaction"; /** @description [Learn more](https://stripe.com/docs/reports/reporting-categories) about how reporting categories can help you understand balance transactions from an accounting perspective. */ readonly reporting_category: string; @@ -1948,7 +2011,10 @@ export interface definitions { readonly source?: string; /** @description If the transaction's net funds are available in the Stripe balance yet. Either `available` or `pending`. */ readonly status: string; - /** @description Transaction type: `adjustment`, `advance`, `advance_funding`, `application_fee`, `application_fee_refund`, `charge`, `connect_collection_transfer`, `issuing_authorization_hold`, `issuing_authorization_release`, `issuing_transaction`, `payment`, `payment_failure_refund`, `payment_refund`, `payout`, `payout_cancel`, `payout_failure`, `refund`, `refund_failure`, `reserve_transaction`, `reserved_funds`, `stripe_fee`, `stripe_fx_fee`, `tax_fee`, `topup`, `topup_reversal`, `transfer`, `transfer_cancel`, `transfer_failure`, or `transfer_refund`. [Learn more](https://stripe.com/docs/reports/balance-transaction-types) about balance transaction types and what they represent. If you are looking to classify transactions for accounting purposes, you might want to consider `reporting_category` instead. */ + /** + * @description Transaction type: `adjustment`, `advance`, `advance_funding`, `application_fee`, `application_fee_refund`, `charge`, `connect_collection_transfer`, `issuing_authorization_hold`, `issuing_authorization_release`, `issuing_transaction`, `payment`, `payment_failure_refund`, `payment_refund`, `payout`, `payout_cancel`, `payout_failure`, `refund`, `refund_failure`, `reserve_transaction`, `reserved_funds`, `stripe_fee`, `stripe_fx_fee`, `tax_fee`, `topup`, `topup_reversal`, `transfer`, `transfer_cancel`, `transfer_failure`, or `transfer_refund`. [Learn more](https://stripe.com/docs/reports/balance-transaction-types) about balance transaction types and what they represent. If you are looking to classify transactions for accounting purposes, you might want to consider `reporting_category` instead. + * @enum {string} + */ readonly type: | "adjustment" | "advance" @@ -2015,7 +2081,10 @@ export interface definitions { readonly last4: string; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata?: { readonly [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "bank_account"; /** @description The routing transit number for the bank account. */ readonly routing_number?: string; @@ -2055,7 +2124,10 @@ export interface definitions { readonly id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "billing_portal.session"; /** @description The URL to which Stripe should send customers when they click on the link to return to your website. */ readonly return_url: string; @@ -2096,7 +2168,10 @@ export interface definitions { readonly livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "bitcoin_receiver"; /** @description The ID of the payment created from the receiver, if any. Hidden when viewing the receiver with a publishable key. */ readonly payment?: string; @@ -2111,7 +2186,10 @@ export interface definitions { readonly data: readonly definitions["bitcoin_transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -2133,7 +2211,10 @@ export interface definitions { readonly currency: string; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "bitcoin_transaction"; /** @description The receiver to which this transaction was sent. */ readonly receiver: string; @@ -2149,14 +2230,20 @@ export interface definitions { readonly account: string; /** @description The identifier for the capability. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "capability"; /** @description Whether the capability has been requested. */ readonly requested: boolean; /** @description Time at which the capability was requested. Measured in seconds since the Unix epoch. */ readonly requested_at?: number; readonly requirements?: definitions["account_capability_requirements"]; - /** @description The status of the capability. Can be `active`, `inactive`, `pending`, or `unrequested`. */ + /** + * @description The status of the capability. Can be `active`, `inactive`, `pending`, or `unrequested`. + * @enum {string} + */ readonly status: "active" | "disabled" | "inactive" | "pending" | "unrequested"; }; /** @@ -2217,7 +2304,10 @@ export interface definitions { readonly metadata: { readonly [key: string]: unknown }; /** @description Cardholder name. */ readonly name?: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "card"; /** @description The recipient that this card belongs to. This attribute will not be in the card object if the card belongs to a customer or account instead. */ readonly recipient?: string; @@ -2275,7 +2365,10 @@ export interface definitions { readonly livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "charge"; /** @description The account (if any) the charge was made on behalf of without triggering an automatic transfer. See the [Connect documentation](https://stripe.com/docs/connect/charges-transfers) for details. */ readonly on_behalf_of?: string; @@ -2306,7 +2399,10 @@ export interface definitions { readonly data: readonly definitions["refund"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -2414,7 +2510,10 @@ export interface definitions { readonly id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description The IETF language tag of the locale Checkout is displayed in. If blank or `auto`, the browser's locale is used. */ + /** + * @description The IETF language tag of the locale Checkout is displayed in. If blank or `auto`, the browser's locale is used. + * @enum {string} + */ readonly locale?: | "auto" | "da" @@ -2435,9 +2534,15 @@ export interface definitions { | "zh"; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata?: { readonly [key: string]: unknown }; - /** @description The mode of the Checkout Session, one of `payment`, `setup`, or `subscription`. */ + /** + * @description The mode of the Checkout Session, one of `payment`, `setup`, or `subscription`. + * @enum {string} + */ readonly mode?: "payment" | "setup" | "subscription"; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "checkout.session"; /** @description The ID of the PaymentIntent for Checkout Sessions in `payment` mode. */ readonly payment_intent?: string; @@ -2455,6 +2560,7 @@ export interface definitions { * relevant text on the page, such as the submit button. `submit_type` can only be * specified on Checkout Sessions in `payment` mode, but not Checkout Sessions * in `subscription` or `setup` mode. + * @enum {string} */ readonly submit_type?: "auto" | "book" | "donate" | "pay"; /** @description The ID of the subscription for Checkout Sessions in `subscription` mode. */ @@ -2500,7 +2606,10 @@ export interface definitions { readonly id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "connect_collection_transfer"; }; /** @@ -2517,7 +2626,10 @@ export interface definitions { readonly default_currency: string; /** @description Unique identifier for the object. Represented as the ISO country code for this country. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "country_spec"; /** @description Currencies that can be accepted in the specific country (for transfers). */ readonly supported_bank_account_currencies: { readonly [key: string]: unknown }; @@ -2554,7 +2666,10 @@ export interface definitions { readonly created: number; /** @description If `amount_off` has been set, the three-letter [ISO code for the currency](https://stripe.com/docs/currencies) of the amount to take off. */ readonly currency?: string; - /** @description One of `forever`, `once`, and `repeating`. Describes how long a customer who applies this coupon will get the discount. */ + /** + * @description One of `forever`, `once`, and `repeating`. Describes how long a customer who applies this coupon will get the discount. + * @enum {string} + */ readonly duration: "forever" | "once" | "repeating"; /** @description If `duration` is `repeating`, the number of months the coupon applies. Null if coupon `duration` is `forever` or `once`. */ readonly duration_in_months?: number; @@ -2568,7 +2683,10 @@ export interface definitions { readonly metadata: { readonly [key: string]: unknown }; /** @description Name of the coupon displayed to customers on for instance invoices or receipts. */ readonly name?: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "coupon"; /** @description Percent that will be taken off the subtotal of any invoices for this customer for the duration of the coupon. For example, a coupon with percent_off of 50 will make a %s100 invoice %s50 instead. */ readonly percent_off?: number; @@ -2611,7 +2729,10 @@ export interface definitions { readonly data: readonly definitions["credit_note_line_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -2624,17 +2745,26 @@ export interface definitions { readonly metadata: { readonly [key: string]: unknown }; /** @description A unique number that identifies this particular credit note and appears on the PDF of the credit note and its associated invoice. */ readonly number: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "credit_note"; /** @description Amount that was credited outside of Stripe. */ readonly out_of_band_amount?: number; /** @description The link to download the PDF of the credit note. */ readonly pdf: string; - /** @description Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory` */ + /** + * @description Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory` + * @enum {string} + */ readonly reason?: "duplicate" | "fraudulent" | "order_change" | "product_unsatisfactory"; /** @description Refund related to this credit note. */ readonly refund?: string; - /** @description Status of this credit note, one of `issued` or `void`. Learn more about [voiding credit notes](https://stripe.com/docs/billing/invoices/credit-notes#voiding). */ + /** + * @description Status of this credit note, one of `issued` or `void`. Learn more about [voiding credit notes](https://stripe.com/docs/billing/invoices/credit-notes#voiding). + * @enum {string} + */ readonly status: "issued" | "void"; /** @description The integer amount in **%s** representing the amount of the credit note, excluding tax and discount. */ readonly subtotal: number; @@ -2642,7 +2772,10 @@ export interface definitions { readonly tax_amounts: readonly definitions["credit_note_tax_amount"][]; /** @description The integer amount in **%s** representing the total amount of the credit note, including tax and discount. */ readonly total: number; - /** @description Type of this credit note, one of `pre_payment` or `post_payment`. A `pre_payment` credit note means it was issued when the invoice was open. A `post_payment` credit note means it was issued when the invoice was paid. */ + /** + * @description Type of this credit note, one of `pre_payment` or `post_payment`. A `pre_payment` credit note means it was issued when the invoice was open. A `post_payment` credit note means it was issued when the invoice was paid. + * @enum {string} + */ readonly type: "post_payment" | "pre_payment"; /** @description The time that the credit note was voided. */ readonly voided_at?: number; @@ -2661,7 +2794,10 @@ export interface definitions { readonly invoice_line_item?: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "credit_note_line_item"; /** @description The number of units of product being credited. */ readonly quantity?: number; @@ -2669,7 +2805,10 @@ export interface definitions { readonly tax_amounts: readonly definitions["credit_note_tax_amount"][]; /** @description The tax rates which apply to the line item. */ readonly tax_rates: readonly definitions["tax_rate"][]; - /** @description The type of the credit note line item, one of `invoice_line_item` or `custom_line_item`. When the type is `invoice_line_item` there is an additional `invoice_line_item` property on the resource the value of which is the id of the credited line item on the invoice. */ + /** + * @description The type of the credit note line item, one of `invoice_line_item` or `custom_line_item`. When the type is `invoice_line_item` there is an additional `invoice_line_item` property on the resource the value of which is the id of the credited line item on the invoice. + * @enum {string} + */ readonly type: "custom_line_item" | "invoice_line_item"; /** @description The cost of each unit of product being credited. */ readonly unit_amount?: number; @@ -2728,7 +2867,10 @@ export interface definitions { readonly name?: string; /** @description The suffix of the customer's next invoice number, e.g., 0001. */ readonly next_invoice_sequence?: number; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "customer"; /** @description The customer's phone number. */ readonly phone?: string; @@ -2744,7 +2886,10 @@ export interface definitions { readonly data: readonly definitions["alipay_account"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -2758,12 +2903,18 @@ export interface definitions { readonly data: readonly definitions["subscription"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; }; - /** @description Describes the customer's tax exemption status. One of `none`, `exempt`, or `reverse`. When set to `reverse`, invoice and receipt PDFs include the text **"Reverse charge"**. */ + /** + * @description Describes the customer's tax exemption status. One of `none`, `exempt`, or `reverse`. When set to `reverse`, invoice and receipt PDFs include the text **"Reverse charge"**. + * @enum {string} + */ readonly tax_exempt?: "exempt" | "none" | "reverse"; /** * TaxIDsList @@ -2774,7 +2925,10 @@ export interface definitions { readonly data: readonly definitions["tax_id"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -2786,7 +2940,10 @@ export interface definitions { readonly accepted_at?: number; readonly offline?: definitions["offline_acceptance"]; readonly online?: definitions["online_acceptance"]; - /** @description The type of customer acceptance information included with the Mandate. One of `online` or `offline`. */ + /** + * @description The type of customer acceptance information included with the Mandate. One of `online` or `offline`. + * @enum {string} + */ readonly type: "offline" | "online"; }; /** @@ -2821,9 +2978,15 @@ export interface definitions { readonly livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata?: { readonly [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "customer_balance_transaction"; - /** @description Transaction type: `adjustment`, `applied_to_invoice`, `credit_note`, `initial`, `invoice_too_large`, `invoice_too_small`, `unspent_receiver_credit`, or `unapplied_from_invoice`. See the [Customer Balance page](https://stripe.com/docs/billing/customer/balance#types) to learn more about transaction types. */ + /** + * @description Transaction type: `adjustment`, `applied_to_invoice`, `credit_note`, `initial`, `invoice_too_large`, `invoice_too_small`, `unspent_receiver_credit`, or `unapplied_from_invoice`. See the [Customer Balance page](https://stripe.com/docs/billing/customer/balance#types) to learn more about transaction types. + * @enum {string} + */ readonly type: | "adjustment" | "applied_to_invoice" @@ -2837,231 +3000,381 @@ export interface definitions { }; /** DeletedAccount */ readonly deleted_account: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "account"; }; /** AlipayDeletedAccount */ readonly deleted_alipay_account: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "alipay_account"; }; /** DeletedApplePayDomain */ readonly deleted_apple_pay_domain: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "apple_pay_domain"; }; /** DeletedBankAccount */ readonly deleted_bank_account: { /** @description Three-letter [ISO code for the currency](https://stripe.com/docs/payouts) paid out to the bank account. */ readonly currency?: string; - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "bank_account"; }; /** BitcoinDeletedReceiver */ readonly deleted_bitcoin_receiver: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "bitcoin_receiver"; }; /** DeletedCard */ readonly deleted_card: { /** @description Three-letter [ISO code for the currency](https://stripe.com/docs/payouts) paid out to the bank account. */ readonly currency?: string; - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "card"; }; /** DeletedCoupon */ readonly deleted_coupon: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "coupon"; }; /** DeletedCustomer */ readonly deleted_customer: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "customer"; }; /** DeletedDiscount */ readonly deleted_discount: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "discount"; }; /** Polymorphic */ readonly deleted_external_account: { /** @description Three-letter [ISO code for the currency](https://stripe.com/docs/payouts) paid out to the bank account. */ readonly currency?: string; - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "bank_account"; }; /** DeletedInvoice */ readonly deleted_invoice: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "invoice"; }; /** DeletedInvoiceItem */ readonly deleted_invoiceitem: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "invoiceitem"; }; /** Polymorphic */ readonly deleted_payment_source: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "alipay_account"; }; /** DeletedPerson */ readonly deleted_person: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "person"; }; /** DeletedPlan */ readonly deleted_plan: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "plan"; }; /** DeletedProduct */ readonly deleted_product: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "product"; }; /** RadarListDeletedList */ readonly "deleted_radar.value_list": { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "radar.value_list"; }; /** RadarListDeletedListItem */ readonly "deleted_radar.value_list_item": { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "radar.value_list_item"; }; /** DeletedTransferRecipient */ readonly deleted_recipient: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "recipient"; }; /** DeletedSKU */ readonly deleted_sku: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "sku"; }; /** DeletedSubscriptionItem */ readonly deleted_subscription_item: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "subscription_item"; }; /** deleted_tax_id */ readonly deleted_tax_id: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "tax_id"; }; /** TerminalLocationDeletedLocation */ readonly "deleted_terminal.location": { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "terminal.location"; }; /** TerminalReaderDeletedReader */ readonly "deleted_terminal.reader": { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "terminal.reader"; }; /** NotificationWebhookEndpointDeleted */ readonly deleted_webhook_endpoint: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "webhook_endpoint"; }; /** DeliveryEstimate */ @@ -3089,7 +3402,10 @@ export interface definitions { readonly customer?: string; /** @description If the coupon has a duration of `repeating`, the date that this discount will end. If the coupon has a duration of `once` or `forever`, this attribute will be null. */ readonly end?: number; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "discount"; /** @description Date that the coupon was applied. */ readonly start: number; @@ -3127,13 +3443,19 @@ export interface definitions { readonly livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "dispute"; /** @description ID of the PaymentIntent that was disputed. */ readonly payment_intent?: string; /** @description Reason given by cardholder for dispute. Possible values are `bank_cannot_process`, `check_returned`, `credit_not_processed`, `customer_initiated`, `debit_not_authorized`, `duplicate`, `fraudulent`, `general`, `incorrect_account_details`, `insufficient_funds`, `product_not_received`, `product_unacceptable`, `subscription_canceled`, or `unrecognized`. Read more about [dispute reasons](https://stripe.com/docs/disputes/categories). */ readonly reason: string; - /** @description Current status of dispute. Possible values are `warning_needs_response`, `warning_under_review`, `warning_closed`, `needs_response`, `under_review`, `charge_refunded`, `won`, or `lost`. */ + /** + * @description Current status of dispute. Possible values are `warning_needs_response`, `warning_under_review`, `warning_closed`, `needs_response`, `under_review`, `charge_refunded`, `won`, or `lost`. + * @enum {string} + */ readonly status: | "charge_refunded" | "lost" @@ -3222,7 +3544,10 @@ export interface definitions { readonly id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "ephemeral_key"; /** @description The key's secret. You can use this value to make authorized requests to the Stripe API. */ readonly secret?: string; @@ -3275,7 +3600,10 @@ export interface definitions { readonly id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "event"; /** @description Number of webhooks that have yet to be successfully delivered (i.e., to return a 20x response) to the URLs you've specified. */ readonly pending_webhooks: number; @@ -3300,7 +3628,10 @@ export interface definitions { readonly exchange_rate: { /** @description Unique identifier for the object. Represented as the three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) in lowercase. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "exchange_rate"; /** @description Hash where the keys are supported currencies and the values are the exchange rate at which the base id currency converts to the key currency. */ readonly rates: { readonly [key: string]: unknown }; @@ -3325,7 +3656,10 @@ export interface definitions { readonly last4: string; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata?: { readonly [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "bank_account"; }; /** Fee */ @@ -3364,7 +3698,10 @@ export interface definitions { readonly id: string; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "fee_refund"; }; /** @@ -3393,12 +3730,18 @@ export interface definitions { readonly data: readonly definitions["file_link"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "file"; /** @description The purpose of the file. Possible values are `additional_verification`, `business_icon`, `business_logo`, `customer_signature`, `dispute_evidence`, `finance_report_run`, `identity_document`, `pci_document`, `sigma_scheduled_query`, or `tax_document_user_upload`. */ readonly purpose: string; @@ -3432,7 +3775,10 @@ export interface definitions { readonly livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "file_link"; /** @description The publicly accessible URL to download the file. */ readonly url?: string; @@ -3519,7 +3865,10 @@ export interface definitions { readonly attempted: boolean; /** @description Controls whether Stripe will perform [automatic collection](https://stripe.com/docs/billing/invoices/workflow/#auto_advance) of the invoice. When `false`, the invoice's state will not automatically advance without an explicit action. */ readonly auto_advance?: boolean; - /** @description Indicates the reason why the invoice was created. `subscription_cycle` indicates an invoice created by a subscription advancing into a new period. `subscription_create` indicates an invoice created due to creating a subscription. `subscription_update` indicates an invoice created due to updating a subscription. `subscription` is set for all old invoices to indicate either a change to a subscription or a period advancement. `manual` is set for all invoices unrelated to a subscription (for example: created via the invoice editor). The `upcoming` value is reserved for simulated invoices per the upcoming invoice endpoint. `subscription_threshold` indicates an invoice created due to a billing threshold being reached. */ + /** + * @description Indicates the reason why the invoice was created. `subscription_cycle` indicates an invoice created by a subscription advancing into a new period. `subscription_create` indicates an invoice created due to creating a subscription. `subscription_update` indicates an invoice created due to updating a subscription. `subscription` is set for all old invoices to indicate either a change to a subscription or a period advancement. `manual` is set for all invoices unrelated to a subscription (for example: created via the invoice editor). The `upcoming` value is reserved for simulated invoices per the upcoming invoice endpoint. `subscription_threshold` indicates an invoice created due to a billing threshold being reached. + * @enum {string} + */ readonly billing_reason?: | "automatic_pending_invoice_item_invoice" | "manual" @@ -3531,7 +3880,10 @@ export interface definitions { | "upcoming"; /** @description ID of the latest charge generated for this invoice, if any. */ readonly charge?: string; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this invoice using the default source attached to the customer. When sending an invoice, Stripe will email this invoice to the customer with payment instructions. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this invoice using the default source attached to the customer. When sending an invoice, Stripe will email this invoice to the customer with payment instructions. + * @enum {string} + */ readonly collection_method?: "charge_automatically" | "send_invoice"; /** @description Time at which the object was created. Measured in seconds since the Unix epoch. */ readonly created: number; @@ -3549,7 +3901,10 @@ export interface definitions { /** @description The customer's phone number. Until the invoice is finalized, this field will equal `customer.phone`. Once the invoice is finalized, this field will no longer be updated. */ readonly customer_phone?: string; readonly customer_shipping?: definitions["shipping"]; - /** @description The customer's tax exempt status. Until the invoice is finalized, this field will equal `customer.tax_exempt`. Once the invoice is finalized, this field will no longer be updated. */ + /** + * @description The customer's tax exempt status. Until the invoice is finalized, this field will equal `customer.tax_exempt`. Once the invoice is finalized, this field will no longer be updated. + * @enum {string} + */ readonly customer_tax_exempt?: "exempt" | "none" | "reverse"; /** @description The customer's tax IDs. Until the invoice is finalized, this field will contain the same tax IDs as `customer.tax_ids`. Once the invoice is finalized, this field will no longer be updated. */ readonly customer_tax_ids?: readonly definitions["invoices_resource_invoice_tax_id"][]; @@ -3583,7 +3938,10 @@ export interface definitions { readonly data: readonly definitions["line_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -3596,7 +3954,10 @@ export interface definitions { readonly next_payment_attempt?: number; /** @description A unique, identifying string that appears on emails sent to the customer for this invoice. This starts with the customer's unique invoice_prefix if it is specified. */ readonly number?: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "invoice"; /** @description Whether payment was successfully collected for this invoice. An invoice can be paid (most commonly) with a charge or with credit from the customer's account balance. */ readonly paid: boolean; @@ -3616,7 +3977,10 @@ export interface definitions { readonly starting_balance: number; /** @description Extra information about an invoice for the customer's credit card statement. */ readonly statement_descriptor?: string; - /** @description The status of the invoice, one of `draft`, `open`, `paid`, `uncollectible`, or `void`. [Learn more](https://stripe.com/docs/billing/invoices/workflow#workflow-overview) */ + /** + * @description The status of the invoice, one of `draft`, `open`, `paid`, `uncollectible`, or `void`. [Learn more](https://stripe.com/docs/billing/invoices/workflow#workflow-overview) + * @enum {string} + */ readonly status?: "deleted" | "draft" | "open" | "paid" | "uncollectible" | "void"; readonly status_transitions: definitions["invoices_status_transitions"]; /** @description The subscription that this invoice was prepared for, if any. */ @@ -3719,7 +4083,10 @@ export interface definitions { readonly livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "invoiceitem"; readonly period: definitions["invoice_line_item_period"]; readonly plan?: definitions["plan"]; @@ -3740,7 +4107,10 @@ export interface definitions { }; /** InvoicesResourceInvoiceTaxID */ readonly invoices_resource_invoice_tax_id: { - /** @description The type of the tax ID, one of `eu_vat`, `nz_gst`, `au_abn`, `in_gst`, `no_vat`, `za_vat`, `ch_vat`, `mx_rfc`, `sg_uen`, `ru_inn`, `ca_bn`, `hk_br`, `es_cif`, `tw_vat`, `th_vat`, `jp_cn`, `li_uid`, `my_itn`, `us_ein`, `kr_brn`, `ca_qst`, `my_sst`, `sg_gst`, or `unknown` */ + /** + * @description The type of the tax ID, one of `eu_vat`, `nz_gst`, `au_abn`, `in_gst`, `no_vat`, `za_vat`, `ch_vat`, `mx_rfc`, `sg_uen`, `ru_inn`, `ca_bn`, `hk_br`, `es_cif`, `tw_vat`, `th_vat`, `jp_cn`, `li_uid`, `my_itn`, `us_ein`, `kr_brn`, `ca_qst`, `my_sst`, `sg_gst`, or `unknown` + * @enum {string} + */ readonly type: | "au_abn" | "ca_bn" @@ -3801,7 +4171,10 @@ export interface definitions { readonly id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "issuer_fraud_record"; /** @description The timestamp at which the card issuer posted the issuer fraud record. */ readonly post_date: number; @@ -3819,7 +4192,10 @@ export interface definitions { readonly amount: number; /** @description Whether the authorization has been approved. */ readonly approved: boolean; - /** @description How the card details were provided. */ + /** + * @description How the card details were provided. + * @enum {string} + */ readonly authorization_method: "chip" | "contactless" | "keyed_in" | "online" | "swipe"; /** @description List of balance transactions associated with this authorization. */ readonly balance_transactions: readonly definitions["balance_transaction"][]; @@ -3841,12 +4217,18 @@ export interface definitions { readonly merchant_data: definitions["issuing_authorization_merchant_data"]; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "issuing.authorization"; readonly pending_request?: definitions["issuing_authorization_pending_request"]; /** @description History of every time the authorization was approved/denied (whether approved/denied by you directly or by Stripe based on your `spending_controls`). If the merchant changes the authorization by performing an [incremental authorization or partial capture](https://stripe.com/docs/issuing/purchases/authorizations), you can look at this field to see the previous states of the authorization. */ readonly request_history: readonly definitions["issuing_authorization_request"][]; - /** @description The current status of the authorization in its lifecycle. */ + /** + * @description The current status of the authorization in its lifecycle. + * @enum {string} + */ readonly status: "closed" | "pending" | "reversed"; /** @description List of [transactions](https://stripe.com/docs/api/issuing/transactions) associated with this authorization. */ readonly transactions: readonly definitions["issuing.transaction"][]; @@ -3861,7 +4243,10 @@ export interface definitions { readonly "issuing.card": { /** @description The brand of the card. */ readonly brand: string; - /** @description The reason why the card was canceled. */ + /** + * @description The reason why the card was canceled. + * @enum {string} + */ readonly cancellation_reason?: "lost" | "stolen"; readonly cardholder: definitions["issuing.cardholder"]; /** @description Time at which the object was created. Measured in seconds since the Unix epoch. */ @@ -3884,19 +4269,31 @@ export interface definitions { readonly metadata: { readonly [key: string]: unknown }; /** @description The full unredacted card number. For security reasons, this is only available for virtual cards, and will be omitted unless you explicitly request it with [the `expand` parameter](https://stripe.com/docs/api/expanding_objects). Additionally, it's only available via the ["Retrieve a card" endpoint](https://stripe.com/docs/api/issuing/cards/retrieve), not via "List all cards" or any other endpoint. */ readonly number?: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "issuing.card"; /** @description The latest card that replaces this card, if any. */ readonly replaced_by?: string; /** @description The card this card replaces, if any. */ readonly replacement_for?: string; - /** @description The reason why the previous card needed to be replaced. */ + /** + * @description The reason why the previous card needed to be replaced. + * @enum {string} + */ readonly replacement_reason?: "damaged" | "expired" | "lost" | "stolen"; readonly shipping?: definitions["issuing_card_shipping"]; readonly spending_controls: definitions["issuing_card_authorization_controls"]; - /** @description Whether authorizations can be approved on this card. */ + /** + * @description Whether authorizations can be approved on this card. + * @enum {string} + */ readonly status: "active" | "canceled" | "inactive"; - /** @description The type of the card. */ + /** + * @description The type of the card. + * @enum {string} + */ readonly type: "physical" | "virtual"; }; /** @@ -3921,15 +4318,24 @@ export interface definitions { readonly metadata: { readonly [key: string]: unknown }; /** @description The cardholder's name. This will be printed on cards issued to them. */ readonly name: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "issuing.cardholder"; /** @description The cardholder's phone number. */ readonly phone_number?: string; readonly requirements: definitions["issuing_cardholder_requirements"]; readonly spending_controls?: definitions["issuing_cardholder_authorization_controls"]; - /** @description Specifies whether to permit authorizations on this cardholder's cards. */ + /** + * @description Specifies whether to permit authorizations on this cardholder's cards. + * @enum {string} + */ readonly status: "active" | "blocked" | "inactive"; - /** @description One of `individual` or `company`. */ + /** + * @description One of `individual` or `company`. + * @enum {string} + */ readonly type: "company" | "individual"; }; /** @@ -3943,7 +4349,10 @@ export interface definitions { readonly id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "issuing.dispute"; }; /** @@ -3969,13 +4378,19 @@ export interface definitions { readonly metadata: { readonly [key: string]: unknown }; /** @description The total net amount required to settle with the network. */ readonly net_total: number; - /** @description The card network for this settlement report. One of ["visa"] */ + /** + * @description The card network for this settlement report. One of ["visa"] + * @enum {string} + */ readonly network: "visa"; /** @description The total amount of fees owed to the network. */ readonly network_fees: number; /** @description The Settlement Identification Number assigned by the network. */ readonly network_settlement_identifier: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "issuing.settlement"; /** @description One of `international` or `uk_national_net`. */ readonly settlement_service: string; @@ -4018,9 +4433,15 @@ export interface definitions { readonly merchant_data: definitions["issuing_authorization_merchant_data"]; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "issuing.transaction"; - /** @description The nature of the transaction. */ + /** + * @description The nature of the transaction. + * @enum {string} + */ readonly type: "capture" | "refund"; }; /** IssuingAuthorizationMerchantData */ @@ -4067,7 +4488,10 @@ export interface definitions { readonly merchant_amount: number; /** @description The currency that was collected by the merchant and presented to the cardholder for the authorization. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). */ readonly merchant_currency: string; - /** @description The reason for the approval or decline. */ + /** + * @description The reason for the approval or decline. + * @enum {string} + */ readonly reason: | "account_disabled" | "card_active" @@ -4085,13 +4509,25 @@ export interface definitions { }; /** IssuingAuthorizationVerificationData */ readonly issuing_authorization_verification_data: { - /** @description Whether the cardholder provided an address first line and if it matched the cardholder’s `billing.address.line1`. */ + /** + * @description Whether the cardholder provided an address first line and if it matched the cardholder’s `billing.address.line1`. + * @enum {string} + */ readonly address_line1_check: "match" | "mismatch" | "not_provided"; - /** @description Whether the cardholder provided a postal code and if it matched the cardholder’s `billing.address.postal_code`. */ + /** + * @description Whether the cardholder provided a postal code and if it matched the cardholder’s `billing.address.postal_code`. + * @enum {string} + */ readonly address_postal_code_check: "match" | "mismatch" | "not_provided"; - /** @description Whether the cardholder provided a CVC and if it matched Stripe’s record. */ + /** + * @description Whether the cardholder provided a CVC and if it matched Stripe’s record. + * @enum {string} + */ readonly cvc_check: "match" | "mismatch" | "not_provided"; - /** @description Whether the cardholder provided an expiry date and if it matched Stripe’s record. */ + /** + * @description Whether the cardholder provided an expiry date and if it matched Stripe’s record. + * @enum {string} + */ readonly expiry_check: "match" | "mismatch" | "not_provided"; }; /** IssuingCardAuthorizationControls */ @@ -4686,21 +5122,33 @@ export interface definitions { /** IssuingCardShipping */ readonly issuing_card_shipping: { readonly address: definitions["address"]; - /** @description The delivery company that shipped a card. */ + /** + * @description The delivery company that shipped a card. + * @enum {string} + */ readonly carrier?: "fedex" | "usps"; /** @description A unix timestamp representing a best estimate of when the card will be delivered. */ readonly eta?: number; /** @description Recipient name. */ readonly name: string; - /** @description Shipment service, such as `standard` or `express`. */ + /** + * @description Shipment service, such as `standard` or `express`. + * @enum {string} + */ readonly service: "express" | "priority" | "standard"; - /** @description The delivery status of the card. */ + /** + * @description The delivery status of the card. + * @enum {string} + */ readonly status?: "canceled" | "delivered" | "failure" | "pending" | "returned" | "shipped"; /** @description A tracking number for a card shipment. */ readonly tracking_number?: string; /** @description A link to the shipping carrier's site where you can view detailed information about a card shipment. */ readonly tracking_url?: string; - /** @description Packaging options. */ + /** + * @description Packaging options. + * @enum {string} + */ readonly type: "bulk" | "individual"; }; /** IssuingCardSpendingLimit */ @@ -4998,7 +5446,10 @@ export interface definitions { | "womens_ready_to_wear_stores" | "wrecking_and_salvage_yards" )[]; - /** @description The time interval or event with which to apply this spending limit towards. */ + /** + * @description The time interval or event with which to apply this spending limit towards. + * @enum {string} + */ readonly interval: "all_time" | "daily" | "monthly" | "per_authorization" | "weekly" | "yearly"; }; /** IssuingCardholderAddress */ @@ -5626,7 +6077,10 @@ export interface definitions { }; /** IssuingCardholderRequirements */ readonly issuing_cardholder_requirements: { - /** @description If `disabled_reason` is present, all cards will decline authorizations with `cardholder_verification_required` reason. */ + /** + * @description If `disabled_reason` is present, all cards will decline authorizations with `cardholder_verification_required` reason. + * @enum {string} + */ readonly disabled_reason?: "listed" | "rejected.listed" | "under_review"; /** @description Array of fields that need to be collected in order to verify and re-enable the cardholder. */ readonly past_due?: readonly ( @@ -5934,7 +6388,10 @@ export interface definitions { | "womens_ready_to_wear_stores" | "wrecking_and_salvage_yards" )[]; - /** @description The time interval or event with which to apply this spending limit towards. */ + /** + * @description The time interval or event with which to apply this spending limit towards. + * @enum {string} + */ readonly interval: "all_time" | "daily" | "monthly" | "per_authorization" | "weekly" | "yearly"; }; /** IssuingCardholderVerification */ @@ -5960,7 +6417,10 @@ export interface definitions { readonly owners_provided?: boolean; /** @description The company's phone number (used for verification). */ readonly phone?: string; - /** @description The category identifying the legal structure of the company or legal entity. See [Business structure](https://stripe.com/docs/connect/identity-verification#business-structure) for more details. */ + /** + * @description The category identifying the legal structure of the company or legal entity. See [Business structure](https://stripe.com/docs/connect/identity-verification#business-structure) for more details. + * @enum {string} + */ readonly structure?: | "government_instrumentality" | "governmental_unit" @@ -6068,7 +6528,10 @@ export interface definitions { readonly livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Note that for line items with `type=subscription` this will reflect the metadata of the subscription that caused the line item to be created. */ readonly metadata: { readonly [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "line_item"; readonly period: definitions["invoice_line_item_period"]; readonly plan?: definitions["plan"]; @@ -6084,14 +6547,20 @@ export interface definitions { readonly tax_amounts?: readonly definitions["invoice_tax_amount"][]; /** @description The tax rates which apply to the line item. */ readonly tax_rates?: readonly definitions["tax_rate"][]; - /** @description A string identifying the type of the source of this line item, either an `invoiceitem` or a `subscription`. */ + /** + * @description A string identifying the type of the source of this line item, either an `invoiceitem` or a `subscription`. + * @enum {string} + */ readonly type: "invoiceitem" | "subscription"; }; /** LoginLink */ readonly login_link: { /** @description Time at which the object was created. Measured in seconds since the Unix epoch. */ readonly created: number; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "login_link"; /** @description The URL for the login link. */ readonly url: string; @@ -6107,15 +6576,24 @@ export interface definitions { /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; readonly multi_use?: definitions["mandate_multi_use"]; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "mandate"; /** @description ID of the payment method associated with this mandate. */ readonly payment_method: string; readonly payment_method_details: definitions["mandate_payment_method_details"]; readonly single_use?: definitions["mandate_single_use"]; - /** @description The status of the mandate, which indicates whether it can be used to initiate a payment. */ + /** + * @description The status of the mandate, which indicates whether it can be used to initiate a payment. + * @enum {string} + */ readonly status: "active" | "inactive" | "pending"; - /** @description The type of the mandate. */ + /** + * @description The type of the mandate. + * @enum {string} + */ readonly type: "multi_use" | "single_use"; }; /** mandate_au_becs_debit */ @@ -6207,7 +6685,10 @@ export interface definitions { readonly livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "order"; /** * OrderReturnList @@ -6218,7 +6699,10 @@ export interface definitions { readonly data: readonly definitions["order_return"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -6250,7 +6734,10 @@ export interface definitions { readonly currency: string; /** @description Description of the line item, meant to be displayable to the user (e.g., `"Express shipping"`). */ readonly description: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "order_item"; /** @description The ID of the associated object for this line item. Expandable if not null (e.g., expandable to a SKU). */ readonly parent?: string; @@ -6279,7 +6766,10 @@ export interface definitions { readonly items: readonly definitions["order_item"][]; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "order_return"; /** @description The order that this return includes items from. */ readonly order?: string; @@ -6324,7 +6814,10 @@ export interface definitions { readonly application_fee_amount?: number; /** @description Populated when `status` is `canceled`, this is the time at which the PaymentIntent was canceled. Measured in seconds since the Unix epoch. */ readonly canceled_at?: number; - /** @description Reason for cancellation of this PaymentIntent, either user-provided (`duplicate`, `fraudulent`, `requested_by_customer`, or `abandoned`) or generated by Stripe internally (`failed_invoice`, `void_invoice`, or `automatic`). */ + /** + * @description Reason for cancellation of this PaymentIntent, either user-provided (`duplicate`, `fraudulent`, `requested_by_customer`, or `abandoned`) or generated by Stripe internally (`failed_invoice`, `void_invoice`, or `automatic`). + * @enum {string} + */ readonly cancellation_reason?: | "abandoned" | "automatic" @@ -6333,7 +6826,10 @@ export interface definitions { | "fraudulent" | "requested_by_customer" | "void_invoice"; - /** @description Controls when the funds will be captured from the customer's account. */ + /** + * @description Controls when the funds will be captured from the customer's account. + * @enum {string} + */ readonly capture_method: "automatic" | "manual"; /** * PaymentFlowsPaymentIntentResourceChargeList @@ -6344,7 +6840,10 @@ export interface definitions { readonly data: readonly definitions["charge"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -6357,6 +6856,7 @@ export interface definitions { * Refer to our docs to [accept a payment](https://stripe.com/docs/payments/accept-a-payment) and learn about how `client_secret` should be handled. */ readonly client_secret?: string; + /** @enum {string} */ readonly confirmation_method: "automatic" | "manual"; /** @description Time at which the object was created. Measured in seconds since the Unix epoch. */ readonly created: number; @@ -6382,7 +6882,10 @@ export interface definitions { /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. For more information, see the [documentation](https://stripe.com/docs/payments/payment-intents/creating-payment-intents#storing-information-in-metadata). */ readonly metadata?: { readonly [key: string]: unknown }; readonly next_action?: definitions["payment_intent_next_action"]; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "payment_intent"; /** @description The account (if any) for which the funds of the PaymentIntent are intended. See the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts) for details. */ readonly on_behalf_of?: string; @@ -6401,6 +6904,7 @@ export interface definitions { * Providing this parameter will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any required actions from the user are complete. If no Customer was provided, the payment method can still be [attached](https://stripe.com/docs/api/payment_methods/attach) to a Customer after the transaction completes. * * When processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication). + * @enum {string} */ readonly setup_future_usage?: "off_session" | "on_session"; readonly shipping?: definitions["shipping"]; @@ -6408,7 +6912,10 @@ export interface definitions { readonly statement_descriptor?: string; /** @description Provides information about a card payment that customers see on their statements. Concatenated with the prefix (shortened descriptor) or statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 22 characters for the concatenated descriptor. */ readonly statement_descriptor_suffix?: string; - /** @description Status of this PaymentIntent, one of `requires_payment_method`, `requires_confirmation`, `requires_action`, `processing`, `requires_capture`, `canceled`, or `succeeded`. Read more about each PaymentIntent [status](https://stripe.com/docs/payments/intents#intent-statuses). */ + /** + * @description Status of this PaymentIntent, one of `requires_payment_method`, `requires_confirmation`, `requires_action`, `processing`, `requires_capture`, `canceled`, or `succeeded`. Read more about each PaymentIntent [status](https://stripe.com/docs/payments/intents#intent-statuses). + * @enum {string} + */ readonly status: | "canceled" | "processing" @@ -6443,7 +6950,10 @@ export interface definitions { /** payment_intent_payment_method_options_card */ readonly payment_intent_payment_method_options_card: { readonly installments?: definitions["payment_method_options_card_installments"]; - /** @description We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Permitted values include: `automatic` or `any`. If not provided, defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine. */ + /** + * @description We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Permitted values include: `automatic` or `any`. If not provided, defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine. + * @enum {string} + */ readonly request_three_d_secure?: "any" | "automatic" | "challenge_only"; }; /** @@ -6471,10 +6981,16 @@ export interface definitions { readonly livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "payment_method"; readonly sepa_debit?: definitions["payment_method_sepa_debit"]; - /** @description The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type. */ + /** + * @description The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type. + * @enum {string} + */ readonly type: "au_becs_debit" | "card" | "fpx" | "ideal" | "sepa_debit"; }; /** payment_method_au_becs_debit */ @@ -6533,7 +7049,10 @@ export interface definitions { readonly google_pay?: definitions["payment_method_card_wallet_google_pay"]; readonly masterpass?: definitions["payment_method_card_wallet_masterpass"]; readonly samsung_pay?: definitions["payment_method_card_wallet_samsung_pay"]; - /** @description The type of the card wallet, one of `amex_express_checkout`, `apple_pay`, `google_pay`, `masterpass`, `samsung_pay`, or `visa_checkout`. An additional hash is included on the Wallet subhash with a name matching this value. It contains additional information specific to the card wallet type. */ + /** + * @description The type of the card wallet, one of `amex_express_checkout`, `apple_pay`, `google_pay`, `masterpass`, `samsung_pay`, or `visa_checkout`. An additional hash is included on the Wallet subhash with a name matching this value. It contains additional information specific to the card wallet type. + * @enum {string} + */ readonly type: | "amex_express_checkout" | "apple_pay" @@ -6609,7 +7128,10 @@ export interface definitions { }; /** payment_method_details_ach_debit */ readonly payment_method_details_ach_debit: { - /** @description Type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description Type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string} + */ readonly account_holder_type?: "company" | "individual"; /** @description Name of the bank associated with the bank account. */ readonly bank_name?: string; @@ -6648,6 +7170,7 @@ export interface definitions { /** * @description Preferred language of the Bancontact authorization page that the customer is redirected to. * Can be one of `en`, `de`, `fr`, or `nl` + * @enum {string} */ readonly preferred_language?: "de" | "en" | "fr" | "nl"; /** @@ -6699,9 +7222,13 @@ export interface definitions { /** * @description For `fixed_count` installment plans, this is the interval between installment payments your customer will make to their credit card. * One of `month`. + * @enum {string} */ readonly interval?: "month"; - /** @description Type of installment plan, one of `fixed_count`. */ + /** + * @description Type of installment plan, one of `fixed_count`. + * @enum {string} + */ readonly type: "fixed_count"; }; /** payment_method_details_card_present */ @@ -6760,7 +7287,10 @@ export interface definitions { readonly google_pay?: definitions["payment_method_details_card_wallet_google_pay"]; readonly masterpass?: definitions["payment_method_details_card_wallet_masterpass"]; readonly samsung_pay?: definitions["payment_method_details_card_wallet_samsung_pay"]; - /** @description The type of the card wallet, one of `amex_express_checkout`, `apple_pay`, `google_pay`, `masterpass`, `samsung_pay`, or `visa_checkout`. An additional hash is included on the Wallet subhash with a name matching this value. It contains additional information specific to the card wallet type. */ + /** + * @description The type of the card wallet, one of `amex_express_checkout`, `apple_pay`, `google_pay`, `masterpass`, `samsung_pay`, or `visa_checkout`. An additional hash is included on the Wallet subhash with a name matching this value. It contains additional information specific to the card wallet type. + * @enum {string} + */ readonly type: | "amex_express_checkout" | "apple_pay" @@ -6806,7 +7336,10 @@ export interface definitions { }; /** payment_method_details_fpx */ readonly payment_method_details_fpx: { - /** @description The customer's bank. Can be one of `affin_bank`, `alliance_bank`, `ambank`, `bank_islam`, `bank_muamalat`, `bank_rakyat`, `bsn`, `cimb`, `hong_leong_bank`, `hsbc`, `kfh`, `maybank2u`, `ocbc`, `public_bank`, `rhb`, `standard_chartered`, `uob`, `deutsche_bank`, `maybank2e`, or `pb_enterprise`. */ + /** + * @description The customer's bank. Can be one of `affin_bank`, `alliance_bank`, `ambank`, `bank_islam`, `bank_muamalat`, `bank_rakyat`, `bsn`, `cimb`, `hong_leong_bank`, `hsbc`, `kfh`, `maybank2u`, `ocbc`, `public_bank`, `rhb`, `standard_chartered`, `uob`, `deutsche_bank`, `maybank2e`, or `pb_enterprise`. + * @enum {string} + */ readonly bank: | "affin_bank" | "alliance_bank" @@ -6847,7 +7380,10 @@ export interface definitions { }; /** payment_method_details_ideal */ readonly payment_method_details_ideal: { - /** @description The customer's bank. Can be one of `abn_amro`, `asn_bank`, `bunq`, `handelsbanken`, `ing`, `knab`, `moneyou`, `rabobank`, `regiobank`, `sns_bank`, `triodos_bank`, or `van_lanschot`. */ + /** + * @description The customer's bank. Can be one of `abn_amro`, `asn_bank`, `bunq`, `handelsbanken`, `ing`, `knab`, `moneyou`, `rabobank`, `regiobank`, `sns_bank`, `triodos_bank`, or `van_lanschot`. + * @enum {string} + */ readonly bank?: | "abn_amro" | "asn_bank" @@ -6861,7 +7397,10 @@ export interface definitions { | "sns_bank" | "triodos_bank" | "van_lanschot"; - /** @description The Bank Identifier Code of the customer's bank. */ + /** + * @description The Bank Identifier Code of the customer's bank. + * @enum {string} + */ readonly bic?: | "ABNANL2A" | "ASNBNL21" @@ -6941,7 +7480,10 @@ export interface definitions { readonly payment_method_details_wechat: { readonly [key: string]: unknown }; /** payment_method_fpx */ readonly payment_method_fpx: { - /** @description The customer's bank, if provided. Can be one of `affin_bank`, `alliance_bank`, `ambank`, `bank_islam`, `bank_muamalat`, `bank_rakyat`, `bsn`, `cimb`, `hong_leong_bank`, `hsbc`, `kfh`, `maybank2u`, `ocbc`, `public_bank`, `rhb`, `standard_chartered`, `uob`, `deutsche_bank`, `maybank2e`, or `pb_enterprise`. */ + /** + * @description The customer's bank, if provided. Can be one of `affin_bank`, `alliance_bank`, `ambank`, `bank_islam`, `bank_muamalat`, `bank_rakyat`, `bsn`, `cimb`, `hong_leong_bank`, `hsbc`, `kfh`, `maybank2u`, `ocbc`, `public_bank`, `rhb`, `standard_chartered`, `uob`, `deutsche_bank`, `maybank2e`, or `pb_enterprise`. + * @enum {string} + */ readonly bank: | "affin_bank" | "alliance_bank" @@ -6966,7 +7508,10 @@ export interface definitions { }; /** payment_method_ideal */ readonly payment_method_ideal: { - /** @description The customer's bank, if provided. Can be one of `abn_amro`, `asn_bank`, `bunq`, `handelsbanken`, `ing`, `knab`, `moneyou`, `rabobank`, `regiobank`, `sns_bank`, `triodos_bank`, or `van_lanschot`. */ + /** + * @description The customer's bank, if provided. Can be one of `abn_amro`, `asn_bank`, `bunq`, `handelsbanken`, `ing`, `knab`, `moneyou`, `rabobank`, `regiobank`, `sns_bank`, `triodos_bank`, or `van_lanschot`. + * @enum {string} + */ readonly bank?: | "abn_amro" | "asn_bank" @@ -6980,7 +7525,10 @@ export interface definitions { | "sns_bank" | "triodos_bank" | "van_lanschot"; - /** @description The Bank Identifier Code of the customer's bank, if the bank was provided. */ + /** + * @description The Bank Identifier Code of the customer's bank, if the bank was provided. + * @enum {string} + */ readonly bic?: | "ABNANL2A" | "ASNBNL21" @@ -7268,7 +7816,10 @@ export interface definitions { readonly id: string; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata?: { readonly [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "account"; }; /** @@ -7313,7 +7864,10 @@ export interface definitions { readonly metadata: { readonly [key: string]: unknown }; /** @description The method used to send this payout, which can be `standard` or `instant`. `instant` is only supported for payouts to debit cards. (See [Instant payouts for marketplaces](https://stripe.com/blog/instant-payouts-for-marketplaces) for more information.) */ readonly method: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "payout"; /** @description The source balance this payout came from. One of `card`, `fpx`, or `bank_account`. */ readonly source_type: string; @@ -7321,7 +7875,10 @@ export interface definitions { readonly statement_descriptor?: string; /** @description Current status of the payout: `paid`, `pending`, `in_transit`, `canceled` or `failed`. A payout is `pending` until it is submitted to the bank, when it becomes `in_transit`. The status then changes to `paid` if the transaction goes through, or to `failed` or `canceled` (within 5 business days). Some failed payouts may initially show as `paid` but then change to `failed`. */ readonly status: string; - /** @description Can be `bank_account` or `card`. */ + /** + * @description Can be `bank_account` or `card`. + * @enum {string} + */ readonly type: "bank_account" | "card"; }; /** Period */ @@ -7359,7 +7916,10 @@ export interface definitions { readonly maiden_name?: string; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata?: { readonly [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "person"; readonly phone?: string; readonly relationship?: definitions["person_relationship"]; @@ -7407,13 +7967,19 @@ export interface definitions { readonly plan: { /** @description Whether the plan can be used for new purchases. */ readonly active: boolean; - /** @description Specifies a usage aggregation strategy for plans of `usage_type=metered`. Allowed values are `sum` for summing up all usage during a period, `last_during_period` for using the last usage record reported within a period, `last_ever` for using the last usage record ever (across period bounds) or `max` which uses the usage record with the maximum reported usage during a period. Defaults to `sum`. */ + /** + * @description Specifies a usage aggregation strategy for plans of `usage_type=metered`. Allowed values are `sum` for summing up all usage during a period, `last_during_period` for using the last usage record reported within a period, `last_ever` for using the last usage record ever (across period bounds) or `max` which uses the usage record with the maximum reported usage during a period. Defaults to `sum`. + * @enum {string} + */ readonly aggregate_usage?: "last_during_period" | "last_ever" | "max" | "sum"; /** @description The amount in %s to be charged on the interval specified. */ readonly amount?: number; /** @description Same as `amount`, but contains a decimal value with at most 12 decimal places. */ readonly amount_decimal?: string; - /** @description Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `amount`) will be charged per unit in `quantity` (for plans with `usage_type=licensed`), or per unit of total usage (for plans with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes. */ + /** + * @description Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `amount`) will be charged per unit in `quantity` (for plans with `usage_type=licensed`), or per unit of total usage (for plans with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes. + * @enum {string} + */ readonly billing_scheme: "per_unit" | "tiered"; /** @description Time at which the object was created. Measured in seconds since the Unix epoch. */ readonly created: number; @@ -7421,7 +7987,10 @@ export interface definitions { readonly currency: string; /** @description Unique identifier for the object. */ readonly id: string; - /** @description The frequency at which a subscription is billed. One of `day`, `week`, `month` or `year`. */ + /** + * @description The frequency at which a subscription is billed. One of `day`, `week`, `month` or `year`. + * @enum {string} + */ readonly interval: "day" | "month" | "week" | "year"; /** @description The number of intervals (specified in the `interval` attribute) between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. */ readonly interval_count: number; @@ -7431,18 +8000,27 @@ export interface definitions { readonly metadata: { readonly [key: string]: unknown }; /** @description A brief description of the plan, hidden from customers. */ readonly nickname?: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "plan"; /** @description The product whose pricing this plan determines. */ readonly product?: string; /** @description Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`. */ readonly tiers?: readonly definitions["plan_tier"][]; - /** @description Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price. In `graduated` tiering, pricing can change as the quantity grows. */ + /** + * @description Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price. In `graduated` tiering, pricing can change as the quantity grows. + * @enum {string} + */ readonly tiers_mode?: "graduated" | "volume"; readonly transform_usage?: definitions["transform_usage"]; /** @description Default number of trial days when subscribing a customer to this plan using [`trial_from_plan=true`](https://stripe.com/docs/api#create_subscription-trial_from_plan). */ readonly trial_period_days?: number; - /** @description Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`. */ + /** + * @description Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`. + * @enum {string} + */ readonly usage_type: "licensed" | "metered"; }; /** PlanTier */ @@ -7464,7 +8042,10 @@ export interface definitions { readonly account: string; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "platform_tax_fee"; /** @description The payment object that caused this tax to be inflicted. */ readonly source_transaction: string; @@ -7505,14 +8086,20 @@ export interface definitions { readonly metadata: { readonly [key: string]: unknown }; /** @description The product's name, meant to be displayable to the customer. Whenever this product is sold via a subscription, name will show up on associated invoice line item descriptions. */ readonly name: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "product"; readonly package_dimensions?: definitions["package_dimensions"]; /** @description Whether this product is a shipped good. Only applicable to products of `type=good`. */ readonly shippable?: boolean; /** @description Extra information about a product which will appear on your customer's credit card statement. In the case that multiple products are billed at once, the first statement descriptor will be used. */ readonly statement_descriptor?: string; - /** @description The type of the product. The product is either of type `good`, which is eligible for use with Orders and SKUs, or `service`, which is eligible for use with Subscriptions and Plans. */ + /** + * @description The type of the product. The product is either of type `good`, which is eligible for use with Orders and SKUs, or `service`, which is eligible for use with Subscriptions and Plans. + * @enum {string} + */ readonly type: "good" | "service"; /** @description A label that represents units of this product in Stripe and on customers’ receipts and invoices. When set, this will be included in associated invoice line item descriptions. */ readonly unit_label?: string; @@ -7541,7 +8128,10 @@ export interface definitions { readonly id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "radar.early_fraud_warning"; }; /** @@ -7559,7 +8149,10 @@ export interface definitions { readonly created_by: string; /** @description Unique identifier for the object. */ readonly id: string; - /** @description The type of items in the value list. One of `card_fingerprint`, `card_bin`, `email`, `ip_address`, `country`, `string`, or `case_sensitive_string`. */ + /** + * @description The type of items in the value list. One of `card_fingerprint`, `card_bin`, `email`, `ip_address`, `country`, `string`, or `case_sensitive_string`. + * @enum {string} + */ readonly item_type: | "card_bin" | "card_fingerprint" @@ -7577,7 +8170,10 @@ export interface definitions { readonly data: readonly definitions["radar.value_list_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -7588,7 +8184,10 @@ export interface definitions { readonly metadata: { readonly [key: string]: unknown }; /** @description The name of the value list. */ readonly name: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "radar.value_list"; }; /** @@ -7606,7 +8205,10 @@ export interface definitions { readonly id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "radar.value_list_item"; /** @description The value of the item. */ readonly value: string; @@ -7658,7 +8260,10 @@ export interface definitions { readonly data: readonly definitions["card"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -7680,7 +8285,10 @@ export interface definitions { readonly migrated_to?: string; /** @description Full, legal name of the recipient. */ readonly name?: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "recipient"; readonly rolled_back_from?: string; /** @description Type of the recipient, one of `individual` or `corporation`. */ @@ -7715,7 +8323,10 @@ export interface definitions { readonly id: string; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "refund"; /** @description ID of the PaymentIntent that was refunded. */ readonly payment_intent?: string; @@ -7754,7 +8365,10 @@ export interface definitions { readonly id: string; /** @description Always `true`: reports can only be run on live-mode data. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "reporting.report_run"; readonly parameters: definitions["financial_reporting_finance_report_run_run_parameters"]; /** @description The ID of the [report type](https://stripe.com/docs/reporting/statements/api#report-types) to run, such as `"balance.summary.1"`. */ @@ -7795,7 +8409,10 @@ export interface definitions { readonly id: string; /** @description Human-readable name of the Report Type */ readonly name: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "reporting.report_type"; /** @description When this Report Type was latest updated. Measured in seconds since the Unix epoch. */ readonly updated: number; @@ -7811,7 +8428,10 @@ export interface definitions { readonly description?: string; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "reserve_transaction"; }; /** @@ -7826,7 +8446,10 @@ export interface definitions { readonly billing_zip?: string; /** @description The charge associated with this review. */ readonly charge?: string; - /** @description The reason the review was closed, or null if it has not yet been closed. One of `approved`, `refunded`, `refunded_as_fraud`, or `disputed`. */ + /** + * @description The reason the review was closed, or null if it has not yet been closed. One of `approved`, `refunded`, `refunded_as_fraud`, or `disputed`. + * @enum {string} + */ readonly closed_reason?: "approved" | "disputed" | "refunded" | "refunded_as_fraud"; /** @description Time at which the object was created. Measured in seconds since the Unix epoch. */ readonly created: number; @@ -7837,11 +8460,17 @@ export interface definitions { readonly ip_address_location?: definitions["radar_review_resource_location"]; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "review"; /** @description If `true`, the review needs action. */ readonly open: boolean; - /** @description The reason the review was opened. One of `rule` or `manual`. */ + /** + * @description The reason the review was opened. One of `rule` or `manual`. + * @enum {string} + */ readonly opened_reason: "manual" | "rule"; /** @description The PaymentIntent ID associated with this review, if one exists. */ readonly payment_intent?: string; @@ -7876,7 +8505,10 @@ export interface definitions { readonly id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "scheduled_query_run"; /** @description Time at which the result expires and is no longer available for download. */ readonly result_available_until: number; @@ -7915,7 +8547,10 @@ export interface definitions { readonly setup_intent: { /** @description ID of the Connect application that created the SetupIntent. */ readonly application?: string; - /** @description Reason for cancellation of this SetupIntent, one of `abandoned`, `requested_by_customer`, or `duplicate`. */ + /** + * @description Reason for cancellation of this SetupIntent, one of `abandoned`, `requested_by_customer`, or `duplicate`. + * @enum {string} + */ readonly cancellation_reason?: "abandoned" | "duplicate" | "requested_by_customer"; /** * @description The client secret of this SetupIntent. Used for client-side retrieval using a publishable key. @@ -7943,7 +8578,10 @@ export interface definitions { /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata?: { readonly [key: string]: unknown }; readonly next_action?: definitions["setup_intent_next_action"]; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "setup_intent"; /** @description The account (if any) for which the setup is intended. */ readonly on_behalf_of?: string; @@ -7954,7 +8592,10 @@ export interface definitions { readonly payment_method_types: readonly string[]; /** @description ID of the single_use Mandate generated by the SetupIntent. */ readonly single_use_mandate?: string; - /** @description [Status](https://stripe.com/docs/payments/intents#intent-statuses) of this SetupIntent, one of `requires_payment_method`, `requires_confirmation`, `requires_action`, `processing`, `canceled`, or `succeeded`. */ + /** + * @description [Status](https://stripe.com/docs/payments/intents#intent-statuses) of this SetupIntent, one of `requires_payment_method`, `requires_confirmation`, `requires_action`, `processing`, `canceled`, or `succeeded`. + * @enum {string} + */ readonly status: | "canceled" | "processing" @@ -7990,7 +8631,10 @@ export interface definitions { }; /** setup_intent_payment_method_options_card */ readonly setup_intent_payment_method_options_card: { - /** @description We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Permitted values include: `automatic` or `any`. If not provided, defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine. */ + /** + * @description We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Permitted values include: `automatic` or `any`. If not provided, defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine. + * @enum {string} + */ readonly request_three_d_secure?: "any" | "automatic" | "challenge_only"; }; /** Shipping */ @@ -8051,7 +8695,10 @@ export interface definitions { readonly livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "sku"; readonly package_dimensions?: definitions["package_dimensions"]; /** @description The cost of the item as a positive integer in the smallest currency unit (that is, 100 cents to charge $1.00, or 100 to charge ¥100, Japanese Yen being a zero-decimal currency). */ @@ -8102,7 +8749,10 @@ export interface definitions { /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata?: { readonly [key: string]: unknown }; readonly multibanco?: definitions["source_type_multibanco"]; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "source"; readonly owner?: definitions["source_owner"]; readonly p24?: definitions["source_type_p24"]; @@ -8116,7 +8766,10 @@ export interface definitions { /** @description The status of the source, one of `canceled`, `chargeable`, `consumed`, `failed`, or `pending`. Only `chargeable` sources can be used to create a charge. */ readonly status: string; readonly three_d_secure?: definitions["source_type_three_d_secure"]; - /** @description The `type` of the source. The `type` is a payment method, one of `ach_credit_transfer`, `ach_debit`, `alipay`, `bancontact`, `card`, `card_present`, `eps`, `giropay`, `ideal`, `multibanco`, `klarna`, `p24`, `sepa_debit`, `sofort`, `three_d_secure`, or `wechat`. An additional hash is included on the source with a name matching this value. It contains additional information specific to the [payment method](https://stripe.com/docs/sources) used. */ + /** + * @description The `type` of the source. The `type` is a payment method, one of `ach_credit_transfer`, `ach_debit`, `alipay`, `bancontact`, `card`, `card_present`, `eps`, `giropay`, `ideal`, `multibanco`, `klarna`, `p24`, `sepa_debit`, `sofort`, `three_d_secure`, or `wechat`. An additional hash is included on the source with a name matching this value. It contains additional information specific to the [payment method](https://stripe.com/docs/sources) used. + * @enum {string} + */ readonly type: | "ach_credit_transfer" | "ach_debit" @@ -8162,7 +8815,10 @@ export interface definitions { readonly id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "source_mandate_notification"; /** @description The reason of the mandate notification. Valid reasons are `mandate_confirmed` or `debit_initiated`. */ readonly reason: string; @@ -8276,7 +8932,10 @@ export interface definitions { readonly id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "source_transaction"; readonly paper_check?: definitions["source_transaction_paper_check_data"]; readonly sepa_credit_transfer?: definitions["source_transaction_sepa_credit_transfer_data"]; @@ -8284,7 +8943,10 @@ export interface definitions { readonly source: string; /** @description The status of the transaction, one of `succeeded`, `pending`, or `failed`. */ readonly status: string; - /** @description The type of source this transaction is attached to. */ + /** + * @description The type of source this transaction is attached to. + * @enum {string} + */ readonly type: | "ach_credit_transfer" | "ach_debit" @@ -8566,7 +9228,10 @@ export interface definitions { readonly cancel_at_period_end: boolean; /** @description If the subscription has been canceled, the date of that cancellation. If the subscription was canceled with `cancel_at_period_end`, `canceled_at` will still reflect the date of the initial cancellation request, not the end of the subscription period when the subscription is automatically moved to a canceled state. */ readonly canceled_at?: number; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. + * @enum {string} + */ readonly collection_method?: "charge_automatically" | "send_invoice"; /** @description Time at which the object was created. Measured in seconds since the Unix epoch. */ readonly created: number; @@ -8598,7 +9263,10 @@ export interface definitions { readonly data: readonly definitions["subscription_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -8611,7 +9279,10 @@ export interface definitions { readonly metadata: { readonly [key: string]: unknown }; /** @description Specifies the approximate timestamp on which any pending invoice items will be billed according to the schedule provided at `pending_invoice_item_interval`. */ readonly next_pending_invoice_item_invoice?: number; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "subscription"; readonly pause_collection?: definitions["subscriptions_resource_pause_collection"]; readonly pending_invoice_item_interval?: definitions["subscription_pending_invoice_item_interval"]; @@ -8635,6 +9306,7 @@ export interface definitions { * If subscription `collection_method=charge_automatically` it becomes `past_due` when payment to renew it fails and `canceled` or `unpaid` (depending on your subscriptions settings) when Stripe has exhausted all payment retry attempts. * * If subscription `collection_method=send_invoice` it becomes `past_due` when its invoice is not paid by the due date, and `canceled` or `unpaid` if it is still not paid by an additional deadline after that. Note that when a subscription has a status of `unpaid`, no subsequent invoices will be attempted (invoices will be created, but then immediately automatically closed). After receiving updated payment information from a customer, you may choose to reopen and pay their closed invoices. + * @enum {string} */ readonly status: "active" | "canceled" | "incomplete" | "incomplete_expired" | "past_due" | "trialing" | "unpaid"; /** @description If provided, each invoice created by this subscription will apply the tax rate, increasing the amount billed to the customer. */ @@ -8664,7 +9336,10 @@ export interface definitions { readonly id: string; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "subscription_item"; readonly plan: definitions["plan"]; /** @description The [quantity](https://stripe.com/docs/subscriptions/quantities) of the plan to which the customer should be subscribed. */ @@ -8681,7 +9356,10 @@ export interface definitions { }; /** SubscriptionPendingInvoiceItemInterval */ readonly subscription_pending_invoice_item_interval: { - /** @description Specifies invoicing frequency. Either `day`, `week`, `month` or `year`. */ + /** + * @description Specifies invoicing frequency. Either `day`, `week`, `month` or `year`. + * @enum {string} + */ readonly interval: "day" | "month" | "week" | "year"; /** @description The number of intervals between invoices. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). */ readonly interval_count: number; @@ -8703,7 +9381,10 @@ export interface definitions { /** @description ID of the customer who owns the subscription schedule. */ readonly customer: string; readonly default_settings: definitions["subscription_schedules_resource_default_settings"]; - /** @description Behavior of the subscription schedule and underlying subscription when it ends. */ + /** + * @description Behavior of the subscription schedule and underlying subscription when it ends. + * @enum {string} + */ readonly end_behavior: "cancel" | "none" | "release" | "renew"; /** @description Unique identifier for the object. */ readonly id: string; @@ -8711,7 +9392,10 @@ export interface definitions { readonly livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata?: { readonly [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "subscription_schedule"; /** @description Configuration for the subscription schedule's phases. */ readonly phases: readonly definitions["subscription_schedule_phase_configuration"][]; @@ -8719,7 +9403,10 @@ export interface definitions { readonly released_at?: number; /** @description ID of the subscription once managed by the subscription schedule (if it is released). */ readonly released_subscription?: string; - /** @description The present status of the subscription schedule. Possible values are `not_started`, `active`, `completed`, `released`, and `canceled`. You can read more about the different states in our [behavior guide](https://stripe.com/docs/billing/subscriptions/subscription-schedules). */ + /** + * @description The present status of the subscription schedule. Possible values are `not_started`, `active`, `completed`, `released`, and `canceled`. You can read more about the different states in our [behavior guide](https://stripe.com/docs/billing/subscriptions/subscription-schedules). + * @enum {string} + */ readonly status: "active" | "canceled" | "completed" | "not_started" | "released"; /** @description ID of the subscription managed by the subscription schedule. */ readonly subscription?: string; @@ -8752,7 +9439,10 @@ export interface definitions { /** @description A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice subtotal that will be transferred to the application owner's Stripe account during this phase of the schedule. */ readonly application_fee_percent?: number; readonly billing_thresholds?: definitions["subscription_billing_thresholds"]; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. + * @enum {string} + */ readonly collection_method?: "charge_automatically" | "send_invoice"; /** @description ID of the coupon to use during this phase of the subscription schedule. */ readonly coupon?: string; @@ -8765,7 +9455,10 @@ export interface definitions { readonly invoice_settings?: definitions["invoice_setting_subscription_schedule_setting"]; /** @description Plans to subscribe during this phase of the subscription schedule. */ readonly plans: readonly definitions["subscription_schedule_configuration_item"][]; - /** @description Controls whether or not the subscription schedule will prorate when transitioning to this phase. Values are `create_prorations` and `none`. */ + /** + * @description Controls whether or not the subscription schedule will prorate when transitioning to this phase. Values are `create_prorations` and `none`. + * @enum {string} + */ readonly proration_behavior?: "always_invoice" | "create_prorations" | "none"; /** @description The start of this phase of the subscription schedule. */ readonly start_date: number; @@ -8777,7 +9470,10 @@ export interface definitions { /** SubscriptionSchedulesResourceDefaultSettings */ readonly subscription_schedules_resource_default_settings: { readonly billing_thresholds?: definitions["subscription_billing_thresholds"]; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. + * @enum {string} + */ readonly collection_method?: "charge_automatically" | "send_invoice"; /** @description ID of the default payment method for the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings. */ readonly default_payment_method?: string; @@ -8789,7 +9485,10 @@ export interface definitions { * should be paused. */ readonly subscriptions_resource_pause_collection: { - /** @description The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`. */ + /** + * @description The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`. + * @enum {string} + */ readonly behavior: "keep_as_draft" | "mark_uncollectible" | "void"; /** @description The time after which the subscription will resume collecting payments. */ readonly resumes_at?: number; @@ -8815,7 +9514,10 @@ export interface definitions { readonly tax_deducted_at_source: { /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "tax_deducted_at_source"; /** @description The end of the invoicing period. This TDS applies to Stripe fees collected during this invoicing period. */ readonly period_end: number; @@ -8842,9 +9544,15 @@ export interface definitions { readonly id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "tax_id"; - /** @description Type of the tax ID, one of `au_abn`, `ca_bn`, `ca_qst`, `ch_vat`, `es_cif`, `eu_vat`, `hk_br`, `in_gst`, `jp_cn`, `kr_brn`, `li_uid`, `mx_rfc`, `my_itn`, `my_sst`, `no_vat`, `nz_gst`, `ru_inn`, `sg_gst`, `sg_uen`, `th_vat`, `tw_vat`, `us_ein`, or `za_vat`. Note that some legacy tax IDs have type `unknown` */ + /** + * @description Type of the tax ID, one of `au_abn`, `ca_bn`, `ca_qst`, `ch_vat`, `es_cif`, `eu_vat`, `hk_br`, `in_gst`, `jp_cn`, `kr_brn`, `li_uid`, `mx_rfc`, `my_itn`, `my_sst`, `no_vat`, `nz_gst`, `ru_inn`, `sg_gst`, `sg_uen`, `th_vat`, `tw_vat`, `us_ein`, or `za_vat`. Note that some legacy tax IDs have type `unknown` + * @enum {string} + */ readonly type: | "au_abn" | "ca_bn" @@ -8876,7 +9584,10 @@ export interface definitions { }; /** tax_id_verification */ readonly tax_id_verification: { - /** @description Verification status, one of `pending`, `verified`, `unverified`, or `unavailable`. */ + /** + * @description Verification status, one of `pending`, `verified`, `unverified`, or `unavailable`. + * @enum {string} + */ readonly status: "pending" | "unavailable" | "unverified" | "verified"; /** @description Verified address. */ readonly verified_address?: string; @@ -8908,7 +9619,10 @@ export interface definitions { readonly livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "tax_rate"; /** @description This represents the tax rate percent out of 100. */ readonly percentage: number; @@ -8922,7 +9636,10 @@ export interface definitions { readonly "terminal.connection_token": { /** @description The id of the location that this connection token is scoped to. */ readonly location?: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "terminal.connection_token"; /** @description Your application should pass this token to the Stripe Terminal SDK. */ readonly secret: string; @@ -8943,7 +9660,10 @@ export interface definitions { readonly livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "terminal.location"; }; /** @@ -8955,7 +9675,10 @@ export interface definitions { readonly "terminal.reader": { /** @description The current software version of the reader. */ readonly device_sw_version?: string; - /** @description Type of reader, one of `bbpos_chipper2x` or `verifone_P400`. */ + /** + * @description Type of reader, one of `bbpos_chipper2x` or `verifone_P400`. + * @enum {string} + */ readonly device_type: "bbpos_chipper2x" | "verifone_P400"; /** @description Unique identifier for the object. */ readonly id: string; @@ -8969,7 +9692,10 @@ export interface definitions { readonly location?: string; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "terminal.reader"; /** @description Serial number of the reader. */ readonly serial_number: string; @@ -8996,7 +9722,10 @@ export interface definitions { readonly id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "three_d_secure"; /** @description If present, this is the URL that you should send the cardholder to for authentication. If you are going to use Stripe.js to display the authentication page in an iframe, you should use the value "_callback". */ readonly redirect_url?: string; @@ -9053,7 +9782,10 @@ export interface definitions { readonly id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "token"; /** @description Type of the token: `account`, `bank_account`, `card`, or `pii`. */ readonly type: string; @@ -9091,12 +9823,18 @@ export interface definitions { readonly livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "topup"; readonly source: definitions["source"]; /** @description Extra information about a top-up. This will appear on your source's bank statement. It must contain at least one letter. */ readonly statement_descriptor?: string; - /** @description The status of the top-up is either `canceled`, `failed`, `pending`, `reversed`, or `succeeded`. */ + /** + * @description The status of the top-up is either `canceled`, `failed`, `pending`, `reversed`, or `succeeded`. + * @enum {string} + */ readonly status: "canceled" | "failed" | "pending" | "reversed" | "succeeded"; /** @description A string that identifies this top-up as part of a group. */ readonly transfer_group?: string; @@ -9137,7 +9875,10 @@ export interface definitions { readonly livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "transfer"; /** * TransferReversalList @@ -9148,7 +9889,10 @@ export interface definitions { readonly data: readonly definitions["transfer_reversal"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -9204,7 +9948,10 @@ export interface definitions { readonly id: string; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "transfer_reversal"; /** @description ID of the refund responsible for the transfer reversal. */ readonly source_refund?: string; @@ -9226,7 +9973,10 @@ export interface definitions { readonly transform_usage: { /** @description Divide usage by this number. */ readonly divide_by: number; - /** @description After division, either round the result `up` or `down`. */ + /** + * @description After division, either round the result `up` or `down`. + * @enum {string} + */ readonly round: "down" | "up"; }; /** @@ -9241,7 +9991,10 @@ export interface definitions { readonly id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "usage_record"; /** @description The usage quantity for the specified date. */ readonly quantity: number; @@ -9258,7 +10011,10 @@ export interface definitions { readonly invoice?: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "usage_record_summary"; readonly period: definitions["period"]; /** @description The ID of the subscription item this summary is describing. */ @@ -9293,7 +10049,10 @@ export interface definitions { readonly livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "webhook_endpoint"; /** @description The endpoint's secret, used to generate [webhook signatures](https://stripe.com/docs/webhooks/signatures). Only returned at creation. */ readonly secret?: string; @@ -9405,7 +10164,10 @@ export interface operations { readonly support_url?: string; readonly url?: string; }; - /** @description The business type. */ + /** + * @description The business type. + * @enum {string} + */ readonly business_type?: "company" | "government_entity" | "individual" | "non_profit"; /** * company_specs @@ -9448,6 +10210,7 @@ export interface operations { readonly name_kanji?: string; readonly owners_provided?: boolean; readonly phone?: string; + /** @enum {string} */ readonly structure?: | "" | "government_instrumentality" @@ -9592,8 +10355,10 @@ export interface operations { /** transfer_schedule_specs */ readonly schedule?: { readonly delay_days?: unknown; + /** @enum {string} */ readonly interval?: "daily" | "manual" | "monthly" | "weekly"; readonly monthly_anchor?: number; + /** @enum {string} */ readonly weekly_anchor?: | "friday" | "monday" @@ -9722,7 +10487,10 @@ export interface operations { readonly payload?: { /** @description The name of the person or business that owns the bank account. */ readonly account_holder_name?: string; - /** @description The type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description The type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string} + */ readonly account_holder_type?: "" | "company" | "individual"; /** @description City/District/Suburb/Town/Village. */ readonly address_city?: string; @@ -9795,7 +10563,10 @@ export interface operations { readonly data: readonly definitions["capability"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -9878,7 +10649,10 @@ export interface operations { readonly data: readonly definitions["bank_account"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -9956,7 +10730,10 @@ export interface operations { readonly payload?: { /** @description The name of the person or business that owns the bank account. */ readonly account_holder_name?: string; - /** @description The type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description The type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string} + */ readonly account_holder_type?: "" | "company" | "individual"; /** @description City/District/Suburb/Town/Village. */ readonly address_city?: string; @@ -10093,7 +10870,10 @@ export interface operations { readonly data: readonly definitions["person"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -10409,7 +11189,10 @@ export interface operations { readonly data: readonly definitions["person"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -10710,7 +11493,10 @@ export interface operations { readonly payload: { /** @description The identifier of the account to create an account link for. */ readonly account: string; - /** @description Which information the platform needs to collect from the user. One of `currently_due` or `eventually_due`. Default is `currently_due`. */ + /** + * @description Which information the platform needs to collect from the user. One of `currently_due` or `eventually_due`. Default is `currently_due`. + * @enum {string} + */ readonly collect?: "currently_due" | "eventually_due"; /** @description Specifies which fields in the response should be expanded. */ readonly expand?: readonly string[]; @@ -10718,7 +11504,10 @@ export interface operations { readonly failure_url: string; /** @description The URL that the user will be redirected to upon leaving or completing the linked flow successfully. */ readonly success_url: string; - /** @description The type of account link the user is requesting. Possible values are `custom_account_verification` or `custom_account_update`. */ + /** + * @description The type of account link the user is requesting. Possible values are `custom_account_verification` or `custom_account_update`. + * @enum {string} + */ readonly type: "custom_account_update" | "custom_account_verification"; }; }; @@ -10756,7 +11545,10 @@ export interface operations { readonly data: readonly definitions["account"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -10797,7 +11589,10 @@ export interface operations { readonly support_url?: string; readonly url?: string; }; - /** @description The business type. */ + /** + * @description The business type. + * @enum {string} + */ readonly business_type?: "company" | "government_entity" | "individual" | "non_profit"; /** * company_specs @@ -10840,6 +11635,7 @@ export interface operations { readonly name_kanji?: string; readonly owners_provided?: boolean; readonly phone?: string; + /** @enum {string} */ readonly structure?: | "" | "government_instrumentality" @@ -10986,8 +11782,10 @@ export interface operations { /** transfer_schedule_specs */ readonly schedule?: { readonly delay_days?: unknown; + /** @enum {string} */ readonly interval?: "daily" | "manual" | "monthly" | "weekly"; readonly monthly_anchor?: number; + /** @enum {string} */ readonly weekly_anchor?: | "friday" | "monday" @@ -11009,7 +11807,10 @@ export interface operations { readonly ip?: string; readonly user_agent?: string; }; - /** @description The type of Stripe account to create. Currently must be `custom`, as only [Custom accounts](https://stripe.com/docs/connect/custom-accounts) may be created via the API. */ + /** + * @description The type of Stripe account to create. Currently must be `custom`, as only [Custom accounts](https://stripe.com/docs/connect/custom-accounts) may be created via the API. + * @enum {string} + */ readonly type?: "custom" | "express" | "standard"; }; }; @@ -11077,7 +11878,10 @@ export interface operations { readonly support_url?: string; readonly url?: string; }; - /** @description The business type. */ + /** + * @description The business type. + * @enum {string} + */ readonly business_type?: "company" | "government_entity" | "individual" | "non_profit"; /** * company_specs @@ -11120,6 +11924,7 @@ export interface operations { readonly name_kanji?: string; readonly owners_provided?: boolean; readonly phone?: string; + /** @enum {string} */ readonly structure?: | "" | "government_instrumentality" @@ -11264,8 +12069,10 @@ export interface operations { /** transfer_schedule_specs */ readonly schedule?: { readonly delay_days?: unknown; + /** @enum {string} */ readonly interval?: "daily" | "manual" | "monthly" | "weekly"; readonly monthly_anchor?: number; + /** @enum {string} */ readonly weekly_anchor?: | "friday" | "monday" @@ -11396,7 +12203,10 @@ export interface operations { readonly payload?: { /** @description The name of the person or business that owns the bank account. */ readonly account_holder_name?: string; - /** @description The type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description The type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string} + */ readonly account_holder_type?: "" | "company" | "individual"; /** @description City/District/Suburb/Town/Village. */ readonly address_city?: string; @@ -11473,7 +12283,10 @@ export interface operations { readonly data: readonly definitions["capability"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -11561,7 +12374,10 @@ export interface operations { readonly data: readonly definitions["bank_account"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -11644,7 +12460,10 @@ export interface operations { readonly payload?: { /** @description The name of the person or business that owns the bank account. */ readonly account_holder_name?: string; - /** @description The type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description The type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string} + */ readonly account_holder_type?: "" | "company" | "individual"; /** @description City/District/Suburb/Town/Village. */ readonly address_city?: string; @@ -11789,7 +12608,10 @@ export interface operations { readonly data: readonly definitions["person"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -12112,7 +12934,10 @@ export interface operations { readonly data: readonly definitions["person"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -12462,7 +13287,10 @@ export interface operations { readonly data: readonly definitions["apple_pay_domain"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -12561,7 +13389,10 @@ export interface operations { readonly data: readonly definitions["application_fee"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -12701,7 +13532,10 @@ export interface operations { readonly data: readonly definitions["fee_refund"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -12809,7 +13643,10 @@ export interface operations { readonly data: readonly definitions["balance_transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -12882,7 +13719,10 @@ export interface operations { readonly data: readonly definitions["balance_transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -12973,7 +13813,10 @@ export interface operations { readonly data: readonly definitions["bitcoin_receiver"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -13034,7 +13877,10 @@ export interface operations { readonly data: readonly definitions["bitcoin_transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -13071,7 +13917,10 @@ export interface operations { readonly data: readonly definitions["bitcoin_transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -13111,7 +13960,10 @@ export interface operations { readonly data: readonly definitions["charge"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -13248,6 +14100,7 @@ export interface operations { * @description A set of key-value pairs you can attach to a charge giving information about its riskiness. If you believe a charge is fraudulent, include a `user_report` key with a value of `fraudulent`. If you believe a charge is safe, include a `user_report` key with a value of `safe`. Stripe will use the information you send to improve our fraud detection algorithms. */ readonly fraud_details?: { + /** @enum {string} */ readonly user_report: "" | "fraudulent" | "safe"; }; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ @@ -13472,6 +14325,7 @@ export interface operations { readonly expand?: readonly string[]; readonly metadata?: unknown; readonly payment_intent?: string; + /** @enum {string} */ readonly reason?: "duplicate" | "fraudulent" | "requested_by_customer"; readonly refund_application_fee?: boolean; readonly reverse_transfer?: boolean; @@ -13514,7 +14368,10 @@ export interface operations { readonly data: readonly definitions["refund"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -13541,6 +14398,7 @@ export interface operations { /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ readonly metadata?: { readonly [key: string]: unknown }; readonly payment_intent?: string; + /** @enum {string} */ readonly reason?: "duplicate" | "fraudulent" | "requested_by_customer"; readonly refund_application_fee?: boolean; readonly reverse_transfer?: boolean; @@ -13633,7 +14491,10 @@ export interface operations { readonly data: readonly definitions["checkout.session"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -13651,7 +14512,10 @@ export interface operations { readonly body: { /** Body parameters for the request. */ readonly payload: { - /** @description Specify whether Checkout should collect the customer's billing address. */ + /** + * @description Specify whether Checkout should collect the customer's billing address. + * @enum {string} + */ readonly billing_address_collection?: "auto" | "required"; /** @description The URL the customer will be directed to if they decide to cancel payment and return to your website. */ readonly cancel_url: string; @@ -13695,7 +14559,10 @@ export interface operations { readonly quantity: number; readonly tax_rates?: readonly string[]; }[]; - /** @description The IETF language tag of the locale Checkout is displayed in. If blank or `auto`, the browser's locale is used. */ + /** + * @description The IETF language tag of the locale Checkout is displayed in. If blank or `auto`, the browser's locale is used. + * @enum {string} + */ readonly locale?: | "auto" | "da" @@ -13716,7 +14583,10 @@ export interface operations { | "zh"; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ readonly metadata?: { readonly [key: string]: unknown }; - /** @description The mode of the Checkout Session, one of `payment`, `setup`, or `subscription`. */ + /** + * @description The mode of the Checkout Session, one of `payment`, `setup`, or `subscription`. + * @enum {string} + */ readonly mode?: "payment" | "setup" | "subscription"; /** * payment_intent_data_params @@ -13724,11 +14594,13 @@ export interface operations { */ readonly payment_intent_data?: { readonly application_fee_amount?: number; + /** @enum {string} */ readonly capture_method?: "automatic" | "manual"; readonly description?: string; readonly metadata?: { readonly [key: string]: unknown }; readonly on_behalf_of?: string; readonly receipt_email?: string; + /** @enum {string} */ readonly setup_future_usage?: "off_session" | "on_session"; /** shipping */ readonly shipping?: { @@ -14015,6 +14887,7 @@ export interface operations { * relevant text on the page, such as the submit button. `submit_type` can only be * specified on Checkout Sessions in `payment` mode, but not Checkout Sessions * in `subscription` or `setup` mode. + * @enum {string} */ readonly submit_type?: "auto" | "book" | "donate" | "pay"; /** @@ -14099,7 +14972,10 @@ export interface operations { readonly data: readonly definitions["country_spec"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -14156,7 +15032,10 @@ export interface operations { readonly data: readonly definitions["coupon"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -14182,7 +15061,10 @@ export interface operations { readonly amount_off?: number; /** @description Three-letter [ISO code for the currency](https://stripe.com/docs/currencies) of the `amount_off` parameter (required if `amount_off` is passed). */ readonly currency?: string; - /** @description Specifies how long the discount will be in effect. Can be `forever`, `once`, or `repeating`. */ + /** + * @description Specifies how long the discount will be in effect. Can be `forever`, `once`, or `repeating`. + * @enum {string} + */ readonly duration: "forever" | "once" | "repeating"; /** @description Required only if `duration` is `repeating`, in which case it must be a positive integer that specifies the number of months the discount will be in effect. */ readonly duration_in_months?: number; @@ -14308,7 +15190,10 @@ export interface operations { readonly data: readonly definitions["credit_note"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -14356,6 +15241,7 @@ export interface operations { readonly invoice_line_item?: string; readonly quantity?: number; readonly tax_rates?: readonly string[]; + /** @enum {string} */ readonly type: "custom_line_item" | "invoice_line_item"; readonly unit_amount?: number; readonly unit_amount_decimal?: string; @@ -14366,7 +15252,10 @@ export interface operations { readonly metadata?: { readonly [key: string]: unknown }; /** @description The integer amount in **%s** representing the amount that is credited outside of Stripe. */ readonly out_of_band_amount?: number; - /** @description Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory` */ + /** + * @description Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory` + * @enum {string} + */ readonly reason?: "duplicate" | "fraudulent" | "order_change" | "product_unsatisfactory"; /** @description ID of an existing refund to link this credit note to. */ readonly refund?: string; @@ -14467,7 +15356,10 @@ export interface operations { readonly data: readonly definitions["credit_note_line_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -14504,7 +15396,10 @@ export interface operations { readonly data: readonly definitions["credit_note_line_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -14616,7 +15511,10 @@ export interface operations { readonly data: readonly definitions["customer"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -14682,10 +15580,14 @@ export interface operations { * Whenever you attach a card to a customer, Stripe will automatically validate the card. */ readonly source?: string; - /** @description The customer's tax exemption. One of `none`, `exempt`, or `reverse`. */ + /** + * @description The customer's tax exemption. One of `none`, `exempt`, or `reverse`. + * @enum {string} + */ readonly tax_exempt?: "" | "exempt" | "none" | "reverse"; /** @description The customer's tax IDs. */ readonly tax_id_data?: readonly { + /** @enum {string} */ readonly type: | "au_abn" | "ca_bn" @@ -14825,7 +15727,10 @@ export interface operations { * Whenever you attach a card to a customer, Stripe will automatically validate the card. */ readonly source?: string; - /** @description The customer's tax exemption. One of `none`, `exempt`, or `reverse`. */ + /** + * @description The customer's tax exemption. One of `none`, `exempt`, or `reverse`. + * @enum {string} + */ readonly tax_exempt?: "" | "exempt" | "none" | "reverse"; /** @description Unix timestamp representing the end of the trial period the customer will get before being charged for the first time. This will always overwrite any trials that might apply via a subscribed plan. If set, trial_end will override the default trial period of the plan the customer is being subscribed to. The special value `now` can be provided to end the customer's trial immediately. Can be at most two years from `billing_cycle_anchor`. */ readonly trial_end?: unknown; @@ -14886,7 +15791,10 @@ export interface operations { readonly data: readonly definitions["customer_balance_transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -15009,7 +15917,10 @@ export interface operations { readonly data: readonly definitions["bank_account"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -15097,7 +16008,10 @@ export interface operations { readonly payload?: { /** @description The name of the person or business that owns the bank account. */ readonly account_holder_name?: string; - /** @description The type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description The type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string} + */ readonly account_holder_type?: "company" | "individual"; /** @description City/District/Suburb/Town/Village. */ readonly address_city?: string; @@ -15232,7 +16146,10 @@ export interface operations { readonly data: readonly definitions["card"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -15320,7 +16237,10 @@ export interface operations { readonly payload?: { /** @description The name of the person or business that owns the bank account. */ readonly account_holder_name?: string; - /** @description The type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description The type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string} + */ readonly account_holder_type?: "company" | "individual"; /** @description City/District/Suburb/Town/Village. */ readonly address_city?: string; @@ -15465,7 +16385,10 @@ export interface operations { readonly data: readonly definitions["alipay_account"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -15553,7 +16476,10 @@ export interface operations { readonly payload?: { /** @description The name of the person or business that owns the bank account. */ readonly account_holder_name?: string; - /** @description The type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description The type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string} + */ readonly account_holder_type?: "company" | "individual"; /** @description City/District/Suburb/Town/Village. */ readonly address_city?: string; @@ -15685,7 +16611,10 @@ export interface operations { readonly data: readonly definitions["subscription"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -15718,7 +16647,10 @@ export interface operations { readonly cancel_at?: number; /** @description Boolean indicating whether this subscription should cancel at the end of the current period. */ readonly cancel_at_period_end?: boolean; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. + * @enum {string} + */ readonly collection_method?: "charge_automatically" | "send_invoice"; /** @description The code of the coupon to apply to this subscription. A coupon applied to a subscription will only affect invoices created for that particular subscription. */ readonly coupon?: string; @@ -15750,6 +16682,7 @@ export interface operations { * Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not create a subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more. * * `pending_if_incomplete` is only used with updates and cannot be passed when creating a subscription. + * @enum {string} */ readonly payment_behavior?: "allow_incomplete" | "error_if_incomplete" | "pending_if_incomplete"; /** @description Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval. */ @@ -15760,6 +16693,7 @@ export interface operations { * @description Determines how to handle [prorations](https://stripe.com/docs/subscriptions/billing-cycle#prorations) resulting from the `billing_cycle_anchor`. Valid values are `create_prorations` or `none`. * * Passing `create_prorations` will cause proration invoice items to be created when applicable. Prorations can be disabled by passing `none`. If no value is passed, the default is `create_prorations`. + * @enum {string} */ readonly proration_behavior?: "always_invoice" | "create_prorations" | "none"; /** @description A non-negative decimal (with at most four decimal places) between 0 and 100. This represents the percentage of the subscription invoice subtotal that will be calculated and added as tax to the final amount in each billing period. For example, a plan which charges $10/month with a `tax_percent` of `20.0` will charge $12 per invoice. To unset a previously-set value, pass an empty string. This field has been deprecated and will be removed in a future API version, for further information view the [migration docs](https://stripe.com/docs/billing/migration/taxes) for `tax_rates`. */ @@ -15819,7 +16753,10 @@ export interface operations { readonly payload?: { /** @description A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice subtotal that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions). */ readonly application_fee_percent?: number; - /** @description Either `now` or `unchanged`. Setting the value to `now` resets the subscription's billing cycle anchor to the current time. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle). */ + /** + * @description Either `now` or `unchanged`. Setting the value to `now` resets the subscription's billing cycle anchor to the current time. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle). + * @enum {string} + */ readonly billing_cycle_anchor?: "now" | "unchanged"; /** @description Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds. */ readonly billing_thresholds?: unknown; @@ -15827,7 +16764,10 @@ export interface operations { readonly cancel_at?: unknown; /** @description Boolean indicating whether this subscription should cancel at the end of the current period. */ readonly cancel_at_period_end?: boolean; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. + * @enum {string} + */ readonly collection_method?: "charge_automatically" | "send_invoice"; /** @description The code of the coupon to apply to this subscription. A coupon applied to a subscription will only affect invoices created for that particular subscription. */ readonly coupon?: string; @@ -15864,6 +16804,7 @@ export interface operations { * Use `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes). * * Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not create a subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more. + * @enum {string} */ readonly payment_behavior?: "allow_incomplete" | "error_if_incomplete" | "pending_if_incomplete"; /** @description Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval. */ @@ -15876,6 +16817,7 @@ export interface operations { * Passing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`. * * Prorations can be disabled by passing `none`. + * @enum {string} */ readonly proration_behavior?: "always_invoice" | "create_prorations" | "none"; /** @description If set, the proration will be calculated as though the subscription was updated at the given time. This can be used to apply exactly the same proration that was previewed with [upcoming invoice](https://stripe.com/docs/api#retrieve_customer_invoice) endpoint. It can also be used to implement custom proration logic, such as prorating by day instead of by second, by providing the time that you wish to use for proration calculations. */ @@ -16002,7 +16944,10 @@ export interface operations { readonly data: readonly definitions["tax_id"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -16025,7 +16970,10 @@ export interface operations { readonly payload: { /** @description Specifies which fields in the response should be expanded. */ readonly expand?: readonly string[]; - /** @description Type of the tax ID, one of `eu_vat`, `nz_gst`, `au_abn`, `in_gst`, `no_vat`, `za_vat`, `ch_vat`, `mx_rfc`, `sg_uen`, `ru_inn`, `ca_bn`, `hk_br`, `es_cif`, `tw_vat`, `th_vat`, `jp_cn`, `li_uid`, `my_itn`, `us_ein`, `kr_brn`, `ca_qst`, `my_sst`, or `sg_gst` */ + /** + * @description Type of the tax ID, one of `eu_vat`, `nz_gst`, `au_abn`, `in_gst`, `no_vat`, `za_vat`, `ch_vat`, `mx_rfc`, `sg_uen`, `ru_inn`, `ca_bn`, `hk_br`, `es_cif`, `tw_vat`, `th_vat`, `jp_cn`, `li_uid`, `my_itn`, `us_ein`, `kr_brn`, `ca_qst`, `my_sst`, or `sg_gst` + * @enum {string} + */ readonly type: | "au_abn" | "ca_bn" @@ -16134,7 +17082,10 @@ export interface operations { readonly data: readonly definitions["dispute"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -16342,7 +17293,10 @@ export interface operations { readonly data: readonly definitions["event"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -16397,7 +17351,10 @@ export interface operations { readonly data: readonly definitions["exchange_rate"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -16457,7 +17414,10 @@ export interface operations { readonly data: readonly definitions["file_link"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -16572,7 +17532,10 @@ export interface operations { readonly data: readonly definitions["file"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -16607,7 +17570,10 @@ export interface operations { readonly expires_at?: number; readonly metadata?: unknown; }; - /** @description The purpose of the uploaded file. Possible values are `additional_verification`, `business_icon`, `business_logo`, `customer_signature`, `dispute_evidence`, `identity_document`, `pci_document`, or `tax_document_user_upload`. */ + /** + * @description The purpose of the uploaded file. Possible values are `additional_verification`, `business_icon`, `business_logo`, `customer_signature`, `dispute_evidence`, `identity_document`, `pci_document`, or `tax_document_user_upload`. + * @enum {string} + */ readonly purpose: | "additional_verification" | "business_icon" @@ -16681,7 +17647,10 @@ export interface operations { readonly data: readonly definitions["invoiceitem"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -16867,7 +17836,10 @@ export interface operations { readonly data: readonly definitions["invoice"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -16889,7 +17861,10 @@ export interface operations { readonly application_fee_amount?: number; /** @description Controls whether Stripe will perform [automatic collection](https://stripe.com/docs/billing/invoices/workflow/#auto_advance) of the invoice. When `false`, the invoice's state will not automatically advance without an explicit action. */ readonly auto_advance?: boolean; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this invoice using the default source attached to the customer. When sending an invoice, Stripe will email this invoice to the customer with payment instructions. Defaults to `charge_automatically`. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this invoice using the default source attached to the customer. When sending an invoice, Stripe will email this invoice to the customer with payment instructions. Defaults to `charge_automatically`. + * @enum {string} + */ readonly collection_method?: "charge_automatically" | "send_invoice"; /** @description A list of up to 4 custom fields to be displayed on the invoice. */ readonly custom_fields?: readonly { @@ -17067,7 +18042,10 @@ export interface operations { readonly data: readonly definitions["line_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -17121,7 +18099,10 @@ export interface operations { readonly application_fee_amount?: number; /** @description Controls whether Stripe will perform [automatic collection](https://stripe.com/docs/billing/invoices/workflow/#auto_advance) of the invoice. */ readonly auto_advance?: boolean; - /** @description Either `charge_automatically` or `send_invoice`. This field can be updated only on `draft` invoices. */ + /** + * @description Either `charge_automatically` or `send_invoice`. This field can be updated only on `draft` invoices. + * @enum {string} + */ readonly collection_method?: "charge_automatically" | "send_invoice"; /** @description A list of up to 4 custom fields to be displayed on the invoice. If a value for `custom_fields` is specified, the list specified will replace the existing custom field list on this invoice. Pass an empty string to remove previously-defined fields. */ readonly custom_fields?: readonly { @@ -17234,7 +18215,10 @@ export interface operations { readonly data: readonly definitions["line_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -17387,7 +18371,10 @@ export interface operations { readonly data: readonly definitions["issuer_fraud_record"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -17454,7 +18441,10 @@ export interface operations { readonly data: readonly definitions["issuing.authorization"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -17602,7 +18592,10 @@ export interface operations { readonly data: readonly definitions["issuing.cardholder"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -18551,13 +19544,20 @@ export interface operations { | "womens_ready_to_wear_stores" | "wrecking_and_salvage_yards" )[]; + /** @enum {string} */ readonly interval: "all_time" | "daily" | "monthly" | "per_authorization" | "weekly" | "yearly"; }[]; readonly spending_limits_currency?: string; }; - /** @description Specifies whether to permit authorizations on this cardholder's cards. Defaults to `active`. */ + /** + * @description Specifies whether to permit authorizations on this cardholder's cards. Defaults to `active`. + * @enum {string} + */ readonly status?: "active" | "inactive"; - /** @description One of `individual` or `company`. */ + /** + * @description One of `individual` or `company`. + * @enum {string} + */ readonly type: "company" | "individual"; }; }; @@ -19533,11 +20533,15 @@ export interface operations { | "womens_ready_to_wear_stores" | "wrecking_and_salvage_yards" )[]; + /** @enum {string} */ readonly interval: "all_time" | "daily" | "monthly" | "per_authorization" | "weekly" | "yearly"; }[]; readonly spending_limits_currency?: string; }; - /** @description Specifies whether to permit authorizations on this cardholder's cards. */ + /** + * @description Specifies whether to permit authorizations on this cardholder's cards. + * @enum {string} + */ readonly status?: "active" | "inactive"; }; }; @@ -19588,7 +20592,10 @@ export interface operations { readonly data: readonly definitions["issuing.card"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -19616,7 +20623,10 @@ export interface operations { readonly metadata?: { readonly [key: string]: unknown }; /** @description The card this is meant to be a replacement for (if any). */ readonly replacement_for?: string; - /** @description If `replacement_for` is specified, this should indicate why that card is being replaced. */ + /** + * @description If `replacement_for` is specified, this should indicate why that card is being replaced. + * @enum {string} + */ readonly replacement_reason?: "damaged" | "expired" | "lost" | "stolen"; /** * shipping_specs @@ -19633,7 +20643,9 @@ export interface operations { readonly state?: string; }; readonly name: string; + /** @enum {string} */ readonly service?: "express" | "priority" | "standard"; + /** @enum {string} */ readonly type?: "bulk" | "individual"; }; /** @@ -20513,12 +21525,19 @@ export interface operations { | "womens_ready_to_wear_stores" | "wrecking_and_salvage_yards" )[]; + /** @enum {string} */ readonly interval: "all_time" | "daily" | "monthly" | "per_authorization" | "weekly" | "yearly"; }[]; }; - /** @description Whether authorizations can be approved on this card. Defaults to `inactive`. */ + /** + * @description Whether authorizations can be approved on this card. Defaults to `inactive`. + * @enum {string} + */ readonly status?: "active" | "inactive"; - /** @description The type of card to issue. Possible values are `physical` or `virtual`. */ + /** + * @description The type of card to issue. Possible values are `physical` or `virtual`. + * @enum {string} + */ readonly type: "physical" | "virtual"; }; }; @@ -20565,7 +21584,10 @@ export interface operations { readonly body: { /** Body parameters for the request. */ readonly payload?: { - /** @description Reason why the `status` of this card is `canceled`. */ + /** + * @description Reason why the `status` of this card is `canceled`. + * @enum {string} + */ readonly cancellation_reason?: "lost" | "stolen"; /** @description Specifies which fields in the response should be expanded. */ readonly expand?: readonly string[]; @@ -21448,10 +22470,14 @@ export interface operations { | "womens_ready_to_wear_stores" | "wrecking_and_salvage_yards" )[]; + /** @enum {string} */ readonly interval: "all_time" | "daily" | "monthly" | "per_authorization" | "weekly" | "yearly"; }[]; }; - /** @description Dictates whether authorizations can be approved on this card. If this card is being canceled because it was lost or stolen, this information should be provided as `cancellation_reason`. */ + /** + * @description Dictates whether authorizations can be approved on this card. If this card is being canceled because it was lost or stolen, this information should be provided as `cancellation_reason`. + * @enum {string} + */ readonly status?: "active" | "canceled" | "inactive"; }; }; @@ -21488,7 +22514,10 @@ export interface operations { readonly data: readonly definitions["issuing.dispute"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -21596,7 +22625,10 @@ export interface operations { readonly data: readonly definitions["issuing.settlement"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -21684,7 +22716,10 @@ export interface operations { readonly data: readonly definitions["issuing.transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -21792,7 +22827,10 @@ export interface operations { readonly data: readonly definitions["order_return"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -21859,7 +22897,10 @@ export interface operations { readonly data: readonly definitions["order"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -21894,6 +22935,7 @@ export interface operations { readonly description?: string; readonly parent?: string; readonly quantity?: number; + /** @enum {string} */ readonly type?: "discount" | "shipping" | "sku" | "tax"; }[]; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ @@ -21976,7 +23018,10 @@ export interface operations { readonly carrier: string; readonly tracking_number: string; }; - /** @description Current order status. One of `created`, `paid`, `canceled`, `fulfilled`, or `returned`. More detail in the [Orders Guide](https://stripe.com/docs/orders/guide#understanding-order-statuses). */ + /** + * @description Current order status. One of `created`, `paid`, `canceled`, `fulfilled`, or `returned`. More detail in the [Orders Guide](https://stripe.com/docs/orders/guide#understanding-order-statuses). + * @enum {string} + */ readonly status?: "canceled" | "created" | "fulfilled" | "paid" | "returned"; }; }; @@ -22044,6 +23089,7 @@ export interface operations { readonly description?: string; readonly parent?: string; readonly quantity?: number; + /** @enum {string} */ readonly type?: "discount" | "shipping" | "sku" | "tax"; }[]; }; @@ -22085,7 +23131,10 @@ export interface operations { readonly data: readonly definitions["payment_intent"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -22122,10 +23171,14 @@ export interface operations { * more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts). */ readonly application_fee_amount?: number; - /** @description Controls when the funds will be captured from the customer's account. */ + /** + * @description Controls when the funds will be captured from the customer's account. + * @enum {string} + */ readonly capture_method?: "automatic" | "manual"; /** @description Set to `true` to attempt to [confirm](https://stripe.com/docs/api/payment_intents/confirm) this PaymentIntent immediately. This parameter defaults to `false`. When creating and confirming a PaymentIntent at the same time, parameters available in the [confirm](https://stripe.com/docs/api/payment_intents/confirm) API may also be provided. */ readonly confirm?: boolean; + /** @enum {string} */ readonly confirmation_method?: "automatic" | "manual"; /** @description Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). */ readonly currency: string; @@ -22160,6 +23213,7 @@ export interface operations { readonly ip_address: string; readonly user_agent: string; }; + /** @enum {string} */ readonly type: "offline" | "online"; }; }; @@ -22194,6 +23248,7 @@ export interface operations { * Providing this parameter will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any required actions from the user are complete. If no Customer was provided, the payment method can still be [attached](https://stripe.com/docs/api/payment_methods/attach) to a Customer after the transaction completes. * * When processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication). + * @enum {string} */ readonly setup_future_usage?: "off_session" | "on_session"; /** @@ -22334,6 +23389,7 @@ export interface operations { * When processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication). * * If `setup_future_usage` is already set and you are performing a request using a publishable key, you may only update the value from `on_session` to `off_session`. + * @enum {string} */ readonly setup_future_usage?: "" | "off_session" | "on_session"; /** @description Shipping information for this PaymentIntent. */ @@ -22378,7 +23434,10 @@ export interface operations { readonly body: { /** Body parameters for the request. */ readonly payload?: { - /** @description Reason for canceling this PaymentIntent. Possible values are `duplicate`, `fraudulent`, `requested_by_customer`, or `abandoned` */ + /** + * @description Reason for canceling this PaymentIntent. Possible values are `duplicate`, `fraudulent`, `requested_by_customer`, or `abandoned` + * @enum {string} + */ readonly cancellation_reason?: "abandoned" | "duplicate" | "fraudulent" | "requested_by_customer"; /** @description Specifies which fields in the response should be expanded. */ readonly expand?: readonly string[]; @@ -22505,6 +23564,7 @@ export interface operations { readonly ip_address: string; readonly user_agent: string; }; + /** @enum {string} */ readonly type: "offline" | "online"; }; }; @@ -22537,6 +23597,7 @@ export interface operations { * When processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication). * * If `setup_future_usage` is already set and you are performing a request using a publishable key, you may only update the value from `on_session` to `off_session`. + * @enum {string} */ readonly setup_future_usage?: "" | "off_session" | "on_session"; /** @description Shipping information for this PaymentIntent. */ @@ -22582,7 +23643,10 @@ export interface operations { readonly data: readonly definitions["payment_method"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -22637,6 +23701,7 @@ export interface operations { * @description If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method. */ readonly fpx?: { + /** @enum {string} */ readonly bank: | "affin_bank" | "alliance_bank" @@ -22664,6 +23729,7 @@ export interface operations { * @description If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method. */ readonly ideal?: { + /** @enum {string} */ readonly bank?: | "abn_amro" | "asn_bank" @@ -22689,7 +23755,10 @@ export interface operations { readonly sepa_debit?: { readonly iban: string; }; - /** @description The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type. Required unless `payment_method` is specified (see the [Cloning PaymentMethods](https://stripe.com/docs/payments/payment-methods/connect#cloning-payment-methods) guide) */ + /** + * @description The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type. Required unless `payment_method` is specified (see the [Cloning PaymentMethods](https://stripe.com/docs/payments/payment-methods/connect#cloning-payment-methods) guide) + * @enum {string} + */ readonly type?: "au_becs_debit" | "card" | "fpx" | "ideal" | "sepa_debit"; }; }; @@ -22876,7 +23945,10 @@ export interface operations { readonly data: readonly definitions["payout"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -22912,9 +23984,15 @@ export interface operations { readonly expand?: readonly string[]; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ readonly metadata?: { readonly [key: string]: unknown }; - /** @description The method used to send this payout, which can be `standard` or `instant`. `instant` is only supported for payouts to debit cards. (See [Instant payouts for marketplaces for more information](https://stripe.com/blog/instant-payouts-for-marketplaces).) */ + /** + * @description The method used to send this payout, which can be `standard` or `instant`. `instant` is only supported for payouts to debit cards. (See [Instant payouts for marketplaces for more information](https://stripe.com/blog/instant-payouts-for-marketplaces).) + * @enum {string} + */ readonly method?: "instant" | "standard"; - /** @description The balance type of your Stripe balance to draw this payout from. Balances for different payment sources are kept separately. You can find the amounts with the balances API. One of `bank_account`, `card`, or `fpx`. */ + /** + * @description The balance type of your Stripe balance to draw this payout from. Balances for different payment sources are kept separately. You can find the amounts with the balances API. One of `bank_account`, `card`, or `fpx`. + * @enum {string} + */ readonly source_type?: "bank_account" | "card" | "fpx"; /** @description A string to be displayed on the recipient's bank or card statement. This may be at most 22 characters. Attempting to use a `statement_descriptor` longer than 22 characters will return an error. Note: Most banks will truncate this information and/or display it inconsistently. Some may not display it at all. */ readonly statement_descriptor?: string; @@ -23033,7 +24111,10 @@ export interface operations { readonly data: readonly definitions["plan"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -23053,13 +24134,19 @@ export interface operations { readonly payload: { /** @description Whether the plan is currently available for new subscriptions. Defaults to `true`. */ readonly active?: boolean; - /** @description Specifies a usage aggregation strategy for plans of `usage_type=metered`. Allowed values are `sum` for summing up all usage during a period, `last_during_period` for using the last usage record reported within a period, `last_ever` for using the last usage record ever (across period bounds) or `max` which uses the usage record with the maximum reported usage during a period. Defaults to `sum`. */ + /** + * @description Specifies a usage aggregation strategy for plans of `usage_type=metered`. Allowed values are `sum` for summing up all usage during a period, `last_during_period` for using the last usage record reported within a period, `last_ever` for using the last usage record ever (across period bounds) or `max` which uses the usage record with the maximum reported usage during a period. Defaults to `sum`. + * @enum {string} + */ readonly aggregate_usage?: "last_during_period" | "last_ever" | "max" | "sum"; /** @description A positive integer in %s (or 0 for a free plan) representing how much to charge on a recurring basis. */ readonly amount?: number; /** @description Same as `amount`, but accepts a decimal value with at most 12 decimal places. Only one of `amount` and `amount_decimal` can be set. */ readonly amount_decimal?: string; - /** @description Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `amount`) will be charged per unit in `quantity` (for plans with `usage_type=licensed`), or per unit of total usage (for plans with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes. */ + /** + * @description Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `amount`) will be charged per unit in `quantity` (for plans with `usage_type=licensed`), or per unit of total usage (for plans with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes. + * @enum {string} + */ readonly billing_scheme?: "per_unit" | "tiered"; /** @description Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). */ readonly currency: string; @@ -23067,7 +24154,10 @@ export interface operations { readonly expand?: readonly string[]; /** @description An identifier randomly generated by Stripe. Used to identify this plan when subscribing a customer. You can optionally override this ID, but the ID must be unique across all plans in your Stripe account. You can, however, use the same plan ID in both live and test modes. */ readonly id?: string; - /** @description Specifies billing frequency. Either `day`, `week`, `month` or `year`. */ + /** + * @description Specifies billing frequency. Either `day`, `week`, `month` or `year`. + * @enum {string} + */ readonly interval: "day" | "month" | "week" | "year"; /** @description The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). */ readonly interval_count?: number; @@ -23095,7 +24185,10 @@ export interface operations { readonly unit_amount_decimal?: string; readonly up_to: unknown; }[]; - /** @description Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price, in `graduated` tiering pricing can successively change as the quantity grows. */ + /** + * @description Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price, in `graduated` tiering pricing can successively change as the quantity grows. + * @enum {string} + */ readonly tiers_mode?: "graduated" | "volume"; /** * transform_usage_param @@ -23103,11 +24196,15 @@ export interface operations { */ readonly transform_usage?: { readonly divide_by: number; + /** @enum {string} */ readonly round: "down" | "up"; }; /** @description Default number of trial days when subscribing a customer to this plan using [`trial_from_plan=true`](https://stripe.com/docs/api#create_subscription-trial_from_plan). */ readonly trial_period_days?: number; - /** @description Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`. */ + /** + * @description Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`. + * @enum {string} + */ readonly usage_type?: "licensed" | "metered"; }; }; @@ -23231,7 +24328,10 @@ export interface operations { readonly data: readonly definitions["product"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -23288,7 +24388,10 @@ export interface operations { * It must contain at least one letter. */ readonly statement_descriptor?: string; - /** @description The type of the product. Defaults to `service` if not explicitly specified, enabling use of this product with Subscriptions and Plans. Set this parameter to `good` to use this product with Orders and SKUs. On API versions before `2018-02-05`, this field defaults to `good` for compatibility reasons. */ + /** + * @description The type of the product. Defaults to `service` if not explicitly specified, enabling use of this product with Subscriptions and Plans. Set this parameter to `good` to use this product with Orders and SKUs. On API versions before `2018-02-05`, this field defaults to `good` for compatibility reasons. + * @enum {string} + */ readonly type?: "good" | "service"; /** @description A label that represents units of this product in Stripe and on customers’ receipts and invoices. When set, this will be included in associated invoice line item descriptions. */ readonly unit_label?: string; @@ -23427,7 +24530,10 @@ export interface operations { readonly data: readonly definitions["radar.early_fraud_warning"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -23491,7 +24597,10 @@ export interface operations { readonly data: readonly definitions["radar.value_list_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -23595,7 +24704,10 @@ export interface operations { readonly data: readonly definitions["radar.value_list"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -23617,7 +24729,10 @@ export interface operations { readonly alias: string; /** @description Specifies which fields in the response should be expanded. */ readonly expand?: readonly string[]; - /** @description Type of the items in the value list. One of `card_fingerprint`, `card_bin`, `email`, `ip_address`, `country`, `string`, or `case_sensitive_string`. Use `string` if the item type is unknown or mixed. */ + /** + * @description Type of the items in the value list. One of `card_fingerprint`, `card_bin`, `email`, `ip_address`, `country`, `string`, or `case_sensitive_string`. Use `string` if the item type is unknown or mixed. + * @enum {string} + */ readonly item_type?: | "card_bin" | "card_fingerprint" @@ -23740,7 +24855,10 @@ export interface operations { readonly data: readonly definitions["recipient"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -23906,7 +25024,10 @@ export interface operations { readonly data: readonly definitions["refund"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -23931,6 +25052,7 @@ export interface operations { /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ readonly metadata?: { readonly [key: string]: unknown }; readonly payment_intent?: string; + /** @enum {string} */ readonly reason?: "duplicate" | "fraudulent" | "requested_by_customer"; readonly refund_application_fee?: boolean; readonly reverse_transfer?: boolean; @@ -24023,7 +25145,10 @@ export interface operations { readonly data: readonly definitions["reporting.report_run"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -24054,6 +25179,7 @@ export interface operations { readonly interval_end?: number; readonly interval_start?: number; readonly payout?: string; + /** @enum {string} */ readonly reporting_category?: | "advance" | "advance_funding" @@ -24086,6 +25212,7 @@ export interface operations { | "topup_reversal" | "transfer" | "transfer_reversal"; + /** @enum {string} */ readonly timezone?: | "Africa/Abidjan" | "Africa/Accra" @@ -24735,7 +25862,10 @@ export interface operations { readonly data: readonly definitions["reporting.report_type"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -24791,7 +25921,10 @@ export interface operations { readonly data: readonly definitions["review"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -24877,7 +26010,10 @@ export interface operations { readonly data: readonly definitions["setup_intent"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -24927,6 +26063,7 @@ export interface operations { readonly ip_address: string; readonly user_agent: string; }; + /** @enum {string} */ readonly type: "offline" | "online"; }; }; @@ -24943,6 +26080,7 @@ export interface operations { readonly payment_method_options?: { /** setup_intent_param */ readonly card?: { + /** @enum {string} */ readonly request_three_d_secure?: "any" | "automatic"; }; }; @@ -24958,7 +26096,10 @@ export interface operations { readonly amount: number; readonly currency: string; }; - /** @description Indicates how the payment method is intended to be used in the future. If not provided, this value defaults to `off_session`. */ + /** + * @description Indicates how the payment method is intended to be used in the future. If not provided, this value defaults to `off_session`. + * @enum {string} + */ readonly usage?: "off_session" | "on_session"; }; }; @@ -25034,6 +26175,7 @@ export interface operations { readonly payment_method_options?: { /** setup_intent_param */ readonly card?: { + /** @enum {string} */ readonly request_three_d_secure?: "any" | "automatic"; }; }; @@ -25066,7 +26208,10 @@ export interface operations { readonly body: { /** Body parameters for the request. */ readonly payload?: { - /** @description Reason for canceling this SetupIntent. Possible values are `abandoned`, `requested_by_customer`, or `duplicate` */ + /** + * @description Reason for canceling this SetupIntent. Possible values are `abandoned`, `requested_by_customer`, or `duplicate` + * @enum {string} + */ readonly cancellation_reason?: "abandoned" | "duplicate" | "requested_by_customer"; /** @description Specifies which fields in the response should be expanded. */ readonly expand?: readonly string[]; @@ -25126,6 +26271,7 @@ export interface operations { readonly ip_address: string; readonly user_agent: string; }; + /** @enum {string} */ readonly type: "offline" | "online"; }; }; @@ -25138,6 +26284,7 @@ export interface operations { readonly payment_method_options?: { /** setup_intent_param */ readonly card?: { + /** @enum {string} */ readonly request_three_d_secure?: "any" | "automatic"; }; }; @@ -25182,7 +26329,10 @@ export interface operations { readonly data: readonly definitions["scheduled_query_run"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -25247,7 +26397,10 @@ export interface operations { readonly data: readonly definitions["sku"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -25283,7 +26436,9 @@ export interface operations { */ readonly inventory: { readonly quantity?: number; + /** @enum {string} */ readonly type?: "bucket" | "finite" | "infinite"; + /** @enum {string} */ readonly value?: "" | "in_stock" | "limited" | "out_of_stock"; }; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ @@ -25367,7 +26522,9 @@ export interface operations { */ readonly inventory?: { readonly quantity?: number; + /** @enum {string} */ readonly type?: "bucket" | "finite" | "infinite"; + /** @enum {string} */ readonly value?: "" | "in_stock" | "limited" | "out_of_stock"; }; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ @@ -25424,7 +26581,10 @@ export interface operations { readonly customer?: string; /** @description Specifies which fields in the response should be expanded. */ readonly expand?: readonly string[]; - /** @description The authentication `flow` of the source to create. `flow` is one of `redirect`, `receiver`, `code_verification`, `none`. It is generally inferred unless a type supports multiple flows. */ + /** + * @description The authentication `flow` of the source to create. `flow` is one of `redirect`, `receiver`, `code_verification`, `none`. It is generally inferred unless a type supports multiple flows. + * @enum {string} + */ readonly flow?: "code_verification" | "none" | "receiver" | "redirect"; /** * mandate_params @@ -25445,13 +26605,17 @@ export interface operations { readonly ip?: string; readonly user_agent?: string; }; + /** @enum {string} */ readonly status: "accepted" | "pending" | "refused" | "revoked"; + /** @enum {string} */ readonly type?: "offline" | "online"; readonly user_agent?: string; }; readonly amount?: unknown; readonly currency?: string; + /** @enum {string} */ readonly interval?: "one_time" | "scheduled" | "variable"; + /** @enum {string} */ readonly notification_method?: "deprecated_none" | "email" | "manual" | "none" | "stripe_email"; }; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ @@ -25481,6 +26645,7 @@ export interface operations { * @description Optional parameters for the receiver flow. Can be set only if the source is a receiver (`flow` is `receiver`). */ readonly receiver?: { + /** @enum {string} */ readonly refund_attributes_method?: "email" | "manual" | "none"; }; /** @@ -25501,6 +26666,7 @@ export interface operations { readonly description?: string; readonly parent?: string; readonly quantity?: number; + /** @enum {string} */ readonly type?: "discount" | "shipping" | "sku" | "tax"; }[]; /** order_shipping */ @@ -25526,7 +26692,10 @@ export interface operations { readonly token?: string; /** @description The `type` of the source to create. Required unless `customer` and `original_source` are specified (see the [Cloning card Sources](https://stripe.com/docs/sources/connect#cloning-card-sources) guide) */ readonly type?: string; - /** @description Either `reusable` or `single_use`. Whether this source should be reusable or not. Some source types may or may not be reusable by construction, while others may leave the option at creation. If an incompatible value is passed, an error will be returned. */ + /** + * @description Either `reusable` or `single_use`. Whether this source should be reusable or not. Some source types may or may not be reusable by construction, while others may leave the option at creation. If an incompatible value is passed, an error will be returned. + * @enum {string} + */ readonly usage?: "reusable" | "single_use"; }; }; @@ -25602,13 +26771,17 @@ export interface operations { readonly ip?: string; readonly user_agent?: string; }; + /** @enum {string} */ readonly status: "accepted" | "pending" | "refused" | "revoked"; + /** @enum {string} */ readonly type?: "offline" | "online"; readonly user_agent?: string; }; readonly amount?: unknown; readonly currency?: string; + /** @enum {string} */ readonly interval?: "one_time" | "scheduled" | "variable"; + /** @enum {string} */ readonly notification_method?: "deprecated_none" | "email" | "manual" | "none" | "stripe_email"; }; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ @@ -25642,6 +26815,7 @@ export interface operations { readonly description?: string; readonly parent?: string; readonly quantity?: number; + /** @enum {string} */ readonly type?: "discount" | "shipping" | "sku" | "tax"; }[]; /** order_shipping */ @@ -25722,7 +26896,10 @@ export interface operations { readonly data: readonly definitions["source_transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -25807,7 +26984,10 @@ export interface operations { readonly data: readonly definitions["subscription_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -25837,6 +27017,7 @@ export interface operations { * Use `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes). * * Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not create a subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more. + * @enum {string} */ readonly payment_behavior?: "allow_incomplete" | "error_if_incomplete" | "pending_if_incomplete"; /** @description The identifier of the plan to add to the subscription. */ @@ -25849,6 +27030,7 @@ export interface operations { * Passing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`. * * Prorations can be disabled by passing `none`. + * @enum {string} */ readonly proration_behavior?: "always_invoice" | "create_prorations" | "none"; /** @description If set, the proration will be calculated as though the subscription was updated at the given time. This can be used to apply the same proration that was previewed with the [upcoming invoice](https://stripe.com/docs/api#retrieve_customer_invoice) endpoint. */ @@ -25918,6 +27100,7 @@ export interface operations { * Use `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes). * * Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not create a subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more. + * @enum {string} */ readonly payment_behavior?: "allow_incomplete" | "error_if_incomplete" | "pending_if_incomplete"; /** @description The identifier of the new plan for this subscription item. */ @@ -25930,6 +27113,7 @@ export interface operations { * Passing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`. * * Prorations can be disabled by passing `none`. + * @enum {string} */ readonly proration_behavior?: "always_invoice" | "create_prorations" | "none"; /** @description If set, the proration will be calculated as though the subscription was updated at the given time. This can be used to apply the same proration that was previewed with the [upcoming invoice](https://stripe.com/docs/api#retrieve_customer_invoice) endpoint. */ @@ -25971,6 +27155,7 @@ export interface operations { * Passing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`. * * Prorations can be disabled by passing `none`. + * @enum {string} */ readonly proration_behavior?: "always_invoice" | "create_prorations" | "none"; /** @description If set, the proration will be calculated as though the subscription was updated at the given time. This can be used to apply the same proration that was previewed with the [upcoming invoice](https://stripe.com/docs/api#retrieve_customer_invoice) endpoint. */ @@ -26017,7 +27202,10 @@ export interface operations { readonly data: readonly definitions["usage_record_summary"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -26046,7 +27234,10 @@ export interface operations { readonly body: { /** Body parameters for the request. */ readonly payload: { - /** @description Valid values are `increment` (default) or `set`. When using `increment` the specified `quantity` will be added to the usage at the specified timestamp. The `set` action will overwrite the usage quantity at that timestamp. If the subscription has [billing thresholds](https://stripe.com/docs/api/subscriptions/object#subscription_object-billing_thresholds), `increment` is the only allowed value. */ + /** + * @description Valid values are `increment` (default) or `set`. When using `increment` the specified `quantity` will be added to the usage at the specified timestamp. The `set` action will overwrite the usage quantity at that timestamp. If the subscription has [billing thresholds](https://stripe.com/docs/api/subscriptions/object#subscription_object-billing_thresholds), `increment` is the only allowed value. + * @enum {string} + */ readonly action?: "increment" | "set"; /** @description Specifies which fields in the response should be expanded. */ readonly expand?: readonly string[]; @@ -26101,7 +27292,10 @@ export interface operations { readonly data: readonly definitions["subscription_schedule"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -26127,6 +27321,7 @@ export interface operations { */ readonly default_settings?: { readonly billing_thresholds?: unknown; + /** @enum {string} */ readonly collection_method?: "charge_automatically" | "send_invoice"; readonly default_payment_method?: string; /** subscription_schedules_param */ @@ -26134,7 +27329,10 @@ export interface operations { readonly days_until_due?: number; }; }; - /** @description Configures how the subscription schedule behaves when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running.`cancel` will end the subscription schedule and cancel the underlying subscription. */ + /** + * @description Configures how the subscription schedule behaves when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running.`cancel` will end the subscription schedule and cancel the underlying subscription. + * @enum {string} + */ readonly end_behavior?: "cancel" | "none" | "release" | "renew"; /** @description Specifies which fields in the response should be expanded. */ readonly expand?: readonly string[]; @@ -26146,6 +27344,7 @@ export interface operations { readonly phases?: readonly { readonly application_fee_percent?: number; readonly billing_thresholds?: unknown; + /** @enum {string} */ readonly collection_method?: "charge_automatically" | "send_invoice"; readonly coupon?: string; readonly default_payment_method?: string; @@ -26162,6 +27361,7 @@ export interface operations { readonly quantity?: number; readonly tax_rates?: readonly string[]; }[]; + /** @enum {string} */ readonly proration_behavior?: "always_invoice" | "create_prorations" | "none"; readonly tax_percent?: number; readonly trial?: boolean; @@ -26220,6 +27420,7 @@ export interface operations { */ readonly default_settings?: { readonly billing_thresholds?: unknown; + /** @enum {string} */ readonly collection_method?: "charge_automatically" | "send_invoice"; readonly default_payment_method?: string; /** subscription_schedules_param */ @@ -26227,7 +27428,10 @@ export interface operations { readonly days_until_due?: number; }; }; - /** @description Configures how the subscription schedule behaves when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running.`cancel` will end the subscription schedule and cancel the underlying subscription. */ + /** + * @description Configures how the subscription schedule behaves when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running.`cancel` will end the subscription schedule and cancel the underlying subscription. + * @enum {string} + */ readonly end_behavior?: "cancel" | "none" | "release" | "renew"; /** @description Specifies which fields in the response should be expanded. */ readonly expand?: readonly string[]; @@ -26237,6 +27441,7 @@ export interface operations { readonly phases?: readonly { readonly application_fee_percent?: number; readonly billing_thresholds?: unknown; + /** @enum {string} */ readonly collection_method?: "charge_automatically" | "send_invoice"; readonly coupon?: string; readonly default_payment_method?: string; @@ -26253,6 +27458,7 @@ export interface operations { readonly quantity?: number; readonly tax_rates?: readonly string[]; }[]; + /** @enum {string} */ readonly proration_behavior?: "always_invoice" | "create_prorations" | "none"; readonly start_date?: unknown; readonly tax_percent?: number; @@ -26261,7 +27467,10 @@ export interface operations { }[]; /** @description This field has been renamed to `proration_behavior`. `prorate=true` can be replaced with `proration_behavior=create_prorations` and `prorate=false` can be replaced with `proration_behavior=none`. */ readonly prorate?: boolean; - /** @description If the update changes the current phase, indicates if the changes should be prorated. Valid values are `create_prorations` or `none`, and the default value is `create_prorations`. */ + /** + * @description If the update changes the current phase, indicates if the changes should be prorated. Valid values are `create_prorations` or `none`, and the default value is `create_prorations`. + * @enum {string} + */ readonly proration_behavior?: "always_invoice" | "create_prorations" | "none"; }; }; @@ -26365,7 +27574,10 @@ export interface operations { readonly data: readonly definitions["subscription"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -26395,7 +27607,10 @@ export interface operations { readonly cancel_at?: number; /** @description Boolean indicating whether this subscription should cancel at the end of the current period. */ readonly cancel_at_period_end?: boolean; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. + * @enum {string} + */ readonly collection_method?: "charge_automatically" | "send_invoice"; /** @description The code of the coupon to apply to this subscription. A coupon applied to a subscription will only affect invoices created for that particular subscription. */ readonly coupon?: string; @@ -26429,6 +27644,7 @@ export interface operations { * Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not create a subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more. * * `pending_if_incomplete` is only used with updates and cannot be passed when creating a subscription. + * @enum {string} */ readonly payment_behavior?: "allow_incomplete" | "error_if_incomplete" | "pending_if_incomplete"; /** @description Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval. */ @@ -26439,6 +27655,7 @@ export interface operations { * @description Determines how to handle [prorations](https://stripe.com/docs/subscriptions/billing-cycle#prorations) resulting from the `billing_cycle_anchor`. Valid values are `create_prorations` or `none`. * * Passing `create_prorations` will cause proration invoice items to be created when applicable. Prorations can be disabled by passing `none`. If no value is passed, the default is `create_prorations`. + * @enum {string} */ readonly proration_behavior?: "always_invoice" | "create_prorations" | "none"; /** @description A non-negative decimal (with at most four decimal places) between 0 and 100. This represents the percentage of the subscription invoice subtotal that will be calculated and added as tax to the final amount in each billing period. For example, a plan which charges $10/month with a `tax_percent` of `20.0` will charge $12 per invoice. To unset a previously-set value, pass an empty string. This field has been deprecated and will be removed in a future API version, for further information view the [migration docs](https://stripe.com/docs/billing/migration/taxes) for `tax_rates`. */ @@ -26496,7 +27713,10 @@ export interface operations { readonly payload?: { /** @description A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice subtotal that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions). */ readonly application_fee_percent?: number; - /** @description Either `now` or `unchanged`. Setting the value to `now` resets the subscription's billing cycle anchor to the current time. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle). */ + /** + * @description Either `now` or `unchanged`. Setting the value to `now` resets the subscription's billing cycle anchor to the current time. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle). + * @enum {string} + */ readonly billing_cycle_anchor?: "now" | "unchanged"; /** @description Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds. */ readonly billing_thresholds?: unknown; @@ -26504,7 +27724,10 @@ export interface operations { readonly cancel_at?: unknown; /** @description Boolean indicating whether this subscription should cancel at the end of the current period. */ readonly cancel_at_period_end?: boolean; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. + * @enum {string} + */ readonly collection_method?: "charge_automatically" | "send_invoice"; /** @description The code of the coupon to apply to this subscription. A coupon applied to a subscription will only affect invoices created for that particular subscription. */ readonly coupon?: string; @@ -26541,6 +27764,7 @@ export interface operations { * Use `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes). * * Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not create a subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more. + * @enum {string} */ readonly payment_behavior?: "allow_incomplete" | "error_if_incomplete" | "pending_if_incomplete"; /** @description Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval. */ @@ -26553,6 +27777,7 @@ export interface operations { * Passing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`. * * Prorations can be disabled by passing `none`. + * @enum {string} */ readonly proration_behavior?: "always_invoice" | "create_prorations" | "none"; /** @description If set, the proration will be calculated as though the subscription was updated at the given time. This can be used to apply exactly the same proration that was previewed with [upcoming invoice](https://stripe.com/docs/api#retrieve_customer_invoice) endpoint. It can also be used to implement custom proration logic, such as prorating by day instead of by second, by providing the time that you wish to use for proration calculations. */ @@ -26657,7 +27882,10 @@ export interface operations { readonly data: readonly definitions["tax_rate"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -26807,7 +28035,10 @@ export interface operations { readonly data: readonly definitions["terminal.location"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -26966,7 +28197,10 @@ export interface operations { readonly data: readonly definitions["terminal.reader"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -27091,6 +28325,7 @@ export interface operations { * @description Information for the account this token will represent. */ readonly account?: { + /** @enum {string} */ readonly business_type?: "company" | "government_entity" | "individual" | "non_profit"; /** company_specs */ readonly company?: { @@ -27130,6 +28365,7 @@ export interface operations { readonly name_kanji?: string; readonly owners_provided?: boolean; readonly phone?: string; + /** @enum {string} */ readonly structure?: | "" | "government_instrumentality" @@ -27226,6 +28462,7 @@ export interface operations { */ readonly bank_account?: { readonly account_holder_name?: string; + /** @enum {string} */ readonly account_holder_type?: "company" | "individual"; readonly account_number: string; readonly country: string; @@ -27378,7 +28615,10 @@ export interface operations { readonly data: readonly definitions["topup"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -27529,7 +28769,10 @@ export interface operations { readonly data: readonly definitions["transfer"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -27561,7 +28804,10 @@ export interface operations { readonly metadata?: { readonly [key: string]: unknown }; /** @description You can use this parameter to transfer funds from a charge before they are added to your available balance. A pending balance will transfer immediately but the funds will not become available until the original charge becomes available. [See the Connect documentation](https://stripe.com/docs/connect/charges-transfers#transfer-availability) for details. */ readonly source_transaction?: string; - /** @description The source balance to use for this transfer. One of `bank_account`, `card`, or `fpx`. For most users, this will default to `card`. */ + /** + * @description The source balance to use for this transfer. One of `bank_account`, `card`, or `fpx`. For most users, this will default to `card`. + * @enum {string} + */ readonly source_type?: "bank_account" | "card" | "fpx"; /** @description A string that identifies this transaction as part of a group. See the [Connect documentation](https://stripe.com/docs/connect/charges-transfers#transfer-options) for details. */ readonly transfer_group?: string; @@ -27604,7 +28850,10 @@ export interface operations { readonly data: readonly definitions["transfer_reversal"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -27786,7 +29035,10 @@ export interface operations { readonly data: readonly definitions["webhook_endpoint"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -27804,7 +29056,10 @@ export interface operations { readonly body: { /** Body parameters for the request. */ readonly payload: { - /** @description Events sent to this endpoint will be generated with this Stripe Version instead of your account's default Stripe Version. */ + /** + * @description Events sent to this endpoint will be generated with this Stripe Version instead of your account's default Stripe Version. + * @enum {string} + */ readonly api_version?: | "2011-01-01" | "2011-06-21" diff --git a/test/v2/expected/stripe.ts b/test/v2/expected/stripe.ts index 34468ddbf..9a88678c7 100644 --- a/test/v2/expected/stripe.ts +++ b/test/v2/expected/stripe.ts @@ -1492,7 +1492,10 @@ export interface definitions { */ account: { business_profile?: definitions["account_business_profile"]; - /** @description The business type. */ + /** + * @description The business type. + * @enum {string} + */ business_type?: "company" | "government_entity" | "individual" | "non_profit"; capabilities?: definitions["account_capabilities"]; /** @description Whether the account can create live charges. */ @@ -1517,7 +1520,10 @@ export interface definitions { data: definitions["bank_account"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -1527,14 +1533,20 @@ export interface definitions { individual?: definitions["person"]; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata?: { [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "account"; /** @description Whether Stripe can send payouts to this account. */ payouts_enabled?: boolean; requirements?: definitions["account_requirements"]; settings?: definitions["account_settings"]; tos_acceptance?: definitions["account_tos_acceptance"]; - /** @description The Stripe account type. Can be `standard`, `express`, or `custom`. */ + /** + * @description The Stripe account type. Can be `standard`, `express`, or `custom`. + * @enum {string} + */ type?: "custom" | "express" | "standard"; }; /** AccountBrandingSettings */ @@ -1568,19 +1580,40 @@ export interface definitions { }; /** AccountCapabilities */ account_capabilities: { - /** @description The status of the BECS Direct Debit (AU) payments capability of the account, or whether the account can directly process BECS Direct Debit (AU) charges. */ + /** + * @description The status of the BECS Direct Debit (AU) payments capability of the account, or whether the account can directly process BECS Direct Debit (AU) charges. + * @enum {string} + */ au_becs_debit_payments?: "active" | "inactive" | "pending"; - /** @description The status of the card issuing capability of the account, or whether you can use Issuing to distribute funds on cards */ + /** + * @description The status of the card issuing capability of the account, or whether you can use Issuing to distribute funds on cards + * @enum {string} + */ card_issuing?: "active" | "inactive" | "pending"; - /** @description The status of the card payments capability of the account, or whether the account can directly process credit and debit card charges. */ + /** + * @description The status of the card payments capability of the account, or whether the account can directly process credit and debit card charges. + * @enum {string} + */ card_payments?: "active" | "inactive" | "pending"; - /** @description The status of the legacy payments capability of the account. */ + /** + * @description The status of the legacy payments capability of the account. + * @enum {string} + */ legacy_payments?: "active" | "inactive" | "pending"; - /** @description The status of the tax reporting 1099-K (US) capability of the account. */ + /** + * @description The status of the tax reporting 1099-K (US) capability of the account. + * @enum {string} + */ tax_reporting_us_1099_k?: "active" | "inactive" | "pending"; - /** @description The status of the tax reporting 1099-MISC (US) capability of the account. */ + /** + * @description The status of the tax reporting 1099-MISC (US) capability of the account. + * @enum {string} + */ tax_reporting_us_1099_misc?: "active" | "inactive" | "pending"; - /** @description The status of the transfers capability of the account, or whether your platform can transfer funds to the account. */ + /** + * @description The status of the transfers capability of the account, or whether your platform can transfer funds to the account. + * @enum {string} + */ transfers?: "active" | "inactive" | "pending"; }; /** AccountCapabilityRequirements */ @@ -1632,7 +1665,10 @@ export interface definitions { created: number; /** @description The timestamp at which this account link will expire. */ expires_at: number; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "account_link"; /** @description The URL for the account link. */ url: string; @@ -1673,7 +1709,10 @@ export interface definitions { }; /** AccountRequirementsError */ account_requirements_error: { - /** @description The code for the type of error. */ + /** + * @description The code for the type of error. + * @enum {string} + */ code: | "invalid_address_city_state_postal_code" | "invalid_street_address" @@ -1764,7 +1803,10 @@ export interface definitions { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata?: { [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "alipay_account"; /** @description If the Alipay account object is not reusable, the exact amount that you can create a charge for. */ payment_amount?: number; @@ -1795,7 +1837,10 @@ export interface definitions { payment_method?: definitions["payment_method"]; setup_intent?: definitions["setup_intent"]; source?: definitions["bank_account"]; - /** @description The type of error returned. One of `api_connection_error`, `api_error`, `authentication_error`, `card_error`, `idempotency_error`, `invalid_request_error`, or `rate_limit_error` */ + /** + * @description The type of error returned. One of `api_connection_error`, `api_error`, `authentication_error`, `card_error`, `idempotency_error`, `invalid_request_error`, or `rate_limit_error` + * @enum {string} + */ type: | "api_connection_error" | "api_error" @@ -1814,7 +1859,10 @@ export interface definitions { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "apple_pay_domain"; }; /** Application */ @@ -1823,7 +1871,10 @@ export interface definitions { id: string; /** @description The name of the application. */ name?: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "application"; }; /** PlatformFee */ @@ -1848,7 +1899,10 @@ export interface definitions { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "application_fee"; /** @description ID of the corresponding charge on the platform account, if this fee was the result of a charge using the `destination` parameter. */ originating_transaction?: string; @@ -1863,7 +1917,10 @@ export interface definitions { data: definitions["fee_refund"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -1890,7 +1947,10 @@ export interface definitions { connect_reserved?: definitions["balance_amount"][]; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "balance"; /** @description Funds that are not yet available in the balance, due to the 7-day rolling pay cycle. The pending balance for each currency, and for each payment type, can be found in the `source_types` property. */ pending: definitions["balance_amount"][]; @@ -1940,7 +2000,10 @@ export interface definitions { id: string; /** @description Net amount of the transaction, in %s. */ net: number; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "balance_transaction"; /** @description [Learn more](https://stripe.com/docs/reports/reporting-categories) about how reporting categories can help you understand balance transactions from an accounting perspective. */ reporting_category: string; @@ -1948,7 +2011,10 @@ export interface definitions { source?: string; /** @description If the transaction's net funds are available in the Stripe balance yet. Either `available` or `pending`. */ status: string; - /** @description Transaction type: `adjustment`, `advance`, `advance_funding`, `application_fee`, `application_fee_refund`, `charge`, `connect_collection_transfer`, `issuing_authorization_hold`, `issuing_authorization_release`, `issuing_transaction`, `payment`, `payment_failure_refund`, `payment_refund`, `payout`, `payout_cancel`, `payout_failure`, `refund`, `refund_failure`, `reserve_transaction`, `reserved_funds`, `stripe_fee`, `stripe_fx_fee`, `tax_fee`, `topup`, `topup_reversal`, `transfer`, `transfer_cancel`, `transfer_failure`, or `transfer_refund`. [Learn more](https://stripe.com/docs/reports/balance-transaction-types) about balance transaction types and what they represent. If you are looking to classify transactions for accounting purposes, you might want to consider `reporting_category` instead. */ + /** + * @description Transaction type: `adjustment`, `advance`, `advance_funding`, `application_fee`, `application_fee_refund`, `charge`, `connect_collection_transfer`, `issuing_authorization_hold`, `issuing_authorization_release`, `issuing_transaction`, `payment`, `payment_failure_refund`, `payment_refund`, `payout`, `payout_cancel`, `payout_failure`, `refund`, `refund_failure`, `reserve_transaction`, `reserved_funds`, `stripe_fee`, `stripe_fx_fee`, `tax_fee`, `topup`, `topup_reversal`, `transfer`, `transfer_cancel`, `transfer_failure`, or `transfer_refund`. [Learn more](https://stripe.com/docs/reports/balance-transaction-types) about balance transaction types and what they represent. If you are looking to classify transactions for accounting purposes, you might want to consider `reporting_category` instead. + * @enum {string} + */ type: | "adjustment" | "advance" @@ -2015,7 +2081,10 @@ export interface definitions { last4: string; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata?: { [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "bank_account"; /** @description The routing transit number for the bank account. */ routing_number?: string; @@ -2055,7 +2124,10 @@ export interface definitions { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "billing_portal.session"; /** @description The URL to which Stripe should send customers when they click on the link to return to your website. */ return_url: string; @@ -2096,7 +2168,10 @@ export interface definitions { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "bitcoin_receiver"; /** @description The ID of the payment created from the receiver, if any. Hidden when viewing the receiver with a publishable key. */ payment?: string; @@ -2111,7 +2186,10 @@ export interface definitions { data: definitions["bitcoin_transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -2133,7 +2211,10 @@ export interface definitions { currency: string; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "bitcoin_transaction"; /** @description The receiver to which this transaction was sent. */ receiver: string; @@ -2149,14 +2230,20 @@ export interface definitions { account: string; /** @description The identifier for the capability. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "capability"; /** @description Whether the capability has been requested. */ requested: boolean; /** @description Time at which the capability was requested. Measured in seconds since the Unix epoch. */ requested_at?: number; requirements?: definitions["account_capability_requirements"]; - /** @description The status of the capability. Can be `active`, `inactive`, `pending`, or `unrequested`. */ + /** + * @description The status of the capability. Can be `active`, `inactive`, `pending`, or `unrequested`. + * @enum {string} + */ status: "active" | "disabled" | "inactive" | "pending" | "unrequested"; }; /** @@ -2217,7 +2304,10 @@ export interface definitions { metadata: { [key: string]: unknown }; /** @description Cardholder name. */ name?: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "card"; /** @description The recipient that this card belongs to. This attribute will not be in the card object if the card belongs to a customer or account instead. */ recipient?: string; @@ -2275,7 +2365,10 @@ export interface definitions { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "charge"; /** @description The account (if any) the charge was made on behalf of without triggering an automatic transfer. See the [Connect documentation](https://stripe.com/docs/connect/charges-transfers) for details. */ on_behalf_of?: string; @@ -2306,7 +2399,10 @@ export interface definitions { data: definitions["refund"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -2414,7 +2510,10 @@ export interface definitions { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description The IETF language tag of the locale Checkout is displayed in. If blank or `auto`, the browser's locale is used. */ + /** + * @description The IETF language tag of the locale Checkout is displayed in. If blank or `auto`, the browser's locale is used. + * @enum {string} + */ locale?: | "auto" | "da" @@ -2435,9 +2534,15 @@ export interface definitions { | "zh"; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata?: { [key: string]: unknown }; - /** @description The mode of the Checkout Session, one of `payment`, `setup`, or `subscription`. */ + /** + * @description The mode of the Checkout Session, one of `payment`, `setup`, or `subscription`. + * @enum {string} + */ mode?: "payment" | "setup" | "subscription"; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "checkout.session"; /** @description The ID of the PaymentIntent for Checkout Sessions in `payment` mode. */ payment_intent?: string; @@ -2455,6 +2560,7 @@ export interface definitions { * relevant text on the page, such as the submit button. `submit_type` can only be * specified on Checkout Sessions in `payment` mode, but not Checkout Sessions * in `subscription` or `setup` mode. + * @enum {string} */ submit_type?: "auto" | "book" | "donate" | "pay"; /** @description The ID of the subscription for Checkout Sessions in `subscription` mode. */ @@ -2500,7 +2606,10 @@ export interface definitions { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "connect_collection_transfer"; }; /** @@ -2517,7 +2626,10 @@ export interface definitions { default_currency: string; /** @description Unique identifier for the object. Represented as the ISO country code for this country. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "country_spec"; /** @description Currencies that can be accepted in the specific country (for transfers). */ supported_bank_account_currencies: { [key: string]: unknown }; @@ -2554,7 +2666,10 @@ export interface definitions { created: number; /** @description If `amount_off` has been set, the three-letter [ISO code for the currency](https://stripe.com/docs/currencies) of the amount to take off. */ currency?: string; - /** @description One of `forever`, `once`, and `repeating`. Describes how long a customer who applies this coupon will get the discount. */ + /** + * @description One of `forever`, `once`, and `repeating`. Describes how long a customer who applies this coupon will get the discount. + * @enum {string} + */ duration: "forever" | "once" | "repeating"; /** @description If `duration` is `repeating`, the number of months the coupon applies. Null if coupon `duration` is `forever` or `once`. */ duration_in_months?: number; @@ -2568,7 +2683,10 @@ export interface definitions { metadata: { [key: string]: unknown }; /** @description Name of the coupon displayed to customers on for instance invoices or receipts. */ name?: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "coupon"; /** @description Percent that will be taken off the subtotal of any invoices for this customer for the duration of the coupon. For example, a coupon with percent_off of 50 will make a %s100 invoice %s50 instead. */ percent_off?: number; @@ -2611,7 +2729,10 @@ export interface definitions { data: definitions["credit_note_line_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -2624,17 +2745,26 @@ export interface definitions { metadata: { [key: string]: unknown }; /** @description A unique number that identifies this particular credit note and appears on the PDF of the credit note and its associated invoice. */ number: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "credit_note"; /** @description Amount that was credited outside of Stripe. */ out_of_band_amount?: number; /** @description The link to download the PDF of the credit note. */ pdf: string; - /** @description Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory` */ + /** + * @description Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory` + * @enum {string} + */ reason?: "duplicate" | "fraudulent" | "order_change" | "product_unsatisfactory"; /** @description Refund related to this credit note. */ refund?: string; - /** @description Status of this credit note, one of `issued` or `void`. Learn more about [voiding credit notes](https://stripe.com/docs/billing/invoices/credit-notes#voiding). */ + /** + * @description Status of this credit note, one of `issued` or `void`. Learn more about [voiding credit notes](https://stripe.com/docs/billing/invoices/credit-notes#voiding). + * @enum {string} + */ status: "issued" | "void"; /** @description The integer amount in **%s** representing the amount of the credit note, excluding tax and discount. */ subtotal: number; @@ -2642,7 +2772,10 @@ export interface definitions { tax_amounts: definitions["credit_note_tax_amount"][]; /** @description The integer amount in **%s** representing the total amount of the credit note, including tax and discount. */ total: number; - /** @description Type of this credit note, one of `pre_payment` or `post_payment`. A `pre_payment` credit note means it was issued when the invoice was open. A `post_payment` credit note means it was issued when the invoice was paid. */ + /** + * @description Type of this credit note, one of `pre_payment` or `post_payment`. A `pre_payment` credit note means it was issued when the invoice was open. A `post_payment` credit note means it was issued when the invoice was paid. + * @enum {string} + */ type: "post_payment" | "pre_payment"; /** @description The time that the credit note was voided. */ voided_at?: number; @@ -2661,7 +2794,10 @@ export interface definitions { invoice_line_item?: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "credit_note_line_item"; /** @description The number of units of product being credited. */ quantity?: number; @@ -2669,7 +2805,10 @@ export interface definitions { tax_amounts: definitions["credit_note_tax_amount"][]; /** @description The tax rates which apply to the line item. */ tax_rates: definitions["tax_rate"][]; - /** @description The type of the credit note line item, one of `invoice_line_item` or `custom_line_item`. When the type is `invoice_line_item` there is an additional `invoice_line_item` property on the resource the value of which is the id of the credited line item on the invoice. */ + /** + * @description The type of the credit note line item, one of `invoice_line_item` or `custom_line_item`. When the type is `invoice_line_item` there is an additional `invoice_line_item` property on the resource the value of which is the id of the credited line item on the invoice. + * @enum {string} + */ type: "custom_line_item" | "invoice_line_item"; /** @description The cost of each unit of product being credited. */ unit_amount?: number; @@ -2728,7 +2867,10 @@ export interface definitions { name?: string; /** @description The suffix of the customer's next invoice number, e.g., 0001. */ next_invoice_sequence?: number; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "customer"; /** @description The customer's phone number. */ phone?: string; @@ -2744,7 +2886,10 @@ export interface definitions { data: definitions["alipay_account"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -2758,12 +2903,18 @@ export interface definitions { data: definitions["subscription"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; }; - /** @description Describes the customer's tax exemption status. One of `none`, `exempt`, or `reverse`. When set to `reverse`, invoice and receipt PDFs include the text **"Reverse charge"**. */ + /** + * @description Describes the customer's tax exemption status. One of `none`, `exempt`, or `reverse`. When set to `reverse`, invoice and receipt PDFs include the text **"Reverse charge"**. + * @enum {string} + */ tax_exempt?: "exempt" | "none" | "reverse"; /** * TaxIDsList @@ -2774,7 +2925,10 @@ export interface definitions { data: definitions["tax_id"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -2786,7 +2940,10 @@ export interface definitions { accepted_at?: number; offline?: definitions["offline_acceptance"]; online?: definitions["online_acceptance"]; - /** @description The type of customer acceptance information included with the Mandate. One of `online` or `offline`. */ + /** + * @description The type of customer acceptance information included with the Mandate. One of `online` or `offline`. + * @enum {string} + */ type: "offline" | "online"; }; /** @@ -2821,9 +2978,15 @@ export interface definitions { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata?: { [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "customer_balance_transaction"; - /** @description Transaction type: `adjustment`, `applied_to_invoice`, `credit_note`, `initial`, `invoice_too_large`, `invoice_too_small`, `unspent_receiver_credit`, or `unapplied_from_invoice`. See the [Customer Balance page](https://stripe.com/docs/billing/customer/balance#types) to learn more about transaction types. */ + /** + * @description Transaction type: `adjustment`, `applied_to_invoice`, `credit_note`, `initial`, `invoice_too_large`, `invoice_too_small`, `unspent_receiver_credit`, or `unapplied_from_invoice`. See the [Customer Balance page](https://stripe.com/docs/billing/customer/balance#types) to learn more about transaction types. + * @enum {string} + */ type: | "adjustment" | "applied_to_invoice" @@ -2837,231 +3000,381 @@ export interface definitions { }; /** DeletedAccount */ deleted_account: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "account"; }; /** AlipayDeletedAccount */ deleted_alipay_account: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "alipay_account"; }; /** DeletedApplePayDomain */ deleted_apple_pay_domain: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "apple_pay_domain"; }; /** DeletedBankAccount */ deleted_bank_account: { /** @description Three-letter [ISO code for the currency](https://stripe.com/docs/payouts) paid out to the bank account. */ currency?: string; - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "bank_account"; }; /** BitcoinDeletedReceiver */ deleted_bitcoin_receiver: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "bitcoin_receiver"; }; /** DeletedCard */ deleted_card: { /** @description Three-letter [ISO code for the currency](https://stripe.com/docs/payouts) paid out to the bank account. */ currency?: string; - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "card"; }; /** DeletedCoupon */ deleted_coupon: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "coupon"; }; /** DeletedCustomer */ deleted_customer: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "customer"; }; /** DeletedDiscount */ deleted_discount: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "discount"; }; /** Polymorphic */ deleted_external_account: { /** @description Three-letter [ISO code for the currency](https://stripe.com/docs/payouts) paid out to the bank account. */ currency?: string; - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "bank_account"; }; /** DeletedInvoice */ deleted_invoice: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "invoice"; }; /** DeletedInvoiceItem */ deleted_invoiceitem: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "invoiceitem"; }; /** Polymorphic */ deleted_payment_source: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "alipay_account"; }; /** DeletedPerson */ deleted_person: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "person"; }; /** DeletedPlan */ deleted_plan: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "plan"; }; /** DeletedProduct */ deleted_product: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "product"; }; /** RadarListDeletedList */ "deleted_radar.value_list": { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "radar.value_list"; }; /** RadarListDeletedListItem */ "deleted_radar.value_list_item": { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "radar.value_list_item"; }; /** DeletedTransferRecipient */ deleted_recipient: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "recipient"; }; /** DeletedSKU */ deleted_sku: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "sku"; }; /** DeletedSubscriptionItem */ deleted_subscription_item: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "subscription_item"; }; /** deleted_tax_id */ deleted_tax_id: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "tax_id"; }; /** TerminalLocationDeletedLocation */ "deleted_terminal.location": { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "terminal.location"; }; /** TerminalReaderDeletedReader */ "deleted_terminal.reader": { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "terminal.reader"; }; /** NotificationWebhookEndpointDeleted */ deleted_webhook_endpoint: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "webhook_endpoint"; }; /** DeliveryEstimate */ @@ -3089,7 +3402,10 @@ export interface definitions { customer?: string; /** @description If the coupon has a duration of `repeating`, the date that this discount will end. If the coupon has a duration of `once` or `forever`, this attribute will be null. */ end?: number; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "discount"; /** @description Date that the coupon was applied. */ start: number; @@ -3127,13 +3443,19 @@ export interface definitions { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "dispute"; /** @description ID of the PaymentIntent that was disputed. */ payment_intent?: string; /** @description Reason given by cardholder for dispute. Possible values are `bank_cannot_process`, `check_returned`, `credit_not_processed`, `customer_initiated`, `debit_not_authorized`, `duplicate`, `fraudulent`, `general`, `incorrect_account_details`, `insufficient_funds`, `product_not_received`, `product_unacceptable`, `subscription_canceled`, or `unrecognized`. Read more about [dispute reasons](https://stripe.com/docs/disputes/categories). */ reason: string; - /** @description Current status of dispute. Possible values are `warning_needs_response`, `warning_under_review`, `warning_closed`, `needs_response`, `under_review`, `charge_refunded`, `won`, or `lost`. */ + /** + * @description Current status of dispute. Possible values are `warning_needs_response`, `warning_under_review`, `warning_closed`, `needs_response`, `under_review`, `charge_refunded`, `won`, or `lost`. + * @enum {string} + */ status: | "charge_refunded" | "lost" @@ -3222,7 +3544,10 @@ export interface definitions { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "ephemeral_key"; /** @description The key's secret. You can use this value to make authorized requests to the Stripe API. */ secret?: string; @@ -3275,7 +3600,10 @@ export interface definitions { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "event"; /** @description Number of webhooks that have yet to be successfully delivered (i.e., to return a 20x response) to the URLs you've specified. */ pending_webhooks: number; @@ -3300,7 +3628,10 @@ export interface definitions { exchange_rate: { /** @description Unique identifier for the object. Represented as the three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) in lowercase. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "exchange_rate"; /** @description Hash where the keys are supported currencies and the values are the exchange rate at which the base id currency converts to the key currency. */ rates: { [key: string]: unknown }; @@ -3325,7 +3656,10 @@ export interface definitions { last4: string; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata?: { [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "bank_account"; }; /** Fee */ @@ -3364,7 +3698,10 @@ export interface definitions { id: string; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "fee_refund"; }; /** @@ -3393,12 +3730,18 @@ export interface definitions { data: definitions["file_link"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "file"; /** @description The purpose of the file. Possible values are `additional_verification`, `business_icon`, `business_logo`, `customer_signature`, `dispute_evidence`, `finance_report_run`, `identity_document`, `pci_document`, `sigma_scheduled_query`, or `tax_document_user_upload`. */ purpose: string; @@ -3432,7 +3775,10 @@ export interface definitions { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "file_link"; /** @description The publicly accessible URL to download the file. */ url?: string; @@ -3519,7 +3865,10 @@ export interface definitions { attempted: boolean; /** @description Controls whether Stripe will perform [automatic collection](https://stripe.com/docs/billing/invoices/workflow/#auto_advance) of the invoice. When `false`, the invoice's state will not automatically advance without an explicit action. */ auto_advance?: boolean; - /** @description Indicates the reason why the invoice was created. `subscription_cycle` indicates an invoice created by a subscription advancing into a new period. `subscription_create` indicates an invoice created due to creating a subscription. `subscription_update` indicates an invoice created due to updating a subscription. `subscription` is set for all old invoices to indicate either a change to a subscription or a period advancement. `manual` is set for all invoices unrelated to a subscription (for example: created via the invoice editor). The `upcoming` value is reserved for simulated invoices per the upcoming invoice endpoint. `subscription_threshold` indicates an invoice created due to a billing threshold being reached. */ + /** + * @description Indicates the reason why the invoice was created. `subscription_cycle` indicates an invoice created by a subscription advancing into a new period. `subscription_create` indicates an invoice created due to creating a subscription. `subscription_update` indicates an invoice created due to updating a subscription. `subscription` is set for all old invoices to indicate either a change to a subscription or a period advancement. `manual` is set for all invoices unrelated to a subscription (for example: created via the invoice editor). The `upcoming` value is reserved for simulated invoices per the upcoming invoice endpoint. `subscription_threshold` indicates an invoice created due to a billing threshold being reached. + * @enum {string} + */ billing_reason?: | "automatic_pending_invoice_item_invoice" | "manual" @@ -3531,7 +3880,10 @@ export interface definitions { | "upcoming"; /** @description ID of the latest charge generated for this invoice, if any. */ charge?: string; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this invoice using the default source attached to the customer. When sending an invoice, Stripe will email this invoice to the customer with payment instructions. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this invoice using the default source attached to the customer. When sending an invoice, Stripe will email this invoice to the customer with payment instructions. + * @enum {string} + */ collection_method?: "charge_automatically" | "send_invoice"; /** @description Time at which the object was created. Measured in seconds since the Unix epoch. */ created: number; @@ -3549,7 +3901,10 @@ export interface definitions { /** @description The customer's phone number. Until the invoice is finalized, this field will equal `customer.phone`. Once the invoice is finalized, this field will no longer be updated. */ customer_phone?: string; customer_shipping?: definitions["shipping"]; - /** @description The customer's tax exempt status. Until the invoice is finalized, this field will equal `customer.tax_exempt`. Once the invoice is finalized, this field will no longer be updated. */ + /** + * @description The customer's tax exempt status. Until the invoice is finalized, this field will equal `customer.tax_exempt`. Once the invoice is finalized, this field will no longer be updated. + * @enum {string} + */ customer_tax_exempt?: "exempt" | "none" | "reverse"; /** @description The customer's tax IDs. Until the invoice is finalized, this field will contain the same tax IDs as `customer.tax_ids`. Once the invoice is finalized, this field will no longer be updated. */ customer_tax_ids?: definitions["invoices_resource_invoice_tax_id"][]; @@ -3583,7 +3938,10 @@ export interface definitions { data: definitions["line_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -3596,7 +3954,10 @@ export interface definitions { next_payment_attempt?: number; /** @description A unique, identifying string that appears on emails sent to the customer for this invoice. This starts with the customer's unique invoice_prefix if it is specified. */ number?: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "invoice"; /** @description Whether payment was successfully collected for this invoice. An invoice can be paid (most commonly) with a charge or with credit from the customer's account balance. */ paid: boolean; @@ -3616,7 +3977,10 @@ export interface definitions { starting_balance: number; /** @description Extra information about an invoice for the customer's credit card statement. */ statement_descriptor?: string; - /** @description The status of the invoice, one of `draft`, `open`, `paid`, `uncollectible`, or `void`. [Learn more](https://stripe.com/docs/billing/invoices/workflow#workflow-overview) */ + /** + * @description The status of the invoice, one of `draft`, `open`, `paid`, `uncollectible`, or `void`. [Learn more](https://stripe.com/docs/billing/invoices/workflow#workflow-overview) + * @enum {string} + */ status?: "deleted" | "draft" | "open" | "paid" | "uncollectible" | "void"; status_transitions: definitions["invoices_status_transitions"]; /** @description The subscription that this invoice was prepared for, if any. */ @@ -3719,7 +4083,10 @@ export interface definitions { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "invoiceitem"; period: definitions["invoice_line_item_period"]; plan?: definitions["plan"]; @@ -3740,7 +4107,10 @@ export interface definitions { }; /** InvoicesResourceInvoiceTaxID */ invoices_resource_invoice_tax_id: { - /** @description The type of the tax ID, one of `eu_vat`, `nz_gst`, `au_abn`, `in_gst`, `no_vat`, `za_vat`, `ch_vat`, `mx_rfc`, `sg_uen`, `ru_inn`, `ca_bn`, `hk_br`, `es_cif`, `tw_vat`, `th_vat`, `jp_cn`, `li_uid`, `my_itn`, `us_ein`, `kr_brn`, `ca_qst`, `my_sst`, `sg_gst`, or `unknown` */ + /** + * @description The type of the tax ID, one of `eu_vat`, `nz_gst`, `au_abn`, `in_gst`, `no_vat`, `za_vat`, `ch_vat`, `mx_rfc`, `sg_uen`, `ru_inn`, `ca_bn`, `hk_br`, `es_cif`, `tw_vat`, `th_vat`, `jp_cn`, `li_uid`, `my_itn`, `us_ein`, `kr_brn`, `ca_qst`, `my_sst`, `sg_gst`, or `unknown` + * @enum {string} + */ type: | "au_abn" | "ca_bn" @@ -3801,7 +4171,10 @@ export interface definitions { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "issuer_fraud_record"; /** @description The timestamp at which the card issuer posted the issuer fraud record. */ post_date: number; @@ -3819,7 +4192,10 @@ export interface definitions { amount: number; /** @description Whether the authorization has been approved. */ approved: boolean; - /** @description How the card details were provided. */ + /** + * @description How the card details were provided. + * @enum {string} + */ authorization_method: "chip" | "contactless" | "keyed_in" | "online" | "swipe"; /** @description List of balance transactions associated with this authorization. */ balance_transactions: definitions["balance_transaction"][]; @@ -3841,12 +4217,18 @@ export interface definitions { merchant_data: definitions["issuing_authorization_merchant_data"]; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "issuing.authorization"; pending_request?: definitions["issuing_authorization_pending_request"]; /** @description History of every time the authorization was approved/denied (whether approved/denied by you directly or by Stripe based on your `spending_controls`). If the merchant changes the authorization by performing an [incremental authorization or partial capture](https://stripe.com/docs/issuing/purchases/authorizations), you can look at this field to see the previous states of the authorization. */ request_history: definitions["issuing_authorization_request"][]; - /** @description The current status of the authorization in its lifecycle. */ + /** + * @description The current status of the authorization in its lifecycle. + * @enum {string} + */ status: "closed" | "pending" | "reversed"; /** @description List of [transactions](https://stripe.com/docs/api/issuing/transactions) associated with this authorization. */ transactions: definitions["issuing.transaction"][]; @@ -3861,7 +4243,10 @@ export interface definitions { "issuing.card": { /** @description The brand of the card. */ brand: string; - /** @description The reason why the card was canceled. */ + /** + * @description The reason why the card was canceled. + * @enum {string} + */ cancellation_reason?: "lost" | "stolen"; cardholder: definitions["issuing.cardholder"]; /** @description Time at which the object was created. Measured in seconds since the Unix epoch. */ @@ -3884,19 +4269,31 @@ export interface definitions { metadata: { [key: string]: unknown }; /** @description The full unredacted card number. For security reasons, this is only available for virtual cards, and will be omitted unless you explicitly request it with [the `expand` parameter](https://stripe.com/docs/api/expanding_objects). Additionally, it's only available via the ["Retrieve a card" endpoint](https://stripe.com/docs/api/issuing/cards/retrieve), not via "List all cards" or any other endpoint. */ number?: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "issuing.card"; /** @description The latest card that replaces this card, if any. */ replaced_by?: string; /** @description The card this card replaces, if any. */ replacement_for?: string; - /** @description The reason why the previous card needed to be replaced. */ + /** + * @description The reason why the previous card needed to be replaced. + * @enum {string} + */ replacement_reason?: "damaged" | "expired" | "lost" | "stolen"; shipping?: definitions["issuing_card_shipping"]; spending_controls: definitions["issuing_card_authorization_controls"]; - /** @description Whether authorizations can be approved on this card. */ + /** + * @description Whether authorizations can be approved on this card. + * @enum {string} + */ status: "active" | "canceled" | "inactive"; - /** @description The type of the card. */ + /** + * @description The type of the card. + * @enum {string} + */ type: "physical" | "virtual"; }; /** @@ -3921,15 +4318,24 @@ export interface definitions { metadata: { [key: string]: unknown }; /** @description The cardholder's name. This will be printed on cards issued to them. */ name: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "issuing.cardholder"; /** @description The cardholder's phone number. */ phone_number?: string; requirements: definitions["issuing_cardholder_requirements"]; spending_controls?: definitions["issuing_cardholder_authorization_controls"]; - /** @description Specifies whether to permit authorizations on this cardholder's cards. */ + /** + * @description Specifies whether to permit authorizations on this cardholder's cards. + * @enum {string} + */ status: "active" | "blocked" | "inactive"; - /** @description One of `individual` or `company`. */ + /** + * @description One of `individual` or `company`. + * @enum {string} + */ type: "company" | "individual"; }; /** @@ -3943,7 +4349,10 @@ export interface definitions { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "issuing.dispute"; }; /** @@ -3969,13 +4378,19 @@ export interface definitions { metadata: { [key: string]: unknown }; /** @description The total net amount required to settle with the network. */ net_total: number; - /** @description The card network for this settlement report. One of ["visa"] */ + /** + * @description The card network for this settlement report. One of ["visa"] + * @enum {string} + */ network: "visa"; /** @description The total amount of fees owed to the network. */ network_fees: number; /** @description The Settlement Identification Number assigned by the network. */ network_settlement_identifier: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "issuing.settlement"; /** @description One of `international` or `uk_national_net`. */ settlement_service: string; @@ -4018,9 +4433,15 @@ export interface definitions { merchant_data: definitions["issuing_authorization_merchant_data"]; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "issuing.transaction"; - /** @description The nature of the transaction. */ + /** + * @description The nature of the transaction. + * @enum {string} + */ type: "capture" | "refund"; }; /** IssuingAuthorizationMerchantData */ @@ -4067,7 +4488,10 @@ export interface definitions { merchant_amount: number; /** @description The currency that was collected by the merchant and presented to the cardholder for the authorization. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). */ merchant_currency: string; - /** @description The reason for the approval or decline. */ + /** + * @description The reason for the approval or decline. + * @enum {string} + */ reason: | "account_disabled" | "card_active" @@ -4085,13 +4509,25 @@ export interface definitions { }; /** IssuingAuthorizationVerificationData */ issuing_authorization_verification_data: { - /** @description Whether the cardholder provided an address first line and if it matched the cardholder’s `billing.address.line1`. */ + /** + * @description Whether the cardholder provided an address first line and if it matched the cardholder’s `billing.address.line1`. + * @enum {string} + */ address_line1_check: "match" | "mismatch" | "not_provided"; - /** @description Whether the cardholder provided a postal code and if it matched the cardholder’s `billing.address.postal_code`. */ + /** + * @description Whether the cardholder provided a postal code and if it matched the cardholder’s `billing.address.postal_code`. + * @enum {string} + */ address_postal_code_check: "match" | "mismatch" | "not_provided"; - /** @description Whether the cardholder provided a CVC and if it matched Stripe’s record. */ + /** + * @description Whether the cardholder provided a CVC and if it matched Stripe’s record. + * @enum {string} + */ cvc_check: "match" | "mismatch" | "not_provided"; - /** @description Whether the cardholder provided an expiry date and if it matched Stripe’s record. */ + /** + * @description Whether the cardholder provided an expiry date and if it matched Stripe’s record. + * @enum {string} + */ expiry_check: "match" | "mismatch" | "not_provided"; }; /** IssuingCardAuthorizationControls */ @@ -4686,21 +5122,33 @@ export interface definitions { /** IssuingCardShipping */ issuing_card_shipping: { address: definitions["address"]; - /** @description The delivery company that shipped a card. */ + /** + * @description The delivery company that shipped a card. + * @enum {string} + */ carrier?: "fedex" | "usps"; /** @description A unix timestamp representing a best estimate of when the card will be delivered. */ eta?: number; /** @description Recipient name. */ name: string; - /** @description Shipment service, such as `standard` or `express`. */ + /** + * @description Shipment service, such as `standard` or `express`. + * @enum {string} + */ service: "express" | "priority" | "standard"; - /** @description The delivery status of the card. */ + /** + * @description The delivery status of the card. + * @enum {string} + */ status?: "canceled" | "delivered" | "failure" | "pending" | "returned" | "shipped"; /** @description A tracking number for a card shipment. */ tracking_number?: string; /** @description A link to the shipping carrier's site where you can view detailed information about a card shipment. */ tracking_url?: string; - /** @description Packaging options. */ + /** + * @description Packaging options. + * @enum {string} + */ type: "bulk" | "individual"; }; /** IssuingCardSpendingLimit */ @@ -4998,7 +5446,10 @@ export interface definitions { | "womens_ready_to_wear_stores" | "wrecking_and_salvage_yards" )[]; - /** @description The time interval or event with which to apply this spending limit towards. */ + /** + * @description The time interval or event with which to apply this spending limit towards. + * @enum {string} + */ interval: "all_time" | "daily" | "monthly" | "per_authorization" | "weekly" | "yearly"; }; /** IssuingCardholderAddress */ @@ -5626,7 +6077,10 @@ export interface definitions { }; /** IssuingCardholderRequirements */ issuing_cardholder_requirements: { - /** @description If `disabled_reason` is present, all cards will decline authorizations with `cardholder_verification_required` reason. */ + /** + * @description If `disabled_reason` is present, all cards will decline authorizations with `cardholder_verification_required` reason. + * @enum {string} + */ disabled_reason?: "listed" | "rejected.listed" | "under_review"; /** @description Array of fields that need to be collected in order to verify and re-enable the cardholder. */ past_due?: ( @@ -5934,7 +6388,10 @@ export interface definitions { | "womens_ready_to_wear_stores" | "wrecking_and_salvage_yards" )[]; - /** @description The time interval or event with which to apply this spending limit towards. */ + /** + * @description The time interval or event with which to apply this spending limit towards. + * @enum {string} + */ interval: "all_time" | "daily" | "monthly" | "per_authorization" | "weekly" | "yearly"; }; /** IssuingCardholderVerification */ @@ -5960,7 +6417,10 @@ export interface definitions { owners_provided?: boolean; /** @description The company's phone number (used for verification). */ phone?: string; - /** @description The category identifying the legal structure of the company or legal entity. See [Business structure](https://stripe.com/docs/connect/identity-verification#business-structure) for more details. */ + /** + * @description The category identifying the legal structure of the company or legal entity. See [Business structure](https://stripe.com/docs/connect/identity-verification#business-structure) for more details. + * @enum {string} + */ structure?: | "government_instrumentality" | "governmental_unit" @@ -6068,7 +6528,10 @@ export interface definitions { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Note that for line items with `type=subscription` this will reflect the metadata of the subscription that caused the line item to be created. */ metadata: { [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "line_item"; period: definitions["invoice_line_item_period"]; plan?: definitions["plan"]; @@ -6084,14 +6547,20 @@ export interface definitions { tax_amounts?: definitions["invoice_tax_amount"][]; /** @description The tax rates which apply to the line item. */ tax_rates?: definitions["tax_rate"][]; - /** @description A string identifying the type of the source of this line item, either an `invoiceitem` or a `subscription`. */ + /** + * @description A string identifying the type of the source of this line item, either an `invoiceitem` or a `subscription`. + * @enum {string} + */ type: "invoiceitem" | "subscription"; }; /** LoginLink */ login_link: { /** @description Time at which the object was created. Measured in seconds since the Unix epoch. */ created: number; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "login_link"; /** @description The URL for the login link. */ url: string; @@ -6107,15 +6576,24 @@ export interface definitions { /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; multi_use?: definitions["mandate_multi_use"]; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "mandate"; /** @description ID of the payment method associated with this mandate. */ payment_method: string; payment_method_details: definitions["mandate_payment_method_details"]; single_use?: definitions["mandate_single_use"]; - /** @description The status of the mandate, which indicates whether it can be used to initiate a payment. */ + /** + * @description The status of the mandate, which indicates whether it can be used to initiate a payment. + * @enum {string} + */ status: "active" | "inactive" | "pending"; - /** @description The type of the mandate. */ + /** + * @description The type of the mandate. + * @enum {string} + */ type: "multi_use" | "single_use"; }; /** mandate_au_becs_debit */ @@ -6207,7 +6685,10 @@ export interface definitions { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "order"; /** * OrderReturnList @@ -6218,7 +6699,10 @@ export interface definitions { data: definitions["order_return"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -6250,7 +6734,10 @@ export interface definitions { currency: string; /** @description Description of the line item, meant to be displayable to the user (e.g., `"Express shipping"`). */ description: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "order_item"; /** @description The ID of the associated object for this line item. Expandable if not null (e.g., expandable to a SKU). */ parent?: string; @@ -6279,7 +6766,10 @@ export interface definitions { items: definitions["order_item"][]; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "order_return"; /** @description The order that this return includes items from. */ order?: string; @@ -6324,7 +6814,10 @@ export interface definitions { application_fee_amount?: number; /** @description Populated when `status` is `canceled`, this is the time at which the PaymentIntent was canceled. Measured in seconds since the Unix epoch. */ canceled_at?: number; - /** @description Reason for cancellation of this PaymentIntent, either user-provided (`duplicate`, `fraudulent`, `requested_by_customer`, or `abandoned`) or generated by Stripe internally (`failed_invoice`, `void_invoice`, or `automatic`). */ + /** + * @description Reason for cancellation of this PaymentIntent, either user-provided (`duplicate`, `fraudulent`, `requested_by_customer`, or `abandoned`) or generated by Stripe internally (`failed_invoice`, `void_invoice`, or `automatic`). + * @enum {string} + */ cancellation_reason?: | "abandoned" | "automatic" @@ -6333,7 +6826,10 @@ export interface definitions { | "fraudulent" | "requested_by_customer" | "void_invoice"; - /** @description Controls when the funds will be captured from the customer's account. */ + /** + * @description Controls when the funds will be captured from the customer's account. + * @enum {string} + */ capture_method: "automatic" | "manual"; /** * PaymentFlowsPaymentIntentResourceChargeList @@ -6344,7 +6840,10 @@ export interface definitions { data: definitions["charge"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -6357,6 +6856,7 @@ export interface definitions { * Refer to our docs to [accept a payment](https://stripe.com/docs/payments/accept-a-payment) and learn about how `client_secret` should be handled. */ client_secret?: string; + /** @enum {string} */ confirmation_method: "automatic" | "manual"; /** @description Time at which the object was created. Measured in seconds since the Unix epoch. */ created: number; @@ -6382,7 +6882,10 @@ export interface definitions { /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. For more information, see the [documentation](https://stripe.com/docs/payments/payment-intents/creating-payment-intents#storing-information-in-metadata). */ metadata?: { [key: string]: unknown }; next_action?: definitions["payment_intent_next_action"]; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "payment_intent"; /** @description The account (if any) for which the funds of the PaymentIntent are intended. See the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts) for details. */ on_behalf_of?: string; @@ -6401,6 +6904,7 @@ export interface definitions { * Providing this parameter will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any required actions from the user are complete. If no Customer was provided, the payment method can still be [attached](https://stripe.com/docs/api/payment_methods/attach) to a Customer after the transaction completes. * * When processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication). + * @enum {string} */ setup_future_usage?: "off_session" | "on_session"; shipping?: definitions["shipping"]; @@ -6408,7 +6912,10 @@ export interface definitions { statement_descriptor?: string; /** @description Provides information about a card payment that customers see on their statements. Concatenated with the prefix (shortened descriptor) or statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 22 characters for the concatenated descriptor. */ statement_descriptor_suffix?: string; - /** @description Status of this PaymentIntent, one of `requires_payment_method`, `requires_confirmation`, `requires_action`, `processing`, `requires_capture`, `canceled`, or `succeeded`. Read more about each PaymentIntent [status](https://stripe.com/docs/payments/intents#intent-statuses). */ + /** + * @description Status of this PaymentIntent, one of `requires_payment_method`, `requires_confirmation`, `requires_action`, `processing`, `requires_capture`, `canceled`, or `succeeded`. Read more about each PaymentIntent [status](https://stripe.com/docs/payments/intents#intent-statuses). + * @enum {string} + */ status: | "canceled" | "processing" @@ -6443,7 +6950,10 @@ export interface definitions { /** payment_intent_payment_method_options_card */ payment_intent_payment_method_options_card: { installments?: definitions["payment_method_options_card_installments"]; - /** @description We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Permitted values include: `automatic` or `any`. If not provided, defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine. */ + /** + * @description We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Permitted values include: `automatic` or `any`. If not provided, defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine. + * @enum {string} + */ request_three_d_secure?: "any" | "automatic" | "challenge_only"; }; /** @@ -6471,10 +6981,16 @@ export interface definitions { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "payment_method"; sepa_debit?: definitions["payment_method_sepa_debit"]; - /** @description The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type. */ + /** + * @description The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type. + * @enum {string} + */ type: "au_becs_debit" | "card" | "fpx" | "ideal" | "sepa_debit"; }; /** payment_method_au_becs_debit */ @@ -6533,7 +7049,10 @@ export interface definitions { google_pay?: definitions["payment_method_card_wallet_google_pay"]; masterpass?: definitions["payment_method_card_wallet_masterpass"]; samsung_pay?: definitions["payment_method_card_wallet_samsung_pay"]; - /** @description The type of the card wallet, one of `amex_express_checkout`, `apple_pay`, `google_pay`, `masterpass`, `samsung_pay`, or `visa_checkout`. An additional hash is included on the Wallet subhash with a name matching this value. It contains additional information specific to the card wallet type. */ + /** + * @description The type of the card wallet, one of `amex_express_checkout`, `apple_pay`, `google_pay`, `masterpass`, `samsung_pay`, or `visa_checkout`. An additional hash is included on the Wallet subhash with a name matching this value. It contains additional information specific to the card wallet type. + * @enum {string} + */ type: "amex_express_checkout" | "apple_pay" | "google_pay" | "masterpass" | "samsung_pay" | "visa_checkout"; visa_checkout?: definitions["payment_method_card_wallet_visa_checkout"]; }; @@ -6603,7 +7122,10 @@ export interface definitions { }; /** payment_method_details_ach_debit */ payment_method_details_ach_debit: { - /** @description Type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description Type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string} + */ account_holder_type?: "company" | "individual"; /** @description Name of the bank associated with the bank account. */ bank_name?: string; @@ -6642,6 +7164,7 @@ export interface definitions { /** * @description Preferred language of the Bancontact authorization page that the customer is redirected to. * Can be one of `en`, `de`, `fr`, or `nl` + * @enum {string} */ preferred_language?: "de" | "en" | "fr" | "nl"; /** @@ -6693,9 +7216,13 @@ export interface definitions { /** * @description For `fixed_count` installment plans, this is the interval between installment payments your customer will make to their credit card. * One of `month`. + * @enum {string} */ interval?: "month"; - /** @description Type of installment plan, one of `fixed_count`. */ + /** + * @description Type of installment plan, one of `fixed_count`. + * @enum {string} + */ type: "fixed_count"; }; /** payment_method_details_card_present */ @@ -6754,7 +7281,10 @@ export interface definitions { google_pay?: definitions["payment_method_details_card_wallet_google_pay"]; masterpass?: definitions["payment_method_details_card_wallet_masterpass"]; samsung_pay?: definitions["payment_method_details_card_wallet_samsung_pay"]; - /** @description The type of the card wallet, one of `amex_express_checkout`, `apple_pay`, `google_pay`, `masterpass`, `samsung_pay`, or `visa_checkout`. An additional hash is included on the Wallet subhash with a name matching this value. It contains additional information specific to the card wallet type. */ + /** + * @description The type of the card wallet, one of `amex_express_checkout`, `apple_pay`, `google_pay`, `masterpass`, `samsung_pay`, or `visa_checkout`. An additional hash is included on the Wallet subhash with a name matching this value. It contains additional information specific to the card wallet type. + * @enum {string} + */ type: "amex_express_checkout" | "apple_pay" | "google_pay" | "masterpass" | "samsung_pay" | "visa_checkout"; visa_checkout?: definitions["payment_method_details_card_wallet_visa_checkout"]; }; @@ -6794,7 +7324,10 @@ export interface definitions { }; /** payment_method_details_fpx */ payment_method_details_fpx: { - /** @description The customer's bank. Can be one of `affin_bank`, `alliance_bank`, `ambank`, `bank_islam`, `bank_muamalat`, `bank_rakyat`, `bsn`, `cimb`, `hong_leong_bank`, `hsbc`, `kfh`, `maybank2u`, `ocbc`, `public_bank`, `rhb`, `standard_chartered`, `uob`, `deutsche_bank`, `maybank2e`, or `pb_enterprise`. */ + /** + * @description The customer's bank. Can be one of `affin_bank`, `alliance_bank`, `ambank`, `bank_islam`, `bank_muamalat`, `bank_rakyat`, `bsn`, `cimb`, `hong_leong_bank`, `hsbc`, `kfh`, `maybank2u`, `ocbc`, `public_bank`, `rhb`, `standard_chartered`, `uob`, `deutsche_bank`, `maybank2e`, or `pb_enterprise`. + * @enum {string} + */ bank: | "affin_bank" | "alliance_bank" @@ -6835,7 +7368,10 @@ export interface definitions { }; /** payment_method_details_ideal */ payment_method_details_ideal: { - /** @description The customer's bank. Can be one of `abn_amro`, `asn_bank`, `bunq`, `handelsbanken`, `ing`, `knab`, `moneyou`, `rabobank`, `regiobank`, `sns_bank`, `triodos_bank`, or `van_lanschot`. */ + /** + * @description The customer's bank. Can be one of `abn_amro`, `asn_bank`, `bunq`, `handelsbanken`, `ing`, `knab`, `moneyou`, `rabobank`, `regiobank`, `sns_bank`, `triodos_bank`, or `van_lanschot`. + * @enum {string} + */ bank?: | "abn_amro" | "asn_bank" @@ -6849,7 +7385,10 @@ export interface definitions { | "sns_bank" | "triodos_bank" | "van_lanschot"; - /** @description The Bank Identifier Code of the customer's bank. */ + /** + * @description The Bank Identifier Code of the customer's bank. + * @enum {string} + */ bic?: | "ABNANL2A" | "ASNBNL21" @@ -6929,7 +7468,10 @@ export interface definitions { payment_method_details_wechat: { [key: string]: unknown }; /** payment_method_fpx */ payment_method_fpx: { - /** @description The customer's bank, if provided. Can be one of `affin_bank`, `alliance_bank`, `ambank`, `bank_islam`, `bank_muamalat`, `bank_rakyat`, `bsn`, `cimb`, `hong_leong_bank`, `hsbc`, `kfh`, `maybank2u`, `ocbc`, `public_bank`, `rhb`, `standard_chartered`, `uob`, `deutsche_bank`, `maybank2e`, or `pb_enterprise`. */ + /** + * @description The customer's bank, if provided. Can be one of `affin_bank`, `alliance_bank`, `ambank`, `bank_islam`, `bank_muamalat`, `bank_rakyat`, `bsn`, `cimb`, `hong_leong_bank`, `hsbc`, `kfh`, `maybank2u`, `ocbc`, `public_bank`, `rhb`, `standard_chartered`, `uob`, `deutsche_bank`, `maybank2e`, or `pb_enterprise`. + * @enum {string} + */ bank: | "affin_bank" | "alliance_bank" @@ -6954,7 +7496,10 @@ export interface definitions { }; /** payment_method_ideal */ payment_method_ideal: { - /** @description The customer's bank, if provided. Can be one of `abn_amro`, `asn_bank`, `bunq`, `handelsbanken`, `ing`, `knab`, `moneyou`, `rabobank`, `regiobank`, `sns_bank`, `triodos_bank`, or `van_lanschot`. */ + /** + * @description The customer's bank, if provided. Can be one of `abn_amro`, `asn_bank`, `bunq`, `handelsbanken`, `ing`, `knab`, `moneyou`, `rabobank`, `regiobank`, `sns_bank`, `triodos_bank`, or `van_lanschot`. + * @enum {string} + */ bank?: | "abn_amro" | "asn_bank" @@ -6968,7 +7513,10 @@ export interface definitions { | "sns_bank" | "triodos_bank" | "van_lanschot"; - /** @description The Bank Identifier Code of the customer's bank, if the bank was provided. */ + /** + * @description The Bank Identifier Code of the customer's bank, if the bank was provided. + * @enum {string} + */ bic?: | "ABNANL2A" | "ASNBNL21" @@ -7256,7 +7804,10 @@ export interface definitions { id: string; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata?: { [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "account"; }; /** @@ -7301,7 +7852,10 @@ export interface definitions { metadata: { [key: string]: unknown }; /** @description The method used to send this payout, which can be `standard` or `instant`. `instant` is only supported for payouts to debit cards. (See [Instant payouts for marketplaces](https://stripe.com/blog/instant-payouts-for-marketplaces) for more information.) */ method: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "payout"; /** @description The source balance this payout came from. One of `card`, `fpx`, or `bank_account`. */ source_type: string; @@ -7309,7 +7863,10 @@ export interface definitions { statement_descriptor?: string; /** @description Current status of the payout: `paid`, `pending`, `in_transit`, `canceled` or `failed`. A payout is `pending` until it is submitted to the bank, when it becomes `in_transit`. The status then changes to `paid` if the transaction goes through, or to `failed` or `canceled` (within 5 business days). Some failed payouts may initially show as `paid` but then change to `failed`. */ status: string; - /** @description Can be `bank_account` or `card`. */ + /** + * @description Can be `bank_account` or `card`. + * @enum {string} + */ type: "bank_account" | "card"; }; /** Period */ @@ -7347,7 +7904,10 @@ export interface definitions { maiden_name?: string; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata?: { [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "person"; phone?: string; relationship?: definitions["person_relationship"]; @@ -7395,13 +7955,19 @@ export interface definitions { plan: { /** @description Whether the plan can be used for new purchases. */ active: boolean; - /** @description Specifies a usage aggregation strategy for plans of `usage_type=metered`. Allowed values are `sum` for summing up all usage during a period, `last_during_period` for using the last usage record reported within a period, `last_ever` for using the last usage record ever (across period bounds) or `max` which uses the usage record with the maximum reported usage during a period. Defaults to `sum`. */ + /** + * @description Specifies a usage aggregation strategy for plans of `usage_type=metered`. Allowed values are `sum` for summing up all usage during a period, `last_during_period` for using the last usage record reported within a period, `last_ever` for using the last usage record ever (across period bounds) or `max` which uses the usage record with the maximum reported usage during a period. Defaults to `sum`. + * @enum {string} + */ aggregate_usage?: "last_during_period" | "last_ever" | "max" | "sum"; /** @description The amount in %s to be charged on the interval specified. */ amount?: number; /** @description Same as `amount`, but contains a decimal value with at most 12 decimal places. */ amount_decimal?: string; - /** @description Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `amount`) will be charged per unit in `quantity` (for plans with `usage_type=licensed`), or per unit of total usage (for plans with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes. */ + /** + * @description Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `amount`) will be charged per unit in `quantity` (for plans with `usage_type=licensed`), or per unit of total usage (for plans with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes. + * @enum {string} + */ billing_scheme: "per_unit" | "tiered"; /** @description Time at which the object was created. Measured in seconds since the Unix epoch. */ created: number; @@ -7409,7 +7975,10 @@ export interface definitions { currency: string; /** @description Unique identifier for the object. */ id: string; - /** @description The frequency at which a subscription is billed. One of `day`, `week`, `month` or `year`. */ + /** + * @description The frequency at which a subscription is billed. One of `day`, `week`, `month` or `year`. + * @enum {string} + */ interval: "day" | "month" | "week" | "year"; /** @description The number of intervals (specified in the `interval` attribute) between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. */ interval_count: number; @@ -7419,18 +7988,27 @@ export interface definitions { metadata: { [key: string]: unknown }; /** @description A brief description of the plan, hidden from customers. */ nickname?: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "plan"; /** @description The product whose pricing this plan determines. */ product?: string; /** @description Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`. */ tiers?: definitions["plan_tier"][]; - /** @description Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price. In `graduated` tiering, pricing can change as the quantity grows. */ + /** + * @description Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price. In `graduated` tiering, pricing can change as the quantity grows. + * @enum {string} + */ tiers_mode?: "graduated" | "volume"; transform_usage?: definitions["transform_usage"]; /** @description Default number of trial days when subscribing a customer to this plan using [`trial_from_plan=true`](https://stripe.com/docs/api#create_subscription-trial_from_plan). */ trial_period_days?: number; - /** @description Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`. */ + /** + * @description Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`. + * @enum {string} + */ usage_type: "licensed" | "metered"; }; /** PlanTier */ @@ -7452,7 +8030,10 @@ export interface definitions { account: string; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "platform_tax_fee"; /** @description The payment object that caused this tax to be inflicted. */ source_transaction: string; @@ -7493,14 +8074,20 @@ export interface definitions { metadata: { [key: string]: unknown }; /** @description The product's name, meant to be displayable to the customer. Whenever this product is sold via a subscription, name will show up on associated invoice line item descriptions. */ name: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "product"; package_dimensions?: definitions["package_dimensions"]; /** @description Whether this product is a shipped good. Only applicable to products of `type=good`. */ shippable?: boolean; /** @description Extra information about a product which will appear on your customer's credit card statement. In the case that multiple products are billed at once, the first statement descriptor will be used. */ statement_descriptor?: string; - /** @description The type of the product. The product is either of type `good`, which is eligible for use with Orders and SKUs, or `service`, which is eligible for use with Subscriptions and Plans. */ + /** + * @description The type of the product. The product is either of type `good`, which is eligible for use with Orders and SKUs, or `service`, which is eligible for use with Subscriptions and Plans. + * @enum {string} + */ type: "good" | "service"; /** @description A label that represents units of this product in Stripe and on customers’ receipts and invoices. When set, this will be included in associated invoice line item descriptions. */ unit_label?: string; @@ -7529,7 +8116,10 @@ export interface definitions { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "radar.early_fraud_warning"; }; /** @@ -7547,7 +8137,10 @@ export interface definitions { created_by: string; /** @description Unique identifier for the object. */ id: string; - /** @description The type of items in the value list. One of `card_fingerprint`, `card_bin`, `email`, `ip_address`, `country`, `string`, or `case_sensitive_string`. */ + /** + * @description The type of items in the value list. One of `card_fingerprint`, `card_bin`, `email`, `ip_address`, `country`, `string`, or `case_sensitive_string`. + * @enum {string} + */ item_type: | "card_bin" | "card_fingerprint" @@ -7565,7 +8158,10 @@ export interface definitions { data: definitions["radar.value_list_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -7576,7 +8172,10 @@ export interface definitions { metadata: { [key: string]: unknown }; /** @description The name of the value list. */ name: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "radar.value_list"; }; /** @@ -7594,7 +8193,10 @@ export interface definitions { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "radar.value_list_item"; /** @description The value of the item. */ value: string; @@ -7646,7 +8248,10 @@ export interface definitions { data: definitions["card"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -7668,7 +8273,10 @@ export interface definitions { migrated_to?: string; /** @description Full, legal name of the recipient. */ name?: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "recipient"; rolled_back_from?: string; /** @description Type of the recipient, one of `individual` or `corporation`. */ @@ -7703,7 +8311,10 @@ export interface definitions { id: string; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "refund"; /** @description ID of the PaymentIntent that was refunded. */ payment_intent?: string; @@ -7742,7 +8353,10 @@ export interface definitions { id: string; /** @description Always `true`: reports can only be run on live-mode data. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "reporting.report_run"; parameters: definitions["financial_reporting_finance_report_run_run_parameters"]; /** @description The ID of the [report type](https://stripe.com/docs/reporting/statements/api#report-types) to run, such as `"balance.summary.1"`. */ @@ -7783,7 +8397,10 @@ export interface definitions { id: string; /** @description Human-readable name of the Report Type */ name: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "reporting.report_type"; /** @description When this Report Type was latest updated. Measured in seconds since the Unix epoch. */ updated: number; @@ -7799,7 +8416,10 @@ export interface definitions { description?: string; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "reserve_transaction"; }; /** @@ -7814,7 +8434,10 @@ export interface definitions { billing_zip?: string; /** @description The charge associated with this review. */ charge?: string; - /** @description The reason the review was closed, or null if it has not yet been closed. One of `approved`, `refunded`, `refunded_as_fraud`, or `disputed`. */ + /** + * @description The reason the review was closed, or null if it has not yet been closed. One of `approved`, `refunded`, `refunded_as_fraud`, or `disputed`. + * @enum {string} + */ closed_reason?: "approved" | "disputed" | "refunded" | "refunded_as_fraud"; /** @description Time at which the object was created. Measured in seconds since the Unix epoch. */ created: number; @@ -7825,11 +8448,17 @@ export interface definitions { ip_address_location?: definitions["radar_review_resource_location"]; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "review"; /** @description If `true`, the review needs action. */ open: boolean; - /** @description The reason the review was opened. One of `rule` or `manual`. */ + /** + * @description The reason the review was opened. One of `rule` or `manual`. + * @enum {string} + */ opened_reason: "manual" | "rule"; /** @description The PaymentIntent ID associated with this review, if one exists. */ payment_intent?: string; @@ -7864,7 +8493,10 @@ export interface definitions { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "scheduled_query_run"; /** @description Time at which the result expires and is no longer available for download. */ result_available_until: number; @@ -7903,7 +8535,10 @@ export interface definitions { setup_intent: { /** @description ID of the Connect application that created the SetupIntent. */ application?: string; - /** @description Reason for cancellation of this SetupIntent, one of `abandoned`, `requested_by_customer`, or `duplicate`. */ + /** + * @description Reason for cancellation of this SetupIntent, one of `abandoned`, `requested_by_customer`, or `duplicate`. + * @enum {string} + */ cancellation_reason?: "abandoned" | "duplicate" | "requested_by_customer"; /** * @description The client secret of this SetupIntent. Used for client-side retrieval using a publishable key. @@ -7931,7 +8566,10 @@ export interface definitions { /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata?: { [key: string]: unknown }; next_action?: definitions["setup_intent_next_action"]; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "setup_intent"; /** @description The account (if any) for which the setup is intended. */ on_behalf_of?: string; @@ -7942,7 +8580,10 @@ export interface definitions { payment_method_types: string[]; /** @description ID of the single_use Mandate generated by the SetupIntent. */ single_use_mandate?: string; - /** @description [Status](https://stripe.com/docs/payments/intents#intent-statuses) of this SetupIntent, one of `requires_payment_method`, `requires_confirmation`, `requires_action`, `processing`, `canceled`, or `succeeded`. */ + /** + * @description [Status](https://stripe.com/docs/payments/intents#intent-statuses) of this SetupIntent, one of `requires_payment_method`, `requires_confirmation`, `requires_action`, `processing`, `canceled`, or `succeeded`. + * @enum {string} + */ status: | "canceled" | "processing" @@ -7978,7 +8619,10 @@ export interface definitions { }; /** setup_intent_payment_method_options_card */ setup_intent_payment_method_options_card: { - /** @description We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Permitted values include: `automatic` or `any`. If not provided, defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine. */ + /** + * @description We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Permitted values include: `automatic` or `any`. If not provided, defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine. + * @enum {string} + */ request_three_d_secure?: "any" | "automatic" | "challenge_only"; }; /** Shipping */ @@ -8039,7 +8683,10 @@ export interface definitions { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "sku"; package_dimensions?: definitions["package_dimensions"]; /** @description The cost of the item as a positive integer in the smallest currency unit (that is, 100 cents to charge $1.00, or 100 to charge ¥100, Japanese Yen being a zero-decimal currency). */ @@ -8090,7 +8737,10 @@ export interface definitions { /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata?: { [key: string]: unknown }; multibanco?: definitions["source_type_multibanco"]; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "source"; owner?: definitions["source_owner"]; p24?: definitions["source_type_p24"]; @@ -8104,7 +8754,10 @@ export interface definitions { /** @description The status of the source, one of `canceled`, `chargeable`, `consumed`, `failed`, or `pending`. Only `chargeable` sources can be used to create a charge. */ status: string; three_d_secure?: definitions["source_type_three_d_secure"]; - /** @description The `type` of the source. The `type` is a payment method, one of `ach_credit_transfer`, `ach_debit`, `alipay`, `bancontact`, `card`, `card_present`, `eps`, `giropay`, `ideal`, `multibanco`, `klarna`, `p24`, `sepa_debit`, `sofort`, `three_d_secure`, or `wechat`. An additional hash is included on the source with a name matching this value. It contains additional information specific to the [payment method](https://stripe.com/docs/sources) used. */ + /** + * @description The `type` of the source. The `type` is a payment method, one of `ach_credit_transfer`, `ach_debit`, `alipay`, `bancontact`, `card`, `card_present`, `eps`, `giropay`, `ideal`, `multibanco`, `klarna`, `p24`, `sepa_debit`, `sofort`, `three_d_secure`, or `wechat`. An additional hash is included on the source with a name matching this value. It contains additional information specific to the [payment method](https://stripe.com/docs/sources) used. + * @enum {string} + */ type: | "ach_credit_transfer" | "ach_debit" @@ -8150,7 +8803,10 @@ export interface definitions { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "source_mandate_notification"; /** @description The reason of the mandate notification. Valid reasons are `mandate_confirmed` or `debit_initiated`. */ reason: string; @@ -8264,7 +8920,10 @@ export interface definitions { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "source_transaction"; paper_check?: definitions["source_transaction_paper_check_data"]; sepa_credit_transfer?: definitions["source_transaction_sepa_credit_transfer_data"]; @@ -8272,7 +8931,10 @@ export interface definitions { source: string; /** @description The status of the transaction, one of `succeeded`, `pending`, or `failed`. */ status: string; - /** @description The type of source this transaction is attached to. */ + /** + * @description The type of source this transaction is attached to. + * @enum {string} + */ type: | "ach_credit_transfer" | "ach_debit" @@ -8554,7 +9216,10 @@ export interface definitions { cancel_at_period_end: boolean; /** @description If the subscription has been canceled, the date of that cancellation. If the subscription was canceled with `cancel_at_period_end`, `canceled_at` will still reflect the date of the initial cancellation request, not the end of the subscription period when the subscription is automatically moved to a canceled state. */ canceled_at?: number; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. + * @enum {string} + */ collection_method?: "charge_automatically" | "send_invoice"; /** @description Time at which the object was created. Measured in seconds since the Unix epoch. */ created: number; @@ -8586,7 +9251,10 @@ export interface definitions { data: definitions["subscription_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -8599,7 +9267,10 @@ export interface definitions { metadata: { [key: string]: unknown }; /** @description Specifies the approximate timestamp on which any pending invoice items will be billed according to the schedule provided at `pending_invoice_item_interval`. */ next_pending_invoice_item_invoice?: number; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "subscription"; pause_collection?: definitions["subscriptions_resource_pause_collection"]; pending_invoice_item_interval?: definitions["subscription_pending_invoice_item_interval"]; @@ -8623,6 +9294,7 @@ export interface definitions { * If subscription `collection_method=charge_automatically` it becomes `past_due` when payment to renew it fails and `canceled` or `unpaid` (depending on your subscriptions settings) when Stripe has exhausted all payment retry attempts. * * If subscription `collection_method=send_invoice` it becomes `past_due` when its invoice is not paid by the due date, and `canceled` or `unpaid` if it is still not paid by an additional deadline after that. Note that when a subscription has a status of `unpaid`, no subsequent invoices will be attempted (invoices will be created, but then immediately automatically closed). After receiving updated payment information from a customer, you may choose to reopen and pay their closed invoices. + * @enum {string} */ status: "active" | "canceled" | "incomplete" | "incomplete_expired" | "past_due" | "trialing" | "unpaid"; /** @description If provided, each invoice created by this subscription will apply the tax rate, increasing the amount billed to the customer. */ @@ -8652,7 +9324,10 @@ export interface definitions { id: string; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "subscription_item"; plan: definitions["plan"]; /** @description The [quantity](https://stripe.com/docs/subscriptions/quantities) of the plan to which the customer should be subscribed. */ @@ -8669,7 +9344,10 @@ export interface definitions { }; /** SubscriptionPendingInvoiceItemInterval */ subscription_pending_invoice_item_interval: { - /** @description Specifies invoicing frequency. Either `day`, `week`, `month` or `year`. */ + /** + * @description Specifies invoicing frequency. Either `day`, `week`, `month` or `year`. + * @enum {string} + */ interval: "day" | "month" | "week" | "year"; /** @description The number of intervals between invoices. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). */ interval_count: number; @@ -8691,7 +9369,10 @@ export interface definitions { /** @description ID of the customer who owns the subscription schedule. */ customer: string; default_settings: definitions["subscription_schedules_resource_default_settings"]; - /** @description Behavior of the subscription schedule and underlying subscription when it ends. */ + /** + * @description Behavior of the subscription schedule and underlying subscription when it ends. + * @enum {string} + */ end_behavior: "cancel" | "none" | "release" | "renew"; /** @description Unique identifier for the object. */ id: string; @@ -8699,7 +9380,10 @@ export interface definitions { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata?: { [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "subscription_schedule"; /** @description Configuration for the subscription schedule's phases. */ phases: definitions["subscription_schedule_phase_configuration"][]; @@ -8707,7 +9391,10 @@ export interface definitions { released_at?: number; /** @description ID of the subscription once managed by the subscription schedule (if it is released). */ released_subscription?: string; - /** @description The present status of the subscription schedule. Possible values are `not_started`, `active`, `completed`, `released`, and `canceled`. You can read more about the different states in our [behavior guide](https://stripe.com/docs/billing/subscriptions/subscription-schedules). */ + /** + * @description The present status of the subscription schedule. Possible values are `not_started`, `active`, `completed`, `released`, and `canceled`. You can read more about the different states in our [behavior guide](https://stripe.com/docs/billing/subscriptions/subscription-schedules). + * @enum {string} + */ status: "active" | "canceled" | "completed" | "not_started" | "released"; /** @description ID of the subscription managed by the subscription schedule. */ subscription?: string; @@ -8740,7 +9427,10 @@ export interface definitions { /** @description A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice subtotal that will be transferred to the application owner's Stripe account during this phase of the schedule. */ application_fee_percent?: number; billing_thresholds?: definitions["subscription_billing_thresholds"]; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. + * @enum {string} + */ collection_method?: "charge_automatically" | "send_invoice"; /** @description ID of the coupon to use during this phase of the subscription schedule. */ coupon?: string; @@ -8753,7 +9443,10 @@ export interface definitions { invoice_settings?: definitions["invoice_setting_subscription_schedule_setting"]; /** @description Plans to subscribe during this phase of the subscription schedule. */ plans: definitions["subscription_schedule_configuration_item"][]; - /** @description Controls whether or not the subscription schedule will prorate when transitioning to this phase. Values are `create_prorations` and `none`. */ + /** + * @description Controls whether or not the subscription schedule will prorate when transitioning to this phase. Values are `create_prorations` and `none`. + * @enum {string} + */ proration_behavior?: "always_invoice" | "create_prorations" | "none"; /** @description The start of this phase of the subscription schedule. */ start_date: number; @@ -8765,7 +9458,10 @@ export interface definitions { /** SubscriptionSchedulesResourceDefaultSettings */ subscription_schedules_resource_default_settings: { billing_thresholds?: definitions["subscription_billing_thresholds"]; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. + * @enum {string} + */ collection_method?: "charge_automatically" | "send_invoice"; /** @description ID of the default payment method for the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings. */ default_payment_method?: string; @@ -8777,7 +9473,10 @@ export interface definitions { * should be paused. */ subscriptions_resource_pause_collection: { - /** @description The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`. */ + /** + * @description The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`. + * @enum {string} + */ behavior: "keep_as_draft" | "mark_uncollectible" | "void"; /** @description The time after which the subscription will resume collecting payments. */ resumes_at?: number; @@ -8803,7 +9502,10 @@ export interface definitions { tax_deducted_at_source: { /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "tax_deducted_at_source"; /** @description The end of the invoicing period. This TDS applies to Stripe fees collected during this invoicing period. */ period_end: number; @@ -8830,9 +9532,15 @@ export interface definitions { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "tax_id"; - /** @description Type of the tax ID, one of `au_abn`, `ca_bn`, `ca_qst`, `ch_vat`, `es_cif`, `eu_vat`, `hk_br`, `in_gst`, `jp_cn`, `kr_brn`, `li_uid`, `mx_rfc`, `my_itn`, `my_sst`, `no_vat`, `nz_gst`, `ru_inn`, `sg_gst`, `sg_uen`, `th_vat`, `tw_vat`, `us_ein`, or `za_vat`. Note that some legacy tax IDs have type `unknown` */ + /** + * @description Type of the tax ID, one of `au_abn`, `ca_bn`, `ca_qst`, `ch_vat`, `es_cif`, `eu_vat`, `hk_br`, `in_gst`, `jp_cn`, `kr_brn`, `li_uid`, `mx_rfc`, `my_itn`, `my_sst`, `no_vat`, `nz_gst`, `ru_inn`, `sg_gst`, `sg_uen`, `th_vat`, `tw_vat`, `us_ein`, or `za_vat`. Note that some legacy tax IDs have type `unknown` + * @enum {string} + */ type: | "au_abn" | "ca_bn" @@ -8864,7 +9572,10 @@ export interface definitions { }; /** tax_id_verification */ tax_id_verification: { - /** @description Verification status, one of `pending`, `verified`, `unverified`, or `unavailable`. */ + /** + * @description Verification status, one of `pending`, `verified`, `unverified`, or `unavailable`. + * @enum {string} + */ status: "pending" | "unavailable" | "unverified" | "verified"; /** @description Verified address. */ verified_address?: string; @@ -8896,7 +9607,10 @@ export interface definitions { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "tax_rate"; /** @description This represents the tax rate percent out of 100. */ percentage: number; @@ -8910,7 +9624,10 @@ export interface definitions { "terminal.connection_token": { /** @description The id of the location that this connection token is scoped to. */ location?: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "terminal.connection_token"; /** @description Your application should pass this token to the Stripe Terminal SDK. */ secret: string; @@ -8931,7 +9648,10 @@ export interface definitions { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "terminal.location"; }; /** @@ -8943,7 +9663,10 @@ export interface definitions { "terminal.reader": { /** @description The current software version of the reader. */ device_sw_version?: string; - /** @description Type of reader, one of `bbpos_chipper2x` or `verifone_P400`. */ + /** + * @description Type of reader, one of `bbpos_chipper2x` or `verifone_P400`. + * @enum {string} + */ device_type: "bbpos_chipper2x" | "verifone_P400"; /** @description Unique identifier for the object. */ id: string; @@ -8957,7 +9680,10 @@ export interface definitions { location?: string; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "terminal.reader"; /** @description Serial number of the reader. */ serial_number: string; @@ -8984,7 +9710,10 @@ export interface definitions { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "three_d_secure"; /** @description If present, this is the URL that you should send the cardholder to for authentication. If you are going to use Stripe.js to display the authentication page in an iframe, you should use the value "_callback". */ redirect_url?: string; @@ -9041,7 +9770,10 @@ export interface definitions { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "token"; /** @description Type of the token: `account`, `bank_account`, `card`, or `pii`. */ type: string; @@ -9079,12 +9811,18 @@ export interface definitions { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "topup"; source: definitions["source"]; /** @description Extra information about a top-up. This will appear on your source's bank statement. It must contain at least one letter. */ statement_descriptor?: string; - /** @description The status of the top-up is either `canceled`, `failed`, `pending`, `reversed`, or `succeeded`. */ + /** + * @description The status of the top-up is either `canceled`, `failed`, `pending`, `reversed`, or `succeeded`. + * @enum {string} + */ status: "canceled" | "failed" | "pending" | "reversed" | "succeeded"; /** @description A string that identifies this top-up as part of a group. */ transfer_group?: string; @@ -9125,7 +9863,10 @@ export interface definitions { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "transfer"; /** * TransferReversalList @@ -9136,7 +9877,10 @@ export interface definitions { data: definitions["transfer_reversal"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -9192,7 +9936,10 @@ export interface definitions { id: string; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "transfer_reversal"; /** @description ID of the refund responsible for the transfer reversal. */ source_refund?: string; @@ -9214,7 +9961,10 @@ export interface definitions { transform_usage: { /** @description Divide usage by this number. */ divide_by: number; - /** @description After division, either round the result `up` or `down`. */ + /** + * @description After division, either round the result `up` or `down`. + * @enum {string} + */ round: "down" | "up"; }; /** @@ -9229,7 +9979,10 @@ export interface definitions { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "usage_record"; /** @description The usage quantity for the specified date. */ quantity: number; @@ -9246,7 +9999,10 @@ export interface definitions { invoice?: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "usage_record_summary"; period: definitions["period"]; /** @description The ID of the subscription item this summary is describing. */ @@ -9281,7 +10037,10 @@ export interface definitions { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: unknown }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "webhook_endpoint"; /** @description The endpoint's secret, used to generate [webhook signatures](https://stripe.com/docs/webhooks/signatures). Only returned at creation. */ secret?: string; @@ -9393,7 +10152,10 @@ export interface operations { support_url?: string; url?: string; }; - /** @description The business type. */ + /** + * @description The business type. + * @enum {string} + */ business_type?: "company" | "government_entity" | "individual" | "non_profit"; /** * company_specs @@ -9436,6 +10198,7 @@ export interface operations { name_kanji?: string; owners_provided?: boolean; phone?: string; + /** @enum {string} */ structure?: | "" | "government_instrumentality" @@ -9580,8 +10343,10 @@ export interface operations { /** transfer_schedule_specs */ schedule?: { delay_days?: unknown; + /** @enum {string} */ interval?: "daily" | "manual" | "monthly" | "weekly"; monthly_anchor?: number; + /** @enum {string} */ weekly_anchor?: "friday" | "monday" | "saturday" | "sunday" | "thursday" | "tuesday" | "wednesday"; }; statement_descriptor?: string; @@ -9703,7 +10468,10 @@ export interface operations { payload?: { /** @description The name of the person or business that owns the bank account. */ account_holder_name?: string; - /** @description The type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description The type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string} + */ account_holder_type?: "" | "company" | "individual"; /** @description City/District/Suburb/Town/Village. */ address_city?: string; @@ -9776,7 +10544,10 @@ export interface operations { data: definitions["capability"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -9859,7 +10630,10 @@ export interface operations { data: definitions["bank_account"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -9937,7 +10711,10 @@ export interface operations { payload?: { /** @description The name of the person or business that owns the bank account. */ account_holder_name?: string; - /** @description The type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description The type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string} + */ account_holder_type?: "" | "company" | "individual"; /** @description City/District/Suburb/Town/Village. */ address_city?: string; @@ -10074,7 +10851,10 @@ export interface operations { data: definitions["person"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -10390,7 +11170,10 @@ export interface operations { data: definitions["person"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -10691,7 +11474,10 @@ export interface operations { payload: { /** @description The identifier of the account to create an account link for. */ account: string; - /** @description Which information the platform needs to collect from the user. One of `currently_due` or `eventually_due`. Default is `currently_due`. */ + /** + * @description Which information the platform needs to collect from the user. One of `currently_due` or `eventually_due`. Default is `currently_due`. + * @enum {string} + */ collect?: "currently_due" | "eventually_due"; /** @description Specifies which fields in the response should be expanded. */ expand?: string[]; @@ -10699,7 +11485,10 @@ export interface operations { failure_url: string; /** @description The URL that the user will be redirected to upon leaving or completing the linked flow successfully. */ success_url: string; - /** @description The type of account link the user is requesting. Possible values are `custom_account_verification` or `custom_account_update`. */ + /** + * @description The type of account link the user is requesting. Possible values are `custom_account_verification` or `custom_account_update`. + * @enum {string} + */ type: "custom_account_update" | "custom_account_verification"; }; }; @@ -10737,7 +11526,10 @@ export interface operations { data: definitions["account"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -10778,7 +11570,10 @@ export interface operations { support_url?: string; url?: string; }; - /** @description The business type. */ + /** + * @description The business type. + * @enum {string} + */ business_type?: "company" | "government_entity" | "individual" | "non_profit"; /** * company_specs @@ -10821,6 +11616,7 @@ export interface operations { name_kanji?: string; owners_provided?: boolean; phone?: string; + /** @enum {string} */ structure?: | "" | "government_instrumentality" @@ -10967,8 +11763,10 @@ export interface operations { /** transfer_schedule_specs */ schedule?: { delay_days?: unknown; + /** @enum {string} */ interval?: "daily" | "manual" | "monthly" | "weekly"; monthly_anchor?: number; + /** @enum {string} */ weekly_anchor?: "friday" | "monday" | "saturday" | "sunday" | "thursday" | "tuesday" | "wednesday"; }; statement_descriptor?: string; @@ -10983,7 +11781,10 @@ export interface operations { ip?: string; user_agent?: string; }; - /** @description The type of Stripe account to create. Currently must be `custom`, as only [Custom accounts](https://stripe.com/docs/connect/custom-accounts) may be created via the API. */ + /** + * @description The type of Stripe account to create. Currently must be `custom`, as only [Custom accounts](https://stripe.com/docs/connect/custom-accounts) may be created via the API. + * @enum {string} + */ type?: "custom" | "express" | "standard"; }; }; @@ -11051,7 +11852,10 @@ export interface operations { support_url?: string; url?: string; }; - /** @description The business type. */ + /** + * @description The business type. + * @enum {string} + */ business_type?: "company" | "government_entity" | "individual" | "non_profit"; /** * company_specs @@ -11094,6 +11898,7 @@ export interface operations { name_kanji?: string; owners_provided?: boolean; phone?: string; + /** @enum {string} */ structure?: | "" | "government_instrumentality" @@ -11238,8 +12043,10 @@ export interface operations { /** transfer_schedule_specs */ schedule?: { delay_days?: unknown; + /** @enum {string} */ interval?: "daily" | "manual" | "monthly" | "weekly"; monthly_anchor?: number; + /** @enum {string} */ weekly_anchor?: "friday" | "monday" | "saturday" | "sunday" | "thursday" | "tuesday" | "wednesday"; }; statement_descriptor?: string; @@ -11363,7 +12170,10 @@ export interface operations { payload?: { /** @description The name of the person or business that owns the bank account. */ account_holder_name?: string; - /** @description The type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description The type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string} + */ account_holder_type?: "" | "company" | "individual"; /** @description City/District/Suburb/Town/Village. */ address_city?: string; @@ -11440,7 +12250,10 @@ export interface operations { data: definitions["capability"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -11528,7 +12341,10 @@ export interface operations { data: definitions["bank_account"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -11611,7 +12427,10 @@ export interface operations { payload?: { /** @description The name of the person or business that owns the bank account. */ account_holder_name?: string; - /** @description The type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description The type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string} + */ account_holder_type?: "" | "company" | "individual"; /** @description City/District/Suburb/Town/Village. */ address_city?: string; @@ -11756,7 +12575,10 @@ export interface operations { data: definitions["person"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -12079,7 +12901,10 @@ export interface operations { data: definitions["person"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -12429,7 +13254,10 @@ export interface operations { data: definitions["apple_pay_domain"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -12528,7 +13356,10 @@ export interface operations { data: definitions["application_fee"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -12668,7 +13499,10 @@ export interface operations { data: definitions["fee_refund"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -12776,7 +13610,10 @@ export interface operations { data: definitions["balance_transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -12849,7 +13686,10 @@ export interface operations { data: definitions["balance_transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -12940,7 +13780,10 @@ export interface operations { data: definitions["bitcoin_receiver"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -13001,7 +13844,10 @@ export interface operations { data: definitions["bitcoin_transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -13038,7 +13884,10 @@ export interface operations { data: definitions["bitcoin_transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -13078,7 +13927,10 @@ export interface operations { data: definitions["charge"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -13215,6 +14067,7 @@ export interface operations { * @description A set of key-value pairs you can attach to a charge giving information about its riskiness. If you believe a charge is fraudulent, include a `user_report` key with a value of `fraudulent`. If you believe a charge is safe, include a `user_report` key with a value of `safe`. Stripe will use the information you send to improve our fraud detection algorithms. */ fraud_details?: { + /** @enum {string} */ user_report: "" | "fraudulent" | "safe"; }; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ @@ -13439,6 +14292,7 @@ export interface operations { expand?: string[]; metadata?: unknown; payment_intent?: string; + /** @enum {string} */ reason?: "duplicate" | "fraudulent" | "requested_by_customer"; refund_application_fee?: boolean; reverse_transfer?: boolean; @@ -13481,7 +14335,10 @@ export interface operations { data: definitions["refund"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -13508,6 +14365,7 @@ export interface operations { /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ metadata?: { [key: string]: unknown }; payment_intent?: string; + /** @enum {string} */ reason?: "duplicate" | "fraudulent" | "requested_by_customer"; refund_application_fee?: boolean; reverse_transfer?: boolean; @@ -13600,7 +14458,10 @@ export interface operations { data: definitions["checkout.session"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -13618,7 +14479,10 @@ export interface operations { body: { /** Body parameters for the request. */ payload: { - /** @description Specify whether Checkout should collect the customer's billing address. */ + /** + * @description Specify whether Checkout should collect the customer's billing address. + * @enum {string} + */ billing_address_collection?: "auto" | "required"; /** @description The URL the customer will be directed to if they decide to cancel payment and return to your website. */ cancel_url: string; @@ -13662,7 +14526,10 @@ export interface operations { quantity: number; tax_rates?: string[]; }[]; - /** @description The IETF language tag of the locale Checkout is displayed in. If blank or `auto`, the browser's locale is used. */ + /** + * @description The IETF language tag of the locale Checkout is displayed in. If blank or `auto`, the browser's locale is used. + * @enum {string} + */ locale?: | "auto" | "da" @@ -13683,7 +14550,10 @@ export interface operations { | "zh"; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ metadata?: { [key: string]: unknown }; - /** @description The mode of the Checkout Session, one of `payment`, `setup`, or `subscription`. */ + /** + * @description The mode of the Checkout Session, one of `payment`, `setup`, or `subscription`. + * @enum {string} + */ mode?: "payment" | "setup" | "subscription"; /** * payment_intent_data_params @@ -13691,11 +14561,13 @@ export interface operations { */ payment_intent_data?: { application_fee_amount?: number; + /** @enum {string} */ capture_method?: "automatic" | "manual"; description?: string; metadata?: { [key: string]: unknown }; on_behalf_of?: string; receipt_email?: string; + /** @enum {string} */ setup_future_usage?: "off_session" | "on_session"; /** shipping */ shipping?: { @@ -13982,6 +14854,7 @@ export interface operations { * relevant text on the page, such as the submit button. `submit_type` can only be * specified on Checkout Sessions in `payment` mode, but not Checkout Sessions * in `subscription` or `setup` mode. + * @enum {string} */ submit_type?: "auto" | "book" | "donate" | "pay"; /** @@ -14066,7 +14939,10 @@ export interface operations { data: definitions["country_spec"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -14123,7 +14999,10 @@ export interface operations { data: definitions["coupon"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -14149,7 +15028,10 @@ export interface operations { amount_off?: number; /** @description Three-letter [ISO code for the currency](https://stripe.com/docs/currencies) of the `amount_off` parameter (required if `amount_off` is passed). */ currency?: string; - /** @description Specifies how long the discount will be in effect. Can be `forever`, `once`, or `repeating`. */ + /** + * @description Specifies how long the discount will be in effect. Can be `forever`, `once`, or `repeating`. + * @enum {string} + */ duration: "forever" | "once" | "repeating"; /** @description Required only if `duration` is `repeating`, in which case it must be a positive integer that specifies the number of months the discount will be in effect. */ duration_in_months?: number; @@ -14275,7 +15157,10 @@ export interface operations { data: definitions["credit_note"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -14323,6 +15208,7 @@ export interface operations { invoice_line_item?: string; quantity?: number; tax_rates?: string[]; + /** @enum {string} */ type: "custom_line_item" | "invoice_line_item"; unit_amount?: number; unit_amount_decimal?: string; @@ -14333,7 +15219,10 @@ export interface operations { metadata?: { [key: string]: unknown }; /** @description The integer amount in **%s** representing the amount that is credited outside of Stripe. */ out_of_band_amount?: number; - /** @description Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory` */ + /** + * @description Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory` + * @enum {string} + */ reason?: "duplicate" | "fraudulent" | "order_change" | "product_unsatisfactory"; /** @description ID of an existing refund to link this credit note to. */ refund?: string; @@ -14434,7 +15323,10 @@ export interface operations { data: definitions["credit_note_line_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -14471,7 +15363,10 @@ export interface operations { data: definitions["credit_note_line_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -14583,7 +15478,10 @@ export interface operations { data: definitions["customer"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -14649,10 +15547,14 @@ export interface operations { * Whenever you attach a card to a customer, Stripe will automatically validate the card. */ source?: string; - /** @description The customer's tax exemption. One of `none`, `exempt`, or `reverse`. */ + /** + * @description The customer's tax exemption. One of `none`, `exempt`, or `reverse`. + * @enum {string} + */ tax_exempt?: "" | "exempt" | "none" | "reverse"; /** @description The customer's tax IDs. */ tax_id_data?: { + /** @enum {string} */ type: | "au_abn" | "ca_bn" @@ -14792,7 +15694,10 @@ export interface operations { * Whenever you attach a card to a customer, Stripe will automatically validate the card. */ source?: string; - /** @description The customer's tax exemption. One of `none`, `exempt`, or `reverse`. */ + /** + * @description The customer's tax exemption. One of `none`, `exempt`, or `reverse`. + * @enum {string} + */ tax_exempt?: "" | "exempt" | "none" | "reverse"; /** @description Unix timestamp representing the end of the trial period the customer will get before being charged for the first time. This will always overwrite any trials that might apply via a subscribed plan. If set, trial_end will override the default trial period of the plan the customer is being subscribed to. The special value `now` can be provided to end the customer's trial immediately. Can be at most two years from `billing_cycle_anchor`. */ trial_end?: unknown; @@ -14853,7 +15758,10 @@ export interface operations { data: definitions["customer_balance_transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -14976,7 +15884,10 @@ export interface operations { data: definitions["bank_account"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -15064,7 +15975,10 @@ export interface operations { payload?: { /** @description The name of the person or business that owns the bank account. */ account_holder_name?: string; - /** @description The type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description The type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string} + */ account_holder_type?: "company" | "individual"; /** @description City/District/Suburb/Town/Village. */ address_city?: string; @@ -15199,7 +16113,10 @@ export interface operations { data: definitions["card"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -15287,7 +16204,10 @@ export interface operations { payload?: { /** @description The name of the person or business that owns the bank account. */ account_holder_name?: string; - /** @description The type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description The type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string} + */ account_holder_type?: "company" | "individual"; /** @description City/District/Suburb/Town/Village. */ address_city?: string; @@ -15432,7 +16352,10 @@ export interface operations { data: definitions["alipay_account"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -15520,7 +16443,10 @@ export interface operations { payload?: { /** @description The name of the person or business that owns the bank account. */ account_holder_name?: string; - /** @description The type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description The type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string} + */ account_holder_type?: "company" | "individual"; /** @description City/District/Suburb/Town/Village. */ address_city?: string; @@ -15652,7 +16578,10 @@ export interface operations { data: definitions["subscription"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -15685,7 +16614,10 @@ export interface operations { cancel_at?: number; /** @description Boolean indicating whether this subscription should cancel at the end of the current period. */ cancel_at_period_end?: boolean; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. + * @enum {string} + */ collection_method?: "charge_automatically" | "send_invoice"; /** @description The code of the coupon to apply to this subscription. A coupon applied to a subscription will only affect invoices created for that particular subscription. */ coupon?: string; @@ -15717,6 +16649,7 @@ export interface operations { * Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not create a subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more. * * `pending_if_incomplete` is only used with updates and cannot be passed when creating a subscription. + * @enum {string} */ payment_behavior?: "allow_incomplete" | "error_if_incomplete" | "pending_if_incomplete"; /** @description Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval. */ @@ -15727,6 +16660,7 @@ export interface operations { * @description Determines how to handle [prorations](https://stripe.com/docs/subscriptions/billing-cycle#prorations) resulting from the `billing_cycle_anchor`. Valid values are `create_prorations` or `none`. * * Passing `create_prorations` will cause proration invoice items to be created when applicable. Prorations can be disabled by passing `none`. If no value is passed, the default is `create_prorations`. + * @enum {string} */ proration_behavior?: "always_invoice" | "create_prorations" | "none"; /** @description A non-negative decimal (with at most four decimal places) between 0 and 100. This represents the percentage of the subscription invoice subtotal that will be calculated and added as tax to the final amount in each billing period. For example, a plan which charges $10/month with a `tax_percent` of `20.0` will charge $12 per invoice. To unset a previously-set value, pass an empty string. This field has been deprecated and will be removed in a future API version, for further information view the [migration docs](https://stripe.com/docs/billing/migration/taxes) for `tax_rates`. */ @@ -15786,7 +16720,10 @@ export interface operations { payload?: { /** @description A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice subtotal that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions). */ application_fee_percent?: number; - /** @description Either `now` or `unchanged`. Setting the value to `now` resets the subscription's billing cycle anchor to the current time. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle). */ + /** + * @description Either `now` or `unchanged`. Setting the value to `now` resets the subscription's billing cycle anchor to the current time. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle). + * @enum {string} + */ billing_cycle_anchor?: "now" | "unchanged"; /** @description Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds. */ billing_thresholds?: unknown; @@ -15794,7 +16731,10 @@ export interface operations { cancel_at?: unknown; /** @description Boolean indicating whether this subscription should cancel at the end of the current period. */ cancel_at_period_end?: boolean; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. + * @enum {string} + */ collection_method?: "charge_automatically" | "send_invoice"; /** @description The code of the coupon to apply to this subscription. A coupon applied to a subscription will only affect invoices created for that particular subscription. */ coupon?: string; @@ -15831,6 +16771,7 @@ export interface operations { * Use `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes). * * Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not create a subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more. + * @enum {string} */ payment_behavior?: "allow_incomplete" | "error_if_incomplete" | "pending_if_incomplete"; /** @description Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval. */ @@ -15843,6 +16784,7 @@ export interface operations { * Passing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`. * * Prorations can be disabled by passing `none`. + * @enum {string} */ proration_behavior?: "always_invoice" | "create_prorations" | "none"; /** @description If set, the proration will be calculated as though the subscription was updated at the given time. This can be used to apply exactly the same proration that was previewed with [upcoming invoice](https://stripe.com/docs/api#retrieve_customer_invoice) endpoint. It can also be used to implement custom proration logic, such as prorating by day instead of by second, by providing the time that you wish to use for proration calculations. */ @@ -15969,7 +16911,10 @@ export interface operations { data: definitions["tax_id"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -15992,7 +16937,10 @@ export interface operations { payload: { /** @description Specifies which fields in the response should be expanded. */ expand?: string[]; - /** @description Type of the tax ID, one of `eu_vat`, `nz_gst`, `au_abn`, `in_gst`, `no_vat`, `za_vat`, `ch_vat`, `mx_rfc`, `sg_uen`, `ru_inn`, `ca_bn`, `hk_br`, `es_cif`, `tw_vat`, `th_vat`, `jp_cn`, `li_uid`, `my_itn`, `us_ein`, `kr_brn`, `ca_qst`, `my_sst`, or `sg_gst` */ + /** + * @description Type of the tax ID, one of `eu_vat`, `nz_gst`, `au_abn`, `in_gst`, `no_vat`, `za_vat`, `ch_vat`, `mx_rfc`, `sg_uen`, `ru_inn`, `ca_bn`, `hk_br`, `es_cif`, `tw_vat`, `th_vat`, `jp_cn`, `li_uid`, `my_itn`, `us_ein`, `kr_brn`, `ca_qst`, `my_sst`, or `sg_gst` + * @enum {string} + */ type: | "au_abn" | "ca_bn" @@ -16101,7 +17049,10 @@ export interface operations { data: definitions["dispute"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -16309,7 +17260,10 @@ export interface operations { data: definitions["event"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -16364,7 +17318,10 @@ export interface operations { data: definitions["exchange_rate"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -16424,7 +17381,10 @@ export interface operations { data: definitions["file_link"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -16539,7 +17499,10 @@ export interface operations { data: definitions["file"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -16574,7 +17537,10 @@ export interface operations { expires_at?: number; metadata?: unknown; }; - /** @description The purpose of the uploaded file. Possible values are `additional_verification`, `business_icon`, `business_logo`, `customer_signature`, `dispute_evidence`, `identity_document`, `pci_document`, or `tax_document_user_upload`. */ + /** + * @description The purpose of the uploaded file. Possible values are `additional_verification`, `business_icon`, `business_logo`, `customer_signature`, `dispute_evidence`, `identity_document`, `pci_document`, or `tax_document_user_upload`. + * @enum {string} + */ purpose: | "additional_verification" | "business_icon" @@ -16648,7 +17614,10 @@ export interface operations { data: definitions["invoiceitem"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -16834,7 +17803,10 @@ export interface operations { data: definitions["invoice"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -16856,7 +17828,10 @@ export interface operations { application_fee_amount?: number; /** @description Controls whether Stripe will perform [automatic collection](https://stripe.com/docs/billing/invoices/workflow/#auto_advance) of the invoice. When `false`, the invoice's state will not automatically advance without an explicit action. */ auto_advance?: boolean; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this invoice using the default source attached to the customer. When sending an invoice, Stripe will email this invoice to the customer with payment instructions. Defaults to `charge_automatically`. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this invoice using the default source attached to the customer. When sending an invoice, Stripe will email this invoice to the customer with payment instructions. Defaults to `charge_automatically`. + * @enum {string} + */ collection_method?: "charge_automatically" | "send_invoice"; /** @description A list of up to 4 custom fields to be displayed on the invoice. */ custom_fields?: { @@ -17034,7 +18009,10 @@ export interface operations { data: definitions["line_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -17088,7 +18066,10 @@ export interface operations { application_fee_amount?: number; /** @description Controls whether Stripe will perform [automatic collection](https://stripe.com/docs/billing/invoices/workflow/#auto_advance) of the invoice. */ auto_advance?: boolean; - /** @description Either `charge_automatically` or `send_invoice`. This field can be updated only on `draft` invoices. */ + /** + * @description Either `charge_automatically` or `send_invoice`. This field can be updated only on `draft` invoices. + * @enum {string} + */ collection_method?: "charge_automatically" | "send_invoice"; /** @description A list of up to 4 custom fields to be displayed on the invoice. If a value for `custom_fields` is specified, the list specified will replace the existing custom field list on this invoice. Pass an empty string to remove previously-defined fields. */ custom_fields?: { @@ -17201,7 +18182,10 @@ export interface operations { data: definitions["line_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -17354,7 +18338,10 @@ export interface operations { data: definitions["issuer_fraud_record"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -17421,7 +18408,10 @@ export interface operations { data: definitions["issuing.authorization"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -17569,7 +18559,10 @@ export interface operations { data: definitions["issuing.cardholder"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -18518,13 +19511,20 @@ export interface operations { | "womens_ready_to_wear_stores" | "wrecking_and_salvage_yards" )[]; + /** @enum {string} */ interval: "all_time" | "daily" | "monthly" | "per_authorization" | "weekly" | "yearly"; }[]; spending_limits_currency?: string; }; - /** @description Specifies whether to permit authorizations on this cardholder's cards. Defaults to `active`. */ + /** + * @description Specifies whether to permit authorizations on this cardholder's cards. Defaults to `active`. + * @enum {string} + */ status?: "active" | "inactive"; - /** @description One of `individual` or `company`. */ + /** + * @description One of `individual` or `company`. + * @enum {string} + */ type: "company" | "individual"; }; }; @@ -19500,11 +20500,15 @@ export interface operations { | "womens_ready_to_wear_stores" | "wrecking_and_salvage_yards" )[]; + /** @enum {string} */ interval: "all_time" | "daily" | "monthly" | "per_authorization" | "weekly" | "yearly"; }[]; spending_limits_currency?: string; }; - /** @description Specifies whether to permit authorizations on this cardholder's cards. */ + /** + * @description Specifies whether to permit authorizations on this cardholder's cards. + * @enum {string} + */ status?: "active" | "inactive"; }; }; @@ -19555,7 +20559,10 @@ export interface operations { data: definitions["issuing.card"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -19583,7 +20590,10 @@ export interface operations { metadata?: { [key: string]: unknown }; /** @description The card this is meant to be a replacement for (if any). */ replacement_for?: string; - /** @description If `replacement_for` is specified, this should indicate why that card is being replaced. */ + /** + * @description If `replacement_for` is specified, this should indicate why that card is being replaced. + * @enum {string} + */ replacement_reason?: "damaged" | "expired" | "lost" | "stolen"; /** * shipping_specs @@ -19600,7 +20610,9 @@ export interface operations { state?: string; }; name: string; + /** @enum {string} */ service?: "express" | "priority" | "standard"; + /** @enum {string} */ type?: "bulk" | "individual"; }; /** @@ -20480,12 +21492,19 @@ export interface operations { | "womens_ready_to_wear_stores" | "wrecking_and_salvage_yards" )[]; + /** @enum {string} */ interval: "all_time" | "daily" | "monthly" | "per_authorization" | "weekly" | "yearly"; }[]; }; - /** @description Whether authorizations can be approved on this card. Defaults to `inactive`. */ + /** + * @description Whether authorizations can be approved on this card. Defaults to `inactive`. + * @enum {string} + */ status?: "active" | "inactive"; - /** @description The type of card to issue. Possible values are `physical` or `virtual`. */ + /** + * @description The type of card to issue. Possible values are `physical` or `virtual`. + * @enum {string} + */ type: "physical" | "virtual"; }; }; @@ -20532,7 +21551,10 @@ export interface operations { body: { /** Body parameters for the request. */ payload?: { - /** @description Reason why the `status` of this card is `canceled`. */ + /** + * @description Reason why the `status` of this card is `canceled`. + * @enum {string} + */ cancellation_reason?: "lost" | "stolen"; /** @description Specifies which fields in the response should be expanded. */ expand?: string[]; @@ -21415,10 +22437,14 @@ export interface operations { | "womens_ready_to_wear_stores" | "wrecking_and_salvage_yards" )[]; + /** @enum {string} */ interval: "all_time" | "daily" | "monthly" | "per_authorization" | "weekly" | "yearly"; }[]; }; - /** @description Dictates whether authorizations can be approved on this card. If this card is being canceled because it was lost or stolen, this information should be provided as `cancellation_reason`. */ + /** + * @description Dictates whether authorizations can be approved on this card. If this card is being canceled because it was lost or stolen, this information should be provided as `cancellation_reason`. + * @enum {string} + */ status?: "active" | "canceled" | "inactive"; }; }; @@ -21455,7 +22481,10 @@ export interface operations { data: definitions["issuing.dispute"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -21563,7 +22592,10 @@ export interface operations { data: definitions["issuing.settlement"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -21651,7 +22683,10 @@ export interface operations { data: definitions["issuing.transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -21759,7 +22794,10 @@ export interface operations { data: definitions["order_return"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -21826,7 +22864,10 @@ export interface operations { data: definitions["order"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -21861,6 +22902,7 @@ export interface operations { description?: string; parent?: string; quantity?: number; + /** @enum {string} */ type?: "discount" | "shipping" | "sku" | "tax"; }[]; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ @@ -21943,7 +22985,10 @@ export interface operations { carrier: string; tracking_number: string; }; - /** @description Current order status. One of `created`, `paid`, `canceled`, `fulfilled`, or `returned`. More detail in the [Orders Guide](https://stripe.com/docs/orders/guide#understanding-order-statuses). */ + /** + * @description Current order status. One of `created`, `paid`, `canceled`, `fulfilled`, or `returned`. More detail in the [Orders Guide](https://stripe.com/docs/orders/guide#understanding-order-statuses). + * @enum {string} + */ status?: "canceled" | "created" | "fulfilled" | "paid" | "returned"; }; }; @@ -22011,6 +23056,7 @@ export interface operations { description?: string; parent?: string; quantity?: number; + /** @enum {string} */ type?: "discount" | "shipping" | "sku" | "tax"; }[]; }; @@ -22052,7 +23098,10 @@ export interface operations { data: definitions["payment_intent"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -22089,10 +23138,14 @@ export interface operations { * more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts). */ application_fee_amount?: number; - /** @description Controls when the funds will be captured from the customer's account. */ + /** + * @description Controls when the funds will be captured from the customer's account. + * @enum {string} + */ capture_method?: "automatic" | "manual"; /** @description Set to `true` to attempt to [confirm](https://stripe.com/docs/api/payment_intents/confirm) this PaymentIntent immediately. This parameter defaults to `false`. When creating and confirming a PaymentIntent at the same time, parameters available in the [confirm](https://stripe.com/docs/api/payment_intents/confirm) API may also be provided. */ confirm?: boolean; + /** @enum {string} */ confirmation_method?: "automatic" | "manual"; /** @description Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). */ currency: string; @@ -22127,6 +23180,7 @@ export interface operations { ip_address: string; user_agent: string; }; + /** @enum {string} */ type: "offline" | "online"; }; }; @@ -22161,6 +23215,7 @@ export interface operations { * Providing this parameter will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any required actions from the user are complete. If no Customer was provided, the payment method can still be [attached](https://stripe.com/docs/api/payment_methods/attach) to a Customer after the transaction completes. * * When processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication). + * @enum {string} */ setup_future_usage?: "off_session" | "on_session"; /** @@ -22301,6 +23356,7 @@ export interface operations { * When processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication). * * If `setup_future_usage` is already set and you are performing a request using a publishable key, you may only update the value from `on_session` to `off_session`. + * @enum {string} */ setup_future_usage?: "" | "off_session" | "on_session"; /** @description Shipping information for this PaymentIntent. */ @@ -22345,7 +23401,10 @@ export interface operations { body: { /** Body parameters for the request. */ payload?: { - /** @description Reason for canceling this PaymentIntent. Possible values are `duplicate`, `fraudulent`, `requested_by_customer`, or `abandoned` */ + /** + * @description Reason for canceling this PaymentIntent. Possible values are `duplicate`, `fraudulent`, `requested_by_customer`, or `abandoned` + * @enum {string} + */ cancellation_reason?: "abandoned" | "duplicate" | "fraudulent" | "requested_by_customer"; /** @description Specifies which fields in the response should be expanded. */ expand?: string[]; @@ -22472,6 +23531,7 @@ export interface operations { ip_address: string; user_agent: string; }; + /** @enum {string} */ type: "offline" | "online"; }; }; @@ -22504,6 +23564,7 @@ export interface operations { * When processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication). * * If `setup_future_usage` is already set and you are performing a request using a publishable key, you may only update the value from `on_session` to `off_session`. + * @enum {string} */ setup_future_usage?: "" | "off_session" | "on_session"; /** @description Shipping information for this PaymentIntent. */ @@ -22549,7 +23610,10 @@ export interface operations { data: definitions["payment_method"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -22604,6 +23668,7 @@ export interface operations { * @description If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method. */ fpx?: { + /** @enum {string} */ bank: | "affin_bank" | "alliance_bank" @@ -22631,6 +23696,7 @@ export interface operations { * @description If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method. */ ideal?: { + /** @enum {string} */ bank?: | "abn_amro" | "asn_bank" @@ -22656,7 +23722,10 @@ export interface operations { sepa_debit?: { iban: string; }; - /** @description The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type. Required unless `payment_method` is specified (see the [Cloning PaymentMethods](https://stripe.com/docs/payments/payment-methods/connect#cloning-payment-methods) guide) */ + /** + * @description The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type. Required unless `payment_method` is specified (see the [Cloning PaymentMethods](https://stripe.com/docs/payments/payment-methods/connect#cloning-payment-methods) guide) + * @enum {string} + */ type?: "au_becs_debit" | "card" | "fpx" | "ideal" | "sepa_debit"; }; }; @@ -22843,7 +23912,10 @@ export interface operations { data: definitions["payout"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -22879,9 +23951,15 @@ export interface operations { expand?: string[]; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ metadata?: { [key: string]: unknown }; - /** @description The method used to send this payout, which can be `standard` or `instant`. `instant` is only supported for payouts to debit cards. (See [Instant payouts for marketplaces for more information](https://stripe.com/blog/instant-payouts-for-marketplaces).) */ + /** + * @description The method used to send this payout, which can be `standard` or `instant`. `instant` is only supported for payouts to debit cards. (See [Instant payouts for marketplaces for more information](https://stripe.com/blog/instant-payouts-for-marketplaces).) + * @enum {string} + */ method?: "instant" | "standard"; - /** @description The balance type of your Stripe balance to draw this payout from. Balances for different payment sources are kept separately. You can find the amounts with the balances API. One of `bank_account`, `card`, or `fpx`. */ + /** + * @description The balance type of your Stripe balance to draw this payout from. Balances for different payment sources are kept separately. You can find the amounts with the balances API. One of `bank_account`, `card`, or `fpx`. + * @enum {string} + */ source_type?: "bank_account" | "card" | "fpx"; /** @description A string to be displayed on the recipient's bank or card statement. This may be at most 22 characters. Attempting to use a `statement_descriptor` longer than 22 characters will return an error. Note: Most banks will truncate this information and/or display it inconsistently. Some may not display it at all. */ statement_descriptor?: string; @@ -23000,7 +24078,10 @@ export interface operations { data: definitions["plan"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -23020,13 +24101,19 @@ export interface operations { payload: { /** @description Whether the plan is currently available for new subscriptions. Defaults to `true`. */ active?: boolean; - /** @description Specifies a usage aggregation strategy for plans of `usage_type=metered`. Allowed values are `sum` for summing up all usage during a period, `last_during_period` for using the last usage record reported within a period, `last_ever` for using the last usage record ever (across period bounds) or `max` which uses the usage record with the maximum reported usage during a period. Defaults to `sum`. */ + /** + * @description Specifies a usage aggregation strategy for plans of `usage_type=metered`. Allowed values are `sum` for summing up all usage during a period, `last_during_period` for using the last usage record reported within a period, `last_ever` for using the last usage record ever (across period bounds) or `max` which uses the usage record with the maximum reported usage during a period. Defaults to `sum`. + * @enum {string} + */ aggregate_usage?: "last_during_period" | "last_ever" | "max" | "sum"; /** @description A positive integer in %s (or 0 for a free plan) representing how much to charge on a recurring basis. */ amount?: number; /** @description Same as `amount`, but accepts a decimal value with at most 12 decimal places. Only one of `amount` and `amount_decimal` can be set. */ amount_decimal?: string; - /** @description Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `amount`) will be charged per unit in `quantity` (for plans with `usage_type=licensed`), or per unit of total usage (for plans with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes. */ + /** + * @description Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `amount`) will be charged per unit in `quantity` (for plans with `usage_type=licensed`), or per unit of total usage (for plans with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes. + * @enum {string} + */ billing_scheme?: "per_unit" | "tiered"; /** @description Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). */ currency: string; @@ -23034,7 +24121,10 @@ export interface operations { expand?: string[]; /** @description An identifier randomly generated by Stripe. Used to identify this plan when subscribing a customer. You can optionally override this ID, but the ID must be unique across all plans in your Stripe account. You can, however, use the same plan ID in both live and test modes. */ id?: string; - /** @description Specifies billing frequency. Either `day`, `week`, `month` or `year`. */ + /** + * @description Specifies billing frequency. Either `day`, `week`, `month` or `year`. + * @enum {string} + */ interval: "day" | "month" | "week" | "year"; /** @description The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). */ interval_count?: number; @@ -23062,7 +24152,10 @@ export interface operations { unit_amount_decimal?: string; up_to: unknown; }[]; - /** @description Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price, in `graduated` tiering pricing can successively change as the quantity grows. */ + /** + * @description Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price, in `graduated` tiering pricing can successively change as the quantity grows. + * @enum {string} + */ tiers_mode?: "graduated" | "volume"; /** * transform_usage_param @@ -23070,11 +24163,15 @@ export interface operations { */ transform_usage?: { divide_by: number; + /** @enum {string} */ round: "down" | "up"; }; /** @description Default number of trial days when subscribing a customer to this plan using [`trial_from_plan=true`](https://stripe.com/docs/api#create_subscription-trial_from_plan). */ trial_period_days?: number; - /** @description Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`. */ + /** + * @description Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`. + * @enum {string} + */ usage_type?: "licensed" | "metered"; }; }; @@ -23198,7 +24295,10 @@ export interface operations { data: definitions["product"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -23255,7 +24355,10 @@ export interface operations { * It must contain at least one letter. */ statement_descriptor?: string; - /** @description The type of the product. Defaults to `service` if not explicitly specified, enabling use of this product with Subscriptions and Plans. Set this parameter to `good` to use this product with Orders and SKUs. On API versions before `2018-02-05`, this field defaults to `good` for compatibility reasons. */ + /** + * @description The type of the product. Defaults to `service` if not explicitly specified, enabling use of this product with Subscriptions and Plans. Set this parameter to `good` to use this product with Orders and SKUs. On API versions before `2018-02-05`, this field defaults to `good` for compatibility reasons. + * @enum {string} + */ type?: "good" | "service"; /** @description A label that represents units of this product in Stripe and on customers’ receipts and invoices. When set, this will be included in associated invoice line item descriptions. */ unit_label?: string; @@ -23394,7 +24497,10 @@ export interface operations { data: definitions["radar.early_fraud_warning"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -23458,7 +24564,10 @@ export interface operations { data: definitions["radar.value_list_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -23562,7 +24671,10 @@ export interface operations { data: definitions["radar.value_list"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -23584,7 +24696,10 @@ export interface operations { alias: string; /** @description Specifies which fields in the response should be expanded. */ expand?: string[]; - /** @description Type of the items in the value list. One of `card_fingerprint`, `card_bin`, `email`, `ip_address`, `country`, `string`, or `case_sensitive_string`. Use `string` if the item type is unknown or mixed. */ + /** + * @description Type of the items in the value list. One of `card_fingerprint`, `card_bin`, `email`, `ip_address`, `country`, `string`, or `case_sensitive_string`. Use `string` if the item type is unknown or mixed. + * @enum {string} + */ item_type?: | "card_bin" | "card_fingerprint" @@ -23707,7 +24822,10 @@ export interface operations { data: definitions["recipient"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -23873,7 +24991,10 @@ export interface operations { data: definitions["refund"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -23898,6 +25019,7 @@ export interface operations { /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ metadata?: { [key: string]: unknown }; payment_intent?: string; + /** @enum {string} */ reason?: "duplicate" | "fraudulent" | "requested_by_customer"; refund_application_fee?: boolean; reverse_transfer?: boolean; @@ -23990,7 +25112,10 @@ export interface operations { data: definitions["reporting.report_run"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -24021,6 +25146,7 @@ export interface operations { interval_end?: number; interval_start?: number; payout?: string; + /** @enum {string} */ reporting_category?: | "advance" | "advance_funding" @@ -24053,6 +25179,7 @@ export interface operations { | "topup_reversal" | "transfer" | "transfer_reversal"; + /** @enum {string} */ timezone?: | "Africa/Abidjan" | "Africa/Accra" @@ -24702,7 +25829,10 @@ export interface operations { data: definitions["reporting.report_type"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -24758,7 +25888,10 @@ export interface operations { data: definitions["review"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -24844,7 +25977,10 @@ export interface operations { data: definitions["setup_intent"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -24894,6 +26030,7 @@ export interface operations { ip_address: string; user_agent: string; }; + /** @enum {string} */ type: "offline" | "online"; }; }; @@ -24910,6 +26047,7 @@ export interface operations { payment_method_options?: { /** setup_intent_param */ card?: { + /** @enum {string} */ request_three_d_secure?: "any" | "automatic"; }; }; @@ -24925,7 +26063,10 @@ export interface operations { amount: number; currency: string; }; - /** @description Indicates how the payment method is intended to be used in the future. If not provided, this value defaults to `off_session`. */ + /** + * @description Indicates how the payment method is intended to be used in the future. If not provided, this value defaults to `off_session`. + * @enum {string} + */ usage?: "off_session" | "on_session"; }; }; @@ -25001,6 +26142,7 @@ export interface operations { payment_method_options?: { /** setup_intent_param */ card?: { + /** @enum {string} */ request_three_d_secure?: "any" | "automatic"; }; }; @@ -25033,7 +26175,10 @@ export interface operations { body: { /** Body parameters for the request. */ payload?: { - /** @description Reason for canceling this SetupIntent. Possible values are `abandoned`, `requested_by_customer`, or `duplicate` */ + /** + * @description Reason for canceling this SetupIntent. Possible values are `abandoned`, `requested_by_customer`, or `duplicate` + * @enum {string} + */ cancellation_reason?: "abandoned" | "duplicate" | "requested_by_customer"; /** @description Specifies which fields in the response should be expanded. */ expand?: string[]; @@ -25093,6 +26238,7 @@ export interface operations { ip_address: string; user_agent: string; }; + /** @enum {string} */ type: "offline" | "online"; }; }; @@ -25105,6 +26251,7 @@ export interface operations { payment_method_options?: { /** setup_intent_param */ card?: { + /** @enum {string} */ request_three_d_secure?: "any" | "automatic"; }; }; @@ -25149,7 +26296,10 @@ export interface operations { data: definitions["scheduled_query_run"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -25214,7 +26364,10 @@ export interface operations { data: definitions["sku"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -25250,7 +26403,9 @@ export interface operations { */ inventory: { quantity?: number; + /** @enum {string} */ type?: "bucket" | "finite" | "infinite"; + /** @enum {string} */ value?: "" | "in_stock" | "limited" | "out_of_stock"; }; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ @@ -25334,7 +26489,9 @@ export interface operations { */ inventory?: { quantity?: number; + /** @enum {string} */ type?: "bucket" | "finite" | "infinite"; + /** @enum {string} */ value?: "" | "in_stock" | "limited" | "out_of_stock"; }; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ @@ -25391,7 +26548,10 @@ export interface operations { customer?: string; /** @description Specifies which fields in the response should be expanded. */ expand?: string[]; - /** @description The authentication `flow` of the source to create. `flow` is one of `redirect`, `receiver`, `code_verification`, `none`. It is generally inferred unless a type supports multiple flows. */ + /** + * @description The authentication `flow` of the source to create. `flow` is one of `redirect`, `receiver`, `code_verification`, `none`. It is generally inferred unless a type supports multiple flows. + * @enum {string} + */ flow?: "code_verification" | "none" | "receiver" | "redirect"; /** * mandate_params @@ -25412,13 +26572,17 @@ export interface operations { ip?: string; user_agent?: string; }; + /** @enum {string} */ status: "accepted" | "pending" | "refused" | "revoked"; + /** @enum {string} */ type?: "offline" | "online"; user_agent?: string; }; amount?: unknown; currency?: string; + /** @enum {string} */ interval?: "one_time" | "scheduled" | "variable"; + /** @enum {string} */ notification_method?: "deprecated_none" | "email" | "manual" | "none" | "stripe_email"; }; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ @@ -25448,6 +26612,7 @@ export interface operations { * @description Optional parameters for the receiver flow. Can be set only if the source is a receiver (`flow` is `receiver`). */ receiver?: { + /** @enum {string} */ refund_attributes_method?: "email" | "manual" | "none"; }; /** @@ -25468,6 +26633,7 @@ export interface operations { description?: string; parent?: string; quantity?: number; + /** @enum {string} */ type?: "discount" | "shipping" | "sku" | "tax"; }[]; /** order_shipping */ @@ -25493,7 +26659,10 @@ export interface operations { token?: string; /** @description The `type` of the source to create. Required unless `customer` and `original_source` are specified (see the [Cloning card Sources](https://stripe.com/docs/sources/connect#cloning-card-sources) guide) */ type?: string; - /** @description Either `reusable` or `single_use`. Whether this source should be reusable or not. Some source types may or may not be reusable by construction, while others may leave the option at creation. If an incompatible value is passed, an error will be returned. */ + /** + * @description Either `reusable` or `single_use`. Whether this source should be reusable or not. Some source types may or may not be reusable by construction, while others may leave the option at creation. If an incompatible value is passed, an error will be returned. + * @enum {string} + */ usage?: "reusable" | "single_use"; }; }; @@ -25569,13 +26738,17 @@ export interface operations { ip?: string; user_agent?: string; }; + /** @enum {string} */ status: "accepted" | "pending" | "refused" | "revoked"; + /** @enum {string} */ type?: "offline" | "online"; user_agent?: string; }; amount?: unknown; currency?: string; + /** @enum {string} */ interval?: "one_time" | "scheduled" | "variable"; + /** @enum {string} */ notification_method?: "deprecated_none" | "email" | "manual" | "none" | "stripe_email"; }; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ @@ -25609,6 +26782,7 @@ export interface operations { description?: string; parent?: string; quantity?: number; + /** @enum {string} */ type?: "discount" | "shipping" | "sku" | "tax"; }[]; /** order_shipping */ @@ -25689,7 +26863,10 @@ export interface operations { data: definitions["source_transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -25774,7 +26951,10 @@ export interface operations { data: definitions["subscription_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -25804,6 +26984,7 @@ export interface operations { * Use `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes). * * Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not create a subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more. + * @enum {string} */ payment_behavior?: "allow_incomplete" | "error_if_incomplete" | "pending_if_incomplete"; /** @description The identifier of the plan to add to the subscription. */ @@ -25816,6 +26997,7 @@ export interface operations { * Passing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`. * * Prorations can be disabled by passing `none`. + * @enum {string} */ proration_behavior?: "always_invoice" | "create_prorations" | "none"; /** @description If set, the proration will be calculated as though the subscription was updated at the given time. This can be used to apply the same proration that was previewed with the [upcoming invoice](https://stripe.com/docs/api#retrieve_customer_invoice) endpoint. */ @@ -25885,6 +27067,7 @@ export interface operations { * Use `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes). * * Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not create a subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more. + * @enum {string} */ payment_behavior?: "allow_incomplete" | "error_if_incomplete" | "pending_if_incomplete"; /** @description The identifier of the new plan for this subscription item. */ @@ -25897,6 +27080,7 @@ export interface operations { * Passing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`. * * Prorations can be disabled by passing `none`. + * @enum {string} */ proration_behavior?: "always_invoice" | "create_prorations" | "none"; /** @description If set, the proration will be calculated as though the subscription was updated at the given time. This can be used to apply the same proration that was previewed with the [upcoming invoice](https://stripe.com/docs/api#retrieve_customer_invoice) endpoint. */ @@ -25938,6 +27122,7 @@ export interface operations { * Passing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`. * * Prorations can be disabled by passing `none`. + * @enum {string} */ proration_behavior?: "always_invoice" | "create_prorations" | "none"; /** @description If set, the proration will be calculated as though the subscription was updated at the given time. This can be used to apply the same proration that was previewed with the [upcoming invoice](https://stripe.com/docs/api#retrieve_customer_invoice) endpoint. */ @@ -25984,7 +27169,10 @@ export interface operations { data: definitions["usage_record_summary"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -26013,7 +27201,10 @@ export interface operations { body: { /** Body parameters for the request. */ payload: { - /** @description Valid values are `increment` (default) or `set`. When using `increment` the specified `quantity` will be added to the usage at the specified timestamp. The `set` action will overwrite the usage quantity at that timestamp. If the subscription has [billing thresholds](https://stripe.com/docs/api/subscriptions/object#subscription_object-billing_thresholds), `increment` is the only allowed value. */ + /** + * @description Valid values are `increment` (default) or `set`. When using `increment` the specified `quantity` will be added to the usage at the specified timestamp. The `set` action will overwrite the usage quantity at that timestamp. If the subscription has [billing thresholds](https://stripe.com/docs/api/subscriptions/object#subscription_object-billing_thresholds), `increment` is the only allowed value. + * @enum {string} + */ action?: "increment" | "set"; /** @description Specifies which fields in the response should be expanded. */ expand?: string[]; @@ -26068,7 +27259,10 @@ export interface operations { data: definitions["subscription_schedule"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -26094,6 +27288,7 @@ export interface operations { */ default_settings?: { billing_thresholds?: unknown; + /** @enum {string} */ collection_method?: "charge_automatically" | "send_invoice"; default_payment_method?: string; /** subscription_schedules_param */ @@ -26101,7 +27296,10 @@ export interface operations { days_until_due?: number; }; }; - /** @description Configures how the subscription schedule behaves when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running.`cancel` will end the subscription schedule and cancel the underlying subscription. */ + /** + * @description Configures how the subscription schedule behaves when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running.`cancel` will end the subscription schedule and cancel the underlying subscription. + * @enum {string} + */ end_behavior?: "cancel" | "none" | "release" | "renew"; /** @description Specifies which fields in the response should be expanded. */ expand?: string[]; @@ -26113,6 +27311,7 @@ export interface operations { phases?: { application_fee_percent?: number; billing_thresholds?: unknown; + /** @enum {string} */ collection_method?: "charge_automatically" | "send_invoice"; coupon?: string; default_payment_method?: string; @@ -26129,6 +27328,7 @@ export interface operations { quantity?: number; tax_rates?: string[]; }[]; + /** @enum {string} */ proration_behavior?: "always_invoice" | "create_prorations" | "none"; tax_percent?: number; trial?: boolean; @@ -26187,6 +27387,7 @@ export interface operations { */ default_settings?: { billing_thresholds?: unknown; + /** @enum {string} */ collection_method?: "charge_automatically" | "send_invoice"; default_payment_method?: string; /** subscription_schedules_param */ @@ -26194,7 +27395,10 @@ export interface operations { days_until_due?: number; }; }; - /** @description Configures how the subscription schedule behaves when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running.`cancel` will end the subscription schedule and cancel the underlying subscription. */ + /** + * @description Configures how the subscription schedule behaves when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running.`cancel` will end the subscription schedule and cancel the underlying subscription. + * @enum {string} + */ end_behavior?: "cancel" | "none" | "release" | "renew"; /** @description Specifies which fields in the response should be expanded. */ expand?: string[]; @@ -26204,6 +27408,7 @@ export interface operations { phases?: { application_fee_percent?: number; billing_thresholds?: unknown; + /** @enum {string} */ collection_method?: "charge_automatically" | "send_invoice"; coupon?: string; default_payment_method?: string; @@ -26220,6 +27425,7 @@ export interface operations { quantity?: number; tax_rates?: string[]; }[]; + /** @enum {string} */ proration_behavior?: "always_invoice" | "create_prorations" | "none"; start_date?: unknown; tax_percent?: number; @@ -26228,7 +27434,10 @@ export interface operations { }[]; /** @description This field has been renamed to `proration_behavior`. `prorate=true` can be replaced with `proration_behavior=create_prorations` and `prorate=false` can be replaced with `proration_behavior=none`. */ prorate?: boolean; - /** @description If the update changes the current phase, indicates if the changes should be prorated. Valid values are `create_prorations` or `none`, and the default value is `create_prorations`. */ + /** + * @description If the update changes the current phase, indicates if the changes should be prorated. Valid values are `create_prorations` or `none`, and the default value is `create_prorations`. + * @enum {string} + */ proration_behavior?: "always_invoice" | "create_prorations" | "none"; }; }; @@ -26332,7 +27541,10 @@ export interface operations { data: definitions["subscription"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -26362,7 +27574,10 @@ export interface operations { cancel_at?: number; /** @description Boolean indicating whether this subscription should cancel at the end of the current period. */ cancel_at_period_end?: boolean; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. + * @enum {string} + */ collection_method?: "charge_automatically" | "send_invoice"; /** @description The code of the coupon to apply to this subscription. A coupon applied to a subscription will only affect invoices created for that particular subscription. */ coupon?: string; @@ -26396,6 +27611,7 @@ export interface operations { * Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not create a subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more. * * `pending_if_incomplete` is only used with updates and cannot be passed when creating a subscription. + * @enum {string} */ payment_behavior?: "allow_incomplete" | "error_if_incomplete" | "pending_if_incomplete"; /** @description Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval. */ @@ -26406,6 +27622,7 @@ export interface operations { * @description Determines how to handle [prorations](https://stripe.com/docs/subscriptions/billing-cycle#prorations) resulting from the `billing_cycle_anchor`. Valid values are `create_prorations` or `none`. * * Passing `create_prorations` will cause proration invoice items to be created when applicable. Prorations can be disabled by passing `none`. If no value is passed, the default is `create_prorations`. + * @enum {string} */ proration_behavior?: "always_invoice" | "create_prorations" | "none"; /** @description A non-negative decimal (with at most four decimal places) between 0 and 100. This represents the percentage of the subscription invoice subtotal that will be calculated and added as tax to the final amount in each billing period. For example, a plan which charges $10/month with a `tax_percent` of `20.0` will charge $12 per invoice. To unset a previously-set value, pass an empty string. This field has been deprecated and will be removed in a future API version, for further information view the [migration docs](https://stripe.com/docs/billing/migration/taxes) for `tax_rates`. */ @@ -26463,7 +27680,10 @@ export interface operations { payload?: { /** @description A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice subtotal that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions). */ application_fee_percent?: number; - /** @description Either `now` or `unchanged`. Setting the value to `now` resets the subscription's billing cycle anchor to the current time. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle). */ + /** + * @description Either `now` or `unchanged`. Setting the value to `now` resets the subscription's billing cycle anchor to the current time. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle). + * @enum {string} + */ billing_cycle_anchor?: "now" | "unchanged"; /** @description Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds. */ billing_thresholds?: unknown; @@ -26471,7 +27691,10 @@ export interface operations { cancel_at?: unknown; /** @description Boolean indicating whether this subscription should cancel at the end of the current period. */ cancel_at_period_end?: boolean; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. + * @enum {string} + */ collection_method?: "charge_automatically" | "send_invoice"; /** @description The code of the coupon to apply to this subscription. A coupon applied to a subscription will only affect invoices created for that particular subscription. */ coupon?: string; @@ -26508,6 +27731,7 @@ export interface operations { * Use `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes). * * Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not create a subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more. + * @enum {string} */ payment_behavior?: "allow_incomplete" | "error_if_incomplete" | "pending_if_incomplete"; /** @description Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval. */ @@ -26520,6 +27744,7 @@ export interface operations { * Passing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`. * * Prorations can be disabled by passing `none`. + * @enum {string} */ proration_behavior?: "always_invoice" | "create_prorations" | "none"; /** @description If set, the proration will be calculated as though the subscription was updated at the given time. This can be used to apply exactly the same proration that was previewed with [upcoming invoice](https://stripe.com/docs/api#retrieve_customer_invoice) endpoint. It can also be used to implement custom proration logic, such as prorating by day instead of by second, by providing the time that you wish to use for proration calculations. */ @@ -26624,7 +27849,10 @@ export interface operations { data: definitions["tax_rate"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -26774,7 +28002,10 @@ export interface operations { data: definitions["terminal.location"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -26933,7 +28164,10 @@ export interface operations { data: definitions["terminal.reader"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -27058,6 +28292,7 @@ export interface operations { * @description Information for the account this token will represent. */ account?: { + /** @enum {string} */ business_type?: "company" | "government_entity" | "individual" | "non_profit"; /** company_specs */ company?: { @@ -27097,6 +28332,7 @@ export interface operations { name_kanji?: string; owners_provided?: boolean; phone?: string; + /** @enum {string} */ structure?: | "" | "government_instrumentality" @@ -27193,6 +28429,7 @@ export interface operations { */ bank_account?: { account_holder_name?: string; + /** @enum {string} */ account_holder_type?: "company" | "individual"; account_number: string; country: string; @@ -27345,7 +28582,10 @@ export interface operations { data: definitions["topup"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -27496,7 +28736,10 @@ export interface operations { data: definitions["transfer"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -27528,7 +28771,10 @@ export interface operations { metadata?: { [key: string]: unknown }; /** @description You can use this parameter to transfer funds from a charge before they are added to your available balance. A pending balance will transfer immediately but the funds will not become available until the original charge becomes available. [See the Connect documentation](https://stripe.com/docs/connect/charges-transfers#transfer-availability) for details. */ source_transaction?: string; - /** @description The source balance to use for this transfer. One of `bank_account`, `card`, or `fpx`. For most users, this will default to `card`. */ + /** + * @description The source balance to use for this transfer. One of `bank_account`, `card`, or `fpx`. For most users, this will default to `card`. + * @enum {string} + */ source_type?: "bank_account" | "card" | "fpx"; /** @description A string that identifies this transaction as part of a group. See the [Connect documentation](https://stripe.com/docs/connect/charges-transfers#transfer-options) for details. */ transfer_group?: string; @@ -27571,7 +28817,10 @@ export interface operations { data: definitions["transfer_reversal"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -27753,7 +29002,10 @@ export interface operations { data: definitions["webhook_endpoint"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -27771,7 +29023,10 @@ export interface operations { body: { /** Body parameters for the request. */ payload: { - /** @description Events sent to this endpoint will be generated with this Stripe Version instead of your account's default Stripe Version. */ + /** + * @description Events sent to this endpoint will be generated with this Stripe Version instead of your account's default Stripe Version. + * @enum {string} + */ api_version?: | "2011-01-01" | "2011-06-21" diff --git a/test/v3/expected/consts-enums.additional.ts b/test/v3/expected/consts-enums.additional.ts new file mode 100644 index 000000000..073786a25 --- /dev/null +++ b/test/v3/expected/consts-enums.additional.ts @@ -0,0 +1,35 @@ +/** + * This file was auto-generated by openapi-typescript. + * Do not make direct changes to the file. + */ + +export interface paths { + "/test": { + get: { + responses: { + /** A list of types. */ + 200: unknown; + }; + }; + }; +} + +export interface components { + schemas: { + /** @description Enum with null and nullable */ + MyType: { + /** @enum {string|null} */ + myEnumTestFieldNullable?: ("foo" | "bar" | null) | null; + /** @enum {string|null} */ + myEnumTestField?: ("foo" | "bar" | null) | null; + /** @constant */ + myConstTestField?: "constant-value"; + /** @constant */ + myConstTestFieldNullable?: 4 | null; + } & { [key: string]: unknown }; + }; +} + +export interface operations {} + +export interface external {} diff --git a/test/v3/expected/consts-enums.immutable.ts b/test/v3/expected/consts-enums.immutable.ts new file mode 100644 index 000000000..9e28f4a7e --- /dev/null +++ b/test/v3/expected/consts-enums.immutable.ts @@ -0,0 +1,35 @@ +/** + * This file was auto-generated by openapi-typescript. + * Do not make direct changes to the file. + */ + +export interface paths { + readonly "/test": { + readonly get: { + readonly responses: { + /** A list of types. */ + readonly 200: unknown; + }; + }; + }; +} + +export interface components { + readonly schemas: { + /** @description Enum with null and nullable */ + readonly MyType: { + /** @enum {string|null} */ + readonly myEnumTestFieldNullable?: ("foo" | "bar" | null) | null; + /** @enum {string|null} */ + readonly myEnumTestField?: ("foo" | "bar" | null) | null; + /** @constant */ + readonly myConstTestField?: "constant-value"; + /** @constant */ + readonly myConstTestFieldNullable?: 4 | null; + }; + }; +} + +export interface operations {} + +export interface external {} diff --git a/test/v3/expected/consts-enums.ts b/test/v3/expected/consts-enums.ts new file mode 100644 index 000000000..4e92ffe8c --- /dev/null +++ b/test/v3/expected/consts-enums.ts @@ -0,0 +1,35 @@ +/** + * This file was auto-generated by openapi-typescript. + * Do not make direct changes to the file. + */ + +export interface paths { + "/test": { + get: { + responses: { + /** A list of types. */ + 200: unknown; + }; + }; + }; +} + +export interface components { + schemas: { + /** @description Enum with null and nullable */ + MyType: { + /** @enum {string|null} */ + myEnumTestFieldNullable?: ("foo" | "bar" | null) | null; + /** @enum {string|null} */ + myEnumTestField?: ("foo" | "bar" | null) | null; + /** @constant */ + myConstTestField?: "constant-value"; + /** @constant */ + myConstTestFieldNullable?: 4 | null; + }; + }; +} + +export interface operations {} + +export interface external {} diff --git a/test/v3/expected/github.additional.ts b/test/v3/expected/github.additional.ts index 56dce729c..fc8ab9151 100644 --- a/test/v3/expected/github.additional.ts +++ b/test/v3/expected/github.additional.ts @@ -5385,7 +5385,10 @@ export interface components { [key: string]: unknown; }) | null; - /** @description Describe whether all repositories have been selected or there's a selection involved */ + /** + * @description Describe whether all repositories have been selected or there's a selection involved + * @enum {string} + */ repository_selection: "all" | "selected"; /** * Format: uri @@ -5446,65 +5449,155 @@ export interface components { * @example [object Object] */ "app-permissions": { - /** @description The level of permission to grant the access token for GitHub Actions workflows, workflow runs, and artifacts. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token for GitHub Actions workflows, workflow runs, and artifacts. Can be one of: `read` or `write`. + * @enum {string} + */ actions?: "read" | "write"; - /** @description The level of permission to grant the access token for repository creation, deletion, settings, teams, and collaborators creation. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token for repository creation, deletion, settings, teams, and collaborators creation. Can be one of: `read` or `write`. + * @enum {string} + */ administration?: "read" | "write"; - /** @description The level of permission to grant the access token for checks on code. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token for checks on code. Can be one of: `read` or `write`. + * @enum {string} + */ checks?: "read" | "write"; - /** @description The level of permission to grant the access token for notification of content references and creation content attachments. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token for notification of content references and creation content attachments. Can be one of: `read` or `write`. + * @enum {string} + */ content_references?: "read" | "write"; - /** @description The level of permission to grant the access token for repository contents, commits, branches, downloads, releases, and merges. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token for repository contents, commits, branches, downloads, releases, and merges. Can be one of: `read` or `write`. + * @enum {string} + */ contents?: "read" | "write"; - /** @description The level of permission to grant the access token for deployments and deployment statuses. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token for deployments and deployment statuses. Can be one of: `read` or `write`. + * @enum {string} + */ deployments?: "read" | "write"; - /** @description The level of permission to grant the access token for managing repository environments. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token for managing repository environments. Can be one of: `read` or `write`. + * @enum {string} + */ environments?: "read" | "write"; - /** @description The level of permission to grant the access token for issues and related comments, assignees, labels, and milestones. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token for issues and related comments, assignees, labels, and milestones. Can be one of: `read` or `write`. + * @enum {string} + */ issues?: "read" | "write"; - /** @description The level of permission to grant the access token to search repositories, list collaborators, and access repository metadata. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to search repositories, list collaborators, and access repository metadata. Can be one of: `read` or `write`. + * @enum {string} + */ metadata?: "read" | "write"; - /** @description The level of permission to grant the access token for packages published to GitHub Packages. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token for packages published to GitHub Packages. Can be one of: `read` or `write`. + * @enum {string} + */ packages?: "read" | "write"; - /** @description The level of permission to grant the access token to retrieve Pages statuses, configuration, and builds, as well as create new builds. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to retrieve Pages statuses, configuration, and builds, as well as create new builds. Can be one of: `read` or `write`. + * @enum {string} + */ pages?: "read" | "write"; - /** @description The level of permission to grant the access token for pull requests and related comments, assignees, labels, milestones, and merges. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token for pull requests and related comments, assignees, labels, milestones, and merges. Can be one of: `read` or `write`. + * @enum {string} + */ pull_requests?: "read" | "write"; - /** @description The level of permission to grant the access token to manage the post-receive hooks for a repository. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to manage the post-receive hooks for a repository. Can be one of: `read` or `write`. + * @enum {string} + */ repository_hooks?: "read" | "write"; - /** @description The level of permission to grant the access token to manage repository projects, columns, and cards. Can be one of: `read`, `write`, or `admin`. */ + /** + * @description The level of permission to grant the access token to manage repository projects, columns, and cards. Can be one of: `read`, `write`, or `admin`. + * @enum {string} + */ repository_projects?: "read" | "write" | "admin"; - /** @description The level of permission to grant the access token to view and manage secret scanning alerts. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to view and manage secret scanning alerts. Can be one of: `read` or `write`. + * @enum {string} + */ secret_scanning_alerts?: "read" | "write"; - /** @description The level of permission to grant the access token to manage repository secrets. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to manage repository secrets. Can be one of: `read` or `write`. + * @enum {string} + */ secrets?: "read" | "write"; - /** @description The level of permission to grant the access token to view and manage security events like code scanning alerts. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to view and manage security events like code scanning alerts. Can be one of: `read` or `write`. + * @enum {string} + */ security_events?: "read" | "write"; - /** @description The level of permission to grant the access token to manage just a single file. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to manage just a single file. Can be one of: `read` or `write`. + * @enum {string} + */ single_file?: "read" | "write"; - /** @description The level of permission to grant the access token for commit statuses. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token for commit statuses. Can be one of: `read` or `write`. + * @enum {string} + */ statuses?: "read" | "write"; - /** @description The level of permission to grant the access token to retrieve Dependabot alerts. Can be one of: `read`. */ + /** + * @description The level of permission to grant the access token to retrieve Dependabot alerts. Can be one of: `read`. + * @enum {string} + */ vulnerability_alerts?: "read"; - /** @description The level of permission to grant the access token to update GitHub Actions workflow files. Can be one of: `write`. */ + /** + * @description The level of permission to grant the access token to update GitHub Actions workflow files. Can be one of: `write`. + * @enum {string} + */ workflows?: "write"; - /** @description The level of permission to grant the access token for organization teams and members. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token for organization teams and members. Can be one of: `read` or `write`. + * @enum {string} + */ members?: "read" | "write"; - /** @description The level of permission to grant the access token to manage access to an organization. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to manage access to an organization. Can be one of: `read` or `write`. + * @enum {string} + */ organization_administration?: "read" | "write"; - /** @description The level of permission to grant the access token to manage the post-receive hooks for an organization. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to manage the post-receive hooks for an organization. Can be one of: `read` or `write`. + * @enum {string} + */ organization_hooks?: "read" | "write"; - /** @description The level of permission to grant the access token for viewing an organization's plan. Can be one of: `read`. */ + /** + * @description The level of permission to grant the access token for viewing an organization's plan. Can be one of: `read`. + * @enum {string} + */ organization_plan?: "read"; - /** @description The level of permission to grant the access token to manage organization projects, columns, and cards. Can be one of: `read`, `write`, or `admin`. */ + /** + * @description The level of permission to grant the access token to manage organization projects, columns, and cards. Can be one of: `read`, `write`, or `admin`. + * @enum {string} + */ organization_projects?: "read" | "write" | "admin"; - /** @description The level of permission to grant the access token to manage organization secrets. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to manage organization secrets. Can be one of: `read` or `write`. + * @enum {string} + */ organization_secrets?: "read" | "write"; - /** @description The level of permission to grant the access token to view and manage GitHub Actions self-hosted runners available to an organization. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to view and manage GitHub Actions self-hosted runners available to an organization. Can be one of: `read` or `write`. + * @enum {string} + */ organization_self_hosted_runners?: "read" | "write"; - /** @description The level of permission to grant the access token to view and manage users blocked by the organization. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to view and manage users blocked by the organization. Can be one of: `read` or `write`. + * @enum {string} + */ organization_user_blocking?: "read" | "write"; - /** @description The level of permission to grant the access token to manage team discussions and related comments. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to manage team discussions and related comments. Can be one of: `read` or `write`. + * @enum {string} + */ team_discussions?: "read" | "write"; } & { [key: string]: unknown }; /** @@ -5925,6 +6018,7 @@ export interface components { /** @example read */ single_file?: string; } & { [key: string]: unknown }; + /** @enum {string} */ repository_selection?: "all" | "selected"; repositories?: components["schemas"]["repository"][]; /** @example README.md */ @@ -5985,7 +6079,10 @@ export interface components { /** Scoped Installation */ "scoped-installation": { permissions: components["schemas"]["app-permissions"]; - /** @description Describe whether all repositories have been selected or there's a selection involved */ + /** + * @description Describe whether all repositories have been selected or there's a selection involved + * @enum {string} + */ repository_selection: "all" | "selected"; /** @example config.yaml */ single_file_name: string | null; @@ -6124,9 +6221,15 @@ export interface components { */ node_id?: string; } & { [key: string]: unknown }; - /** @description The policy that controls the organizations in the enterprise that are allowed to run GitHub Actions. Can be one of: `all`, `none`, or `selected`. */ + /** + * @description The policy that controls the organizations in the enterprise that are allowed to run GitHub Actions. Can be one of: `all`, `none`, or `selected`. + * @enum {string} + */ "enabled-organizations": "all" | "none" | "selected"; - /** @description The permissions policy that controls the actions that are allowed to run. Can be one of: `all`, `local_only`, or `selected`. */ + /** + * @description The permissions policy that controls the actions that are allowed to run. Can be one of: `all`, `local_only`, or `selected`. + * @enum {string} + */ "allowed-actions": "all" | "local_only" | "selected"; /** @description The API URL to use to get or set the actions that are allowed to run, when `allowed_actions` is set to `selected`. */ "selected-actions-url": string; @@ -6224,7 +6327,10 @@ export interface components { id?: number; /** @description Name of the label. */ name?: string; - /** @description The type of label. Read-only labels are applied automatically when the runner is configured. */ + /** + * @description The type of label. Read-only labels are applied automatically when the runner is configured. + * @enum {string} + */ type?: "read-only" | "custom"; } & { [key: string]: unknown })[]; } & { [key: string]: unknown }; @@ -6260,7 +6366,10 @@ export interface components { repositories?: components["schemas"]["repository"][]; /** @example config.yaml */ single_file?: string | null; - /** @description Describe whether all repositories have been selected or there's a selection involved */ + /** + * @description Describe whether all repositories have been selected or there's a selection involved + * @enum {string} + */ repository_selection?: "all" | "selected"; } & { [key: string]: unknown }; "audit-log-event": { @@ -6420,6 +6529,7 @@ export interface components { * @description The state of the milestone. * @default open * @example open + * @enum {string} */ state: "open" | "closed"; /** @@ -6459,6 +6569,7 @@ export interface components { * author_association * @description How the author is associated with the repository. * @example OWNER + * @enum {string} */ author_association: | "COLLABORATOR" @@ -7468,7 +7579,10 @@ export interface components { /** Format: date-time */ updated_at: string; } & { [key: string]: unknown }; - /** @description The policy that controls the repositories in the organization that are allowed to run GitHub Actions. Can be one of: `all`, `none`, or `selected`. */ + /** + * @description The policy that controls the repositories in the organization that are allowed to run GitHub Actions. Can be one of: `all`, `none`, or `selected`. + * @enum {string} + */ "enabled-repositories": "all" | "none" | "selected"; "actions-organization-permissions": { enabled_repositories: components["schemas"]["enabled-repositories"]; @@ -7503,7 +7617,10 @@ export interface components { created_at: string; /** Format: date-time */ updated_at: string; - /** @description Visibility of a secret */ + /** + * @description Visibility of a secret + * @enum {string} + */ visibility: "all" | "private" | "selected"; /** * Format: uri @@ -7663,6 +7780,7 @@ export interface components { /** * @description The type of GitHub user that can comment, open issues, or create pull requests while the interaction limit is in effect. Can be one of: `existing_users`, `contributors_only`, `collaborators_only`. * @example collaborators_only + * @enum {string} */ "interaction-group": "existing_users" | "contributors_only" | "collaborators_only"; /** @@ -7682,6 +7800,7 @@ export interface components { /** * @description The duration of the interaction restriction. Can be one of: `one_day`, `three_days`, `one_week`, `one_month`, `six_months`. Default: `one_day`. * @example one_month + * @enum {string} */ "interaction-expiry": "one_day" | "three_days" | "one_week" | "one_month" | "six_months"; /** @@ -7852,7 +7971,10 @@ export interface components { * @example super-linter */ name: string; - /** @example docker */ + /** + * @example docker + * @enum {string} + */ package_type: "npm" | "maven" | "rubygems" | "docker" | "nuget" | "container"; /** @example https://api.github.com/orgs/github/packages/container/super-linter */ url: string; @@ -7863,7 +7985,10 @@ export interface components { * @example 1 */ version_count: number; - /** @example private */ + /** + * @example private + * @enum {string} + */ visibility: "private" | "public"; owner?: (components["schemas"]["simple-user"] & { [key: string]: unknown }) | null; repository?: (components["schemas"]["minimal-repository"] & { [key: string]: unknown }) | null; @@ -7913,7 +8038,10 @@ export interface components { deleted_at?: string; /** Package Version Metadata */ metadata?: { - /** @example docker */ + /** + * @example docker + * @enum {string} + */ package_type: "npm" | "maven" | "rubygems" | "docker" | "nuget" | "container"; /** Container Metadata */ container?: { @@ -7984,7 +8112,10 @@ export interface components { * @example 2014-03-03T18:58:10Z */ updated_at: string; - /** @description The baseline permission that all organization members have on this project. Only present if owner is an organization. */ + /** + * @description The baseline permission that all organization members have on this project. Only present if owner is an organization. + * @enum {string} + */ organization_permission?: "read" | "write" | "admin" | "none"; /** @description Whether or not this project can be seen by everyone. Only present if owner is an organization. */ private?: boolean; @@ -8061,6 +8192,7 @@ export interface components { /** * @description The level of privacy this team should have * @example closed + * @enum {string} */ privacy?: "closed" | "secret"; /** @@ -8239,6 +8371,7 @@ export interface components { /** * @description The reaction to use * @example heart + * @enum {string} */ content: "+1" | "-1" | "laugh" | "confused" | "heart" | "hooray" | "rocket" | "eyes"; /** @@ -8258,6 +8391,7 @@ export interface components { * @description The role of the user in the team. * @default member * @example member + * @enum {string} */ role: "member" | "maintainer"; state: string; @@ -9007,6 +9141,7 @@ export interface components { /** * @description The phase of the lifecycle that the job is currently in. * @example queued + * @enum {string} */ status: "queued" | "in_progress" | "completed"; /** @@ -9036,6 +9171,7 @@ export interface components { /** * @description The phase of the lifecycle that the job is currently in. * @example queued + * @enum {string} */ status: "queued" | "in_progress" | "completed"; /** @@ -9252,6 +9388,7 @@ export interface components { /** * @description Whether deployment to the environment(s) was approved or rejected * @example approved + * @enum {string} */ state: "approved" | "rejected"; user: components["schemas"]["simple-user"]; @@ -9264,6 +9401,7 @@ export interface components { /** * @description The type of reviewer. Must be one of: `User` or `Team` * @example User + * @enum {string} */ "deployment-reviewer-type": "User" | "Team"; /** @@ -9434,7 +9572,10 @@ export interface components { name: string; /** @example ruby.yaml */ path: string; - /** @example active */ + /** + * @example active + * @enum {string} + */ state: "active" | "deleted"; /** * Format: date-time @@ -9948,9 +10089,13 @@ export interface components { /** * @description The phase of the lifecycle that the check is currently in. * @example queued + * @enum {string} */ status: "queued" | "in_progress" | "completed"; - /** @example neutral */ + /** + * @example neutral + * @enum {string|null} + */ conclusion: | ("success" | "failure" | "neutral" | "cancelled" | "skipped" | "timed_out" | "action_required") | null; @@ -10027,9 +10172,15 @@ export interface components { * @example 009b8a3a9ccbb128af87f9b1c0f4c62e8a304f6d */ head_sha: string; - /** @example completed */ + /** + * @example completed + * @enum {string|null} + */ status: ("queued" | "in_progress" | "completed") | null; - /** @example neutral */ + /** + * @example neutral + * @enum {string|null} + */ conclusion: | ("success" | "failure" | "neutral" | "cancelled" | "skipped" | "timed_out" | "action_required") | null; @@ -10069,7 +10220,10 @@ export interface components { "code-scanning-analysis-tool-guid": string | null; /** @description The full Git reference, formatted as `refs/heads/`. */ "code-scanning-ref": string; - /** @description State of a code scanning alert. */ + /** + * @description State of a code scanning alert. + * @enum {string} + */ "code-scanning-alert-state": "open" | "dismissed" | "fixed"; /** @description The security alert number. */ "alert-number": number; @@ -10105,7 +10259,10 @@ export interface components { id?: string | null; /** @description The name of the rule used to detect the alert. */ name?: string; - /** @description The severity of the alert. */ + /** + * @description The severity of the alert. + * @enum {string|null} + */ severity?: ("none" | "note" | "warning" | "error") | null; /** @description A short description of the rule used to detect the alert. */ description?: string; @@ -10129,7 +10286,10 @@ export interface components { start_column?: number; end_column?: number; } & { [key: string]: unknown }; - /** @description A classification of the file. For example to identify it as generated. */ + /** + * @description A classification of the file. For example to identify it as generated. + * @enum {string|null} + */ "code-scanning-alert-classification": ("source" | "generated" | "test" | "library") | null; "code-scanning-alert-instance": { ref?: components["schemas"]["code-scanning-ref"]; @@ -10167,7 +10327,10 @@ export interface components { id?: string | null; /** @description The name of the rule used to detect the alert. */ name?: string; - /** @description The severity of the alert. */ + /** + * @description The severity of the alert. + * @enum {string|null} + */ severity?: ("none" | "note" | "warning" | "error") | null; /** @description A short description of the rule used to detect the alert. */ description?: string; @@ -10192,7 +10355,10 @@ export interface components { tool: components["schemas"]["code-scanning-analysis-tool"]; most_recent_instance: components["schemas"]["code-scanning-alert-instance"]; } & { [key: string]: unknown }; - /** @description Sets the state of the code scanning alert. Can be one of `open` or `dismissed`. You must provide `dismissed_reason` when you set the state to `dismissed`. */ + /** + * @description Sets the state of the code scanning alert. Can be one of `open` or `dismissed`. You must provide `dismissed_reason` when you set the state to `dismissed`. + * @enum {string} + */ "code-scanning-alert-set-state": "open" | "dismissed"; /** * @description An identifier for the upload. @@ -10271,7 +10437,10 @@ export interface components { url?: string; } & { [key: string]: unknown }; "code-scanning-sarifs-status": { - /** @description `pending` files have not yet been processed, while `complete` means all results in the SARIF have been stored. */ + /** + * @description `pending` files have not yet been processed, while `complete` means all results in the SARIF have been stored. + * @enum {string} + */ processing_status?: "pending" | "complete"; /** * Format: uri @@ -10365,6 +10534,7 @@ export interface components { /** * @description The permission associated with the invitation. * @example read + * @enum {string} */ permissions: "read" | "write" | "admin"; /** @@ -10433,7 +10603,10 @@ export interface components { auto_merge: | ({ enabled_by: components["schemas"]["simple-user"]; - /** @description The merge method to use. */ + /** + * @description The merge method to use. + * @enum {string} + */ merge_method: "merge" | "squash" | "rebase"; /** @description Title for the merge commit message. */ commit_title: string; @@ -10729,7 +10902,10 @@ export interface components { patch_url: string; base_commit: components["schemas"]["commit"]; merge_base_commit: components["schemas"]["commit"]; - /** @example ahead */ + /** + * @example ahead + * @enum {string} + */ status: "diverged" | "ahead" | "behind" | "identical"; /** @example 4 */ ahead_by: number; @@ -11020,6 +11196,7 @@ export interface components { /** * @description The state of the status. * @example success + * @enum {string} */ state: "error" | "failure" | "inactive" | "pending" | "success" | "queued" | "in_progress"; creator: (components["schemas"]["simple-user"] & { [key: string]: unknown }) | null; @@ -11440,6 +11617,7 @@ export interface components { vcs_url: string; svc_root?: string; tfvc_project?: string; + /** @enum {string} */ status: | "auth" | "error" @@ -11698,6 +11876,7 @@ export interface components { /** * @description The status of the most recent build of the Page. * @example built + * @enum {string|null} */ status: ("built" | "building" | "errored") | null; /** @@ -11816,6 +11995,7 @@ export interface components { /** * @description State of this Pull Request. Either `open` or `closed`. * @example open + * @enum {string} */ state: "open" | "closed"; /** @example true */ @@ -12373,6 +12553,7 @@ export interface components { /** * @description The side of the first line of the range for a multi-line comment. * @default RIGHT + * @enum {string|null} */ start_side?: ("LEFT" | "RIGHT") | null; /** @@ -12388,6 +12569,7 @@ export interface components { /** * @description The side of the diff to which the comment applies. The side of the last line of the range for a multi-line comment * @default RIGHT + * @enum {string} */ side?: "LEFT" | "RIGHT"; reactions?: components["schemas"]["reaction-rollup"]; @@ -12526,11 +12708,13 @@ export interface components { /** * @description The side of the first line of the range for a multi-line comment. * @default RIGHT + * @enum {string} */ side?: "LEFT" | "RIGHT"; /** * @description The side of the first line of the range for a multi-line comment. * @default RIGHT + * @enum {string|null} */ start_side?: ("LEFT" | "RIGHT") | null; /** @@ -12571,7 +12755,10 @@ export interface components { */ name: string; label: string | null; - /** @description State of the release asset. */ + /** + * @description State of the release asset. + * @enum {string} + */ state: "uploaded" | "open"; content_type: string; size: number; @@ -12625,7 +12812,10 @@ export interface components { body_html?: string; body_text?: string; } & { [key: string]: unknown }; - /** @description Sets the state of the secret scanning alert. Can be either `open` or `resolved`. You must provide `resolution` when you set the state to `resolved`. */ + /** + * @description Sets the state of the secret scanning alert. Can be either `open` or `resolved`. You must provide `resolution` when you set the state to `resolved`. + * @enum {string} + */ "secret-scanning-alert-state": "open" | "resolved"; /** @description **Required when the `state` is `resolved`.** The reason for resolving the alert. Can be one of `false_positive`, `wont_fix`, `revoked`, or `used_in_tests`. */ "secret-scanning-alert-resolution": string | null; @@ -12977,6 +13167,7 @@ export interface components { * @example [object Object] */ operations?: ({ + /** @enum {string} */ op: "add" | "remove" | "replace"; path?: string; value?: (string | { [key: string]: unknown } | unknown[]) & { [key: string]: unknown }; @@ -15292,7 +15483,10 @@ export interface operations { "application/json": { /** @description Name of the runner group. */ name: string; - /** @description Visibility of a runner group. You can select all organizations or select individual organization. Can be one of: `all` or `selected` */ + /** + * @description Visibility of a runner group. You can select all organizations or select individual organization. Can be one of: `all` or `selected` + * @enum {string} + */ visibility?: "selected" | "all"; /** @description List of organization IDs that can access the runner group. */ selected_organization_ids?: number[]; @@ -15374,6 +15568,7 @@ export interface operations { /** * @description Visibility of a runner group. You can select all organizations or select individual organizations. Can be one of: `all` or `selected` * @default all + * @enum {string} */ visibility?: "selected" | "all"; } & { [key: string]: unknown }; @@ -16563,6 +16758,7 @@ export interface operations { * @description The rendering mode. * @default markdown * @example markdown + * @enum {string} */ mode?: "markdown" | "gfm"; /** @description The repository context to use when creating references in `gfm` mode. */ @@ -17099,6 +17295,7 @@ export interface operations { * \* `admin` - can pull, push, and administer this repository. * \* `none` - no permissions granted by default. * @default read + * @enum {string} */ default_repository_permission?: "read" | "write" | "admin" | "none"; /** @@ -17137,6 +17334,7 @@ export interface operations { * \* `private` - members can create private repositories. This option is only available to repositories that are part of an organization on GitHub Enterprise Cloud. * \* `none` - only admin members can create repositories. * **Note:** This parameter is deprecated and will be removed in the future. Its return value ignores internal repositories. Using this parameter overrides values set in `members_can_create_repositories`. See the parameter deprecation notice in the operation description for details. + * @enum {string} */ members_allowed_repository_creation_type?: "all" | "private" | "none"; /** @@ -17404,6 +17602,7 @@ export interface operations { /** * @description Visibility of a runner group. You can select all repositories, select individual repositories, or limit access to private repositories. Can be one of: `all`, `selected`, or `private`. * @default all + * @enum {string} */ visibility?: "selected" | "all" | "private"; /** @description List of repository IDs that can access the runner group. */ @@ -17486,7 +17685,10 @@ export interface operations { "application/json": { /** @description Name of the runner group. */ name?: string; - /** @description Visibility of a runner group. You can select all repositories, select individual repositories, or all private repositories. Can be one of: `all`, `selected`, or `private`. */ + /** + * @description Visibility of a runner group. You can select all repositories, select individual repositories, or all private repositories. Can be one of: `all`, `selected`, or `private`. + * @enum {string} + */ visibility?: "selected" | "all" | "private"; } & { [key: string]: unknown }; }; @@ -18011,6 +18213,7 @@ export interface operations { * \- `all` - All repositories in an organization can access the secret. * \- `private` - Private repositories in an organization can access the secret. * \- `selected` - Only specific repositories can access the secret. + * @enum {string} */ visibility?: "all" | "private" | "selected"; /** @description An array of repository ids that can access the organization secret. You can only provide a list of repository ids when the `visibility` is set to `selected`. You can manage the list of selected repositories using the [List selected repositories for an organization secret](https://docs.github.com/rest/reference/actions#list-selected-repositories-for-an-organization-secret), [Set selected repositories for an organization secret](https://docs.github.com/rest/reference/actions#set-selected-repositories-for-an-organization-secret), and [Remove selected repository from an organization secret](https://docs.github.com/rest/reference/actions#remove-selected-repository-from-an-organization-secret) endpoints. */ @@ -18669,6 +18872,7 @@ export interface operations { * \* `direct_member` - Non-owner organization members with ability to see other members and join teams by invitation. * \* `billing_manager` - Non-owner organization members with ability to manage the billing settings of your organization. * @default direct_member + * @enum {string} */ role?: "admin" | "direct_member" | "billing_manager"; /** @description Specify IDs for the teams you want to invite new members to. */ @@ -18898,6 +19102,7 @@ export interface operations { * \* `admin` - The user will become an owner of the organization. * \* `member` - The user will become a non-owner member of the organization. * @default member + * @enum {string} */ role?: "admin" | "member"; } & { [key: string]: unknown }; @@ -19547,6 +19752,7 @@ export interface operations { /** * @description Can be `public` or `private`. If your organization is associated with an enterprise account using GitHub Enterprise Cloud or GitHub Enterprise Server 2.20+, `visibility` can also be `internal`. For more information, see "[Creating an internal repository](https://help.github.com/en/github/creating-cloning-and-archiving-repositories/about-repository-visibility#about-internal-repositories)" in the GitHub Help documentation. * The `visibility` parameter overrides the `private` parameter when you use both parameters with the `nebula-preview` preview header. + * @enum {string} */ visibility?: "public" | "private" | "visibility" | "internal"; /** @@ -19757,6 +19963,7 @@ export interface operations { * **For a parent or child team:** * \* `closed` - visible to all members of this organization. * Default for child team: `closed` + * @enum {string} */ privacy?: "secret" | "closed"; /** @@ -19765,6 +19972,7 @@ export interface operations { * \* `push` - team members can pull and push, but not administer newly-added repositories. * \* `admin` - team members can pull, push and administer newly-added repositories. * @default pull + * @enum {string} */ permission?: "pull" | "push" | "admin"; /** @description The ID of a team to set as the parent team. */ @@ -19851,6 +20059,7 @@ export interface operations { * \* `closed` - visible to all members of this organization. * **For a parent or child team:** * \* `closed` - visible to all members of this organization. + * @enum {string} */ privacy?: "secret" | "closed"; /** @@ -19859,6 +20068,7 @@ export interface operations { * \* `push` - team members can pull and push, but not administer newly-added repositories. * \* `admin` - team members can pull, push and administer newly-added repositories. * @default pull + * @enum {string} */ permission?: "pull" | "push" | "admin"; /** @description The ID of a team to set as the parent team. */ @@ -20209,7 +20419,10 @@ export interface operations { requestBody: { content: { "application/json": { - /** @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the team discussion comment. */ + /** + * @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the team discussion comment. + * @enum {string} + */ content: "+1" | "-1" | "laugh" | "confused" | "heart" | "hooray" | "rocket" | "eyes"; } & { [key: string]: unknown }; }; @@ -20293,7 +20506,10 @@ export interface operations { requestBody: { content: { "application/json": { - /** @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the team discussion. */ + /** + * @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the team discussion. + * @enum {string} + */ content: "+1" | "-1" | "laugh" | "confused" | "heart" | "hooray" | "rocket" | "eyes"; } & { [key: string]: unknown }; }; @@ -20466,6 +20682,7 @@ export interface operations { * \* `member` - a normal member of the team. * \* `maintainer` - a team maintainer. Able to add/remove other team members, promote other team members to team maintainer, and edit the team's name and description. * @default member + * @enum {string} */ role?: "member" | "maintainer"; } & { [key: string]: unknown }; @@ -20588,6 +20805,7 @@ export interface operations { * \* `write` - team members can read and write, but not administer this project. * \* `admin` - team members can read, write and administer this project. * Default: the team's `permission` attribute will be used to determine what permission to grant the team on this project. Note that, if you choose not to pass any parameters, you'll need to set `Content-Length` to zero when calling out to this endpoint. For more information, see "[HTTP verbs](https://docs.github.com/rest/overview/resources-in-the-rest-api#http-verbs)." + * @enum {string} */ permission?: "read" | "write" | "admin"; } & { [key: string]: unknown }) @@ -20708,6 +20926,7 @@ export interface operations { * \* `triage` - team members can proactively manage issues and pull requests without write access. Recommended for contributors who triage a repository. Only applies to repositories owned by organizations. * * If no permission is specified, the team's `permission` attribute will be used to determine what permission to grant the team on this repository. + * @enum {string} */ permission?: "pull" | "push" | "admin" | "maintain" | "triage"; } & { [key: string]: unknown }; @@ -21259,7 +21478,10 @@ export interface operations { * @example open */ state?: string; - /** @description The baseline permission that all organization members have on this project */ + /** + * @description The baseline permission that all organization members have on this project + * @enum {string} + */ organization_permission?: "read" | "write" | "admin" | "none"; /** @description Whether or not this project can be seen by everyone. */ private?: boolean; @@ -21328,6 +21550,7 @@ export interface operations { * @description The permission to grant the collaborator. * @default write * @example write + * @enum {string} */ permission?: "read" | "write" | "admin"; } & { [key: string]: unknown }; @@ -21556,7 +21779,10 @@ export interface operations { * **Note**: You will get a `422` error if the organization restricts [changing repository visibility](https://help.github.com/articles/repository-permission-levels-for-an-organization#changing-the-visibility-of-repositories) to organization owners and a non-owner tries to change the value of private. **Note**: You will get a `422` error if the organization restricts [changing repository visibility](https://help.github.com/articles/repository-permission-levels-for-an-organization#changing-the-visibility-of-repositories) to organization owners and a non-owner tries to change the value of private. */ private?: boolean; - /** @description Can be `public` or `private`. If your organization is associated with an enterprise account using GitHub Enterprise Cloud or GitHub Enterprise Server 2.20+, `visibility` can also be `internal`. The `visibility` parameter overrides the `private` parameter when you use both along with the `nebula-preview` preview header. */ + /** + * @description Can be `public` or `private`. If your organization is associated with an enterprise account using GitHub Enterprise Cloud or GitHub Enterprise Server 2.20+, `visibility` can also be `internal`. The `visibility` parameter overrides the `private` parameter when you use both along with the `nebula-preview` preview header. + * @enum {string} + */ visibility?: "public" | "private" | "visibility" | "internal"; /** * @description Either `true` to enable issues for this repository or `false` to disable them. @@ -22231,6 +22457,7 @@ export interface operations { /** * @description Whether to approve or reject deployment to the specified environments. Must be one of: `approved` or `rejected` * @example approved + * @enum {string} */ state: "approved" | "rejected"; /** @@ -23785,6 +24012,7 @@ export interface operations { content: { "application/json": (Partial< { + /** @enum {undefined} */ status?: "completed"; } & { conclusion: unknown; @@ -23792,6 +24020,7 @@ export interface operations { > & Partial< { + /** @enum {undefined} */ status?: "queued" | "in_progress"; } & { [key: string]: unknown } >) & { @@ -23806,6 +24035,7 @@ export interface operations { /** * @description The current status. Can be one of `queued`, `in_progress`, or `completed`. * @default queued + * @enum {string} */ status?: "queued" | "in_progress" | "completed"; /** @description The time that the check run began. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`. */ @@ -23813,6 +24043,7 @@ export interface operations { /** * @description **Required if you provide `completed_at` or a `status` of `completed`**. The final conclusion of the check. Can be one of `action_required`, `cancelled`, `failure`, `neutral`, `success`, `skipped`, `stale`, or `timed_out`. When the conclusion is `action_required`, additional details should be provided on the site specified by `details_url`. * **Note:** Providing `conclusion` will automatically set the `status` parameter to `completed`. You cannot change a check run conclusion to `stale`, only GitHub can set this. + * @enum {string} */ conclusion?: | "action_required" @@ -23845,7 +24076,10 @@ export interface operations { start_column?: number; /** @description The end column of the annotation. Annotations only support `start_column` and `end_column` on the same line. Omit this parameter if `start_line` and `end_line` have different values. */ end_column?: number; - /** @description The level of the annotation. Can be one of `notice`, `warning`, or `failure`. */ + /** + * @description The level of the annotation. Can be one of `notice`, `warning`, or `failure`. + * @enum {string} + */ annotation_level: "notice" | "warning" | "failure"; /** @description A short description of the feedback for these lines of code. The maximum size is 64 KB. */ message: string; @@ -23926,6 +24160,7 @@ export interface operations { content: { "application/json": (Partial< { + /** @enum {undefined} */ status?: "completed"; } & { conclusion: unknown; @@ -23933,6 +24168,7 @@ export interface operations { > & Partial< { + /** @enum {undefined} */ status?: "queued" | "in_progress"; } & { [key: string]: unknown } >) & { @@ -23944,11 +24180,15 @@ export interface operations { external_id?: string; /** @description This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`. */ started_at?: string; - /** @description The current status. Can be one of `queued`, `in_progress`, or `completed`. */ + /** + * @description The current status. Can be one of `queued`, `in_progress`, or `completed`. + * @enum {string} + */ status?: "queued" | "in_progress" | "completed"; /** * @description **Required if you provide `completed_at` or a `status` of `completed`**. The final conclusion of the check. Can be one of `action_required`, `cancelled`, `failure`, `neutral`, `success`, `skipped`, `stale`, or `timed_out`. * **Note:** Providing `conclusion` will automatically set the `status` parameter to `completed`. You cannot change a check run conclusion to `stale`, only GitHub can set this. + * @enum {string} */ conclusion?: | "action_required" @@ -23981,7 +24221,10 @@ export interface operations { start_column?: number; /** @description The end column of the annotation. Annotations only support `start_column` and `end_column` on the same line. Omit this parameter if `start_line` and `end_line` have different values. */ end_column?: number; - /** @description The level of the annotation. Can be one of `notice`, `warning`, or `failure`. */ + /** + * @description The level of the annotation. Can be one of `notice`, `warning`, or `failure`. + * @enum {string} + */ annotation_level: "notice" | "warning" | "failure"; /** @description A short description of the feedback for these lines of code. The maximum size is 64 KB. */ message: string; @@ -24685,6 +24928,7 @@ export interface operations { * \* `maintain` - Recommended for project managers who need to manage the repository without access to sensitive or destructive actions. * \* `triage` - Recommended for contributors who need to proactively manage issues and pull requests without write access. * @default push + * @enum {string} */ permission?: "pull" | "push" | "admin" | "maintain" | "triage"; /** @example "push" */ @@ -24873,7 +25117,10 @@ export interface operations { requestBody: { content: { "application/json": { - /** @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the commit comment. */ + /** + * @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the commit comment. + * @enum {string} + */ content: "+1" | "-1" | "laugh" | "confused" | "heart" | "hooray" | "rocket" | "eyes"; } & { [key: string]: unknown }; }; @@ -25867,7 +26114,10 @@ export interface operations { requestBody: { content: { "application/json": { - /** @description The state of the status. Can be one of `error`, `failure`, `inactive`, `in_progress`, `queued` `pending`, or `success`. **Note:** To use the `inactive` state, you must provide the [`application/vnd.github.ant-man-preview+json`](https://docs.github.com/rest/overview/api-previews#enhanced-deployments) custom media type. To use the `in_progress` and `queued` states, you must provide the [`application/vnd.github.flash-preview+json`](https://docs.github.com/rest/overview/api-previews#deployment-statuses) custom media type. When you set a transient deployment to `inactive`, the deployment will be shown as `destroyed` in GitHub. */ + /** + * @description The state of the status. Can be one of `error`, `failure`, `inactive`, `in_progress`, `queued` `pending`, or `success`. **Note:** To use the `inactive` state, you must provide the [`application/vnd.github.ant-man-preview+json`](https://docs.github.com/rest/overview/api-previews#enhanced-deployments) custom media type. To use the `in_progress` and `queued` states, you must provide the [`application/vnd.github.flash-preview+json`](https://docs.github.com/rest/overview/api-previews#deployment-statuses) custom media type. When you set a transient deployment to `inactive`, the deployment will be shown as `destroyed` in GitHub. + * @enum {string} + */ state: "error" | "failure" | "inactive" | "in_progress" | "queued" | "pending" | "success"; /** @description The target URL to associate with this status. This URL should contain output to keep the user updated while the task is running or serve as historical information for what happened in the deployment. **Note:** It's recommended to use the `log_url` parameter, which replaces `target_url`. */ target_url?: string; @@ -25878,7 +26128,10 @@ export interface operations { log_url?: string; /** @description A short description of the status. The maximum description length is 140 characters. */ description?: string; - /** @description Name for the target deployment environment, which can be changed when setting a deploy status. For example, `production`, `staging`, or `qa`. **Note:** This parameter requires you to use the [`application/vnd.github.flash-preview+json`](https://docs.github.com/rest/overview/api-previews#deployment-statuses) custom media type. */ + /** + * @description Name for the target deployment environment, which can be changed when setting a deploy status. For example, `production`, `staging`, or `qa`. **Note:** This parameter requires you to use the [`application/vnd.github.flash-preview+json`](https://docs.github.com/rest/overview/api-previews#deployment-statuses) custom media type. + * @enum {string} + */ environment?: "production" | "staging" | "qa"; /** * @description Sets the URL for accessing your environment. Default: `""` @@ -26537,7 +26790,10 @@ export interface operations { message: string; /** @description The SHA of the git object this is tagging. */ object: string; - /** @description The type of the object we're tagging. Normally this is a `commit` but it can also be a `tree` or a `blob`. */ + /** + * @description The type of the object we're tagging. Normally this is a `commit` but it can also be a `tree` or a `blob`. + * @enum {string} + */ type: "commit" | "tree" | "blob"; /** @description An object with information about the individual creating the tag. */ tagger?: { @@ -26633,9 +26889,15 @@ export interface operations { tree: ({ /** @description The file referenced in the tree. */ path?: string; - /** @description The file mode; one of `100644` for file (blob), `100755` for executable (blob), `040000` for subdirectory (tree), `160000` for submodule (commit), or `120000` for a blob that specifies the path of a symlink. */ + /** + * @description The file mode; one of `100644` for file (blob), `100755` for executable (blob), `040000` for subdirectory (tree), `160000` for submodule (commit), or `120000` for a blob that specifies the path of a symlink. + * @enum {string} + */ mode?: "100644" | "100755" | "040000" | "160000" | "120000"; - /** @description Either `blob`, `tree`, or `commit`. */ + /** + * @description Either `blob`, `tree`, or `commit`. + * @enum {string} + */ type?: "blob" | "tree" | "commit"; /** * @description The SHA1 checksum ID of the object in the tree. Also called `tree.sha`. If the value is `null` then the file will be deleted. @@ -27017,7 +27279,10 @@ export interface operations { "application/json": { /** @description The URL of the originating repository. */ vcs_url: string; - /** @description The originating VCS type. Can be one of `subversion`, `git`, `mercurial`, or `tfvc`. Please be aware that without this parameter, the import job will take additional time to detect the VCS type before beginning the import. This detection step will be reflected in the response. */ + /** + * @description The originating VCS type. Can be one of `subversion`, `git`, `mercurial`, or `tfvc`. Please be aware that without this parameter, the import job will take additional time to detect the VCS type before beginning the import. This detection step will be reflected in the response. + * @enum {string} + */ vcs?: "subversion" | "git" | "mercurial" | "tfvc"; /** @description If authentication is required, the username to provide to `vcs_url`. */ vcs_username?: string; @@ -27171,7 +27436,10 @@ export interface operations { requestBody: { content: { "application/json": { - /** @description Can be one of `opt_in` (large files will be stored using Git LFS) or `opt_out` (large files will be removed during the import). */ + /** + * @description Can be one of `opt_in` (large files will be stored using Git LFS) or `opt_out` (large files will be removed during the import). + * @enum {string} + */ use_lfs: "opt_in" | "opt_out"; } & { [key: string]: unknown }; }; @@ -27314,7 +27582,10 @@ export interface operations { requestBody: { content: { "application/json": { - /** @description The permissions that the associated user will have on the repository. Valid values are `read`, `write`, `maintain`, `triage`, and `admin`. */ + /** + * @description The permissions that the associated user will have on the repository. Valid values are `read`, `write`, `maintain`, `triage`, and `admin`. + * @enum {string} + */ permissions?: "read" | "write" | "maintain" | "triage" | "admin"; } & { [key: string]: unknown }; }; @@ -27577,7 +27848,10 @@ export interface operations { requestBody: { content: { "application/json": { - /** @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the issue comment. */ + /** + * @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the issue comment. + * @enum {string} + */ content: "+1" | "-1" | "laugh" | "confused" | "heart" | "hooray" | "rocket" | "eyes"; } & { [key: string]: unknown }; }; @@ -27715,7 +27989,10 @@ export interface operations { body?: string | null; /** @description Login for the user that this issue should be assigned to. **This field is deprecated.** */ assignee?: string | null; - /** @description State of the issue. Either `open` or `closed`. */ + /** + * @description State of the issue. Either `open` or `closed`. + * @enum {string} + */ state?: "open" | "closed"; milestone?: ((string | number) & { [key: string]: unknown }) | null; /** @description Labels to associate with this issue. Pass one or more Labels to _replace_ the set of Labels on this Issue. Send an empty array (`[]`) to clear all Labels from the Issue. _NOTE: Only users with push access can set labels for issues. Labels are silently dropped otherwise._ */ @@ -28030,6 +28307,7 @@ export interface operations { * \* `too heated` * \* `resolved` * \* `spam` + * @enum {string} */ lock_reason?: "off-topic" | "too heated" | "resolved" | "spam"; } & { [key: string]: unknown }) @@ -28108,7 +28386,10 @@ export interface operations { requestBody: { content: { "application/json": { - /** @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the issue. */ + /** + * @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the issue. + * @enum {string} + */ content: "+1" | "-1" | "laugh" | "confused" | "heart" | "hooray" | "rocket" | "eyes"; } & { [key: string]: unknown }; }; @@ -28519,6 +28800,7 @@ export interface operations { /** * @description The state of the milestone. Either `open` or `closed`. * @default open + * @enum {string} */ state?: "open" | "closed"; /** @description A description of the milestone. */ @@ -28588,6 +28870,7 @@ export interface operations { /** * @description The state of the milestone. Either `open` or `closed`. * @default open + * @enum {string} */ state?: "open" | "closed"; /** @description A description of the milestone. */ @@ -28719,7 +29002,10 @@ export interface operations { { /** @description The repository branch used to publish your site's source files. */ branch: string; - /** @description The repository directory that includes the source files for the Pages site. Allowed paths are `/` or `/docs`. */ + /** + * @description The repository directory that includes the source files for the Pages site. Allowed paths are `/` or `/docs`. + * @enum {string} + */ path: "/" | "/docs"; } & { [key: string]: unknown } >) & { [key: string]: unknown }; @@ -28756,6 +29042,7 @@ export interface operations { /** * @description The repository directory that includes the source files for the Pages site. Allowed paths are `/` or `/docs`. Default: `/` * @default / + * @enum {string} */ path?: "/" | "/docs"; } & { [key: string]: unknown }; @@ -29156,7 +29443,10 @@ export interface operations { requestBody: { content: { "application/json": { - /** @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the pull request review comment. */ + /** + * @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the pull request review comment. + * @enum {string} + */ content: "+1" | "-1" | "laugh" | "confused" | "heart" | "hooray" | "rocket" | "eyes"; } & { [key: string]: unknown }; }; @@ -29249,7 +29539,10 @@ export interface operations { title?: string; /** @description The contents of the pull request. */ body?: string; - /** @description State of this Pull Request. Either `open` or `closed`. */ + /** + * @description State of this Pull Request. Either `open` or `closed`. + * @enum {string} + */ state?: "open" | "closed"; /** @description The name of the branch you want your changes pulled into. This should be an existing branch on the current repository. You cannot update the base branch on a pull request to point to another repository. */ base?: string; @@ -29331,13 +29624,19 @@ export interface operations { path?: string; /** @description **Required without `comfort-fade` preview**. The position in the diff where you want to add a review comment. Note this value is not the same as the line number in the file. For help finding the position value, read the note above. */ position?: number; - /** @description **Required with `comfort-fade` preview**. In a split diff view, the side of the diff that the pull request's changes appear on. Can be `LEFT` or `RIGHT`. Use `LEFT` for deletions that appear in red. Use `RIGHT` for additions that appear in green or unchanged lines that appear in white and are shown for context. For a multi-line comment, side represents whether the last line of the comment range is a deletion or addition. For more information, see "[Diff view options](https://help.github.com/en/articles/about-comparing-branches-in-pull-requests#diff-view-options)" in the GitHub Help documentation. */ + /** + * @description **Required with `comfort-fade` preview**. In a split diff view, the side of the diff that the pull request's changes appear on. Can be `LEFT` or `RIGHT`. Use `LEFT` for deletions that appear in red. Use `RIGHT` for additions that appear in green or unchanged lines that appear in white and are shown for context. For a multi-line comment, side represents whether the last line of the comment range is a deletion or addition. For more information, see "[Diff view options](https://help.github.com/en/articles/about-comparing-branches-in-pull-requests#diff-view-options)" in the GitHub Help documentation. + * @enum {string} + */ side?: "LEFT" | "RIGHT"; /** @description **Required with `comfort-fade` preview**. The line of the blob in the pull request diff that the comment applies to. For a multi-line comment, the last line of the range that your comment applies to. */ line?: number; /** @description **Required when using multi-line comments**. To create multi-line comments, you must use the `comfort-fade` preview header. The `start_line` is the first line in the pull request diff that your multi-line comment applies to. To learn more about multi-line comments, see "[Commenting on a pull request](https://help.github.com/en/articles/commenting-on-a-pull-request#adding-line-comments-to-a-pull-request)" in the GitHub Help documentation. */ start_line?: number; - /** @description **Required when using multi-line comments**. To create multi-line comments, you must use the `comfort-fade` preview header. The `start_side` is the starting side of the diff that the comment applies to. Can be `LEFT` or `RIGHT`. To learn more about multi-line comments, see "[Commenting on a pull request](https://help.github.com/en/articles/commenting-on-a-pull-request#adding-line-comments-to-a-pull-request)" in the GitHub Help documentation. See `side` in this table for additional context. */ + /** + * @description **Required when using multi-line comments**. To create multi-line comments, you must use the `comfort-fade` preview header. The `start_side` is the starting side of the diff that the comment applies to. Can be `LEFT` or `RIGHT`. To learn more about multi-line comments, see "[Commenting on a pull request](https://help.github.com/en/articles/commenting-on-a-pull-request#adding-line-comments-to-a-pull-request)" in the GitHub Help documentation. See `side` in this table for additional context. + * @enum {string} + */ start_side?: "LEFT" | "RIGHT" | "side"; /** @example 2 */ in_reply_to?: number; @@ -29496,7 +29795,10 @@ export interface operations { commit_message?: string; /** @description SHA that pull request head must match to allow merge. */ sha?: string; - /** @description Merge method to use. Possible values are `merge`, `squash` or `rebase`. Default is `merge`. */ + /** + * @description Merge method to use. Possible values are `merge`, `squash` or `rebase`. Default is `merge`. + * @enum {string} + */ merge_method?: "merge" | "squash" | "rebase"; } & { [key: string]: unknown }) | null; @@ -29641,7 +29943,10 @@ export interface operations { commit_id?: string; /** @description **Required** when using `REQUEST_CHANGES` or `COMMENT` for the `event` parameter. The body text of the pull request review. */ body?: string; - /** @description The review action you want to perform. The review actions include: `APPROVE`, `REQUEST_CHANGES`, or `COMMENT`. By leaving this blank, you set the review action state to `PENDING`, which means you will need to [submit the pull request review](https://docs.github.com/rest/reference/pulls#submit-a-review-for-a-pull-request) when you are ready. */ + /** + * @description The review action you want to perform. The review actions include: `APPROVE`, `REQUEST_CHANGES`, or `COMMENT`. By leaving this blank, you set the review action state to `PENDING`, which means you will need to [submit the pull request review](https://docs.github.com/rest/reference/pulls#submit-a-review-for-a-pull-request) when you are ready. + * @enum {string} + */ event?: "APPROVE" | "REQUEST_CHANGES" | "COMMENT"; /** @description Use the following table to specify the location, destination, and contents of the draft review comment. */ comments?: ({ @@ -29820,7 +30125,10 @@ export interface operations { "application/json": { /** @description The body text of the pull request review */ body?: string; - /** @description The review action you want to perform. The review actions include: `APPROVE`, `REQUEST_CHANGES`, or `COMMENT`. When you leave this blank, the API returns _HTTP 422 (Unrecognizable entity)_ and sets the review action state to `PENDING`, which means you will need to re-submit the pull request review using a review action. */ + /** + * @description The review action you want to perform. The review actions include: `APPROVE`, `REQUEST_CHANGES`, or `COMMENT`. When you leave this blank, the API returns _HTTP 422 (Unrecognizable entity)_ and sets the review action state to `PENDING`, which means you will need to re-submit the pull request review using a review action. + * @enum {string} + */ event: "APPROVE" | "REQUEST_CHANGES" | "COMMENT"; } & { [key: string]: unknown }; }; @@ -30472,7 +30780,10 @@ export interface operations { requestBody: { content: { "application/json": { - /** @description The state of the status. Can be one of `error`, `failure`, `pending`, or `success`. */ + /** + * @description The state of the status. Can be one of `error`, `failure`, `pending`, or `success`. + * @enum {string} + */ state: "error" | "failure" | "pending" | "success"; /** * @description The target URL to associate with this status. This URL will be linked from the GitHub UI to allow users to easily see the source of the status. @@ -31763,6 +32074,7 @@ export interface operations { * @example [object Object] */ Operations: ({ + /** @enum {string} */ op: "add" | "remove" | "replace"; path?: string; value?: ( @@ -32170,6 +32482,7 @@ export interface operations { * \* `closed` - visible to all members of this organization. * **For a parent or child team:** * \* `closed` - visible to all members of this organization. + * @enum {string} */ privacy?: "secret" | "closed"; /** @@ -32178,6 +32491,7 @@ export interface operations { * \* `push` - team members can pull and push, but not administer newly-added repositories. * \* `admin` - team members can pull, push and administer newly-added repositories. * @default pull + * @enum {string} */ permission?: "pull" | "push" | "admin"; /** @description The ID of a team to set as the parent team. */ @@ -32504,7 +32818,10 @@ export interface operations { requestBody: { content: { "application/json": { - /** @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the team discussion comment. */ + /** + * @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the team discussion comment. + * @enum {string} + */ content: "+1" | "-1" | "laugh" | "confused" | "heart" | "hooray" | "rocket" | "eyes"; } & { [key: string]: unknown }; }; @@ -32563,7 +32880,10 @@ export interface operations { requestBody: { content: { "application/json": { - /** @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the team discussion. */ + /** + * @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the team discussion. + * @enum {string} + */ content: "+1" | "-1" | "laugh" | "confused" | "heart" | "hooray" | "rocket" | "eyes"; } & { [key: string]: unknown }; }; @@ -32800,6 +33120,7 @@ export interface operations { * \* `member` - a normal member of the team. * \* `maintainer` - a team maintainer. Able to add/remove other team members, promote other team members to team maintainer, and edit the team's name and description. * @default member + * @enum {string} */ role?: "member" | "maintainer"; } & { [key: string]: unknown }; @@ -32919,6 +33240,7 @@ export interface operations { * \* `write` - team members can read and write, but not administer this project. * \* `admin` - team members can read, write and administer this project. * Default: the team's `permission` attribute will be used to determine what permission to grant the team on this project. Note that, if you choose not to pass any parameters, you'll need to set `Content-Length` to zero when calling out to this endpoint. For more information, see "[HTTP verbs](https://docs.github.com/rest/overview/resources-in-the-rest-api#http-verbs)." + * @enum {string} */ permission?: "read" | "write" | "admin"; } & { [key: string]: unknown }; @@ -33028,6 +33350,7 @@ export interface operations { * \* `admin` - team members can pull, push and administer this repository. * * If no permission is specified, the team's `permission` attribute will be used to determine what permission to grant the team on this repository. + * @enum {string} */ permission?: "pull" | "push" | "admin"; } & { [key: string]: unknown }; @@ -33319,7 +33642,10 @@ export interface operations { * @example org@example.com */ email: string; - /** @description Denotes whether an email is publically visible. */ + /** + * @description Denotes whether an email is publically visible. + * @enum {string} + */ visibility: "public" | "private"; } & { [key: string]: unknown }; }; @@ -33994,7 +34320,10 @@ export interface operations { requestBody: { content: { "application/json": { - /** @description The state that the membership should be in. Only `"active"` will be accepted. */ + /** + * @description The state that the membership should be in. Only `"active"` will be accepted. + * @enum {string} + */ state: "active"; } & { [key: string]: unknown }; }; diff --git a/test/v3/expected/github.immutable.ts b/test/v3/expected/github.immutable.ts index 8ec16bf6e..b108ff4d6 100644 --- a/test/v3/expected/github.immutable.ts +++ b/test/v3/expected/github.immutable.ts @@ -5381,7 +5381,10 @@ export interface components { readonly account: | (Partial & Partial) | null; - /** @description Describe whether all repositories have been selected or there's a selection involved */ + /** + * @description Describe whether all repositories have been selected or there's a selection involved + * @enum {string} + */ readonly repository_selection: "all" | "selected"; /** * Format: uri @@ -5442,65 +5445,155 @@ export interface components { * @example [object Object] */ readonly "app-permissions": { - /** @description The level of permission to grant the access token for GitHub Actions workflows, workflow runs, and artifacts. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token for GitHub Actions workflows, workflow runs, and artifacts. Can be one of: `read` or `write`. + * @enum {string} + */ readonly actions?: "read" | "write"; - /** @description The level of permission to grant the access token for repository creation, deletion, settings, teams, and collaborators creation. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token for repository creation, deletion, settings, teams, and collaborators creation. Can be one of: `read` or `write`. + * @enum {string} + */ readonly administration?: "read" | "write"; - /** @description The level of permission to grant the access token for checks on code. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token for checks on code. Can be one of: `read` or `write`. + * @enum {string} + */ readonly checks?: "read" | "write"; - /** @description The level of permission to grant the access token for notification of content references and creation content attachments. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token for notification of content references and creation content attachments. Can be one of: `read` or `write`. + * @enum {string} + */ readonly content_references?: "read" | "write"; - /** @description The level of permission to grant the access token for repository contents, commits, branches, downloads, releases, and merges. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token for repository contents, commits, branches, downloads, releases, and merges. Can be one of: `read` or `write`. + * @enum {string} + */ readonly contents?: "read" | "write"; - /** @description The level of permission to grant the access token for deployments and deployment statuses. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token for deployments and deployment statuses. Can be one of: `read` or `write`. + * @enum {string} + */ readonly deployments?: "read" | "write"; - /** @description The level of permission to grant the access token for managing repository environments. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token for managing repository environments. Can be one of: `read` or `write`. + * @enum {string} + */ readonly environments?: "read" | "write"; - /** @description The level of permission to grant the access token for issues and related comments, assignees, labels, and milestones. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token for issues and related comments, assignees, labels, and milestones. Can be one of: `read` or `write`. + * @enum {string} + */ readonly issues?: "read" | "write"; - /** @description The level of permission to grant the access token to search repositories, list collaborators, and access repository metadata. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to search repositories, list collaborators, and access repository metadata. Can be one of: `read` or `write`. + * @enum {string} + */ readonly metadata?: "read" | "write"; - /** @description The level of permission to grant the access token for packages published to GitHub Packages. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token for packages published to GitHub Packages. Can be one of: `read` or `write`. + * @enum {string} + */ readonly packages?: "read" | "write"; - /** @description The level of permission to grant the access token to retrieve Pages statuses, configuration, and builds, as well as create new builds. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to retrieve Pages statuses, configuration, and builds, as well as create new builds. Can be one of: `read` or `write`. + * @enum {string} + */ readonly pages?: "read" | "write"; - /** @description The level of permission to grant the access token for pull requests and related comments, assignees, labels, milestones, and merges. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token for pull requests and related comments, assignees, labels, milestones, and merges. Can be one of: `read` or `write`. + * @enum {string} + */ readonly pull_requests?: "read" | "write"; - /** @description The level of permission to grant the access token to manage the post-receive hooks for a repository. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to manage the post-receive hooks for a repository. Can be one of: `read` or `write`. + * @enum {string} + */ readonly repository_hooks?: "read" | "write"; - /** @description The level of permission to grant the access token to manage repository projects, columns, and cards. Can be one of: `read`, `write`, or `admin`. */ + /** + * @description The level of permission to grant the access token to manage repository projects, columns, and cards. Can be one of: `read`, `write`, or `admin`. + * @enum {string} + */ readonly repository_projects?: "read" | "write" | "admin"; - /** @description The level of permission to grant the access token to view and manage secret scanning alerts. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to view and manage secret scanning alerts. Can be one of: `read` or `write`. + * @enum {string} + */ readonly secret_scanning_alerts?: "read" | "write"; - /** @description The level of permission to grant the access token to manage repository secrets. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to manage repository secrets. Can be one of: `read` or `write`. + * @enum {string} + */ readonly secrets?: "read" | "write"; - /** @description The level of permission to grant the access token to view and manage security events like code scanning alerts. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to view and manage security events like code scanning alerts. Can be one of: `read` or `write`. + * @enum {string} + */ readonly security_events?: "read" | "write"; - /** @description The level of permission to grant the access token to manage just a single file. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to manage just a single file. Can be one of: `read` or `write`. + * @enum {string} + */ readonly single_file?: "read" | "write"; - /** @description The level of permission to grant the access token for commit statuses. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token for commit statuses. Can be one of: `read` or `write`. + * @enum {string} + */ readonly statuses?: "read" | "write"; - /** @description The level of permission to grant the access token to retrieve Dependabot alerts. Can be one of: `read`. */ + /** + * @description The level of permission to grant the access token to retrieve Dependabot alerts. Can be one of: `read`. + * @enum {string} + */ readonly vulnerability_alerts?: "read"; - /** @description The level of permission to grant the access token to update GitHub Actions workflow files. Can be one of: `write`. */ + /** + * @description The level of permission to grant the access token to update GitHub Actions workflow files. Can be one of: `write`. + * @enum {string} + */ readonly workflows?: "write"; - /** @description The level of permission to grant the access token for organization teams and members. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token for organization teams and members. Can be one of: `read` or `write`. + * @enum {string} + */ readonly members?: "read" | "write"; - /** @description The level of permission to grant the access token to manage access to an organization. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to manage access to an organization. Can be one of: `read` or `write`. + * @enum {string} + */ readonly organization_administration?: "read" | "write"; - /** @description The level of permission to grant the access token to manage the post-receive hooks for an organization. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to manage the post-receive hooks for an organization. Can be one of: `read` or `write`. + * @enum {string} + */ readonly organization_hooks?: "read" | "write"; - /** @description The level of permission to grant the access token for viewing an organization's plan. Can be one of: `read`. */ + /** + * @description The level of permission to grant the access token for viewing an organization's plan. Can be one of: `read`. + * @enum {string} + */ readonly organization_plan?: "read"; - /** @description The level of permission to grant the access token to manage organization projects, columns, and cards. Can be one of: `read`, `write`, or `admin`. */ + /** + * @description The level of permission to grant the access token to manage organization projects, columns, and cards. Can be one of: `read`, `write`, or `admin`. + * @enum {string} + */ readonly organization_projects?: "read" | "write" | "admin"; - /** @description The level of permission to grant the access token to manage organization secrets. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to manage organization secrets. Can be one of: `read` or `write`. + * @enum {string} + */ readonly organization_secrets?: "read" | "write"; - /** @description The level of permission to grant the access token to view and manage GitHub Actions self-hosted runners available to an organization. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to view and manage GitHub Actions self-hosted runners available to an organization. Can be one of: `read` or `write`. + * @enum {string} + */ readonly organization_self_hosted_runners?: "read" | "write"; - /** @description The level of permission to grant the access token to view and manage users blocked by the organization. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to view and manage users blocked by the organization. Can be one of: `read` or `write`. + * @enum {string} + */ readonly organization_user_blocking?: "read" | "write"; - /** @description The level of permission to grant the access token to manage team discussions and related comments. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to manage team discussions and related comments. Can be one of: `read` or `write`. + * @enum {string} + */ readonly team_discussions?: "read" | "write"; }; /** @@ -5919,6 +6012,7 @@ export interface components { /** @example read */ readonly single_file?: string; }; + /** @enum {string} */ readonly repository_selection?: "all" | "selected"; readonly repositories?: readonly components["schemas"]["repository"][]; /** @example README.md */ @@ -5979,7 +6073,10 @@ export interface components { /** Scoped Installation */ readonly "scoped-installation": { readonly permissions: components["schemas"]["app-permissions"]; - /** @description Describe whether all repositories have been selected or there's a selection involved */ + /** + * @description Describe whether all repositories have been selected or there's a selection involved + * @enum {string} + */ readonly repository_selection: "all" | "selected"; /** @example config.yaml */ readonly single_file_name: string | null; @@ -6118,9 +6215,15 @@ export interface components { */ readonly node_id?: string; }; - /** @description The policy that controls the organizations in the enterprise that are allowed to run GitHub Actions. Can be one of: `all`, `none`, or `selected`. */ + /** + * @description The policy that controls the organizations in the enterprise that are allowed to run GitHub Actions. Can be one of: `all`, `none`, or `selected`. + * @enum {string} + */ readonly "enabled-organizations": "all" | "none" | "selected"; - /** @description The permissions policy that controls the actions that are allowed to run. Can be one of: `all`, `local_only`, or `selected`. */ + /** + * @description The permissions policy that controls the actions that are allowed to run. Can be one of: `all`, `local_only`, or `selected`. + * @enum {string} + */ readonly "allowed-actions": "all" | "local_only" | "selected"; /** @description The API URL to use to get or set the actions that are allowed to run, when `allowed_actions` is set to `selected`. */ readonly "selected-actions-url": string; @@ -6218,7 +6321,10 @@ export interface components { readonly id?: number; /** @description Name of the label. */ readonly name?: string; - /** @description The type of label. Read-only labels are applied automatically when the runner is configured. */ + /** + * @description The type of label. Read-only labels are applied automatically when the runner is configured. + * @enum {string} + */ readonly type?: "read-only" | "custom"; }[]; }; @@ -6254,7 +6360,10 @@ export interface components { readonly repositories?: readonly components["schemas"]["repository"][]; /** @example config.yaml */ readonly single_file?: string | null; - /** @description Describe whether all repositories have been selected or there's a selection involved */ + /** + * @description Describe whether all repositories have been selected or there's a selection involved + * @enum {string} + */ readonly repository_selection?: "all" | "selected"; }; readonly "audit-log-event": { @@ -6414,6 +6523,7 @@ export interface components { * @description The state of the milestone. * @default open * @example open + * @enum {string} */ readonly state: "open" | "closed"; /** @@ -6453,6 +6563,7 @@ export interface components { * author_association * @description How the author is associated with the repository. * @example OWNER + * @enum {string} */ readonly author_association: | "COLLABORATOR" @@ -7456,7 +7567,10 @@ export interface components { /** Format: date-time */ readonly updated_at: string; }; - /** @description The policy that controls the repositories in the organization that are allowed to run GitHub Actions. Can be one of: `all`, `none`, or `selected`. */ + /** + * @description The policy that controls the repositories in the organization that are allowed to run GitHub Actions. Can be one of: `all`, `none`, or `selected`. + * @enum {string} + */ readonly "enabled-repositories": "all" | "none" | "selected"; readonly "actions-organization-permissions": { readonly enabled_repositories: components["schemas"]["enabled-repositories"]; @@ -7491,7 +7605,10 @@ export interface components { readonly created_at: string; /** Format: date-time */ readonly updated_at: string; - /** @description Visibility of a secret */ + /** + * @description Visibility of a secret + * @enum {string} + */ readonly visibility: "all" | "private" | "selected"; /** * Format: uri @@ -7651,6 +7768,7 @@ export interface components { /** * @description The type of GitHub user that can comment, open issues, or create pull requests while the interaction limit is in effect. Can be one of: `existing_users`, `contributors_only`, `collaborators_only`. * @example collaborators_only + * @enum {string} */ readonly "interaction-group": "existing_users" | "contributors_only" | "collaborators_only"; /** @@ -7670,6 +7788,7 @@ export interface components { /** * @description The duration of the interaction restriction. Can be one of: `one_day`, `three_days`, `one_week`, `one_month`, `six_months`. Default: `one_day`. * @example one_month + * @enum {string} */ readonly "interaction-expiry": "one_day" | "three_days" | "one_week" | "one_month" | "six_months"; /** @@ -7838,7 +7957,10 @@ export interface components { * @example super-linter */ readonly name: string; - /** @example docker */ + /** + * @example docker + * @enum {string} + */ readonly package_type: "npm" | "maven" | "rubygems" | "docker" | "nuget" | "container"; /** @example https://api.github.com/orgs/github/packages/container/super-linter */ readonly url: string; @@ -7849,7 +7971,10 @@ export interface components { * @example 1 */ readonly version_count: number; - /** @example private */ + /** + * @example private + * @enum {string} + */ readonly visibility: "private" | "public"; readonly owner?: components["schemas"]["simple-user"] | null; readonly repository?: components["schemas"]["minimal-repository"] | null; @@ -7899,7 +8024,10 @@ export interface components { readonly deleted_at?: string; /** Package Version Metadata */ readonly metadata?: { - /** @example docker */ + /** + * @example docker + * @enum {string} + */ readonly package_type: "npm" | "maven" | "rubygems" | "docker" | "nuget" | "container"; /** Container Metadata */ readonly container?: { @@ -7970,7 +8098,10 @@ export interface components { * @example 2014-03-03T18:58:10Z */ readonly updated_at: string; - /** @description The baseline permission that all organization members have on this project. Only present if owner is an organization. */ + /** + * @description The baseline permission that all organization members have on this project. Only present if owner is an organization. + * @enum {string} + */ readonly organization_permission?: "read" | "write" | "admin" | "none"; /** @description Whether or not this project can be seen by everyone. Only present if owner is an organization. */ readonly private?: boolean; @@ -8047,6 +8178,7 @@ export interface components { /** * @description The level of privacy this team should have * @example closed + * @enum {string} */ readonly privacy?: "closed" | "secret"; /** @@ -8225,6 +8357,7 @@ export interface components { /** * @description The reaction to use * @example heart + * @enum {string} */ readonly content: "+1" | "-1" | "laugh" | "confused" | "heart" | "hooray" | "rocket" | "eyes"; /** @@ -8244,6 +8377,7 @@ export interface components { * @description The role of the user in the team. * @default member * @example member + * @enum {string} */ readonly role: "member" | "maintainer"; readonly state: string; @@ -8993,6 +9127,7 @@ export interface components { /** * @description The phase of the lifecycle that the job is currently in. * @example queued + * @enum {string} */ readonly status: "queued" | "in_progress" | "completed"; /** @@ -9022,6 +9157,7 @@ export interface components { /** * @description The phase of the lifecycle that the job is currently in. * @example queued + * @enum {string} */ readonly status: "queued" | "in_progress" | "completed"; /** @@ -9234,6 +9370,7 @@ export interface components { /** * @description Whether deployment to the environment(s) was approved or rejected * @example approved + * @enum {string} */ readonly state: "approved" | "rejected"; readonly user: components["schemas"]["simple-user"]; @@ -9246,6 +9383,7 @@ export interface components { /** * @description The type of reviewer. Must be one of: `User` or `Team` * @example User + * @enum {string} */ readonly "deployment-reviewer-type": "User" | "Team"; /** @@ -9415,7 +9553,10 @@ export interface components { readonly name: string; /** @example ruby.yaml */ readonly path: string; - /** @example active */ + /** + * @example active + * @enum {string} + */ readonly state: "active" | "deleted"; /** * Format: date-time @@ -9929,9 +10070,13 @@ export interface components { /** * @description The phase of the lifecycle that the check is currently in. * @example queued + * @enum {string} */ readonly status: "queued" | "in_progress" | "completed"; - /** @example neutral */ + /** + * @example neutral + * @enum {string|null} + */ readonly conclusion: | ("success" | "failure" | "neutral" | "cancelled" | "skipped" | "timed_out" | "action_required") | null; @@ -10006,9 +10151,15 @@ export interface components { * @example 009b8a3a9ccbb128af87f9b1c0f4c62e8a304f6d */ readonly head_sha: string; - /** @example completed */ + /** + * @example completed + * @enum {string|null} + */ readonly status: ("queued" | "in_progress" | "completed") | null; - /** @example neutral */ + /** + * @example neutral + * @enum {string|null} + */ readonly conclusion: | ("success" | "failure" | "neutral" | "cancelled" | "skipped" | "timed_out" | "action_required") | null; @@ -10048,7 +10199,10 @@ export interface components { readonly "code-scanning-analysis-tool-guid": string | null; /** @description The full Git reference, formatted as `refs/heads/`. */ readonly "code-scanning-ref": string; - /** @description State of a code scanning alert. */ + /** + * @description State of a code scanning alert. + * @enum {string} + */ readonly "code-scanning-alert-state": "open" | "dismissed" | "fixed"; /** @description The security alert number. */ readonly "alert-number": number; @@ -10084,7 +10238,10 @@ export interface components { readonly id?: string | null; /** @description The name of the rule used to detect the alert. */ readonly name?: string; - /** @description The severity of the alert. */ + /** + * @description The severity of the alert. + * @enum {string|null} + */ readonly severity?: ("none" | "note" | "warning" | "error") | null; /** @description A short description of the rule used to detect the alert. */ readonly description?: string; @@ -10108,7 +10265,10 @@ export interface components { readonly start_column?: number; readonly end_column?: number; }; - /** @description A classification of the file. For example to identify it as generated. */ + /** + * @description A classification of the file. For example to identify it as generated. + * @enum {string|null} + */ readonly "code-scanning-alert-classification": ("source" | "generated" | "test" | "library") | null; readonly "code-scanning-alert-instance": { readonly ref?: components["schemas"]["code-scanning-ref"]; @@ -10146,7 +10306,10 @@ export interface components { readonly id?: string | null; /** @description The name of the rule used to detect the alert. */ readonly name?: string; - /** @description The severity of the alert. */ + /** + * @description The severity of the alert. + * @enum {string|null} + */ readonly severity?: ("none" | "note" | "warning" | "error") | null; /** @description A short description of the rule used to detect the alert. */ readonly description?: string; @@ -10171,7 +10334,10 @@ export interface components { readonly tool: components["schemas"]["code-scanning-analysis-tool"]; readonly most_recent_instance: components["schemas"]["code-scanning-alert-instance"]; }; - /** @description Sets the state of the code scanning alert. Can be one of `open` or `dismissed`. You must provide `dismissed_reason` when you set the state to `dismissed`. */ + /** + * @description Sets the state of the code scanning alert. Can be one of `open` or `dismissed`. You must provide `dismissed_reason` when you set the state to `dismissed`. + * @enum {string} + */ readonly "code-scanning-alert-set-state": "open" | "dismissed"; /** * @description An identifier for the upload. @@ -10250,7 +10416,10 @@ export interface components { readonly url?: string; }; readonly "code-scanning-sarifs-status": { - /** @description `pending` files have not yet been processed, while `complete` means all results in the SARIF have been stored. */ + /** + * @description `pending` files have not yet been processed, while `complete` means all results in the SARIF have been stored. + * @enum {string} + */ readonly processing_status?: "pending" | "complete"; /** * Format: uri @@ -10344,6 +10513,7 @@ export interface components { /** * @description The permission associated with the invitation. * @example read + * @enum {string} */ readonly permissions: "read" | "write" | "admin"; /** @@ -10411,7 +10581,10 @@ export interface components { */ readonly auto_merge: { readonly enabled_by: components["schemas"]["simple-user"]; - /** @description The merge method to use. */ + /** + * @description The merge method to use. + * @enum {string} + */ readonly merge_method: "merge" | "squash" | "rebase"; /** @description Title for the merge commit message. */ readonly commit_title: string; @@ -10706,7 +10879,10 @@ export interface components { readonly patch_url: string; readonly base_commit: components["schemas"]["commit"]; readonly merge_base_commit: components["schemas"]["commit"]; - /** @example ahead */ + /** + * @example ahead + * @enum {string} + */ readonly status: "diverged" | "ahead" | "behind" | "identical"; /** @example 4 */ readonly ahead_by: number; @@ -10995,6 +11171,7 @@ export interface components { /** * @description The state of the status. * @example success + * @enum {string} */ readonly state: "error" | "failure" | "inactive" | "pending" | "success" | "queued" | "in_progress"; readonly creator: components["schemas"]["simple-user"] | null; @@ -11407,6 +11584,7 @@ export interface components { readonly vcs_url: string; readonly svc_root?: string; readonly tfvc_project?: string; + /** @enum {string} */ readonly status: | "auth" | "error" @@ -11665,6 +11843,7 @@ export interface components { /** * @description The status of the most recent build of the Page. * @example built + * @enum {string|null} */ readonly status: ("built" | "building" | "errored") | null; /** @@ -11783,6 +11962,7 @@ export interface components { /** * @description State of this Pull Request. Either `open` or `closed`. * @example open + * @enum {string} */ readonly state: "open" | "closed"; /** @example true */ @@ -12338,6 +12518,7 @@ export interface components { /** * @description The side of the first line of the range for a multi-line comment. * @default RIGHT + * @enum {string|null} */ readonly start_side?: ("LEFT" | "RIGHT") | null; /** @@ -12353,6 +12534,7 @@ export interface components { /** * @description The side of the diff to which the comment applies. The side of the last line of the range for a multi-line comment * @default RIGHT + * @enum {string} */ readonly side?: "LEFT" | "RIGHT"; readonly reactions?: components["schemas"]["reaction-rollup"]; @@ -12491,11 +12673,13 @@ export interface components { /** * @description The side of the first line of the range for a multi-line comment. * @default RIGHT + * @enum {string} */ readonly side?: "LEFT" | "RIGHT"; /** * @description The side of the first line of the range for a multi-line comment. * @default RIGHT + * @enum {string|null} */ readonly start_side?: ("LEFT" | "RIGHT") | null; /** @@ -12536,7 +12720,10 @@ export interface components { */ readonly name: string; readonly label: string | null; - /** @description State of the release asset. */ + /** + * @description State of the release asset. + * @enum {string} + */ readonly state: "uploaded" | "open"; readonly content_type: string; readonly size: number; @@ -12590,7 +12777,10 @@ export interface components { readonly body_html?: string; readonly body_text?: string; }; - /** @description Sets the state of the secret scanning alert. Can be either `open` or `resolved`. You must provide `resolution` when you set the state to `resolved`. */ + /** + * @description Sets the state of the secret scanning alert. Can be either `open` or `resolved`. You must provide `resolution` when you set the state to `resolved`. + * @enum {string} + */ readonly "secret-scanning-alert-state": "open" | "resolved"; /** @description **Required when the `state` is `resolved`.** The reason for resolving the alert. Can be one of `false_positive`, `wont_fix`, `revoked`, or `used_in_tests`. */ readonly "secret-scanning-alert-resolution": string | null; @@ -12942,6 +13132,7 @@ export interface components { * @example [object Object] */ readonly operations?: readonly { + /** @enum {string} */ readonly op: "add" | "remove" | "replace"; readonly path?: string; readonly value?: string | { readonly [key: string]: unknown } | readonly unknown[]; @@ -15257,7 +15448,10 @@ export interface operations { readonly "application/json": { /** @description Name of the runner group. */ readonly name: string; - /** @description Visibility of a runner group. You can select all organizations or select individual organization. Can be one of: `all` or `selected` */ + /** + * @description Visibility of a runner group. You can select all organizations or select individual organization. Can be one of: `all` or `selected` + * @enum {string} + */ readonly visibility?: "selected" | "all"; /** @description List of organization IDs that can access the runner group. */ readonly selected_organization_ids?: readonly number[]; @@ -15339,6 +15533,7 @@ export interface operations { /** * @description Visibility of a runner group. You can select all organizations or select individual organizations. Can be one of: `all` or `selected` * @default all + * @enum {string} */ readonly visibility?: "selected" | "all"; }; @@ -16526,6 +16721,7 @@ export interface operations { * @description The rendering mode. * @default markdown * @example markdown + * @enum {string} */ readonly mode?: "markdown" | "gfm"; /** @description The repository context to use when creating references in `gfm` mode. */ @@ -17061,6 +17257,7 @@ export interface operations { * \* `admin` - can pull, push, and administer this repository. * \* `none` - no permissions granted by default. * @default read + * @enum {string} */ readonly default_repository_permission?: "read" | "write" | "admin" | "none"; /** @@ -17099,6 +17296,7 @@ export interface operations { * \* `private` - members can create private repositories. This option is only available to repositories that are part of an organization on GitHub Enterprise Cloud. * \* `none` - only admin members can create repositories. * **Note:** This parameter is deprecated and will be removed in the future. Its return value ignores internal repositories. Using this parameter overrides values set in `members_can_create_repositories`. See the parameter deprecation notice in the operation description for details. + * @enum {string} */ readonly members_allowed_repository_creation_type?: "all" | "private" | "none"; /** @@ -17366,6 +17564,7 @@ export interface operations { /** * @description Visibility of a runner group. You can select all repositories, select individual repositories, or limit access to private repositories. Can be one of: `all`, `selected`, or `private`. * @default all + * @enum {string} */ readonly visibility?: "selected" | "all" | "private"; /** @description List of repository IDs that can access the runner group. */ @@ -17448,7 +17647,10 @@ export interface operations { readonly "application/json": { /** @description Name of the runner group. */ readonly name?: string; - /** @description Visibility of a runner group. You can select all repositories, select individual repositories, or all private repositories. Can be one of: `all`, `selected`, or `private`. */ + /** + * @description Visibility of a runner group. You can select all repositories, select individual repositories, or all private repositories. Can be one of: `all`, `selected`, or `private`. + * @enum {string} + */ readonly visibility?: "selected" | "all" | "private"; }; }; @@ -17973,6 +18175,7 @@ export interface operations { * \- `all` - All repositories in an organization can access the secret. * \- `private` - Private repositories in an organization can access the secret. * \- `selected` - Only specific repositories can access the secret. + * @enum {string} */ readonly visibility?: "all" | "private" | "selected"; /** @description An array of repository ids that can access the organization secret. You can only provide a list of repository ids when the `visibility` is set to `selected`. You can manage the list of selected repositories using the [List selected repositories for an organization secret](https://docs.github.com/rest/reference/actions#list-selected-repositories-for-an-organization-secret), [Set selected repositories for an organization secret](https://docs.github.com/rest/reference/actions#set-selected-repositories-for-an-organization-secret), and [Remove selected repository from an organization secret](https://docs.github.com/rest/reference/actions#remove-selected-repository-from-an-organization-secret) endpoints. */ @@ -18631,6 +18834,7 @@ export interface operations { * \* `direct_member` - Non-owner organization members with ability to see other members and join teams by invitation. * \* `billing_manager` - Non-owner organization members with ability to manage the billing settings of your organization. * @default direct_member + * @enum {string} */ readonly role?: "admin" | "direct_member" | "billing_manager"; /** @description Specify IDs for the teams you want to invite new members to. */ @@ -18860,6 +19064,7 @@ export interface operations { * \* `admin` - The user will become an owner of the organization. * \* `member` - The user will become a non-owner member of the organization. * @default member + * @enum {string} */ readonly role?: "admin" | "member"; }; @@ -19509,6 +19714,7 @@ export interface operations { /** * @description Can be `public` or `private`. If your organization is associated with an enterprise account using GitHub Enterprise Cloud or GitHub Enterprise Server 2.20+, `visibility` can also be `internal`. For more information, see "[Creating an internal repository](https://help.github.com/en/github/creating-cloning-and-archiving-repositories/about-repository-visibility#about-internal-repositories)" in the GitHub Help documentation. * The `visibility` parameter overrides the `private` parameter when you use both parameters with the `nebula-preview` preview header. + * @enum {string} */ readonly visibility?: "public" | "private" | "visibility" | "internal"; /** @@ -19719,6 +19925,7 @@ export interface operations { * **For a parent or child team:** * \* `closed` - visible to all members of this organization. * Default for child team: `closed` + * @enum {string} */ readonly privacy?: "secret" | "closed"; /** @@ -19727,6 +19934,7 @@ export interface operations { * \* `push` - team members can pull and push, but not administer newly-added repositories. * \* `admin` - team members can pull, push and administer newly-added repositories. * @default pull + * @enum {string} */ readonly permission?: "pull" | "push" | "admin"; /** @description The ID of a team to set as the parent team. */ @@ -19813,6 +20021,7 @@ export interface operations { * \* `closed` - visible to all members of this organization. * **For a parent or child team:** * \* `closed` - visible to all members of this organization. + * @enum {string} */ readonly privacy?: "secret" | "closed"; /** @@ -19821,6 +20030,7 @@ export interface operations { * \* `push` - team members can pull and push, but not administer newly-added repositories. * \* `admin` - team members can pull, push and administer newly-added repositories. * @default pull + * @enum {string} */ readonly permission?: "pull" | "push" | "admin"; /** @description The ID of a team to set as the parent team. */ @@ -20171,7 +20381,10 @@ export interface operations { readonly requestBody: { readonly content: { readonly "application/json": { - /** @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the team discussion comment. */ + /** + * @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the team discussion comment. + * @enum {string} + */ readonly content: "+1" | "-1" | "laugh" | "confused" | "heart" | "hooray" | "rocket" | "eyes"; }; }; @@ -20255,7 +20468,10 @@ export interface operations { readonly requestBody: { readonly content: { readonly "application/json": { - /** @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the team discussion. */ + /** + * @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the team discussion. + * @enum {string} + */ readonly content: "+1" | "-1" | "laugh" | "confused" | "heart" | "hooray" | "rocket" | "eyes"; }; }; @@ -20428,6 +20644,7 @@ export interface operations { * \* `member` - a normal member of the team. * \* `maintainer` - a team maintainer. Able to add/remove other team members, promote other team members to team maintainer, and edit the team's name and description. * @default member + * @enum {string} */ readonly role?: "member" | "maintainer"; }; @@ -20549,6 +20766,7 @@ export interface operations { * \* `write` - team members can read and write, but not administer this project. * \* `admin` - team members can read, write and administer this project. * Default: the team's `permission` attribute will be used to determine what permission to grant the team on this project. Note that, if you choose not to pass any parameters, you'll need to set `Content-Length` to zero when calling out to this endpoint. For more information, see "[HTTP verbs](https://docs.github.com/rest/overview/resources-in-the-rest-api#http-verbs)." + * @enum {string} */ readonly permission?: "read" | "write" | "admin"; } | null; @@ -20668,6 +20886,7 @@ export interface operations { * \* `triage` - team members can proactively manage issues and pull requests without write access. Recommended for contributors who triage a repository. Only applies to repositories owned by organizations. * * If no permission is specified, the team's `permission` attribute will be used to determine what permission to grant the team on this repository. + * @enum {string} */ readonly permission?: "pull" | "push" | "admin" | "maintain" | "triage"; }; @@ -21217,7 +21436,10 @@ export interface operations { * @example open */ readonly state?: string; - /** @description The baseline permission that all organization members have on this project */ + /** + * @description The baseline permission that all organization members have on this project + * @enum {string} + */ readonly organization_permission?: "read" | "write" | "admin" | "none"; /** @description Whether or not this project can be seen by everyone. */ readonly private?: boolean; @@ -21286,6 +21508,7 @@ export interface operations { * @description The permission to grant the collaborator. * @default write * @example write + * @enum {string} */ readonly permission?: "read" | "write" | "admin"; }; @@ -21514,7 +21737,10 @@ export interface operations { * **Note**: You will get a `422` error if the organization restricts [changing repository visibility](https://help.github.com/articles/repository-permission-levels-for-an-organization#changing-the-visibility-of-repositories) to organization owners and a non-owner tries to change the value of private. **Note**: You will get a `422` error if the organization restricts [changing repository visibility](https://help.github.com/articles/repository-permission-levels-for-an-organization#changing-the-visibility-of-repositories) to organization owners and a non-owner tries to change the value of private. */ readonly private?: boolean; - /** @description Can be `public` or `private`. If your organization is associated with an enterprise account using GitHub Enterprise Cloud or GitHub Enterprise Server 2.20+, `visibility` can also be `internal`. The `visibility` parameter overrides the `private` parameter when you use both along with the `nebula-preview` preview header. */ + /** + * @description Can be `public` or `private`. If your organization is associated with an enterprise account using GitHub Enterprise Cloud or GitHub Enterprise Server 2.20+, `visibility` can also be `internal`. The `visibility` parameter overrides the `private` parameter when you use both along with the `nebula-preview` preview header. + * @enum {string} + */ readonly visibility?: "public" | "private" | "visibility" | "internal"; /** * @description Either `true` to enable issues for this repository or `false` to disable them. @@ -22189,6 +22415,7 @@ export interface operations { /** * @description Whether to approve or reject deployment to the specified environments. Must be one of: `approved` or `rejected` * @example approved + * @enum {string} */ readonly state: "approved" | "rejected"; /** @@ -23737,6 +23964,7 @@ export interface operations { readonly content: { readonly "application/json": (Partial< { + /** @enum {undefined} */ readonly status?: "completed"; } & { conclusion: unknown; @@ -23744,6 +23972,7 @@ export interface operations { > & Partial< { + /** @enum {undefined} */ readonly status?: "queued" | "in_progress"; } & { readonly [key: string]: unknown } >) & { @@ -23758,6 +23987,7 @@ export interface operations { /** * @description The current status. Can be one of `queued`, `in_progress`, or `completed`. * @default queued + * @enum {string} */ readonly status?: "queued" | "in_progress" | "completed"; /** @description The time that the check run began. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`. */ @@ -23765,6 +23995,7 @@ export interface operations { /** * @description **Required if you provide `completed_at` or a `status` of `completed`**. The final conclusion of the check. Can be one of `action_required`, `cancelled`, `failure`, `neutral`, `success`, `skipped`, `stale`, or `timed_out`. When the conclusion is `action_required`, additional details should be provided on the site specified by `details_url`. * **Note:** Providing `conclusion` will automatically set the `status` parameter to `completed`. You cannot change a check run conclusion to `stale`, only GitHub can set this. + * @enum {string} */ readonly conclusion?: | "action_required" @@ -23797,7 +24028,10 @@ export interface operations { readonly start_column?: number; /** @description The end column of the annotation. Annotations only support `start_column` and `end_column` on the same line. Omit this parameter if `start_line` and `end_line` have different values. */ readonly end_column?: number; - /** @description The level of the annotation. Can be one of `notice`, `warning`, or `failure`. */ + /** + * @description The level of the annotation. Can be one of `notice`, `warning`, or `failure`. + * @enum {string} + */ readonly annotation_level: "notice" | "warning" | "failure"; /** @description A short description of the feedback for these lines of code. The maximum size is 64 KB. */ readonly message: string; @@ -23878,6 +24112,7 @@ export interface operations { readonly content: { readonly "application/json": (Partial< { + /** @enum {undefined} */ readonly status?: "completed"; } & { conclusion: unknown; @@ -23885,6 +24120,7 @@ export interface operations { > & Partial< { + /** @enum {undefined} */ readonly status?: "queued" | "in_progress"; } & { readonly [key: string]: unknown } >) & { @@ -23896,11 +24132,15 @@ export interface operations { readonly external_id?: string; /** @description This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`. */ readonly started_at?: string; - /** @description The current status. Can be one of `queued`, `in_progress`, or `completed`. */ + /** + * @description The current status. Can be one of `queued`, `in_progress`, or `completed`. + * @enum {string} + */ readonly status?: "queued" | "in_progress" | "completed"; /** * @description **Required if you provide `completed_at` or a `status` of `completed`**. The final conclusion of the check. Can be one of `action_required`, `cancelled`, `failure`, `neutral`, `success`, `skipped`, `stale`, or `timed_out`. * **Note:** Providing `conclusion` will automatically set the `status` parameter to `completed`. You cannot change a check run conclusion to `stale`, only GitHub can set this. + * @enum {string} */ readonly conclusion?: | "action_required" @@ -23933,7 +24173,10 @@ export interface operations { readonly start_column?: number; /** @description The end column of the annotation. Annotations only support `start_column` and `end_column` on the same line. Omit this parameter if `start_line` and `end_line` have different values. */ readonly end_column?: number; - /** @description The level of the annotation. Can be one of `notice`, `warning`, or `failure`. */ + /** + * @description The level of the annotation. Can be one of `notice`, `warning`, or `failure`. + * @enum {string} + */ readonly annotation_level: "notice" | "warning" | "failure"; /** @description A short description of the feedback for these lines of code. The maximum size is 64 KB. */ readonly message: string; @@ -24637,6 +24880,7 @@ export interface operations { * \* `maintain` - Recommended for project managers who need to manage the repository without access to sensitive or destructive actions. * \* `triage` - Recommended for contributors who need to proactively manage issues and pull requests without write access. * @default push + * @enum {string} */ readonly permission?: "pull" | "push" | "admin" | "maintain" | "triage"; /** @example "push" */ @@ -24825,7 +25069,10 @@ export interface operations { readonly requestBody: { readonly content: { readonly "application/json": { - /** @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the commit comment. */ + /** + * @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the commit comment. + * @enum {string} + */ readonly content: "+1" | "-1" | "laugh" | "confused" | "heart" | "hooray" | "rocket" | "eyes"; }; }; @@ -25818,7 +26065,10 @@ export interface operations { readonly requestBody: { readonly content: { readonly "application/json": { - /** @description The state of the status. Can be one of `error`, `failure`, `inactive`, `in_progress`, `queued` `pending`, or `success`. **Note:** To use the `inactive` state, you must provide the [`application/vnd.github.ant-man-preview+json`](https://docs.github.com/rest/overview/api-previews#enhanced-deployments) custom media type. To use the `in_progress` and `queued` states, you must provide the [`application/vnd.github.flash-preview+json`](https://docs.github.com/rest/overview/api-previews#deployment-statuses) custom media type. When you set a transient deployment to `inactive`, the deployment will be shown as `destroyed` in GitHub. */ + /** + * @description The state of the status. Can be one of `error`, `failure`, `inactive`, `in_progress`, `queued` `pending`, or `success`. **Note:** To use the `inactive` state, you must provide the [`application/vnd.github.ant-man-preview+json`](https://docs.github.com/rest/overview/api-previews#enhanced-deployments) custom media type. To use the `in_progress` and `queued` states, you must provide the [`application/vnd.github.flash-preview+json`](https://docs.github.com/rest/overview/api-previews#deployment-statuses) custom media type. When you set a transient deployment to `inactive`, the deployment will be shown as `destroyed` in GitHub. + * @enum {string} + */ readonly state: "error" | "failure" | "inactive" | "in_progress" | "queued" | "pending" | "success"; /** @description The target URL to associate with this status. This URL should contain output to keep the user updated while the task is running or serve as historical information for what happened in the deployment. **Note:** It's recommended to use the `log_url` parameter, which replaces `target_url`. */ readonly target_url?: string; @@ -25829,7 +26079,10 @@ export interface operations { readonly log_url?: string; /** @description A short description of the status. The maximum description length is 140 characters. */ readonly description?: string; - /** @description Name for the target deployment environment, which can be changed when setting a deploy status. For example, `production`, `staging`, or `qa`. **Note:** This parameter requires you to use the [`application/vnd.github.flash-preview+json`](https://docs.github.com/rest/overview/api-previews#deployment-statuses) custom media type. */ + /** + * @description Name for the target deployment environment, which can be changed when setting a deploy status. For example, `production`, `staging`, or `qa`. **Note:** This parameter requires you to use the [`application/vnd.github.flash-preview+json`](https://docs.github.com/rest/overview/api-previews#deployment-statuses) custom media type. + * @enum {string} + */ readonly environment?: "production" | "staging" | "qa"; /** * @description Sets the URL for accessing your environment. Default: `""` @@ -26488,7 +26741,10 @@ export interface operations { readonly message: string; /** @description The SHA of the git object this is tagging. */ readonly object: string; - /** @description The type of the object we're tagging. Normally this is a `commit` but it can also be a `tree` or a `blob`. */ + /** + * @description The type of the object we're tagging. Normally this is a `commit` but it can also be a `tree` or a `blob`. + * @enum {string} + */ readonly type: "commit" | "tree" | "blob"; /** @description An object with information about the individual creating the tag. */ readonly tagger?: { @@ -26584,9 +26840,15 @@ export interface operations { readonly tree: readonly { /** @description The file referenced in the tree. */ readonly path?: string; - /** @description The file mode; one of `100644` for file (blob), `100755` for executable (blob), `040000` for subdirectory (tree), `160000` for submodule (commit), or `120000` for a blob that specifies the path of a symlink. */ + /** + * @description The file mode; one of `100644` for file (blob), `100755` for executable (blob), `040000` for subdirectory (tree), `160000` for submodule (commit), or `120000` for a blob that specifies the path of a symlink. + * @enum {string} + */ readonly mode?: "100644" | "100755" | "040000" | "160000" | "120000"; - /** @description Either `blob`, `tree`, or `commit`. */ + /** + * @description Either `blob`, `tree`, or `commit`. + * @enum {string} + */ readonly type?: "blob" | "tree" | "commit"; /** * @description The SHA1 checksum ID of the object in the tree. Also called `tree.sha`. If the value is `null` then the file will be deleted. @@ -26968,7 +27230,10 @@ export interface operations { readonly "application/json": { /** @description The URL of the originating repository. */ readonly vcs_url: string; - /** @description The originating VCS type. Can be one of `subversion`, `git`, `mercurial`, or `tfvc`. Please be aware that without this parameter, the import job will take additional time to detect the VCS type before beginning the import. This detection step will be reflected in the response. */ + /** + * @description The originating VCS type. Can be one of `subversion`, `git`, `mercurial`, or `tfvc`. Please be aware that without this parameter, the import job will take additional time to detect the VCS type before beginning the import. This detection step will be reflected in the response. + * @enum {string} + */ readonly vcs?: "subversion" | "git" | "mercurial" | "tfvc"; /** @description If authentication is required, the username to provide to `vcs_url`. */ readonly vcs_username?: string; @@ -27122,7 +27387,10 @@ export interface operations { readonly requestBody: { readonly content: { readonly "application/json": { - /** @description Can be one of `opt_in` (large files will be stored using Git LFS) or `opt_out` (large files will be removed during the import). */ + /** + * @description Can be one of `opt_in` (large files will be stored using Git LFS) or `opt_out` (large files will be removed during the import). + * @enum {string} + */ readonly use_lfs: "opt_in" | "opt_out"; }; }; @@ -27265,7 +27533,10 @@ export interface operations { readonly requestBody: { readonly content: { readonly "application/json": { - /** @description The permissions that the associated user will have on the repository. Valid values are `read`, `write`, `maintain`, `triage`, and `admin`. */ + /** + * @description The permissions that the associated user will have on the repository. Valid values are `read`, `write`, `maintain`, `triage`, and `admin`. + * @enum {string} + */ readonly permissions?: "read" | "write" | "maintain" | "triage" | "admin"; }; }; @@ -27528,7 +27799,10 @@ export interface operations { readonly requestBody: { readonly content: { readonly "application/json": { - /** @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the issue comment. */ + /** + * @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the issue comment. + * @enum {string} + */ readonly content: "+1" | "-1" | "laugh" | "confused" | "heart" | "hooray" | "rocket" | "eyes"; }; }; @@ -27666,7 +27940,10 @@ export interface operations { readonly body?: string | null; /** @description Login for the user that this issue should be assigned to. **This field is deprecated.** */ readonly assignee?: string | null; - /** @description State of the issue. Either `open` or `closed`. */ + /** + * @description State of the issue. Either `open` or `closed`. + * @enum {string} + */ readonly state?: "open" | "closed"; readonly milestone?: (string | number) | null; /** @description Labels to associate with this issue. Pass one or more Labels to _replace_ the set of Labels on this Issue. Send an empty array (`[]`) to clear all Labels from the Issue. _NOTE: Only users with push access can set labels for issues. Labels are silently dropped otherwise._ */ @@ -27980,6 +28257,7 @@ export interface operations { * \* `too heated` * \* `resolved` * \* `spam` + * @enum {string} */ readonly lock_reason?: "off-topic" | "too heated" | "resolved" | "spam"; } | null; @@ -28057,7 +28335,10 @@ export interface operations { readonly requestBody: { readonly content: { readonly "application/json": { - /** @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the issue. */ + /** + * @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the issue. + * @enum {string} + */ readonly content: "+1" | "-1" | "laugh" | "confused" | "heart" | "hooray" | "rocket" | "eyes"; }; }; @@ -28468,6 +28749,7 @@ export interface operations { /** * @description The state of the milestone. Either `open` or `closed`. * @default open + * @enum {string} */ readonly state?: "open" | "closed"; /** @description A description of the milestone. */ @@ -28537,6 +28819,7 @@ export interface operations { /** * @description The state of the milestone. Either `open` or `closed`. * @default open + * @enum {string} */ readonly state?: "open" | "closed"; /** @description A description of the milestone. */ @@ -28667,7 +28950,10 @@ export interface operations { Partial<{ /** @description The repository branch used to publish your site's source files. */ readonly branch: string; - /** @description The repository directory that includes the source files for the Pages site. Allowed paths are `/` or `/docs`. */ + /** + * @description The repository directory that includes the source files for the Pages site. Allowed paths are `/` or `/docs`. + * @enum {string} + */ readonly path: "/" | "/docs"; }>; }; @@ -28703,6 +28989,7 @@ export interface operations { /** * @description The repository directory that includes the source files for the Pages site. Allowed paths are `/` or `/docs`. Default: `/` * @default / + * @enum {string} */ readonly path?: "/" | "/docs"; }; @@ -29103,7 +29390,10 @@ export interface operations { readonly requestBody: { readonly content: { readonly "application/json": { - /** @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the pull request review comment. */ + /** + * @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the pull request review comment. + * @enum {string} + */ readonly content: "+1" | "-1" | "laugh" | "confused" | "heart" | "hooray" | "rocket" | "eyes"; }; }; @@ -29196,7 +29486,10 @@ export interface operations { readonly title?: string; /** @description The contents of the pull request. */ readonly body?: string; - /** @description State of this Pull Request. Either `open` or `closed`. */ + /** + * @description State of this Pull Request. Either `open` or `closed`. + * @enum {string} + */ readonly state?: "open" | "closed"; /** @description The name of the branch you want your changes pulled into. This should be an existing branch on the current repository. You cannot update the base branch on a pull request to point to another repository. */ readonly base?: string; @@ -29278,13 +29571,19 @@ export interface operations { readonly path?: string; /** @description **Required without `comfort-fade` preview**. The position in the diff where you want to add a review comment. Note this value is not the same as the line number in the file. For help finding the position value, read the note above. */ readonly position?: number; - /** @description **Required with `comfort-fade` preview**. In a split diff view, the side of the diff that the pull request's changes appear on. Can be `LEFT` or `RIGHT`. Use `LEFT` for deletions that appear in red. Use `RIGHT` for additions that appear in green or unchanged lines that appear in white and are shown for context. For a multi-line comment, side represents whether the last line of the comment range is a deletion or addition. For more information, see "[Diff view options](https://help.github.com/en/articles/about-comparing-branches-in-pull-requests#diff-view-options)" in the GitHub Help documentation. */ + /** + * @description **Required with `comfort-fade` preview**. In a split diff view, the side of the diff that the pull request's changes appear on. Can be `LEFT` or `RIGHT`. Use `LEFT` for deletions that appear in red. Use `RIGHT` for additions that appear in green or unchanged lines that appear in white and are shown for context. For a multi-line comment, side represents whether the last line of the comment range is a deletion or addition. For more information, see "[Diff view options](https://help.github.com/en/articles/about-comparing-branches-in-pull-requests#diff-view-options)" in the GitHub Help documentation. + * @enum {string} + */ readonly side?: "LEFT" | "RIGHT"; /** @description **Required with `comfort-fade` preview**. The line of the blob in the pull request diff that the comment applies to. For a multi-line comment, the last line of the range that your comment applies to. */ readonly line?: number; /** @description **Required when using multi-line comments**. To create multi-line comments, you must use the `comfort-fade` preview header. The `start_line` is the first line in the pull request diff that your multi-line comment applies to. To learn more about multi-line comments, see "[Commenting on a pull request](https://help.github.com/en/articles/commenting-on-a-pull-request#adding-line-comments-to-a-pull-request)" in the GitHub Help documentation. */ readonly start_line?: number; - /** @description **Required when using multi-line comments**. To create multi-line comments, you must use the `comfort-fade` preview header. The `start_side` is the starting side of the diff that the comment applies to. Can be `LEFT` or `RIGHT`. To learn more about multi-line comments, see "[Commenting on a pull request](https://help.github.com/en/articles/commenting-on-a-pull-request#adding-line-comments-to-a-pull-request)" in the GitHub Help documentation. See `side` in this table for additional context. */ + /** + * @description **Required when using multi-line comments**. To create multi-line comments, you must use the `comfort-fade` preview header. The `start_side` is the starting side of the diff that the comment applies to. Can be `LEFT` or `RIGHT`. To learn more about multi-line comments, see "[Commenting on a pull request](https://help.github.com/en/articles/commenting-on-a-pull-request#adding-line-comments-to-a-pull-request)" in the GitHub Help documentation. See `side` in this table for additional context. + * @enum {string} + */ readonly start_side?: "LEFT" | "RIGHT" | "side"; /** @example 2 */ readonly in_reply_to?: number; @@ -29442,7 +29741,10 @@ export interface operations { readonly commit_message?: string; /** @description SHA that pull request head must match to allow merge. */ readonly sha?: string; - /** @description Merge method to use. Possible values are `merge`, `squash` or `rebase`. Default is `merge`. */ + /** + * @description Merge method to use. Possible values are `merge`, `squash` or `rebase`. Default is `merge`. + * @enum {string} + */ readonly merge_method?: "merge" | "squash" | "rebase"; } | null; }; @@ -29586,7 +29888,10 @@ export interface operations { readonly commit_id?: string; /** @description **Required** when using `REQUEST_CHANGES` or `COMMENT` for the `event` parameter. The body text of the pull request review. */ readonly body?: string; - /** @description The review action you want to perform. The review actions include: `APPROVE`, `REQUEST_CHANGES`, or `COMMENT`. By leaving this blank, you set the review action state to `PENDING`, which means you will need to [submit the pull request review](https://docs.github.com/rest/reference/pulls#submit-a-review-for-a-pull-request) when you are ready. */ + /** + * @description The review action you want to perform. The review actions include: `APPROVE`, `REQUEST_CHANGES`, or `COMMENT`. By leaving this blank, you set the review action state to `PENDING`, which means you will need to [submit the pull request review](https://docs.github.com/rest/reference/pulls#submit-a-review-for-a-pull-request) when you are ready. + * @enum {string} + */ readonly event?: "APPROVE" | "REQUEST_CHANGES" | "COMMENT"; /** @description Use the following table to specify the location, destination, and contents of the draft review comment. */ readonly comments?: readonly { @@ -29765,7 +30070,10 @@ export interface operations { readonly "application/json": { /** @description The body text of the pull request review */ readonly body?: string; - /** @description The review action you want to perform. The review actions include: `APPROVE`, `REQUEST_CHANGES`, or `COMMENT`. When you leave this blank, the API returns _HTTP 422 (Unrecognizable entity)_ and sets the review action state to `PENDING`, which means you will need to re-submit the pull request review using a review action. */ + /** + * @description The review action you want to perform. The review actions include: `APPROVE`, `REQUEST_CHANGES`, or `COMMENT`. When you leave this blank, the API returns _HTTP 422 (Unrecognizable entity)_ and sets the review action state to `PENDING`, which means you will need to re-submit the pull request review using a review action. + * @enum {string} + */ readonly event: "APPROVE" | "REQUEST_CHANGES" | "COMMENT"; }; }; @@ -30415,7 +30723,10 @@ export interface operations { readonly requestBody: { readonly content: { readonly "application/json": { - /** @description The state of the status. Can be one of `error`, `failure`, `pending`, or `success`. */ + /** + * @description The state of the status. Can be one of `error`, `failure`, `pending`, or `success`. + * @enum {string} + */ readonly state: "error" | "failure" | "pending" | "success"; /** * @description The target URL to associate with this status. This URL will be linked from the GitHub UI to allow users to easily see the source of the status. @@ -31706,6 +32017,7 @@ export interface operations { * @example [object Object] */ readonly Operations: readonly { + /** @enum {string} */ readonly op: "add" | "remove" | "replace"; readonly path?: string; readonly value?: @@ -32112,6 +32424,7 @@ export interface operations { * \* `closed` - visible to all members of this organization. * **For a parent or child team:** * \* `closed` - visible to all members of this organization. + * @enum {string} */ readonly privacy?: "secret" | "closed"; /** @@ -32120,6 +32433,7 @@ export interface operations { * \* `push` - team members can pull and push, but not administer newly-added repositories. * \* `admin` - team members can pull, push and administer newly-added repositories. * @default pull + * @enum {string} */ readonly permission?: "pull" | "push" | "admin"; /** @description The ID of a team to set as the parent team. */ @@ -32446,7 +32760,10 @@ export interface operations { readonly requestBody: { readonly content: { readonly "application/json": { - /** @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the team discussion comment. */ + /** + * @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the team discussion comment. + * @enum {string} + */ readonly content: "+1" | "-1" | "laugh" | "confused" | "heart" | "hooray" | "rocket" | "eyes"; }; }; @@ -32505,7 +32822,10 @@ export interface operations { readonly requestBody: { readonly content: { readonly "application/json": { - /** @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the team discussion. */ + /** + * @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the team discussion. + * @enum {string} + */ readonly content: "+1" | "-1" | "laugh" | "confused" | "heart" | "hooray" | "rocket" | "eyes"; }; }; @@ -32742,6 +33062,7 @@ export interface operations { * \* `member` - a normal member of the team. * \* `maintainer` - a team maintainer. Able to add/remove other team members, promote other team members to team maintainer, and edit the team's name and description. * @default member + * @enum {string} */ readonly role?: "member" | "maintainer"; }; @@ -32861,6 +33182,7 @@ export interface operations { * \* `write` - team members can read and write, but not administer this project. * \* `admin` - team members can read, write and administer this project. * Default: the team's `permission` attribute will be used to determine what permission to grant the team on this project. Note that, if you choose not to pass any parameters, you'll need to set `Content-Length` to zero when calling out to this endpoint. For more information, see "[HTTP verbs](https://docs.github.com/rest/overview/resources-in-the-rest-api#http-verbs)." + * @enum {string} */ readonly permission?: "read" | "write" | "admin"; }; @@ -32970,6 +33292,7 @@ export interface operations { * \* `admin` - team members can pull, push and administer this repository. * * If no permission is specified, the team's `permission` attribute will be used to determine what permission to grant the team on this repository. + * @enum {string} */ readonly permission?: "pull" | "push" | "admin"; }; @@ -33259,7 +33582,10 @@ export interface operations { * @example org@example.com */ readonly email: string; - /** @description Denotes whether an email is publically visible. */ + /** + * @description Denotes whether an email is publically visible. + * @enum {string} + */ readonly visibility: "public" | "private"; }; }; @@ -33932,7 +34258,10 @@ export interface operations { readonly requestBody: { readonly content: { readonly "application/json": { - /** @description The state that the membership should be in. Only `"active"` will be accepted. */ + /** + * @description The state that the membership should be in. Only `"active"` will be accepted. + * @enum {string} + */ readonly state: "active"; }; }; diff --git a/test/v3/expected/github.ts b/test/v3/expected/github.ts index 3a700e6e3..b591332fd 100644 --- a/test/v3/expected/github.ts +++ b/test/v3/expected/github.ts @@ -5379,7 +5379,10 @@ export interface components { */ id: number; account: (Partial & Partial) | null; - /** @description Describe whether all repositories have been selected or there's a selection involved */ + /** + * @description Describe whether all repositories have been selected or there's a selection involved + * @enum {string} + */ repository_selection: "all" | "selected"; /** * Format: uri @@ -5440,65 +5443,155 @@ export interface components { * @example [object Object] */ "app-permissions": { - /** @description The level of permission to grant the access token for GitHub Actions workflows, workflow runs, and artifacts. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token for GitHub Actions workflows, workflow runs, and artifacts. Can be one of: `read` or `write`. + * @enum {string} + */ actions?: "read" | "write"; - /** @description The level of permission to grant the access token for repository creation, deletion, settings, teams, and collaborators creation. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token for repository creation, deletion, settings, teams, and collaborators creation. Can be one of: `read` or `write`. + * @enum {string} + */ administration?: "read" | "write"; - /** @description The level of permission to grant the access token for checks on code. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token for checks on code. Can be one of: `read` or `write`. + * @enum {string} + */ checks?: "read" | "write"; - /** @description The level of permission to grant the access token for notification of content references and creation content attachments. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token for notification of content references and creation content attachments. Can be one of: `read` or `write`. + * @enum {string} + */ content_references?: "read" | "write"; - /** @description The level of permission to grant the access token for repository contents, commits, branches, downloads, releases, and merges. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token for repository contents, commits, branches, downloads, releases, and merges. Can be one of: `read` or `write`. + * @enum {string} + */ contents?: "read" | "write"; - /** @description The level of permission to grant the access token for deployments and deployment statuses. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token for deployments and deployment statuses. Can be one of: `read` or `write`. + * @enum {string} + */ deployments?: "read" | "write"; - /** @description The level of permission to grant the access token for managing repository environments. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token for managing repository environments. Can be one of: `read` or `write`. + * @enum {string} + */ environments?: "read" | "write"; - /** @description The level of permission to grant the access token for issues and related comments, assignees, labels, and milestones. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token for issues and related comments, assignees, labels, and milestones. Can be one of: `read` or `write`. + * @enum {string} + */ issues?: "read" | "write"; - /** @description The level of permission to grant the access token to search repositories, list collaborators, and access repository metadata. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to search repositories, list collaborators, and access repository metadata. Can be one of: `read` or `write`. + * @enum {string} + */ metadata?: "read" | "write"; - /** @description The level of permission to grant the access token for packages published to GitHub Packages. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token for packages published to GitHub Packages. Can be one of: `read` or `write`. + * @enum {string} + */ packages?: "read" | "write"; - /** @description The level of permission to grant the access token to retrieve Pages statuses, configuration, and builds, as well as create new builds. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to retrieve Pages statuses, configuration, and builds, as well as create new builds. Can be one of: `read` or `write`. + * @enum {string} + */ pages?: "read" | "write"; - /** @description The level of permission to grant the access token for pull requests and related comments, assignees, labels, milestones, and merges. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token for pull requests and related comments, assignees, labels, milestones, and merges. Can be one of: `read` or `write`. + * @enum {string} + */ pull_requests?: "read" | "write"; - /** @description The level of permission to grant the access token to manage the post-receive hooks for a repository. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to manage the post-receive hooks for a repository. Can be one of: `read` or `write`. + * @enum {string} + */ repository_hooks?: "read" | "write"; - /** @description The level of permission to grant the access token to manage repository projects, columns, and cards. Can be one of: `read`, `write`, or `admin`. */ + /** + * @description The level of permission to grant the access token to manage repository projects, columns, and cards. Can be one of: `read`, `write`, or `admin`. + * @enum {string} + */ repository_projects?: "read" | "write" | "admin"; - /** @description The level of permission to grant the access token to view and manage secret scanning alerts. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to view and manage secret scanning alerts. Can be one of: `read` or `write`. + * @enum {string} + */ secret_scanning_alerts?: "read" | "write"; - /** @description The level of permission to grant the access token to manage repository secrets. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to manage repository secrets. Can be one of: `read` or `write`. + * @enum {string} + */ secrets?: "read" | "write"; - /** @description The level of permission to grant the access token to view and manage security events like code scanning alerts. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to view and manage security events like code scanning alerts. Can be one of: `read` or `write`. + * @enum {string} + */ security_events?: "read" | "write"; - /** @description The level of permission to grant the access token to manage just a single file. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to manage just a single file. Can be one of: `read` or `write`. + * @enum {string} + */ single_file?: "read" | "write"; - /** @description The level of permission to grant the access token for commit statuses. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token for commit statuses. Can be one of: `read` or `write`. + * @enum {string} + */ statuses?: "read" | "write"; - /** @description The level of permission to grant the access token to retrieve Dependabot alerts. Can be one of: `read`. */ + /** + * @description The level of permission to grant the access token to retrieve Dependabot alerts. Can be one of: `read`. + * @enum {string} + */ vulnerability_alerts?: "read"; - /** @description The level of permission to grant the access token to update GitHub Actions workflow files. Can be one of: `write`. */ + /** + * @description The level of permission to grant the access token to update GitHub Actions workflow files. Can be one of: `write`. + * @enum {string} + */ workflows?: "write"; - /** @description The level of permission to grant the access token for organization teams and members. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token for organization teams and members. Can be one of: `read` or `write`. + * @enum {string} + */ members?: "read" | "write"; - /** @description The level of permission to grant the access token to manage access to an organization. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to manage access to an organization. Can be one of: `read` or `write`. + * @enum {string} + */ organization_administration?: "read" | "write"; - /** @description The level of permission to grant the access token to manage the post-receive hooks for an organization. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to manage the post-receive hooks for an organization. Can be one of: `read` or `write`. + * @enum {string} + */ organization_hooks?: "read" | "write"; - /** @description The level of permission to grant the access token for viewing an organization's plan. Can be one of: `read`. */ + /** + * @description The level of permission to grant the access token for viewing an organization's plan. Can be one of: `read`. + * @enum {string} + */ organization_plan?: "read"; - /** @description The level of permission to grant the access token to manage organization projects, columns, and cards. Can be one of: `read`, `write`, or `admin`. */ + /** + * @description The level of permission to grant the access token to manage organization projects, columns, and cards. Can be one of: `read`, `write`, or `admin`. + * @enum {string} + */ organization_projects?: "read" | "write" | "admin"; - /** @description The level of permission to grant the access token to manage organization secrets. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to manage organization secrets. Can be one of: `read` or `write`. + * @enum {string} + */ organization_secrets?: "read" | "write"; - /** @description The level of permission to grant the access token to view and manage GitHub Actions self-hosted runners available to an organization. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to view and manage GitHub Actions self-hosted runners available to an organization. Can be one of: `read` or `write`. + * @enum {string} + */ organization_self_hosted_runners?: "read" | "write"; - /** @description The level of permission to grant the access token to view and manage users blocked by the organization. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to view and manage users blocked by the organization. Can be one of: `read` or `write`. + * @enum {string} + */ organization_user_blocking?: "read" | "write"; - /** @description The level of permission to grant the access token to manage team discussions and related comments. Can be one of: `read` or `write`. */ + /** + * @description The level of permission to grant the access token to manage team discussions and related comments. Can be one of: `read` or `write`. + * @enum {string} + */ team_discussions?: "read" | "write"; }; /** @@ -5917,6 +6010,7 @@ export interface components { /** @example read */ single_file?: string; }; + /** @enum {string} */ repository_selection?: "all" | "selected"; repositories?: components["schemas"]["repository"][]; /** @example README.md */ @@ -5977,7 +6071,10 @@ export interface components { /** Scoped Installation */ "scoped-installation": { permissions: components["schemas"]["app-permissions"]; - /** @description Describe whether all repositories have been selected or there's a selection involved */ + /** + * @description Describe whether all repositories have been selected or there's a selection involved + * @enum {string} + */ repository_selection: "all" | "selected"; /** @example config.yaml */ single_file_name: string | null; @@ -6116,9 +6213,15 @@ export interface components { */ node_id?: string; }; - /** @description The policy that controls the organizations in the enterprise that are allowed to run GitHub Actions. Can be one of: `all`, `none`, or `selected`. */ + /** + * @description The policy that controls the organizations in the enterprise that are allowed to run GitHub Actions. Can be one of: `all`, `none`, or `selected`. + * @enum {string} + */ "enabled-organizations": "all" | "none" | "selected"; - /** @description The permissions policy that controls the actions that are allowed to run. Can be one of: `all`, `local_only`, or `selected`. */ + /** + * @description The permissions policy that controls the actions that are allowed to run. Can be one of: `all`, `local_only`, or `selected`. + * @enum {string} + */ "allowed-actions": "all" | "local_only" | "selected"; /** @description The API URL to use to get or set the actions that are allowed to run, when `allowed_actions` is set to `selected`. */ "selected-actions-url": string; @@ -6216,7 +6319,10 @@ export interface components { id?: number; /** @description Name of the label. */ name?: string; - /** @description The type of label. Read-only labels are applied automatically when the runner is configured. */ + /** + * @description The type of label. Read-only labels are applied automatically when the runner is configured. + * @enum {string} + */ type?: "read-only" | "custom"; }[]; }; @@ -6252,7 +6358,10 @@ export interface components { repositories?: components["schemas"]["repository"][]; /** @example config.yaml */ single_file?: string | null; - /** @description Describe whether all repositories have been selected or there's a selection involved */ + /** + * @description Describe whether all repositories have been selected or there's a selection involved + * @enum {string} + */ repository_selection?: "all" | "selected"; }; "audit-log-event": { @@ -6412,6 +6521,7 @@ export interface components { * @description The state of the milestone. * @default open * @example open + * @enum {string} */ state: "open" | "closed"; /** @@ -6451,6 +6561,7 @@ export interface components { * author_association * @description How the author is associated with the repository. * @example OWNER + * @enum {string} */ author_association: | "COLLABORATOR" @@ -7454,7 +7565,10 @@ export interface components { /** Format: date-time */ updated_at: string; }; - /** @description The policy that controls the repositories in the organization that are allowed to run GitHub Actions. Can be one of: `all`, `none`, or `selected`. */ + /** + * @description The policy that controls the repositories in the organization that are allowed to run GitHub Actions. Can be one of: `all`, `none`, or `selected`. + * @enum {string} + */ "enabled-repositories": "all" | "none" | "selected"; "actions-organization-permissions": { enabled_repositories: components["schemas"]["enabled-repositories"]; @@ -7489,7 +7603,10 @@ export interface components { created_at: string; /** Format: date-time */ updated_at: string; - /** @description Visibility of a secret */ + /** + * @description Visibility of a secret + * @enum {string} + */ visibility: "all" | "private" | "selected"; /** * Format: uri @@ -7649,6 +7766,7 @@ export interface components { /** * @description The type of GitHub user that can comment, open issues, or create pull requests while the interaction limit is in effect. Can be one of: `existing_users`, `contributors_only`, `collaborators_only`. * @example collaborators_only + * @enum {string} */ "interaction-group": "existing_users" | "contributors_only" | "collaborators_only"; /** @@ -7668,6 +7786,7 @@ export interface components { /** * @description The duration of the interaction restriction. Can be one of: `one_day`, `three_days`, `one_week`, `one_month`, `six_months`. Default: `one_day`. * @example one_month + * @enum {string} */ "interaction-expiry": "one_day" | "three_days" | "one_week" | "one_month" | "six_months"; /** @@ -7836,7 +7955,10 @@ export interface components { * @example super-linter */ name: string; - /** @example docker */ + /** + * @example docker + * @enum {string} + */ package_type: "npm" | "maven" | "rubygems" | "docker" | "nuget" | "container"; /** @example https://api.github.com/orgs/github/packages/container/super-linter */ url: string; @@ -7847,7 +7969,10 @@ export interface components { * @example 1 */ version_count: number; - /** @example private */ + /** + * @example private + * @enum {string} + */ visibility: "private" | "public"; owner?: components["schemas"]["simple-user"] | null; repository?: components["schemas"]["minimal-repository"] | null; @@ -7897,7 +8022,10 @@ export interface components { deleted_at?: string; /** Package Version Metadata */ metadata?: { - /** @example docker */ + /** + * @example docker + * @enum {string} + */ package_type: "npm" | "maven" | "rubygems" | "docker" | "nuget" | "container"; /** Container Metadata */ container?: { @@ -7968,7 +8096,10 @@ export interface components { * @example 2014-03-03T18:58:10Z */ updated_at: string; - /** @description The baseline permission that all organization members have on this project. Only present if owner is an organization. */ + /** + * @description The baseline permission that all organization members have on this project. Only present if owner is an organization. + * @enum {string} + */ organization_permission?: "read" | "write" | "admin" | "none"; /** @description Whether or not this project can be seen by everyone. Only present if owner is an organization. */ private?: boolean; @@ -8045,6 +8176,7 @@ export interface components { /** * @description The level of privacy this team should have * @example closed + * @enum {string} */ privacy?: "closed" | "secret"; /** @@ -8223,6 +8355,7 @@ export interface components { /** * @description The reaction to use * @example heart + * @enum {string} */ content: "+1" | "-1" | "laugh" | "confused" | "heart" | "hooray" | "rocket" | "eyes"; /** @@ -8242,6 +8375,7 @@ export interface components { * @description The role of the user in the team. * @default member * @example member + * @enum {string} */ role: "member" | "maintainer"; state: string; @@ -8991,6 +9125,7 @@ export interface components { /** * @description The phase of the lifecycle that the job is currently in. * @example queued + * @enum {string} */ status: "queued" | "in_progress" | "completed"; /** @@ -9020,6 +9155,7 @@ export interface components { /** * @description The phase of the lifecycle that the job is currently in. * @example queued + * @enum {string} */ status: "queued" | "in_progress" | "completed"; /** @@ -9232,6 +9368,7 @@ export interface components { /** * @description Whether deployment to the environment(s) was approved or rejected * @example approved + * @enum {string} */ state: "approved" | "rejected"; user: components["schemas"]["simple-user"]; @@ -9244,6 +9381,7 @@ export interface components { /** * @description The type of reviewer. Must be one of: `User` or `Team` * @example User + * @enum {string} */ "deployment-reviewer-type": "User" | "Team"; /** @@ -9412,7 +9550,10 @@ export interface components { name: string; /** @example ruby.yaml */ path: string; - /** @example active */ + /** + * @example active + * @enum {string} + */ state: "active" | "deleted"; /** * Format: date-time @@ -9926,9 +10067,13 @@ export interface components { /** * @description The phase of the lifecycle that the check is currently in. * @example queued + * @enum {string} */ status: "queued" | "in_progress" | "completed"; - /** @example neutral */ + /** + * @example neutral + * @enum {string|null} + */ conclusion: | ("success" | "failure" | "neutral" | "cancelled" | "skipped" | "timed_out" | "action_required") | null; @@ -10003,9 +10148,15 @@ export interface components { * @example 009b8a3a9ccbb128af87f9b1c0f4c62e8a304f6d */ head_sha: string; - /** @example completed */ + /** + * @example completed + * @enum {string|null} + */ status: ("queued" | "in_progress" | "completed") | null; - /** @example neutral */ + /** + * @example neutral + * @enum {string|null} + */ conclusion: | ("success" | "failure" | "neutral" | "cancelled" | "skipped" | "timed_out" | "action_required") | null; @@ -10045,7 +10196,10 @@ export interface components { "code-scanning-analysis-tool-guid": string | null; /** @description The full Git reference, formatted as `refs/heads/`. */ "code-scanning-ref": string; - /** @description State of a code scanning alert. */ + /** + * @description State of a code scanning alert. + * @enum {string} + */ "code-scanning-alert-state": "open" | "dismissed" | "fixed"; /** @description The security alert number. */ "alert-number": number; @@ -10081,7 +10235,10 @@ export interface components { id?: string | null; /** @description The name of the rule used to detect the alert. */ name?: string; - /** @description The severity of the alert. */ + /** + * @description The severity of the alert. + * @enum {string|null} + */ severity?: ("none" | "note" | "warning" | "error") | null; /** @description A short description of the rule used to detect the alert. */ description?: string; @@ -10105,7 +10262,10 @@ export interface components { start_column?: number; end_column?: number; }; - /** @description A classification of the file. For example to identify it as generated. */ + /** + * @description A classification of the file. For example to identify it as generated. + * @enum {string|null} + */ "code-scanning-alert-classification": ("source" | "generated" | "test" | "library") | null; "code-scanning-alert-instance": { ref?: components["schemas"]["code-scanning-ref"]; @@ -10143,7 +10303,10 @@ export interface components { id?: string | null; /** @description The name of the rule used to detect the alert. */ name?: string; - /** @description The severity of the alert. */ + /** + * @description The severity of the alert. + * @enum {string|null} + */ severity?: ("none" | "note" | "warning" | "error") | null; /** @description A short description of the rule used to detect the alert. */ description?: string; @@ -10168,7 +10331,10 @@ export interface components { tool: components["schemas"]["code-scanning-analysis-tool"]; most_recent_instance: components["schemas"]["code-scanning-alert-instance"]; }; - /** @description Sets the state of the code scanning alert. Can be one of `open` or `dismissed`. You must provide `dismissed_reason` when you set the state to `dismissed`. */ + /** + * @description Sets the state of the code scanning alert. Can be one of `open` or `dismissed`. You must provide `dismissed_reason` when you set the state to `dismissed`. + * @enum {string} + */ "code-scanning-alert-set-state": "open" | "dismissed"; /** * @description An identifier for the upload. @@ -10247,7 +10413,10 @@ export interface components { url?: string; }; "code-scanning-sarifs-status": { - /** @description `pending` files have not yet been processed, while `complete` means all results in the SARIF have been stored. */ + /** + * @description `pending` files have not yet been processed, while `complete` means all results in the SARIF have been stored. + * @enum {string} + */ processing_status?: "pending" | "complete"; /** * Format: uri @@ -10341,6 +10510,7 @@ export interface components { /** * @description The permission associated with the invitation. * @example read + * @enum {string} */ permissions: "read" | "write" | "admin"; /** @@ -10408,7 +10578,10 @@ export interface components { */ auto_merge: { enabled_by: components["schemas"]["simple-user"]; - /** @description The merge method to use. */ + /** + * @description The merge method to use. + * @enum {string} + */ merge_method: "merge" | "squash" | "rebase"; /** @description Title for the merge commit message. */ commit_title: string; @@ -10703,7 +10876,10 @@ export interface components { patch_url: string; base_commit: components["schemas"]["commit"]; merge_base_commit: components["schemas"]["commit"]; - /** @example ahead */ + /** + * @example ahead + * @enum {string} + */ status: "diverged" | "ahead" | "behind" | "identical"; /** @example 4 */ ahead_by: number; @@ -10992,6 +11168,7 @@ export interface components { /** * @description The state of the status. * @example success + * @enum {string} */ state: "error" | "failure" | "inactive" | "pending" | "success" | "queued" | "in_progress"; creator: components["schemas"]["simple-user"] | null; @@ -11403,6 +11580,7 @@ export interface components { vcs_url: string; svc_root?: string; tfvc_project?: string; + /** @enum {string} */ status: | "auth" | "error" @@ -11661,6 +11839,7 @@ export interface components { /** * @description The status of the most recent build of the Page. * @example built + * @enum {string|null} */ status: ("built" | "building" | "errored") | null; /** @@ -11779,6 +11958,7 @@ export interface components { /** * @description State of this Pull Request. Either `open` or `closed`. * @example open + * @enum {string} */ state: "open" | "closed"; /** @example true */ @@ -12334,6 +12514,7 @@ export interface components { /** * @description The side of the first line of the range for a multi-line comment. * @default RIGHT + * @enum {string|null} */ start_side?: ("LEFT" | "RIGHT") | null; /** @@ -12349,6 +12530,7 @@ export interface components { /** * @description The side of the diff to which the comment applies. The side of the last line of the range for a multi-line comment * @default RIGHT + * @enum {string} */ side?: "LEFT" | "RIGHT"; reactions?: components["schemas"]["reaction-rollup"]; @@ -12487,11 +12669,13 @@ export interface components { /** * @description The side of the first line of the range for a multi-line comment. * @default RIGHT + * @enum {string} */ side?: "LEFT" | "RIGHT"; /** * @description The side of the first line of the range for a multi-line comment. * @default RIGHT + * @enum {string|null} */ start_side?: ("LEFT" | "RIGHT") | null; /** @@ -12532,7 +12716,10 @@ export interface components { */ name: string; label: string | null; - /** @description State of the release asset. */ + /** + * @description State of the release asset. + * @enum {string} + */ state: "uploaded" | "open"; content_type: string; size: number; @@ -12586,7 +12773,10 @@ export interface components { body_html?: string; body_text?: string; }; - /** @description Sets the state of the secret scanning alert. Can be either `open` or `resolved`. You must provide `resolution` when you set the state to `resolved`. */ + /** + * @description Sets the state of the secret scanning alert. Can be either `open` or `resolved`. You must provide `resolution` when you set the state to `resolved`. + * @enum {string} + */ "secret-scanning-alert-state": "open" | "resolved"; /** @description **Required when the `state` is `resolved`.** The reason for resolving the alert. Can be one of `false_positive`, `wont_fix`, `revoked`, or `used_in_tests`. */ "secret-scanning-alert-resolution": string | null; @@ -12938,6 +13128,7 @@ export interface components { * @example [object Object] */ operations?: { + /** @enum {string} */ op: "add" | "remove" | "replace"; path?: string; value?: string | { [key: string]: unknown } | unknown[]; @@ -15253,7 +15444,10 @@ export interface operations { "application/json": { /** @description Name of the runner group. */ name: string; - /** @description Visibility of a runner group. You can select all organizations or select individual organization. Can be one of: `all` or `selected` */ + /** + * @description Visibility of a runner group. You can select all organizations or select individual organization. Can be one of: `all` or `selected` + * @enum {string} + */ visibility?: "selected" | "all"; /** @description List of organization IDs that can access the runner group. */ selected_organization_ids?: number[]; @@ -15335,6 +15529,7 @@ export interface operations { /** * @description Visibility of a runner group. You can select all organizations or select individual organizations. Can be one of: `all` or `selected` * @default all + * @enum {string} */ visibility?: "selected" | "all"; }; @@ -16522,6 +16717,7 @@ export interface operations { * @description The rendering mode. * @default markdown * @example markdown + * @enum {string} */ mode?: "markdown" | "gfm"; /** @description The repository context to use when creating references in `gfm` mode. */ @@ -17057,6 +17253,7 @@ export interface operations { * \* `admin` - can pull, push, and administer this repository. * \* `none` - no permissions granted by default. * @default read + * @enum {string} */ default_repository_permission?: "read" | "write" | "admin" | "none"; /** @@ -17095,6 +17292,7 @@ export interface operations { * \* `private` - members can create private repositories. This option is only available to repositories that are part of an organization on GitHub Enterprise Cloud. * \* `none` - only admin members can create repositories. * **Note:** This parameter is deprecated and will be removed in the future. Its return value ignores internal repositories. Using this parameter overrides values set in `members_can_create_repositories`. See the parameter deprecation notice in the operation description for details. + * @enum {string} */ members_allowed_repository_creation_type?: "all" | "private" | "none"; /** @@ -17362,6 +17560,7 @@ export interface operations { /** * @description Visibility of a runner group. You can select all repositories, select individual repositories, or limit access to private repositories. Can be one of: `all`, `selected`, or `private`. * @default all + * @enum {string} */ visibility?: "selected" | "all" | "private"; /** @description List of repository IDs that can access the runner group. */ @@ -17444,7 +17643,10 @@ export interface operations { "application/json": { /** @description Name of the runner group. */ name?: string; - /** @description Visibility of a runner group. You can select all repositories, select individual repositories, or all private repositories. Can be one of: `all`, `selected`, or `private`. */ + /** + * @description Visibility of a runner group. You can select all repositories, select individual repositories, or all private repositories. Can be one of: `all`, `selected`, or `private`. + * @enum {string} + */ visibility?: "selected" | "all" | "private"; }; }; @@ -17969,6 +18171,7 @@ export interface operations { * \- `all` - All repositories in an organization can access the secret. * \- `private` - Private repositories in an organization can access the secret. * \- `selected` - Only specific repositories can access the secret. + * @enum {string} */ visibility?: "all" | "private" | "selected"; /** @description An array of repository ids that can access the organization secret. You can only provide a list of repository ids when the `visibility` is set to `selected`. You can manage the list of selected repositories using the [List selected repositories for an organization secret](https://docs.github.com/rest/reference/actions#list-selected-repositories-for-an-organization-secret), [Set selected repositories for an organization secret](https://docs.github.com/rest/reference/actions#set-selected-repositories-for-an-organization-secret), and [Remove selected repository from an organization secret](https://docs.github.com/rest/reference/actions#remove-selected-repository-from-an-organization-secret) endpoints. */ @@ -18627,6 +18830,7 @@ export interface operations { * \* `direct_member` - Non-owner organization members with ability to see other members and join teams by invitation. * \* `billing_manager` - Non-owner organization members with ability to manage the billing settings of your organization. * @default direct_member + * @enum {string} */ role?: "admin" | "direct_member" | "billing_manager"; /** @description Specify IDs for the teams you want to invite new members to. */ @@ -18856,6 +19060,7 @@ export interface operations { * \* `admin` - The user will become an owner of the organization. * \* `member` - The user will become a non-owner member of the organization. * @default member + * @enum {string} */ role?: "admin" | "member"; }; @@ -19505,6 +19710,7 @@ export interface operations { /** * @description Can be `public` or `private`. If your organization is associated with an enterprise account using GitHub Enterprise Cloud or GitHub Enterprise Server 2.20+, `visibility` can also be `internal`. For more information, see "[Creating an internal repository](https://help.github.com/en/github/creating-cloning-and-archiving-repositories/about-repository-visibility#about-internal-repositories)" in the GitHub Help documentation. * The `visibility` parameter overrides the `private` parameter when you use both parameters with the `nebula-preview` preview header. + * @enum {string} */ visibility?: "public" | "private" | "visibility" | "internal"; /** @@ -19715,6 +19921,7 @@ export interface operations { * **For a parent or child team:** * \* `closed` - visible to all members of this organization. * Default for child team: `closed` + * @enum {string} */ privacy?: "secret" | "closed"; /** @@ -19723,6 +19930,7 @@ export interface operations { * \* `push` - team members can pull and push, but not administer newly-added repositories. * \* `admin` - team members can pull, push and administer newly-added repositories. * @default pull + * @enum {string} */ permission?: "pull" | "push" | "admin"; /** @description The ID of a team to set as the parent team. */ @@ -19809,6 +20017,7 @@ export interface operations { * \* `closed` - visible to all members of this organization. * **For a parent or child team:** * \* `closed` - visible to all members of this organization. + * @enum {string} */ privacy?: "secret" | "closed"; /** @@ -19817,6 +20026,7 @@ export interface operations { * \* `push` - team members can pull and push, but not administer newly-added repositories. * \* `admin` - team members can pull, push and administer newly-added repositories. * @default pull + * @enum {string} */ permission?: "pull" | "push" | "admin"; /** @description The ID of a team to set as the parent team. */ @@ -20167,7 +20377,10 @@ export interface operations { requestBody: { content: { "application/json": { - /** @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the team discussion comment. */ + /** + * @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the team discussion comment. + * @enum {string} + */ content: "+1" | "-1" | "laugh" | "confused" | "heart" | "hooray" | "rocket" | "eyes"; }; }; @@ -20251,7 +20464,10 @@ export interface operations { requestBody: { content: { "application/json": { - /** @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the team discussion. */ + /** + * @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the team discussion. + * @enum {string} + */ content: "+1" | "-1" | "laugh" | "confused" | "heart" | "hooray" | "rocket" | "eyes"; }; }; @@ -20424,6 +20640,7 @@ export interface operations { * \* `member` - a normal member of the team. * \* `maintainer` - a team maintainer. Able to add/remove other team members, promote other team members to team maintainer, and edit the team's name and description. * @default member + * @enum {string} */ role?: "member" | "maintainer"; }; @@ -20545,6 +20762,7 @@ export interface operations { * \* `write` - team members can read and write, but not administer this project. * \* `admin` - team members can read, write and administer this project. * Default: the team's `permission` attribute will be used to determine what permission to grant the team on this project. Note that, if you choose not to pass any parameters, you'll need to set `Content-Length` to zero when calling out to this endpoint. For more information, see "[HTTP verbs](https://docs.github.com/rest/overview/resources-in-the-rest-api#http-verbs)." + * @enum {string} */ permission?: "read" | "write" | "admin"; } | null; @@ -20664,6 +20882,7 @@ export interface operations { * \* `triage` - team members can proactively manage issues and pull requests without write access. Recommended for contributors who triage a repository. Only applies to repositories owned by organizations. * * If no permission is specified, the team's `permission` attribute will be used to determine what permission to grant the team on this repository. + * @enum {string} */ permission?: "pull" | "push" | "admin" | "maintain" | "triage"; }; @@ -21213,7 +21432,10 @@ export interface operations { * @example open */ state?: string; - /** @description The baseline permission that all organization members have on this project */ + /** + * @description The baseline permission that all organization members have on this project + * @enum {string} + */ organization_permission?: "read" | "write" | "admin" | "none"; /** @description Whether or not this project can be seen by everyone. */ private?: boolean; @@ -21282,6 +21504,7 @@ export interface operations { * @description The permission to grant the collaborator. * @default write * @example write + * @enum {string} */ permission?: "read" | "write" | "admin"; }; @@ -21510,7 +21733,10 @@ export interface operations { * **Note**: You will get a `422` error if the organization restricts [changing repository visibility](https://help.github.com/articles/repository-permission-levels-for-an-organization#changing-the-visibility-of-repositories) to organization owners and a non-owner tries to change the value of private. **Note**: You will get a `422` error if the organization restricts [changing repository visibility](https://help.github.com/articles/repository-permission-levels-for-an-organization#changing-the-visibility-of-repositories) to organization owners and a non-owner tries to change the value of private. */ private?: boolean; - /** @description Can be `public` or `private`. If your organization is associated with an enterprise account using GitHub Enterprise Cloud or GitHub Enterprise Server 2.20+, `visibility` can also be `internal`. The `visibility` parameter overrides the `private` parameter when you use both along with the `nebula-preview` preview header. */ + /** + * @description Can be `public` or `private`. If your organization is associated with an enterprise account using GitHub Enterprise Cloud or GitHub Enterprise Server 2.20+, `visibility` can also be `internal`. The `visibility` parameter overrides the `private` parameter when you use both along with the `nebula-preview` preview header. + * @enum {string} + */ visibility?: "public" | "private" | "visibility" | "internal"; /** * @description Either `true` to enable issues for this repository or `false` to disable them. @@ -22185,6 +22411,7 @@ export interface operations { /** * @description Whether to approve or reject deployment to the specified environments. Must be one of: `approved` or `rejected` * @example approved + * @enum {string} */ state: "approved" | "rejected"; /** @@ -23733,6 +23960,7 @@ export interface operations { content: { "application/json": (Partial< { + /** @enum {undefined} */ status?: "completed"; } & { conclusion: unknown; @@ -23740,6 +23968,7 @@ export interface operations { > & Partial< { + /** @enum {undefined} */ status?: "queued" | "in_progress"; } & { [key: string]: unknown } >) & { @@ -23754,6 +23983,7 @@ export interface operations { /** * @description The current status. Can be one of `queued`, `in_progress`, or `completed`. * @default queued + * @enum {string} */ status?: "queued" | "in_progress" | "completed"; /** @description The time that the check run began. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`. */ @@ -23761,6 +23991,7 @@ export interface operations { /** * @description **Required if you provide `completed_at` or a `status` of `completed`**. The final conclusion of the check. Can be one of `action_required`, `cancelled`, `failure`, `neutral`, `success`, `skipped`, `stale`, or `timed_out`. When the conclusion is `action_required`, additional details should be provided on the site specified by `details_url`. * **Note:** Providing `conclusion` will automatically set the `status` parameter to `completed`. You cannot change a check run conclusion to `stale`, only GitHub can set this. + * @enum {string} */ conclusion?: | "action_required" @@ -23793,7 +24024,10 @@ export interface operations { start_column?: number; /** @description The end column of the annotation. Annotations only support `start_column` and `end_column` on the same line. Omit this parameter if `start_line` and `end_line` have different values. */ end_column?: number; - /** @description The level of the annotation. Can be one of `notice`, `warning`, or `failure`. */ + /** + * @description The level of the annotation. Can be one of `notice`, `warning`, or `failure`. + * @enum {string} + */ annotation_level: "notice" | "warning" | "failure"; /** @description A short description of the feedback for these lines of code. The maximum size is 64 KB. */ message: string; @@ -23874,6 +24108,7 @@ export interface operations { content: { "application/json": (Partial< { + /** @enum {undefined} */ status?: "completed"; } & { conclusion: unknown; @@ -23881,6 +24116,7 @@ export interface operations { > & Partial< { + /** @enum {undefined} */ status?: "queued" | "in_progress"; } & { [key: string]: unknown } >) & { @@ -23892,11 +24128,15 @@ export interface operations { external_id?: string; /** @description This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`. */ started_at?: string; - /** @description The current status. Can be one of `queued`, `in_progress`, or `completed`. */ + /** + * @description The current status. Can be one of `queued`, `in_progress`, or `completed`. + * @enum {string} + */ status?: "queued" | "in_progress" | "completed"; /** * @description **Required if you provide `completed_at` or a `status` of `completed`**. The final conclusion of the check. Can be one of `action_required`, `cancelled`, `failure`, `neutral`, `success`, `skipped`, `stale`, or `timed_out`. * **Note:** Providing `conclusion` will automatically set the `status` parameter to `completed`. You cannot change a check run conclusion to `stale`, only GitHub can set this. + * @enum {string} */ conclusion?: | "action_required" @@ -23929,7 +24169,10 @@ export interface operations { start_column?: number; /** @description The end column of the annotation. Annotations only support `start_column` and `end_column` on the same line. Omit this parameter if `start_line` and `end_line` have different values. */ end_column?: number; - /** @description The level of the annotation. Can be one of `notice`, `warning`, or `failure`. */ + /** + * @description The level of the annotation. Can be one of `notice`, `warning`, or `failure`. + * @enum {string} + */ annotation_level: "notice" | "warning" | "failure"; /** @description A short description of the feedback for these lines of code. The maximum size is 64 KB. */ message: string; @@ -24633,6 +24876,7 @@ export interface operations { * \* `maintain` - Recommended for project managers who need to manage the repository without access to sensitive or destructive actions. * \* `triage` - Recommended for contributors who need to proactively manage issues and pull requests without write access. * @default push + * @enum {string} */ permission?: "pull" | "push" | "admin" | "maintain" | "triage"; /** @example "push" */ @@ -24821,7 +25065,10 @@ export interface operations { requestBody: { content: { "application/json": { - /** @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the commit comment. */ + /** + * @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the commit comment. + * @enum {string} + */ content: "+1" | "-1" | "laugh" | "confused" | "heart" | "hooray" | "rocket" | "eyes"; }; }; @@ -25814,7 +26061,10 @@ export interface operations { requestBody: { content: { "application/json": { - /** @description The state of the status. Can be one of `error`, `failure`, `inactive`, `in_progress`, `queued` `pending`, or `success`. **Note:** To use the `inactive` state, you must provide the [`application/vnd.github.ant-man-preview+json`](https://docs.github.com/rest/overview/api-previews#enhanced-deployments) custom media type. To use the `in_progress` and `queued` states, you must provide the [`application/vnd.github.flash-preview+json`](https://docs.github.com/rest/overview/api-previews#deployment-statuses) custom media type. When you set a transient deployment to `inactive`, the deployment will be shown as `destroyed` in GitHub. */ + /** + * @description The state of the status. Can be one of `error`, `failure`, `inactive`, `in_progress`, `queued` `pending`, or `success`. **Note:** To use the `inactive` state, you must provide the [`application/vnd.github.ant-man-preview+json`](https://docs.github.com/rest/overview/api-previews#enhanced-deployments) custom media type. To use the `in_progress` and `queued` states, you must provide the [`application/vnd.github.flash-preview+json`](https://docs.github.com/rest/overview/api-previews#deployment-statuses) custom media type. When you set a transient deployment to `inactive`, the deployment will be shown as `destroyed` in GitHub. + * @enum {string} + */ state: "error" | "failure" | "inactive" | "in_progress" | "queued" | "pending" | "success"; /** @description The target URL to associate with this status. This URL should contain output to keep the user updated while the task is running or serve as historical information for what happened in the deployment. **Note:** It's recommended to use the `log_url` parameter, which replaces `target_url`. */ target_url?: string; @@ -25825,7 +26075,10 @@ export interface operations { log_url?: string; /** @description A short description of the status. The maximum description length is 140 characters. */ description?: string; - /** @description Name for the target deployment environment, which can be changed when setting a deploy status. For example, `production`, `staging`, or `qa`. **Note:** This parameter requires you to use the [`application/vnd.github.flash-preview+json`](https://docs.github.com/rest/overview/api-previews#deployment-statuses) custom media type. */ + /** + * @description Name for the target deployment environment, which can be changed when setting a deploy status. For example, `production`, `staging`, or `qa`. **Note:** This parameter requires you to use the [`application/vnd.github.flash-preview+json`](https://docs.github.com/rest/overview/api-previews#deployment-statuses) custom media type. + * @enum {string} + */ environment?: "production" | "staging" | "qa"; /** * @description Sets the URL for accessing your environment. Default: `""` @@ -26484,7 +26737,10 @@ export interface operations { message: string; /** @description The SHA of the git object this is tagging. */ object: string; - /** @description The type of the object we're tagging. Normally this is a `commit` but it can also be a `tree` or a `blob`. */ + /** + * @description The type of the object we're tagging. Normally this is a `commit` but it can also be a `tree` or a `blob`. + * @enum {string} + */ type: "commit" | "tree" | "blob"; /** @description An object with information about the individual creating the tag. */ tagger?: { @@ -26580,9 +26836,15 @@ export interface operations { tree: { /** @description The file referenced in the tree. */ path?: string; - /** @description The file mode; one of `100644` for file (blob), `100755` for executable (blob), `040000` for subdirectory (tree), `160000` for submodule (commit), or `120000` for a blob that specifies the path of a symlink. */ + /** + * @description The file mode; one of `100644` for file (blob), `100755` for executable (blob), `040000` for subdirectory (tree), `160000` for submodule (commit), or `120000` for a blob that specifies the path of a symlink. + * @enum {string} + */ mode?: "100644" | "100755" | "040000" | "160000" | "120000"; - /** @description Either `blob`, `tree`, or `commit`. */ + /** + * @description Either `blob`, `tree`, or `commit`. + * @enum {string} + */ type?: "blob" | "tree" | "commit"; /** * @description The SHA1 checksum ID of the object in the tree. Also called `tree.sha`. If the value is `null` then the file will be deleted. @@ -26964,7 +27226,10 @@ export interface operations { "application/json": { /** @description The URL of the originating repository. */ vcs_url: string; - /** @description The originating VCS type. Can be one of `subversion`, `git`, `mercurial`, or `tfvc`. Please be aware that without this parameter, the import job will take additional time to detect the VCS type before beginning the import. This detection step will be reflected in the response. */ + /** + * @description The originating VCS type. Can be one of `subversion`, `git`, `mercurial`, or `tfvc`. Please be aware that without this parameter, the import job will take additional time to detect the VCS type before beginning the import. This detection step will be reflected in the response. + * @enum {string} + */ vcs?: "subversion" | "git" | "mercurial" | "tfvc"; /** @description If authentication is required, the username to provide to `vcs_url`. */ vcs_username?: string; @@ -27118,7 +27383,10 @@ export interface operations { requestBody: { content: { "application/json": { - /** @description Can be one of `opt_in` (large files will be stored using Git LFS) or `opt_out` (large files will be removed during the import). */ + /** + * @description Can be one of `opt_in` (large files will be stored using Git LFS) or `opt_out` (large files will be removed during the import). + * @enum {string} + */ use_lfs: "opt_in" | "opt_out"; }; }; @@ -27261,7 +27529,10 @@ export interface operations { requestBody: { content: { "application/json": { - /** @description The permissions that the associated user will have on the repository. Valid values are `read`, `write`, `maintain`, `triage`, and `admin`. */ + /** + * @description The permissions that the associated user will have on the repository. Valid values are `read`, `write`, `maintain`, `triage`, and `admin`. + * @enum {string} + */ permissions?: "read" | "write" | "maintain" | "triage" | "admin"; }; }; @@ -27524,7 +27795,10 @@ export interface operations { requestBody: { content: { "application/json": { - /** @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the issue comment. */ + /** + * @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the issue comment. + * @enum {string} + */ content: "+1" | "-1" | "laugh" | "confused" | "heart" | "hooray" | "rocket" | "eyes"; }; }; @@ -27662,7 +27936,10 @@ export interface operations { body?: string | null; /** @description Login for the user that this issue should be assigned to. **This field is deprecated.** */ assignee?: string | null; - /** @description State of the issue. Either `open` or `closed`. */ + /** + * @description State of the issue. Either `open` or `closed`. + * @enum {string} + */ state?: "open" | "closed"; milestone?: (string | number) | null; /** @description Labels to associate with this issue. Pass one or more Labels to _replace_ the set of Labels on this Issue. Send an empty array (`[]`) to clear all Labels from the Issue. _NOTE: Only users with push access can set labels for issues. Labels are silently dropped otherwise._ */ @@ -27976,6 +28253,7 @@ export interface operations { * \* `too heated` * \* `resolved` * \* `spam` + * @enum {string} */ lock_reason?: "off-topic" | "too heated" | "resolved" | "spam"; } | null; @@ -28053,7 +28331,10 @@ export interface operations { requestBody: { content: { "application/json": { - /** @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the issue. */ + /** + * @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the issue. + * @enum {string} + */ content: "+1" | "-1" | "laugh" | "confused" | "heart" | "hooray" | "rocket" | "eyes"; }; }; @@ -28464,6 +28745,7 @@ export interface operations { /** * @description The state of the milestone. Either `open` or `closed`. * @default open + * @enum {string} */ state?: "open" | "closed"; /** @description A description of the milestone. */ @@ -28533,6 +28815,7 @@ export interface operations { /** * @description The state of the milestone. Either `open` or `closed`. * @default open + * @enum {string} */ state?: "open" | "closed"; /** @description A description of the milestone. */ @@ -28663,7 +28946,10 @@ export interface operations { Partial<{ /** @description The repository branch used to publish your site's source files. */ branch: string; - /** @description The repository directory that includes the source files for the Pages site. Allowed paths are `/` or `/docs`. */ + /** + * @description The repository directory that includes the source files for the Pages site. Allowed paths are `/` or `/docs`. + * @enum {string} + */ path: "/" | "/docs"; }>; }; @@ -28699,6 +28985,7 @@ export interface operations { /** * @description The repository directory that includes the source files for the Pages site. Allowed paths are `/` or `/docs`. Default: `/` * @default / + * @enum {string} */ path?: "/" | "/docs"; }; @@ -29099,7 +29386,10 @@ export interface operations { requestBody: { content: { "application/json": { - /** @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the pull request review comment. */ + /** + * @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the pull request review comment. + * @enum {string} + */ content: "+1" | "-1" | "laugh" | "confused" | "heart" | "hooray" | "rocket" | "eyes"; }; }; @@ -29192,7 +29482,10 @@ export interface operations { title?: string; /** @description The contents of the pull request. */ body?: string; - /** @description State of this Pull Request. Either `open` or `closed`. */ + /** + * @description State of this Pull Request. Either `open` or `closed`. + * @enum {string} + */ state?: "open" | "closed"; /** @description The name of the branch you want your changes pulled into. This should be an existing branch on the current repository. You cannot update the base branch on a pull request to point to another repository. */ base?: string; @@ -29274,13 +29567,19 @@ export interface operations { path?: string; /** @description **Required without `comfort-fade` preview**. The position in the diff where you want to add a review comment. Note this value is not the same as the line number in the file. For help finding the position value, read the note above. */ position?: number; - /** @description **Required with `comfort-fade` preview**. In a split diff view, the side of the diff that the pull request's changes appear on. Can be `LEFT` or `RIGHT`. Use `LEFT` for deletions that appear in red. Use `RIGHT` for additions that appear in green or unchanged lines that appear in white and are shown for context. For a multi-line comment, side represents whether the last line of the comment range is a deletion or addition. For more information, see "[Diff view options](https://help.github.com/en/articles/about-comparing-branches-in-pull-requests#diff-view-options)" in the GitHub Help documentation. */ + /** + * @description **Required with `comfort-fade` preview**. In a split diff view, the side of the diff that the pull request's changes appear on. Can be `LEFT` or `RIGHT`. Use `LEFT` for deletions that appear in red. Use `RIGHT` for additions that appear in green or unchanged lines that appear in white and are shown for context. For a multi-line comment, side represents whether the last line of the comment range is a deletion or addition. For more information, see "[Diff view options](https://help.github.com/en/articles/about-comparing-branches-in-pull-requests#diff-view-options)" in the GitHub Help documentation. + * @enum {string} + */ side?: "LEFT" | "RIGHT"; /** @description **Required with `comfort-fade` preview**. The line of the blob in the pull request diff that the comment applies to. For a multi-line comment, the last line of the range that your comment applies to. */ line?: number; /** @description **Required when using multi-line comments**. To create multi-line comments, you must use the `comfort-fade` preview header. The `start_line` is the first line in the pull request diff that your multi-line comment applies to. To learn more about multi-line comments, see "[Commenting on a pull request](https://help.github.com/en/articles/commenting-on-a-pull-request#adding-line-comments-to-a-pull-request)" in the GitHub Help documentation. */ start_line?: number; - /** @description **Required when using multi-line comments**. To create multi-line comments, you must use the `comfort-fade` preview header. The `start_side` is the starting side of the diff that the comment applies to. Can be `LEFT` or `RIGHT`. To learn more about multi-line comments, see "[Commenting on a pull request](https://help.github.com/en/articles/commenting-on-a-pull-request#adding-line-comments-to-a-pull-request)" in the GitHub Help documentation. See `side` in this table for additional context. */ + /** + * @description **Required when using multi-line comments**. To create multi-line comments, you must use the `comfort-fade` preview header. The `start_side` is the starting side of the diff that the comment applies to. Can be `LEFT` or `RIGHT`. To learn more about multi-line comments, see "[Commenting on a pull request](https://help.github.com/en/articles/commenting-on-a-pull-request#adding-line-comments-to-a-pull-request)" in the GitHub Help documentation. See `side` in this table for additional context. + * @enum {string} + */ start_side?: "LEFT" | "RIGHT" | "side"; /** @example 2 */ in_reply_to?: number; @@ -29438,7 +29737,10 @@ export interface operations { commit_message?: string; /** @description SHA that pull request head must match to allow merge. */ sha?: string; - /** @description Merge method to use. Possible values are `merge`, `squash` or `rebase`. Default is `merge`. */ + /** + * @description Merge method to use. Possible values are `merge`, `squash` or `rebase`. Default is `merge`. + * @enum {string} + */ merge_method?: "merge" | "squash" | "rebase"; } | null; }; @@ -29582,7 +29884,10 @@ export interface operations { commit_id?: string; /** @description **Required** when using `REQUEST_CHANGES` or `COMMENT` for the `event` parameter. The body text of the pull request review. */ body?: string; - /** @description The review action you want to perform. The review actions include: `APPROVE`, `REQUEST_CHANGES`, or `COMMENT`. By leaving this blank, you set the review action state to `PENDING`, which means you will need to [submit the pull request review](https://docs.github.com/rest/reference/pulls#submit-a-review-for-a-pull-request) when you are ready. */ + /** + * @description The review action you want to perform. The review actions include: `APPROVE`, `REQUEST_CHANGES`, or `COMMENT`. By leaving this blank, you set the review action state to `PENDING`, which means you will need to [submit the pull request review](https://docs.github.com/rest/reference/pulls#submit-a-review-for-a-pull-request) when you are ready. + * @enum {string} + */ event?: "APPROVE" | "REQUEST_CHANGES" | "COMMENT"; /** @description Use the following table to specify the location, destination, and contents of the draft review comment. */ comments?: { @@ -29761,7 +30066,10 @@ export interface operations { "application/json": { /** @description The body text of the pull request review */ body?: string; - /** @description The review action you want to perform. The review actions include: `APPROVE`, `REQUEST_CHANGES`, or `COMMENT`. When you leave this blank, the API returns _HTTP 422 (Unrecognizable entity)_ and sets the review action state to `PENDING`, which means you will need to re-submit the pull request review using a review action. */ + /** + * @description The review action you want to perform. The review actions include: `APPROVE`, `REQUEST_CHANGES`, or `COMMENT`. When you leave this blank, the API returns _HTTP 422 (Unrecognizable entity)_ and sets the review action state to `PENDING`, which means you will need to re-submit the pull request review using a review action. + * @enum {string} + */ event: "APPROVE" | "REQUEST_CHANGES" | "COMMENT"; }; }; @@ -30411,7 +30719,10 @@ export interface operations { requestBody: { content: { "application/json": { - /** @description The state of the status. Can be one of `error`, `failure`, `pending`, or `success`. */ + /** + * @description The state of the status. Can be one of `error`, `failure`, `pending`, or `success`. + * @enum {string} + */ state: "error" | "failure" | "pending" | "success"; /** * @description The target URL to associate with this status. This URL will be linked from the GitHub UI to allow users to easily see the source of the status. @@ -31702,6 +32013,7 @@ export interface operations { * @example [object Object] */ Operations: { + /** @enum {string} */ op: "add" | "remove" | "replace"; path?: string; value?: @@ -32108,6 +32420,7 @@ export interface operations { * \* `closed` - visible to all members of this organization. * **For a parent or child team:** * \* `closed` - visible to all members of this organization. + * @enum {string} */ privacy?: "secret" | "closed"; /** @@ -32116,6 +32429,7 @@ export interface operations { * \* `push` - team members can pull and push, but not administer newly-added repositories. * \* `admin` - team members can pull, push and administer newly-added repositories. * @default pull + * @enum {string} */ permission?: "pull" | "push" | "admin"; /** @description The ID of a team to set as the parent team. */ @@ -32442,7 +32756,10 @@ export interface operations { requestBody: { content: { "application/json": { - /** @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the team discussion comment. */ + /** + * @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the team discussion comment. + * @enum {string} + */ content: "+1" | "-1" | "laugh" | "confused" | "heart" | "hooray" | "rocket" | "eyes"; }; }; @@ -32501,7 +32818,10 @@ export interface operations { requestBody: { content: { "application/json": { - /** @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the team discussion. */ + /** + * @description The [reaction type](https://docs.github.com/rest/reference/reactions#reaction-types) to add to the team discussion. + * @enum {string} + */ content: "+1" | "-1" | "laugh" | "confused" | "heart" | "hooray" | "rocket" | "eyes"; }; }; @@ -32738,6 +33058,7 @@ export interface operations { * \* `member` - a normal member of the team. * \* `maintainer` - a team maintainer. Able to add/remove other team members, promote other team members to team maintainer, and edit the team's name and description. * @default member + * @enum {string} */ role?: "member" | "maintainer"; }; @@ -32857,6 +33178,7 @@ export interface operations { * \* `write` - team members can read and write, but not administer this project. * \* `admin` - team members can read, write and administer this project. * Default: the team's `permission` attribute will be used to determine what permission to grant the team on this project. Note that, if you choose not to pass any parameters, you'll need to set `Content-Length` to zero when calling out to this endpoint. For more information, see "[HTTP verbs](https://docs.github.com/rest/overview/resources-in-the-rest-api#http-verbs)." + * @enum {string} */ permission?: "read" | "write" | "admin"; }; @@ -32966,6 +33288,7 @@ export interface operations { * \* `admin` - team members can pull, push and administer this repository. * * If no permission is specified, the team's `permission` attribute will be used to determine what permission to grant the team on this repository. + * @enum {string} */ permission?: "pull" | "push" | "admin"; }; @@ -33255,7 +33578,10 @@ export interface operations { * @example org@example.com */ email: string; - /** @description Denotes whether an email is publically visible. */ + /** + * @description Denotes whether an email is publically visible. + * @enum {string} + */ visibility: "public" | "private"; }; }; @@ -33928,7 +34254,10 @@ export interface operations { requestBody: { content: { "application/json": { - /** @description The state that the membership should be in. Only `"active"` will be accepted. */ + /** + * @description The state that the membership should be in. Only `"active"` will be accepted. + * @enum {string} + */ state: "active"; }; }; diff --git a/test/v3/expected/http.ts b/test/v3/expected/http.ts index 76f393a14..9280fd9c2 100644 --- a/test/v3/expected/http.ts +++ b/test/v3/expected/http.ts @@ -695,6 +695,7 @@ export interface components { }; Region: { id: components["schemas"]["ID"]; + /** @enum {string} */ type: "region"; version: number; body: components["schemas"]["RegionBody"]; @@ -730,6 +731,7 @@ export interface components { Provider: { id: components["schemas"]["ID"]; version: number; + /** @enum {string} */ type: "provider"; body: components["schemas"]["ProviderBody"]; }; @@ -772,12 +774,16 @@ export interface components { base_url?: string | null; /** Format: url */ sso_url?: string | null; + /** @enum {string|null} */ version?: "v1" | null; features?: { access_code?: boolean | null; sso?: boolean | null; plan_change?: boolean | null; - /** @default multiple */ + /** + * @default multiple + * @enum {string|null} + */ credential?: ("none" | "single" | "multiple" | "unknown") | null; }; } | null; @@ -816,6 +822,7 @@ export interface components { FeatureType: { label: components["schemas"]["Label"]; name: components["schemas"]["Name"]; + /** @enum {string} */ type: "boolean" | "string" | "number"; /** @description This sets whether or not the feature can be customized by a consumer. */ customizable?: boolean; @@ -934,6 +941,7 @@ export interface components { ProductImageURL: string; /** @description List of tags for product categorization and search */ ProductTags: components["schemas"]["Label"][]; + /** @enum {string} */ ProductState: "available" | "hidden" | "grandfathered" | "new" | "upcoming"; ProductListing: { /** @@ -982,6 +990,8 @@ export interface components { * Pre-Order, should not be used yet. But in the future it should allow people to * pre-provision a resource for when it does go live. * Public, means the resource is live and everyone should be able to provision it. + * + * @enum {string} */ ProductProvisioning: "provider-only" | "pre-order" | "public"; ProductIntegrationFeatures: { @@ -1004,6 +1014,8 @@ export interface components { * @description Describes how the region for a resource is specified, if * unspecified, then regions have no impact on this * resource. + * + * @enum {string} */ region?: "user-specified" | "unspecified"; /** @@ -1015,6 +1027,7 @@ export interface components { * * `unknown`: The credential type is unknown. * * @default multiple + * @enum {string} */ credential?: "none" | "single" | "multiple" | "unknown"; }; @@ -1047,7 +1060,9 @@ export interface components { }; feature_types: components["schemas"]["FeatureType"][]; billing: { + /** @enum {string} */ type: "monthly-prorated" | "monthly-anniversary" | "annual-anniversary"; + /** @enum {string} */ currency: "usd"; }; integration: { @@ -1056,6 +1071,7 @@ export interface components { base_url: string; /** Format: url */ sso_url?: string | null; + /** @enum {string} */ version: "v1"; features: components["schemas"]["ProductIntegrationFeatures"]; }; @@ -1064,6 +1080,7 @@ export interface components { Product: { id: components["schemas"]["ID"]; version: number; + /** @enum {string} */ type: "product"; body: components["schemas"]["ProductBody"]; }; @@ -1092,6 +1109,7 @@ export interface components { /** @description Dollar value in cents. */ cost: number; }; + /** @enum {string} */ PlanState: "hidden" | "available" | "grandfathered" | "unlisted"; ExpandedPlanBody: components["schemas"]["PlanBody"] & { /** @description An array of feature definitions for the plan, as defined on the Product. */ @@ -1111,12 +1129,14 @@ export interface components { Plan: { id: components["schemas"]["ID"]; version: number; + /** @enum {string} */ type: "plan"; body: components["schemas"]["PlanBody"]; }; ExpandedPlan: { id: components["schemas"]["ID"]; version: number; + /** @enum {string} */ type: "plan"; body: components["schemas"]["ExpandedPlanBody"]; }; @@ -1157,6 +1177,7 @@ export interface components { ExpandedProduct: { id: components["schemas"]["ID"]; version: number; + /** @enum {string} */ type: "product"; body: components["schemas"]["ProductBody"]; plans?: components["schemas"]["ExpandedPlan"][]; diff --git a/test/v3/expected/manifold.additional.ts b/test/v3/expected/manifold.additional.ts index 5102ec43c..e3f70acd3 100644 --- a/test/v3/expected/manifold.additional.ts +++ b/test/v3/expected/manifold.additional.ts @@ -695,6 +695,7 @@ export interface components { } & { [key: string]: unknown }; Region: { id: components["schemas"]["ID"]; + /** @enum {string} */ type: "region"; version: number; body: components["schemas"]["RegionBody"]; @@ -730,6 +731,7 @@ export interface components { Provider: { id: components["schemas"]["ID"]; version: number; + /** @enum {string} */ type: "provider"; body: components["schemas"]["ProviderBody"]; } & { [key: string]: unknown }; @@ -773,12 +775,16 @@ export interface components { base_url?: string | null; /** Format: url */ sso_url?: string | null; + /** @enum {string|null} */ version?: "v1" | null; features?: { access_code?: boolean | null; sso?: boolean | null; plan_change?: boolean | null; - /** @default multiple */ + /** + * @default multiple + * @enum {string|null} + */ credential?: ("none" | "single" | "multiple" | "unknown") | null; } & { [key: string]: unknown }; } & { [key: string]: unknown }) @@ -818,6 +824,7 @@ export interface components { FeatureType: { label: components["schemas"]["Label"]; name: components["schemas"]["Name"]; + /** @enum {string} */ type: "boolean" | "string" | "number"; /** @description This sets whether or not the feature can be customized by a consumer. */ customizable?: boolean; @@ -938,6 +945,7 @@ export interface components { ProductImageURL: string; /** @description List of tags for product categorization and search */ ProductTags: components["schemas"]["Label"][]; + /** @enum {string} */ ProductState: "available" | "hidden" | "grandfathered" | "new" | "upcoming"; ProductListing: { /** @@ -986,6 +994,8 @@ export interface components { * Pre-Order, should not be used yet. But in the future it should allow people to * pre-provision a resource for when it does go live. * Public, means the resource is live and everyone should be able to provision it. + * + * @enum {string} */ ProductProvisioning: "provider-only" | "pre-order" | "public"; ProductIntegrationFeatures: { @@ -1008,6 +1018,8 @@ export interface components { * @description Describes how the region for a resource is specified, if * unspecified, then regions have no impact on this * resource. + * + * @enum {string} */ region?: "user-specified" | "unspecified"; /** @@ -1019,6 +1031,7 @@ export interface components { * * `unknown`: The credential type is unknown. * * @default multiple + * @enum {string} */ credential?: "none" | "single" | "multiple" | "unknown"; } & { [key: string]: unknown }; @@ -1051,7 +1064,9 @@ export interface components { } & { [key: string]: unknown }; feature_types: components["schemas"]["FeatureType"][]; billing: { + /** @enum {string} */ type: "monthly-prorated" | "monthly-anniversary" | "annual-anniversary"; + /** @enum {string} */ currency: "usd"; } & { [key: string]: unknown }; integration: { @@ -1060,6 +1075,7 @@ export interface components { base_url: string; /** Format: url */ sso_url?: string | null; + /** @enum {string} */ version: "v1"; features: components["schemas"]["ProductIntegrationFeatures"]; } & { [key: string]: unknown }; @@ -1068,6 +1084,7 @@ export interface components { Product: { id: components["schemas"]["ID"]; version: number; + /** @enum {string} */ type: "product"; body: components["schemas"]["ProductBody"]; } & { [key: string]: unknown }; @@ -1096,6 +1113,7 @@ export interface components { /** @description Dollar value in cents. */ cost: number; } & { [key: string]: unknown }; + /** @enum {string} */ PlanState: "hidden" | "available" | "grandfathered" | "unlisted"; ExpandedPlanBody: components["schemas"]["PlanBody"] & ({ @@ -1117,12 +1135,14 @@ export interface components { Plan: { id: components["schemas"]["ID"]; version: number; + /** @enum {string} */ type: "plan"; body: components["schemas"]["PlanBody"]; } & { [key: string]: unknown }; ExpandedPlan: { id: components["schemas"]["ID"]; version: number; + /** @enum {string} */ type: "plan"; body: components["schemas"]["ExpandedPlanBody"]; } & { [key: string]: unknown }; @@ -1163,6 +1183,7 @@ export interface components { ExpandedProduct: { id: components["schemas"]["ID"]; version: number; + /** @enum {string} */ type: "product"; body: components["schemas"]["ProductBody"]; plans?: components["schemas"]["ExpandedPlan"][]; diff --git a/test/v3/expected/manifold.immutable.ts b/test/v3/expected/manifold.immutable.ts index ed2c77af0..47c3575ff 100644 --- a/test/v3/expected/manifold.immutable.ts +++ b/test/v3/expected/manifold.immutable.ts @@ -695,6 +695,7 @@ export interface components { }; readonly Region: { readonly id: components["schemas"]["ID"]; + /** @enum {string} */ readonly type: "region"; readonly version: number; readonly body: components["schemas"]["RegionBody"]; @@ -730,6 +731,7 @@ export interface components { readonly Provider: { readonly id: components["schemas"]["ID"]; readonly version: number; + /** @enum {string} */ readonly type: "provider"; readonly body: components["schemas"]["ProviderBody"]; }; @@ -772,12 +774,16 @@ export interface components { readonly base_url?: string | null; /** Format: url */ readonly sso_url?: string | null; + /** @enum {string|null} */ readonly version?: "v1" | null; readonly features?: { readonly access_code?: boolean | null; readonly sso?: boolean | null; readonly plan_change?: boolean | null; - /** @default multiple */ + /** + * @default multiple + * @enum {string|null} + */ readonly credential?: ("none" | "single" | "multiple" | "unknown") | null; }; } | null; @@ -816,6 +822,7 @@ export interface components { readonly FeatureType: { readonly label: components["schemas"]["Label"]; readonly name: components["schemas"]["Name"]; + /** @enum {string} */ readonly type: "boolean" | "string" | "number"; /** @description This sets whether or not the feature can be customized by a consumer. */ readonly customizable?: boolean; @@ -934,6 +941,7 @@ export interface components { readonly ProductImageURL: string; /** @description List of tags for product categorization and search */ readonly ProductTags: readonly components["schemas"]["Label"][]; + /** @enum {string} */ readonly ProductState: "available" | "hidden" | "grandfathered" | "new" | "upcoming"; readonly ProductListing: { /** @@ -982,6 +990,8 @@ export interface components { * Pre-Order, should not be used yet. But in the future it should allow people to * pre-provision a resource for when it does go live. * Public, means the resource is live and everyone should be able to provision it. + * + * @enum {string} */ readonly ProductProvisioning: "provider-only" | "pre-order" | "public"; readonly ProductIntegrationFeatures: { @@ -1004,6 +1014,8 @@ export interface components { * @description Describes how the region for a resource is specified, if * unspecified, then regions have no impact on this * resource. + * + * @enum {string} */ readonly region?: "user-specified" | "unspecified"; /** @@ -1015,6 +1027,7 @@ export interface components { * * `unknown`: The credential type is unknown. * * @default multiple + * @enum {string} */ readonly credential?: "none" | "single" | "multiple" | "unknown"; }; @@ -1047,7 +1060,9 @@ export interface components { }; readonly feature_types: readonly components["schemas"]["FeatureType"][]; readonly billing: { + /** @enum {string} */ readonly type: "monthly-prorated" | "monthly-anniversary" | "annual-anniversary"; + /** @enum {string} */ readonly currency: "usd"; }; readonly integration: { @@ -1056,6 +1071,7 @@ export interface components { readonly base_url: string; /** Format: url */ readonly sso_url?: string | null; + /** @enum {string} */ readonly version: "v1"; readonly features: components["schemas"]["ProductIntegrationFeatures"]; }; @@ -1064,6 +1080,7 @@ export interface components { readonly Product: { readonly id: components["schemas"]["ID"]; readonly version: number; + /** @enum {string} */ readonly type: "product"; readonly body: components["schemas"]["ProductBody"]; }; @@ -1092,6 +1109,7 @@ export interface components { /** @description Dollar value in cents. */ readonly cost: number; }; + /** @enum {string} */ readonly PlanState: "hidden" | "available" | "grandfathered" | "unlisted"; readonly ExpandedPlanBody: components["schemas"]["PlanBody"] & { /** @description An array of feature definitions for the plan, as defined on the Product. */ @@ -1111,12 +1129,14 @@ export interface components { readonly Plan: { readonly id: components["schemas"]["ID"]; readonly version: number; + /** @enum {string} */ readonly type: "plan"; readonly body: components["schemas"]["PlanBody"]; }; readonly ExpandedPlan: { readonly id: components["schemas"]["ID"]; readonly version: number; + /** @enum {string} */ readonly type: "plan"; readonly body: components["schemas"]["ExpandedPlanBody"]; }; @@ -1157,6 +1177,7 @@ export interface components { readonly ExpandedProduct: { readonly id: components["schemas"]["ID"]; readonly version: number; + /** @enum {string} */ readonly type: "product"; readonly body: components["schemas"]["ProductBody"]; readonly plans?: readonly components["schemas"]["ExpandedPlan"][]; diff --git a/test/v3/expected/manifold.ts b/test/v3/expected/manifold.ts index 76f393a14..9280fd9c2 100644 --- a/test/v3/expected/manifold.ts +++ b/test/v3/expected/manifold.ts @@ -695,6 +695,7 @@ export interface components { }; Region: { id: components["schemas"]["ID"]; + /** @enum {string} */ type: "region"; version: number; body: components["schemas"]["RegionBody"]; @@ -730,6 +731,7 @@ export interface components { Provider: { id: components["schemas"]["ID"]; version: number; + /** @enum {string} */ type: "provider"; body: components["schemas"]["ProviderBody"]; }; @@ -772,12 +774,16 @@ export interface components { base_url?: string | null; /** Format: url */ sso_url?: string | null; + /** @enum {string|null} */ version?: "v1" | null; features?: { access_code?: boolean | null; sso?: boolean | null; plan_change?: boolean | null; - /** @default multiple */ + /** + * @default multiple + * @enum {string|null} + */ credential?: ("none" | "single" | "multiple" | "unknown") | null; }; } | null; @@ -816,6 +822,7 @@ export interface components { FeatureType: { label: components["schemas"]["Label"]; name: components["schemas"]["Name"]; + /** @enum {string} */ type: "boolean" | "string" | "number"; /** @description This sets whether or not the feature can be customized by a consumer. */ customizable?: boolean; @@ -934,6 +941,7 @@ export interface components { ProductImageURL: string; /** @description List of tags for product categorization and search */ ProductTags: components["schemas"]["Label"][]; + /** @enum {string} */ ProductState: "available" | "hidden" | "grandfathered" | "new" | "upcoming"; ProductListing: { /** @@ -982,6 +990,8 @@ export interface components { * Pre-Order, should not be used yet. But in the future it should allow people to * pre-provision a resource for when it does go live. * Public, means the resource is live and everyone should be able to provision it. + * + * @enum {string} */ ProductProvisioning: "provider-only" | "pre-order" | "public"; ProductIntegrationFeatures: { @@ -1004,6 +1014,8 @@ export interface components { * @description Describes how the region for a resource is specified, if * unspecified, then regions have no impact on this * resource. + * + * @enum {string} */ region?: "user-specified" | "unspecified"; /** @@ -1015,6 +1027,7 @@ export interface components { * * `unknown`: The credential type is unknown. * * @default multiple + * @enum {string} */ credential?: "none" | "single" | "multiple" | "unknown"; }; @@ -1047,7 +1060,9 @@ export interface components { }; feature_types: components["schemas"]["FeatureType"][]; billing: { + /** @enum {string} */ type: "monthly-prorated" | "monthly-anniversary" | "annual-anniversary"; + /** @enum {string} */ currency: "usd"; }; integration: { @@ -1056,6 +1071,7 @@ export interface components { base_url: string; /** Format: url */ sso_url?: string | null; + /** @enum {string} */ version: "v1"; features: components["schemas"]["ProductIntegrationFeatures"]; }; @@ -1064,6 +1080,7 @@ export interface components { Product: { id: components["schemas"]["ID"]; version: number; + /** @enum {string} */ type: "product"; body: components["schemas"]["ProductBody"]; }; @@ -1092,6 +1109,7 @@ export interface components { /** @description Dollar value in cents. */ cost: number; }; + /** @enum {string} */ PlanState: "hidden" | "available" | "grandfathered" | "unlisted"; ExpandedPlanBody: components["schemas"]["PlanBody"] & { /** @description An array of feature definitions for the plan, as defined on the Product. */ @@ -1111,12 +1129,14 @@ export interface components { Plan: { id: components["schemas"]["ID"]; version: number; + /** @enum {string} */ type: "plan"; body: components["schemas"]["PlanBody"]; }; ExpandedPlan: { id: components["schemas"]["ID"]; version: number; + /** @enum {string} */ type: "plan"; body: components["schemas"]["ExpandedPlanBody"]; }; @@ -1157,6 +1177,7 @@ export interface components { ExpandedProduct: { id: components["schemas"]["ID"]; version: number; + /** @enum {string} */ type: "product"; body: components["schemas"]["ProductBody"]; plans?: components["schemas"]["ExpandedPlan"][]; diff --git a/test/v3/expected/null-in-enum.additional.ts b/test/v3/expected/null-in-enum.additional.ts index 854f024d5..7a0c7d555 100644 --- a/test/v3/expected/null-in-enum.additional.ts +++ b/test/v3/expected/null-in-enum.additional.ts @@ -18,18 +18,22 @@ export interface components { schemas: { /** @description Enum with null and nullable */ MyType: { - myField?: ("foo" | "bar") | null; + /** @enum {string|null} */ + myField?: ("foo" | "bar" | null) | null; } & { [key: string]: unknown }; /** @description Enum with null */ MyTypeNotNullable: { + /** @enum {string} */ myField?: "foo" | "bar" | null; } & { [key: string]: unknown }; /** @description Enum with null */ MyTypeNotNullableNotNull: { + /** @enum {string} */ myField?: "foo" | "bar"; } & { [key: string]: unknown }; /** @description Enum with null */ MyTypeMixed: { + /** @enum {string} */ myField?: "foo" | 2 | false | null; } & { [key: string]: unknown }; }; diff --git a/test/v3/expected/null-in-enum.immutable.ts b/test/v3/expected/null-in-enum.immutable.ts index 6f0e9cdf4..4046246f5 100644 --- a/test/v3/expected/null-in-enum.immutable.ts +++ b/test/v3/expected/null-in-enum.immutable.ts @@ -18,18 +18,22 @@ export interface components { readonly schemas: { /** @description Enum with null and nullable */ readonly MyType: { - readonly myField?: ("foo" | "bar") | null; + /** @enum {string|null} */ + readonly myField?: ("foo" | "bar" | null) | null; }; /** @description Enum with null */ readonly MyTypeNotNullable: { + /** @enum {string} */ readonly myField?: "foo" | "bar" | null; }; /** @description Enum with null */ readonly MyTypeNotNullableNotNull: { + /** @enum {string} */ readonly myField?: "foo" | "bar"; }; /** @description Enum with null */ readonly MyTypeMixed: { + /** @enum {string} */ readonly myField?: "foo" | 2 | false | null; }; }; diff --git a/test/v3/expected/null-in-enum.ts b/test/v3/expected/null-in-enum.ts index 70e3fb043..61f8c54f5 100644 --- a/test/v3/expected/null-in-enum.ts +++ b/test/v3/expected/null-in-enum.ts @@ -18,18 +18,22 @@ export interface components { schemas: { /** @description Enum with null and nullable */ MyType: { - myField?: ("foo" | "bar") | null; + /** @enum {string|null} */ + myField?: ("foo" | "bar" | null) | null; }; /** @description Enum with null */ MyTypeNotNullable: { + /** @enum {string} */ myField?: "foo" | "bar" | null; }; /** @description Enum with null */ MyTypeNotNullableNotNull: { + /** @enum {string} */ myField?: "foo" | "bar"; }; /** @description Enum with null */ MyTypeMixed: { + /** @enum {string} */ myField?: "foo" | 2 | false | null; }; }; diff --git a/test/v3/expected/one-of-empty.additional.ts b/test/v3/expected/one-of-empty.additional.ts new file mode 100644 index 000000000..079a85a4a --- /dev/null +++ b/test/v3/expected/one-of-empty.additional.ts @@ -0,0 +1,30 @@ +/** + * This file was auto-generated by openapi-typescript. + * Do not make direct changes to the file. + */ + +export interface paths { + "/test": { + get: { + responses: { + /** A list of types. */ + 200: unknown; + }; + }; + }; +} + +export interface components { + schemas: { + /** @description Enum with null and nullable */ + Example: { + emptyAllOf?: { [key: string]: unknown }; + emptyOneOf?: undefined & { [key: string]: unknown }; + emptyAnyOf?: { [key: string]: unknown }; + } & { [key: string]: unknown }; + }; +} + +export interface operations {} + +export interface external {} diff --git a/test/v3/expected/one-of-empty.immutable.ts b/test/v3/expected/one-of-empty.immutable.ts new file mode 100644 index 000000000..c88ded8ea --- /dev/null +++ b/test/v3/expected/one-of-empty.immutable.ts @@ -0,0 +1,30 @@ +/** + * This file was auto-generated by openapi-typescript. + * Do not make direct changes to the file. + */ + +export interface paths { + readonly "/test": { + readonly get: { + readonly responses: { + /** A list of types. */ + readonly 200: unknown; + }; + }; + }; +} + +export interface components { + readonly schemas: { + /** @description Enum with null and nullable */ + readonly Example: { + readonly emptyAllOf?: undefined; + readonly emptyOneOf?: undefined; + readonly emptyAnyOf?: undefined; + }; + }; +} + +export interface operations {} + +export interface external {} diff --git a/test/v3/expected/one-of-empty.ts b/test/v3/expected/one-of-empty.ts new file mode 100644 index 000000000..7d391f33d --- /dev/null +++ b/test/v3/expected/one-of-empty.ts @@ -0,0 +1,30 @@ +/** + * This file was auto-generated by openapi-typescript. + * Do not make direct changes to the file. + */ + +export interface paths { + "/test": { + get: { + responses: { + /** A list of types. */ + 200: unknown; + }; + }; + }; +} + +export interface components { + schemas: { + /** @description Enum with null and nullable */ + Example: { + emptyAllOf?: undefined; + emptyOneOf?: undefined; + emptyAnyOf?: undefined; + }; + }; +} + +export interface operations {} + +export interface external {} diff --git a/test/v3/expected/petstore-openapitools.additional.ts b/test/v3/expected/petstore-openapitools.additional.ts index 7052492db..643c33773 100644 --- a/test/v3/expected/petstore-openapitools.additional.ts +++ b/test/v3/expected/petstore-openapitools.additional.ts @@ -78,7 +78,10 @@ export interface components { quantity?: number; /** Format: date-time */ shipDate?: string; - /** @description Order Status */ + /** + * @description Order Status + * @enum {string} + */ status?: "placed" | "approved" | "delivered"; complete?: boolean; } & { [key: string]: unknown }; @@ -131,7 +134,10 @@ export interface components { name: string; photoUrls: string[]; tags?: components["schemas"]["Tag"][]; - /** @description pet status in the store */ + /** + * @description pet status in the store + * @enum {string} + */ status?: "available" | "pending" | "sold"; } & { [key: string]: unknown }; /** diff --git a/test/v3/expected/petstore-openapitools.immutable.ts b/test/v3/expected/petstore-openapitools.immutable.ts index 6e0308be8..28d8ab03f 100644 --- a/test/v3/expected/petstore-openapitools.immutable.ts +++ b/test/v3/expected/petstore-openapitools.immutable.ts @@ -78,7 +78,10 @@ export interface components { readonly quantity?: number; /** Format: date-time */ readonly shipDate?: string; - /** @description Order Status */ + /** + * @description Order Status + * @enum {string} + */ readonly status?: "placed" | "approved" | "delivered"; readonly complete?: boolean; }; @@ -131,7 +134,10 @@ export interface components { readonly name: string; readonly photoUrls: readonly string[]; readonly tags?: readonly components["schemas"]["Tag"][]; - /** @description pet status in the store */ + /** + * @description pet status in the store + * @enum {string} + */ readonly status?: "available" | "pending" | "sold"; }; /** diff --git a/test/v3/expected/petstore-openapitools.ts b/test/v3/expected/petstore-openapitools.ts index 2d37dd989..c6fb95bc1 100644 --- a/test/v3/expected/petstore-openapitools.ts +++ b/test/v3/expected/petstore-openapitools.ts @@ -78,7 +78,10 @@ export interface components { quantity?: number; /** Format: date-time */ shipDate?: string; - /** @description Order Status */ + /** + * @description Order Status + * @enum {string} + */ status?: "placed" | "approved" | "delivered"; complete?: boolean; }; @@ -131,7 +134,10 @@ export interface components { name: string; photoUrls: string[]; tags?: components["schemas"]["Tag"][]; - /** @description pet status in the store */ + /** + * @description pet status in the store + * @enum {string} + */ status?: "available" | "pending" | "sold"; }; /** diff --git a/test/v3/expected/petstore.additional.ts b/test/v3/expected/petstore.additional.ts index 630902d45..4c88dd37c 100644 --- a/test/v3/expected/petstore.additional.ts +++ b/test/v3/expected/petstore.additional.ts @@ -74,7 +74,10 @@ export interface components { quantity?: number; /** Format: date-time */ shipDate?: string; - /** @description Order Status */ + /** + * @description Order Status + * @enum {string} + */ status?: "placed" | "approved" | "delivered"; complete?: boolean; } & { [key: string]: unknown }; @@ -111,7 +114,10 @@ export interface components { name: string; photoUrls: string[]; tags?: components["schemas"]["Tag"][]; - /** @description pet status in the store */ + /** + * @description pet status in the store + * @enum {string} + */ status?: "available" | "pending" | "sold"; } & { [key: string]: unknown }; ApiResponse: { diff --git a/test/v3/expected/petstore.immutable.ts b/test/v3/expected/petstore.immutable.ts index 82fd7c4e8..71eda2cc3 100644 --- a/test/v3/expected/petstore.immutable.ts +++ b/test/v3/expected/petstore.immutable.ts @@ -74,7 +74,10 @@ export interface components { readonly quantity?: number; /** Format: date-time */ readonly shipDate?: string; - /** @description Order Status */ + /** + * @description Order Status + * @enum {string} + */ readonly status?: "placed" | "approved" | "delivered"; readonly complete?: boolean; }; @@ -111,7 +114,10 @@ export interface components { readonly name: string; readonly photoUrls: readonly string[]; readonly tags?: readonly components["schemas"]["Tag"][]; - /** @description pet status in the store */ + /** + * @description pet status in the store + * @enum {string} + */ readonly status?: "available" | "pending" | "sold"; }; readonly ApiResponse: { diff --git a/test/v3/expected/petstore.ts b/test/v3/expected/petstore.ts index 6e9dda83f..9199645c1 100644 --- a/test/v3/expected/petstore.ts +++ b/test/v3/expected/petstore.ts @@ -74,7 +74,10 @@ export interface components { quantity?: number; /** Format: date-time */ shipDate?: string; - /** @description Order Status */ + /** + * @description Order Status + * @enum {string} + */ status?: "placed" | "approved" | "delivered"; complete?: boolean; }; @@ -111,7 +114,10 @@ export interface components { name: string; photoUrls: string[]; tags?: components["schemas"]["Tag"][]; - /** @description pet status in the store */ + /** + * @description pet status in the store + * @enum {string} + */ status?: "available" | "pending" | "sold"; }; ApiResponse: { diff --git a/test/v3/expected/stripe.additional.ts b/test/v3/expected/stripe.additional.ts index 0b12f9c52..a15fc6773 100644 --- a/test/v3/expected/stripe.additional.ts +++ b/test/v3/expected/stripe.additional.ts @@ -1496,7 +1496,10 @@ export interface components { business_profile?: | (Partial & { [key: string]: unknown }) | null; - /** @description The business type. */ + /** + * @description The business type. + * @enum {string|null} + */ business_type?: ("company" | "government_entity" | "individual" | "non_profit") | null; capabilities?: components["schemas"]["account_capabilities"]; /** @description Whether the account can create live charges. */ @@ -1526,7 +1529,10 @@ export interface components { })[]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -1536,7 +1542,10 @@ export interface components { individual?: components["schemas"]["person"]; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata?: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "account"; /** @description Whether Stripe can send payouts to this account. */ payouts_enabled?: boolean; @@ -1544,7 +1553,10 @@ export interface components { /** @description Options for customizing how the account functions within Stripe. */ settings?: (Partial & { [key: string]: unknown }) | null; tos_acceptance?: components["schemas"]["account_tos_acceptance"]; - /** @description The Stripe account type. Can be `standard`, `express`, or `custom`. */ + /** + * @description The Stripe account type. Can be `standard`, `express`, or `custom`. + * @enum {string} + */ type?: "custom" | "express" | "standard"; } & { [key: string]: unknown }; /** AccountBrandingSettings */ @@ -1579,19 +1591,40 @@ export interface components { } & { [key: string]: unknown }; /** AccountCapabilities */ account_capabilities: { - /** @description The status of the BECS Direct Debit (AU) payments capability of the account, or whether the account can directly process BECS Direct Debit (AU) charges. */ + /** + * @description The status of the BECS Direct Debit (AU) payments capability of the account, or whether the account can directly process BECS Direct Debit (AU) charges. + * @enum {string} + */ au_becs_debit_payments?: "active" | "inactive" | "pending"; - /** @description The status of the card issuing capability of the account, or whether you can use Issuing to distribute funds on cards */ + /** + * @description The status of the card issuing capability of the account, or whether you can use Issuing to distribute funds on cards + * @enum {string} + */ card_issuing?: "active" | "inactive" | "pending"; - /** @description The status of the card payments capability of the account, or whether the account can directly process credit and debit card charges. */ + /** + * @description The status of the card payments capability of the account, or whether the account can directly process credit and debit card charges. + * @enum {string} + */ card_payments?: "active" | "inactive" | "pending"; - /** @description The status of the legacy payments capability of the account. */ + /** + * @description The status of the legacy payments capability of the account. + * @enum {string} + */ legacy_payments?: "active" | "inactive" | "pending"; - /** @description The status of the tax reporting 1099-K (US) capability of the account. */ + /** + * @description The status of the tax reporting 1099-K (US) capability of the account. + * @enum {string} + */ tax_reporting_us_1099_k?: "active" | "inactive" | "pending"; - /** @description The status of the tax reporting 1099-MISC (US) capability of the account. */ + /** + * @description The status of the tax reporting 1099-MISC (US) capability of the account. + * @enum {string} + */ tax_reporting_us_1099_misc?: "active" | "inactive" | "pending"; - /** @description The status of the transfers capability of the account, or whether your platform can transfer funds to the account. */ + /** + * @description The status of the transfers capability of the account, or whether your platform can transfer funds to the account. + * @enum {string} + */ transfers?: "active" | "inactive" | "pending"; } & { [key: string]: unknown }; /** AccountCapabilityRequirements */ @@ -1652,7 +1685,10 @@ export interface components { * @description The timestamp at which this account link will expire. */ expires_at: number; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "account_link"; /** @description The URL for the account link. */ url: string; @@ -1696,7 +1732,10 @@ export interface components { } & { [key: string]: unknown }; /** AccountRequirementsError */ account_requirements_error: { - /** @description The code for the type of error. */ + /** + * @description The code for the type of error. + * @enum {string} + */ code: | "invalid_address_city_state_postal_code" | "invalid_street_address" @@ -1797,7 +1836,10 @@ export interface components { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata?: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "alipay_account"; /** @description If the Alipay account object is not reusable, the exact amount that you can create a charge for. */ payment_amount?: number | null; @@ -1831,7 +1873,10 @@ export interface components { source?: (Partial & Partial & Partial) & { [key: string]: unknown }; - /** @description The type of error returned. One of `api_connection_error`, `api_error`, `authentication_error`, `card_error`, `idempotency_error`, `invalid_request_error`, or `rate_limit_error` */ + /** + * @description The type of error returned. One of `api_connection_error`, `api_error`, `authentication_error`, `card_error`, `idempotency_error`, `invalid_request_error`, or `rate_limit_error` + * @enum {string} + */ type: | "api_connection_error" | "api_error" @@ -1853,7 +1898,10 @@ export interface components { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "apple_pay_domain"; } & { [key: string]: unknown }; /** Application */ @@ -1862,7 +1910,10 @@ export interface components { id: string; /** @description The name of the application. */ name?: string | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "application"; } & { [key: string]: unknown }; /** PlatformFee */ @@ -1892,7 +1943,10 @@ export interface components { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "application_fee"; /** @description ID of the corresponding charge on the platform account, if this fee was the result of a charge using the `destination` parameter. */ originating_transaction?: @@ -1909,7 +1963,10 @@ export interface components { data: components["schemas"]["fee_refund"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -1936,7 +1993,10 @@ export interface components { connect_reserved?: components["schemas"]["balance_amount"][]; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "balance"; /** @description Funds that are not yet available in the balance, due to the 7-day rolling pay cycle. The pending balance for each currency, and for each payment type, can be found in the `source_types` property. */ pending: components["schemas"]["balance_amount"][]; @@ -1992,7 +2052,10 @@ export interface components { id: string; /** @description Net amount of the transaction, in %s. */ net: number; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "balance_transaction"; /** @description [Learn more](https://stripe.com/docs/reports/reporting-categories) about how reporting categories can help you understand balance transactions from an accounting perspective. */ reporting_category: string; @@ -2017,7 +2080,10 @@ export interface components { | null; /** @description If the transaction's net funds are available in the Stripe balance yet. Either `available` or `pending`. */ status: string; - /** @description Transaction type: `adjustment`, `advance`, `advance_funding`, `application_fee`, `application_fee_refund`, `charge`, `connect_collection_transfer`, `issuing_authorization_hold`, `issuing_authorization_release`, `issuing_transaction`, `payment`, `payment_failure_refund`, `payment_refund`, `payout`, `payout_cancel`, `payout_failure`, `refund`, `refund_failure`, `reserve_transaction`, `reserved_funds`, `stripe_fee`, `stripe_fx_fee`, `tax_fee`, `topup`, `topup_reversal`, `transfer`, `transfer_cancel`, `transfer_failure`, or `transfer_refund`. [Learn more](https://stripe.com/docs/reports/balance-transaction-types) about balance transaction types and what they represent. If you are looking to classify transactions for accounting purposes, you might want to consider `reporting_category` instead. */ + /** + * @description Transaction type: `adjustment`, `advance`, `advance_funding`, `application_fee`, `application_fee_refund`, `charge`, `connect_collection_transfer`, `issuing_authorization_hold`, `issuing_authorization_release`, `issuing_transaction`, `payment`, `payment_failure_refund`, `payment_refund`, `payout`, `payout_cancel`, `payout_failure`, `refund`, `refund_failure`, `reserve_transaction`, `reserved_funds`, `stripe_fee`, `stripe_fx_fee`, `tax_fee`, `topup`, `topup_reversal`, `transfer`, `transfer_cancel`, `transfer_failure`, or `transfer_refund`. [Learn more](https://stripe.com/docs/reports/balance-transaction-types) about balance transaction types and what they represent. If you are looking to classify transactions for accounting purposes, you might want to consider `reporting_category` instead. + * @enum {string} + */ type: | "adjustment" | "advance" @@ -2088,7 +2154,10 @@ export interface components { last4: string; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata?: { [key: string]: string } | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "bank_account"; /** @description The routing transit number for the bank account. */ routing_number?: string | null; @@ -2132,7 +2201,10 @@ export interface components { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "billing_portal.session"; /** @description The URL to which Stripe should send customers when they click on the link to return to your website. */ return_url: string; @@ -2176,7 +2248,10 @@ export interface components { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "bitcoin_receiver"; /** @description The ID of the payment created from the receiver, if any. Hidden when viewing the receiver with a publishable key. */ payment?: string | null; @@ -2191,7 +2266,10 @@ export interface components { data: components["schemas"]["bitcoin_transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -2216,7 +2294,10 @@ export interface components { currency: string; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "bitcoin_transaction"; /** @description The receiver to which this transaction was sent. */ receiver: string; @@ -2232,7 +2313,10 @@ export interface components { account: (Partial & Partial) & { [key: string]: unknown }; /** @description The identifier for the capability. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "capability"; /** @description Whether the capability has been requested. */ requested: boolean; @@ -2242,7 +2326,10 @@ export interface components { */ requested_at?: number | null; requirements?: components["schemas"]["account_capability_requirements"]; - /** @description The status of the capability. Can be `active`, `inactive`, `pending`, or `unrequested`. */ + /** + * @description The status of the capability. Can be `active`, `inactive`, `pending`, or `unrequested`. + * @enum {string} + */ status: "active" | "disabled" | "inactive" | "pending" | "unrequested"; } & { [key: string]: unknown }; /** @@ -2307,7 +2394,10 @@ export interface components { metadata: { [key: string]: string }; /** @description Cardholder name. */ name?: string | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "card"; /** @description The recipient that this card belongs to. This attribute will not be in the card object if the card belongs to a customer or account instead. */ recipient?: ((Partial & Partial) & { [key: string]: unknown }) | null; @@ -2379,7 +2469,10 @@ export interface components { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "charge"; /** @description The account (if any) the charge was made on behalf of without triggering an automatic transfer. See the [Connect documentation](https://stripe.com/docs/connect/charges-transfers) for details. */ on_behalf_of?: @@ -2418,7 +2511,10 @@ export interface components { data: components["schemas"]["refund"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -2530,7 +2626,10 @@ export interface components { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description The IETF language tag of the locale Checkout is displayed in. If blank or `auto`, the browser's locale is used. */ + /** + * @description The IETF language tag of the locale Checkout is displayed in. If blank or `auto`, the browser's locale is used. + * @enum {string|null} + */ locale?: | ( | "auto" @@ -2554,9 +2653,15 @@ export interface components { | null; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata?: { [key: string]: string } | null; - /** @description The mode of the Checkout Session, one of `payment`, `setup`, or `subscription`. */ + /** + * @description The mode of the Checkout Session, one of `payment`, `setup`, or `subscription`. + * @enum {string|null} + */ mode?: ("payment" | "setup" | "subscription") | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "checkout.session"; /** @description The ID of the PaymentIntent for Checkout Sessions in `payment` mode. */ payment_intent?: @@ -2584,6 +2689,7 @@ export interface components { * relevant text on the page, such as the submit button. `submit_type` can only be * specified on Checkout Sessions in `payment` mode, but not Checkout Sessions * in `subscription` or `setup` mode. + * @enum {string|null} */ submit_type?: ("auto" | "book" | "donate" | "pay") | null; /** @description The ID of the subscription for Checkout Sessions in `subscription` mode. */ @@ -2631,7 +2737,10 @@ export interface components { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "connect_collection_transfer"; } & { [key: string]: unknown }; /** @@ -2648,7 +2757,10 @@ export interface components { default_currency: string; /** @description Unique identifier for the object. Represented as the ISO country code for this country. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "country_spec"; /** @description Currencies that can be accepted in the specific country (for transfers). */ supported_bank_account_currencies: { [key: string]: string[] }; @@ -2688,7 +2800,10 @@ export interface components { created: number; /** @description If `amount_off` has been set, the three-letter [ISO code for the currency](https://stripe.com/docs/currencies) of the amount to take off. */ currency?: string | null; - /** @description One of `forever`, `once`, and `repeating`. Describes how long a customer who applies this coupon will get the discount. */ + /** + * @description One of `forever`, `once`, and `repeating`. Describes how long a customer who applies this coupon will get the discount. + * @enum {string} + */ duration: "forever" | "once" | "repeating"; /** @description If `duration` is `repeating`, the number of months the coupon applies. Null if coupon `duration` is `forever` or `once`. */ duration_in_months?: number | null; @@ -2702,7 +2817,10 @@ export interface components { metadata: { [key: string]: string }; /** @description Name of the coupon displayed to customers on for instance invoices or receipts. */ name?: string | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "coupon"; /** @description Percent that will be taken off the subtotal of any invoices for this customer for the duration of the coupon. For example, a coupon with percent_off of 50 will make a %s100 invoice %s50 instead. */ percent_off?: number | null; @@ -2755,7 +2873,10 @@ export interface components { data: components["schemas"]["credit_note_line_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -2768,17 +2889,26 @@ export interface components { metadata: { [key: string]: string }; /** @description A unique number that identifies this particular credit note and appears on the PDF of the credit note and its associated invoice. */ number: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "credit_note"; /** @description Amount that was credited outside of Stripe. */ out_of_band_amount?: number | null; /** @description The link to download the PDF of the credit note. */ pdf: string; - /** @description Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory` */ + /** + * @description Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory` + * @enum {string|null} + */ reason?: ("duplicate" | "fraudulent" | "order_change" | "product_unsatisfactory") | null; /** @description Refund related to this credit note. */ refund?: ((Partial & Partial) & { [key: string]: unknown }) | null; - /** @description Status of this credit note, one of `issued` or `void`. Learn more about [voiding credit notes](https://stripe.com/docs/billing/invoices/credit-notes#voiding). */ + /** + * @description Status of this credit note, one of `issued` or `void`. Learn more about [voiding credit notes](https://stripe.com/docs/billing/invoices/credit-notes#voiding). + * @enum {string} + */ status: "issued" | "void"; /** @description The integer amount in **%s** representing the amount of the credit note, excluding tax and discount. */ subtotal: number; @@ -2786,7 +2916,10 @@ export interface components { tax_amounts: components["schemas"]["credit_note_tax_amount"][]; /** @description The integer amount in **%s** representing the total amount of the credit note, including tax and discount. */ total: number; - /** @description Type of this credit note, one of `pre_payment` or `post_payment`. A `pre_payment` credit note means it was issued when the invoice was open. A `post_payment` credit note means it was issued when the invoice was paid. */ + /** + * @description Type of this credit note, one of `pre_payment` or `post_payment`. A `pre_payment` credit note means it was issued when the invoice was open. A `post_payment` credit note means it was issued when the invoice was paid. + * @enum {string} + */ type: "post_payment" | "pre_payment"; /** * Format: unix-time @@ -2808,7 +2941,10 @@ export interface components { invoice_line_item?: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "credit_note_line_item"; /** @description The number of units of product being credited. */ quantity?: number | null; @@ -2816,7 +2952,10 @@ export interface components { tax_amounts: components["schemas"]["credit_note_tax_amount"][]; /** @description The tax rates which apply to the line item. */ tax_rates: components["schemas"]["tax_rate"][]; - /** @description The type of the credit note line item, one of `invoice_line_item` or `custom_line_item`. When the type is `invoice_line_item` there is an additional `invoice_line_item` property on the resource the value of which is the id of the credited line item on the invoice. */ + /** + * @description The type of the credit note line item, one of `invoice_line_item` or `custom_line_item`. When the type is `invoice_line_item` there is an additional `invoice_line_item` property on the resource the value of which is the id of the credited line item on the invoice. + * @enum {string} + */ type: "custom_line_item" | "invoice_line_item"; /** @description The cost of each unit of product being credited. */ unit_amount?: number | null; @@ -2890,7 +3029,10 @@ export interface components { name?: string | null; /** @description The suffix of the customer's next invoice number, e.g., 0001. */ next_invoice_sequence?: number; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "customer"; /** @description The customer's phone number. */ phone?: string | null; @@ -2911,7 +3053,10 @@ export interface components { Partial) & { [key: string]: unknown })[]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -2925,12 +3070,18 @@ export interface components { data: components["schemas"]["subscription"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; } & { [key: string]: unknown }; - /** @description Describes the customer's tax exemption status. One of `none`, `exempt`, or `reverse`. When set to `reverse`, invoice and receipt PDFs include the text **"Reverse charge"**. */ + /** + * @description Describes the customer's tax exemption status. One of `none`, `exempt`, or `reverse`. When set to `reverse`, invoice and receipt PDFs include the text **"Reverse charge"**. + * @enum {string|null} + */ tax_exempt?: ("exempt" | "none" | "reverse") | null; /** * TaxIDsList @@ -2941,7 +3092,10 @@ export interface components { data: components["schemas"]["tax_id"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -2956,7 +3110,10 @@ export interface components { accepted_at?: number | null; offline?: components["schemas"]["offline_acceptance"]; online?: components["schemas"]["online_acceptance"]; - /** @description The type of customer acceptance information included with the Mandate. One of `online` or `offline`. */ + /** + * @description The type of customer acceptance information included with the Mandate. One of `online` or `offline`. + * @enum {string} + */ type: "offline" | "online"; } & { [key: string]: unknown }; /** @@ -2996,9 +3153,15 @@ export interface components { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata?: { [key: string]: string } | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "customer_balance_transaction"; - /** @description Transaction type: `adjustment`, `applied_to_invoice`, `credit_note`, `initial`, `invoice_too_large`, `invoice_too_small`, `unspent_receiver_credit`, or `unapplied_from_invoice`. See the [Customer Balance page](https://stripe.com/docs/billing/customer/balance#types) to learn more about transaction types. */ + /** + * @description Transaction type: `adjustment`, `applied_to_invoice`, `credit_note`, `initial`, `invoice_too_large`, `invoice_too_small`, `unspent_receiver_credit`, or `unapplied_from_invoice`. See the [Customer Balance page](https://stripe.com/docs/billing/customer/balance#types) to learn more about transaction types. + * @enum {string} + */ type: | "adjustment" | "applied_to_invoice" @@ -3012,85 +3175,139 @@ export interface components { } & { [key: string]: unknown }; /** DeletedAccount */ deleted_account: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "account"; } & { [key: string]: unknown }; /** AlipayDeletedAccount */ deleted_alipay_account: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "alipay_account"; } & { [key: string]: unknown }; /** DeletedApplePayDomain */ deleted_apple_pay_domain: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "apple_pay_domain"; } & { [key: string]: unknown }; /** DeletedBankAccount */ deleted_bank_account: { /** @description Three-letter [ISO code for the currency](https://stripe.com/docs/payouts) paid out to the bank account. */ currency?: string | null; - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "bank_account"; } & { [key: string]: unknown }; /** BitcoinDeletedReceiver */ deleted_bitcoin_receiver: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "bitcoin_receiver"; } & { [key: string]: unknown }; /** DeletedCard */ deleted_card: { /** @description Three-letter [ISO code for the currency](https://stripe.com/docs/payouts) paid out to the bank account. */ currency?: string | null; - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "card"; } & { [key: string]: unknown }; /** DeletedCoupon */ deleted_coupon: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "coupon"; } & { [key: string]: unknown }; /** DeletedCustomer */ deleted_customer: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "customer"; } & { [key: string]: unknown }; /** DeletedDiscount */ deleted_discount: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "discount"; } & { [key: string]: unknown }; /** Polymorphic */ @@ -3098,20 +3315,32 @@ export interface components { Partial) & { [key: string]: unknown }; /** DeletedInvoice */ deleted_invoice: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "invoice"; } & { [key: string]: unknown }; /** DeletedInvoiceItem */ deleted_invoiceitem: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "invoiceitem"; } & { [key: string]: unknown }; /** Polymorphic */ @@ -3121,110 +3350,182 @@ export interface components { Partial) & { [key: string]: unknown }; /** DeletedPerson */ deleted_person: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "person"; } & { [key: string]: unknown }; /** DeletedPlan */ deleted_plan: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "plan"; } & { [key: string]: unknown }; /** DeletedProduct */ deleted_product: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "product"; } & { [key: string]: unknown }; /** RadarListDeletedList */ "deleted_radar.value_list": { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "radar.value_list"; } & { [key: string]: unknown }; /** RadarListDeletedListItem */ "deleted_radar.value_list_item": { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "radar.value_list_item"; } & { [key: string]: unknown }; /** DeletedTransferRecipient */ deleted_recipient: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "recipient"; } & { [key: string]: unknown }; /** DeletedSKU */ deleted_sku: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "sku"; } & { [key: string]: unknown }; /** DeletedSubscriptionItem */ deleted_subscription_item: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "subscription_item"; } & { [key: string]: unknown }; /** deleted_tax_id */ deleted_tax_id: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "tax_id"; } & { [key: string]: unknown }; /** TerminalLocationDeletedLocation */ "deleted_terminal.location": { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "terminal.location"; } & { [key: string]: unknown }; /** TerminalReaderDeletedReader */ "deleted_terminal.reader": { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "terminal.reader"; } & { [key: string]: unknown }; /** NotificationWebhookEndpointDeleted */ deleted_webhook_endpoint: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "webhook_endpoint"; } & { [key: string]: unknown }; /** DeliveryEstimate */ @@ -3259,7 +3560,10 @@ export interface components { * @description If the coupon has a duration of `repeating`, the date that this discount will end. If the coupon has a duration of `once` or `forever`, this attribute will be null. */ end?: number | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "discount"; /** * Format: unix-time @@ -3303,7 +3607,10 @@ export interface components { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "dispute"; /** @description ID of the PaymentIntent that was disputed. */ payment_intent?: @@ -3311,7 +3618,10 @@ export interface components { | null; /** @description Reason given by cardholder for dispute. Possible values are `bank_cannot_process`, `check_returned`, `credit_not_processed`, `customer_initiated`, `debit_not_authorized`, `duplicate`, `fraudulent`, `general`, `incorrect_account_details`, `insufficient_funds`, `product_not_received`, `product_unacceptable`, `subscription_canceled`, or `unrecognized`. Read more about [dispute reasons](https://stripe.com/docs/disputes/categories). */ reason: string; - /** @description Current status of dispute. Possible values are `warning_needs_response`, `warning_under_review`, `warning_closed`, `needs_response`, `under_review`, `charge_refunded`, `won`, or `lost`. */ + /** + * @description Current status of dispute. Possible values are `warning_needs_response`, `warning_under_review`, `warning_closed`, `needs_response`, `under_review`, `charge_refunded`, `won`, or `lost`. + * @enum {string} + */ status: | "charge_refunded" | "lost" @@ -3423,7 +3733,10 @@ export interface components { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "ephemeral_key"; /** @description The key's secret. You can use this value to make authorized requests to the Stripe API. */ secret?: string; @@ -3479,7 +3792,10 @@ export interface components { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "event"; /** @description Number of webhooks that have yet to be successfully delivered (i.e., to return a 20x response) to the URLs you've specified. */ pending_webhooks: number; @@ -3505,7 +3821,10 @@ export interface components { exchange_rate: { /** @description Unique identifier for the object. Represented as the three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) in lowercase. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "exchange_rate"; /** @description Hash where the keys are supported currencies and the values are the exchange rate at which the base id currency converts to the key currency. */ rates: { [key: string]: number }; @@ -3555,7 +3874,10 @@ export interface components { id: string; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "fee_refund"; } & { [key: string]: unknown }; /** @@ -3588,13 +3910,19 @@ export interface components { data: components["schemas"]["file_link"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; } & { [key: string]: unknown }) | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "file"; /** @description The purpose of the file. Possible values are `additional_verification`, `business_icon`, `business_logo`, `customer_signature`, `dispute_evidence`, `finance_report_run`, `identity_document`, `pci_document`, `sigma_scheduled_query`, or `tax_document_user_upload`. */ purpose: string; @@ -3634,7 +3962,10 @@ export interface components { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "file_link"; /** @description The publicly accessible URL to download the file. */ url?: string | null; @@ -3727,7 +4058,10 @@ export interface components { attempted: boolean; /** @description Controls whether Stripe will perform [automatic collection](https://stripe.com/docs/billing/invoices/workflow/#auto_advance) of the invoice. When `false`, the invoice's state will not automatically advance without an explicit action. */ auto_advance?: boolean; - /** @description Indicates the reason why the invoice was created. `subscription_cycle` indicates an invoice created by a subscription advancing into a new period. `subscription_create` indicates an invoice created due to creating a subscription. `subscription_update` indicates an invoice created due to updating a subscription. `subscription` is set for all old invoices to indicate either a change to a subscription or a period advancement. `manual` is set for all invoices unrelated to a subscription (for example: created via the invoice editor). The `upcoming` value is reserved for simulated invoices per the upcoming invoice endpoint. `subscription_threshold` indicates an invoice created due to a billing threshold being reached. */ + /** + * @description Indicates the reason why the invoice was created. `subscription_cycle` indicates an invoice created by a subscription advancing into a new period. `subscription_create` indicates an invoice created due to creating a subscription. `subscription_update` indicates an invoice created due to updating a subscription. `subscription` is set for all old invoices to indicate either a change to a subscription or a period advancement. `manual` is set for all invoices unrelated to a subscription (for example: created via the invoice editor). The `upcoming` value is reserved for simulated invoices per the upcoming invoice endpoint. `subscription_threshold` indicates an invoice created due to a billing threshold being reached. + * @enum {string|null} + */ billing_reason?: | ( | "automatic_pending_invoice_item_invoice" @@ -3742,7 +4076,10 @@ export interface components { | null; /** @description ID of the latest charge generated for this invoice, if any. */ charge?: ((Partial & Partial) & { [key: string]: unknown }) | null; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this invoice using the default source attached to the customer. When sending an invoice, Stripe will email this invoice to the customer with payment instructions. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this invoice using the default source attached to the customer. When sending an invoice, Stripe will email this invoice to the customer with payment instructions. + * @enum {string|null} + */ collection_method?: ("charge_automatically" | "send_invoice") | null; /** * Format: unix-time @@ -3767,7 +4104,10 @@ export interface components { customer_phone?: string | null; /** @description The customer's shipping information. Until the invoice is finalized, this field will equal `customer.shipping`. Once the invoice is finalized, this field will no longer be updated. */ customer_shipping?: (Partial & { [key: string]: unknown }) | null; - /** @description The customer's tax exempt status. Until the invoice is finalized, this field will equal `customer.tax_exempt`. Once the invoice is finalized, this field will no longer be updated. */ + /** + * @description The customer's tax exempt status. Until the invoice is finalized, this field will equal `customer.tax_exempt`. Once the invoice is finalized, this field will no longer be updated. + * @enum {string|null} + */ customer_tax_exempt?: ("exempt" | "none" | "reverse") | null; /** @description The customer's tax IDs. Until the invoice is finalized, this field will contain the same tax IDs as `customer.tax_ids`. Once the invoice is finalized, this field will no longer be updated. */ customer_tax_ids?: components["schemas"]["invoices_resource_invoice_tax_id"][] | null; @@ -3814,7 +4154,10 @@ export interface components { data: components["schemas"]["line_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -3830,7 +4173,10 @@ export interface components { next_payment_attempt?: number | null; /** @description A unique, identifying string that appears on emails sent to the customer for this invoice. This starts with the customer's unique invoice_prefix if it is specified. */ number?: string | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "invoice"; /** @description Whether payment was successfully collected for this invoice. An invoice can be paid (most commonly) with a charge or with credit from the customer's account balance. */ paid: boolean; @@ -3858,7 +4204,10 @@ export interface components { starting_balance: number; /** @description Extra information about an invoice for the customer's credit card statement. */ statement_descriptor?: string | null; - /** @description The status of the invoice, one of `draft`, `open`, `paid`, `uncollectible`, or `void`. [Learn more](https://stripe.com/docs/billing/invoices/workflow#workflow-overview) */ + /** + * @description The status of the invoice, one of `draft`, `open`, `paid`, `uncollectible`, or `void`. [Learn more](https://stripe.com/docs/billing/invoices/workflow#workflow-overview) + * @enum {string|null} + */ status?: ("deleted" | "draft" | "open" | "paid" | "uncollectible" | "void") | null; status_transitions: components["schemas"]["invoices_status_transitions"]; /** @description The subscription that this invoice was prepared for, if any. */ @@ -3973,7 +4322,10 @@ export interface components { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "invoiceitem"; period: components["schemas"]["invoice_line_item_period"]; /** @description If the invoice item is a proration, the plan of the subscription that the proration was computed for. */ @@ -4000,7 +4352,10 @@ export interface components { } & { [key: string]: unknown }; /** InvoicesResourceInvoiceTaxID */ invoices_resource_invoice_tax_id: { - /** @description The type of the tax ID, one of `eu_vat`, `nz_gst`, `au_abn`, `in_gst`, `no_vat`, `za_vat`, `ch_vat`, `mx_rfc`, `sg_uen`, `ru_inn`, `ca_bn`, `hk_br`, `es_cif`, `tw_vat`, `th_vat`, `jp_cn`, `li_uid`, `my_itn`, `us_ein`, `kr_brn`, `ca_qst`, `my_sst`, `sg_gst`, or `unknown` */ + /** + * @description The type of the tax ID, one of `eu_vat`, `nz_gst`, `au_abn`, `in_gst`, `no_vat`, `za_vat`, `ch_vat`, `mx_rfc`, `sg_uen`, `ru_inn`, `ca_bn`, `hk_br`, `es_cif`, `tw_vat`, `th_vat`, `jp_cn`, `li_uid`, `my_itn`, `us_ein`, `kr_brn`, `ca_qst`, `my_sst`, `sg_gst`, or `unknown` + * @enum {string} + */ type: | "au_abn" | "ca_bn" @@ -4076,7 +4431,10 @@ export interface components { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "issuer_fraud_record"; /** @description The timestamp at which the card issuer posted the issuer fraud record. */ post_date: number; @@ -4094,7 +4452,10 @@ export interface components { amount: number; /** @description Whether the authorization has been approved. */ approved: boolean; - /** @description How the card details were provided. */ + /** + * @description How the card details were provided. + * @enum {string} + */ authorization_method: "chip" | "contactless" | "keyed_in" | "online" | "swipe"; /** @description List of balance transactions associated with this authorization. */ balance_transactions: components["schemas"]["balance_transaction"][]; @@ -4121,7 +4482,10 @@ export interface components { merchant_data: components["schemas"]["issuing_authorization_merchant_data"]; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "issuing.authorization"; /** @description The pending authorization request. This field will only be non-null during an `issuing_authorization.request` webhook. */ pending_request?: @@ -4129,7 +4493,10 @@ export interface components { | null; /** @description History of every time the authorization was approved/denied (whether approved/denied by you directly or by Stripe based on your `spending_controls`). If the merchant changes the authorization by performing an [incremental authorization or partial capture](https://stripe.com/docs/issuing/purchases/authorizations), you can look at this field to see the previous states of the authorization. */ request_history: components["schemas"]["issuing_authorization_request"][]; - /** @description The current status of the authorization in its lifecycle. */ + /** + * @description The current status of the authorization in its lifecycle. + * @enum {string} + */ status: "closed" | "pending" | "reversed"; /** @description List of [transactions](https://stripe.com/docs/api/issuing/transactions) associated with this authorization. */ transactions: components["schemas"]["issuing.transaction"][]; @@ -4144,7 +4511,10 @@ export interface components { "issuing.card": { /** @description The brand of the card. */ brand: string; - /** @description The reason why the card was canceled. */ + /** + * @description The reason why the card was canceled. + * @enum {string|null} + */ cancellation_reason?: ("lost" | "stolen") | null; cardholder: components["schemas"]["issuing.cardholder"]; /** @@ -4170,7 +4540,10 @@ export interface components { metadata: { [key: string]: string }; /** @description The full unredacted card number. For security reasons, this is only available for virtual cards, and will be omitted unless you explicitly request it with [the `expand` parameter](https://stripe.com/docs/api/expanding_objects). Additionally, it's only available via the ["Retrieve a card" endpoint](https://stripe.com/docs/api/issuing/cards/retrieve), not via "List all cards" or any other endpoint. */ number?: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "issuing.card"; /** @description The latest card that replaces this card, if any. */ replaced_by?: @@ -4180,14 +4553,23 @@ export interface components { replacement_for?: | ((Partial & Partial) & { [key: string]: unknown }) | null; - /** @description The reason why the previous card needed to be replaced. */ + /** + * @description The reason why the previous card needed to be replaced. + * @enum {string|null} + */ replacement_reason?: ("damaged" | "expired" | "lost" | "stolen") | null; /** @description Where and how the card will be shipped. */ shipping?: (Partial & { [key: string]: unknown }) | null; spending_controls: components["schemas"]["issuing_card_authorization_controls"]; - /** @description Whether authorizations can be approved on this card. */ + /** + * @description Whether authorizations can be approved on this card. + * @enum {string} + */ status: "active" | "canceled" | "inactive"; - /** @description The type of the card. */ + /** + * @description The type of the card. + * @enum {string} + */ type: "physical" | "virtual"; } & { [key: string]: unknown }; /** @@ -4219,7 +4601,10 @@ export interface components { metadata: { [key: string]: string }; /** @description The cardholder's name. This will be printed on cards issued to them. */ name: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "issuing.cardholder"; /** @description The cardholder's phone number. */ phone_number?: string | null; @@ -4228,9 +4613,15 @@ export interface components { spending_controls?: | (Partial & { [key: string]: unknown }) | null; - /** @description Specifies whether to permit authorizations on this cardholder's cards. */ + /** + * @description Specifies whether to permit authorizations on this cardholder's cards. + * @enum {string} + */ status: "active" | "blocked" | "inactive"; - /** @description One of `individual` or `company`. */ + /** + * @description One of `individual` or `company`. + * @enum {string} + */ type: "company" | "individual"; } & { [key: string]: unknown }; /** @@ -4244,7 +4635,10 @@ export interface components { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "issuing.dispute"; } & { [key: string]: unknown }; /** @@ -4273,13 +4667,19 @@ export interface components { metadata: { [key: string]: string }; /** @description The total net amount required to settle with the network. */ net_total: number; - /** @description The card network for this settlement report. One of ["visa"] */ + /** + * @description The card network for this settlement report. One of ["visa"] + * @enum {string} + */ network: "visa"; /** @description The total amount of fees owed to the network. */ network_fees: number; /** @description The Settlement Identification Number assigned by the network. */ network_settlement_identifier: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "issuing.settlement"; /** @description One of `international` or `uk_national_net`. */ settlement_service: string; @@ -4331,9 +4731,15 @@ export interface components { merchant_data: components["schemas"]["issuing_authorization_merchant_data"]; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "issuing.transaction"; - /** @description The nature of the transaction. */ + /** + * @description The nature of the transaction. + * @enum {string} + */ type: "capture" | "refund"; } & { [key: string]: unknown }; /** IssuingAuthorizationMerchantData */ @@ -4383,7 +4789,10 @@ export interface components { merchant_amount: number; /** @description The currency that was collected by the merchant and presented to the cardholder for the authorization. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). */ merchant_currency: string; - /** @description The reason for the approval or decline. */ + /** + * @description The reason for the approval or decline. + * @enum {string} + */ reason: | "account_disabled" | "card_active" @@ -4401,13 +4810,25 @@ export interface components { } & { [key: string]: unknown }; /** IssuingAuthorizationVerificationData */ issuing_authorization_verification_data: { - /** @description Whether the cardholder provided an address first line and if it matched the cardholder’s `billing.address.line1`. */ + /** + * @description Whether the cardholder provided an address first line and if it matched the cardholder’s `billing.address.line1`. + * @enum {string} + */ address_line1_check: "match" | "mismatch" | "not_provided"; - /** @description Whether the cardholder provided a postal code and if it matched the cardholder’s `billing.address.postal_code`. */ + /** + * @description Whether the cardholder provided a postal code and if it matched the cardholder’s `billing.address.postal_code`. + * @enum {string} + */ address_postal_code_check: "match" | "mismatch" | "not_provided"; - /** @description Whether the cardholder provided a CVC and if it matched Stripe’s record. */ + /** + * @description Whether the cardholder provided a CVC and if it matched Stripe’s record. + * @enum {string} + */ cvc_check: "match" | "mismatch" | "not_provided"; - /** @description Whether the cardholder provided an expiry date and if it matched Stripe’s record. */ + /** + * @description Whether the cardholder provided an expiry date and if it matched Stripe’s record. + * @enum {string} + */ expiry_check: "match" | "mismatch" | "not_provided"; } & { [key: string]: unknown }; /** IssuingCardAuthorizationControls */ @@ -5006,7 +5427,10 @@ export interface components { /** IssuingCardShipping */ issuing_card_shipping: { address: components["schemas"]["address"]; - /** @description The delivery company that shipped a card. */ + /** + * @description The delivery company that shipped a card. + * @enum {string|null} + */ carrier?: ("fedex" | "usps") | null; /** * Format: unix-time @@ -5015,15 +5439,24 @@ export interface components { eta?: number | null; /** @description Recipient name. */ name: string; - /** @description Shipment service, such as `standard` or `express`. */ + /** + * @description Shipment service, such as `standard` or `express`. + * @enum {string} + */ service: "express" | "priority" | "standard"; - /** @description The delivery status of the card. */ + /** + * @description The delivery status of the card. + * @enum {string|null} + */ status?: ("canceled" | "delivered" | "failure" | "pending" | "returned" | "shipped") | null; /** @description A tracking number for a card shipment. */ tracking_number?: string | null; /** @description A link to the shipping carrier's site where you can view detailed information about a card shipment. */ tracking_url?: string | null; - /** @description Packaging options. */ + /** + * @description Packaging options. + * @enum {string} + */ type: "bulk" | "individual"; } & { [key: string]: unknown }; /** IssuingCardSpendingLimit */ @@ -5323,7 +5756,10 @@ export interface components { | "wrecking_and_salvage_yards" )[] | null; - /** @description The time interval or event with which to apply this spending limit towards. */ + /** + * @description The time interval or event with which to apply this spending limit towards. + * @enum {string} + */ interval: "all_time" | "daily" | "monthly" | "per_authorization" | "weekly" | "yearly"; } & { [key: string]: unknown }; /** IssuingCardholderAddress */ @@ -5959,7 +6395,10 @@ export interface components { } & { [key: string]: unknown }; /** IssuingCardholderRequirements */ issuing_cardholder_requirements: { - /** @description If `disabled_reason` is present, all cards will decline authorizations with `cardholder_verification_required` reason. */ + /** + * @description If `disabled_reason` is present, all cards will decline authorizations with `cardholder_verification_required` reason. + * @enum {string|null} + */ disabled_reason?: ("listed" | "rejected.listed" | "under_review") | null; /** @description Array of fields that need to be collected in order to verify and re-enable the cardholder. */ past_due?: @@ -6271,7 +6710,10 @@ export interface components { | "wrecking_and_salvage_yards" )[] | null; - /** @description The time interval or event with which to apply this spending limit towards. */ + /** + * @description The time interval or event with which to apply this spending limit towards. + * @enum {string} + */ interval: "all_time" | "daily" | "monthly" | "per_authorization" | "weekly" | "yearly"; } & { [key: string]: unknown }; /** IssuingCardholderVerification */ @@ -6302,7 +6744,10 @@ export interface components { owners_provided?: boolean; /** @description The company's phone number (used for verification). */ phone?: string | null; - /** @description The category identifying the legal structure of the company or legal entity. See [Business structure](https://stripe.com/docs/connect/identity-verification#business-structure) for more details. */ + /** + * @description The category identifying the legal structure of the company or legal entity. See [Business structure](https://stripe.com/docs/connect/identity-verification#business-structure) for more details. + * @enum {string} + */ structure?: | "government_instrumentality" | "governmental_unit" @@ -6416,7 +6861,10 @@ export interface components { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Note that for line items with `type=subscription` this will reflect the metadata of the subscription that caused the line item to be created. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "line_item"; period: components["schemas"]["invoice_line_item_period"]; /** @description The plan of the subscription, if the line item is a subscription or a proration. */ @@ -6433,7 +6881,10 @@ export interface components { tax_amounts?: components["schemas"]["invoice_tax_amount"][] | null; /** @description The tax rates which apply to the line item. */ tax_rates?: components["schemas"]["tax_rate"][] | null; - /** @description A string identifying the type of the source of this line item, either an `invoiceitem` or a `subscription`. */ + /** + * @description A string identifying the type of the source of this line item, either an `invoiceitem` or a `subscription`. + * @enum {string} + */ type: "invoiceitem" | "subscription"; } & { [key: string]: unknown }; /** LoginLink */ @@ -6443,7 +6894,10 @@ export interface components { * @description Time at which the object was created. Measured in seconds since the Unix epoch. */ created: number; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "login_link"; /** @description The URL for the login link. */ url: string; @@ -6459,15 +6913,24 @@ export interface components { /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; multi_use?: components["schemas"]["mandate_multi_use"]; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "mandate"; /** @description ID of the payment method associated with this mandate. */ payment_method: (Partial & Partial) & { [key: string]: unknown }; payment_method_details: components["schemas"]["mandate_payment_method_details"]; single_use?: components["schemas"]["mandate_single_use"]; - /** @description The status of the mandate, which indicates whether it can be used to initiate a payment. */ + /** + * @description The status of the mandate, which indicates whether it can be used to initiate a payment. + * @enum {string} + */ status: "active" | "inactive" | "pending"; - /** @description The type of the mandate. */ + /** + * @description The type of the mandate. + * @enum {string} + */ type: "multi_use" | "single_use"; } & { [key: string]: unknown }; /** mandate_au_becs_debit */ @@ -6566,7 +7029,10 @@ export interface components { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "order"; /** * OrderReturnList @@ -6578,7 +7044,10 @@ export interface components { data: components["schemas"]["order_return"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -6616,7 +7085,10 @@ export interface components { currency: string; /** @description Description of the line item, meant to be displayable to the user (e.g., `"Express shipping"`). */ description: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "order_item"; /** @description The ID of the associated object for this line item. Expandable if not null (e.g., expandable to a SKU). */ parent?: ((Partial & Partial) & { [key: string]: unknown }) | null; @@ -6648,7 +7120,10 @@ export interface components { items: components["schemas"]["order_item"][]; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "order_return"; /** @description The order that this return includes items from. */ order?: ((Partial & Partial) & { [key: string]: unknown }) | null; @@ -6698,7 +7173,10 @@ export interface components { * @description Populated when `status` is `canceled`, this is the time at which the PaymentIntent was canceled. Measured in seconds since the Unix epoch. */ canceled_at?: number | null; - /** @description Reason for cancellation of this PaymentIntent, either user-provided (`duplicate`, `fraudulent`, `requested_by_customer`, or `abandoned`) or generated by Stripe internally (`failed_invoice`, `void_invoice`, or `automatic`). */ + /** + * @description Reason for cancellation of this PaymentIntent, either user-provided (`duplicate`, `fraudulent`, `requested_by_customer`, or `abandoned`) or generated by Stripe internally (`failed_invoice`, `void_invoice`, or `automatic`). + * @enum {string|null} + */ cancellation_reason?: | ( | "abandoned" @@ -6710,7 +7188,10 @@ export interface components { | "void_invoice" ) | null; - /** @description Controls when the funds will be captured from the customer's account. */ + /** + * @description Controls when the funds will be captured from the customer's account. + * @enum {string} + */ capture_method: "automatic" | "manual"; /** * PaymentFlowsPaymentIntentResourceChargeList @@ -6721,7 +7202,10 @@ export interface components { data: components["schemas"]["charge"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -6734,6 +7218,7 @@ export interface components { * Refer to our docs to [accept a payment](https://stripe.com/docs/payments/accept-a-payment) and learn about how `client_secret` should be handled. */ client_secret?: string | null; + /** @enum {string} */ confirmation_method: "automatic" | "manual"; /** * Format: unix-time @@ -6768,7 +7253,10 @@ export interface components { metadata?: { [key: string]: string }; /** @description If present, this property tells you what actions you need to take in order for your customer to fulfill a payment using the provided source. */ next_action?: (Partial & { [key: string]: unknown }) | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "payment_intent"; /** @description The account (if any) for which the funds of the PaymentIntent are intended. See the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts) for details. */ on_behalf_of?: @@ -6794,6 +7282,7 @@ export interface components { * Providing this parameter will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any required actions from the user are complete. If no Customer was provided, the payment method can still be [attached](https://stripe.com/docs/api/payment_methods/attach) to a Customer after the transaction completes. * * When processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication). + * @enum {string|null} */ setup_future_usage?: ("off_session" | "on_session") | null; /** @description Shipping information for this PaymentIntent. */ @@ -6802,7 +7291,10 @@ export interface components { statement_descriptor?: string | null; /** @description Provides information about a card payment that customers see on their statements. Concatenated with the prefix (shortened descriptor) or statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 22 characters for the concatenated descriptor. */ statement_descriptor_suffix?: string | null; - /** @description Status of this PaymentIntent, one of `requires_payment_method`, `requires_confirmation`, `requires_action`, `processing`, `requires_capture`, `canceled`, or `succeeded`. Read more about each PaymentIntent [status](https://stripe.com/docs/payments/intents#intent-statuses). */ + /** + * @description Status of this PaymentIntent, one of `requires_payment_method`, `requires_confirmation`, `requires_action`, `processing`, `requires_capture`, `canceled`, or `succeeded`. Read more about each PaymentIntent [status](https://stripe.com/docs/payments/intents#intent-statuses). + * @enum {string} + */ status: | "canceled" | "processing" @@ -6845,7 +7337,10 @@ export interface components { installments?: | (Partial & { [key: string]: unknown }) | null; - /** @description We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Permitted values include: `automatic` or `any`. If not provided, defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine. */ + /** + * @description We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Permitted values include: `automatic` or `any`. If not provided, defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine. + * @enum {string|null} + */ request_three_d_secure?: ("any" | "automatic" | "challenge_only") | null; } & { [key: string]: unknown }; /** @@ -6876,10 +7371,16 @@ export interface components { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "payment_method"; sepa_debit?: components["schemas"]["payment_method_sepa_debit"]; - /** @description The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type. */ + /** + * @description The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type. + * @enum {string} + */ type: "au_becs_debit" | "card" | "fpx" | "ideal" | "sepa_debit"; } & { [key: string]: unknown }; /** payment_method_au_becs_debit */ @@ -6949,7 +7450,10 @@ export interface components { google_pay?: components["schemas"]["payment_method_card_wallet_google_pay"]; masterpass?: components["schemas"]["payment_method_card_wallet_masterpass"]; samsung_pay?: components["schemas"]["payment_method_card_wallet_samsung_pay"]; - /** @description The type of the card wallet, one of `amex_express_checkout`, `apple_pay`, `google_pay`, `masterpass`, `samsung_pay`, or `visa_checkout`. An additional hash is included on the Wallet subhash with a name matching this value. It contains additional information specific to the card wallet type. */ + /** + * @description The type of the card wallet, one of `amex_express_checkout`, `apple_pay`, `google_pay`, `masterpass`, `samsung_pay`, or `visa_checkout`. An additional hash is included on the Wallet subhash with a name matching this value. It contains additional information specific to the card wallet type. + * @enum {string} + */ type: "amex_express_checkout" | "apple_pay" | "google_pay" | "masterpass" | "samsung_pay" | "visa_checkout"; visa_checkout?: components["schemas"]["payment_method_card_wallet_visa_checkout"]; } & { [key: string]: unknown }; @@ -7023,7 +7527,10 @@ export interface components { } & { [key: string]: unknown }; /** payment_method_details_ach_debit */ payment_method_details_ach_debit: { - /** @description Type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description Type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string|null} + */ account_holder_type?: ("company" | "individual") | null; /** @description Name of the bank associated with the bank account. */ bank_name?: string | null; @@ -7062,6 +7569,7 @@ export interface components { /** * @description Preferred language of the Bancontact authorization page that the customer is redirected to. * Can be one of `en`, `de`, `fr`, or `nl` + * @enum {string|null} */ preferred_language?: ("de" | "en" | "fr" | "nl") | null; /** @@ -7130,9 +7638,13 @@ export interface components { /** * @description For `fixed_count` installment plans, this is the interval between installment payments your customer will make to their credit card. * One of `month`. + * @enum {string|null} */ interval?: "month" | null; - /** @description Type of installment plan, one of `fixed_count`. */ + /** + * @description Type of installment plan, one of `fixed_count`. + * @enum {string} + */ type: "fixed_count"; } & { [key: string]: unknown }; /** payment_method_details_card_present */ @@ -7194,7 +7706,10 @@ export interface components { google_pay?: components["schemas"]["payment_method_details_card_wallet_google_pay"]; masterpass?: components["schemas"]["payment_method_details_card_wallet_masterpass"]; samsung_pay?: components["schemas"]["payment_method_details_card_wallet_samsung_pay"]; - /** @description The type of the card wallet, one of `amex_express_checkout`, `apple_pay`, `google_pay`, `masterpass`, `samsung_pay`, or `visa_checkout`. An additional hash is included on the Wallet subhash with a name matching this value. It contains additional information specific to the card wallet type. */ + /** + * @description The type of the card wallet, one of `amex_express_checkout`, `apple_pay`, `google_pay`, `masterpass`, `samsung_pay`, or `visa_checkout`. An additional hash is included on the Wallet subhash with a name matching this value. It contains additional information specific to the card wallet type. + * @enum {string} + */ type: "amex_express_checkout" | "apple_pay" | "google_pay" | "masterpass" | "samsung_pay" | "visa_checkout"; visa_checkout?: components["schemas"]["payment_method_details_card_wallet_visa_checkout"]; } & { [key: string]: unknown }; @@ -7238,7 +7753,10 @@ export interface components { } & { [key: string]: unknown }; /** payment_method_details_fpx */ payment_method_details_fpx: { - /** @description The customer's bank. Can be one of `affin_bank`, `alliance_bank`, `ambank`, `bank_islam`, `bank_muamalat`, `bank_rakyat`, `bsn`, `cimb`, `hong_leong_bank`, `hsbc`, `kfh`, `maybank2u`, `ocbc`, `public_bank`, `rhb`, `standard_chartered`, `uob`, `deutsche_bank`, `maybank2e`, or `pb_enterprise`. */ + /** + * @description The customer's bank. Can be one of `affin_bank`, `alliance_bank`, `ambank`, `bank_islam`, `bank_muamalat`, `bank_rakyat`, `bsn`, `cimb`, `hong_leong_bank`, `hsbc`, `kfh`, `maybank2u`, `ocbc`, `public_bank`, `rhb`, `standard_chartered`, `uob`, `deutsche_bank`, `maybank2e`, or `pb_enterprise`. + * @enum {string} + */ bank: | "affin_bank" | "alliance_bank" @@ -7279,7 +7797,10 @@ export interface components { } & { [key: string]: unknown }; /** payment_method_details_ideal */ payment_method_details_ideal: { - /** @description The customer's bank. Can be one of `abn_amro`, `asn_bank`, `bunq`, `handelsbanken`, `ing`, `knab`, `moneyou`, `rabobank`, `regiobank`, `sns_bank`, `triodos_bank`, or `van_lanschot`. */ + /** + * @description The customer's bank. Can be one of `abn_amro`, `asn_bank`, `bunq`, `handelsbanken`, `ing`, `knab`, `moneyou`, `rabobank`, `regiobank`, `sns_bank`, `triodos_bank`, or `van_lanschot`. + * @enum {string|null} + */ bank?: | ( | "abn_amro" @@ -7296,7 +7817,10 @@ export interface components { | "van_lanschot" ) | null; - /** @description The Bank Identifier Code of the customer's bank. */ + /** + * @description The Bank Identifier Code of the customer's bank. + * @enum {string|null} + */ bic?: | ( | "ABNANL2A" @@ -7379,7 +7903,10 @@ export interface components { payment_method_details_wechat: { [key: string]: unknown }; /** payment_method_fpx */ payment_method_fpx: { - /** @description The customer's bank, if provided. Can be one of `affin_bank`, `alliance_bank`, `ambank`, `bank_islam`, `bank_muamalat`, `bank_rakyat`, `bsn`, `cimb`, `hong_leong_bank`, `hsbc`, `kfh`, `maybank2u`, `ocbc`, `public_bank`, `rhb`, `standard_chartered`, `uob`, `deutsche_bank`, `maybank2e`, or `pb_enterprise`. */ + /** + * @description The customer's bank, if provided. Can be one of `affin_bank`, `alliance_bank`, `ambank`, `bank_islam`, `bank_muamalat`, `bank_rakyat`, `bsn`, `cimb`, `hong_leong_bank`, `hsbc`, `kfh`, `maybank2u`, `ocbc`, `public_bank`, `rhb`, `standard_chartered`, `uob`, `deutsche_bank`, `maybank2e`, or `pb_enterprise`. + * @enum {string} + */ bank: | "affin_bank" | "alliance_bank" @@ -7404,7 +7931,10 @@ export interface components { } & { [key: string]: unknown }; /** payment_method_ideal */ payment_method_ideal: { - /** @description The customer's bank, if provided. Can be one of `abn_amro`, `asn_bank`, `bunq`, `handelsbanken`, `ing`, `knab`, `moneyou`, `rabobank`, `regiobank`, `sns_bank`, `triodos_bank`, or `van_lanschot`. */ + /** + * @description The customer's bank, if provided. Can be one of `abn_amro`, `asn_bank`, `bunq`, `handelsbanken`, `ing`, `knab`, `moneyou`, `rabobank`, `regiobank`, `sns_bank`, `triodos_bank`, or `van_lanschot`. + * @enum {string|null} + */ bank?: | ( | "abn_amro" @@ -7421,7 +7951,10 @@ export interface components { | "van_lanschot" ) | null; - /** @description The Bank Identifier Code of the customer's bank, if the bank was provided. */ + /** + * @description The Bank Identifier Code of the customer's bank, if the bank was provided. + * @enum {string|null} + */ bic?: | ( | "ABNANL2A" @@ -7774,7 +8307,10 @@ export interface components { metadata: { [key: string]: string }; /** @description The method used to send this payout, which can be `standard` or `instant`. `instant` is only supported for payouts to debit cards. (See [Instant payouts for marketplaces](https://stripe.com/blog/instant-payouts-for-marketplaces) for more information.) */ method: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "payout"; /** @description The source balance this payout came from. One of `card`, `fpx`, or `bank_account`. */ source_type: string; @@ -7782,7 +8318,10 @@ export interface components { statement_descriptor?: string | null; /** @description Current status of the payout: `paid`, `pending`, `in_transit`, `canceled` or `failed`. A payout is `pending` until it is submitted to the bank, when it becomes `in_transit`. The status then changes to `paid` if the transaction goes through, or to `failed` or `canceled` (within 5 business days). Some failed payouts may initially show as `paid` but then change to `failed`. */ status: string; - /** @description Can be `bank_account` or `card`. */ + /** + * @description Can be `bank_account` or `card`. + * @enum {string} + */ type: "bank_account" | "card"; } & { [key: string]: unknown }; /** Period */ @@ -7831,7 +8370,10 @@ export interface components { maiden_name?: string | null; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata?: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "person"; phone?: string | null; relationship?: components["schemas"]["person_relationship"]; @@ -7879,7 +8421,10 @@ export interface components { plan: { /** @description Whether the plan can be used for new purchases. */ active: boolean; - /** @description Specifies a usage aggregation strategy for plans of `usage_type=metered`. Allowed values are `sum` for summing up all usage during a period, `last_during_period` for using the last usage record reported within a period, `last_ever` for using the last usage record ever (across period bounds) or `max` which uses the usage record with the maximum reported usage during a period. Defaults to `sum`. */ + /** + * @description Specifies a usage aggregation strategy for plans of `usage_type=metered`. Allowed values are `sum` for summing up all usage during a period, `last_during_period` for using the last usage record reported within a period, `last_ever` for using the last usage record ever (across period bounds) or `max` which uses the usage record with the maximum reported usage during a period. Defaults to `sum`. + * @enum {string|null} + */ aggregate_usage?: ("last_during_period" | "last_ever" | "max" | "sum") | null; /** @description The amount in %s to be charged on the interval specified. */ amount?: number | null; @@ -7888,7 +8433,10 @@ export interface components { * @description Same as `amount`, but contains a decimal value with at most 12 decimal places. */ amount_decimal?: string | null; - /** @description Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `amount`) will be charged per unit in `quantity` (for plans with `usage_type=licensed`), or per unit of total usage (for plans with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes. */ + /** + * @description Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `amount`) will be charged per unit in `quantity` (for plans with `usage_type=licensed`), or per unit of total usage (for plans with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes. + * @enum {string} + */ billing_scheme: "per_unit" | "tiered"; /** * Format: unix-time @@ -7899,7 +8447,10 @@ export interface components { currency: string; /** @description Unique identifier for the object. */ id: string; - /** @description The frequency at which a subscription is billed. One of `day`, `week`, `month` or `year`. */ + /** + * @description The frequency at which a subscription is billed. One of `day`, `week`, `month` or `year`. + * @enum {string} + */ interval: "day" | "month" | "week" | "year"; /** @description The number of intervals (specified in the `interval` attribute) between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. */ interval_count: number; @@ -7909,7 +8460,10 @@ export interface components { metadata: { [key: string]: string }; /** @description A brief description of the plan, hidden from customers. */ nickname?: string | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "plan"; /** @description The product whose pricing this plan determines. */ product?: @@ -7919,13 +8473,19 @@ export interface components { | null; /** @description Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`. */ tiers?: components["schemas"]["plan_tier"][] | null; - /** @description Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price. In `graduated` tiering, pricing can change as the quantity grows. */ + /** + * @description Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price. In `graduated` tiering, pricing can change as the quantity grows. + * @enum {string|null} + */ tiers_mode?: ("graduated" | "volume") | null; /** @description Apply a transformation to the reported usage or set quantity before computing the amount billed. Cannot be combined with `tiers`. */ transform_usage?: (Partial & { [key: string]: unknown }) | null; /** @description Default number of trial days when subscribing a customer to this plan using [`trial_from_plan=true`](https://stripe.com/docs/api#create_subscription-trial_from_plan). */ trial_period_days?: number | null; - /** @description Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`. */ + /** + * @description Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`. + * @enum {string} + */ usage_type: "licensed" | "metered"; } & { [key: string]: unknown }; /** PlanTier */ @@ -7953,7 +8513,10 @@ export interface components { account: string; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "platform_tax_fee"; /** @description The payment object that caused this tax to be inflicted. */ source_transaction: string; @@ -7997,7 +8560,10 @@ export interface components { metadata: { [key: string]: string }; /** @description The product's name, meant to be displayable to the customer. Whenever this product is sold via a subscription, name will show up on associated invoice line item descriptions. */ name: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "product"; /** @description The dimensions of this product for shipping purposes. A SKU associated with this product can override this value by having its own `package_dimensions`. Only applicable to products of `type=good`. */ package_dimensions?: (Partial & { [key: string]: unknown }) | null; @@ -8005,7 +8571,10 @@ export interface components { shippable?: boolean | null; /** @description Extra information about a product which will appear on your customer's credit card statement. In the case that multiple products are billed at once, the first statement descriptor will be used. */ statement_descriptor?: string | null; - /** @description The type of the product. The product is either of type `good`, which is eligible for use with Orders and SKUs, or `service`, which is eligible for use with Subscriptions and Plans. */ + /** + * @description The type of the product. The product is either of type `good`, which is eligible for use with Orders and SKUs, or `service`, which is eligible for use with Subscriptions and Plans. + * @enum {string} + */ type: "good" | "service"; /** @description A label that represents units of this product in Stripe and on customers’ receipts and invoices. When set, this will be included in associated invoice line item descriptions. */ unit_label?: string | null; @@ -8040,7 +8609,10 @@ export interface components { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "radar.early_fraud_warning"; } & { [key: string]: unknown }; /** @@ -8061,7 +8633,10 @@ export interface components { created_by: string; /** @description Unique identifier for the object. */ id: string; - /** @description The type of items in the value list. One of `card_fingerprint`, `card_bin`, `email`, `ip_address`, `country`, `string`, or `case_sensitive_string`. */ + /** + * @description The type of items in the value list. One of `card_fingerprint`, `card_bin`, `email`, `ip_address`, `country`, `string`, or `case_sensitive_string`. + * @enum {string} + */ item_type: | "card_bin" | "card_fingerprint" @@ -8079,7 +8654,10 @@ export interface components { data: components["schemas"]["radar.value_list_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -8090,7 +8668,10 @@ export interface components { metadata: { [key: string]: string }; /** @description The name of the value list. */ name: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "radar.value_list"; } & { [key: string]: unknown }; /** @@ -8111,7 +8692,10 @@ export interface components { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "radar.value_list_item"; /** @description The value of the item. */ value: string; @@ -8165,7 +8749,10 @@ export interface components { data: components["schemas"]["card"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -8191,7 +8778,10 @@ export interface components { migrated_to?: ((Partial & Partial) & { [key: string]: unknown }) | null; /** @description Full, legal name of the recipient. */ name?: string | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "recipient"; rolled_back_from?: (Partial & Partial) & { [key: string]: unknown }; /** @description Type of the recipient, one of `individual` or `corporation`. */ @@ -8233,7 +8823,10 @@ export interface components { id: string; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "refund"; /** @description ID of the PaymentIntent that was refunded. */ payment_intent?: @@ -8281,7 +8874,10 @@ export interface components { id: string; /** @description Always `true`: reports can only be run on live-mode data. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "reporting.report_run"; parameters: components["schemas"]["financial_reporting_finance_report_run_run_parameters"]; /** @description The ID of the [report type](https://stripe.com/docs/reporting/statements/api#report-types) to run, such as `"balance.summary.1"`. */ @@ -8333,7 +8929,10 @@ export interface components { id: string; /** @description Human-readable name of the Report Type */ name: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "reporting.report_type"; /** * Format: unix-time @@ -8352,7 +8951,10 @@ export interface components { description?: string | null; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "reserve_transaction"; } & { [key: string]: unknown }; /** @@ -8367,7 +8969,10 @@ export interface components { billing_zip?: string | null; /** @description The charge associated with this review. */ charge?: ((Partial & Partial) & { [key: string]: unknown }) | null; - /** @description The reason the review was closed, or null if it has not yet been closed. One of `approved`, `refunded`, `refunded_as_fraud`, or `disputed`. */ + /** + * @description The reason the review was closed, or null if it has not yet been closed. One of `approved`, `refunded`, `refunded_as_fraud`, or `disputed`. + * @enum {string|null} + */ closed_reason?: ("approved" | "disputed" | "refunded" | "refunded_as_fraud") | null; /** * Format: unix-time @@ -8384,11 +8989,17 @@ export interface components { | null; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "review"; /** @description If `true`, the review needs action. */ open: boolean; - /** @description The reason the review was opened. One of `rule` or `manual`. */ + /** + * @description The reason the review was opened. One of `rule` or `manual`. + * @enum {string} + */ opened_reason: "manual" | "rule"; /** @description The PaymentIntent ID associated with this review, if one exists. */ payment_intent?: (Partial & Partial) & { @@ -8433,7 +9044,10 @@ export interface components { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "scheduled_query_run"; /** * Format: unix-time @@ -8477,7 +9091,10 @@ export interface components { application?: | ((Partial & Partial) & { [key: string]: unknown }) | null; - /** @description Reason for cancellation of this SetupIntent, one of `abandoned`, `requested_by_customer`, or `duplicate`. */ + /** + * @description Reason for cancellation of this SetupIntent, one of `abandoned`, `requested_by_customer`, or `duplicate`. + * @enum {string|null} + */ cancellation_reason?: ("abandoned" | "duplicate" | "requested_by_customer") | null; /** * @description The client secret of this SetupIntent. Used for client-side retrieval using a publishable key. @@ -8514,7 +9131,10 @@ export interface components { metadata?: { [key: string]: string }; /** @description If present, this property tells you what actions you need to take in order for your customer to continue payment setup. */ next_action?: (Partial & { [key: string]: unknown }) | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "setup_intent"; /** @description The account (if any) for which the setup is intended. */ on_behalf_of?: @@ -8534,7 +9154,10 @@ export interface components { single_use_mandate?: | ((Partial & Partial) & { [key: string]: unknown }) | null; - /** @description [Status](https://stripe.com/docs/payments/intents#intent-statuses) of this SetupIntent, one of `requires_payment_method`, `requires_confirmation`, `requires_action`, `processing`, `canceled`, or `succeeded`. */ + /** + * @description [Status](https://stripe.com/docs/payments/intents#intent-statuses) of this SetupIntent, one of `requires_payment_method`, `requires_confirmation`, `requires_action`, `processing`, `canceled`, or `succeeded`. + * @enum {string} + */ status: | "canceled" | "processing" @@ -8570,7 +9193,10 @@ export interface components { } & { [key: string]: unknown }; /** setup_intent_payment_method_options_card */ setup_intent_payment_method_options_card: { - /** @description We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Permitted values include: `automatic` or `any`. If not provided, defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine. */ + /** + * @description We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Permitted values include: `automatic` or `any`. If not provided, defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine. + * @enum {string|null} + */ request_three_d_secure?: ("any" | "automatic" | "challenge_only") | null; } & { [key: string]: unknown }; /** Shipping */ @@ -8635,7 +9261,10 @@ export interface components { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "sku"; /** @description The dimensions of this SKU for shipping purposes. */ package_dimensions?: (Partial & { [key: string]: unknown }) | null; @@ -8693,7 +9322,10 @@ export interface components { /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata?: { [key: string]: string } | null; multibanco?: components["schemas"]["source_type_multibanco"]; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "source"; /** @description Information about the owner of the payment instrument that may be used or required by particular source types. */ owner?: (Partial & { [key: string]: unknown }) | null; @@ -8708,7 +9340,10 @@ export interface components { /** @description The status of the source, one of `canceled`, `chargeable`, `consumed`, `failed`, or `pending`. Only `chargeable` sources can be used to create a charge. */ status: string; three_d_secure?: components["schemas"]["source_type_three_d_secure"]; - /** @description The `type` of the source. The `type` is a payment method, one of `ach_credit_transfer`, `ach_debit`, `alipay`, `bancontact`, `card`, `card_present`, `eps`, `giropay`, `ideal`, `multibanco`, `klarna`, `p24`, `sepa_debit`, `sofort`, `three_d_secure`, or `wechat`. An additional hash is included on the source with a name matching this value. It contains additional information specific to the [payment method](https://stripe.com/docs/sources) used. */ + /** + * @description The `type` of the source. The `type` is a payment method, one of `ach_credit_transfer`, `ach_debit`, `alipay`, `bancontact`, `card`, `card_present`, `eps`, `giropay`, `ideal`, `multibanco`, `klarna`, `p24`, `sepa_debit`, `sofort`, `three_d_secure`, or `wechat`. An additional hash is included on the source with a name matching this value. It contains additional information specific to the [payment method](https://stripe.com/docs/sources) used. + * @enum {string} + */ type: | "ach_credit_transfer" | "ach_debit" @@ -8757,7 +9392,10 @@ export interface components { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "source_mandate_notification"; /** @description The reason of the mandate notification. Valid reasons are `mandate_confirmed` or `debit_initiated`. */ reason: string; @@ -8876,7 +9514,10 @@ export interface components { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "source_transaction"; paper_check?: components["schemas"]["source_transaction_paper_check_data"]; sepa_credit_transfer?: components["schemas"]["source_transaction_sepa_credit_transfer_data"]; @@ -8884,7 +9525,10 @@ export interface components { source: string; /** @description The status of the transaction, one of `succeeded`, `pending`, or `failed`. */ status: string; - /** @description The type of source this transaction is attached to. */ + /** + * @description The type of source this transaction is attached to. + * @enum {string} + */ type: | "ach_credit_transfer" | "ach_debit" @@ -9190,7 +9834,10 @@ export interface components { * @description If the subscription has been canceled, the date of that cancellation. If the subscription was canceled with `cancel_at_period_end`, `canceled_at` will still reflect the date of the initial cancellation request, not the end of the subscription period when the subscription is automatically moved to a canceled state. */ canceled_at?: number | null; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. + * @enum {string|null} + */ collection_method?: ("charge_automatically" | "send_invoice") | null; /** * Format: unix-time @@ -9246,7 +9893,10 @@ export interface components { data: components["schemas"]["subscription_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -9264,7 +9914,10 @@ export interface components { * @description Specifies the approximate timestamp on which any pending invoice items will be billed according to the schedule provided at `pending_invoice_item_interval`. */ next_pending_invoice_item_invoice?: number | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "subscription"; /** @description If specified, payment collection for this subscription will be paused. */ pause_collection?: @@ -9305,6 +9958,7 @@ export interface components { * If subscription `collection_method=charge_automatically` it becomes `past_due` when payment to renew it fails and `canceled` or `unpaid` (depending on your subscriptions settings) when Stripe has exhausted all payment retry attempts. * * If subscription `collection_method=send_invoice` it becomes `past_due` when its invoice is not paid by the due date, and `canceled` or `unpaid` if it is still not paid by an additional deadline after that. Note that when a subscription has a status of `unpaid`, no subsequent invoices will be attempted (invoices will be created, but then immediately automatically closed). After receiving updated payment information from a customer, you may choose to reopen and pay their closed invoices. + * @enum {string} */ status: "active" | "canceled" | "incomplete" | "incomplete_expired" | "past_due" | "trialing" | "unpaid"; /** @description If provided, each invoice created by this subscription will apply the tax rate, increasing the amount billed to the customer. */ @@ -9343,7 +9997,10 @@ export interface components { id: string; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "subscription_item"; plan: components["schemas"]["plan"]; /** @description The [quantity](https://stripe.com/docs/subscriptions/quantities) of the plan to which the customer should be subscribed. */ @@ -9360,7 +10017,10 @@ export interface components { } & { [key: string]: unknown }; /** SubscriptionPendingInvoiceItemInterval */ subscription_pending_invoice_item_interval: { - /** @description Specifies invoicing frequency. Either `day`, `week`, `month` or `year`. */ + /** + * @description Specifies invoicing frequency. Either `day`, `week`, `month` or `year`. + * @enum {string} + */ interval: "day" | "month" | "week" | "year"; /** @description The number of intervals between invoices. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). */ interval_count: number; @@ -9396,7 +10056,10 @@ export interface components { Partial & Partial) & { [key: string]: unknown }; default_settings: components["schemas"]["subscription_schedules_resource_default_settings"]; - /** @description Behavior of the subscription schedule and underlying subscription when it ends. */ + /** + * @description Behavior of the subscription schedule and underlying subscription when it ends. + * @enum {string} + */ end_behavior: "cancel" | "none" | "release" | "renew"; /** @description Unique identifier for the object. */ id: string; @@ -9404,7 +10067,10 @@ export interface components { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata?: { [key: string]: string } | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "subscription_schedule"; /** @description Configuration for the subscription schedule's phases. */ phases: components["schemas"]["subscription_schedule_phase_configuration"][]; @@ -9415,7 +10081,10 @@ export interface components { released_at?: number | null; /** @description ID of the subscription once managed by the subscription schedule (if it is released). */ released_subscription?: string | null; - /** @description The present status of the subscription schedule. Possible values are `not_started`, `active`, `completed`, `released`, and `canceled`. You can read more about the different states in our [behavior guide](https://stripe.com/docs/billing/subscriptions/subscription-schedules). */ + /** + * @description The present status of the subscription schedule. Possible values are `not_started`, `active`, `completed`, `released`, and `canceled`. You can read more about the different states in our [behavior guide](https://stripe.com/docs/billing/subscriptions/subscription-schedules). + * @enum {string} + */ status: "active" | "canceled" | "completed" | "not_started" | "released"; /** @description ID of the subscription managed by the subscription schedule. */ subscription?: @@ -9464,7 +10133,10 @@ export interface components { billing_thresholds?: | (Partial & { [key: string]: unknown }) | null; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. + * @enum {string|null} + */ collection_method?: ("charge_automatically" | "send_invoice") | null; /** @description ID of the coupon to use during this phase of the subscription schedule. */ coupon?: @@ -9489,7 +10161,10 @@ export interface components { | null; /** @description Plans to subscribe during this phase of the subscription schedule. */ plans: components["schemas"]["subscription_schedule_configuration_item"][]; - /** @description Controls whether or not the subscription schedule will prorate when transitioning to this phase. Values are `create_prorations` and `none`. */ + /** + * @description Controls whether or not the subscription schedule will prorate when transitioning to this phase. Values are `create_prorations` and `none`. + * @enum {string|null} + */ proration_behavior?: ("always_invoice" | "create_prorations" | "none") | null; /** * Format: unix-time @@ -9510,7 +10185,10 @@ export interface components { billing_thresholds?: | (Partial & { [key: string]: unknown }) | null; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. + * @enum {string|null} + */ collection_method?: ("charge_automatically" | "send_invoice") | null; /** @description ID of the default payment method for the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings. */ default_payment_method?: @@ -9527,7 +10205,10 @@ export interface components { * should be paused. */ subscriptions_resource_pause_collection: { - /** @description The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`. */ + /** + * @description The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`. + * @enum {string} + */ behavior: "keep_as_draft" | "mark_uncollectible" | "void"; /** * Format: unix-time @@ -9565,7 +10246,10 @@ export interface components { tax_deducted_at_source: { /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "tax_deducted_at_source"; /** * Format: unix-time @@ -9601,9 +10285,15 @@ export interface components { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "tax_id"; - /** @description Type of the tax ID, one of `au_abn`, `ca_bn`, `ca_qst`, `ch_vat`, `es_cif`, `eu_vat`, `hk_br`, `in_gst`, `jp_cn`, `kr_brn`, `li_uid`, `mx_rfc`, `my_itn`, `my_sst`, `no_vat`, `nz_gst`, `ru_inn`, `sg_gst`, `sg_uen`, `th_vat`, `tw_vat`, `us_ein`, or `za_vat`. Note that some legacy tax IDs have type `unknown` */ + /** + * @description Type of the tax ID, one of `au_abn`, `ca_bn`, `ca_qst`, `ch_vat`, `es_cif`, `eu_vat`, `hk_br`, `in_gst`, `jp_cn`, `kr_brn`, `li_uid`, `mx_rfc`, `my_itn`, `my_sst`, `no_vat`, `nz_gst`, `ru_inn`, `sg_gst`, `sg_uen`, `th_vat`, `tw_vat`, `us_ein`, or `za_vat`. Note that some legacy tax IDs have type `unknown` + * @enum {string} + */ type: | "au_abn" | "ca_bn" @@ -9635,7 +10325,10 @@ export interface components { } & { [key: string]: unknown }; /** tax_id_verification */ tax_id_verification: { - /** @description Verification status, one of `pending`, `verified`, `unverified`, or `unavailable`. */ + /** + * @description Verification status, one of `pending`, `verified`, `unverified`, or `unavailable`. + * @enum {string} + */ status: "pending" | "unavailable" | "unverified" | "verified"; /** @description Verified address. */ verified_address?: string | null; @@ -9670,7 +10363,10 @@ export interface components { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "tax_rate"; /** @description This represents the tax rate percent out of 100. */ percentage: number; @@ -9684,7 +10380,10 @@ export interface components { "terminal.connection_token": { /** @description The id of the location that this connection token is scoped to. */ location?: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "terminal.connection_token"; /** @description Your application should pass this token to the Stripe Terminal SDK. */ secret: string; @@ -9705,7 +10404,10 @@ export interface components { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "terminal.location"; } & { [key: string]: unknown }; /** @@ -9717,7 +10419,10 @@ export interface components { "terminal.reader": { /** @description The current software version of the reader. */ device_sw_version?: string | null; - /** @description Type of reader, one of `bbpos_chipper2x` or `verifone_P400`. */ + /** + * @description Type of reader, one of `bbpos_chipper2x` or `verifone_P400`. + * @enum {string} + */ device_type: "bbpos_chipper2x" | "verifone_P400"; /** @description Unique identifier for the object. */ id: string; @@ -9731,7 +10436,10 @@ export interface components { location?: string | null; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "terminal.reader"; /** @description Serial number of the reader. */ serial_number: string; @@ -9761,7 +10469,10 @@ export interface components { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "three_d_secure"; /** @description If present, this is the URL that you should send the cardholder to for authentication. If you are going to use Stripe.js to display the authentication page in an iframe, you should use the value "_callback". */ redirect_url?: string | null; @@ -9821,7 +10532,10 @@ export interface components { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "token"; /** @description Type of the token: `account`, `bank_account`, `card`, or `pii`. */ type: string; @@ -9864,12 +10578,18 @@ export interface components { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "topup"; source: components["schemas"]["source"]; /** @description Extra information about a top-up. This will appear on your source's bank statement. It must contain at least one letter. */ statement_descriptor?: string | null; - /** @description The status of the top-up is either `canceled`, `failed`, `pending`, `reversed`, or `succeeded`. */ + /** + * @description The status of the top-up is either `canceled`, `failed`, `pending`, `reversed`, or `succeeded`. + * @enum {string} + */ status: "canceled" | "failed" | "pending" | "reversed" | "succeeded"; /** @description A string that identifies this top-up as part of a group. */ transfer_group?: string | null; @@ -9915,7 +10635,10 @@ export interface components { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "transfer"; /** * TransferReversalList @@ -9926,7 +10649,10 @@ export interface components { data: components["schemas"]["transfer_reversal"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -9991,7 +10717,10 @@ export interface components { id: string; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "transfer_reversal"; /** @description ID of the refund responsible for the transfer reversal. */ source_refund?: @@ -10015,7 +10744,10 @@ export interface components { transform_usage: { /** @description Divide usage by this number. */ divide_by: number; - /** @description After division, either round the result `up` or `down`. */ + /** + * @description After division, either round the result `up` or `down`. + * @enum {string} + */ round: "down" | "up"; } & { [key: string]: unknown }; /** @@ -10030,7 +10762,10 @@ export interface components { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "usage_record"; /** @description The usage quantity for the specified date. */ quantity: number; @@ -10050,7 +10785,10 @@ export interface components { invoice?: string | null; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "usage_record_summary"; period: components["schemas"]["period"]; /** @description The ID of the subscription item this summary is describing. */ @@ -10088,7 +10826,10 @@ export interface components { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "webhook_endpoint"; /** @description The endpoint's secret, used to generate [webhook signatures](https://stripe.com/docs/webhooks/signatures). Only returned at creation. */ secret?: string; @@ -10224,10 +10965,12 @@ export interface operations { bank_account?: (Partial< { account_holder_name?: string; + /** @enum {string} */ account_holder_type?: "company" | "individual"; account_number: string; country: string; currency?: string; + /** @enum {string} */ object?: "bank_account"; routing_number?: string; } & { [key: string]: unknown } @@ -10246,7 +10989,10 @@ export interface operations { support_url?: string; url?: string; } & { [key: string]: unknown }; - /** @description The business type. */ + /** + * @description The business type. + * @enum {string} + */ business_type?: "company" | "government_entity" | "individual" | "non_profit"; /** * company_specs @@ -10289,6 +11035,7 @@ export interface operations { name_kanji?: string; owners_provided?: boolean; phone?: string; + /** @enum {string} */ structure?: | "" | "government_instrumentality" @@ -10440,8 +11187,10 @@ export interface operations { /** transfer_schedule_specs */ schedule?: { delay_days?: (Partial<"minimum"> & Partial) & { [key: string]: unknown }; + /** @enum {string} */ interval?: "daily" | "manual" | "monthly" | "weekly"; monthly_anchor?: number; + /** @enum {string} */ weekly_anchor?: "friday" | "monday" | "saturday" | "sunday" | "thursday" | "tuesday" | "wednesday"; } & { [key: string]: unknown }; statement_descriptor?: string; @@ -10514,10 +11263,12 @@ export interface operations { bank_account?: (Partial< { account_holder_name?: string; + /** @enum {string} */ account_holder_type?: "company" | "individual"; account_number: string; country: string; currency?: string; + /** @enum {string} */ object?: "bank_account"; routing_number?: string; } & { [key: string]: unknown } @@ -10595,7 +11346,10 @@ export interface operations { "application/x-www-form-urlencoded": { /** @description The name of the person or business that owns the bank account. */ account_holder_name?: string; - /** @description The type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description The type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string} + */ account_holder_type?: "" | "company" | "individual"; /** @description City/District/Suburb/Town/Village. */ address_city?: string; @@ -10668,7 +11422,10 @@ export interface operations { data: components["schemas"]["capability"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -10776,7 +11533,10 @@ export interface operations { })[]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -10819,10 +11579,12 @@ export interface operations { bank_account?: (Partial< { account_holder_name?: string; + /** @enum {string} */ account_holder_type?: "company" | "individual"; account_number: string; country: string; currency?: string; + /** @enum {string} */ object?: "bank_account"; routing_number?: string; } & { [key: string]: unknown } @@ -10900,7 +11662,10 @@ export interface operations { "application/x-www-form-urlencoded": { /** @description The name of the person or business that owns the bank account. */ account_holder_name?: string; - /** @description The type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description The type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string} + */ account_holder_type?: "" | "company" | "individual"; /** @description City/District/Suburb/Town/Village. */ address_city?: string; @@ -11048,7 +11813,10 @@ export interface operations { data: components["schemas"]["person"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -11418,7 +12186,10 @@ export interface operations { data: components["schemas"]["person"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -11780,7 +12551,10 @@ export interface operations { "application/x-www-form-urlencoded": { /** @description The identifier of the account to create an account link for. */ account: string; - /** @description Which information the platform needs to collect from the user. One of `currently_due` or `eventually_due`. Default is `currently_due`. */ + /** + * @description Which information the platform needs to collect from the user. One of `currently_due` or `eventually_due`. Default is `currently_due`. + * @enum {string} + */ collect?: "currently_due" | "eventually_due"; /** @description Specifies which fields in the response should be expanded. */ expand?: string[]; @@ -11788,7 +12562,10 @@ export interface operations { failure_url: string; /** @description The URL that the user will be redirected to upon leaving or completing the linked flow successfully. */ success_url: string; - /** @description The type of account link the user is requesting. Possible values are `custom_account_verification` or `custom_account_update`. */ + /** + * @description The type of account link the user is requesting. Possible values are `custom_account_verification` or `custom_account_update`. + * @enum {string} + */ type: "custom_account_update" | "custom_account_verification"; }; }; @@ -11825,7 +12602,10 @@ export interface operations { data: components["schemas"]["account"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -11876,10 +12656,12 @@ export interface operations { bank_account?: (Partial< { account_holder_name?: string; + /** @enum {string} */ account_holder_type?: "company" | "individual"; account_number: string; country: string; currency?: string; + /** @enum {string} */ object?: "bank_account"; routing_number?: string; } & { [key: string]: unknown } @@ -11898,7 +12680,10 @@ export interface operations { support_url?: string; url?: string; } & { [key: string]: unknown }; - /** @description The business type. */ + /** + * @description The business type. + * @enum {string} + */ business_type?: "company" | "government_entity" | "individual" | "non_profit"; /** * company_specs @@ -11941,6 +12726,7 @@ export interface operations { name_kanji?: string; owners_provided?: boolean; phone?: string; + /** @enum {string} */ structure?: | "" | "government_instrumentality" @@ -12094,8 +12880,10 @@ export interface operations { /** transfer_schedule_specs */ schedule?: { delay_days?: (Partial<"minimum"> & Partial) & { [key: string]: unknown }; + /** @enum {string} */ interval?: "daily" | "manual" | "monthly" | "weekly"; monthly_anchor?: number; + /** @enum {string} */ weekly_anchor?: "friday" | "monday" | "saturday" | "sunday" | "thursday" | "tuesday" | "wednesday"; } & { [key: string]: unknown }; statement_descriptor?: string; @@ -12111,7 +12899,10 @@ export interface operations { ip?: string; user_agent?: string; } & { [key: string]: unknown }; - /** @description The type of Stripe account to create. Currently must be `custom`, as only [Custom accounts](https://stripe.com/docs/connect/custom-accounts) may be created via the API. */ + /** + * @description The type of Stripe account to create. Currently must be `custom`, as only [Custom accounts](https://stripe.com/docs/connect/custom-accounts) may be created via the API. + * @enum {string} + */ type?: "custom" | "express" | "standard"; }; }; @@ -12182,10 +12973,12 @@ export interface operations { bank_account?: (Partial< { account_holder_name?: string; + /** @enum {string} */ account_holder_type?: "company" | "individual"; account_number: string; country: string; currency?: string; + /** @enum {string} */ object?: "bank_account"; routing_number?: string; } & { [key: string]: unknown } @@ -12204,7 +12997,10 @@ export interface operations { support_url?: string; url?: string; } & { [key: string]: unknown }; - /** @description The business type. */ + /** + * @description The business type. + * @enum {string} + */ business_type?: "company" | "government_entity" | "individual" | "non_profit"; /** * company_specs @@ -12247,6 +13043,7 @@ export interface operations { name_kanji?: string; owners_provided?: boolean; phone?: string; + /** @enum {string} */ structure?: | "" | "government_instrumentality" @@ -12398,8 +13195,10 @@ export interface operations { /** transfer_schedule_specs */ schedule?: { delay_days?: (Partial<"minimum"> & Partial) & { [key: string]: unknown }; + /** @enum {string} */ interval?: "daily" | "manual" | "monthly" | "weekly"; monthly_anchor?: number; + /** @enum {string} */ weekly_anchor?: "friday" | "monday" | "saturday" | "sunday" | "thursday" | "tuesday" | "wednesday"; } & { [key: string]: unknown }; statement_descriptor?: string; @@ -12480,10 +13279,12 @@ export interface operations { bank_account?: (Partial< { account_holder_name?: string; + /** @enum {string} */ account_holder_type?: "company" | "individual"; account_number: string; country: string; currency?: string; + /** @enum {string} */ object?: "bank_account"; routing_number?: string; } & { [key: string]: unknown } @@ -12563,7 +13364,10 @@ export interface operations { "application/x-www-form-urlencoded": { /** @description The name of the person or business that owns the bank account. */ account_holder_name?: string; - /** @description The type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description The type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string} + */ account_holder_type?: "" | "company" | "individual"; /** @description City/District/Suburb/Town/Village. */ address_city?: string; @@ -12640,7 +13444,10 @@ export interface operations { data: components["schemas"]["capability"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -12753,7 +13560,10 @@ export interface operations { })[]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -12801,10 +13611,12 @@ export interface operations { bank_account?: (Partial< { account_holder_name?: string; + /** @enum {string} */ account_holder_type?: "company" | "individual"; account_number: string; country: string; currency?: string; + /** @enum {string} */ object?: "bank_account"; routing_number?: string; } & { [key: string]: unknown } @@ -12884,7 +13696,10 @@ export interface operations { "application/x-www-form-urlencoded": { /** @description The name of the person or business that owns the bank account. */ account_holder_name?: string; - /** @description The type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description The type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string} + */ account_holder_type?: "" | "company" | "individual"; /** @description City/District/Suburb/Town/Village. */ address_city?: string; @@ -13044,7 +13859,10 @@ export interface operations { data: components["schemas"]["person"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -13423,7 +14241,10 @@ export interface operations { data: components["schemas"]["person"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -13829,7 +14650,10 @@ export interface operations { data: components["schemas"]["apple_pay_domain"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -13966,7 +14790,10 @@ export interface operations { data: components["schemas"]["application_fee"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -14143,7 +14970,10 @@ export interface operations { data: components["schemas"]["fee_refund"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -14290,7 +15120,10 @@ export interface operations { data: components["schemas"]["balance_transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -14397,7 +15230,10 @@ export interface operations { data: components["schemas"]["balance_transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -14509,7 +15345,10 @@ export interface operations { data: components["schemas"]["bitcoin_receiver"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -14588,7 +15427,10 @@ export interface operations { data: components["schemas"]["bitcoin_transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -14634,7 +15476,10 @@ export interface operations { data: components["schemas"]["bitcoin_transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -14691,7 +15536,10 @@ export interface operations { data: components["schemas"]["charge"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -14752,6 +15600,7 @@ export interface operations { metadata?: { [key: string]: string }; name?: string; number: string; + /** @enum {string} */ object?: "card"; } & { [key: string]: unknown } > & @@ -14882,6 +15731,7 @@ export interface operations { * @description A set of key-value pairs you can attach to a charge giving information about its riskiness. If you believe a charge is fraudulent, include a `user_report` key with a value of `fraudulent`. If you believe a charge is safe, include a `user_report` key with a value of `safe`. Stripe will use the information you send to improve our fraud detection algorithms. */ fraud_details?: { + /** @enum {string} */ user_report: "" | "fraudulent" | "safe"; } & { [key: string]: unknown }; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ @@ -15136,6 +15986,7 @@ export interface operations { /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ metadata?: (Partial<{ [key: string]: string }> & Partial<"">) & { [key: string]: unknown }; payment_intent?: string; + /** @enum {string} */ reason?: "duplicate" | "fraudulent" | "requested_by_customer"; refund_application_fee?: boolean; reverse_transfer?: boolean; @@ -15169,7 +16020,10 @@ export interface operations { data: components["schemas"]["refund"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -15219,6 +16073,7 @@ export interface operations { /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ metadata?: (Partial<{ [key: string]: string }> & Partial<"">) & { [key: string]: unknown }; payment_intent?: string; + /** @enum {string} */ reason?: "duplicate" | "fraudulent" | "requested_by_customer"; refund_application_fee?: boolean; reverse_transfer?: boolean; @@ -15316,7 +16171,10 @@ export interface operations { data: components["schemas"]["checkout.session"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -15355,7 +16213,10 @@ export interface operations { requestBody: { content: { "application/x-www-form-urlencoded": { - /** @description Specify whether Checkout should collect the customer's billing address. */ + /** + * @description Specify whether Checkout should collect the customer's billing address. + * @enum {string} + */ billing_address_collection?: "auto" | "required"; /** @description The URL the customer will be directed to if they decide to cancel payment and return to your website. */ cancel_url: string; @@ -15399,7 +16260,10 @@ export interface operations { quantity: number; tax_rates?: string[]; } & { [key: string]: unknown })[]; - /** @description The IETF language tag of the locale Checkout is displayed in. If blank or `auto`, the browser's locale is used. */ + /** + * @description The IETF language tag of the locale Checkout is displayed in. If blank or `auto`, the browser's locale is used. + * @enum {string} + */ locale?: | "auto" | "da" @@ -15420,7 +16284,10 @@ export interface operations { | "zh"; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ metadata?: { [key: string]: string }; - /** @description The mode of the Checkout Session, one of `payment`, `setup`, or `subscription`. */ + /** + * @description The mode of the Checkout Session, one of `payment`, `setup`, or `subscription`. + * @enum {string} + */ mode?: "payment" | "setup" | "subscription"; /** * payment_intent_data_params @@ -15428,11 +16295,13 @@ export interface operations { */ payment_intent_data?: { application_fee_amount?: number; + /** @enum {string} */ capture_method?: "automatic" | "manual"; description?: string; metadata?: { [key: string]: string }; on_behalf_of?: string; receipt_email?: string; + /** @enum {string} */ setup_future_usage?: "off_session" | "on_session"; /** shipping */ shipping?: { @@ -15719,6 +16588,7 @@ export interface operations { * relevant text on the page, such as the submit button. `submit_type` can only be * specified on Checkout Sessions in `payment` mode, but not Checkout Sessions * in `subscription` or `setup` mode. + * @enum {string} */ submit_type?: "auto" | "book" | "donate" | "pay"; /** @@ -15804,7 +16674,10 @@ export interface operations { data: components["schemas"]["country_spec"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -15887,7 +16760,10 @@ export interface operations { data: components["schemas"]["coupon"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -15934,7 +16810,10 @@ export interface operations { amount_off?: number; /** @description Three-letter [ISO code for the currency](https://stripe.com/docs/currencies) of the `amount_off` parameter (required if `amount_off` is passed). */ currency?: string; - /** @description Specifies how long the discount will be in effect. Can be `forever`, `once`, or `repeating`. */ + /** + * @description Specifies how long the discount will be in effect. Can be `forever`, `once`, or `repeating`. + * @enum {string} + */ duration: "forever" | "once" | "repeating"; /** @description Required only if `duration` is `repeating`, in which case it must be a positive integer that specifies the number of months the discount will be in effect. */ duration_in_months?: number; @@ -16077,7 +16956,10 @@ export interface operations { data: components["schemas"]["credit_note"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -16146,6 +17028,7 @@ export interface operations { invoice_line_item?: string; quantity?: number; tax_rates?: (Partial & Partial<"">) & { [key: string]: unknown }; + /** @enum {string} */ type: "custom_line_item" | "invoice_line_item"; unit_amount?: number; /** Format: decimal */ @@ -16157,7 +17040,10 @@ export interface operations { metadata?: { [key: string]: string }; /** @description The integer amount in **%s** representing the amount that is credited outside of Stripe. */ out_of_band_amount?: number; - /** @description Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory` */ + /** + * @description Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory` + * @enum {string} + */ reason?: "duplicate" | "fraudulent" | "order_change" | "product_unsatisfactory"; /** @description ID of an existing refund to link this credit note to. */ refund?: string; @@ -16186,6 +17072,7 @@ export interface operations { invoice_line_item?: string; quantity?: number; tax_rates?: (Partial & Partial<"">) & { [key: string]: unknown }; + /** @enum {string} */ type: "custom_line_item" | "invoice_line_item"; unit_amount?: number; /** Format: decimal */ @@ -16248,6 +17135,7 @@ export interface operations { invoice_line_item?: string; quantity?: number; tax_rates?: (Partial & Partial<"">) & { [key: string]: unknown }; + /** @enum {string} */ type: "custom_line_item" | "invoice_line_item"; unit_amount?: number; /** Format: decimal */ @@ -16278,7 +17166,10 @@ export interface operations { data: components["schemas"]["credit_note_line_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -16324,7 +17215,10 @@ export interface operations { data: components["schemas"]["credit_note_line_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -16472,7 +17366,10 @@ export interface operations { data: components["schemas"]["customer"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -16578,10 +17475,14 @@ export interface operations { > & Partial<"">) & { [key: string]: unknown }; source?: string; - /** @description The customer's tax exemption. One of `none`, `exempt`, or `reverse`. */ + /** + * @description The customer's tax exemption. One of `none`, `exempt`, or `reverse`. + * @enum {string} + */ tax_exempt?: "" | "exempt" | "none" | "reverse"; /** @description The customer's tax IDs. */ tax_id_data?: ({ + /** @enum {string} */ type: | "au_abn" | "ca_bn" @@ -16690,10 +17591,12 @@ export interface operations { bank_account?: (Partial< { account_holder_name?: string; + /** @enum {string} */ account_holder_type?: "company" | "individual"; account_number: string; country: string; currency?: string; + /** @enum {string} */ object?: "bank_account"; routing_number?: string; } & { [key: string]: unknown } @@ -16714,6 +17617,7 @@ export interface operations { metadata?: { [key: string]: string }; name?: string; number: string; + /** @enum {string} */ object?: "card"; } & { [key: string]: unknown } > & @@ -16784,7 +17688,10 @@ export interface operations { > & Partial<"">) & { [key: string]: unknown }; source?: string; - /** @description The customer's tax exemption. One of `none`, `exempt`, or `reverse`. */ + /** + * @description The customer's tax exemption. One of `none`, `exempt`, or `reverse`. + * @enum {string} + */ tax_exempt?: "" | "exempt" | "none" | "reverse"; /** @description Unix timestamp representing the end of the trial period the customer will get before being charged for the first time. This will always overwrite any trials that might apply via a subscribed plan. If set, trial_end will override the default trial period of the plan the customer is being subscribed to. The special value `now` can be provided to end the customer's trial immediately. Can be at most two years from `billing_cycle_anchor`. */ trial_end?: (Partial<"now"> & Partial) & { [key: string]: unknown }; @@ -16845,7 +17752,10 @@ export interface operations { data: components["schemas"]["customer_balance_transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -16996,7 +17906,10 @@ export interface operations { data: components["schemas"]["bank_account"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -17052,10 +17965,12 @@ export interface operations { bank_account?: (Partial< { account_holder_name?: string; + /** @enum {string} */ account_holder_type?: "company" | "individual"; account_number: string; country: string; currency?: string; + /** @enum {string} */ object?: "bank_account"; routing_number?: string; } & { [key: string]: unknown } @@ -17076,6 +17991,7 @@ export interface operations { metadata?: { [key: string]: string }; name?: string; number: string; + /** @enum {string} */ object?: "card"; } & { [key: string]: unknown } > & @@ -17151,7 +18067,10 @@ export interface operations { "application/x-www-form-urlencoded": { /** @description The name of the person or business that owns the bank account. */ account_holder_name?: string; - /** @description The type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description The type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string} + */ account_holder_type?: "company" | "individual"; /** @description City/District/Suburb/Town/Village. */ address_city?: string; @@ -17288,7 +18207,10 @@ export interface operations { data: components["schemas"]["card"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -17344,10 +18266,12 @@ export interface operations { bank_account?: (Partial< { account_holder_name?: string; + /** @enum {string} */ account_holder_type?: "company" | "individual"; account_number: string; country: string; currency?: string; + /** @enum {string} */ object?: "bank_account"; routing_number?: string; } & { [key: string]: unknown } @@ -17368,6 +18292,7 @@ export interface operations { metadata?: { [key: string]: string }; name?: string; number: string; + /** @enum {string} */ object?: "card"; } & { [key: string]: unknown } > & @@ -17443,7 +18368,10 @@ export interface operations { "application/x-www-form-urlencoded": { /** @description The name of the person or business that owns the bank account. */ account_holder_name?: string; - /** @description The type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description The type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string} + */ account_holder_type?: "company" | "individual"; /** @description City/District/Suburb/Town/Village. */ address_city?: string; @@ -17607,7 +18535,10 @@ export interface operations { Partial) & { [key: string]: unknown })[]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -17663,10 +18594,12 @@ export interface operations { bank_account?: (Partial< { account_holder_name?: string; + /** @enum {string} */ account_holder_type?: "company" | "individual"; account_number: string; country: string; currency?: string; + /** @enum {string} */ object?: "bank_account"; routing_number?: string; } & { [key: string]: unknown } @@ -17687,6 +18620,7 @@ export interface operations { metadata?: { [key: string]: string }; name?: string; number: string; + /** @enum {string} */ object?: "card"; } & { [key: string]: unknown } > & @@ -17762,7 +18696,10 @@ export interface operations { "application/x-www-form-urlencoded": { /** @description The name of the person or business that owns the bank account. */ account_holder_name?: string; - /** @description The type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description The type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string} + */ account_holder_type?: "company" | "individual"; /** @description City/District/Suburb/Town/Village. */ address_city?: string; @@ -17896,7 +18833,10 @@ export interface operations { data: components["schemas"]["subscription"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -17967,7 +18907,10 @@ export interface operations { cancel_at?: number; /** @description Boolean indicating whether this subscription should cancel at the end of the current period. */ cancel_at_period_end?: boolean; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. + * @enum {string} + */ collection_method?: "charge_automatically" | "send_invoice"; /** @description The code of the coupon to apply to this subscription. A coupon applied to a subscription will only affect invoices created for that particular subscription. */ coupon?: string; @@ -18004,11 +18947,13 @@ export interface operations { * Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not create a subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more. * * `pending_if_incomplete` is only used with updates and cannot be passed when creating a subscription. + * @enum {string} */ payment_behavior?: "allow_incomplete" | "error_if_incomplete" | "pending_if_incomplete"; /** @description Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval. */ pending_invoice_item_interval?: (Partial< { + /** @enum {string} */ interval: "day" | "month" | "week" | "year"; interval_count?: number; } & { [key: string]: unknown } @@ -18020,6 +18965,7 @@ export interface operations { * @description Determines how to handle [prorations](https://stripe.com/docs/subscriptions/billing-cycle#prorations) resulting from the `billing_cycle_anchor`. Valid values are `create_prorations` or `none`. * * Passing `create_prorations` will cause proration invoice items to be created when applicable. Prorations can be disabled by passing `none`. If no value is passed, the default is `create_prorations`. + * @enum {string} */ proration_behavior?: "always_invoice" | "create_prorations" | "none"; /** @description A non-negative decimal (with at most four decimal places) between 0 and 100. This represents the percentage of the subscription invoice subtotal that will be calculated and added as tax to the final amount in each billing period. For example, a plan which charges $10/month with a `tax_percent` of `20.0` will charge $12 per invoice. To unset a previously-set value, pass an empty string. This field has been deprecated and will be removed in a future API version, for further information view the [migration docs](https://stripe.com/docs/billing/migration/taxes) for `tax_rates`. */ @@ -18093,7 +19039,10 @@ export interface operations { "application/x-www-form-urlencoded": { /** @description A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice subtotal that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions). */ application_fee_percent?: number; - /** @description Either `now` or `unchanged`. Setting the value to `now` resets the subscription's billing cycle anchor to the current time. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle). */ + /** + * @description Either `now` or `unchanged`. Setting the value to `now` resets the subscription's billing cycle anchor to the current time. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle). + * @enum {string} + */ billing_cycle_anchor?: "now" | "unchanged"; /** @description Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds. */ billing_thresholds?: (Partial< @@ -18107,7 +19056,10 @@ export interface operations { cancel_at?: (Partial & Partial<"">) & { [key: string]: unknown }; /** @description Boolean indicating whether this subscription should cancel at the end of the current period. */ cancel_at_period_end?: boolean; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. + * @enum {string} + */ collection_method?: "charge_automatically" | "send_invoice"; /** @description The code of the coupon to apply to this subscription. A coupon applied to a subscription will only affect invoices created for that particular subscription. */ coupon?: string; @@ -18144,6 +19096,7 @@ export interface operations { /** @description If specified, payment collection for this subscription will be paused. */ pause_collection?: (Partial< { + /** @enum {string} */ behavior: "keep_as_draft" | "mark_uncollectible" | "void"; /** Format: unix-time */ resumes_at?: number; @@ -18156,11 +19109,13 @@ export interface operations { * Use `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes). * * Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not create a subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more. + * @enum {string} */ payment_behavior?: "allow_incomplete" | "error_if_incomplete" | "pending_if_incomplete"; /** @description Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval. */ pending_invoice_item_interval?: (Partial< { + /** @enum {string} */ interval: "day" | "month" | "week" | "year"; interval_count?: number; } & { [key: string]: unknown } @@ -18174,6 +19129,7 @@ export interface operations { * Passing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`. * * Prorations can be disabled by passing `none`. + * @enum {string} */ proration_behavior?: "always_invoice" | "create_prorations" | "none"; /** @@ -18317,7 +19273,10 @@ export interface operations { data: components["schemas"]["tax_id"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -18363,7 +19322,10 @@ export interface operations { "application/x-www-form-urlencoded": { /** @description Specifies which fields in the response should be expanded. */ expand?: string[]; - /** @description Type of the tax ID, one of `eu_vat`, `nz_gst`, `au_abn`, `in_gst`, `no_vat`, `za_vat`, `ch_vat`, `mx_rfc`, `sg_uen`, `ru_inn`, `ca_bn`, `hk_br`, `es_cif`, `tw_vat`, `th_vat`, `jp_cn`, `li_uid`, `my_itn`, `us_ein`, `kr_brn`, `ca_qst`, `my_sst`, or `sg_gst` */ + /** + * @description Type of the tax ID, one of `eu_vat`, `nz_gst`, `au_abn`, `in_gst`, `no_vat`, `za_vat`, `ch_vat`, `mx_rfc`, `sg_uen`, `ru_inn`, `ca_bn`, `hk_br`, `es_cif`, `tw_vat`, `th_vat`, `jp_cn`, `li_uid`, `my_itn`, `us_ein`, `kr_brn`, `ca_qst`, `my_sst`, or `sg_gst` + * @enum {string} + */ type: | "au_abn" | "ca_bn" @@ -18489,7 +19451,10 @@ export interface operations { data: components["schemas"]["dispute"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -18741,7 +19706,10 @@ export interface operations { data: components["schemas"]["event"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -18814,7 +19782,10 @@ export interface operations { data: components["schemas"]["exchange_rate"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -18900,7 +19871,10 @@ export interface operations { data: components["schemas"]["file_link"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -19062,7 +20036,10 @@ export interface operations { data: components["schemas"]["file"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -19119,7 +20096,10 @@ export interface operations { expires_at?: number; metadata?: (Partial<{ [key: string]: string }> & Partial<"">) & { [key: string]: unknown }; } & { [key: string]: unknown }; - /** @description The purpose of the uploaded file. Possible values are `additional_verification`, `business_icon`, `business_logo`, `customer_signature`, `dispute_evidence`, `identity_document`, `pci_document`, or `tax_document_user_upload`. */ + /** + * @description The purpose of the uploaded file. Possible values are `additional_verification`, `business_icon`, `business_logo`, `customer_signature`, `dispute_evidence`, `identity_document`, `pci_document`, or `tax_document_user_upload`. + * @enum {string} + */ purpose: | "additional_verification" | "business_icon" @@ -19201,7 +20181,10 @@ export interface operations { data: components["schemas"]["invoiceitem"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -19448,7 +20431,10 @@ export interface operations { data: components["schemas"]["invoice"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -19491,7 +20477,10 @@ export interface operations { application_fee_amount?: number; /** @description Controls whether Stripe will perform [automatic collection](https://stripe.com/docs/billing/invoices/workflow/#auto_advance) of the invoice. When `false`, the invoice's state will not automatically advance without an explicit action. */ auto_advance?: boolean; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this invoice using the default source attached to the customer. When sending an invoice, Stripe will email this invoice to the customer with payment instructions. Defaults to `charge_automatically`. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this invoice using the default source attached to the customer. When sending an invoice, Stripe will email this invoice to the customer with payment instructions. Defaults to `charge_automatically`. + * @enum {string} + */ collection_method?: "charge_automatically" | "send_invoice"; /** @description A list of up to 4 custom fields to be displayed on the invoice. */ custom_fields?: (Partial< @@ -19745,7 +20734,10 @@ export interface operations { data: components["schemas"]["line_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -19831,7 +20823,10 @@ export interface operations { application_fee_amount?: number; /** @description Controls whether Stripe will perform [automatic collection](https://stripe.com/docs/billing/invoices/workflow/#auto_advance) of the invoice. */ auto_advance?: boolean; - /** @description Either `charge_automatically` or `send_invoice`. This field can be updated only on `draft` invoices. */ + /** + * @description Either `charge_automatically` or `send_invoice`. This field can be updated only on `draft` invoices. + * @enum {string} + */ collection_method?: "charge_automatically" | "send_invoice"; /** @description A list of up to 4 custom fields to be displayed on the invoice. If a value for `custom_fields` is specified, the list specified will replace the existing custom field list on this invoice. Pass an empty string to remove previously-defined fields. */ custom_fields?: (Partial< @@ -19955,7 +20950,10 @@ export interface operations { data: components["schemas"]["line_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -20137,7 +21135,10 @@ export interface operations { data: components["schemas"]["issuer_fraud_record"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -20230,7 +21231,10 @@ export interface operations { data: components["schemas"]["issuing.authorization"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -20419,7 +21423,10 @@ export interface operations { data: components["schemas"]["issuing.cardholder"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -21389,13 +22396,20 @@ export interface operations { | "womens_ready_to_wear_stores" | "wrecking_and_salvage_yards" )[]; + /** @enum {string} */ interval: "all_time" | "daily" | "monthly" | "per_authorization" | "weekly" | "yearly"; } & { [key: string]: unknown })[]; spending_limits_currency?: string; } & { [key: string]: unknown }; - /** @description Specifies whether to permit authorizations on this cardholder's cards. Defaults to `active`. */ + /** + * @description Specifies whether to permit authorizations on this cardholder's cards. Defaults to `active`. + * @enum {string} + */ status?: "active" | "inactive"; - /** @description One of `individual` or `company`. */ + /** + * @description One of `individual` or `company`. + * @enum {string} + */ type: "company" | "individual"; }; }; @@ -22385,11 +23399,15 @@ export interface operations { | "womens_ready_to_wear_stores" | "wrecking_and_salvage_yards" )[]; + /** @enum {string} */ interval: "all_time" | "daily" | "monthly" | "per_authorization" | "weekly" | "yearly"; } & { [key: string]: unknown })[]; spending_limits_currency?: string; } & { [key: string]: unknown }; - /** @description Specifies whether to permit authorizations on this cardholder's cards. */ + /** + * @description Specifies whether to permit authorizations on this cardholder's cards. + * @enum {string} + */ status?: "active" | "inactive"; }; }; @@ -22439,7 +23457,10 @@ export interface operations { data: components["schemas"]["issuing.card"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -22488,7 +23509,10 @@ export interface operations { metadata?: { [key: string]: string }; /** @description The card this is meant to be a replacement for (if any). */ replacement_for?: string; - /** @description If `replacement_for` is specified, this should indicate why that card is being replaced. */ + /** + * @description If `replacement_for` is specified, this should indicate why that card is being replaced. + * @enum {string} + */ replacement_reason?: "damaged" | "expired" | "lost" | "stolen"; /** * shipping_specs @@ -22505,7 +23529,9 @@ export interface operations { state?: string; } & { [key: string]: unknown }; name: string; + /** @enum {string} */ service?: "express" | "priority" | "standard"; + /** @enum {string} */ type?: "bulk" | "individual"; } & { [key: string]: unknown }; /** @@ -23385,12 +24411,19 @@ export interface operations { | "womens_ready_to_wear_stores" | "wrecking_and_salvage_yards" )[]; + /** @enum {string} */ interval: "all_time" | "daily" | "monthly" | "per_authorization" | "weekly" | "yearly"; } & { [key: string]: unknown })[]; } & { [key: string]: unknown }; - /** @description Whether authorizations can be approved on this card. Defaults to `inactive`. */ + /** + * @description Whether authorizations can be approved on this card. Defaults to `inactive`. + * @enum {string} + */ status?: "active" | "inactive"; - /** @description The type of card to issue. Possible values are `physical` or `virtual`. */ + /** + * @description The type of card to issue. Possible values are `physical` or `virtual`. + * @enum {string} + */ type: "physical" | "virtual"; }; }; @@ -23451,7 +24484,10 @@ export interface operations { requestBody: { content: { "application/x-www-form-urlencoded": { - /** @description Reason why the `status` of this card is `canceled`. */ + /** + * @description Reason why the `status` of this card is `canceled`. + * @enum {string} + */ cancellation_reason?: "lost" | "stolen"; /** @description Specifies which fields in the response should be expanded. */ expand?: string[]; @@ -24334,10 +25370,14 @@ export interface operations { | "womens_ready_to_wear_stores" | "wrecking_and_salvage_yards" )[]; + /** @enum {string} */ interval: "all_time" | "daily" | "monthly" | "per_authorization" | "weekly" | "yearly"; } & { [key: string]: unknown })[]; } & { [key: string]: unknown }; - /** @description Dictates whether authorizations can be approved on this card. If this card is being canceled because it was lost or stolen, this information should be provided as `cancellation_reason`. */ + /** + * @description Dictates whether authorizations can be approved on this card. If this card is being canceled because it was lost or stolen, this information should be provided as `cancellation_reason`. + * @enum {string} + */ status?: "active" | "canceled" | "inactive"; }; }; @@ -24365,7 +25405,10 @@ export interface operations { data: components["schemas"]["issuing.dispute"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -24507,7 +25550,10 @@ export interface operations { data: components["schemas"]["issuing.settlement"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -24626,7 +25672,10 @@ export interface operations { data: components["schemas"]["issuing.transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -24774,7 +25823,10 @@ export interface operations { data: components["schemas"]["order_return"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -24904,7 +25956,10 @@ export interface operations { data: components["schemas"]["order"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -24960,6 +26015,7 @@ export interface operations { description?: string; parent?: string; quantity?: number; + /** @enum {string} */ type?: "discount" | "shipping" | "sku" | "tax"; } & { [key: string]: unknown })[]; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ @@ -25056,7 +26112,10 @@ export interface operations { carrier: string; tracking_number: string; } & { [key: string]: unknown }; - /** @description Current order status. One of `created`, `paid`, `canceled`, `fulfilled`, or `returned`. More detail in the [Orders Guide](https://stripe.com/docs/orders/guide#understanding-order-statuses). */ + /** + * @description Current order status. One of `created`, `paid`, `canceled`, `fulfilled`, or `returned`. More detail in the [Orders Guide](https://stripe.com/docs/orders/guide#understanding-order-statuses). + * @enum {string} + */ status?: "canceled" | "created" | "fulfilled" | "paid" | "returned"; }; }; @@ -25135,6 +26194,7 @@ export interface operations { description?: string; parent?: string; quantity?: number; + /** @enum {string} */ type?: "discount" | "shipping" | "sku" | "tax"; } & { [key: string]: unknown })[] > & @@ -25177,7 +26237,10 @@ export interface operations { data: components["schemas"]["payment_intent"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -25235,10 +26298,14 @@ export interface operations { * more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts). */ application_fee_amount?: number; - /** @description Controls when the funds will be captured from the customer's account. */ + /** + * @description Controls when the funds will be captured from the customer's account. + * @enum {string} + */ capture_method?: "automatic" | "manual"; /** @description Set to `true` to attempt to [confirm](https://stripe.com/docs/api/payment_intents/confirm) this PaymentIntent immediately. This parameter defaults to `false`. When creating and confirming a PaymentIntent at the same time, parameters available in the [confirm](https://stripe.com/docs/api/payment_intents/confirm) API may also be provided. */ confirm?: boolean; + /** @enum {string} */ confirmation_method?: "automatic" | "manual"; /** @description Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). */ currency: string; @@ -25274,6 +26341,7 @@ export interface operations { ip_address: string; user_agent: string; } & { [key: string]: unknown }; + /** @enum {string} */ type: "offline" | "online"; } & { [key: string]: unknown }; } & { [key: string]: unknown }; @@ -25302,12 +26370,15 @@ export interface operations { plan?: (Partial< { count: number; + /** @enum {string} */ interval: "month"; + /** @enum {string} */ type: "fixed_count"; } & { [key: string]: unknown } > & Partial<"">) & { [key: string]: unknown }; } & { [key: string]: unknown }; + /** @enum {string} */ request_three_d_secure?: "any" | "automatic"; } & { [key: string]: unknown } > & @@ -25325,6 +26396,7 @@ export interface operations { * Providing this parameter will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any required actions from the user are complete. If no Customer was provided, the payment method can still be [attached](https://stripe.com/docs/api/payment_methods/attach) to a Customer after the transaction completes. * * When processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication). + * @enum {string} */ setup_future_usage?: "off_session" | "on_session"; /** @@ -25473,12 +26545,15 @@ export interface operations { plan?: (Partial< { count: number; + /** @enum {string} */ interval: "month"; + /** @enum {string} */ type: "fixed_count"; } & { [key: string]: unknown } > & Partial<"">) & { [key: string]: unknown }; } & { [key: string]: unknown }; + /** @enum {string} */ request_three_d_secure?: "any" | "automatic"; } & { [key: string]: unknown } > & @@ -25496,6 +26571,7 @@ export interface operations { * When processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication). * * If `setup_future_usage` is already set and you are performing a request using a publishable key, you may only update the value from `on_session` to `off_session`. + * @enum {string} */ setup_future_usage?: "" | "off_session" | "on_session"; /** @description Shipping information for this PaymentIntent. */ @@ -25562,7 +26638,10 @@ export interface operations { requestBody: { content: { "application/x-www-form-urlencoded": { - /** @description Reason for canceling this PaymentIntent. Possible values are `duplicate`, `fraudulent`, `requested_by_customer`, or `abandoned` */ + /** + * @description Reason for canceling this PaymentIntent. Possible values are `duplicate`, `fraudulent`, `requested_by_customer`, or `abandoned` + * @enum {string} + */ cancellation_reason?: "abandoned" | "duplicate" | "fraudulent" | "requested_by_customer"; /** @description Specifies which fields in the response should be expanded. */ expand?: string[]; @@ -25698,6 +26777,7 @@ export interface operations { ip_address: string; user_agent: string; } & { [key: string]: unknown }; + /** @enum {string} */ type: "offline" | "online"; } & { [key: string]: unknown }; } & { [key: string]: unknown } @@ -25711,6 +26791,7 @@ export interface operations { ip_address?: string; user_agent?: string; } & { [key: string]: unknown }; + /** @enum {string} */ type: "online"; } & { [key: string]: unknown }; } & { [key: string]: unknown } @@ -25732,12 +26813,15 @@ export interface operations { plan?: (Partial< { count: number; + /** @enum {string} */ interval: "month"; + /** @enum {string} */ type: "fixed_count"; } & { [key: string]: unknown } > & Partial<"">) & { [key: string]: unknown }; } & { [key: string]: unknown }; + /** @enum {string} */ request_three_d_secure?: "any" | "automatic"; } & { [key: string]: unknown } > & @@ -25761,6 +26845,7 @@ export interface operations { * When processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication). * * If `setup_future_usage` is already set and you are performing a request using a publishable key, you may only update the value from `on_session` to `off_session`. + * @enum {string} */ setup_future_usage?: "" | "off_session" | "on_session"; /** @description Shipping information for this PaymentIntent. */ @@ -25814,7 +26899,10 @@ export interface operations { data: components["schemas"]["payment_method"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -25902,6 +26990,7 @@ export interface operations { * @description If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method. */ fpx?: { + /** @enum {string} */ bank: | "affin_bank" | "alliance_bank" @@ -25929,6 +27018,7 @@ export interface operations { * @description If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method. */ ideal?: { + /** @enum {string} */ bank?: | "abn_amro" | "asn_bank" @@ -25954,7 +27044,10 @@ export interface operations { sepa_debit?: { iban: string; } & { [key: string]: unknown }; - /** @description The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type. Required unless `payment_method` is specified (see the [Cloning PaymentMethods](https://stripe.com/docs/payments/payment-methods/connect#cloning-payment-methods) guide) */ + /** + * @description The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type. Required unless `payment_method` is specified (see the [Cloning PaymentMethods](https://stripe.com/docs/payments/payment-methods/connect#cloning-payment-methods) guide) + * @enum {string} + */ type?: "au_becs_debit" | "card" | "fpx" | "ideal" | "sepa_debit"; }; }; @@ -26172,7 +27265,10 @@ export interface operations { data: components["schemas"]["payout"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -26229,9 +27325,15 @@ export interface operations { expand?: string[]; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ metadata?: { [key: string]: string }; - /** @description The method used to send this payout, which can be `standard` or `instant`. `instant` is only supported for payouts to debit cards. (See [Instant payouts for marketplaces for more information](https://stripe.com/blog/instant-payouts-for-marketplaces).) */ + /** + * @description The method used to send this payout, which can be `standard` or `instant`. `instant` is only supported for payouts to debit cards. (See [Instant payouts for marketplaces for more information](https://stripe.com/blog/instant-payouts-for-marketplaces).) + * @enum {string} + */ method?: "instant" | "standard"; - /** @description The balance type of your Stripe balance to draw this payout from. Balances for different payment sources are kept separately. You can find the amounts with the balances API. One of `bank_account`, `card`, or `fpx`. */ + /** + * @description The balance type of your Stripe balance to draw this payout from. Balances for different payment sources are kept separately. You can find the amounts with the balances API. One of `bank_account`, `card`, or `fpx`. + * @enum {string} + */ source_type?: "bank_account" | "card" | "fpx"; /** @description A string to be displayed on the recipient's bank or card statement. This may be at most 22 characters. Attempting to use a `statement_descriptor` longer than 22 characters will return an error. Note: Most banks will truncate this information and/or display it inconsistently. Some may not display it at all. */ statement_descriptor?: string; @@ -26368,7 +27470,10 @@ export interface operations { data: components["schemas"]["plan"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -26409,7 +27514,10 @@ export interface operations { "application/x-www-form-urlencoded": { /** @description Whether the plan is currently available for new subscriptions. Defaults to `true`. */ active?: boolean; - /** @description Specifies a usage aggregation strategy for plans of `usage_type=metered`. Allowed values are `sum` for summing up all usage during a period, `last_during_period` for using the last usage record reported within a period, `last_ever` for using the last usage record ever (across period bounds) or `max` which uses the usage record with the maximum reported usage during a period. Defaults to `sum`. */ + /** + * @description Specifies a usage aggregation strategy for plans of `usage_type=metered`. Allowed values are `sum` for summing up all usage during a period, `last_during_period` for using the last usage record reported within a period, `last_ever` for using the last usage record ever (across period bounds) or `max` which uses the usage record with the maximum reported usage during a period. Defaults to `sum`. + * @enum {string} + */ aggregate_usage?: "last_during_period" | "last_ever" | "max" | "sum"; /** @description A positive integer in %s (or 0 for a free plan) representing how much to charge on a recurring basis. */ amount?: number; @@ -26418,7 +27526,10 @@ export interface operations { * @description Same as `amount`, but accepts a decimal value with at most 12 decimal places. Only one of `amount` and `amount_decimal` can be set. */ amount_decimal?: string; - /** @description Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `amount`) will be charged per unit in `quantity` (for plans with `usage_type=licensed`), or per unit of total usage (for plans with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes. */ + /** + * @description Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `amount`) will be charged per unit in `quantity` (for plans with `usage_type=licensed`), or per unit of total usage (for plans with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes. + * @enum {string} + */ billing_scheme?: "per_unit" | "tiered"; /** @description Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). */ currency: string; @@ -26426,7 +27537,10 @@ export interface operations { expand?: string[]; /** @description An identifier randomly generated by Stripe. Used to identify this plan when subscribing a customer. You can optionally override this ID, but the ID must be unique across all plans in your Stripe account. You can, however, use the same plan ID in both live and test modes. */ id?: string; - /** @description Specifies billing frequency. Either `day`, `week`, `month` or `year`. */ + /** + * @description Specifies billing frequency. Either `day`, `week`, `month` or `year`. + * @enum {string} + */ interval: "day" | "month" | "week" | "year"; /** @description The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). */ interval_count?: number; @@ -26455,7 +27569,10 @@ export interface operations { unit_amount_decimal?: string; up_to: (Partial<"inf"> & Partial) & { [key: string]: unknown }; } & { [key: string]: unknown })[]; - /** @description Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price, in `graduated` tiering pricing can successively change as the quantity grows. */ + /** + * @description Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price, in `graduated` tiering pricing can successively change as the quantity grows. + * @enum {string} + */ tiers_mode?: "graduated" | "volume"; /** * transform_usage_param @@ -26463,11 +27580,15 @@ export interface operations { */ transform_usage?: { divide_by: number; + /** @enum {string} */ round: "down" | "up"; } & { [key: string]: unknown }; /** @description Default number of trial days when subscribing a customer to this plan using [`trial_from_plan=true`](https://stripe.com/docs/api#create_subscription-trial_from_plan). */ trial_period_days?: number; - /** @description Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`. */ + /** + * @description Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`. + * @enum {string} + */ usage_type?: "licensed" | "metered"; }; }; @@ -26613,7 +27734,10 @@ export interface operations { data: components["schemas"]["product"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -26691,7 +27815,10 @@ export interface operations { * It must contain at least one letter. */ statement_descriptor?: string; - /** @description The type of the product. Defaults to `service` if not explicitly specified, enabling use of this product with Subscriptions and Plans. Set this parameter to `good` to use this product with Orders and SKUs. On API versions before `2018-02-05`, this field defaults to `good` for compatibility reasons. */ + /** + * @description The type of the product. Defaults to `service` if not explicitly specified, enabling use of this product with Subscriptions and Plans. Set this parameter to `good` to use this product with Orders and SKUs. On API versions before `2018-02-05`, this field defaults to `good` for compatibility reasons. + * @enum {string} + */ type?: "good" | "service"; /** @description A label that represents units of this product in Stripe and on customers’ receipts and invoices. When set, this will be included in associated invoice line item descriptions. */ unit_label?: string; @@ -26852,7 +27979,10 @@ export interface operations { data: components["schemas"]["radar.early_fraud_warning"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -26942,7 +28072,10 @@ export interface operations { data: components["schemas"]["radar.value_list_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -27084,7 +28217,10 @@ export interface operations { data: components["schemas"]["radar.value_list"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -27127,7 +28263,10 @@ export interface operations { alias: string; /** @description Specifies which fields in the response should be expanded. */ expand?: string[]; - /** @description Type of the items in the value list. One of `card_fingerprint`, `card_bin`, `email`, `ip_address`, `country`, `string`, or `case_sensitive_string`. Use `string` if the item type is unknown or mixed. */ + /** + * @description Type of the items in the value list. One of `card_fingerprint`, `card_bin`, `email`, `ip_address`, `country`, `string`, or `case_sensitive_string`. Use `string` if the item type is unknown or mixed. + * @enum {string} + */ item_type?: | "card_bin" | "card_fingerprint" @@ -27272,7 +28411,10 @@ export interface operations { data: components["schemas"]["recipient"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -27482,7 +28624,10 @@ export interface operations { data: components["schemas"]["refund"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -27528,6 +28673,7 @@ export interface operations { /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ metadata?: (Partial<{ [key: string]: string }> & Partial<"">) & { [key: string]: unknown }; payment_intent?: string; + /** @enum {string} */ reason?: "duplicate" | "fraudulent" | "requested_by_customer"; refund_application_fee?: boolean; reverse_transfer?: boolean; @@ -27633,7 +28779,10 @@ export interface operations { data: components["schemas"]["reporting.report_run"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -27687,6 +28836,7 @@ export interface operations { /** Format: unix-time */ interval_start?: number; payout?: string; + /** @enum {string} */ reporting_category?: | "advance" | "advance_funding" @@ -27719,6 +28869,7 @@ export interface operations { | "topup_reversal" | "transfer" | "transfer_reversal"; + /** @enum {string} */ timezone?: | "Africa/Abidjan" | "Africa/Accra" @@ -28368,7 +29519,10 @@ export interface operations { data: components["schemas"]["reporting.report_type"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -28450,7 +29604,10 @@ export interface operations { data: components["schemas"]["review"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -28567,7 +29724,10 @@ export interface operations { data: components["schemas"]["setup_intent"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -28639,6 +29799,7 @@ export interface operations { ip_address: string; user_agent: string; } & { [key: string]: unknown }; + /** @enum {string} */ type: "offline" | "online"; } & { [key: string]: unknown }; } & { [key: string]: unknown }; @@ -28655,6 +29816,7 @@ export interface operations { payment_method_options?: { /** setup_intent_param */ card?: { + /** @enum {string} */ request_three_d_secure?: "any" | "automatic"; } & { [key: string]: unknown }; } & { [key: string]: unknown }; @@ -28670,7 +29832,10 @@ export interface operations { amount: number; currency: string; } & { [key: string]: unknown }; - /** @description Indicates how the payment method is intended to be used in the future. If not provided, this value defaults to `off_session`. */ + /** + * @description Indicates how the payment method is intended to be used in the future. If not provided, this value defaults to `off_session`. + * @enum {string} + */ usage?: "off_session" | "on_session"; }; }; @@ -28760,6 +29925,7 @@ export interface operations { payment_method_options?: { /** setup_intent_param */ card?: { + /** @enum {string} */ request_three_d_secure?: "any" | "automatic"; } & { [key: string]: unknown }; } & { [key: string]: unknown }; @@ -28797,7 +29963,10 @@ export interface operations { requestBody: { content: { "application/x-www-form-urlencoded": { - /** @description Reason for canceling this SetupIntent. Possible values are `abandoned`, `requested_by_customer`, or `duplicate` */ + /** + * @description Reason for canceling this SetupIntent. Possible values are `abandoned`, `requested_by_customer`, or `duplicate` + * @enum {string} + */ cancellation_reason?: "abandoned" | "duplicate" | "requested_by_customer"; /** @description Specifies which fields in the response should be expanded. */ expand?: string[]; @@ -28861,6 +30030,7 @@ export interface operations { ip_address: string; user_agent: string; } & { [key: string]: unknown }; + /** @enum {string} */ type: "offline" | "online"; } & { [key: string]: unknown }; } & { [key: string]: unknown } @@ -28874,6 +30044,7 @@ export interface operations { ip_address?: string; user_agent?: string; } & { [key: string]: unknown }; + /** @enum {string} */ type: "online"; } & { [key: string]: unknown }; } & { [key: string]: unknown } @@ -28887,6 +30058,7 @@ export interface operations { payment_method_options?: { /** setup_intent_param */ card?: { + /** @enum {string} */ request_three_d_secure?: "any" | "automatic"; } & { [key: string]: unknown }; } & { [key: string]: unknown }; @@ -28922,7 +30094,10 @@ export interface operations { data: components["schemas"]["scheduled_query_run"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -29005,7 +30180,10 @@ export interface operations { data: components["schemas"]["sku"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -29062,7 +30240,9 @@ export interface operations { */ inventory: { quantity?: number; + /** @enum {string} */ type?: "bucket" | "finite" | "infinite"; + /** @enum {string} */ value?: "" | "in_stock" | "limited" | "out_of_stock"; } & { [key: string]: unknown }; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ @@ -29161,7 +30341,9 @@ export interface operations { */ inventory?: { quantity?: number; + /** @enum {string} */ type?: "bucket" | "finite" | "infinite"; + /** @enum {string} */ value?: "" | "in_stock" | "limited" | "out_of_stock"; } & { [key: string]: unknown }; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ @@ -29238,7 +30420,10 @@ export interface operations { customer?: string; /** @description Specifies which fields in the response should be expanded. */ expand?: string[]; - /** @description The authentication `flow` of the source to create. `flow` is one of `redirect`, `receiver`, `code_verification`, `none`. It is generally inferred unless a type supports multiple flows. */ + /** + * @description The authentication `flow` of the source to create. `flow` is one of `redirect`, `receiver`, `code_verification`, `none`. It is generally inferred unless a type supports multiple flows. + * @enum {string} + */ flow?: "code_verification" | "none" | "receiver" | "redirect"; /** * mandate_params @@ -29261,13 +30446,17 @@ export interface operations { ip?: string; user_agent?: string; } & { [key: string]: unknown }; + /** @enum {string} */ status: "accepted" | "pending" | "refused" | "revoked"; + /** @enum {string} */ type?: "offline" | "online"; user_agent?: string; } & { [key: string]: unknown }; amount?: (Partial & Partial<"">) & { [key: string]: unknown }; currency?: string; + /** @enum {string} */ interval?: "one_time" | "scheduled" | "variable"; + /** @enum {string} */ notification_method?: "deprecated_none" | "email" | "manual" | "none" | "stripe_email"; } & { [key: string]: unknown }; metadata?: { [key: string]: string }; @@ -29296,6 +30485,7 @@ export interface operations { * @description Optional parameters for the receiver flow. Can be set only if the source is a receiver (`flow` is `receiver`). */ receiver?: { + /** @enum {string} */ refund_attributes_method?: "email" | "manual" | "none"; } & { [key: string]: unknown }; /** @@ -29316,6 +30506,7 @@ export interface operations { description?: string; parent?: string; quantity?: number; + /** @enum {string} */ type?: "discount" | "shipping" | "sku" | "tax"; } & { [key: string]: unknown })[]; /** order_shipping */ @@ -29341,6 +30532,7 @@ export interface operations { token?: string; /** @description The `type` of the source to create. Required unless `customer` and `original_source` are specified (see the [Cloning card Sources](https://stripe.com/docs/sources/connect#cloning-card-sources) guide) */ type?: string; + /** @enum {string} */ usage?: "reusable" | "single_use"; }; }; @@ -29432,13 +30624,17 @@ export interface operations { ip?: string; user_agent?: string; } & { [key: string]: unknown }; + /** @enum {string} */ status: "accepted" | "pending" | "refused" | "revoked"; + /** @enum {string} */ type?: "offline" | "online"; user_agent?: string; } & { [key: string]: unknown }; amount?: (Partial & Partial<"">) & { [key: string]: unknown }; currency?: string; + /** @enum {string} */ interval?: "one_time" | "scheduled" | "variable"; + /** @enum {string} */ notification_method?: "deprecated_none" | "email" | "manual" | "none" | "stripe_email"; } & { [key: string]: unknown }; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ @@ -29472,6 +30668,7 @@ export interface operations { description?: string; parent?: string; quantity?: number; + /** @enum {string} */ type?: "discount" | "shipping" | "sku" | "tax"; } & { [key: string]: unknown })[]; /** order_shipping */ @@ -29552,7 +30749,10 @@ export interface operations { data: components["schemas"]["source_transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -29660,7 +30860,10 @@ export interface operations { data: components["schemas"]["subscription_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -29716,6 +30919,7 @@ export interface operations { * Use `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes). * * Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not create a subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more. + * @enum {string} */ payment_behavior?: "allow_incomplete" | "error_if_incomplete" | "pending_if_incomplete"; /** @description The identifier of the plan to add to the subscription. */ @@ -29728,6 +30932,7 @@ export interface operations { * Passing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`. * * Prorations can be disabled by passing `none`. + * @enum {string} */ proration_behavior?: "always_invoice" | "create_prorations" | "none"; /** @@ -29819,6 +31024,7 @@ export interface operations { * Use `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes). * * Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not create a subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more. + * @enum {string} */ payment_behavior?: "allow_incomplete" | "error_if_incomplete" | "pending_if_incomplete"; /** @description The identifier of the new plan for this subscription item. */ @@ -29831,6 +31037,7 @@ export interface operations { * Passing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`. * * Prorations can be disabled by passing `none`. + * @enum {string} */ proration_behavior?: "always_invoice" | "create_prorations" | "none"; /** @@ -29880,6 +31087,7 @@ export interface operations { * Passing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`. * * Prorations can be disabled by passing `none`. + * @enum {string} */ proration_behavior?: "always_invoice" | "create_prorations" | "none"; /** @@ -29920,7 +31128,10 @@ export interface operations { data: components["schemas"]["usage_record_summary"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -29972,7 +31183,10 @@ export interface operations { requestBody: { content: { "application/x-www-form-urlencoded": { - /** @description Valid values are `increment` (default) or `set`. When using `increment` the specified `quantity` will be added to the usage at the specified timestamp. The `set` action will overwrite the usage quantity at that timestamp. If the subscription has [billing thresholds](https://stripe.com/docs/api/subscriptions/object#subscription_object-billing_thresholds), `increment` is the only allowed value. */ + /** + * @description Valid values are `increment` (default) or `set`. When using `increment` the specified `quantity` will be added to the usage at the specified timestamp. The `set` action will overwrite the usage quantity at that timestamp. If the subscription has [billing thresholds](https://stripe.com/docs/api/subscriptions/object#subscription_object-billing_thresholds), `increment` is the only allowed value. + * @enum {string} + */ action?: "increment" | "set"; /** @description Specifies which fields in the response should be expanded. */ expand?: string[]; @@ -30050,7 +31264,10 @@ export interface operations { data: components["schemas"]["subscription_schedule"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -30103,6 +31320,7 @@ export interface operations { } & { [key: string]: unknown } > & Partial<"">) & { [key: string]: unknown }; + /** @enum {string} */ collection_method?: "charge_automatically" | "send_invoice"; default_payment_method?: string; /** subscription_schedules_param */ @@ -30110,7 +31328,10 @@ export interface operations { days_until_due?: number; } & { [key: string]: unknown }; } & { [key: string]: unknown }; - /** @description Configures how the subscription schedule behaves when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running.`cancel` will end the subscription schedule and cancel the underlying subscription. */ + /** + * @description Configures how the subscription schedule behaves when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running.`cancel` will end the subscription schedule and cancel the underlying subscription. + * @enum {string} + */ end_behavior?: "cancel" | "none" | "release" | "renew"; /** @description Specifies which fields in the response should be expanded. */ expand?: string[]; @@ -30128,6 +31349,7 @@ export interface operations { } & { [key: string]: unknown } > & Partial<"">) & { [key: string]: unknown }; + /** @enum {string} */ collection_method?: "charge_automatically" | "send_invoice"; coupon?: string; default_payment_method?: string; @@ -30150,6 +31372,7 @@ export interface operations { quantity?: number; tax_rates?: (Partial & Partial<"">) & { [key: string]: unknown }; } & { [key: string]: unknown })[]; + /** @enum {string} */ proration_behavior?: "always_invoice" | "create_prorations" | "none"; tax_percent?: number; trial?: boolean; @@ -30229,6 +31452,7 @@ export interface operations { } & { [key: string]: unknown } > & Partial<"">) & { [key: string]: unknown }; + /** @enum {string} */ collection_method?: "charge_automatically" | "send_invoice"; default_payment_method?: string; /** subscription_schedules_param */ @@ -30236,7 +31460,10 @@ export interface operations { days_until_due?: number; } & { [key: string]: unknown }; } & { [key: string]: unknown }; - /** @description Configures how the subscription schedule behaves when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running.`cancel` will end the subscription schedule and cancel the underlying subscription. */ + /** + * @description Configures how the subscription schedule behaves when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running.`cancel` will end the subscription schedule and cancel the underlying subscription. + * @enum {string} + */ end_behavior?: "cancel" | "none" | "release" | "renew"; /** @description Specifies which fields in the response should be expanded. */ expand?: string[]; @@ -30252,6 +31479,7 @@ export interface operations { } & { [key: string]: unknown } > & Partial<"">) & { [key: string]: unknown }; + /** @enum {string} */ collection_method?: "charge_automatically" | "send_invoice"; coupon?: string; default_payment_method?: string; @@ -30273,6 +31501,7 @@ export interface operations { quantity?: number; tax_rates?: (Partial & Partial<"">) & { [key: string]: unknown }; } & { [key: string]: unknown })[]; + /** @enum {string} */ proration_behavior?: "always_invoice" | "create_prorations" | "none"; start_date?: (Partial & Partial<"now">) & { [key: string]: unknown }; tax_percent?: number; @@ -30281,7 +31510,10 @@ export interface operations { } & { [key: string]: unknown })[]; /** @description This field has been renamed to `proration_behavior`. `prorate=true` can be replaced with `proration_behavior=create_prorations` and `prorate=false` can be replaced with `proration_behavior=none`. */ prorate?: boolean; - /** @description If the update changes the current phase, indicates if the changes should be prorated. Valid values are `create_prorations` or `none`, and the default value is `create_prorations`. */ + /** + * @description If the update changes the current phase, indicates if the changes should be prorated. Valid values are `create_prorations` or `none`, and the default value is `create_prorations`. + * @enum {string} + */ proration_behavior?: "always_invoice" | "create_prorations" | "none"; }; }; @@ -30419,7 +31651,10 @@ export interface operations { data: components["schemas"]["subscription"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -30485,7 +31720,10 @@ export interface operations { cancel_at?: number; /** @description Boolean indicating whether this subscription should cancel at the end of the current period. */ cancel_at_period_end?: boolean; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. + * @enum {string} + */ collection_method?: "charge_automatically" | "send_invoice"; /** @description The code of the coupon to apply to this subscription. A coupon applied to a subscription will only affect invoices created for that particular subscription. */ coupon?: string; @@ -30524,11 +31762,13 @@ export interface operations { * Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not create a subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more. * * `pending_if_incomplete` is only used with updates and cannot be passed when creating a subscription. + * @enum {string} */ payment_behavior?: "allow_incomplete" | "error_if_incomplete" | "pending_if_incomplete"; /** @description Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval. */ pending_invoice_item_interval?: (Partial< { + /** @enum {string} */ interval: "day" | "month" | "week" | "year"; interval_count?: number; } & { [key: string]: unknown } @@ -30540,6 +31780,7 @@ export interface operations { * @description Determines how to handle [prorations](https://stripe.com/docs/subscriptions/billing-cycle#prorations) resulting from the `billing_cycle_anchor`. Valid values are `create_prorations` or `none`. * * Passing `create_prorations` will cause proration invoice items to be created when applicable. Prorations can be disabled by passing `none`. If no value is passed, the default is `create_prorations`. + * @enum {string} */ proration_behavior?: "always_invoice" | "create_prorations" | "none"; /** @description A non-negative decimal (with at most four decimal places) between 0 and 100. This represents the percentage of the subscription invoice subtotal that will be calculated and added as tax to the final amount in each billing period. For example, a plan which charges $10/month with a `tax_percent` of `20.0` will charge $12 per invoice. To unset a previously-set value, pass an empty string. This field has been deprecated and will be removed in a future API version, for further information view the [migration docs](https://stripe.com/docs/billing/migration/taxes) for `tax_rates`. */ @@ -30611,7 +31852,10 @@ export interface operations { "application/x-www-form-urlencoded": { /** @description A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice subtotal that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions). */ application_fee_percent?: number; - /** @description Either `now` or `unchanged`. Setting the value to `now` resets the subscription's billing cycle anchor to the current time. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle). */ + /** + * @description Either `now` or `unchanged`. Setting the value to `now` resets the subscription's billing cycle anchor to the current time. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle). + * @enum {string} + */ billing_cycle_anchor?: "now" | "unchanged"; /** @description Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds. */ billing_thresholds?: (Partial< @@ -30625,7 +31869,10 @@ export interface operations { cancel_at?: (Partial & Partial<"">) & { [key: string]: unknown }; /** @description Boolean indicating whether this subscription should cancel at the end of the current period. */ cancel_at_period_end?: boolean; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. + * @enum {string} + */ collection_method?: "charge_automatically" | "send_invoice"; /** @description The code of the coupon to apply to this subscription. A coupon applied to a subscription will only affect invoices created for that particular subscription. */ coupon?: string; @@ -30662,6 +31909,7 @@ export interface operations { /** @description If specified, payment collection for this subscription will be paused. */ pause_collection?: (Partial< { + /** @enum {string} */ behavior: "keep_as_draft" | "mark_uncollectible" | "void"; /** Format: unix-time */ resumes_at?: number; @@ -30674,11 +31922,13 @@ export interface operations { * Use `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes). * * Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not create a subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more. + * @enum {string} */ payment_behavior?: "allow_incomplete" | "error_if_incomplete" | "pending_if_incomplete"; /** @description Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval. */ pending_invoice_item_interval?: (Partial< { + /** @enum {string} */ interval: "day" | "month" | "week" | "year"; interval_count?: number; } & { [key: string]: unknown } @@ -30692,6 +31942,7 @@ export interface operations { * Passing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`. * * Prorations can be disabled by passing `none`. + * @enum {string} */ proration_behavior?: "always_invoice" | "create_prorations" | "none"; /** @@ -30812,7 +32063,10 @@ export interface operations { data: components["schemas"]["tax_rate"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -30991,7 +32245,10 @@ export interface operations { data: components["schemas"]["terminal.location"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -31185,7 +32442,10 @@ export interface operations { data: components["schemas"]["terminal.reader"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -31357,6 +32617,7 @@ export interface operations { * @description Information for the account this token will represent. */ account?: { + /** @enum {string} */ business_type?: "company" | "government_entity" | "individual" | "non_profit"; /** company_specs */ company?: { @@ -31396,6 +32657,7 @@ export interface operations { name_kanji?: string; owners_provided?: boolean; phone?: string; + /** @enum {string} */ structure?: | "" | "government_instrumentality" @@ -31499,6 +32761,7 @@ export interface operations { */ bank_account?: { account_holder_name?: string; + /** @enum {string} */ account_holder_type?: "company" | "individual"; account_number: string; country: string; @@ -31690,7 +32953,10 @@ export interface operations { data: components["schemas"]["topup"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -31880,7 +33146,10 @@ export interface operations { data: components["schemas"]["transfer"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -31933,7 +33202,10 @@ export interface operations { metadata?: { [key: string]: string }; /** @description You can use this parameter to transfer funds from a charge before they are added to your available balance. A pending balance will transfer immediately but the funds will not become available until the original charge becomes available. [See the Connect documentation](https://stripe.com/docs/connect/charges-transfers#transfer-availability) for details. */ source_transaction?: string; - /** @description The source balance to use for this transfer. One of `bank_account`, `card`, or `fpx`. For most users, this will default to `card`. */ + /** + * @description The source balance to use for this transfer. One of `bank_account`, `card`, or `fpx`. For most users, this will default to `card`. + * @enum {string} + */ source_type?: "bank_account" | "card" | "fpx"; /** @description A string that identifies this transaction as part of a group. See the [Connect documentation](https://stripe.com/docs/connect/charges-transfers#transfer-options) for details. */ transfer_group?: string; @@ -31967,7 +33239,10 @@ export interface operations { data: components["schemas"]["transfer_reversal"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -32191,7 +33466,10 @@ export interface operations { data: components["schemas"]["webhook_endpoint"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -32230,7 +33508,10 @@ export interface operations { requestBody: { content: { "application/x-www-form-urlencoded": { - /** @description Events sent to this endpoint will be generated with this Stripe Version instead of your account's default Stripe Version. */ + /** + * @description Events sent to this endpoint will be generated with this Stripe Version instead of your account's default Stripe Version. + * @enum {string} + */ api_version?: | "2011-01-01" | "2011-06-21" diff --git a/test/v3/expected/stripe.immutable.ts b/test/v3/expected/stripe.immutable.ts index acfdc4e78..6ad7f238b 100644 --- a/test/v3/expected/stripe.immutable.ts +++ b/test/v3/expected/stripe.immutable.ts @@ -1494,7 +1494,10 @@ export interface components { readonly account: { /** @description Business information about the account. */ readonly business_profile?: Partial | null; - /** @description The business type. */ + /** + * @description The business type. + * @enum {string|null} + */ readonly business_type?: ("company" | "government_entity" | "individual" | "non_profit") | null; readonly capabilities?: components["schemas"]["account_capabilities"]; /** @description Whether the account can create live charges. */ @@ -1523,7 +1526,10 @@ export interface components { Partial)[]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -1533,7 +1539,10 @@ export interface components { readonly individual?: components["schemas"]["person"]; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata?: { readonly [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "account"; /** @description Whether Stripe can send payouts to this account. */ readonly payouts_enabled?: boolean; @@ -1541,7 +1550,10 @@ export interface components { /** @description Options for customizing how the account functions within Stripe. */ readonly settings?: Partial | null; readonly tos_acceptance?: components["schemas"]["account_tos_acceptance"]; - /** @description The Stripe account type. Can be `standard`, `express`, or `custom`. */ + /** + * @description The Stripe account type. Can be `standard`, `express`, or `custom`. + * @enum {string} + */ readonly type?: "custom" | "express" | "standard"; }; /** AccountBrandingSettings */ @@ -1576,19 +1588,40 @@ export interface components { }; /** AccountCapabilities */ readonly account_capabilities: { - /** @description The status of the BECS Direct Debit (AU) payments capability of the account, or whether the account can directly process BECS Direct Debit (AU) charges. */ + /** + * @description The status of the BECS Direct Debit (AU) payments capability of the account, or whether the account can directly process BECS Direct Debit (AU) charges. + * @enum {string} + */ readonly au_becs_debit_payments?: "active" | "inactive" | "pending"; - /** @description The status of the card issuing capability of the account, or whether you can use Issuing to distribute funds on cards */ + /** + * @description The status of the card issuing capability of the account, or whether you can use Issuing to distribute funds on cards + * @enum {string} + */ readonly card_issuing?: "active" | "inactive" | "pending"; - /** @description The status of the card payments capability of the account, or whether the account can directly process credit and debit card charges. */ + /** + * @description The status of the card payments capability of the account, or whether the account can directly process credit and debit card charges. + * @enum {string} + */ readonly card_payments?: "active" | "inactive" | "pending"; - /** @description The status of the legacy payments capability of the account. */ + /** + * @description The status of the legacy payments capability of the account. + * @enum {string} + */ readonly legacy_payments?: "active" | "inactive" | "pending"; - /** @description The status of the tax reporting 1099-K (US) capability of the account. */ + /** + * @description The status of the tax reporting 1099-K (US) capability of the account. + * @enum {string} + */ readonly tax_reporting_us_1099_k?: "active" | "inactive" | "pending"; - /** @description The status of the tax reporting 1099-MISC (US) capability of the account. */ + /** + * @description The status of the tax reporting 1099-MISC (US) capability of the account. + * @enum {string} + */ readonly tax_reporting_us_1099_misc?: "active" | "inactive" | "pending"; - /** @description The status of the transfers capability of the account, or whether your platform can transfer funds to the account. */ + /** + * @description The status of the transfers capability of the account, or whether your platform can transfer funds to the account. + * @enum {string} + */ readonly transfers?: "active" | "inactive" | "pending"; }; /** AccountCapabilityRequirements */ @@ -1649,7 +1682,10 @@ export interface components { * @description The timestamp at which this account link will expire. */ readonly expires_at: number; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "account_link"; /** @description The URL for the account link. */ readonly url: string; @@ -1693,7 +1729,10 @@ export interface components { }; /** AccountRequirementsError */ readonly account_requirements_error: { - /** @description The code for the type of error. */ + /** + * @description The code for the type of error. + * @enum {string} + */ readonly code: | "invalid_address_city_state_postal_code" | "invalid_street_address" @@ -1794,7 +1833,10 @@ export interface components { readonly livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata?: { readonly [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "alipay_account"; /** @description If the Alipay account object is not reusable, the exact amount that you can create a charge for. */ readonly payment_amount?: number | null; @@ -1828,7 +1870,10 @@ export interface components { readonly source?: Partial & Partial & Partial; - /** @description The type of error returned. One of `api_connection_error`, `api_error`, `authentication_error`, `card_error`, `idempotency_error`, `invalid_request_error`, or `rate_limit_error` */ + /** + * @description The type of error returned. One of `api_connection_error`, `api_error`, `authentication_error`, `card_error`, `idempotency_error`, `invalid_request_error`, or `rate_limit_error` + * @enum {string} + */ readonly type: | "api_connection_error" | "api_error" @@ -1850,7 +1895,10 @@ export interface components { readonly id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "apple_pay_domain"; }; /** Application */ @@ -1859,7 +1907,10 @@ export interface components { readonly id: string; /** @description The name of the application. */ readonly name?: string | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "application"; }; /** PlatformFee */ @@ -1887,7 +1938,10 @@ export interface components { readonly id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "application_fee"; /** @description ID of the corresponding charge on the platform account, if this fee was the result of a charge using the `destination` parameter. */ readonly originating_transaction?: (Partial & Partial) | null; @@ -1902,7 +1956,10 @@ export interface components { readonly data: readonly components["schemas"]["fee_refund"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -1929,7 +1986,10 @@ export interface components { readonly connect_reserved?: readonly components["schemas"]["balance_amount"][]; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "balance"; /** @description Funds that are not yet available in the balance, due to the 7-day rolling pay cycle. The pending balance for each currency, and for each payment type, can be found in the `source_types` property. */ readonly pending: readonly components["schemas"]["balance_amount"][]; @@ -1985,7 +2045,10 @@ export interface components { readonly id: string; /** @description Net amount of the transaction, in %s. */ readonly net: number; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "balance_transaction"; /** @description [Learn more](https://stripe.com/docs/reports/reporting-categories) about how reporting categories can help you understand balance transactions from an accounting perspective. */ readonly reporting_category: string; @@ -2010,7 +2073,10 @@ export interface components { | null; /** @description If the transaction's net funds are available in the Stripe balance yet. Either `available` or `pending`. */ readonly status: string; - /** @description Transaction type: `adjustment`, `advance`, `advance_funding`, `application_fee`, `application_fee_refund`, `charge`, `connect_collection_transfer`, `issuing_authorization_hold`, `issuing_authorization_release`, `issuing_transaction`, `payment`, `payment_failure_refund`, `payment_refund`, `payout`, `payout_cancel`, `payout_failure`, `refund`, `refund_failure`, `reserve_transaction`, `reserved_funds`, `stripe_fee`, `stripe_fx_fee`, `tax_fee`, `topup`, `topup_reversal`, `transfer`, `transfer_cancel`, `transfer_failure`, or `transfer_refund`. [Learn more](https://stripe.com/docs/reports/balance-transaction-types) about balance transaction types and what they represent. If you are looking to classify transactions for accounting purposes, you might want to consider `reporting_category` instead. */ + /** + * @description Transaction type: `adjustment`, `advance`, `advance_funding`, `application_fee`, `application_fee_refund`, `charge`, `connect_collection_transfer`, `issuing_authorization_hold`, `issuing_authorization_release`, `issuing_transaction`, `payment`, `payment_failure_refund`, `payment_refund`, `payout`, `payout_cancel`, `payout_failure`, `refund`, `refund_failure`, `reserve_transaction`, `reserved_funds`, `stripe_fee`, `stripe_fx_fee`, `tax_fee`, `topup`, `topup_reversal`, `transfer`, `transfer_cancel`, `transfer_failure`, or `transfer_refund`. [Learn more](https://stripe.com/docs/reports/balance-transaction-types) about balance transaction types and what they represent. If you are looking to classify transactions for accounting purposes, you might want to consider `reporting_category` instead. + * @enum {string} + */ readonly type: | "adjustment" | "advance" @@ -2081,7 +2147,10 @@ export interface components { readonly last4: string; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata?: { readonly [key: string]: string } | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "bank_account"; /** @description The routing transit number for the bank account. */ readonly routing_number?: string | null; @@ -2125,7 +2194,10 @@ export interface components { readonly id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "billing_portal.session"; /** @description The URL to which Stripe should send customers when they click on the link to return to your website. */ readonly return_url: string; @@ -2169,7 +2241,10 @@ export interface components { readonly livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "bitcoin_receiver"; /** @description The ID of the payment created from the receiver, if any. Hidden when viewing the receiver with a publishable key. */ readonly payment?: string | null; @@ -2184,7 +2259,10 @@ export interface components { readonly data: readonly components["schemas"]["bitcoin_transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -2209,7 +2287,10 @@ export interface components { readonly currency: string; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "bitcoin_transaction"; /** @description The receiver to which this transaction was sent. */ readonly receiver: string; @@ -2225,7 +2306,10 @@ export interface components { readonly account: Partial & Partial; /** @description The identifier for the capability. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "capability"; /** @description Whether the capability has been requested. */ readonly requested: boolean; @@ -2235,7 +2319,10 @@ export interface components { */ readonly requested_at?: number | null; readonly requirements?: components["schemas"]["account_capability_requirements"]; - /** @description The status of the capability. Can be `active`, `inactive`, `pending`, or `unrequested`. */ + /** + * @description The status of the capability. Can be `active`, `inactive`, `pending`, or `unrequested`. + * @enum {string} + */ readonly status: "active" | "disabled" | "inactive" | "pending" | "unrequested"; }; /** @@ -2300,7 +2387,10 @@ export interface components { readonly metadata: { readonly [key: string]: string }; /** @description Cardholder name. */ readonly name?: string | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "card"; /** @description The recipient that this card belongs to. This attribute will not be in the card object if the card belongs to a customer or account instead. */ readonly recipient?: (Partial & Partial) | null; @@ -2366,7 +2456,10 @@ export interface components { readonly livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "charge"; /** @description The account (if any) the charge was made on behalf of without triggering an automatic transfer. See the [Connect documentation](https://stripe.com/docs/connect/charges-transfers) for details. */ readonly on_behalf_of?: (Partial & Partial) | null; @@ -2399,7 +2492,10 @@ export interface components { readonly data: readonly components["schemas"]["refund"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -2509,7 +2605,10 @@ export interface components { readonly id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description The IETF language tag of the locale Checkout is displayed in. If blank or `auto`, the browser's locale is used. */ + /** + * @description The IETF language tag of the locale Checkout is displayed in. If blank or `auto`, the browser's locale is used. + * @enum {string|null} + */ readonly locale?: | ( | "auto" @@ -2533,9 +2632,15 @@ export interface components { | null; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata?: { readonly [key: string]: string } | null; - /** @description The mode of the Checkout Session, one of `payment`, `setup`, or `subscription`. */ + /** + * @description The mode of the Checkout Session, one of `payment`, `setup`, or `subscription`. + * @enum {string|null} + */ readonly mode?: ("payment" | "setup" | "subscription") | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "checkout.session"; /** @description The ID of the PaymentIntent for Checkout Sessions in `payment` mode. */ readonly payment_intent?: (Partial & Partial) | null; @@ -2557,6 +2662,7 @@ export interface components { * relevant text on the page, such as the submit button. `submit_type` can only be * specified on Checkout Sessions in `payment` mode, but not Checkout Sessions * in `subscription` or `setup` mode. + * @enum {string|null} */ readonly submit_type?: ("auto" | "book" | "donate" | "pay") | null; /** @description The ID of the subscription for Checkout Sessions in `subscription` mode. */ @@ -2602,7 +2708,10 @@ export interface components { readonly id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "connect_collection_transfer"; }; /** @@ -2619,7 +2728,10 @@ export interface components { readonly default_currency: string; /** @description Unique identifier for the object. Represented as the ISO country code for this country. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "country_spec"; /** @description Currencies that can be accepted in the specific country (for transfers). */ readonly supported_bank_account_currencies: { readonly [key: string]: readonly string[] }; @@ -2659,7 +2771,10 @@ export interface components { readonly created: number; /** @description If `amount_off` has been set, the three-letter [ISO code for the currency](https://stripe.com/docs/currencies) of the amount to take off. */ readonly currency?: string | null; - /** @description One of `forever`, `once`, and `repeating`. Describes how long a customer who applies this coupon will get the discount. */ + /** + * @description One of `forever`, `once`, and `repeating`. Describes how long a customer who applies this coupon will get the discount. + * @enum {string} + */ readonly duration: "forever" | "once" | "repeating"; /** @description If `duration` is `repeating`, the number of months the coupon applies. Null if coupon `duration` is `forever` or `once`. */ readonly duration_in_months?: number | null; @@ -2673,7 +2788,10 @@ export interface components { readonly metadata: { readonly [key: string]: string }; /** @description Name of the coupon displayed to customers on for instance invoices or receipts. */ readonly name?: string | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "coupon"; /** @description Percent that will be taken off the subtotal of any invoices for this customer for the duration of the coupon. For example, a coupon with percent_off of 50 will make a %s100 invoice %s50 instead. */ readonly percent_off?: number | null; @@ -2724,7 +2842,10 @@ export interface components { readonly data: readonly components["schemas"]["credit_note_line_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -2737,17 +2858,26 @@ export interface components { readonly metadata: { readonly [key: string]: string }; /** @description A unique number that identifies this particular credit note and appears on the PDF of the credit note and its associated invoice. */ readonly number: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "credit_note"; /** @description Amount that was credited outside of Stripe. */ readonly out_of_band_amount?: number | null; /** @description The link to download the PDF of the credit note. */ readonly pdf: string; - /** @description Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory` */ + /** + * @description Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory` + * @enum {string|null} + */ readonly reason?: ("duplicate" | "fraudulent" | "order_change" | "product_unsatisfactory") | null; /** @description Refund related to this credit note. */ readonly refund?: (Partial & Partial) | null; - /** @description Status of this credit note, one of `issued` or `void`. Learn more about [voiding credit notes](https://stripe.com/docs/billing/invoices/credit-notes#voiding). */ + /** + * @description Status of this credit note, one of `issued` or `void`. Learn more about [voiding credit notes](https://stripe.com/docs/billing/invoices/credit-notes#voiding). + * @enum {string} + */ readonly status: "issued" | "void"; /** @description The integer amount in **%s** representing the amount of the credit note, excluding tax and discount. */ readonly subtotal: number; @@ -2755,7 +2885,10 @@ export interface components { readonly tax_amounts: readonly components["schemas"]["credit_note_tax_amount"][]; /** @description The integer amount in **%s** representing the total amount of the credit note, including tax and discount. */ readonly total: number; - /** @description Type of this credit note, one of `pre_payment` or `post_payment`. A `pre_payment` credit note means it was issued when the invoice was open. A `post_payment` credit note means it was issued when the invoice was paid. */ + /** + * @description Type of this credit note, one of `pre_payment` or `post_payment`. A `pre_payment` credit note means it was issued when the invoice was open. A `post_payment` credit note means it was issued when the invoice was paid. + * @enum {string} + */ readonly type: "post_payment" | "pre_payment"; /** * Format: unix-time @@ -2777,7 +2910,10 @@ export interface components { readonly invoice_line_item?: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "credit_note_line_item"; /** @description The number of units of product being credited. */ readonly quantity?: number | null; @@ -2785,7 +2921,10 @@ export interface components { readonly tax_amounts: readonly components["schemas"]["credit_note_tax_amount"][]; /** @description The tax rates which apply to the line item. */ readonly tax_rates: readonly components["schemas"]["tax_rate"][]; - /** @description The type of the credit note line item, one of `invoice_line_item` or `custom_line_item`. When the type is `invoice_line_item` there is an additional `invoice_line_item` property on the resource the value of which is the id of the credited line item on the invoice. */ + /** + * @description The type of the credit note line item, one of `invoice_line_item` or `custom_line_item`. When the type is `invoice_line_item` there is an additional `invoice_line_item` property on the resource the value of which is the id of the credited line item on the invoice. + * @enum {string} + */ readonly type: "custom_line_item" | "invoice_line_item"; /** @description The cost of each unit of product being credited. */ readonly unit_amount?: number | null; @@ -2859,7 +2998,10 @@ export interface components { readonly name?: string | null; /** @description The suffix of the customer's next invoice number, e.g., 0001. */ readonly next_invoice_sequence?: number; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "customer"; /** @description The customer's phone number. */ readonly phone?: string | null; @@ -2880,7 +3022,10 @@ export interface components { Partial)[]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -2894,12 +3039,18 @@ export interface components { readonly data: readonly components["schemas"]["subscription"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; }; - /** @description Describes the customer's tax exemption status. One of `none`, `exempt`, or `reverse`. When set to `reverse`, invoice and receipt PDFs include the text **"Reverse charge"**. */ + /** + * @description Describes the customer's tax exemption status. One of `none`, `exempt`, or `reverse`. When set to `reverse`, invoice and receipt PDFs include the text **"Reverse charge"**. + * @enum {string|null} + */ readonly tax_exempt?: ("exempt" | "none" | "reverse") | null; /** * TaxIDsList @@ -2910,7 +3061,10 @@ export interface components { readonly data: readonly components["schemas"]["tax_id"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -2925,7 +3079,10 @@ export interface components { readonly accepted_at?: number | null; readonly offline?: components["schemas"]["offline_acceptance"]; readonly online?: components["schemas"]["online_acceptance"]; - /** @description The type of customer acceptance information included with the Mandate. One of `online` or `offline`. */ + /** + * @description The type of customer acceptance information included with the Mandate. One of `online` or `offline`. + * @enum {string} + */ readonly type: "offline" | "online"; }; /** @@ -2963,9 +3120,15 @@ export interface components { readonly livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata?: { readonly [key: string]: string } | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "customer_balance_transaction"; - /** @description Transaction type: `adjustment`, `applied_to_invoice`, `credit_note`, `initial`, `invoice_too_large`, `invoice_too_small`, `unspent_receiver_credit`, or `unapplied_from_invoice`. See the [Customer Balance page](https://stripe.com/docs/billing/customer/balance#types) to learn more about transaction types. */ + /** + * @description Transaction type: `adjustment`, `applied_to_invoice`, `credit_note`, `initial`, `invoice_too_large`, `invoice_too_small`, `unspent_receiver_credit`, or `unapplied_from_invoice`. See the [Customer Balance page](https://stripe.com/docs/billing/customer/balance#types) to learn more about transaction types. + * @enum {string} + */ readonly type: | "adjustment" | "applied_to_invoice" @@ -2979,85 +3142,139 @@ export interface components { }; /** DeletedAccount */ readonly deleted_account: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "account"; }; /** AlipayDeletedAccount */ readonly deleted_alipay_account: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "alipay_account"; }; /** DeletedApplePayDomain */ readonly deleted_apple_pay_domain: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "apple_pay_domain"; }; /** DeletedBankAccount */ readonly deleted_bank_account: { /** @description Three-letter [ISO code for the currency](https://stripe.com/docs/payouts) paid out to the bank account. */ readonly currency?: string | null; - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "bank_account"; }; /** BitcoinDeletedReceiver */ readonly deleted_bitcoin_receiver: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "bitcoin_receiver"; }; /** DeletedCard */ readonly deleted_card: { /** @description Three-letter [ISO code for the currency](https://stripe.com/docs/payouts) paid out to the bank account. */ readonly currency?: string | null; - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "card"; }; /** DeletedCoupon */ readonly deleted_coupon: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "coupon"; }; /** DeletedCustomer */ readonly deleted_customer: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "customer"; }; /** DeletedDiscount */ readonly deleted_discount: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "discount"; }; /** Polymorphic */ @@ -3065,20 +3282,32 @@ export interface components { Partial; /** DeletedInvoice */ readonly deleted_invoice: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "invoice"; }; /** DeletedInvoiceItem */ readonly deleted_invoiceitem: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "invoiceitem"; }; /** Polymorphic */ @@ -3088,110 +3317,182 @@ export interface components { Partial; /** DeletedPerson */ readonly deleted_person: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "person"; }; /** DeletedPlan */ readonly deleted_plan: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "plan"; }; /** DeletedProduct */ readonly deleted_product: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "product"; }; /** RadarListDeletedList */ readonly "deleted_radar.value_list": { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "radar.value_list"; }; /** RadarListDeletedListItem */ readonly "deleted_radar.value_list_item": { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "radar.value_list_item"; }; /** DeletedTransferRecipient */ readonly deleted_recipient: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "recipient"; }; /** DeletedSKU */ readonly deleted_sku: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "sku"; }; /** DeletedSubscriptionItem */ readonly deleted_subscription_item: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "subscription_item"; }; /** deleted_tax_id */ readonly deleted_tax_id: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "tax_id"; }; /** TerminalLocationDeletedLocation */ readonly "deleted_terminal.location": { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "terminal.location"; }; /** TerminalReaderDeletedReader */ readonly "deleted_terminal.reader": { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "terminal.reader"; }; /** NotificationWebhookEndpointDeleted */ readonly deleted_webhook_endpoint: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ readonly deleted: true; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "webhook_endpoint"; }; /** DeliveryEstimate */ @@ -3226,7 +3527,10 @@ export interface components { * @description If the coupon has a duration of `repeating`, the date that this discount will end. If the coupon has a duration of `once` or `forever`, this attribute will be null. */ readonly end?: number | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "discount"; /** * Format: unix-time @@ -3270,13 +3574,19 @@ export interface components { readonly livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "dispute"; /** @description ID of the PaymentIntent that was disputed. */ readonly payment_intent?: (Partial & Partial) | null; /** @description Reason given by cardholder for dispute. Possible values are `bank_cannot_process`, `check_returned`, `credit_not_processed`, `customer_initiated`, `debit_not_authorized`, `duplicate`, `fraudulent`, `general`, `incorrect_account_details`, `insufficient_funds`, `product_not_received`, `product_unacceptable`, `subscription_canceled`, or `unrecognized`. Read more about [dispute reasons](https://stripe.com/docs/disputes/categories). */ readonly reason: string; - /** @description Current status of dispute. Possible values are `warning_needs_response`, `warning_under_review`, `warning_closed`, `needs_response`, `under_review`, `charge_refunded`, `won`, or `lost`. */ + /** + * @description Current status of dispute. Possible values are `warning_needs_response`, `warning_under_review`, `warning_closed`, `needs_response`, `under_review`, `charge_refunded`, `won`, or `lost`. + * @enum {string} + */ readonly status: | "charge_refunded" | "lost" @@ -3374,7 +3684,10 @@ export interface components { readonly id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "ephemeral_key"; /** @description The key's secret. You can use this value to make authorized requests to the Stripe API. */ readonly secret?: string; @@ -3430,7 +3743,10 @@ export interface components { readonly id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "event"; /** @description Number of webhooks that have yet to be successfully delivered (i.e., to return a 20x response) to the URLs you've specified. */ readonly pending_webhooks: number; @@ -3456,7 +3772,10 @@ export interface components { readonly exchange_rate: { /** @description Unique identifier for the object. Represented as the three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) in lowercase. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "exchange_rate"; /** @description Hash where the keys are supported currencies and the values are the exchange rate at which the base id currency converts to the key currency. */ readonly rates: { readonly [key: string]: number }; @@ -3502,7 +3821,10 @@ export interface components { readonly id: string; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "fee_refund"; }; /** @@ -3534,12 +3856,18 @@ export interface components { readonly data: readonly components["schemas"]["file_link"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; } | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "file"; /** @description The purpose of the file. Possible values are `additional_verification`, `business_icon`, `business_logo`, `customer_signature`, `dispute_evidence`, `finance_report_run`, `identity_document`, `pci_document`, `sigma_scheduled_query`, or `tax_document_user_upload`. */ readonly purpose: string; @@ -3579,7 +3907,10 @@ export interface components { readonly livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "file_link"; /** @description The publicly accessible URL to download the file. */ readonly url?: string | null; @@ -3672,7 +4003,10 @@ export interface components { readonly attempted: boolean; /** @description Controls whether Stripe will perform [automatic collection](https://stripe.com/docs/billing/invoices/workflow/#auto_advance) of the invoice. When `false`, the invoice's state will not automatically advance without an explicit action. */ readonly auto_advance?: boolean; - /** @description Indicates the reason why the invoice was created. `subscription_cycle` indicates an invoice created by a subscription advancing into a new period. `subscription_create` indicates an invoice created due to creating a subscription. `subscription_update` indicates an invoice created due to updating a subscription. `subscription` is set for all old invoices to indicate either a change to a subscription or a period advancement. `manual` is set for all invoices unrelated to a subscription (for example: created via the invoice editor). The `upcoming` value is reserved for simulated invoices per the upcoming invoice endpoint. `subscription_threshold` indicates an invoice created due to a billing threshold being reached. */ + /** + * @description Indicates the reason why the invoice was created. `subscription_cycle` indicates an invoice created by a subscription advancing into a new period. `subscription_create` indicates an invoice created due to creating a subscription. `subscription_update` indicates an invoice created due to updating a subscription. `subscription` is set for all old invoices to indicate either a change to a subscription or a period advancement. `manual` is set for all invoices unrelated to a subscription (for example: created via the invoice editor). The `upcoming` value is reserved for simulated invoices per the upcoming invoice endpoint. `subscription_threshold` indicates an invoice created due to a billing threshold being reached. + * @enum {string|null} + */ readonly billing_reason?: | ( | "automatic_pending_invoice_item_invoice" @@ -3687,7 +4021,10 @@ export interface components { | null; /** @description ID of the latest charge generated for this invoice, if any. */ readonly charge?: (Partial & Partial) | null; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this invoice using the default source attached to the customer. When sending an invoice, Stripe will email this invoice to the customer with payment instructions. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this invoice using the default source attached to the customer. When sending an invoice, Stripe will email this invoice to the customer with payment instructions. + * @enum {string|null} + */ readonly collection_method?: ("charge_automatically" | "send_invoice") | null; /** * Format: unix-time @@ -3712,7 +4049,10 @@ export interface components { readonly customer_phone?: string | null; /** @description The customer's shipping information. Until the invoice is finalized, this field will equal `customer.shipping`. Once the invoice is finalized, this field will no longer be updated. */ readonly customer_shipping?: Partial | null; - /** @description The customer's tax exempt status. Until the invoice is finalized, this field will equal `customer.tax_exempt`. Once the invoice is finalized, this field will no longer be updated. */ + /** + * @description The customer's tax exempt status. Until the invoice is finalized, this field will equal `customer.tax_exempt`. Once the invoice is finalized, this field will no longer be updated. + * @enum {string|null} + */ readonly customer_tax_exempt?: ("exempt" | "none" | "reverse") | null; /** @description The customer's tax IDs. Until the invoice is finalized, this field will contain the same tax IDs as `customer.tax_ids`. Once the invoice is finalized, this field will no longer be updated. */ readonly customer_tax_ids?: readonly components["schemas"]["invoices_resource_invoice_tax_id"][] | null; @@ -3757,7 +4097,10 @@ export interface components { readonly data: readonly components["schemas"]["line_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -3773,7 +4116,10 @@ export interface components { readonly next_payment_attempt?: number | null; /** @description A unique, identifying string that appears on emails sent to the customer for this invoice. This starts with the customer's unique invoice_prefix if it is specified. */ readonly number?: string | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "invoice"; /** @description Whether payment was successfully collected for this invoice. An invoice can be paid (most commonly) with a charge or with credit from the customer's account balance. */ readonly paid: boolean; @@ -3799,7 +4145,10 @@ export interface components { readonly starting_balance: number; /** @description Extra information about an invoice for the customer's credit card statement. */ readonly statement_descriptor?: string | null; - /** @description The status of the invoice, one of `draft`, `open`, `paid`, `uncollectible`, or `void`. [Learn more](https://stripe.com/docs/billing/invoices/workflow#workflow-overview) */ + /** + * @description The status of the invoice, one of `draft`, `open`, `paid`, `uncollectible`, or `void`. [Learn more](https://stripe.com/docs/billing/invoices/workflow#workflow-overview) + * @enum {string|null} + */ readonly status?: ("deleted" | "draft" | "open" | "paid" | "uncollectible" | "void") | null; readonly status_transitions: components["schemas"]["invoices_status_transitions"]; /** @description The subscription that this invoice was prepared for, if any. */ @@ -3910,7 +4259,10 @@ export interface components { readonly livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "invoiceitem"; readonly period: components["schemas"]["invoice_line_item_period"]; /** @description If the invoice item is a proration, the plan of the subscription that the proration was computed for. */ @@ -3935,7 +4287,10 @@ export interface components { }; /** InvoicesResourceInvoiceTaxID */ readonly invoices_resource_invoice_tax_id: { - /** @description The type of the tax ID, one of `eu_vat`, `nz_gst`, `au_abn`, `in_gst`, `no_vat`, `za_vat`, `ch_vat`, `mx_rfc`, `sg_uen`, `ru_inn`, `ca_bn`, `hk_br`, `es_cif`, `tw_vat`, `th_vat`, `jp_cn`, `li_uid`, `my_itn`, `us_ein`, `kr_brn`, `ca_qst`, `my_sst`, `sg_gst`, or `unknown` */ + /** + * @description The type of the tax ID, one of `eu_vat`, `nz_gst`, `au_abn`, `in_gst`, `no_vat`, `za_vat`, `ch_vat`, `mx_rfc`, `sg_uen`, `ru_inn`, `ca_bn`, `hk_br`, `es_cif`, `tw_vat`, `th_vat`, `jp_cn`, `li_uid`, `my_itn`, `us_ein`, `kr_brn`, `ca_qst`, `my_sst`, `sg_gst`, or `unknown` + * @enum {string} + */ readonly type: | "au_abn" | "ca_bn" @@ -4011,7 +4366,10 @@ export interface components { readonly id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "issuer_fraud_record"; /** @description The timestamp at which the card issuer posted the issuer fraud record. */ readonly post_date: number; @@ -4029,7 +4387,10 @@ export interface components { readonly amount: number; /** @description Whether the authorization has been approved. */ readonly approved: boolean; - /** @description How the card details were provided. */ + /** + * @description How the card details were provided. + * @enum {string} + */ readonly authorization_method: "chip" | "contactless" | "keyed_in" | "online" | "swipe"; /** @description List of balance transactions associated with this authorization. */ readonly balance_transactions: readonly components["schemas"]["balance_transaction"][]; @@ -4054,13 +4415,19 @@ export interface components { readonly merchant_data: components["schemas"]["issuing_authorization_merchant_data"]; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "issuing.authorization"; /** @description The pending authorization request. This field will only be non-null during an `issuing_authorization.request` webhook. */ readonly pending_request?: Partial | null; /** @description History of every time the authorization was approved/denied (whether approved/denied by you directly or by Stripe based on your `spending_controls`). If the merchant changes the authorization by performing an [incremental authorization or partial capture](https://stripe.com/docs/issuing/purchases/authorizations), you can look at this field to see the previous states of the authorization. */ readonly request_history: readonly components["schemas"]["issuing_authorization_request"][]; - /** @description The current status of the authorization in its lifecycle. */ + /** + * @description The current status of the authorization in its lifecycle. + * @enum {string} + */ readonly status: "closed" | "pending" | "reversed"; /** @description List of [transactions](https://stripe.com/docs/api/issuing/transactions) associated with this authorization. */ readonly transactions: readonly components["schemas"]["issuing.transaction"][]; @@ -4075,7 +4442,10 @@ export interface components { readonly "issuing.card": { /** @description The brand of the card. */ readonly brand: string; - /** @description The reason why the card was canceled. */ + /** + * @description The reason why the card was canceled. + * @enum {string|null} + */ readonly cancellation_reason?: ("lost" | "stolen") | null; readonly cardholder: components["schemas"]["issuing.cardholder"]; /** @@ -4101,20 +4471,32 @@ export interface components { readonly metadata: { readonly [key: string]: string }; /** @description The full unredacted card number. For security reasons, this is only available for virtual cards, and will be omitted unless you explicitly request it with [the `expand` parameter](https://stripe.com/docs/api/expanding_objects). Additionally, it's only available via the ["Retrieve a card" endpoint](https://stripe.com/docs/api/issuing/cards/retrieve), not via "List all cards" or any other endpoint. */ readonly number?: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "issuing.card"; /** @description The latest card that replaces this card, if any. */ readonly replaced_by?: (Partial & Partial) | null; /** @description The card this card replaces, if any. */ readonly replacement_for?: (Partial & Partial) | null; - /** @description The reason why the previous card needed to be replaced. */ + /** + * @description The reason why the previous card needed to be replaced. + * @enum {string|null} + */ readonly replacement_reason?: ("damaged" | "expired" | "lost" | "stolen") | null; /** @description Where and how the card will be shipped. */ readonly shipping?: Partial | null; readonly spending_controls: components["schemas"]["issuing_card_authorization_controls"]; - /** @description Whether authorizations can be approved on this card. */ + /** + * @description Whether authorizations can be approved on this card. + * @enum {string} + */ readonly status: "active" | "canceled" | "inactive"; - /** @description The type of the card. */ + /** + * @description The type of the card. + * @enum {string} + */ readonly type: "physical" | "virtual"; }; /** @@ -4144,16 +4526,25 @@ export interface components { readonly metadata: { readonly [key: string]: string }; /** @description The cardholder's name. This will be printed on cards issued to them. */ readonly name: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "issuing.cardholder"; /** @description The cardholder's phone number. */ readonly phone_number?: string | null; readonly requirements: components["schemas"]["issuing_cardholder_requirements"]; /** @description Spending rules that give you some control over how this cardholder's cards can be used. Refer to our [authorizations](https://stripe.com/docs/issuing/purchases/authorizations) documentation for more details. */ readonly spending_controls?: Partial | null; - /** @description Specifies whether to permit authorizations on this cardholder's cards. */ + /** + * @description Specifies whether to permit authorizations on this cardholder's cards. + * @enum {string} + */ readonly status: "active" | "blocked" | "inactive"; - /** @description One of `individual` or `company`. */ + /** + * @description One of `individual` or `company`. + * @enum {string} + */ readonly type: "company" | "individual"; }; /** @@ -4167,7 +4558,10 @@ export interface components { readonly id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "issuing.dispute"; }; /** @@ -4196,13 +4590,19 @@ export interface components { readonly metadata: { readonly [key: string]: string }; /** @description The total net amount required to settle with the network. */ readonly net_total: number; - /** @description The card network for this settlement report. One of ["visa"] */ + /** + * @description The card network for this settlement report. One of ["visa"] + * @enum {string} + */ readonly network: "visa"; /** @description The total amount of fees owed to the network. */ readonly network_fees: number; /** @description The Settlement Identification Number assigned by the network. */ readonly network_settlement_identifier: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "issuing.settlement"; /** @description One of `international` or `uk_national_net`. */ readonly settlement_service: string; @@ -4248,9 +4648,15 @@ export interface components { readonly merchant_data: components["schemas"]["issuing_authorization_merchant_data"]; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "issuing.transaction"; - /** @description The nature of the transaction. */ + /** + * @description The nature of the transaction. + * @enum {string} + */ readonly type: "capture" | "refund"; }; /** IssuingAuthorizationMerchantData */ @@ -4300,7 +4706,10 @@ export interface components { readonly merchant_amount: number; /** @description The currency that was collected by the merchant and presented to the cardholder for the authorization. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). */ readonly merchant_currency: string; - /** @description The reason for the approval or decline. */ + /** + * @description The reason for the approval or decline. + * @enum {string} + */ readonly reason: | "account_disabled" | "card_active" @@ -4318,13 +4727,25 @@ export interface components { }; /** IssuingAuthorizationVerificationData */ readonly issuing_authorization_verification_data: { - /** @description Whether the cardholder provided an address first line and if it matched the cardholder’s `billing.address.line1`. */ + /** + * @description Whether the cardholder provided an address first line and if it matched the cardholder’s `billing.address.line1`. + * @enum {string} + */ readonly address_line1_check: "match" | "mismatch" | "not_provided"; - /** @description Whether the cardholder provided a postal code and if it matched the cardholder’s `billing.address.postal_code`. */ + /** + * @description Whether the cardholder provided a postal code and if it matched the cardholder’s `billing.address.postal_code`. + * @enum {string} + */ readonly address_postal_code_check: "match" | "mismatch" | "not_provided"; - /** @description Whether the cardholder provided a CVC and if it matched Stripe’s record. */ + /** + * @description Whether the cardholder provided a CVC and if it matched Stripe’s record. + * @enum {string} + */ readonly cvc_check: "match" | "mismatch" | "not_provided"; - /** @description Whether the cardholder provided an expiry date and if it matched Stripe’s record. */ + /** + * @description Whether the cardholder provided an expiry date and if it matched Stripe’s record. + * @enum {string} + */ readonly expiry_check: "match" | "mismatch" | "not_provided"; }; /** IssuingCardAuthorizationControls */ @@ -4923,7 +5344,10 @@ export interface components { /** IssuingCardShipping */ readonly issuing_card_shipping: { readonly address: components["schemas"]["address"]; - /** @description The delivery company that shipped a card. */ + /** + * @description The delivery company that shipped a card. + * @enum {string|null} + */ readonly carrier?: ("fedex" | "usps") | null; /** * Format: unix-time @@ -4932,15 +5356,24 @@ export interface components { readonly eta?: number | null; /** @description Recipient name. */ readonly name: string; - /** @description Shipment service, such as `standard` or `express`. */ + /** + * @description Shipment service, such as `standard` or `express`. + * @enum {string} + */ readonly service: "express" | "priority" | "standard"; - /** @description The delivery status of the card. */ + /** + * @description The delivery status of the card. + * @enum {string|null} + */ readonly status?: ("canceled" | "delivered" | "failure" | "pending" | "returned" | "shipped") | null; /** @description A tracking number for a card shipment. */ readonly tracking_number?: string | null; /** @description A link to the shipping carrier's site where you can view detailed information about a card shipment. */ readonly tracking_url?: string | null; - /** @description Packaging options. */ + /** + * @description Packaging options. + * @enum {string} + */ readonly type: "bulk" | "individual"; }; /** IssuingCardSpendingLimit */ @@ -5240,7 +5673,10 @@ export interface components { | "wrecking_and_salvage_yards" )[] | null; - /** @description The time interval or event with which to apply this spending limit towards. */ + /** + * @description The time interval or event with which to apply this spending limit towards. + * @enum {string} + */ readonly interval: "all_time" | "daily" | "monthly" | "per_authorization" | "weekly" | "yearly"; }; /** IssuingCardholderAddress */ @@ -5874,7 +6310,10 @@ export interface components { }; /** IssuingCardholderRequirements */ readonly issuing_cardholder_requirements: { - /** @description If `disabled_reason` is present, all cards will decline authorizations with `cardholder_verification_required` reason. */ + /** + * @description If `disabled_reason` is present, all cards will decline authorizations with `cardholder_verification_required` reason. + * @enum {string|null} + */ readonly disabled_reason?: ("listed" | "rejected.listed" | "under_review") | null; /** @description Array of fields that need to be collected in order to verify and re-enable the cardholder. */ readonly past_due?: @@ -6186,7 +6625,10 @@ export interface components { | "wrecking_and_salvage_yards" )[] | null; - /** @description The time interval or event with which to apply this spending limit towards. */ + /** + * @description The time interval or event with which to apply this spending limit towards. + * @enum {string} + */ readonly interval: "all_time" | "daily" | "monthly" | "per_authorization" | "weekly" | "yearly"; }; /** IssuingCardholderVerification */ @@ -6215,7 +6657,10 @@ export interface components { readonly owners_provided?: boolean; /** @description The company's phone number (used for verification). */ readonly phone?: string | null; - /** @description The category identifying the legal structure of the company or legal entity. See [Business structure](https://stripe.com/docs/connect/identity-verification#business-structure) for more details. */ + /** + * @description The category identifying the legal structure of the company or legal entity. See [Business structure](https://stripe.com/docs/connect/identity-verification#business-structure) for more details. + * @enum {string} + */ readonly structure?: | "government_instrumentality" | "governmental_unit" @@ -6325,7 +6770,10 @@ export interface components { readonly livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Note that for line items with `type=subscription` this will reflect the metadata of the subscription that caused the line item to be created. */ readonly metadata: { readonly [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "line_item"; readonly period: components["schemas"]["invoice_line_item_period"]; /** @description The plan of the subscription, if the line item is a subscription or a proration. */ @@ -6342,7 +6790,10 @@ export interface components { readonly tax_amounts?: readonly components["schemas"]["invoice_tax_amount"][] | null; /** @description The tax rates which apply to the line item. */ readonly tax_rates?: readonly components["schemas"]["tax_rate"][] | null; - /** @description A string identifying the type of the source of this line item, either an `invoiceitem` or a `subscription`. */ + /** + * @description A string identifying the type of the source of this line item, either an `invoiceitem` or a `subscription`. + * @enum {string} + */ readonly type: "invoiceitem" | "subscription"; }; /** LoginLink */ @@ -6352,7 +6803,10 @@ export interface components { * @description Time at which the object was created. Measured in seconds since the Unix epoch. */ readonly created: number; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "login_link"; /** @description The URL for the login link. */ readonly url: string; @@ -6368,15 +6822,24 @@ export interface components { /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; readonly multi_use?: components["schemas"]["mandate_multi_use"]; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "mandate"; /** @description ID of the payment method associated with this mandate. */ readonly payment_method: Partial & Partial; readonly payment_method_details: components["schemas"]["mandate_payment_method_details"]; readonly single_use?: components["schemas"]["mandate_single_use"]; - /** @description The status of the mandate, which indicates whether it can be used to initiate a payment. */ + /** + * @description The status of the mandate, which indicates whether it can be used to initiate a payment. + * @enum {string} + */ readonly status: "active" | "inactive" | "pending"; - /** @description The type of the mandate. */ + /** + * @description The type of the mandate. + * @enum {string} + */ readonly type: "multi_use" | "single_use"; }; /** mandate_au_becs_debit */ @@ -6475,7 +6938,10 @@ export interface components { readonly livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "order"; /** * OrderReturnList @@ -6486,7 +6952,10 @@ export interface components { readonly data: readonly components["schemas"]["order_return"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -6523,7 +6992,10 @@ export interface components { readonly currency: string; /** @description Description of the line item, meant to be displayable to the user (e.g., `"Express shipping"`). */ readonly description: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "order_item"; /** @description The ID of the associated object for this line item. Expandable if not null (e.g., expandable to a SKU). */ readonly parent?: (Partial & Partial) | null; @@ -6555,7 +7027,10 @@ export interface components { readonly items: readonly components["schemas"]["order_item"][]; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "order_return"; /** @description The order that this return includes items from. */ readonly order?: (Partial & Partial) | null; @@ -6603,7 +7078,10 @@ export interface components { * @description Populated when `status` is `canceled`, this is the time at which the PaymentIntent was canceled. Measured in seconds since the Unix epoch. */ readonly canceled_at?: number | null; - /** @description Reason for cancellation of this PaymentIntent, either user-provided (`duplicate`, `fraudulent`, `requested_by_customer`, or `abandoned`) or generated by Stripe internally (`failed_invoice`, `void_invoice`, or `automatic`). */ + /** + * @description Reason for cancellation of this PaymentIntent, either user-provided (`duplicate`, `fraudulent`, `requested_by_customer`, or `abandoned`) or generated by Stripe internally (`failed_invoice`, `void_invoice`, or `automatic`). + * @enum {string|null} + */ readonly cancellation_reason?: | ( | "abandoned" @@ -6615,7 +7093,10 @@ export interface components { | "void_invoice" ) | null; - /** @description Controls when the funds will be captured from the customer's account. */ + /** + * @description Controls when the funds will be captured from the customer's account. + * @enum {string} + */ readonly capture_method: "automatic" | "manual"; /** * PaymentFlowsPaymentIntentResourceChargeList @@ -6626,7 +7107,10 @@ export interface components { readonly data: readonly components["schemas"]["charge"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -6639,6 +7123,7 @@ export interface components { * Refer to our docs to [accept a payment](https://stripe.com/docs/payments/accept-a-payment) and learn about how `client_secret` should be handled. */ readonly client_secret?: string | null; + /** @enum {string} */ readonly confirmation_method: "automatic" | "manual"; /** * Format: unix-time @@ -6673,7 +7158,10 @@ export interface components { readonly metadata?: { readonly [key: string]: string }; /** @description If present, this property tells you what actions you need to take in order for your customer to fulfill a payment using the provided source. */ readonly next_action?: Partial | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "payment_intent"; /** @description The account (if any) for which the funds of the PaymentIntent are intended. See the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts) for details. */ readonly on_behalf_of?: (Partial & Partial) | null; @@ -6693,6 +7181,7 @@ export interface components { * Providing this parameter will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any required actions from the user are complete. If no Customer was provided, the payment method can still be [attached](https://stripe.com/docs/api/payment_methods/attach) to a Customer after the transaction completes. * * When processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication). + * @enum {string|null} */ readonly setup_future_usage?: ("off_session" | "on_session") | null; /** @description Shipping information for this PaymentIntent. */ @@ -6701,7 +7190,10 @@ export interface components { readonly statement_descriptor?: string | null; /** @description Provides information about a card payment that customers see on their statements. Concatenated with the prefix (shortened descriptor) or statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 22 characters for the concatenated descriptor. */ readonly statement_descriptor_suffix?: string | null; - /** @description Status of this PaymentIntent, one of `requires_payment_method`, `requires_confirmation`, `requires_action`, `processing`, `requires_capture`, `canceled`, or `succeeded`. Read more about each PaymentIntent [status](https://stripe.com/docs/payments/intents#intent-statuses). */ + /** + * @description Status of this PaymentIntent, one of `requires_payment_method`, `requires_confirmation`, `requires_action`, `processing`, `requires_capture`, `canceled`, or `succeeded`. Read more about each PaymentIntent [status](https://stripe.com/docs/payments/intents#intent-statuses). + * @enum {string} + */ readonly status: | "canceled" | "processing" @@ -6742,7 +7234,10 @@ export interface components { * For more information, see the [installments integration guide](https://stripe.com/docs/payments/installments). */ readonly installments?: Partial | null; - /** @description We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Permitted values include: `automatic` or `any`. If not provided, defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine. */ + /** + * @description We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Permitted values include: `automatic` or `any`. If not provided, defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine. + * @enum {string|null} + */ readonly request_three_d_secure?: ("any" | "automatic" | "challenge_only") | null; }; /** @@ -6773,10 +7268,16 @@ export interface components { readonly livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "payment_method"; readonly sepa_debit?: components["schemas"]["payment_method_sepa_debit"]; - /** @description The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type. */ + /** + * @description The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type. + * @enum {string} + */ readonly type: "au_becs_debit" | "card" | "fpx" | "ideal" | "sepa_debit"; }; /** payment_method_au_becs_debit */ @@ -6840,7 +7341,10 @@ export interface components { readonly google_pay?: components["schemas"]["payment_method_card_wallet_google_pay"]; readonly masterpass?: components["schemas"]["payment_method_card_wallet_masterpass"]; readonly samsung_pay?: components["schemas"]["payment_method_card_wallet_samsung_pay"]; - /** @description The type of the card wallet, one of `amex_express_checkout`, `apple_pay`, `google_pay`, `masterpass`, `samsung_pay`, or `visa_checkout`. An additional hash is included on the Wallet subhash with a name matching this value. It contains additional information specific to the card wallet type. */ + /** + * @description The type of the card wallet, one of `amex_express_checkout`, `apple_pay`, `google_pay`, `masterpass`, `samsung_pay`, or `visa_checkout`. An additional hash is included on the Wallet subhash with a name matching this value. It contains additional information specific to the card wallet type. + * @enum {string} + */ readonly type: | "amex_express_checkout" | "apple_pay" @@ -6920,7 +7424,10 @@ export interface components { }; /** payment_method_details_ach_debit */ readonly payment_method_details_ach_debit: { - /** @description Type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description Type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string|null} + */ readonly account_holder_type?: ("company" | "individual") | null; /** @description Name of the bank associated with the bank account. */ readonly bank_name?: string | null; @@ -6959,6 +7466,7 @@ export interface components { /** * @description Preferred language of the Bancontact authorization page that the customer is redirected to. * Can be one of `en`, `de`, `fr`, or `nl` + * @enum {string|null} */ readonly preferred_language?: ("de" | "en" | "fr" | "nl") | null; /** @@ -7019,9 +7527,13 @@ export interface components { /** * @description For `fixed_count` installment plans, this is the interval between installment payments your customer will make to their credit card. * One of `month`. + * @enum {string|null} */ readonly interval?: "month" | null; - /** @description Type of installment plan, one of `fixed_count`. */ + /** + * @description Type of installment plan, one of `fixed_count`. + * @enum {string} + */ readonly type: "fixed_count"; }; /** payment_method_details_card_present */ @@ -7081,7 +7593,10 @@ export interface components { readonly google_pay?: components["schemas"]["payment_method_details_card_wallet_google_pay"]; readonly masterpass?: components["schemas"]["payment_method_details_card_wallet_masterpass"]; readonly samsung_pay?: components["schemas"]["payment_method_details_card_wallet_samsung_pay"]; - /** @description The type of the card wallet, one of `amex_express_checkout`, `apple_pay`, `google_pay`, `masterpass`, `samsung_pay`, or `visa_checkout`. An additional hash is included on the Wallet subhash with a name matching this value. It contains additional information specific to the card wallet type. */ + /** + * @description The type of the card wallet, one of `amex_express_checkout`, `apple_pay`, `google_pay`, `masterpass`, `samsung_pay`, or `visa_checkout`. An additional hash is included on the Wallet subhash with a name matching this value. It contains additional information specific to the card wallet type. + * @enum {string} + */ readonly type: | "amex_express_checkout" | "apple_pay" @@ -7131,7 +7646,10 @@ export interface components { }; /** payment_method_details_fpx */ readonly payment_method_details_fpx: { - /** @description The customer's bank. Can be one of `affin_bank`, `alliance_bank`, `ambank`, `bank_islam`, `bank_muamalat`, `bank_rakyat`, `bsn`, `cimb`, `hong_leong_bank`, `hsbc`, `kfh`, `maybank2u`, `ocbc`, `public_bank`, `rhb`, `standard_chartered`, `uob`, `deutsche_bank`, `maybank2e`, or `pb_enterprise`. */ + /** + * @description The customer's bank. Can be one of `affin_bank`, `alliance_bank`, `ambank`, `bank_islam`, `bank_muamalat`, `bank_rakyat`, `bsn`, `cimb`, `hong_leong_bank`, `hsbc`, `kfh`, `maybank2u`, `ocbc`, `public_bank`, `rhb`, `standard_chartered`, `uob`, `deutsche_bank`, `maybank2e`, or `pb_enterprise`. + * @enum {string} + */ readonly bank: | "affin_bank" | "alliance_bank" @@ -7172,7 +7690,10 @@ export interface components { }; /** payment_method_details_ideal */ readonly payment_method_details_ideal: { - /** @description The customer's bank. Can be one of `abn_amro`, `asn_bank`, `bunq`, `handelsbanken`, `ing`, `knab`, `moneyou`, `rabobank`, `regiobank`, `sns_bank`, `triodos_bank`, or `van_lanschot`. */ + /** + * @description The customer's bank. Can be one of `abn_amro`, `asn_bank`, `bunq`, `handelsbanken`, `ing`, `knab`, `moneyou`, `rabobank`, `regiobank`, `sns_bank`, `triodos_bank`, or `van_lanschot`. + * @enum {string|null} + */ readonly bank?: | ( | "abn_amro" @@ -7189,7 +7710,10 @@ export interface components { | "van_lanschot" ) | null; - /** @description The Bank Identifier Code of the customer's bank. */ + /** + * @description The Bank Identifier Code of the customer's bank. + * @enum {string|null} + */ readonly bic?: | ( | "ABNANL2A" @@ -7272,7 +7796,10 @@ export interface components { readonly payment_method_details_wechat: { readonly [key: string]: unknown }; /** payment_method_fpx */ readonly payment_method_fpx: { - /** @description The customer's bank, if provided. Can be one of `affin_bank`, `alliance_bank`, `ambank`, `bank_islam`, `bank_muamalat`, `bank_rakyat`, `bsn`, `cimb`, `hong_leong_bank`, `hsbc`, `kfh`, `maybank2u`, `ocbc`, `public_bank`, `rhb`, `standard_chartered`, `uob`, `deutsche_bank`, `maybank2e`, or `pb_enterprise`. */ + /** + * @description The customer's bank, if provided. Can be one of `affin_bank`, `alliance_bank`, `ambank`, `bank_islam`, `bank_muamalat`, `bank_rakyat`, `bsn`, `cimb`, `hong_leong_bank`, `hsbc`, `kfh`, `maybank2u`, `ocbc`, `public_bank`, `rhb`, `standard_chartered`, `uob`, `deutsche_bank`, `maybank2e`, or `pb_enterprise`. + * @enum {string} + */ readonly bank: | "affin_bank" | "alliance_bank" @@ -7297,7 +7824,10 @@ export interface components { }; /** payment_method_ideal */ readonly payment_method_ideal: { - /** @description The customer's bank, if provided. Can be one of `abn_amro`, `asn_bank`, `bunq`, `handelsbanken`, `ing`, `knab`, `moneyou`, `rabobank`, `regiobank`, `sns_bank`, `triodos_bank`, or `van_lanschot`. */ + /** + * @description The customer's bank, if provided. Can be one of `abn_amro`, `asn_bank`, `bunq`, `handelsbanken`, `ing`, `knab`, `moneyou`, `rabobank`, `regiobank`, `sns_bank`, `triodos_bank`, or `van_lanschot`. + * @enum {string|null} + */ readonly bank?: | ( | "abn_amro" @@ -7314,7 +7844,10 @@ export interface components { | "van_lanschot" ) | null; - /** @description The Bank Identifier Code of the customer's bank, if the bank was provided. */ + /** + * @description The Bank Identifier Code of the customer's bank, if the bank was provided. + * @enum {string|null} + */ readonly bic?: | ( | "ABNANL2A" @@ -7665,7 +8198,10 @@ export interface components { readonly metadata: { readonly [key: string]: string }; /** @description The method used to send this payout, which can be `standard` or `instant`. `instant` is only supported for payouts to debit cards. (See [Instant payouts for marketplaces](https://stripe.com/blog/instant-payouts-for-marketplaces) for more information.) */ readonly method: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "payout"; /** @description The source balance this payout came from. One of `card`, `fpx`, or `bank_account`. */ readonly source_type: string; @@ -7673,7 +8209,10 @@ export interface components { readonly statement_descriptor?: string | null; /** @description Current status of the payout: `paid`, `pending`, `in_transit`, `canceled` or `failed`. A payout is `pending` until it is submitted to the bank, when it becomes `in_transit`. The status then changes to `paid` if the transaction goes through, or to `failed` or `canceled` (within 5 business days). Some failed payouts may initially show as `paid` but then change to `failed`. */ readonly status: string; - /** @description Can be `bank_account` or `card`. */ + /** + * @description Can be `bank_account` or `card`. + * @enum {string} + */ readonly type: "bank_account" | "card"; }; /** Period */ @@ -7720,7 +8259,10 @@ export interface components { readonly maiden_name?: string | null; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata?: { readonly [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "person"; readonly phone?: string | null; readonly relationship?: components["schemas"]["person_relationship"]; @@ -7768,7 +8310,10 @@ export interface components { readonly plan: { /** @description Whether the plan can be used for new purchases. */ readonly active: boolean; - /** @description Specifies a usage aggregation strategy for plans of `usage_type=metered`. Allowed values are `sum` for summing up all usage during a period, `last_during_period` for using the last usage record reported within a period, `last_ever` for using the last usage record ever (across period bounds) or `max` which uses the usage record with the maximum reported usage during a period. Defaults to `sum`. */ + /** + * @description Specifies a usage aggregation strategy for plans of `usage_type=metered`. Allowed values are `sum` for summing up all usage during a period, `last_during_period` for using the last usage record reported within a period, `last_ever` for using the last usage record ever (across period bounds) or `max` which uses the usage record with the maximum reported usage during a period. Defaults to `sum`. + * @enum {string|null} + */ readonly aggregate_usage?: ("last_during_period" | "last_ever" | "max" | "sum") | null; /** @description The amount in %s to be charged on the interval specified. */ readonly amount?: number | null; @@ -7777,7 +8322,10 @@ export interface components { * @description Same as `amount`, but contains a decimal value with at most 12 decimal places. */ readonly amount_decimal?: string | null; - /** @description Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `amount`) will be charged per unit in `quantity` (for plans with `usage_type=licensed`), or per unit of total usage (for plans with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes. */ + /** + * @description Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `amount`) will be charged per unit in `quantity` (for plans with `usage_type=licensed`), or per unit of total usage (for plans with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes. + * @enum {string} + */ readonly billing_scheme: "per_unit" | "tiered"; /** * Format: unix-time @@ -7788,7 +8336,10 @@ export interface components { readonly currency: string; /** @description Unique identifier for the object. */ readonly id: string; - /** @description The frequency at which a subscription is billed. One of `day`, `week`, `month` or `year`. */ + /** + * @description The frequency at which a subscription is billed. One of `day`, `week`, `month` or `year`. + * @enum {string} + */ readonly interval: "day" | "month" | "week" | "year"; /** @description The number of intervals (specified in the `interval` attribute) between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. */ readonly interval_count: number; @@ -7798,7 +8349,10 @@ export interface components { readonly metadata: { readonly [key: string]: string }; /** @description A brief description of the plan, hidden from customers. */ readonly nickname?: string | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "plan"; /** @description The product whose pricing this plan determines. */ readonly product?: @@ -7808,13 +8362,19 @@ export interface components { | null; /** @description Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`. */ readonly tiers?: readonly components["schemas"]["plan_tier"][] | null; - /** @description Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price. In `graduated` tiering, pricing can change as the quantity grows. */ + /** + * @description Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price. In `graduated` tiering, pricing can change as the quantity grows. + * @enum {string|null} + */ readonly tiers_mode?: ("graduated" | "volume") | null; /** @description Apply a transformation to the reported usage or set quantity before computing the amount billed. Cannot be combined with `tiers`. */ readonly transform_usage?: Partial | null; /** @description Default number of trial days when subscribing a customer to this plan using [`trial_from_plan=true`](https://stripe.com/docs/api#create_subscription-trial_from_plan). */ readonly trial_period_days?: number | null; - /** @description Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`. */ + /** + * @description Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`. + * @enum {string} + */ readonly usage_type: "licensed" | "metered"; }; /** PlanTier */ @@ -7842,7 +8402,10 @@ export interface components { readonly account: string; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "platform_tax_fee"; /** @description The payment object that caused this tax to be inflicted. */ readonly source_transaction: string; @@ -7886,7 +8449,10 @@ export interface components { readonly metadata: { readonly [key: string]: string }; /** @description The product's name, meant to be displayable to the customer. Whenever this product is sold via a subscription, name will show up on associated invoice line item descriptions. */ readonly name: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "product"; /** @description The dimensions of this product for shipping purposes. A SKU associated with this product can override this value by having its own `package_dimensions`. Only applicable to products of `type=good`. */ readonly package_dimensions?: Partial | null; @@ -7894,7 +8460,10 @@ export interface components { readonly shippable?: boolean | null; /** @description Extra information about a product which will appear on your customer's credit card statement. In the case that multiple products are billed at once, the first statement descriptor will be used. */ readonly statement_descriptor?: string | null; - /** @description The type of the product. The product is either of type `good`, which is eligible for use with Orders and SKUs, or `service`, which is eligible for use with Subscriptions and Plans. */ + /** + * @description The type of the product. The product is either of type `good`, which is eligible for use with Orders and SKUs, or `service`, which is eligible for use with Subscriptions and Plans. + * @enum {string} + */ readonly type: "good" | "service"; /** @description A label that represents units of this product in Stripe and on customers’ receipts and invoices. When set, this will be included in associated invoice line item descriptions. */ readonly unit_label?: string | null; @@ -7929,7 +8498,10 @@ export interface components { readonly id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "radar.early_fraud_warning"; }; /** @@ -7950,7 +8522,10 @@ export interface components { readonly created_by: string; /** @description Unique identifier for the object. */ readonly id: string; - /** @description The type of items in the value list. One of `card_fingerprint`, `card_bin`, `email`, `ip_address`, `country`, `string`, or `case_sensitive_string`. */ + /** + * @description The type of items in the value list. One of `card_fingerprint`, `card_bin`, `email`, `ip_address`, `country`, `string`, or `case_sensitive_string`. + * @enum {string} + */ readonly item_type: | "card_bin" | "card_fingerprint" @@ -7968,7 +8543,10 @@ export interface components { readonly data: readonly components["schemas"]["radar.value_list_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -7979,7 +8557,10 @@ export interface components { readonly metadata: { readonly [key: string]: string }; /** @description The name of the value list. */ readonly name: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "radar.value_list"; }; /** @@ -8000,7 +8581,10 @@ export interface components { readonly id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "radar.value_list_item"; /** @description The value of the item. */ readonly value: string; @@ -8053,7 +8637,10 @@ export interface components { readonly data: readonly components["schemas"]["card"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -8078,7 +8665,10 @@ export interface components { readonly migrated_to?: (Partial & Partial) | null; /** @description Full, legal name of the recipient. */ readonly name?: string | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "recipient"; readonly rolled_back_from?: Partial & Partial; /** @description Type of the recipient, one of `individual` or `corporation`. */ @@ -8116,7 +8706,10 @@ export interface components { readonly id: string; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "refund"; /** @description ID of the PaymentIntent that was refunded. */ readonly payment_intent?: (Partial & Partial) | null; @@ -8160,7 +8753,10 @@ export interface components { readonly id: string; /** @description Always `true`: reports can only be run on live-mode data. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "reporting.report_run"; readonly parameters: components["schemas"]["financial_reporting_finance_report_run_run_parameters"]; /** @description The ID of the [report type](https://stripe.com/docs/reporting/statements/api#report-types) to run, such as `"balance.summary.1"`. */ @@ -8212,7 +8808,10 @@ export interface components { readonly id: string; /** @description Human-readable name of the Report Type */ readonly name: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "reporting.report_type"; /** * Format: unix-time @@ -8231,7 +8830,10 @@ export interface components { readonly description?: string | null; /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "reserve_transaction"; }; /** @@ -8246,7 +8848,10 @@ export interface components { readonly billing_zip?: string | null; /** @description The charge associated with this review. */ readonly charge?: (Partial & Partial) | null; - /** @description The reason the review was closed, or null if it has not yet been closed. One of `approved`, `refunded`, `refunded_as_fraud`, or `disputed`. */ + /** + * @description The reason the review was closed, or null if it has not yet been closed. One of `approved`, `refunded`, `refunded_as_fraud`, or `disputed`. + * @enum {string|null} + */ readonly closed_reason?: ("approved" | "disputed" | "refunded" | "refunded_as_fraud") | null; /** * Format: unix-time @@ -8261,11 +8866,17 @@ export interface components { readonly ip_address_location?: Partial | null; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "review"; /** @description If `true`, the review needs action. */ readonly open: boolean; - /** @description The reason the review was opened. One of `rule` or `manual`. */ + /** + * @description The reason the review was opened. One of `rule` or `manual`. + * @enum {string} + */ readonly opened_reason: "manual" | "rule"; /** @description The PaymentIntent ID associated with this review, if one exists. */ readonly payment_intent?: Partial & Partial; @@ -8308,7 +8919,10 @@ export interface components { readonly id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "scheduled_query_run"; /** * Format: unix-time @@ -8350,7 +8964,10 @@ export interface components { readonly setup_intent: { /** @description ID of the Connect application that created the SetupIntent. */ readonly application?: (Partial & Partial) | null; - /** @description Reason for cancellation of this SetupIntent, one of `abandoned`, `requested_by_customer`, or `duplicate`. */ + /** + * @description Reason for cancellation of this SetupIntent, one of `abandoned`, `requested_by_customer`, or `duplicate`. + * @enum {string|null} + */ readonly cancellation_reason?: ("abandoned" | "duplicate" | "requested_by_customer") | null; /** * @description The client secret of this SetupIntent. Used for client-side retrieval using a publishable key. @@ -8387,7 +9004,10 @@ export interface components { readonly metadata?: { readonly [key: string]: string }; /** @description If present, this property tells you what actions you need to take in order for your customer to continue payment setup. */ readonly next_action?: Partial | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "setup_intent"; /** @description The account (if any) for which the setup is intended. */ readonly on_behalf_of?: (Partial & Partial) | null; @@ -8399,7 +9019,10 @@ export interface components { readonly payment_method_types: readonly string[]; /** @description ID of the single_use Mandate generated by the SetupIntent. */ readonly single_use_mandate?: (Partial & Partial) | null; - /** @description [Status](https://stripe.com/docs/payments/intents#intent-statuses) of this SetupIntent, one of `requires_payment_method`, `requires_confirmation`, `requires_action`, `processing`, `canceled`, or `succeeded`. */ + /** + * @description [Status](https://stripe.com/docs/payments/intents#intent-statuses) of this SetupIntent, one of `requires_payment_method`, `requires_confirmation`, `requires_action`, `processing`, `canceled`, or `succeeded`. + * @enum {string} + */ readonly status: | "canceled" | "processing" @@ -8435,7 +9058,10 @@ export interface components { }; /** setup_intent_payment_method_options_card */ readonly setup_intent_payment_method_options_card: { - /** @description We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Permitted values include: `automatic` or `any`. If not provided, defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine. */ + /** + * @description We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Permitted values include: `automatic` or `any`. If not provided, defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine. + * @enum {string|null} + */ readonly request_three_d_secure?: ("any" | "automatic" | "challenge_only") | null; }; /** Shipping */ @@ -8500,7 +9126,10 @@ export interface components { readonly livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "sku"; /** @description The dimensions of this SKU for shipping purposes. */ readonly package_dimensions?: Partial | null; @@ -8558,7 +9187,10 @@ export interface components { /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata?: { readonly [key: string]: string } | null; readonly multibanco?: components["schemas"]["source_type_multibanco"]; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "source"; /** @description Information about the owner of the payment instrument that may be used or required by particular source types. */ readonly owner?: Partial | null; @@ -8573,7 +9205,10 @@ export interface components { /** @description The status of the source, one of `canceled`, `chargeable`, `consumed`, `failed`, or `pending`. Only `chargeable` sources can be used to create a charge. */ readonly status: string; readonly three_d_secure?: components["schemas"]["source_type_three_d_secure"]; - /** @description The `type` of the source. The `type` is a payment method, one of `ach_credit_transfer`, `ach_debit`, `alipay`, `bancontact`, `card`, `card_present`, `eps`, `giropay`, `ideal`, `multibanco`, `klarna`, `p24`, `sepa_debit`, `sofort`, `three_d_secure`, or `wechat`. An additional hash is included on the source with a name matching this value. It contains additional information specific to the [payment method](https://stripe.com/docs/sources) used. */ + /** + * @description The `type` of the source. The `type` is a payment method, one of `ach_credit_transfer`, `ach_debit`, `alipay`, `bancontact`, `card`, `card_present`, `eps`, `giropay`, `ideal`, `multibanco`, `klarna`, `p24`, `sepa_debit`, `sofort`, `three_d_secure`, or `wechat`. An additional hash is included on the source with a name matching this value. It contains additional information specific to the [payment method](https://stripe.com/docs/sources) used. + * @enum {string} + */ readonly type: | "ach_credit_transfer" | "ach_debit" @@ -8622,7 +9257,10 @@ export interface components { readonly id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "source_mandate_notification"; /** @description The reason of the mandate notification. Valid reasons are `mandate_confirmed` or `debit_initiated`. */ readonly reason: string; @@ -8741,7 +9379,10 @@ export interface components { readonly id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "source_transaction"; readonly paper_check?: components["schemas"]["source_transaction_paper_check_data"]; readonly sepa_credit_transfer?: components["schemas"]["source_transaction_sepa_credit_transfer_data"]; @@ -8749,7 +9390,10 @@ export interface components { readonly source: string; /** @description The status of the transaction, one of `succeeded`, `pending`, or `failed`. */ readonly status: string; - /** @description The type of source this transaction is attached to. */ + /** + * @description The type of source this transaction is attached to. + * @enum {string} + */ readonly type: | "ach_credit_transfer" | "ach_debit" @@ -9053,7 +9697,10 @@ export interface components { * @description If the subscription has been canceled, the date of that cancellation. If the subscription was canceled with `cancel_at_period_end`, `canceled_at` will still reflect the date of the initial cancellation request, not the end of the subscription period when the subscription is automatically moved to a canceled state. */ readonly canceled_at?: number | null; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. + * @enum {string|null} + */ readonly collection_method?: ("charge_automatically" | "send_invoice") | null; /** * Format: unix-time @@ -9107,7 +9754,10 @@ export interface components { readonly data: readonly components["schemas"]["subscription_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -9123,7 +9773,10 @@ export interface components { * @description Specifies the approximate timestamp on which any pending invoice items will be billed according to the schedule provided at `pending_invoice_item_interval`. */ readonly next_pending_invoice_item_invoice?: number | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "subscription"; /** @description If specified, payment collection for this subscription will be paused. */ readonly pause_collection?: Partial | null; @@ -9156,6 +9809,7 @@ export interface components { * If subscription `collection_method=charge_automatically` it becomes `past_due` when payment to renew it fails and `canceled` or `unpaid` (depending on your subscriptions settings) when Stripe has exhausted all payment retry attempts. * * If subscription `collection_method=send_invoice` it becomes `past_due` when its invoice is not paid by the due date, and `canceled` or `unpaid` if it is still not paid by an additional deadline after that. Note that when a subscription has a status of `unpaid`, no subsequent invoices will be attempted (invoices will be created, but then immediately automatically closed). After receiving updated payment information from a customer, you may choose to reopen and pay their closed invoices. + * @enum {string} */ readonly status: "active" | "canceled" | "incomplete" | "incomplete_expired" | "past_due" | "trialing" | "unpaid"; /** @description If provided, each invoice created by this subscription will apply the tax rate, increasing the amount billed to the customer. */ @@ -9192,7 +9846,10 @@ export interface components { readonly id: string; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "subscription_item"; readonly plan: components["schemas"]["plan"]; /** @description The [quantity](https://stripe.com/docs/subscriptions/quantities) of the plan to which the customer should be subscribed. */ @@ -9209,7 +9866,10 @@ export interface components { }; /** SubscriptionPendingInvoiceItemInterval */ readonly subscription_pending_invoice_item_interval: { - /** @description Specifies invoicing frequency. Either `day`, `week`, `month` or `year`. */ + /** + * @description Specifies invoicing frequency. Either `day`, `week`, `month` or `year`. + * @enum {string} + */ readonly interval: "day" | "month" | "week" | "year"; /** @description The number of intervals between invoices. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). */ readonly interval_count: number; @@ -9243,7 +9903,10 @@ export interface components { Partial & Partial; readonly default_settings: components["schemas"]["subscription_schedules_resource_default_settings"]; - /** @description Behavior of the subscription schedule and underlying subscription when it ends. */ + /** + * @description Behavior of the subscription schedule and underlying subscription when it ends. + * @enum {string} + */ readonly end_behavior: "cancel" | "none" | "release" | "renew"; /** @description Unique identifier for the object. */ readonly id: string; @@ -9251,7 +9914,10 @@ export interface components { readonly livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata?: { readonly [key: string]: string } | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "subscription_schedule"; /** @description Configuration for the subscription schedule's phases. */ readonly phases: readonly components["schemas"]["subscription_schedule_phase_configuration"][]; @@ -9262,7 +9928,10 @@ export interface components { readonly released_at?: number | null; /** @description ID of the subscription once managed by the subscription schedule (if it is released). */ readonly released_subscription?: string | null; - /** @description The present status of the subscription schedule. Possible values are `not_started`, `active`, `completed`, `released`, and `canceled`. You can read more about the different states in our [behavior guide](https://stripe.com/docs/billing/subscriptions/subscription-schedules). */ + /** + * @description The present status of the subscription schedule. Possible values are `not_started`, `active`, `completed`, `released`, and `canceled`. You can read more about the different states in our [behavior guide](https://stripe.com/docs/billing/subscriptions/subscription-schedules). + * @enum {string} + */ readonly status: "active" | "canceled" | "completed" | "not_started" | "released"; /** @description ID of the subscription managed by the subscription schedule. */ readonly subscription?: (Partial & Partial) | null; @@ -9305,7 +9974,10 @@ export interface components { readonly application_fee_percent?: number | null; /** @description Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period */ readonly billing_thresholds?: Partial | null; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. + * @enum {string|null} + */ readonly collection_method?: ("charge_automatically" | "send_invoice") | null; /** @description ID of the coupon to use during this phase of the subscription schedule. */ readonly coupon?: @@ -9328,7 +10000,10 @@ export interface components { > | null; /** @description Plans to subscribe during this phase of the subscription schedule. */ readonly plans: readonly components["schemas"]["subscription_schedule_configuration_item"][]; - /** @description Controls whether or not the subscription schedule will prorate when transitioning to this phase. Values are `create_prorations` and `none`. */ + /** + * @description Controls whether or not the subscription schedule will prorate when transitioning to this phase. Values are `create_prorations` and `none`. + * @enum {string|null} + */ readonly proration_behavior?: ("always_invoice" | "create_prorations" | "none") | null; /** * Format: unix-time @@ -9347,7 +10022,10 @@ export interface components { readonly subscription_schedules_resource_default_settings: { /** @description Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period */ readonly billing_thresholds?: Partial | null; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. + * @enum {string|null} + */ readonly collection_method?: ("charge_automatically" | "send_invoice") | null; /** @description ID of the default payment method for the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings. */ readonly default_payment_method?: (Partial & Partial) | null; @@ -9362,7 +10040,10 @@ export interface components { * should be paused. */ readonly subscriptions_resource_pause_collection: { - /** @description The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`. */ + /** + * @description The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`. + * @enum {string} + */ readonly behavior: "keep_as_draft" | "mark_uncollectible" | "void"; /** * Format: unix-time @@ -9400,7 +10081,10 @@ export interface components { readonly tax_deducted_at_source: { /** @description Unique identifier for the object. */ readonly id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "tax_deducted_at_source"; /** * Format: unix-time @@ -9436,9 +10120,15 @@ export interface components { readonly id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "tax_id"; - /** @description Type of the tax ID, one of `au_abn`, `ca_bn`, `ca_qst`, `ch_vat`, `es_cif`, `eu_vat`, `hk_br`, `in_gst`, `jp_cn`, `kr_brn`, `li_uid`, `mx_rfc`, `my_itn`, `my_sst`, `no_vat`, `nz_gst`, `ru_inn`, `sg_gst`, `sg_uen`, `th_vat`, `tw_vat`, `us_ein`, or `za_vat`. Note that some legacy tax IDs have type `unknown` */ + /** + * @description Type of the tax ID, one of `au_abn`, `ca_bn`, `ca_qst`, `ch_vat`, `es_cif`, `eu_vat`, `hk_br`, `in_gst`, `jp_cn`, `kr_brn`, `li_uid`, `mx_rfc`, `my_itn`, `my_sst`, `no_vat`, `nz_gst`, `ru_inn`, `sg_gst`, `sg_uen`, `th_vat`, `tw_vat`, `us_ein`, or `za_vat`. Note that some legacy tax IDs have type `unknown` + * @enum {string} + */ readonly type: | "au_abn" | "ca_bn" @@ -9470,7 +10160,10 @@ export interface components { }; /** tax_id_verification */ readonly tax_id_verification: { - /** @description Verification status, one of `pending`, `verified`, `unverified`, or `unavailable`. */ + /** + * @description Verification status, one of `pending`, `verified`, `unverified`, or `unavailable`. + * @enum {string} + */ readonly status: "pending" | "unavailable" | "unverified" | "verified"; /** @description Verified address. */ readonly verified_address?: string | null; @@ -9505,7 +10198,10 @@ export interface components { readonly livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "tax_rate"; /** @description This represents the tax rate percent out of 100. */ readonly percentage: number; @@ -9519,7 +10215,10 @@ export interface components { readonly "terminal.connection_token": { /** @description The id of the location that this connection token is scoped to. */ readonly location?: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "terminal.connection_token"; /** @description Your application should pass this token to the Stripe Terminal SDK. */ readonly secret: string; @@ -9540,7 +10239,10 @@ export interface components { readonly livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "terminal.location"; }; /** @@ -9552,7 +10254,10 @@ export interface components { readonly "terminal.reader": { /** @description The current software version of the reader. */ readonly device_sw_version?: string | null; - /** @description Type of reader, one of `bbpos_chipper2x` or `verifone_P400`. */ + /** + * @description Type of reader, one of `bbpos_chipper2x` or `verifone_P400`. + * @enum {string} + */ readonly device_type: "bbpos_chipper2x" | "verifone_P400"; /** @description Unique identifier for the object. */ readonly id: string; @@ -9566,7 +10271,10 @@ export interface components { readonly location?: string | null; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "terminal.reader"; /** @description Serial number of the reader. */ readonly serial_number: string; @@ -9596,7 +10304,10 @@ export interface components { readonly id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "three_d_secure"; /** @description If present, this is the URL that you should send the cardholder to for authentication. If you are going to use Stripe.js to display the authentication page in an iframe, you should use the value "_callback". */ readonly redirect_url?: string | null; @@ -9656,7 +10367,10 @@ export interface components { readonly id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "token"; /** @description Type of the token: `account`, `bank_account`, `card`, or `pii`. */ readonly type: string; @@ -9697,12 +10411,18 @@ export interface components { readonly livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "topup"; readonly source: components["schemas"]["source"]; /** @description Extra information about a top-up. This will appear on your source's bank statement. It must contain at least one letter. */ readonly statement_descriptor?: string | null; - /** @description The status of the top-up is either `canceled`, `failed`, `pending`, `reversed`, or `succeeded`. */ + /** + * @description The status of the top-up is either `canceled`, `failed`, `pending`, `reversed`, or `succeeded`. + * @enum {string} + */ readonly status: "canceled" | "failed" | "pending" | "reversed" | "succeeded"; /** @description A string that identifies this top-up as part of a group. */ readonly transfer_group?: string | null; @@ -9746,7 +10466,10 @@ export interface components { readonly livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "transfer"; /** * TransferReversalList @@ -9757,7 +10480,10 @@ export interface components { readonly data: readonly components["schemas"]["transfer_reversal"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -9816,7 +10542,10 @@ export interface components { readonly id: string; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "transfer_reversal"; /** @description ID of the refund responsible for the transfer reversal. */ readonly source_refund?: (Partial & Partial) | null; @@ -9838,7 +10567,10 @@ export interface components { readonly transform_usage: { /** @description Divide usage by this number. */ readonly divide_by: number; - /** @description After division, either round the result `up` or `down`. */ + /** + * @description After division, either round the result `up` or `down`. + * @enum {string} + */ readonly round: "down" | "up"; }; /** @@ -9853,7 +10585,10 @@ export interface components { readonly id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "usage_record"; /** @description The usage quantity for the specified date. */ readonly quantity: number; @@ -9873,7 +10608,10 @@ export interface components { readonly invoice?: string | null; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ readonly livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "usage_record_summary"; readonly period: components["schemas"]["period"]; /** @description The ID of the subscription item this summary is describing. */ @@ -9911,7 +10649,10 @@ export interface components { readonly livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ readonly metadata: { readonly [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ readonly object: "webhook_endpoint"; /** @description The endpoint's secret, used to generate [webhook signatures](https://stripe.com/docs/webhooks/signatures). Only returned at creation. */ readonly secret?: string; @@ -10046,10 +10787,12 @@ export interface operations { /** @description Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js), or a dictionary containing a user's bank account details. */ readonly bank_account?: Partial<{ readonly account_holder_name?: string; + /** @enum {string} */ readonly account_holder_type?: "company" | "individual"; readonly account_number: string; readonly country: string; readonly currency?: string; + /** @enum {string} */ readonly object?: "bank_account"; readonly routing_number?: string; }> & @@ -10067,7 +10810,10 @@ export interface operations { readonly support_url?: string; readonly url?: string; }; - /** @description The business type. */ + /** + * @description The business type. + * @enum {string} + */ readonly business_type?: "company" | "government_entity" | "individual" | "non_profit"; /** * company_specs @@ -10110,6 +10856,7 @@ export interface operations { readonly name_kanji?: string; readonly owners_provided?: boolean; readonly phone?: string; + /** @enum {string} */ readonly structure?: | "" | "government_instrumentality" @@ -10259,8 +11006,10 @@ export interface operations { /** transfer_schedule_specs */ readonly schedule?: { readonly delay_days?: Partial<"minimum"> & Partial; + /** @enum {string} */ readonly interval?: "daily" | "manual" | "monthly" | "weekly"; readonly monthly_anchor?: number; + /** @enum {string} */ readonly weekly_anchor?: | "friday" | "monday" @@ -10339,10 +11088,12 @@ export interface operations { /** @description Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js), or a dictionary containing a user's bank account details. */ readonly bank_account?: Partial<{ readonly account_holder_name?: string; + /** @enum {string} */ readonly account_holder_type?: "company" | "individual"; readonly account_number: string; readonly country: string; readonly currency?: string; + /** @enum {string} */ readonly object?: "bank_account"; readonly routing_number?: string; }> & @@ -10419,7 +11170,10 @@ export interface operations { readonly "application/x-www-form-urlencoded": { /** @description The name of the person or business that owns the bank account. */ readonly account_holder_name?: string; - /** @description The type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description The type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string} + */ readonly account_holder_type?: "" | "company" | "individual"; /** @description City/District/Suburb/Town/Village. */ readonly address_city?: string; @@ -10492,7 +11246,10 @@ export interface operations { readonly data: readonly components["schemas"]["capability"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -10599,7 +11356,10 @@ export interface operations { Partial)[]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -10641,10 +11401,12 @@ export interface operations { /** @description Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js), or a dictionary containing a user's bank account details. */ readonly bank_account?: Partial<{ readonly account_holder_name?: string; + /** @enum {string} */ readonly account_holder_type?: "company" | "individual"; readonly account_number: string; readonly country: string; readonly currency?: string; + /** @enum {string} */ readonly object?: "bank_account"; readonly routing_number?: string; }> & @@ -10721,7 +11483,10 @@ export interface operations { readonly "application/x-www-form-urlencoded": { /** @description The name of the person or business that owns the bank account. */ readonly account_holder_name?: string; - /** @description The type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description The type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string} + */ readonly account_holder_type?: "" | "company" | "individual"; /** @description City/District/Suburb/Town/Village. */ readonly address_city?: string; @@ -10869,7 +11634,10 @@ export interface operations { readonly data: readonly components["schemas"]["person"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -11235,7 +12003,10 @@ export interface operations { readonly data: readonly components["schemas"]["person"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -11593,7 +12364,10 @@ export interface operations { readonly "application/x-www-form-urlencoded": { /** @description The identifier of the account to create an account link for. */ readonly account: string; - /** @description Which information the platform needs to collect from the user. One of `currently_due` or `eventually_due`. Default is `currently_due`. */ + /** + * @description Which information the platform needs to collect from the user. One of `currently_due` or `eventually_due`. Default is `currently_due`. + * @enum {string} + */ readonly collect?: "currently_due" | "eventually_due"; /** @description Specifies which fields in the response should be expanded. */ readonly expand?: readonly string[]; @@ -11601,7 +12375,10 @@ export interface operations { readonly failure_url: string; /** @description The URL that the user will be redirected to upon leaving or completing the linked flow successfully. */ readonly success_url: string; - /** @description The type of account link the user is requesting. Possible values are `custom_account_verification` or `custom_account_update`. */ + /** + * @description The type of account link the user is requesting. Possible values are `custom_account_verification` or `custom_account_update`. + * @enum {string} + */ readonly type: "custom_account_update" | "custom_account_verification"; }; }; @@ -11636,7 +12413,10 @@ export interface operations { readonly data: readonly components["schemas"]["account"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -11686,10 +12466,12 @@ export interface operations { /** @description Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js), or a dictionary containing a user's bank account details. */ readonly bank_account?: Partial<{ readonly account_holder_name?: string; + /** @enum {string} */ readonly account_holder_type?: "company" | "individual"; readonly account_number: string; readonly country: string; readonly currency?: string; + /** @enum {string} */ readonly object?: "bank_account"; readonly routing_number?: string; }> & @@ -11707,7 +12489,10 @@ export interface operations { readonly support_url?: string; readonly url?: string; }; - /** @description The business type. */ + /** + * @description The business type. + * @enum {string} + */ readonly business_type?: "company" | "government_entity" | "individual" | "non_profit"; /** * company_specs @@ -11750,6 +12535,7 @@ export interface operations { readonly name_kanji?: string; readonly owners_provided?: boolean; readonly phone?: string; + /** @enum {string} */ readonly structure?: | "" | "government_instrumentality" @@ -11901,8 +12687,10 @@ export interface operations { /** transfer_schedule_specs */ readonly schedule?: { readonly delay_days?: Partial<"minimum"> & Partial; + /** @enum {string} */ readonly interval?: "daily" | "manual" | "monthly" | "weekly"; readonly monthly_anchor?: number; + /** @enum {string} */ readonly weekly_anchor?: | "friday" | "monday" @@ -11925,7 +12713,10 @@ export interface operations { readonly ip?: string; readonly user_agent?: string; }; - /** @description The type of Stripe account to create. Currently must be `custom`, as only [Custom accounts](https://stripe.com/docs/connect/custom-accounts) may be created via the API. */ + /** + * @description The type of Stripe account to create. Currently must be `custom`, as only [Custom accounts](https://stripe.com/docs/connect/custom-accounts) may be created via the API. + * @enum {string} + */ readonly type?: "custom" | "express" | "standard"; }; }; @@ -11995,10 +12786,12 @@ export interface operations { /** @description Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js), or a dictionary containing a user's bank account details. */ readonly bank_account?: Partial<{ readonly account_holder_name?: string; + /** @enum {string} */ readonly account_holder_type?: "company" | "individual"; readonly account_number: string; readonly country: string; readonly currency?: string; + /** @enum {string} */ readonly object?: "bank_account"; readonly routing_number?: string; }> & @@ -12016,7 +12809,10 @@ export interface operations { readonly support_url?: string; readonly url?: string; }; - /** @description The business type. */ + /** + * @description The business type. + * @enum {string} + */ readonly business_type?: "company" | "government_entity" | "individual" | "non_profit"; /** * company_specs @@ -12059,6 +12855,7 @@ export interface operations { readonly name_kanji?: string; readonly owners_provided?: boolean; readonly phone?: string; + /** @enum {string} */ readonly structure?: | "" | "government_instrumentality" @@ -12208,8 +13005,10 @@ export interface operations { /** transfer_schedule_specs */ readonly schedule?: { readonly delay_days?: Partial<"minimum"> & Partial; + /** @enum {string} */ readonly interval?: "daily" | "manual" | "monthly" | "weekly"; readonly monthly_anchor?: number; + /** @enum {string} */ readonly weekly_anchor?: | "friday" | "monday" @@ -12296,10 +13095,12 @@ export interface operations { /** @description Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js), or a dictionary containing a user's bank account details. */ readonly bank_account?: Partial<{ readonly account_holder_name?: string; + /** @enum {string} */ readonly account_holder_type?: "company" | "individual"; readonly account_number: string; readonly country: string; readonly currency?: string; + /** @enum {string} */ readonly object?: "bank_account"; readonly routing_number?: string; }> & @@ -12378,7 +13179,10 @@ export interface operations { readonly "application/x-www-form-urlencoded": { /** @description The name of the person or business that owns the bank account. */ readonly account_holder_name?: string; - /** @description The type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description The type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string} + */ readonly account_holder_type?: "" | "company" | "individual"; /** @description City/District/Suburb/Town/Village. */ readonly address_city?: string; @@ -12455,7 +13259,10 @@ export interface operations { readonly data: readonly components["schemas"]["capability"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -12567,7 +13374,10 @@ export interface operations { Partial)[]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -12614,10 +13424,12 @@ export interface operations { /** @description Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js), or a dictionary containing a user's bank account details. */ readonly bank_account?: Partial<{ readonly account_holder_name?: string; + /** @enum {string} */ readonly account_holder_type?: "company" | "individual"; readonly account_number: string; readonly country: string; readonly currency?: string; + /** @enum {string} */ readonly object?: "bank_account"; readonly routing_number?: string; }> & @@ -12696,7 +13508,10 @@ export interface operations { readonly "application/x-www-form-urlencoded": { /** @description The name of the person or business that owns the bank account. */ readonly account_holder_name?: string; - /** @description The type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description The type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string} + */ readonly account_holder_type?: "" | "company" | "individual"; /** @description City/District/Suburb/Town/Village. */ readonly address_city?: string; @@ -12856,7 +13671,10 @@ export interface operations { readonly data: readonly components["schemas"]["person"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -13231,7 +14049,10 @@ export interface operations { readonly data: readonly components["schemas"]["person"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -13633,7 +14454,10 @@ export interface operations { readonly data: readonly components["schemas"]["apple_pay_domain"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -13768,7 +14592,10 @@ export interface operations { readonly data: readonly components["schemas"]["application_fee"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -13945,7 +14772,10 @@ export interface operations { readonly data: readonly components["schemas"]["fee_refund"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -14088,7 +14918,10 @@ export interface operations { readonly data: readonly components["schemas"]["balance_transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -14191,7 +15024,10 @@ export interface operations { readonly data: readonly components["schemas"]["balance_transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -14303,7 +15139,10 @@ export interface operations { readonly data: readonly components["schemas"]["bitcoin_receiver"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -14382,7 +15221,10 @@ export interface operations { readonly data: readonly components["schemas"]["bitcoin_transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -14428,7 +15270,10 @@ export interface operations { readonly data: readonly components["schemas"]["bitcoin_transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -14483,7 +15328,10 @@ export interface operations { readonly data: readonly components["schemas"]["charge"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -14543,6 +15391,7 @@ export interface operations { readonly metadata?: { readonly [key: string]: string }; readonly name?: string; readonly number: string; + /** @enum {string} */ readonly object?: "card"; }> & Partial; @@ -14670,6 +15519,7 @@ export interface operations { * @description A set of key-value pairs you can attach to a charge giving information about its riskiness. If you believe a charge is fraudulent, include a `user_report` key with a value of `fraudulent`. If you believe a charge is safe, include a `user_report` key with a value of `safe`. Stripe will use the information you send to improve our fraud detection algorithms. */ readonly fraud_details?: { + /** @enum {string} */ readonly user_report: "" | "fraudulent" | "safe"; }; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ @@ -14924,6 +15774,7 @@ export interface operations { /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ readonly metadata?: Partial<{ readonly [key: string]: string }> & Partial<"">; readonly payment_intent?: string; + /** @enum {string} */ readonly reason?: "duplicate" | "fraudulent" | "requested_by_customer"; readonly refund_application_fee?: boolean; readonly reverse_transfer?: boolean; @@ -14957,7 +15808,10 @@ export interface operations { readonly data: readonly components["schemas"]["refund"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -15007,6 +15861,7 @@ export interface operations { /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ readonly metadata?: Partial<{ readonly [key: string]: string }> & Partial<"">; readonly payment_intent?: string; + /** @enum {string} */ readonly reason?: "duplicate" | "fraudulent" | "requested_by_customer"; readonly refund_application_fee?: boolean; readonly reverse_transfer?: boolean; @@ -15104,7 +15959,10 @@ export interface operations { readonly data: readonly components["schemas"]["checkout.session"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -15143,7 +16001,10 @@ export interface operations { readonly requestBody: { readonly content: { readonly "application/x-www-form-urlencoded": { - /** @description Specify whether Checkout should collect the customer's billing address. */ + /** + * @description Specify whether Checkout should collect the customer's billing address. + * @enum {string} + */ readonly billing_address_collection?: "auto" | "required"; /** @description The URL the customer will be directed to if they decide to cancel payment and return to your website. */ readonly cancel_url: string; @@ -15187,7 +16048,10 @@ export interface operations { readonly quantity: number; readonly tax_rates?: readonly string[]; }[]; - /** @description The IETF language tag of the locale Checkout is displayed in. If blank or `auto`, the browser's locale is used. */ + /** + * @description The IETF language tag of the locale Checkout is displayed in. If blank or `auto`, the browser's locale is used. + * @enum {string} + */ readonly locale?: | "auto" | "da" @@ -15208,7 +16072,10 @@ export interface operations { | "zh"; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ readonly metadata?: { readonly [key: string]: string }; - /** @description The mode of the Checkout Session, one of `payment`, `setup`, or `subscription`. */ + /** + * @description The mode of the Checkout Session, one of `payment`, `setup`, or `subscription`. + * @enum {string} + */ readonly mode?: "payment" | "setup" | "subscription"; /** * payment_intent_data_params @@ -15216,11 +16083,13 @@ export interface operations { */ readonly payment_intent_data?: { readonly application_fee_amount?: number; + /** @enum {string} */ readonly capture_method?: "automatic" | "manual"; readonly description?: string; readonly metadata?: { readonly [key: string]: string }; readonly on_behalf_of?: string; readonly receipt_email?: string; + /** @enum {string} */ readonly setup_future_usage?: "off_session" | "on_session"; /** shipping */ readonly shipping?: { @@ -15507,6 +16376,7 @@ export interface operations { * relevant text on the page, such as the submit button. `submit_type` can only be * specified on Checkout Sessions in `payment` mode, but not Checkout Sessions * in `subscription` or `setup` mode. + * @enum {string} */ readonly submit_type?: "auto" | "book" | "donate" | "pay"; /** @@ -15592,7 +16462,10 @@ export interface operations { readonly data: readonly components["schemas"]["country_spec"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -15673,7 +16546,10 @@ export interface operations { readonly data: readonly components["schemas"]["coupon"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -15720,7 +16596,10 @@ export interface operations { readonly amount_off?: number; /** @description Three-letter [ISO code for the currency](https://stripe.com/docs/currencies) of the `amount_off` parameter (required if `amount_off` is passed). */ readonly currency?: string; - /** @description Specifies how long the discount will be in effect. Can be `forever`, `once`, or `repeating`. */ + /** + * @description Specifies how long the discount will be in effect. Can be `forever`, `once`, or `repeating`. + * @enum {string} + */ readonly duration: "forever" | "once" | "repeating"; /** @description Required only if `duration` is `repeating`, in which case it must be a positive integer that specifies the number of months the discount will be in effect. */ readonly duration_in_months?: number; @@ -15863,7 +16742,10 @@ export interface operations { readonly data: readonly components["schemas"]["credit_note"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -15932,6 +16814,7 @@ export interface operations { readonly invoice_line_item?: string; readonly quantity?: number; readonly tax_rates?: Partial & Partial<"">; + /** @enum {string} */ readonly type: "custom_line_item" | "invoice_line_item"; readonly unit_amount?: number; /** Format: decimal */ @@ -15943,7 +16826,10 @@ export interface operations { readonly metadata?: { readonly [key: string]: string }; /** @description The integer amount in **%s** representing the amount that is credited outside of Stripe. */ readonly out_of_band_amount?: number; - /** @description Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory` */ + /** + * @description Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory` + * @enum {string} + */ readonly reason?: "duplicate" | "fraudulent" | "order_change" | "product_unsatisfactory"; /** @description ID of an existing refund to link this credit note to. */ readonly refund?: string; @@ -15972,6 +16858,7 @@ export interface operations { readonly invoice_line_item?: string; readonly quantity?: number; readonly tax_rates?: Partial & Partial<"">; + /** @enum {string} */ readonly type: "custom_line_item" | "invoice_line_item"; readonly unit_amount?: number; /** Format: decimal */ @@ -16034,6 +16921,7 @@ export interface operations { readonly invoice_line_item?: string; readonly quantity?: number; readonly tax_rates?: Partial & Partial<"">; + /** @enum {string} */ readonly type: "custom_line_item" | "invoice_line_item"; readonly unit_amount?: number; /** Format: decimal */ @@ -16064,7 +16952,10 @@ export interface operations { readonly data: readonly components["schemas"]["credit_note_line_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -16110,7 +17001,10 @@ export interface operations { readonly data: readonly components["schemas"]["credit_note_line_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -16256,7 +17150,10 @@ export interface operations { readonly data: readonly components["schemas"]["customer"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -16358,10 +17255,14 @@ export interface operations { }> & Partial<"">; readonly source?: string; - /** @description The customer's tax exemption. One of `none`, `exempt`, or `reverse`. */ + /** + * @description The customer's tax exemption. One of `none`, `exempt`, or `reverse`. + * @enum {string} + */ readonly tax_exempt?: "" | "exempt" | "none" | "reverse"; /** @description The customer's tax IDs. */ readonly tax_id_data?: readonly { + /** @enum {string} */ readonly type: | "au_abn" | "ca_bn" @@ -16467,10 +17368,12 @@ export interface operations { /** @description Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js), or a dictionary containing a user's bank account details. */ readonly bank_account?: Partial<{ readonly account_holder_name?: string; + /** @enum {string} */ readonly account_holder_type?: "company" | "individual"; readonly account_number: string; readonly country: string; readonly currency?: string; + /** @enum {string} */ readonly object?: "bank_account"; readonly routing_number?: string; }> & @@ -16489,6 +17392,7 @@ export interface operations { readonly metadata?: { readonly [key: string]: string }; readonly name?: string; readonly number: string; + /** @enum {string} */ readonly object?: "card"; }> & Partial; @@ -16556,7 +17460,10 @@ export interface operations { }> & Partial<"">; readonly source?: string; - /** @description The customer's tax exemption. One of `none`, `exempt`, or `reverse`. */ + /** + * @description The customer's tax exemption. One of `none`, `exempt`, or `reverse`. + * @enum {string} + */ readonly tax_exempt?: "" | "exempt" | "none" | "reverse"; /** @description Unix timestamp representing the end of the trial period the customer will get before being charged for the first time. This will always overwrite any trials that might apply via a subscribed plan. If set, trial_end will override the default trial period of the plan the customer is being subscribed to. The special value `now` can be provided to end the customer's trial immediately. Can be at most two years from `billing_cycle_anchor`. */ readonly trial_end?: Partial<"now"> & Partial; @@ -16617,7 +17524,10 @@ export interface operations { readonly data: readonly components["schemas"]["customer_balance_transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -16768,7 +17678,10 @@ export interface operations { readonly data: readonly components["schemas"]["bank_account"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -16823,10 +17736,12 @@ export interface operations { /** @description Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js), or a dictionary containing a user's bank account details. */ readonly bank_account?: Partial<{ readonly account_holder_name?: string; + /** @enum {string} */ readonly account_holder_type?: "company" | "individual"; readonly account_number: string; readonly country: string; readonly currency?: string; + /** @enum {string} */ readonly object?: "bank_account"; readonly routing_number?: string; }> & @@ -16845,6 +17760,7 @@ export interface operations { readonly metadata?: { readonly [key: string]: string }; readonly name?: string; readonly number: string; + /** @enum {string} */ readonly object?: "card"; }> & Partial; @@ -16919,7 +17835,10 @@ export interface operations { readonly "application/x-www-form-urlencoded": { /** @description The name of the person or business that owns the bank account. */ readonly account_holder_name?: string; - /** @description The type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description The type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string} + */ readonly account_holder_type?: "company" | "individual"; /** @description City/District/Suburb/Town/Village. */ readonly address_city?: string; @@ -17056,7 +17975,10 @@ export interface operations { readonly data: readonly components["schemas"]["card"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -17111,10 +18033,12 @@ export interface operations { /** @description Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js), or a dictionary containing a user's bank account details. */ readonly bank_account?: Partial<{ readonly account_holder_name?: string; + /** @enum {string} */ readonly account_holder_type?: "company" | "individual"; readonly account_number: string; readonly country: string; readonly currency?: string; + /** @enum {string} */ readonly object?: "bank_account"; readonly routing_number?: string; }> & @@ -17133,6 +18057,7 @@ export interface operations { readonly metadata?: { readonly [key: string]: string }; readonly name?: string; readonly number: string; + /** @enum {string} */ readonly object?: "card"; }> & Partial; @@ -17207,7 +18132,10 @@ export interface operations { readonly "application/x-www-form-urlencoded": { /** @description The name of the person or business that owns the bank account. */ readonly account_holder_name?: string; - /** @description The type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description The type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string} + */ readonly account_holder_type?: "company" | "individual"; /** @description City/District/Suburb/Town/Village. */ readonly address_city?: string; @@ -17371,7 +18299,10 @@ export interface operations { Partial)[]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -17426,10 +18357,12 @@ export interface operations { /** @description Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js), or a dictionary containing a user's bank account details. */ readonly bank_account?: Partial<{ readonly account_holder_name?: string; + /** @enum {string} */ readonly account_holder_type?: "company" | "individual"; readonly account_number: string; readonly country: string; readonly currency?: string; + /** @enum {string} */ readonly object?: "bank_account"; readonly routing_number?: string; }> & @@ -17448,6 +18381,7 @@ export interface operations { readonly metadata?: { readonly [key: string]: string }; readonly name?: string; readonly number: string; + /** @enum {string} */ readonly object?: "card"; }> & Partial; @@ -17522,7 +18456,10 @@ export interface operations { readonly "application/x-www-form-urlencoded": { /** @description The name of the person or business that owns the bank account. */ readonly account_holder_name?: string; - /** @description The type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description The type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string} + */ readonly account_holder_type?: "company" | "individual"; /** @description City/District/Suburb/Town/Village. */ readonly address_city?: string; @@ -17656,7 +18593,10 @@ export interface operations { readonly data: readonly components["schemas"]["subscription"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -17725,7 +18665,10 @@ export interface operations { readonly cancel_at?: number; /** @description Boolean indicating whether this subscription should cancel at the end of the current period. */ readonly cancel_at_period_end?: boolean; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. + * @enum {string} + */ readonly collection_method?: "charge_automatically" | "send_invoice"; /** @description The code of the coupon to apply to this subscription. A coupon applied to a subscription will only affect invoices created for that particular subscription. */ readonly coupon?: string; @@ -17760,10 +18703,12 @@ export interface operations { * Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not create a subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more. * * `pending_if_incomplete` is only used with updates and cannot be passed when creating a subscription. + * @enum {string} */ readonly payment_behavior?: "allow_incomplete" | "error_if_incomplete" | "pending_if_incomplete"; /** @description Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval. */ readonly pending_invoice_item_interval?: Partial<{ + /** @enum {string} */ readonly interval: "day" | "month" | "week" | "year"; readonly interval_count?: number; }> & @@ -17774,6 +18719,7 @@ export interface operations { * @description Determines how to handle [prorations](https://stripe.com/docs/subscriptions/billing-cycle#prorations) resulting from the `billing_cycle_anchor`. Valid values are `create_prorations` or `none`. * * Passing `create_prorations` will cause proration invoice items to be created when applicable. Prorations can be disabled by passing `none`. If no value is passed, the default is `create_prorations`. + * @enum {string} */ readonly proration_behavior?: "always_invoice" | "create_prorations" | "none"; /** @description A non-negative decimal (with at most four decimal places) between 0 and 100. This represents the percentage of the subscription invoice subtotal that will be calculated and added as tax to the final amount in each billing period. For example, a plan which charges $10/month with a `tax_percent` of `20.0` will charge $12 per invoice. To unset a previously-set value, pass an empty string. This field has been deprecated and will be removed in a future API version, for further information view the [migration docs](https://stripe.com/docs/billing/migration/taxes) for `tax_rates`. */ @@ -17847,7 +18793,10 @@ export interface operations { readonly "application/x-www-form-urlencoded": { /** @description A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice subtotal that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions). */ readonly application_fee_percent?: number; - /** @description Either `now` or `unchanged`. Setting the value to `now` resets the subscription's billing cycle anchor to the current time. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle). */ + /** + * @description Either `now` or `unchanged`. Setting the value to `now` resets the subscription's billing cycle anchor to the current time. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle). + * @enum {string} + */ readonly billing_cycle_anchor?: "now" | "unchanged"; /** @description Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds. */ readonly billing_thresholds?: Partial<{ @@ -17859,7 +18808,10 @@ export interface operations { readonly cancel_at?: Partial & Partial<"">; /** @description Boolean indicating whether this subscription should cancel at the end of the current period. */ readonly cancel_at_period_end?: boolean; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. + * @enum {string} + */ readonly collection_method?: "charge_automatically" | "send_invoice"; /** @description The code of the coupon to apply to this subscription. A coupon applied to a subscription will only affect invoices created for that particular subscription. */ readonly coupon?: string; @@ -17893,6 +18845,7 @@ export interface operations { readonly off_session?: boolean; /** @description If specified, payment collection for this subscription will be paused. */ readonly pause_collection?: Partial<{ + /** @enum {string} */ readonly behavior: "keep_as_draft" | "mark_uncollectible" | "void"; /** Format: unix-time */ readonly resumes_at?: number; @@ -17904,10 +18857,12 @@ export interface operations { * Use `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes). * * Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not create a subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more. + * @enum {string} */ readonly payment_behavior?: "allow_incomplete" | "error_if_incomplete" | "pending_if_incomplete"; /** @description Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval. */ readonly pending_invoice_item_interval?: Partial<{ + /** @enum {string} */ readonly interval: "day" | "month" | "week" | "year"; readonly interval_count?: number; }> & @@ -17920,6 +18875,7 @@ export interface operations { * Passing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`. * * Prorations can be disabled by passing `none`. + * @enum {string} */ readonly proration_behavior?: "always_invoice" | "create_prorations" | "none"; /** @@ -18063,7 +19019,10 @@ export interface operations { readonly data: readonly components["schemas"]["tax_id"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -18109,7 +19068,10 @@ export interface operations { readonly "application/x-www-form-urlencoded": { /** @description Specifies which fields in the response should be expanded. */ readonly expand?: readonly string[]; - /** @description Type of the tax ID, one of `eu_vat`, `nz_gst`, `au_abn`, `in_gst`, `no_vat`, `za_vat`, `ch_vat`, `mx_rfc`, `sg_uen`, `ru_inn`, `ca_bn`, `hk_br`, `es_cif`, `tw_vat`, `th_vat`, `jp_cn`, `li_uid`, `my_itn`, `us_ein`, `kr_brn`, `ca_qst`, `my_sst`, or `sg_gst` */ + /** + * @description Type of the tax ID, one of `eu_vat`, `nz_gst`, `au_abn`, `in_gst`, `no_vat`, `za_vat`, `ch_vat`, `mx_rfc`, `sg_uen`, `ru_inn`, `ca_bn`, `hk_br`, `es_cif`, `tw_vat`, `th_vat`, `jp_cn`, `li_uid`, `my_itn`, `us_ein`, `kr_brn`, `ca_qst`, `my_sst`, or `sg_gst` + * @enum {string} + */ readonly type: | "au_abn" | "ca_bn" @@ -18233,7 +19195,10 @@ export interface operations { readonly data: readonly components["schemas"]["dispute"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -18483,7 +19448,10 @@ export interface operations { readonly data: readonly components["schemas"]["event"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -18556,7 +19524,10 @@ export interface operations { readonly data: readonly components["schemas"]["exchange_rate"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -18640,7 +19611,10 @@ export interface operations { readonly data: readonly components["schemas"]["file_link"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -18800,7 +19774,10 @@ export interface operations { readonly data: readonly components["schemas"]["file"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -18857,7 +19834,10 @@ export interface operations { readonly expires_at?: number; readonly metadata?: Partial<{ readonly [key: string]: string }> & Partial<"">; }; - /** @description The purpose of the uploaded file. Possible values are `additional_verification`, `business_icon`, `business_logo`, `customer_signature`, `dispute_evidence`, `identity_document`, `pci_document`, or `tax_document_user_upload`. */ + /** + * @description The purpose of the uploaded file. Possible values are `additional_verification`, `business_icon`, `business_logo`, `customer_signature`, `dispute_evidence`, `identity_document`, `pci_document`, or `tax_document_user_upload`. + * @enum {string} + */ readonly purpose: | "additional_verification" | "business_icon" @@ -18937,7 +19917,10 @@ export interface operations { readonly data: readonly components["schemas"]["invoiceitem"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -19180,7 +20163,10 @@ export interface operations { readonly data: readonly components["schemas"]["invoice"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -19223,7 +20209,10 @@ export interface operations { readonly application_fee_amount?: number; /** @description Controls whether Stripe will perform [automatic collection](https://stripe.com/docs/billing/invoices/workflow/#auto_advance) of the invoice. When `false`, the invoice's state will not automatically advance without an explicit action. */ readonly auto_advance?: boolean; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this invoice using the default source attached to the customer. When sending an invoice, Stripe will email this invoice to the customer with payment instructions. Defaults to `charge_automatically`. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this invoice using the default source attached to the customer. When sending an invoice, Stripe will email this invoice to the customer with payment instructions. Defaults to `charge_automatically`. + * @enum {string} + */ readonly collection_method?: "charge_automatically" | "send_invoice"; /** @description A list of up to 4 custom fields to be displayed on the invoice. */ readonly custom_fields?: Partial< @@ -19469,7 +20458,10 @@ export interface operations { readonly data: readonly components["schemas"]["line_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -19555,7 +20547,10 @@ export interface operations { readonly application_fee_amount?: number; /** @description Controls whether Stripe will perform [automatic collection](https://stripe.com/docs/billing/invoices/workflow/#auto_advance) of the invoice. */ readonly auto_advance?: boolean; - /** @description Either `charge_automatically` or `send_invoice`. This field can be updated only on `draft` invoices. */ + /** + * @description Either `charge_automatically` or `send_invoice`. This field can be updated only on `draft` invoices. + * @enum {string} + */ readonly collection_method?: "charge_automatically" | "send_invoice"; /** @description A list of up to 4 custom fields to be displayed on the invoice. If a value for `custom_fields` is specified, the list specified will replace the existing custom field list on this invoice. Pass an empty string to remove previously-defined fields. */ readonly custom_fields?: Partial< @@ -19679,7 +20674,10 @@ export interface operations { readonly data: readonly components["schemas"]["line_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -19861,7 +20859,10 @@ export interface operations { readonly data: readonly components["schemas"]["issuer_fraud_record"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -19952,7 +20953,10 @@ export interface operations { readonly data: readonly components["schemas"]["issuing.authorization"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -20139,7 +21143,10 @@ export interface operations { readonly data: readonly components["schemas"]["issuing.cardholder"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -21109,13 +22116,20 @@ export interface operations { | "womens_ready_to_wear_stores" | "wrecking_and_salvage_yards" )[]; + /** @enum {string} */ readonly interval: "all_time" | "daily" | "monthly" | "per_authorization" | "weekly" | "yearly"; }[]; readonly spending_limits_currency?: string; }; - /** @description Specifies whether to permit authorizations on this cardholder's cards. Defaults to `active`. */ + /** + * @description Specifies whether to permit authorizations on this cardholder's cards. Defaults to `active`. + * @enum {string} + */ readonly status?: "active" | "inactive"; - /** @description One of `individual` or `company`. */ + /** + * @description One of `individual` or `company`. + * @enum {string} + */ readonly type: "company" | "individual"; }; }; @@ -22105,11 +23119,15 @@ export interface operations { | "womens_ready_to_wear_stores" | "wrecking_and_salvage_yards" )[]; + /** @enum {string} */ readonly interval: "all_time" | "daily" | "monthly" | "per_authorization" | "weekly" | "yearly"; }[]; readonly spending_limits_currency?: string; }; - /** @description Specifies whether to permit authorizations on this cardholder's cards. */ + /** + * @description Specifies whether to permit authorizations on this cardholder's cards. + * @enum {string} + */ readonly status?: "active" | "inactive"; }; }; @@ -22157,7 +23175,10 @@ export interface operations { readonly data: readonly components["schemas"]["issuing.card"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -22206,7 +23227,10 @@ export interface operations { readonly metadata?: { readonly [key: string]: string }; /** @description The card this is meant to be a replacement for (if any). */ readonly replacement_for?: string; - /** @description If `replacement_for` is specified, this should indicate why that card is being replaced. */ + /** + * @description If `replacement_for` is specified, this should indicate why that card is being replaced. + * @enum {string} + */ readonly replacement_reason?: "damaged" | "expired" | "lost" | "stolen"; /** * shipping_specs @@ -22223,7 +23247,9 @@ export interface operations { readonly state?: string; }; readonly name: string; + /** @enum {string} */ readonly service?: "express" | "priority" | "standard"; + /** @enum {string} */ readonly type?: "bulk" | "individual"; }; /** @@ -23103,12 +24129,19 @@ export interface operations { | "womens_ready_to_wear_stores" | "wrecking_and_salvage_yards" )[]; + /** @enum {string} */ readonly interval: "all_time" | "daily" | "monthly" | "per_authorization" | "weekly" | "yearly"; }[]; }; - /** @description Whether authorizations can be approved on this card. Defaults to `inactive`. */ + /** + * @description Whether authorizations can be approved on this card. Defaults to `inactive`. + * @enum {string} + */ readonly status?: "active" | "inactive"; - /** @description The type of card to issue. Possible values are `physical` or `virtual`. */ + /** + * @description The type of card to issue. Possible values are `physical` or `virtual`. + * @enum {string} + */ readonly type: "physical" | "virtual"; }; }; @@ -23169,7 +24202,10 @@ export interface operations { readonly requestBody: { readonly content: { readonly "application/x-www-form-urlencoded": { - /** @description Reason why the `status` of this card is `canceled`. */ + /** + * @description Reason why the `status` of this card is `canceled`. + * @enum {string} + */ readonly cancellation_reason?: "lost" | "stolen"; /** @description Specifies which fields in the response should be expanded. */ readonly expand?: readonly string[]; @@ -24052,10 +25088,14 @@ export interface operations { | "womens_ready_to_wear_stores" | "wrecking_and_salvage_yards" )[]; + /** @enum {string} */ readonly interval: "all_time" | "daily" | "monthly" | "per_authorization" | "weekly" | "yearly"; }[]; }; - /** @description Dictates whether authorizations can be approved on this card. If this card is being canceled because it was lost or stolen, this information should be provided as `cancellation_reason`. */ + /** + * @description Dictates whether authorizations can be approved on this card. If this card is being canceled because it was lost or stolen, this information should be provided as `cancellation_reason`. + * @enum {string} + */ readonly status?: "active" | "canceled" | "inactive"; }; }; @@ -24083,7 +25123,10 @@ export interface operations { readonly data: readonly components["schemas"]["issuing.dispute"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -24223,7 +25266,10 @@ export interface operations { readonly data: readonly components["schemas"]["issuing.settlement"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -24340,7 +25386,10 @@ export interface operations { readonly data: readonly components["schemas"]["issuing.transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -24486,7 +25535,10 @@ export interface operations { readonly data: readonly components["schemas"]["order_return"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -24606,7 +25658,10 @@ export interface operations { readonly data: readonly components["schemas"]["order"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -24662,6 +25717,7 @@ export interface operations { readonly description?: string; readonly parent?: string; readonly quantity?: number; + /** @enum {string} */ readonly type?: "discount" | "shipping" | "sku" | "tax"; }[]; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ @@ -24758,7 +25814,10 @@ export interface operations { readonly carrier: string; readonly tracking_number: string; }; - /** @description Current order status. One of `created`, `paid`, `canceled`, `fulfilled`, or `returned`. More detail in the [Orders Guide](https://stripe.com/docs/orders/guide#understanding-order-statuses). */ + /** + * @description Current order status. One of `created`, `paid`, `canceled`, `fulfilled`, or `returned`. More detail in the [Orders Guide](https://stripe.com/docs/orders/guide#understanding-order-statuses). + * @enum {string} + */ readonly status?: "canceled" | "created" | "fulfilled" | "paid" | "returned"; }; }; @@ -24837,6 +25896,7 @@ export interface operations { readonly description?: string; readonly parent?: string; readonly quantity?: number; + /** @enum {string} */ readonly type?: "discount" | "shipping" | "sku" | "tax"; }[] > & @@ -24877,7 +25937,10 @@ export interface operations { readonly data: readonly components["schemas"]["payment_intent"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -24935,10 +25998,14 @@ export interface operations { * more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts). */ readonly application_fee_amount?: number; - /** @description Controls when the funds will be captured from the customer's account. */ + /** + * @description Controls when the funds will be captured from the customer's account. + * @enum {string} + */ readonly capture_method?: "automatic" | "manual"; /** @description Set to `true` to attempt to [confirm](https://stripe.com/docs/api/payment_intents/confirm) this PaymentIntent immediately. This parameter defaults to `false`. When creating and confirming a PaymentIntent at the same time, parameters available in the [confirm](https://stripe.com/docs/api/payment_intents/confirm) API may also be provided. */ readonly confirm?: boolean; + /** @enum {string} */ readonly confirmation_method?: "automatic" | "manual"; /** @description Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). */ readonly currency: string; @@ -24974,6 +26041,7 @@ export interface operations { readonly ip_address: string; readonly user_agent: string; }; + /** @enum {string} */ readonly type: "offline" | "online"; }; }; @@ -25000,11 +26068,14 @@ export interface operations { readonly enabled?: boolean; readonly plan?: Partial<{ readonly count: number; + /** @enum {string} */ readonly interval: "month"; + /** @enum {string} */ readonly type: "fixed_count"; }> & Partial<"">; }; + /** @enum {string} */ readonly request_three_d_secure?: "any" | "automatic"; }> & Partial<"">; @@ -25021,6 +26092,7 @@ export interface operations { * Providing this parameter will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any required actions from the user are complete. If no Customer was provided, the payment method can still be [attached](https://stripe.com/docs/api/payment_methods/attach) to a Customer after the transaction completes. * * When processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication). + * @enum {string} */ readonly setup_future_usage?: "off_session" | "on_session"; /** @@ -25167,11 +26239,14 @@ export interface operations { readonly enabled?: boolean; readonly plan?: Partial<{ readonly count: number; + /** @enum {string} */ readonly interval: "month"; + /** @enum {string} */ readonly type: "fixed_count"; }> & Partial<"">; }; + /** @enum {string} */ readonly request_three_d_secure?: "any" | "automatic"; }> & Partial<"">; @@ -25188,6 +26263,7 @@ export interface operations { * When processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication). * * If `setup_future_usage` is already set and you are performing a request using a publishable key, you may only update the value from `on_session` to `off_session`. + * @enum {string} */ readonly setup_future_usage?: "" | "off_session" | "on_session"; /** @description Shipping information for this PaymentIntent. */ @@ -25252,7 +26328,10 @@ export interface operations { readonly requestBody: { readonly content: { readonly "application/x-www-form-urlencoded": { - /** @description Reason for canceling this PaymentIntent. Possible values are `duplicate`, `fraudulent`, `requested_by_customer`, or `abandoned` */ + /** + * @description Reason for canceling this PaymentIntent. Possible values are `duplicate`, `fraudulent`, `requested_by_customer`, or `abandoned` + * @enum {string} + */ readonly cancellation_reason?: "abandoned" | "duplicate" | "fraudulent" | "requested_by_customer"; /** @description Specifies which fields in the response should be expanded. */ readonly expand?: readonly string[]; @@ -25387,6 +26466,7 @@ export interface operations { readonly ip_address: string; readonly user_agent: string; }; + /** @enum {string} */ readonly type: "offline" | "online"; }; }> & @@ -25398,6 +26478,7 @@ export interface operations { readonly ip_address?: string; readonly user_agent?: string; }; + /** @enum {string} */ readonly type: "online"; }; }>; @@ -25416,11 +26497,14 @@ export interface operations { readonly enabled?: boolean; readonly plan?: Partial<{ readonly count: number; + /** @enum {string} */ readonly interval: "month"; + /** @enum {string} */ readonly type: "fixed_count"; }> & Partial<"">; }; + /** @enum {string} */ readonly request_three_d_secure?: "any" | "automatic"; }> & Partial<"">; @@ -25443,6 +26527,7 @@ export interface operations { * When processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication). * * If `setup_future_usage` is already set and you are performing a request using a publishable key, you may only update the value from `on_session` to `off_session`. + * @enum {string} */ readonly setup_future_usage?: "" | "off_session" | "on_session"; /** @description Shipping information for this PaymentIntent. */ @@ -25494,7 +26579,10 @@ export interface operations { readonly data: readonly components["schemas"]["payment_method"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -25578,6 +26666,7 @@ export interface operations { * @description If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method. */ readonly fpx?: { + /** @enum {string} */ readonly bank: | "affin_bank" | "alliance_bank" @@ -25605,6 +26694,7 @@ export interface operations { * @description If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method. */ readonly ideal?: { + /** @enum {string} */ readonly bank?: | "abn_amro" | "asn_bank" @@ -25630,7 +26720,10 @@ export interface operations { readonly sepa_debit?: { readonly iban: string; }; - /** @description The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type. Required unless `payment_method` is specified (see the [Cloning PaymentMethods](https://stripe.com/docs/payments/payment-methods/connect#cloning-payment-methods) guide) */ + /** + * @description The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type. Required unless `payment_method` is specified (see the [Cloning PaymentMethods](https://stripe.com/docs/payments/payment-methods/connect#cloning-payment-methods) guide) + * @enum {string} + */ readonly type?: "au_becs_debit" | "card" | "fpx" | "ideal" | "sepa_debit"; }; }; @@ -25844,7 +26937,10 @@ export interface operations { readonly data: readonly components["schemas"]["payout"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -25901,9 +26997,15 @@ export interface operations { readonly expand?: readonly string[]; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ readonly metadata?: { readonly [key: string]: string }; - /** @description The method used to send this payout, which can be `standard` or `instant`. `instant` is only supported for payouts to debit cards. (See [Instant payouts for marketplaces for more information](https://stripe.com/blog/instant-payouts-for-marketplaces).) */ + /** + * @description The method used to send this payout, which can be `standard` or `instant`. `instant` is only supported for payouts to debit cards. (See [Instant payouts for marketplaces for more information](https://stripe.com/blog/instant-payouts-for-marketplaces).) + * @enum {string} + */ readonly method?: "instant" | "standard"; - /** @description The balance type of your Stripe balance to draw this payout from. Balances for different payment sources are kept separately. You can find the amounts with the balances API. One of `bank_account`, `card`, or `fpx`. */ + /** + * @description The balance type of your Stripe balance to draw this payout from. Balances for different payment sources are kept separately. You can find the amounts with the balances API. One of `bank_account`, `card`, or `fpx`. + * @enum {string} + */ readonly source_type?: "bank_account" | "card" | "fpx"; /** @description A string to be displayed on the recipient's bank or card statement. This may be at most 22 characters. Attempting to use a `statement_descriptor` longer than 22 characters will return an error. Note: Most banks will truncate this information and/or display it inconsistently. Some may not display it at all. */ readonly statement_descriptor?: string; @@ -26038,7 +27140,10 @@ export interface operations { readonly data: readonly components["schemas"]["plan"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -26079,7 +27184,10 @@ export interface operations { readonly "application/x-www-form-urlencoded": { /** @description Whether the plan is currently available for new subscriptions. Defaults to `true`. */ readonly active?: boolean; - /** @description Specifies a usage aggregation strategy for plans of `usage_type=metered`. Allowed values are `sum` for summing up all usage during a period, `last_during_period` for using the last usage record reported within a period, `last_ever` for using the last usage record ever (across period bounds) or `max` which uses the usage record with the maximum reported usage during a period. Defaults to `sum`. */ + /** + * @description Specifies a usage aggregation strategy for plans of `usage_type=metered`. Allowed values are `sum` for summing up all usage during a period, `last_during_period` for using the last usage record reported within a period, `last_ever` for using the last usage record ever (across period bounds) or `max` which uses the usage record with the maximum reported usage during a period. Defaults to `sum`. + * @enum {string} + */ readonly aggregate_usage?: "last_during_period" | "last_ever" | "max" | "sum"; /** @description A positive integer in %s (or 0 for a free plan) representing how much to charge on a recurring basis. */ readonly amount?: number; @@ -26088,7 +27196,10 @@ export interface operations { * @description Same as `amount`, but accepts a decimal value with at most 12 decimal places. Only one of `amount` and `amount_decimal` can be set. */ readonly amount_decimal?: string; - /** @description Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `amount`) will be charged per unit in `quantity` (for plans with `usage_type=licensed`), or per unit of total usage (for plans with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes. */ + /** + * @description Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `amount`) will be charged per unit in `quantity` (for plans with `usage_type=licensed`), or per unit of total usage (for plans with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes. + * @enum {string} + */ readonly billing_scheme?: "per_unit" | "tiered"; /** @description Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). */ readonly currency: string; @@ -26096,7 +27207,10 @@ export interface operations { readonly expand?: readonly string[]; /** @description An identifier randomly generated by Stripe. Used to identify this plan when subscribing a customer. You can optionally override this ID, but the ID must be unique across all plans in your Stripe account. You can, however, use the same plan ID in both live and test modes. */ readonly id?: string; - /** @description Specifies billing frequency. Either `day`, `week`, `month` or `year`. */ + /** + * @description Specifies billing frequency. Either `day`, `week`, `month` or `year`. + * @enum {string} + */ readonly interval: "day" | "month" | "week" | "year"; /** @description The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). */ readonly interval_count?: number; @@ -26123,7 +27237,10 @@ export interface operations { readonly unit_amount_decimal?: string; readonly up_to: Partial<"inf"> & Partial; }[]; - /** @description Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price, in `graduated` tiering pricing can successively change as the quantity grows. */ + /** + * @description Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price, in `graduated` tiering pricing can successively change as the quantity grows. + * @enum {string} + */ readonly tiers_mode?: "graduated" | "volume"; /** * transform_usage_param @@ -26131,11 +27248,15 @@ export interface operations { */ readonly transform_usage?: { readonly divide_by: number; + /** @enum {string} */ readonly round: "down" | "up"; }; /** @description Default number of trial days when subscribing a customer to this plan using [`trial_from_plan=true`](https://stripe.com/docs/api#create_subscription-trial_from_plan). */ readonly trial_period_days?: number; - /** @description Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`. */ + /** + * @description Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`. + * @enum {string} + */ readonly usage_type?: "licensed" | "metered"; }; }; @@ -26279,7 +27400,10 @@ export interface operations { readonly data: readonly components["schemas"]["product"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -26357,7 +27481,10 @@ export interface operations { * It must contain at least one letter. */ readonly statement_descriptor?: string; - /** @description The type of the product. Defaults to `service` if not explicitly specified, enabling use of this product with Subscriptions and Plans. Set this parameter to `good` to use this product with Orders and SKUs. On API versions before `2018-02-05`, this field defaults to `good` for compatibility reasons. */ + /** + * @description The type of the product. Defaults to `service` if not explicitly specified, enabling use of this product with Subscriptions and Plans. Set this parameter to `good` to use this product with Orders and SKUs. On API versions before `2018-02-05`, this field defaults to `good` for compatibility reasons. + * @enum {string} + */ readonly type?: "good" | "service"; /** @description A label that represents units of this product in Stripe and on customers’ receipts and invoices. When set, this will be included in associated invoice line item descriptions. */ readonly unit_label?: string; @@ -26516,7 +27643,10 @@ export interface operations { readonly data: readonly components["schemas"]["radar.early_fraud_warning"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -26604,7 +27734,10 @@ export interface operations { readonly data: readonly components["schemas"]["radar.value_list_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -26744,7 +27877,10 @@ export interface operations { readonly data: readonly components["schemas"]["radar.value_list"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -26787,7 +27923,10 @@ export interface operations { readonly alias: string; /** @description Specifies which fields in the response should be expanded. */ readonly expand?: readonly string[]; - /** @description Type of the items in the value list. One of `card_fingerprint`, `card_bin`, `email`, `ip_address`, `country`, `string`, or `case_sensitive_string`. Use `string` if the item type is unknown or mixed. */ + /** + * @description Type of the items in the value list. One of `card_fingerprint`, `card_bin`, `email`, `ip_address`, `country`, `string`, or `case_sensitive_string`. Use `string` if the item type is unknown or mixed. + * @enum {string} + */ readonly item_type?: | "card_bin" | "card_fingerprint" @@ -26930,7 +28069,10 @@ export interface operations { readonly data: readonly components["schemas"]["recipient"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -27138,7 +28280,10 @@ export interface operations { readonly data: readonly components["schemas"]["refund"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -27184,6 +28329,7 @@ export interface operations { /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ readonly metadata?: Partial<{ readonly [key: string]: string }> & Partial<"">; readonly payment_intent?: string; + /** @enum {string} */ readonly reason?: "duplicate" | "fraudulent" | "requested_by_customer"; readonly refund_application_fee?: boolean; readonly reverse_transfer?: boolean; @@ -27287,7 +28433,10 @@ export interface operations { readonly data: readonly components["schemas"]["reporting.report_run"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -27341,6 +28490,7 @@ export interface operations { /** Format: unix-time */ readonly interval_start?: number; readonly payout?: string; + /** @enum {string} */ readonly reporting_category?: | "advance" | "advance_funding" @@ -27373,6 +28523,7 @@ export interface operations { | "topup_reversal" | "transfer" | "transfer_reversal"; + /** @enum {string} */ readonly timezone?: | "Africa/Abidjan" | "Africa/Accra" @@ -28022,7 +29173,10 @@ export interface operations { readonly data: readonly components["schemas"]["reporting.report_type"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -28102,7 +29256,10 @@ export interface operations { readonly data: readonly components["schemas"]["review"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -28217,7 +29374,10 @@ export interface operations { readonly data: readonly components["schemas"]["setup_intent"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -28289,6 +29449,7 @@ export interface operations { readonly ip_address: string; readonly user_agent: string; }; + /** @enum {string} */ readonly type: "offline" | "online"; }; }; @@ -28305,6 +29466,7 @@ export interface operations { readonly payment_method_options?: { /** setup_intent_param */ readonly card?: { + /** @enum {string} */ readonly request_three_d_secure?: "any" | "automatic"; }; }; @@ -28320,7 +29482,10 @@ export interface operations { readonly amount: number; readonly currency: string; }; - /** @description Indicates how the payment method is intended to be used in the future. If not provided, this value defaults to `off_session`. */ + /** + * @description Indicates how the payment method is intended to be used in the future. If not provided, this value defaults to `off_session`. + * @enum {string} + */ readonly usage?: "off_session" | "on_session"; }; }; @@ -28410,6 +29575,7 @@ export interface operations { readonly payment_method_options?: { /** setup_intent_param */ readonly card?: { + /** @enum {string} */ readonly request_three_d_secure?: "any" | "automatic"; }; }; @@ -28447,7 +29613,10 @@ export interface operations { readonly requestBody: { readonly content: { readonly "application/x-www-form-urlencoded": { - /** @description Reason for canceling this SetupIntent. Possible values are `abandoned`, `requested_by_customer`, or `duplicate` */ + /** + * @description Reason for canceling this SetupIntent. Possible values are `abandoned`, `requested_by_customer`, or `duplicate` + * @enum {string} + */ readonly cancellation_reason?: "abandoned" | "duplicate" | "requested_by_customer"; /** @description Specifies which fields in the response should be expanded. */ readonly expand?: readonly string[]; @@ -28510,6 +29679,7 @@ export interface operations { readonly ip_address: string; readonly user_agent: string; }; + /** @enum {string} */ readonly type: "offline" | "online"; }; }> & @@ -28521,6 +29691,7 @@ export interface operations { readonly ip_address?: string; readonly user_agent?: string; }; + /** @enum {string} */ readonly type: "online"; }; }>; @@ -28533,6 +29704,7 @@ export interface operations { readonly payment_method_options?: { /** setup_intent_param */ readonly card?: { + /** @enum {string} */ readonly request_three_d_secure?: "any" | "automatic"; }; }; @@ -28568,7 +29740,10 @@ export interface operations { readonly data: readonly components["schemas"]["scheduled_query_run"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -28651,7 +29826,10 @@ export interface operations { readonly data: readonly components["schemas"]["sku"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -28708,7 +29886,9 @@ export interface operations { */ readonly inventory: { readonly quantity?: number; + /** @enum {string} */ readonly type?: "bucket" | "finite" | "infinite"; + /** @enum {string} */ readonly value?: "" | "in_stock" | "limited" | "out_of_stock"; }; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ @@ -28807,7 +29987,9 @@ export interface operations { */ readonly inventory?: { readonly quantity?: number; + /** @enum {string} */ readonly type?: "bucket" | "finite" | "infinite"; + /** @enum {string} */ readonly value?: "" | "in_stock" | "limited" | "out_of_stock"; }; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ @@ -28882,7 +30064,10 @@ export interface operations { readonly customer?: string; /** @description Specifies which fields in the response should be expanded. */ readonly expand?: readonly string[]; - /** @description The authentication `flow` of the source to create. `flow` is one of `redirect`, `receiver`, `code_verification`, `none`. It is generally inferred unless a type supports multiple flows. */ + /** + * @description The authentication `flow` of the source to create. `flow` is one of `redirect`, `receiver`, `code_verification`, `none`. It is generally inferred unless a type supports multiple flows. + * @enum {string} + */ readonly flow?: "code_verification" | "none" | "receiver" | "redirect"; /** * mandate_params @@ -28905,13 +30090,17 @@ export interface operations { readonly ip?: string; readonly user_agent?: string; }; + /** @enum {string} */ readonly status: "accepted" | "pending" | "refused" | "revoked"; + /** @enum {string} */ readonly type?: "offline" | "online"; readonly user_agent?: string; }; readonly amount?: Partial & Partial<"">; readonly currency?: string; + /** @enum {string} */ readonly interval?: "one_time" | "scheduled" | "variable"; + /** @enum {string} */ readonly notification_method?: "deprecated_none" | "email" | "manual" | "none" | "stripe_email"; }; readonly metadata?: { readonly [key: string]: string }; @@ -28940,6 +30129,7 @@ export interface operations { * @description Optional parameters for the receiver flow. Can be set only if the source is a receiver (`flow` is `receiver`). */ readonly receiver?: { + /** @enum {string} */ readonly refund_attributes_method?: "email" | "manual" | "none"; }; /** @@ -28960,6 +30150,7 @@ export interface operations { readonly description?: string; readonly parent?: string; readonly quantity?: number; + /** @enum {string} */ readonly type?: "discount" | "shipping" | "sku" | "tax"; }[]; /** order_shipping */ @@ -28985,6 +30176,7 @@ export interface operations { readonly token?: string; /** @description The `type` of the source to create. Required unless `customer` and `original_source` are specified (see the [Cloning card Sources](https://stripe.com/docs/sources/connect#cloning-card-sources) guide) */ readonly type?: string; + /** @enum {string} */ readonly usage?: "reusable" | "single_use"; }; }; @@ -29076,13 +30268,17 @@ export interface operations { readonly ip?: string; readonly user_agent?: string; }; + /** @enum {string} */ readonly status: "accepted" | "pending" | "refused" | "revoked"; + /** @enum {string} */ readonly type?: "offline" | "online"; readonly user_agent?: string; }; readonly amount?: Partial & Partial<"">; readonly currency?: string; + /** @enum {string} */ readonly interval?: "one_time" | "scheduled" | "variable"; + /** @enum {string} */ readonly notification_method?: "deprecated_none" | "email" | "manual" | "none" | "stripe_email"; }; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ @@ -29116,6 +30312,7 @@ export interface operations { readonly description?: string; readonly parent?: string; readonly quantity?: number; + /** @enum {string} */ readonly type?: "discount" | "shipping" | "sku" | "tax"; }[]; /** order_shipping */ @@ -29196,7 +30393,10 @@ export interface operations { readonly data: readonly components["schemas"]["source_transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -29304,7 +30504,10 @@ export interface operations { readonly data: readonly components["schemas"]["subscription_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -29358,6 +30561,7 @@ export interface operations { * Use `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes). * * Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not create a subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more. + * @enum {string} */ readonly payment_behavior?: "allow_incomplete" | "error_if_incomplete" | "pending_if_incomplete"; /** @description The identifier of the plan to add to the subscription. */ @@ -29370,6 +30574,7 @@ export interface operations { * Passing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`. * * Prorations can be disabled by passing `none`. + * @enum {string} */ readonly proration_behavior?: "always_invoice" | "create_prorations" | "none"; /** @@ -29459,6 +30664,7 @@ export interface operations { * Use `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes). * * Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not create a subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more. + * @enum {string} */ readonly payment_behavior?: "allow_incomplete" | "error_if_incomplete" | "pending_if_incomplete"; /** @description The identifier of the new plan for this subscription item. */ @@ -29471,6 +30677,7 @@ export interface operations { * Passing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`. * * Prorations can be disabled by passing `none`. + * @enum {string} */ readonly proration_behavior?: "always_invoice" | "create_prorations" | "none"; /** @@ -29520,6 +30727,7 @@ export interface operations { * Passing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`. * * Prorations can be disabled by passing `none`. + * @enum {string} */ readonly proration_behavior?: "always_invoice" | "create_prorations" | "none"; /** @@ -29560,7 +30768,10 @@ export interface operations { readonly data: readonly components["schemas"]["usage_record_summary"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -29612,7 +30823,10 @@ export interface operations { readonly requestBody: { readonly content: { readonly "application/x-www-form-urlencoded": { - /** @description Valid values are `increment` (default) or `set`. When using `increment` the specified `quantity` will be added to the usage at the specified timestamp. The `set` action will overwrite the usage quantity at that timestamp. If the subscription has [billing thresholds](https://stripe.com/docs/api/subscriptions/object#subscription_object-billing_thresholds), `increment` is the only allowed value. */ + /** + * @description Valid values are `increment` (default) or `set`. When using `increment` the specified `quantity` will be added to the usage at the specified timestamp. The `set` action will overwrite the usage quantity at that timestamp. If the subscription has [billing thresholds](https://stripe.com/docs/api/subscriptions/object#subscription_object-billing_thresholds), `increment` is the only allowed value. + * @enum {string} + */ readonly action?: "increment" | "set"; /** @description Specifies which fields in the response should be expanded. */ readonly expand?: readonly string[]; @@ -29682,7 +30896,10 @@ export interface operations { readonly data: readonly components["schemas"]["subscription_schedule"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -29733,6 +30950,7 @@ export interface operations { readonly reset_billing_cycle_anchor?: boolean; }> & Partial<"">; + /** @enum {string} */ readonly collection_method?: "charge_automatically" | "send_invoice"; readonly default_payment_method?: string; /** subscription_schedules_param */ @@ -29740,7 +30958,10 @@ export interface operations { readonly days_until_due?: number; }; }; - /** @description Configures how the subscription schedule behaves when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running.`cancel` will end the subscription schedule and cancel the underlying subscription. */ + /** + * @description Configures how the subscription schedule behaves when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running.`cancel` will end the subscription schedule and cancel the underlying subscription. + * @enum {string} + */ readonly end_behavior?: "cancel" | "none" | "release" | "renew"; /** @description Specifies which fields in the response should be expanded. */ readonly expand?: readonly string[]; @@ -29756,6 +30977,7 @@ export interface operations { readonly reset_billing_cycle_anchor?: boolean; }> & Partial<"">; + /** @enum {string} */ readonly collection_method?: "charge_automatically" | "send_invoice"; readonly coupon?: string; readonly default_payment_method?: string; @@ -29776,6 +30998,7 @@ export interface operations { readonly quantity?: number; readonly tax_rates?: Partial & Partial<"">; }[]; + /** @enum {string} */ readonly proration_behavior?: "always_invoice" | "create_prorations" | "none"; readonly tax_percent?: number; readonly trial?: boolean; @@ -29853,6 +31076,7 @@ export interface operations { readonly reset_billing_cycle_anchor?: boolean; }> & Partial<"">; + /** @enum {string} */ readonly collection_method?: "charge_automatically" | "send_invoice"; readonly default_payment_method?: string; /** subscription_schedules_param */ @@ -29860,7 +31084,10 @@ export interface operations { readonly days_until_due?: number; }; }; - /** @description Configures how the subscription schedule behaves when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running.`cancel` will end the subscription schedule and cancel the underlying subscription. */ + /** + * @description Configures how the subscription schedule behaves when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running.`cancel` will end the subscription schedule and cancel the underlying subscription. + * @enum {string} + */ readonly end_behavior?: "cancel" | "none" | "release" | "renew"; /** @description Specifies which fields in the response should be expanded. */ readonly expand?: readonly string[]; @@ -29874,6 +31101,7 @@ export interface operations { readonly reset_billing_cycle_anchor?: boolean; }> & Partial<"">; + /** @enum {string} */ readonly collection_method?: "charge_automatically" | "send_invoice"; readonly coupon?: string; readonly default_payment_method?: string; @@ -29893,6 +31121,7 @@ export interface operations { readonly quantity?: number; readonly tax_rates?: Partial & Partial<"">; }[]; + /** @enum {string} */ readonly proration_behavior?: "always_invoice" | "create_prorations" | "none"; readonly start_date?: Partial & Partial<"now">; readonly tax_percent?: number; @@ -29901,7 +31130,10 @@ export interface operations { }[]; /** @description This field has been renamed to `proration_behavior`. `prorate=true` can be replaced with `proration_behavior=create_prorations` and `prorate=false` can be replaced with `proration_behavior=none`. */ readonly prorate?: boolean; - /** @description If the update changes the current phase, indicates if the changes should be prorated. Valid values are `create_prorations` or `none`, and the default value is `create_prorations`. */ + /** + * @description If the update changes the current phase, indicates if the changes should be prorated. Valid values are `create_prorations` or `none`, and the default value is `create_prorations`. + * @enum {string} + */ readonly proration_behavior?: "always_invoice" | "create_prorations" | "none"; }; }; @@ -30033,7 +31265,10 @@ export interface operations { readonly data: readonly components["schemas"]["subscription"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -30097,7 +31332,10 @@ export interface operations { readonly cancel_at?: number; /** @description Boolean indicating whether this subscription should cancel at the end of the current period. */ readonly cancel_at_period_end?: boolean; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. + * @enum {string} + */ readonly collection_method?: "charge_automatically" | "send_invoice"; /** @description The code of the coupon to apply to this subscription. A coupon applied to a subscription will only affect invoices created for that particular subscription. */ readonly coupon?: string; @@ -30134,10 +31372,12 @@ export interface operations { * Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not create a subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more. * * `pending_if_incomplete` is only used with updates and cannot be passed when creating a subscription. + * @enum {string} */ readonly payment_behavior?: "allow_incomplete" | "error_if_incomplete" | "pending_if_incomplete"; /** @description Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval. */ readonly pending_invoice_item_interval?: Partial<{ + /** @enum {string} */ readonly interval: "day" | "month" | "week" | "year"; readonly interval_count?: number; }> & @@ -30148,6 +31388,7 @@ export interface operations { * @description Determines how to handle [prorations](https://stripe.com/docs/subscriptions/billing-cycle#prorations) resulting from the `billing_cycle_anchor`. Valid values are `create_prorations` or `none`. * * Passing `create_prorations` will cause proration invoice items to be created when applicable. Prorations can be disabled by passing `none`. If no value is passed, the default is `create_prorations`. + * @enum {string} */ readonly proration_behavior?: "always_invoice" | "create_prorations" | "none"; /** @description A non-negative decimal (with at most four decimal places) between 0 and 100. This represents the percentage of the subscription invoice subtotal that will be calculated and added as tax to the final amount in each billing period. For example, a plan which charges $10/month with a `tax_percent` of `20.0` will charge $12 per invoice. To unset a previously-set value, pass an empty string. This field has been deprecated and will be removed in a future API version, for further information view the [migration docs](https://stripe.com/docs/billing/migration/taxes) for `tax_rates`. */ @@ -30219,7 +31460,10 @@ export interface operations { readonly "application/x-www-form-urlencoded": { /** @description A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice subtotal that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions). */ readonly application_fee_percent?: number; - /** @description Either `now` or `unchanged`. Setting the value to `now` resets the subscription's billing cycle anchor to the current time. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle). */ + /** + * @description Either `now` or `unchanged`. Setting the value to `now` resets the subscription's billing cycle anchor to the current time. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle). + * @enum {string} + */ readonly billing_cycle_anchor?: "now" | "unchanged"; /** @description Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds. */ readonly billing_thresholds?: Partial<{ @@ -30231,7 +31475,10 @@ export interface operations { readonly cancel_at?: Partial & Partial<"">; /** @description Boolean indicating whether this subscription should cancel at the end of the current period. */ readonly cancel_at_period_end?: boolean; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. + * @enum {string} + */ readonly collection_method?: "charge_automatically" | "send_invoice"; /** @description The code of the coupon to apply to this subscription. A coupon applied to a subscription will only affect invoices created for that particular subscription. */ readonly coupon?: string; @@ -30265,6 +31512,7 @@ export interface operations { readonly off_session?: boolean; /** @description If specified, payment collection for this subscription will be paused. */ readonly pause_collection?: Partial<{ + /** @enum {string} */ readonly behavior: "keep_as_draft" | "mark_uncollectible" | "void"; /** Format: unix-time */ readonly resumes_at?: number; @@ -30276,10 +31524,12 @@ export interface operations { * Use `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes). * * Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not create a subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more. + * @enum {string} */ readonly payment_behavior?: "allow_incomplete" | "error_if_incomplete" | "pending_if_incomplete"; /** @description Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval. */ readonly pending_invoice_item_interval?: Partial<{ + /** @enum {string} */ readonly interval: "day" | "month" | "week" | "year"; readonly interval_count?: number; }> & @@ -30292,6 +31542,7 @@ export interface operations { * Passing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`. * * Prorations can be disabled by passing `none`. + * @enum {string} */ readonly proration_behavior?: "always_invoice" | "create_prorations" | "none"; /** @@ -30410,7 +31661,10 @@ export interface operations { readonly data: readonly components["schemas"]["tax_rate"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -30589,7 +31843,10 @@ export interface operations { readonly data: readonly components["schemas"]["terminal.location"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -30783,7 +32040,10 @@ export interface operations { readonly data: readonly components["schemas"]["terminal.reader"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -30955,6 +32215,7 @@ export interface operations { * @description Information for the account this token will represent. */ readonly account?: { + /** @enum {string} */ readonly business_type?: "company" | "government_entity" | "individual" | "non_profit"; /** company_specs */ readonly company?: { @@ -30994,6 +32255,7 @@ export interface operations { readonly name_kanji?: string; readonly owners_provided?: boolean; readonly phone?: string; + /** @enum {string} */ readonly structure?: | "" | "government_instrumentality" @@ -31095,6 +32357,7 @@ export interface operations { */ readonly bank_account?: { readonly account_holder_name?: string; + /** @enum {string} */ readonly account_holder_type?: "company" | "individual"; readonly account_number: string; readonly country: string; @@ -31278,7 +32541,10 @@ export interface operations { readonly data: readonly components["schemas"]["topup"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -31466,7 +32732,10 @@ export interface operations { readonly data: readonly components["schemas"]["transfer"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -31519,7 +32788,10 @@ export interface operations { readonly metadata?: { readonly [key: string]: string }; /** @description You can use this parameter to transfer funds from a charge before they are added to your available balance. A pending balance will transfer immediately but the funds will not become available until the original charge becomes available. [See the Connect documentation](https://stripe.com/docs/connect/charges-transfers#transfer-availability) for details. */ readonly source_transaction?: string; - /** @description The source balance to use for this transfer. One of `bank_account`, `card`, or `fpx`. For most users, this will default to `card`. */ + /** + * @description The source balance to use for this transfer. One of `bank_account`, `card`, or `fpx`. For most users, this will default to `card`. + * @enum {string} + */ readonly source_type?: "bank_account" | "card" | "fpx"; /** @description A string that identifies this transaction as part of a group. See the [Connect documentation](https://stripe.com/docs/connect/charges-transfers#transfer-options) for details. */ readonly transfer_group?: string; @@ -31553,7 +32825,10 @@ export interface operations { readonly data: readonly components["schemas"]["transfer_reversal"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -31777,7 +33052,10 @@ export interface operations { readonly data: readonly components["schemas"]["webhook_endpoint"][]; /** @description True if this list has another page of items after this one that can be fetched. */ readonly has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ readonly object: "list"; /** @description The URL where this list can be accessed. */ readonly url: string; @@ -31816,7 +33094,10 @@ export interface operations { readonly requestBody: { readonly content: { readonly "application/x-www-form-urlencoded": { - /** @description Events sent to this endpoint will be generated with this Stripe Version instead of your account's default Stripe Version. */ + /** + * @description Events sent to this endpoint will be generated with this Stripe Version instead of your account's default Stripe Version. + * @enum {string} + */ readonly api_version?: | "2011-01-01" | "2011-06-21" diff --git a/test/v3/expected/stripe.ts b/test/v3/expected/stripe.ts index 7851c5445..61212c8a2 100644 --- a/test/v3/expected/stripe.ts +++ b/test/v3/expected/stripe.ts @@ -1494,7 +1494,10 @@ export interface components { account: { /** @description Business information about the account. */ business_profile?: Partial | null; - /** @description The business type. */ + /** + * @description The business type. + * @enum {string|null} + */ business_type?: ("company" | "government_entity" | "individual" | "non_profit") | null; capabilities?: components["schemas"]["account_capabilities"]; /** @description Whether the account can create live charges. */ @@ -1522,7 +1525,10 @@ export interface components { data: (Partial & Partial)[]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -1532,7 +1538,10 @@ export interface components { individual?: components["schemas"]["person"]; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata?: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "account"; /** @description Whether Stripe can send payouts to this account. */ payouts_enabled?: boolean; @@ -1540,7 +1549,10 @@ export interface components { /** @description Options for customizing how the account functions within Stripe. */ settings?: Partial | null; tos_acceptance?: components["schemas"]["account_tos_acceptance"]; - /** @description The Stripe account type. Can be `standard`, `express`, or `custom`. */ + /** + * @description The Stripe account type. Can be `standard`, `express`, or `custom`. + * @enum {string} + */ type?: "custom" | "express" | "standard"; }; /** AccountBrandingSettings */ @@ -1575,19 +1587,40 @@ export interface components { }; /** AccountCapabilities */ account_capabilities: { - /** @description The status of the BECS Direct Debit (AU) payments capability of the account, or whether the account can directly process BECS Direct Debit (AU) charges. */ + /** + * @description The status of the BECS Direct Debit (AU) payments capability of the account, or whether the account can directly process BECS Direct Debit (AU) charges. + * @enum {string} + */ au_becs_debit_payments?: "active" | "inactive" | "pending"; - /** @description The status of the card issuing capability of the account, or whether you can use Issuing to distribute funds on cards */ + /** + * @description The status of the card issuing capability of the account, or whether you can use Issuing to distribute funds on cards + * @enum {string} + */ card_issuing?: "active" | "inactive" | "pending"; - /** @description The status of the card payments capability of the account, or whether the account can directly process credit and debit card charges. */ + /** + * @description The status of the card payments capability of the account, or whether the account can directly process credit and debit card charges. + * @enum {string} + */ card_payments?: "active" | "inactive" | "pending"; - /** @description The status of the legacy payments capability of the account. */ + /** + * @description The status of the legacy payments capability of the account. + * @enum {string} + */ legacy_payments?: "active" | "inactive" | "pending"; - /** @description The status of the tax reporting 1099-K (US) capability of the account. */ + /** + * @description The status of the tax reporting 1099-K (US) capability of the account. + * @enum {string} + */ tax_reporting_us_1099_k?: "active" | "inactive" | "pending"; - /** @description The status of the tax reporting 1099-MISC (US) capability of the account. */ + /** + * @description The status of the tax reporting 1099-MISC (US) capability of the account. + * @enum {string} + */ tax_reporting_us_1099_misc?: "active" | "inactive" | "pending"; - /** @description The status of the transfers capability of the account, or whether your platform can transfer funds to the account. */ + /** + * @description The status of the transfers capability of the account, or whether your platform can transfer funds to the account. + * @enum {string} + */ transfers?: "active" | "inactive" | "pending"; }; /** AccountCapabilityRequirements */ @@ -1648,7 +1681,10 @@ export interface components { * @description The timestamp at which this account link will expire. */ expires_at: number; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "account_link"; /** @description The URL for the account link. */ url: string; @@ -1692,7 +1728,10 @@ export interface components { }; /** AccountRequirementsError */ account_requirements_error: { - /** @description The code for the type of error. */ + /** + * @description The code for the type of error. + * @enum {string} + */ code: | "invalid_address_city_state_postal_code" | "invalid_street_address" @@ -1793,7 +1832,10 @@ export interface components { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata?: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "alipay_account"; /** @description If the Alipay account object is not reusable, the exact amount that you can create a charge for. */ payment_amount?: number | null; @@ -1827,7 +1869,10 @@ export interface components { source?: Partial & Partial & Partial; - /** @description The type of error returned. One of `api_connection_error`, `api_error`, `authentication_error`, `card_error`, `idempotency_error`, `invalid_request_error`, or `rate_limit_error` */ + /** + * @description The type of error returned. One of `api_connection_error`, `api_error`, `authentication_error`, `card_error`, `idempotency_error`, `invalid_request_error`, or `rate_limit_error` + * @enum {string} + */ type: | "api_connection_error" | "api_error" @@ -1849,7 +1894,10 @@ export interface components { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "apple_pay_domain"; }; /** Application */ @@ -1858,7 +1906,10 @@ export interface components { id: string; /** @description The name of the application. */ name?: string | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "application"; }; /** PlatformFee */ @@ -1886,7 +1937,10 @@ export interface components { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "application_fee"; /** @description ID of the corresponding charge on the platform account, if this fee was the result of a charge using the `destination` parameter. */ originating_transaction?: (Partial & Partial) | null; @@ -1901,7 +1955,10 @@ export interface components { data: components["schemas"]["fee_refund"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -1928,7 +1985,10 @@ export interface components { connect_reserved?: components["schemas"]["balance_amount"][]; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "balance"; /** @description Funds that are not yet available in the balance, due to the 7-day rolling pay cycle. The pending balance for each currency, and for each payment type, can be found in the `source_types` property. */ pending: components["schemas"]["balance_amount"][]; @@ -1984,7 +2044,10 @@ export interface components { id: string; /** @description Net amount of the transaction, in %s. */ net: number; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "balance_transaction"; /** @description [Learn more](https://stripe.com/docs/reports/reporting-categories) about how reporting categories can help you understand balance transactions from an accounting perspective. */ reporting_category: string; @@ -2009,7 +2072,10 @@ export interface components { | null; /** @description If the transaction's net funds are available in the Stripe balance yet. Either `available` or `pending`. */ status: string; - /** @description Transaction type: `adjustment`, `advance`, `advance_funding`, `application_fee`, `application_fee_refund`, `charge`, `connect_collection_transfer`, `issuing_authorization_hold`, `issuing_authorization_release`, `issuing_transaction`, `payment`, `payment_failure_refund`, `payment_refund`, `payout`, `payout_cancel`, `payout_failure`, `refund`, `refund_failure`, `reserve_transaction`, `reserved_funds`, `stripe_fee`, `stripe_fx_fee`, `tax_fee`, `topup`, `topup_reversal`, `transfer`, `transfer_cancel`, `transfer_failure`, or `transfer_refund`. [Learn more](https://stripe.com/docs/reports/balance-transaction-types) about balance transaction types and what they represent. If you are looking to classify transactions for accounting purposes, you might want to consider `reporting_category` instead. */ + /** + * @description Transaction type: `adjustment`, `advance`, `advance_funding`, `application_fee`, `application_fee_refund`, `charge`, `connect_collection_transfer`, `issuing_authorization_hold`, `issuing_authorization_release`, `issuing_transaction`, `payment`, `payment_failure_refund`, `payment_refund`, `payout`, `payout_cancel`, `payout_failure`, `refund`, `refund_failure`, `reserve_transaction`, `reserved_funds`, `stripe_fee`, `stripe_fx_fee`, `tax_fee`, `topup`, `topup_reversal`, `transfer`, `transfer_cancel`, `transfer_failure`, or `transfer_refund`. [Learn more](https://stripe.com/docs/reports/balance-transaction-types) about balance transaction types and what they represent. If you are looking to classify transactions for accounting purposes, you might want to consider `reporting_category` instead. + * @enum {string} + */ type: | "adjustment" | "advance" @@ -2080,7 +2146,10 @@ export interface components { last4: string; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata?: { [key: string]: string } | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "bank_account"; /** @description The routing transit number for the bank account. */ routing_number?: string | null; @@ -2124,7 +2193,10 @@ export interface components { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "billing_portal.session"; /** @description The URL to which Stripe should send customers when they click on the link to return to your website. */ return_url: string; @@ -2168,7 +2240,10 @@ export interface components { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "bitcoin_receiver"; /** @description The ID of the payment created from the receiver, if any. Hidden when viewing the receiver with a publishable key. */ payment?: string | null; @@ -2183,7 +2258,10 @@ export interface components { data: components["schemas"]["bitcoin_transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -2208,7 +2286,10 @@ export interface components { currency: string; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "bitcoin_transaction"; /** @description The receiver to which this transaction was sent. */ receiver: string; @@ -2224,7 +2305,10 @@ export interface components { account: Partial & Partial; /** @description The identifier for the capability. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "capability"; /** @description Whether the capability has been requested. */ requested: boolean; @@ -2234,7 +2318,10 @@ export interface components { */ requested_at?: number | null; requirements?: components["schemas"]["account_capability_requirements"]; - /** @description The status of the capability. Can be `active`, `inactive`, `pending`, or `unrequested`. */ + /** + * @description The status of the capability. Can be `active`, `inactive`, `pending`, or `unrequested`. + * @enum {string} + */ status: "active" | "disabled" | "inactive" | "pending" | "unrequested"; }; /** @@ -2299,7 +2386,10 @@ export interface components { metadata: { [key: string]: string }; /** @description Cardholder name. */ name?: string | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "card"; /** @description The recipient that this card belongs to. This attribute will not be in the card object if the card belongs to a customer or account instead. */ recipient?: (Partial & Partial) | null; @@ -2365,7 +2455,10 @@ export interface components { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "charge"; /** @description The account (if any) the charge was made on behalf of without triggering an automatic transfer. See the [Connect documentation](https://stripe.com/docs/connect/charges-transfers) for details. */ on_behalf_of?: (Partial & Partial) | null; @@ -2398,7 +2491,10 @@ export interface components { data: components["schemas"]["refund"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -2508,7 +2604,10 @@ export interface components { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description The IETF language tag of the locale Checkout is displayed in. If blank or `auto`, the browser's locale is used. */ + /** + * @description The IETF language tag of the locale Checkout is displayed in. If blank or `auto`, the browser's locale is used. + * @enum {string|null} + */ locale?: | ( | "auto" @@ -2532,9 +2631,15 @@ export interface components { | null; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata?: { [key: string]: string } | null; - /** @description The mode of the Checkout Session, one of `payment`, `setup`, or `subscription`. */ + /** + * @description The mode of the Checkout Session, one of `payment`, `setup`, or `subscription`. + * @enum {string|null} + */ mode?: ("payment" | "setup" | "subscription") | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "checkout.session"; /** @description The ID of the PaymentIntent for Checkout Sessions in `payment` mode. */ payment_intent?: (Partial & Partial) | null; @@ -2556,6 +2661,7 @@ export interface components { * relevant text on the page, such as the submit button. `submit_type` can only be * specified on Checkout Sessions in `payment` mode, but not Checkout Sessions * in `subscription` or `setup` mode. + * @enum {string|null} */ submit_type?: ("auto" | "book" | "donate" | "pay") | null; /** @description The ID of the subscription for Checkout Sessions in `subscription` mode. */ @@ -2601,7 +2707,10 @@ export interface components { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "connect_collection_transfer"; }; /** @@ -2618,7 +2727,10 @@ export interface components { default_currency: string; /** @description Unique identifier for the object. Represented as the ISO country code for this country. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "country_spec"; /** @description Currencies that can be accepted in the specific country (for transfers). */ supported_bank_account_currencies: { [key: string]: string[] }; @@ -2658,7 +2770,10 @@ export interface components { created: number; /** @description If `amount_off` has been set, the three-letter [ISO code for the currency](https://stripe.com/docs/currencies) of the amount to take off. */ currency?: string | null; - /** @description One of `forever`, `once`, and `repeating`. Describes how long a customer who applies this coupon will get the discount. */ + /** + * @description One of `forever`, `once`, and `repeating`. Describes how long a customer who applies this coupon will get the discount. + * @enum {string} + */ duration: "forever" | "once" | "repeating"; /** @description If `duration` is `repeating`, the number of months the coupon applies. Null if coupon `duration` is `forever` or `once`. */ duration_in_months?: number | null; @@ -2672,7 +2787,10 @@ export interface components { metadata: { [key: string]: string }; /** @description Name of the coupon displayed to customers on for instance invoices or receipts. */ name?: string | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "coupon"; /** @description Percent that will be taken off the subtotal of any invoices for this customer for the duration of the coupon. For example, a coupon with percent_off of 50 will make a %s100 invoice %s50 instead. */ percent_off?: number | null; @@ -2723,7 +2841,10 @@ export interface components { data: components["schemas"]["credit_note_line_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -2736,17 +2857,26 @@ export interface components { metadata: { [key: string]: string }; /** @description A unique number that identifies this particular credit note and appears on the PDF of the credit note and its associated invoice. */ number: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "credit_note"; /** @description Amount that was credited outside of Stripe. */ out_of_band_amount?: number | null; /** @description The link to download the PDF of the credit note. */ pdf: string; - /** @description Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory` */ + /** + * @description Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory` + * @enum {string|null} + */ reason?: ("duplicate" | "fraudulent" | "order_change" | "product_unsatisfactory") | null; /** @description Refund related to this credit note. */ refund?: (Partial & Partial) | null; - /** @description Status of this credit note, one of `issued` or `void`. Learn more about [voiding credit notes](https://stripe.com/docs/billing/invoices/credit-notes#voiding). */ + /** + * @description Status of this credit note, one of `issued` or `void`. Learn more about [voiding credit notes](https://stripe.com/docs/billing/invoices/credit-notes#voiding). + * @enum {string} + */ status: "issued" | "void"; /** @description The integer amount in **%s** representing the amount of the credit note, excluding tax and discount. */ subtotal: number; @@ -2754,7 +2884,10 @@ export interface components { tax_amounts: components["schemas"]["credit_note_tax_amount"][]; /** @description The integer amount in **%s** representing the total amount of the credit note, including tax and discount. */ total: number; - /** @description Type of this credit note, one of `pre_payment` or `post_payment`. A `pre_payment` credit note means it was issued when the invoice was open. A `post_payment` credit note means it was issued when the invoice was paid. */ + /** + * @description Type of this credit note, one of `pre_payment` or `post_payment`. A `pre_payment` credit note means it was issued when the invoice was open. A `post_payment` credit note means it was issued when the invoice was paid. + * @enum {string} + */ type: "post_payment" | "pre_payment"; /** * Format: unix-time @@ -2776,7 +2909,10 @@ export interface components { invoice_line_item?: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "credit_note_line_item"; /** @description The number of units of product being credited. */ quantity?: number | null; @@ -2784,7 +2920,10 @@ export interface components { tax_amounts: components["schemas"]["credit_note_tax_amount"][]; /** @description The tax rates which apply to the line item. */ tax_rates: components["schemas"]["tax_rate"][]; - /** @description The type of the credit note line item, one of `invoice_line_item` or `custom_line_item`. When the type is `invoice_line_item` there is an additional `invoice_line_item` property on the resource the value of which is the id of the credited line item on the invoice. */ + /** + * @description The type of the credit note line item, one of `invoice_line_item` or `custom_line_item`. When the type is `invoice_line_item` there is an additional `invoice_line_item` property on the resource the value of which is the id of the credited line item on the invoice. + * @enum {string} + */ type: "custom_line_item" | "invoice_line_item"; /** @description The cost of each unit of product being credited. */ unit_amount?: number | null; @@ -2858,7 +2997,10 @@ export interface components { name?: string | null; /** @description The suffix of the customer's next invoice number, e.g., 0001. */ next_invoice_sequence?: number; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "customer"; /** @description The customer's phone number. */ phone?: string | null; @@ -2879,7 +3021,10 @@ export interface components { Partial)[]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -2893,12 +3038,18 @@ export interface components { data: components["schemas"]["subscription"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; }; - /** @description Describes the customer's tax exemption status. One of `none`, `exempt`, or `reverse`. When set to `reverse`, invoice and receipt PDFs include the text **"Reverse charge"**. */ + /** + * @description Describes the customer's tax exemption status. One of `none`, `exempt`, or `reverse`. When set to `reverse`, invoice and receipt PDFs include the text **"Reverse charge"**. + * @enum {string|null} + */ tax_exempt?: ("exempt" | "none" | "reverse") | null; /** * TaxIDsList @@ -2909,7 +3060,10 @@ export interface components { data: components["schemas"]["tax_id"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -2924,7 +3078,10 @@ export interface components { accepted_at?: number | null; offline?: components["schemas"]["offline_acceptance"]; online?: components["schemas"]["online_acceptance"]; - /** @description The type of customer acceptance information included with the Mandate. One of `online` or `offline`. */ + /** + * @description The type of customer acceptance information included with the Mandate. One of `online` or `offline`. + * @enum {string} + */ type: "offline" | "online"; }; /** @@ -2962,9 +3119,15 @@ export interface components { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata?: { [key: string]: string } | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "customer_balance_transaction"; - /** @description Transaction type: `adjustment`, `applied_to_invoice`, `credit_note`, `initial`, `invoice_too_large`, `invoice_too_small`, `unspent_receiver_credit`, or `unapplied_from_invoice`. See the [Customer Balance page](https://stripe.com/docs/billing/customer/balance#types) to learn more about transaction types. */ + /** + * @description Transaction type: `adjustment`, `applied_to_invoice`, `credit_note`, `initial`, `invoice_too_large`, `invoice_too_small`, `unspent_receiver_credit`, or `unapplied_from_invoice`. See the [Customer Balance page](https://stripe.com/docs/billing/customer/balance#types) to learn more about transaction types. + * @enum {string} + */ type: | "adjustment" | "applied_to_invoice" @@ -2978,85 +3141,139 @@ export interface components { }; /** DeletedAccount */ deleted_account: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "account"; }; /** AlipayDeletedAccount */ deleted_alipay_account: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "alipay_account"; }; /** DeletedApplePayDomain */ deleted_apple_pay_domain: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "apple_pay_domain"; }; /** DeletedBankAccount */ deleted_bank_account: { /** @description Three-letter [ISO code for the currency](https://stripe.com/docs/payouts) paid out to the bank account. */ currency?: string | null; - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "bank_account"; }; /** BitcoinDeletedReceiver */ deleted_bitcoin_receiver: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "bitcoin_receiver"; }; /** DeletedCard */ deleted_card: { /** @description Three-letter [ISO code for the currency](https://stripe.com/docs/payouts) paid out to the bank account. */ currency?: string | null; - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "card"; }; /** DeletedCoupon */ deleted_coupon: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "coupon"; }; /** DeletedCustomer */ deleted_customer: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "customer"; }; /** DeletedDiscount */ deleted_discount: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "discount"; }; /** Polymorphic */ @@ -3064,20 +3281,32 @@ export interface components { Partial; /** DeletedInvoice */ deleted_invoice: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "invoice"; }; /** DeletedInvoiceItem */ deleted_invoiceitem: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "invoiceitem"; }; /** Polymorphic */ @@ -3087,110 +3316,182 @@ export interface components { Partial; /** DeletedPerson */ deleted_person: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "person"; }; /** DeletedPlan */ deleted_plan: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "plan"; }; /** DeletedProduct */ deleted_product: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "product"; }; /** RadarListDeletedList */ "deleted_radar.value_list": { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "radar.value_list"; }; /** RadarListDeletedListItem */ "deleted_radar.value_list_item": { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "radar.value_list_item"; }; /** DeletedTransferRecipient */ deleted_recipient: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "recipient"; }; /** DeletedSKU */ deleted_sku: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "sku"; }; /** DeletedSubscriptionItem */ deleted_subscription_item: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "subscription_item"; }; /** deleted_tax_id */ deleted_tax_id: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "tax_id"; }; /** TerminalLocationDeletedLocation */ "deleted_terminal.location": { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "terminal.location"; }; /** TerminalReaderDeletedReader */ "deleted_terminal.reader": { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "terminal.reader"; }; /** NotificationWebhookEndpointDeleted */ deleted_webhook_endpoint: { - /** @description Always true for a deleted object */ + /** + * @description Always true for a deleted object + * @enum {boolean} + */ deleted: true; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "webhook_endpoint"; }; /** DeliveryEstimate */ @@ -3225,7 +3526,10 @@ export interface components { * @description If the coupon has a duration of `repeating`, the date that this discount will end. If the coupon has a duration of `once` or `forever`, this attribute will be null. */ end?: number | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "discount"; /** * Format: unix-time @@ -3269,13 +3573,19 @@ export interface components { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "dispute"; /** @description ID of the PaymentIntent that was disputed. */ payment_intent?: (Partial & Partial) | null; /** @description Reason given by cardholder for dispute. Possible values are `bank_cannot_process`, `check_returned`, `credit_not_processed`, `customer_initiated`, `debit_not_authorized`, `duplicate`, `fraudulent`, `general`, `incorrect_account_details`, `insufficient_funds`, `product_not_received`, `product_unacceptable`, `subscription_canceled`, or `unrecognized`. Read more about [dispute reasons](https://stripe.com/docs/disputes/categories). */ reason: string; - /** @description Current status of dispute. Possible values are `warning_needs_response`, `warning_under_review`, `warning_closed`, `needs_response`, `under_review`, `charge_refunded`, `won`, or `lost`. */ + /** + * @description Current status of dispute. Possible values are `warning_needs_response`, `warning_under_review`, `warning_closed`, `needs_response`, `under_review`, `charge_refunded`, `won`, or `lost`. + * @enum {string} + */ status: | "charge_refunded" | "lost" @@ -3373,7 +3683,10 @@ export interface components { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "ephemeral_key"; /** @description The key's secret. You can use this value to make authorized requests to the Stripe API. */ secret?: string; @@ -3429,7 +3742,10 @@ export interface components { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "event"; /** @description Number of webhooks that have yet to be successfully delivered (i.e., to return a 20x response) to the URLs you've specified. */ pending_webhooks: number; @@ -3455,7 +3771,10 @@ export interface components { exchange_rate: { /** @description Unique identifier for the object. Represented as the three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) in lowercase. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "exchange_rate"; /** @description Hash where the keys are supported currencies and the values are the exchange rate at which the base id currency converts to the key currency. */ rates: { [key: string]: number }; @@ -3501,7 +3820,10 @@ export interface components { id: string; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "fee_refund"; }; /** @@ -3533,12 +3855,18 @@ export interface components { data: components["schemas"]["file_link"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; } | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "file"; /** @description The purpose of the file. Possible values are `additional_verification`, `business_icon`, `business_logo`, `customer_signature`, `dispute_evidence`, `finance_report_run`, `identity_document`, `pci_document`, `sigma_scheduled_query`, or `tax_document_user_upload`. */ purpose: string; @@ -3578,7 +3906,10 @@ export interface components { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "file_link"; /** @description The publicly accessible URL to download the file. */ url?: string | null; @@ -3671,7 +4002,10 @@ export interface components { attempted: boolean; /** @description Controls whether Stripe will perform [automatic collection](https://stripe.com/docs/billing/invoices/workflow/#auto_advance) of the invoice. When `false`, the invoice's state will not automatically advance without an explicit action. */ auto_advance?: boolean; - /** @description Indicates the reason why the invoice was created. `subscription_cycle` indicates an invoice created by a subscription advancing into a new period. `subscription_create` indicates an invoice created due to creating a subscription. `subscription_update` indicates an invoice created due to updating a subscription. `subscription` is set for all old invoices to indicate either a change to a subscription or a period advancement. `manual` is set for all invoices unrelated to a subscription (for example: created via the invoice editor). The `upcoming` value is reserved for simulated invoices per the upcoming invoice endpoint. `subscription_threshold` indicates an invoice created due to a billing threshold being reached. */ + /** + * @description Indicates the reason why the invoice was created. `subscription_cycle` indicates an invoice created by a subscription advancing into a new period. `subscription_create` indicates an invoice created due to creating a subscription. `subscription_update` indicates an invoice created due to updating a subscription. `subscription` is set for all old invoices to indicate either a change to a subscription or a period advancement. `manual` is set for all invoices unrelated to a subscription (for example: created via the invoice editor). The `upcoming` value is reserved for simulated invoices per the upcoming invoice endpoint. `subscription_threshold` indicates an invoice created due to a billing threshold being reached. + * @enum {string|null} + */ billing_reason?: | ( | "automatic_pending_invoice_item_invoice" @@ -3686,7 +4020,10 @@ export interface components { | null; /** @description ID of the latest charge generated for this invoice, if any. */ charge?: (Partial & Partial) | null; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this invoice using the default source attached to the customer. When sending an invoice, Stripe will email this invoice to the customer with payment instructions. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this invoice using the default source attached to the customer. When sending an invoice, Stripe will email this invoice to the customer with payment instructions. + * @enum {string|null} + */ collection_method?: ("charge_automatically" | "send_invoice") | null; /** * Format: unix-time @@ -3711,7 +4048,10 @@ export interface components { customer_phone?: string | null; /** @description The customer's shipping information. Until the invoice is finalized, this field will equal `customer.shipping`. Once the invoice is finalized, this field will no longer be updated. */ customer_shipping?: Partial | null; - /** @description The customer's tax exempt status. Until the invoice is finalized, this field will equal `customer.tax_exempt`. Once the invoice is finalized, this field will no longer be updated. */ + /** + * @description The customer's tax exempt status. Until the invoice is finalized, this field will equal `customer.tax_exempt`. Once the invoice is finalized, this field will no longer be updated. + * @enum {string|null} + */ customer_tax_exempt?: ("exempt" | "none" | "reverse") | null; /** @description The customer's tax IDs. Until the invoice is finalized, this field will contain the same tax IDs as `customer.tax_ids`. Once the invoice is finalized, this field will no longer be updated. */ customer_tax_ids?: components["schemas"]["invoices_resource_invoice_tax_id"][] | null; @@ -3756,7 +4096,10 @@ export interface components { data: components["schemas"]["line_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -3772,7 +4115,10 @@ export interface components { next_payment_attempt?: number | null; /** @description A unique, identifying string that appears on emails sent to the customer for this invoice. This starts with the customer's unique invoice_prefix if it is specified. */ number?: string | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "invoice"; /** @description Whether payment was successfully collected for this invoice. An invoice can be paid (most commonly) with a charge or with credit from the customer's account balance. */ paid: boolean; @@ -3798,7 +4144,10 @@ export interface components { starting_balance: number; /** @description Extra information about an invoice for the customer's credit card statement. */ statement_descriptor?: string | null; - /** @description The status of the invoice, one of `draft`, `open`, `paid`, `uncollectible`, or `void`. [Learn more](https://stripe.com/docs/billing/invoices/workflow#workflow-overview) */ + /** + * @description The status of the invoice, one of `draft`, `open`, `paid`, `uncollectible`, or `void`. [Learn more](https://stripe.com/docs/billing/invoices/workflow#workflow-overview) + * @enum {string|null} + */ status?: ("deleted" | "draft" | "open" | "paid" | "uncollectible" | "void") | null; status_transitions: components["schemas"]["invoices_status_transitions"]; /** @description The subscription that this invoice was prepared for, if any. */ @@ -3909,7 +4258,10 @@ export interface components { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "invoiceitem"; period: components["schemas"]["invoice_line_item_period"]; /** @description If the invoice item is a proration, the plan of the subscription that the proration was computed for. */ @@ -3934,7 +4286,10 @@ export interface components { }; /** InvoicesResourceInvoiceTaxID */ invoices_resource_invoice_tax_id: { - /** @description The type of the tax ID, one of `eu_vat`, `nz_gst`, `au_abn`, `in_gst`, `no_vat`, `za_vat`, `ch_vat`, `mx_rfc`, `sg_uen`, `ru_inn`, `ca_bn`, `hk_br`, `es_cif`, `tw_vat`, `th_vat`, `jp_cn`, `li_uid`, `my_itn`, `us_ein`, `kr_brn`, `ca_qst`, `my_sst`, `sg_gst`, or `unknown` */ + /** + * @description The type of the tax ID, one of `eu_vat`, `nz_gst`, `au_abn`, `in_gst`, `no_vat`, `za_vat`, `ch_vat`, `mx_rfc`, `sg_uen`, `ru_inn`, `ca_bn`, `hk_br`, `es_cif`, `tw_vat`, `th_vat`, `jp_cn`, `li_uid`, `my_itn`, `us_ein`, `kr_brn`, `ca_qst`, `my_sst`, `sg_gst`, or `unknown` + * @enum {string} + */ type: | "au_abn" | "ca_bn" @@ -4010,7 +4365,10 @@ export interface components { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "issuer_fraud_record"; /** @description The timestamp at which the card issuer posted the issuer fraud record. */ post_date: number; @@ -4028,7 +4386,10 @@ export interface components { amount: number; /** @description Whether the authorization has been approved. */ approved: boolean; - /** @description How the card details were provided. */ + /** + * @description How the card details were provided. + * @enum {string} + */ authorization_method: "chip" | "contactless" | "keyed_in" | "online" | "swipe"; /** @description List of balance transactions associated with this authorization. */ balance_transactions: components["schemas"]["balance_transaction"][]; @@ -4053,13 +4414,19 @@ export interface components { merchant_data: components["schemas"]["issuing_authorization_merchant_data"]; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "issuing.authorization"; /** @description The pending authorization request. This field will only be non-null during an `issuing_authorization.request` webhook. */ pending_request?: Partial | null; /** @description History of every time the authorization was approved/denied (whether approved/denied by you directly or by Stripe based on your `spending_controls`). If the merchant changes the authorization by performing an [incremental authorization or partial capture](https://stripe.com/docs/issuing/purchases/authorizations), you can look at this field to see the previous states of the authorization. */ request_history: components["schemas"]["issuing_authorization_request"][]; - /** @description The current status of the authorization in its lifecycle. */ + /** + * @description The current status of the authorization in its lifecycle. + * @enum {string} + */ status: "closed" | "pending" | "reversed"; /** @description List of [transactions](https://stripe.com/docs/api/issuing/transactions) associated with this authorization. */ transactions: components["schemas"]["issuing.transaction"][]; @@ -4074,7 +4441,10 @@ export interface components { "issuing.card": { /** @description The brand of the card. */ brand: string; - /** @description The reason why the card was canceled. */ + /** + * @description The reason why the card was canceled. + * @enum {string|null} + */ cancellation_reason?: ("lost" | "stolen") | null; cardholder: components["schemas"]["issuing.cardholder"]; /** @@ -4100,20 +4470,32 @@ export interface components { metadata: { [key: string]: string }; /** @description The full unredacted card number. For security reasons, this is only available for virtual cards, and will be omitted unless you explicitly request it with [the `expand` parameter](https://stripe.com/docs/api/expanding_objects). Additionally, it's only available via the ["Retrieve a card" endpoint](https://stripe.com/docs/api/issuing/cards/retrieve), not via "List all cards" or any other endpoint. */ number?: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "issuing.card"; /** @description The latest card that replaces this card, if any. */ replaced_by?: (Partial & Partial) | null; /** @description The card this card replaces, if any. */ replacement_for?: (Partial & Partial) | null; - /** @description The reason why the previous card needed to be replaced. */ + /** + * @description The reason why the previous card needed to be replaced. + * @enum {string|null} + */ replacement_reason?: ("damaged" | "expired" | "lost" | "stolen") | null; /** @description Where and how the card will be shipped. */ shipping?: Partial | null; spending_controls: components["schemas"]["issuing_card_authorization_controls"]; - /** @description Whether authorizations can be approved on this card. */ + /** + * @description Whether authorizations can be approved on this card. + * @enum {string} + */ status: "active" | "canceled" | "inactive"; - /** @description The type of the card. */ + /** + * @description The type of the card. + * @enum {string} + */ type: "physical" | "virtual"; }; /** @@ -4143,16 +4525,25 @@ export interface components { metadata: { [key: string]: string }; /** @description The cardholder's name. This will be printed on cards issued to them. */ name: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "issuing.cardholder"; /** @description The cardholder's phone number. */ phone_number?: string | null; requirements: components["schemas"]["issuing_cardholder_requirements"]; /** @description Spending rules that give you some control over how this cardholder's cards can be used. Refer to our [authorizations](https://stripe.com/docs/issuing/purchases/authorizations) documentation for more details. */ spending_controls?: Partial | null; - /** @description Specifies whether to permit authorizations on this cardholder's cards. */ + /** + * @description Specifies whether to permit authorizations on this cardholder's cards. + * @enum {string} + */ status: "active" | "blocked" | "inactive"; - /** @description One of `individual` or `company`. */ + /** + * @description One of `individual` or `company`. + * @enum {string} + */ type: "company" | "individual"; }; /** @@ -4166,7 +4557,10 @@ export interface components { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "issuing.dispute"; }; /** @@ -4195,13 +4589,19 @@ export interface components { metadata: { [key: string]: string }; /** @description The total net amount required to settle with the network. */ net_total: number; - /** @description The card network for this settlement report. One of ["visa"] */ + /** + * @description The card network for this settlement report. One of ["visa"] + * @enum {string} + */ network: "visa"; /** @description The total amount of fees owed to the network. */ network_fees: number; /** @description The Settlement Identification Number assigned by the network. */ network_settlement_identifier: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "issuing.settlement"; /** @description One of `international` or `uk_national_net`. */ settlement_service: string; @@ -4247,9 +4647,15 @@ export interface components { merchant_data: components["schemas"]["issuing_authorization_merchant_data"]; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "issuing.transaction"; - /** @description The nature of the transaction. */ + /** + * @description The nature of the transaction. + * @enum {string} + */ type: "capture" | "refund"; }; /** IssuingAuthorizationMerchantData */ @@ -4299,7 +4705,10 @@ export interface components { merchant_amount: number; /** @description The currency that was collected by the merchant and presented to the cardholder for the authorization. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). */ merchant_currency: string; - /** @description The reason for the approval or decline. */ + /** + * @description The reason for the approval or decline. + * @enum {string} + */ reason: | "account_disabled" | "card_active" @@ -4317,13 +4726,25 @@ export interface components { }; /** IssuingAuthorizationVerificationData */ issuing_authorization_verification_data: { - /** @description Whether the cardholder provided an address first line and if it matched the cardholder’s `billing.address.line1`. */ + /** + * @description Whether the cardholder provided an address first line and if it matched the cardholder’s `billing.address.line1`. + * @enum {string} + */ address_line1_check: "match" | "mismatch" | "not_provided"; - /** @description Whether the cardholder provided a postal code and if it matched the cardholder’s `billing.address.postal_code`. */ + /** + * @description Whether the cardholder provided a postal code and if it matched the cardholder’s `billing.address.postal_code`. + * @enum {string} + */ address_postal_code_check: "match" | "mismatch" | "not_provided"; - /** @description Whether the cardholder provided a CVC and if it matched Stripe’s record. */ + /** + * @description Whether the cardholder provided a CVC and if it matched Stripe’s record. + * @enum {string} + */ cvc_check: "match" | "mismatch" | "not_provided"; - /** @description Whether the cardholder provided an expiry date and if it matched Stripe’s record. */ + /** + * @description Whether the cardholder provided an expiry date and if it matched Stripe’s record. + * @enum {string} + */ expiry_check: "match" | "mismatch" | "not_provided"; }; /** IssuingCardAuthorizationControls */ @@ -4922,7 +5343,10 @@ export interface components { /** IssuingCardShipping */ issuing_card_shipping: { address: components["schemas"]["address"]; - /** @description The delivery company that shipped a card. */ + /** + * @description The delivery company that shipped a card. + * @enum {string|null} + */ carrier?: ("fedex" | "usps") | null; /** * Format: unix-time @@ -4931,15 +5355,24 @@ export interface components { eta?: number | null; /** @description Recipient name. */ name: string; - /** @description Shipment service, such as `standard` or `express`. */ + /** + * @description Shipment service, such as `standard` or `express`. + * @enum {string} + */ service: "express" | "priority" | "standard"; - /** @description The delivery status of the card. */ + /** + * @description The delivery status of the card. + * @enum {string|null} + */ status?: ("canceled" | "delivered" | "failure" | "pending" | "returned" | "shipped") | null; /** @description A tracking number for a card shipment. */ tracking_number?: string | null; /** @description A link to the shipping carrier's site where you can view detailed information about a card shipment. */ tracking_url?: string | null; - /** @description Packaging options. */ + /** + * @description Packaging options. + * @enum {string} + */ type: "bulk" | "individual"; }; /** IssuingCardSpendingLimit */ @@ -5239,7 +5672,10 @@ export interface components { | "wrecking_and_salvage_yards" )[] | null; - /** @description The time interval or event with which to apply this spending limit towards. */ + /** + * @description The time interval or event with which to apply this spending limit towards. + * @enum {string} + */ interval: "all_time" | "daily" | "monthly" | "per_authorization" | "weekly" | "yearly"; }; /** IssuingCardholderAddress */ @@ -5873,7 +6309,10 @@ export interface components { }; /** IssuingCardholderRequirements */ issuing_cardholder_requirements: { - /** @description If `disabled_reason` is present, all cards will decline authorizations with `cardholder_verification_required` reason. */ + /** + * @description If `disabled_reason` is present, all cards will decline authorizations with `cardholder_verification_required` reason. + * @enum {string|null} + */ disabled_reason?: ("listed" | "rejected.listed" | "under_review") | null; /** @description Array of fields that need to be collected in order to verify and re-enable the cardholder. */ past_due?: @@ -6185,7 +6624,10 @@ export interface components { | "wrecking_and_salvage_yards" )[] | null; - /** @description The time interval or event with which to apply this spending limit towards. */ + /** + * @description The time interval or event with which to apply this spending limit towards. + * @enum {string} + */ interval: "all_time" | "daily" | "monthly" | "per_authorization" | "weekly" | "yearly"; }; /** IssuingCardholderVerification */ @@ -6214,7 +6656,10 @@ export interface components { owners_provided?: boolean; /** @description The company's phone number (used for verification). */ phone?: string | null; - /** @description The category identifying the legal structure of the company or legal entity. See [Business structure](https://stripe.com/docs/connect/identity-verification#business-structure) for more details. */ + /** + * @description The category identifying the legal structure of the company or legal entity. See [Business structure](https://stripe.com/docs/connect/identity-verification#business-structure) for more details. + * @enum {string} + */ structure?: | "government_instrumentality" | "governmental_unit" @@ -6324,7 +6769,10 @@ export interface components { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Note that for line items with `type=subscription` this will reflect the metadata of the subscription that caused the line item to be created. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "line_item"; period: components["schemas"]["invoice_line_item_period"]; /** @description The plan of the subscription, if the line item is a subscription or a proration. */ @@ -6341,7 +6789,10 @@ export interface components { tax_amounts?: components["schemas"]["invoice_tax_amount"][] | null; /** @description The tax rates which apply to the line item. */ tax_rates?: components["schemas"]["tax_rate"][] | null; - /** @description A string identifying the type of the source of this line item, either an `invoiceitem` or a `subscription`. */ + /** + * @description A string identifying the type of the source of this line item, either an `invoiceitem` or a `subscription`. + * @enum {string} + */ type: "invoiceitem" | "subscription"; }; /** LoginLink */ @@ -6351,7 +6802,10 @@ export interface components { * @description Time at which the object was created. Measured in seconds since the Unix epoch. */ created: number; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "login_link"; /** @description The URL for the login link. */ url: string; @@ -6367,15 +6821,24 @@ export interface components { /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; multi_use?: components["schemas"]["mandate_multi_use"]; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "mandate"; /** @description ID of the payment method associated with this mandate. */ payment_method: Partial & Partial; payment_method_details: components["schemas"]["mandate_payment_method_details"]; single_use?: components["schemas"]["mandate_single_use"]; - /** @description The status of the mandate, which indicates whether it can be used to initiate a payment. */ + /** + * @description The status of the mandate, which indicates whether it can be used to initiate a payment. + * @enum {string} + */ status: "active" | "inactive" | "pending"; - /** @description The type of the mandate. */ + /** + * @description The type of the mandate. + * @enum {string} + */ type: "multi_use" | "single_use"; }; /** mandate_au_becs_debit */ @@ -6474,7 +6937,10 @@ export interface components { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "order"; /** * OrderReturnList @@ -6485,7 +6951,10 @@ export interface components { data: components["schemas"]["order_return"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -6522,7 +6991,10 @@ export interface components { currency: string; /** @description Description of the line item, meant to be displayable to the user (e.g., `"Express shipping"`). */ description: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "order_item"; /** @description The ID of the associated object for this line item. Expandable if not null (e.g., expandable to a SKU). */ parent?: (Partial & Partial) | null; @@ -6554,7 +7026,10 @@ export interface components { items: components["schemas"]["order_item"][]; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "order_return"; /** @description The order that this return includes items from. */ order?: (Partial & Partial) | null; @@ -6602,7 +7077,10 @@ export interface components { * @description Populated when `status` is `canceled`, this is the time at which the PaymentIntent was canceled. Measured in seconds since the Unix epoch. */ canceled_at?: number | null; - /** @description Reason for cancellation of this PaymentIntent, either user-provided (`duplicate`, `fraudulent`, `requested_by_customer`, or `abandoned`) or generated by Stripe internally (`failed_invoice`, `void_invoice`, or `automatic`). */ + /** + * @description Reason for cancellation of this PaymentIntent, either user-provided (`duplicate`, `fraudulent`, `requested_by_customer`, or `abandoned`) or generated by Stripe internally (`failed_invoice`, `void_invoice`, or `automatic`). + * @enum {string|null} + */ cancellation_reason?: | ( | "abandoned" @@ -6614,7 +7092,10 @@ export interface components { | "void_invoice" ) | null; - /** @description Controls when the funds will be captured from the customer's account. */ + /** + * @description Controls when the funds will be captured from the customer's account. + * @enum {string} + */ capture_method: "automatic" | "manual"; /** * PaymentFlowsPaymentIntentResourceChargeList @@ -6625,7 +7106,10 @@ export interface components { data: components["schemas"]["charge"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -6638,6 +7122,7 @@ export interface components { * Refer to our docs to [accept a payment](https://stripe.com/docs/payments/accept-a-payment) and learn about how `client_secret` should be handled. */ client_secret?: string | null; + /** @enum {string} */ confirmation_method: "automatic" | "manual"; /** * Format: unix-time @@ -6672,7 +7157,10 @@ export interface components { metadata?: { [key: string]: string }; /** @description If present, this property tells you what actions you need to take in order for your customer to fulfill a payment using the provided source. */ next_action?: Partial | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "payment_intent"; /** @description The account (if any) for which the funds of the PaymentIntent are intended. See the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts) for details. */ on_behalf_of?: (Partial & Partial) | null; @@ -6692,6 +7180,7 @@ export interface components { * Providing this parameter will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any required actions from the user are complete. If no Customer was provided, the payment method can still be [attached](https://stripe.com/docs/api/payment_methods/attach) to a Customer after the transaction completes. * * When processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication). + * @enum {string|null} */ setup_future_usage?: ("off_session" | "on_session") | null; /** @description Shipping information for this PaymentIntent. */ @@ -6700,7 +7189,10 @@ export interface components { statement_descriptor?: string | null; /** @description Provides information about a card payment that customers see on their statements. Concatenated with the prefix (shortened descriptor) or statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 22 characters for the concatenated descriptor. */ statement_descriptor_suffix?: string | null; - /** @description Status of this PaymentIntent, one of `requires_payment_method`, `requires_confirmation`, `requires_action`, `processing`, `requires_capture`, `canceled`, or `succeeded`. Read more about each PaymentIntent [status](https://stripe.com/docs/payments/intents#intent-statuses). */ + /** + * @description Status of this PaymentIntent, one of `requires_payment_method`, `requires_confirmation`, `requires_action`, `processing`, `requires_capture`, `canceled`, or `succeeded`. Read more about each PaymentIntent [status](https://stripe.com/docs/payments/intents#intent-statuses). + * @enum {string} + */ status: | "canceled" | "processing" @@ -6741,7 +7233,10 @@ export interface components { * For more information, see the [installments integration guide](https://stripe.com/docs/payments/installments). */ installments?: Partial | null; - /** @description We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Permitted values include: `automatic` or `any`. If not provided, defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine. */ + /** + * @description We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Permitted values include: `automatic` or `any`. If not provided, defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine. + * @enum {string|null} + */ request_three_d_secure?: ("any" | "automatic" | "challenge_only") | null; }; /** @@ -6772,10 +7267,16 @@ export interface components { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "payment_method"; sepa_debit?: components["schemas"]["payment_method_sepa_debit"]; - /** @description The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type. */ + /** + * @description The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type. + * @enum {string} + */ type: "au_becs_debit" | "card" | "fpx" | "ideal" | "sepa_debit"; }; /** payment_method_au_becs_debit */ @@ -6839,7 +7340,10 @@ export interface components { google_pay?: components["schemas"]["payment_method_card_wallet_google_pay"]; masterpass?: components["schemas"]["payment_method_card_wallet_masterpass"]; samsung_pay?: components["schemas"]["payment_method_card_wallet_samsung_pay"]; - /** @description The type of the card wallet, one of `amex_express_checkout`, `apple_pay`, `google_pay`, `masterpass`, `samsung_pay`, or `visa_checkout`. An additional hash is included on the Wallet subhash with a name matching this value. It contains additional information specific to the card wallet type. */ + /** + * @description The type of the card wallet, one of `amex_express_checkout`, `apple_pay`, `google_pay`, `masterpass`, `samsung_pay`, or `visa_checkout`. An additional hash is included on the Wallet subhash with a name matching this value. It contains additional information specific to the card wallet type. + * @enum {string} + */ type: "amex_express_checkout" | "apple_pay" | "google_pay" | "masterpass" | "samsung_pay" | "visa_checkout"; visa_checkout?: components["schemas"]["payment_method_card_wallet_visa_checkout"]; }; @@ -6913,7 +7417,10 @@ export interface components { }; /** payment_method_details_ach_debit */ payment_method_details_ach_debit: { - /** @description Type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description Type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string|null} + */ account_holder_type?: ("company" | "individual") | null; /** @description Name of the bank associated with the bank account. */ bank_name?: string | null; @@ -6952,6 +7459,7 @@ export interface components { /** * @description Preferred language of the Bancontact authorization page that the customer is redirected to. * Can be one of `en`, `de`, `fr`, or `nl` + * @enum {string|null} */ preferred_language?: ("de" | "en" | "fr" | "nl") | null; /** @@ -7012,9 +7520,13 @@ export interface components { /** * @description For `fixed_count` installment plans, this is the interval between installment payments your customer will make to their credit card. * One of `month`. + * @enum {string|null} */ interval?: "month" | null; - /** @description Type of installment plan, one of `fixed_count`. */ + /** + * @description Type of installment plan, one of `fixed_count`. + * @enum {string} + */ type: "fixed_count"; }; /** payment_method_details_card_present */ @@ -7074,7 +7586,10 @@ export interface components { google_pay?: components["schemas"]["payment_method_details_card_wallet_google_pay"]; masterpass?: components["schemas"]["payment_method_details_card_wallet_masterpass"]; samsung_pay?: components["schemas"]["payment_method_details_card_wallet_samsung_pay"]; - /** @description The type of the card wallet, one of `amex_express_checkout`, `apple_pay`, `google_pay`, `masterpass`, `samsung_pay`, or `visa_checkout`. An additional hash is included on the Wallet subhash with a name matching this value. It contains additional information specific to the card wallet type. */ + /** + * @description The type of the card wallet, one of `amex_express_checkout`, `apple_pay`, `google_pay`, `masterpass`, `samsung_pay`, or `visa_checkout`. An additional hash is included on the Wallet subhash with a name matching this value. It contains additional information specific to the card wallet type. + * @enum {string} + */ type: "amex_express_checkout" | "apple_pay" | "google_pay" | "masterpass" | "samsung_pay" | "visa_checkout"; visa_checkout?: components["schemas"]["payment_method_details_card_wallet_visa_checkout"]; }; @@ -7118,7 +7633,10 @@ export interface components { }; /** payment_method_details_fpx */ payment_method_details_fpx: { - /** @description The customer's bank. Can be one of `affin_bank`, `alliance_bank`, `ambank`, `bank_islam`, `bank_muamalat`, `bank_rakyat`, `bsn`, `cimb`, `hong_leong_bank`, `hsbc`, `kfh`, `maybank2u`, `ocbc`, `public_bank`, `rhb`, `standard_chartered`, `uob`, `deutsche_bank`, `maybank2e`, or `pb_enterprise`. */ + /** + * @description The customer's bank. Can be one of `affin_bank`, `alliance_bank`, `ambank`, `bank_islam`, `bank_muamalat`, `bank_rakyat`, `bsn`, `cimb`, `hong_leong_bank`, `hsbc`, `kfh`, `maybank2u`, `ocbc`, `public_bank`, `rhb`, `standard_chartered`, `uob`, `deutsche_bank`, `maybank2e`, or `pb_enterprise`. + * @enum {string} + */ bank: | "affin_bank" | "alliance_bank" @@ -7159,7 +7677,10 @@ export interface components { }; /** payment_method_details_ideal */ payment_method_details_ideal: { - /** @description The customer's bank. Can be one of `abn_amro`, `asn_bank`, `bunq`, `handelsbanken`, `ing`, `knab`, `moneyou`, `rabobank`, `regiobank`, `sns_bank`, `triodos_bank`, or `van_lanschot`. */ + /** + * @description The customer's bank. Can be one of `abn_amro`, `asn_bank`, `bunq`, `handelsbanken`, `ing`, `knab`, `moneyou`, `rabobank`, `regiobank`, `sns_bank`, `triodos_bank`, or `van_lanschot`. + * @enum {string|null} + */ bank?: | ( | "abn_amro" @@ -7176,7 +7697,10 @@ export interface components { | "van_lanschot" ) | null; - /** @description The Bank Identifier Code of the customer's bank. */ + /** + * @description The Bank Identifier Code of the customer's bank. + * @enum {string|null} + */ bic?: | ( | "ABNANL2A" @@ -7259,7 +7783,10 @@ export interface components { payment_method_details_wechat: { [key: string]: unknown }; /** payment_method_fpx */ payment_method_fpx: { - /** @description The customer's bank, if provided. Can be one of `affin_bank`, `alliance_bank`, `ambank`, `bank_islam`, `bank_muamalat`, `bank_rakyat`, `bsn`, `cimb`, `hong_leong_bank`, `hsbc`, `kfh`, `maybank2u`, `ocbc`, `public_bank`, `rhb`, `standard_chartered`, `uob`, `deutsche_bank`, `maybank2e`, or `pb_enterprise`. */ + /** + * @description The customer's bank, if provided. Can be one of `affin_bank`, `alliance_bank`, `ambank`, `bank_islam`, `bank_muamalat`, `bank_rakyat`, `bsn`, `cimb`, `hong_leong_bank`, `hsbc`, `kfh`, `maybank2u`, `ocbc`, `public_bank`, `rhb`, `standard_chartered`, `uob`, `deutsche_bank`, `maybank2e`, or `pb_enterprise`. + * @enum {string} + */ bank: | "affin_bank" | "alliance_bank" @@ -7284,7 +7811,10 @@ export interface components { }; /** payment_method_ideal */ payment_method_ideal: { - /** @description The customer's bank, if provided. Can be one of `abn_amro`, `asn_bank`, `bunq`, `handelsbanken`, `ing`, `knab`, `moneyou`, `rabobank`, `regiobank`, `sns_bank`, `triodos_bank`, or `van_lanschot`. */ + /** + * @description The customer's bank, if provided. Can be one of `abn_amro`, `asn_bank`, `bunq`, `handelsbanken`, `ing`, `knab`, `moneyou`, `rabobank`, `regiobank`, `sns_bank`, `triodos_bank`, or `van_lanschot`. + * @enum {string|null} + */ bank?: | ( | "abn_amro" @@ -7301,7 +7831,10 @@ export interface components { | "van_lanschot" ) | null; - /** @description The Bank Identifier Code of the customer's bank, if the bank was provided. */ + /** + * @description The Bank Identifier Code of the customer's bank, if the bank was provided. + * @enum {string|null} + */ bic?: | ( | "ABNANL2A" @@ -7648,7 +8181,10 @@ export interface components { metadata: { [key: string]: string }; /** @description The method used to send this payout, which can be `standard` or `instant`. `instant` is only supported for payouts to debit cards. (See [Instant payouts for marketplaces](https://stripe.com/blog/instant-payouts-for-marketplaces) for more information.) */ method: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "payout"; /** @description The source balance this payout came from. One of `card`, `fpx`, or `bank_account`. */ source_type: string; @@ -7656,7 +8192,10 @@ export interface components { statement_descriptor?: string | null; /** @description Current status of the payout: `paid`, `pending`, `in_transit`, `canceled` or `failed`. A payout is `pending` until it is submitted to the bank, when it becomes `in_transit`. The status then changes to `paid` if the transaction goes through, or to `failed` or `canceled` (within 5 business days). Some failed payouts may initially show as `paid` but then change to `failed`. */ status: string; - /** @description Can be `bank_account` or `card`. */ + /** + * @description Can be `bank_account` or `card`. + * @enum {string} + */ type: "bank_account" | "card"; }; /** Period */ @@ -7703,7 +8242,10 @@ export interface components { maiden_name?: string | null; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata?: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "person"; phone?: string | null; relationship?: components["schemas"]["person_relationship"]; @@ -7751,7 +8293,10 @@ export interface components { plan: { /** @description Whether the plan can be used for new purchases. */ active: boolean; - /** @description Specifies a usage aggregation strategy for plans of `usage_type=metered`. Allowed values are `sum` for summing up all usage during a period, `last_during_period` for using the last usage record reported within a period, `last_ever` for using the last usage record ever (across period bounds) or `max` which uses the usage record with the maximum reported usage during a period. Defaults to `sum`. */ + /** + * @description Specifies a usage aggregation strategy for plans of `usage_type=metered`. Allowed values are `sum` for summing up all usage during a period, `last_during_period` for using the last usage record reported within a period, `last_ever` for using the last usage record ever (across period bounds) or `max` which uses the usage record with the maximum reported usage during a period. Defaults to `sum`. + * @enum {string|null} + */ aggregate_usage?: ("last_during_period" | "last_ever" | "max" | "sum") | null; /** @description The amount in %s to be charged on the interval specified. */ amount?: number | null; @@ -7760,7 +8305,10 @@ export interface components { * @description Same as `amount`, but contains a decimal value with at most 12 decimal places. */ amount_decimal?: string | null; - /** @description Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `amount`) will be charged per unit in `quantity` (for plans with `usage_type=licensed`), or per unit of total usage (for plans with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes. */ + /** + * @description Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `amount`) will be charged per unit in `quantity` (for plans with `usage_type=licensed`), or per unit of total usage (for plans with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes. + * @enum {string} + */ billing_scheme: "per_unit" | "tiered"; /** * Format: unix-time @@ -7771,7 +8319,10 @@ export interface components { currency: string; /** @description Unique identifier for the object. */ id: string; - /** @description The frequency at which a subscription is billed. One of `day`, `week`, `month` or `year`. */ + /** + * @description The frequency at which a subscription is billed. One of `day`, `week`, `month` or `year`. + * @enum {string} + */ interval: "day" | "month" | "week" | "year"; /** @description The number of intervals (specified in the `interval` attribute) between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. */ interval_count: number; @@ -7781,7 +8332,10 @@ export interface components { metadata: { [key: string]: string }; /** @description A brief description of the plan, hidden from customers. */ nickname?: string | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "plan"; /** @description The product whose pricing this plan determines. */ product?: @@ -7791,13 +8345,19 @@ export interface components { | null; /** @description Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`. */ tiers?: components["schemas"]["plan_tier"][] | null; - /** @description Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price. In `graduated` tiering, pricing can change as the quantity grows. */ + /** + * @description Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price. In `graduated` tiering, pricing can change as the quantity grows. + * @enum {string|null} + */ tiers_mode?: ("graduated" | "volume") | null; /** @description Apply a transformation to the reported usage or set quantity before computing the amount billed. Cannot be combined with `tiers`. */ transform_usage?: Partial | null; /** @description Default number of trial days when subscribing a customer to this plan using [`trial_from_plan=true`](https://stripe.com/docs/api#create_subscription-trial_from_plan). */ trial_period_days?: number | null; - /** @description Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`. */ + /** + * @description Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`. + * @enum {string} + */ usage_type: "licensed" | "metered"; }; /** PlanTier */ @@ -7825,7 +8385,10 @@ export interface components { account: string; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "platform_tax_fee"; /** @description The payment object that caused this tax to be inflicted. */ source_transaction: string; @@ -7869,7 +8432,10 @@ export interface components { metadata: { [key: string]: string }; /** @description The product's name, meant to be displayable to the customer. Whenever this product is sold via a subscription, name will show up on associated invoice line item descriptions. */ name: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "product"; /** @description The dimensions of this product for shipping purposes. A SKU associated with this product can override this value by having its own `package_dimensions`. Only applicable to products of `type=good`. */ package_dimensions?: Partial | null; @@ -7877,7 +8443,10 @@ export interface components { shippable?: boolean | null; /** @description Extra information about a product which will appear on your customer's credit card statement. In the case that multiple products are billed at once, the first statement descriptor will be used. */ statement_descriptor?: string | null; - /** @description The type of the product. The product is either of type `good`, which is eligible for use with Orders and SKUs, or `service`, which is eligible for use with Subscriptions and Plans. */ + /** + * @description The type of the product. The product is either of type `good`, which is eligible for use with Orders and SKUs, or `service`, which is eligible for use with Subscriptions and Plans. + * @enum {string} + */ type: "good" | "service"; /** @description A label that represents units of this product in Stripe and on customers’ receipts and invoices. When set, this will be included in associated invoice line item descriptions. */ unit_label?: string | null; @@ -7912,7 +8481,10 @@ export interface components { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "radar.early_fraud_warning"; }; /** @@ -7933,7 +8505,10 @@ export interface components { created_by: string; /** @description Unique identifier for the object. */ id: string; - /** @description The type of items in the value list. One of `card_fingerprint`, `card_bin`, `email`, `ip_address`, `country`, `string`, or `case_sensitive_string`. */ + /** + * @description The type of items in the value list. One of `card_fingerprint`, `card_bin`, `email`, `ip_address`, `country`, `string`, or `case_sensitive_string`. + * @enum {string} + */ item_type: | "card_bin" | "card_fingerprint" @@ -7951,7 +8526,10 @@ export interface components { data: components["schemas"]["radar.value_list_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -7962,7 +8540,10 @@ export interface components { metadata: { [key: string]: string }; /** @description The name of the value list. */ name: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "radar.value_list"; }; /** @@ -7983,7 +8564,10 @@ export interface components { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "radar.value_list_item"; /** @description The value of the item. */ value: string; @@ -8036,7 +8620,10 @@ export interface components { data: components["schemas"]["card"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -8061,7 +8648,10 @@ export interface components { migrated_to?: (Partial & Partial) | null; /** @description Full, legal name of the recipient. */ name?: string | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "recipient"; rolled_back_from?: Partial & Partial; /** @description Type of the recipient, one of `individual` or `corporation`. */ @@ -8099,7 +8689,10 @@ export interface components { id: string; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "refund"; /** @description ID of the PaymentIntent that was refunded. */ payment_intent?: (Partial & Partial) | null; @@ -8141,7 +8734,10 @@ export interface components { id: string; /** @description Always `true`: reports can only be run on live-mode data. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "reporting.report_run"; parameters: components["schemas"]["financial_reporting_finance_report_run_run_parameters"]; /** @description The ID of the [report type](https://stripe.com/docs/reporting/statements/api#report-types) to run, such as `"balance.summary.1"`. */ @@ -8193,7 +8789,10 @@ export interface components { id: string; /** @description Human-readable name of the Report Type */ name: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "reporting.report_type"; /** * Format: unix-time @@ -8212,7 +8811,10 @@ export interface components { description?: string | null; /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "reserve_transaction"; }; /** @@ -8227,7 +8829,10 @@ export interface components { billing_zip?: string | null; /** @description The charge associated with this review. */ charge?: (Partial & Partial) | null; - /** @description The reason the review was closed, or null if it has not yet been closed. One of `approved`, `refunded`, `refunded_as_fraud`, or `disputed`. */ + /** + * @description The reason the review was closed, or null if it has not yet been closed. One of `approved`, `refunded`, `refunded_as_fraud`, or `disputed`. + * @enum {string|null} + */ closed_reason?: ("approved" | "disputed" | "refunded" | "refunded_as_fraud") | null; /** * Format: unix-time @@ -8242,11 +8847,17 @@ export interface components { ip_address_location?: Partial | null; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "review"; /** @description If `true`, the review needs action. */ open: boolean; - /** @description The reason the review was opened. One of `rule` or `manual`. */ + /** + * @description The reason the review was opened. One of `rule` or `manual`. + * @enum {string} + */ opened_reason: "manual" | "rule"; /** @description The PaymentIntent ID associated with this review, if one exists. */ payment_intent?: Partial & Partial; @@ -8289,7 +8900,10 @@ export interface components { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "scheduled_query_run"; /** * Format: unix-time @@ -8331,7 +8945,10 @@ export interface components { setup_intent: { /** @description ID of the Connect application that created the SetupIntent. */ application?: (Partial & Partial) | null; - /** @description Reason for cancellation of this SetupIntent, one of `abandoned`, `requested_by_customer`, or `duplicate`. */ + /** + * @description Reason for cancellation of this SetupIntent, one of `abandoned`, `requested_by_customer`, or `duplicate`. + * @enum {string|null} + */ cancellation_reason?: ("abandoned" | "duplicate" | "requested_by_customer") | null; /** * @description The client secret of this SetupIntent. Used for client-side retrieval using a publishable key. @@ -8368,7 +8985,10 @@ export interface components { metadata?: { [key: string]: string }; /** @description If present, this property tells you what actions you need to take in order for your customer to continue payment setup. */ next_action?: Partial | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "setup_intent"; /** @description The account (if any) for which the setup is intended. */ on_behalf_of?: (Partial & Partial) | null; @@ -8380,7 +9000,10 @@ export interface components { payment_method_types: string[]; /** @description ID of the single_use Mandate generated by the SetupIntent. */ single_use_mandate?: (Partial & Partial) | null; - /** @description [Status](https://stripe.com/docs/payments/intents#intent-statuses) of this SetupIntent, one of `requires_payment_method`, `requires_confirmation`, `requires_action`, `processing`, `canceled`, or `succeeded`. */ + /** + * @description [Status](https://stripe.com/docs/payments/intents#intent-statuses) of this SetupIntent, one of `requires_payment_method`, `requires_confirmation`, `requires_action`, `processing`, `canceled`, or `succeeded`. + * @enum {string} + */ status: | "canceled" | "processing" @@ -8416,7 +9039,10 @@ export interface components { }; /** setup_intent_payment_method_options_card */ setup_intent_payment_method_options_card: { - /** @description We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Permitted values include: `automatic` or `any`. If not provided, defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine. */ + /** + * @description We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Permitted values include: `automatic` or `any`. If not provided, defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine. + * @enum {string|null} + */ request_three_d_secure?: ("any" | "automatic" | "challenge_only") | null; }; /** Shipping */ @@ -8481,7 +9107,10 @@ export interface components { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "sku"; /** @description The dimensions of this SKU for shipping purposes. */ package_dimensions?: Partial | null; @@ -8539,7 +9168,10 @@ export interface components { /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata?: { [key: string]: string } | null; multibanco?: components["schemas"]["source_type_multibanco"]; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "source"; /** @description Information about the owner of the payment instrument that may be used or required by particular source types. */ owner?: Partial | null; @@ -8554,7 +9186,10 @@ export interface components { /** @description The status of the source, one of `canceled`, `chargeable`, `consumed`, `failed`, or `pending`. Only `chargeable` sources can be used to create a charge. */ status: string; three_d_secure?: components["schemas"]["source_type_three_d_secure"]; - /** @description The `type` of the source. The `type` is a payment method, one of `ach_credit_transfer`, `ach_debit`, `alipay`, `bancontact`, `card`, `card_present`, `eps`, `giropay`, `ideal`, `multibanco`, `klarna`, `p24`, `sepa_debit`, `sofort`, `three_d_secure`, or `wechat`. An additional hash is included on the source with a name matching this value. It contains additional information specific to the [payment method](https://stripe.com/docs/sources) used. */ + /** + * @description The `type` of the source. The `type` is a payment method, one of `ach_credit_transfer`, `ach_debit`, `alipay`, `bancontact`, `card`, `card_present`, `eps`, `giropay`, `ideal`, `multibanco`, `klarna`, `p24`, `sepa_debit`, `sofort`, `three_d_secure`, or `wechat`. An additional hash is included on the source with a name matching this value. It contains additional information specific to the [payment method](https://stripe.com/docs/sources) used. + * @enum {string} + */ type: | "ach_credit_transfer" | "ach_debit" @@ -8603,7 +9238,10 @@ export interface components { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "source_mandate_notification"; /** @description The reason of the mandate notification. Valid reasons are `mandate_confirmed` or `debit_initiated`. */ reason: string; @@ -8722,7 +9360,10 @@ export interface components { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "source_transaction"; paper_check?: components["schemas"]["source_transaction_paper_check_data"]; sepa_credit_transfer?: components["schemas"]["source_transaction_sepa_credit_transfer_data"]; @@ -8730,7 +9371,10 @@ export interface components { source: string; /** @description The status of the transaction, one of `succeeded`, `pending`, or `failed`. */ status: string; - /** @description The type of source this transaction is attached to. */ + /** + * @description The type of source this transaction is attached to. + * @enum {string} + */ type: | "ach_credit_transfer" | "ach_debit" @@ -9034,7 +9678,10 @@ export interface components { * @description If the subscription has been canceled, the date of that cancellation. If the subscription was canceled with `cancel_at_period_end`, `canceled_at` will still reflect the date of the initial cancellation request, not the end of the subscription period when the subscription is automatically moved to a canceled state. */ canceled_at?: number | null; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. + * @enum {string|null} + */ collection_method?: ("charge_automatically" | "send_invoice") | null; /** * Format: unix-time @@ -9088,7 +9735,10 @@ export interface components { data: components["schemas"]["subscription_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -9104,7 +9754,10 @@ export interface components { * @description Specifies the approximate timestamp on which any pending invoice items will be billed according to the schedule provided at `pending_invoice_item_interval`. */ next_pending_invoice_item_invoice?: number | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "subscription"; /** @description If specified, payment collection for this subscription will be paused. */ pause_collection?: Partial | null; @@ -9137,6 +9790,7 @@ export interface components { * If subscription `collection_method=charge_automatically` it becomes `past_due` when payment to renew it fails and `canceled` or `unpaid` (depending on your subscriptions settings) when Stripe has exhausted all payment retry attempts. * * If subscription `collection_method=send_invoice` it becomes `past_due` when its invoice is not paid by the due date, and `canceled` or `unpaid` if it is still not paid by an additional deadline after that. Note that when a subscription has a status of `unpaid`, no subsequent invoices will be attempted (invoices will be created, but then immediately automatically closed). After receiving updated payment information from a customer, you may choose to reopen and pay their closed invoices. + * @enum {string} */ status: "active" | "canceled" | "incomplete" | "incomplete_expired" | "past_due" | "trialing" | "unpaid"; /** @description If provided, each invoice created by this subscription will apply the tax rate, increasing the amount billed to the customer. */ @@ -9173,7 +9827,10 @@ export interface components { id: string; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "subscription_item"; plan: components["schemas"]["plan"]; /** @description The [quantity](https://stripe.com/docs/subscriptions/quantities) of the plan to which the customer should be subscribed. */ @@ -9190,7 +9847,10 @@ export interface components { }; /** SubscriptionPendingInvoiceItemInterval */ subscription_pending_invoice_item_interval: { - /** @description Specifies invoicing frequency. Either `day`, `week`, `month` or `year`. */ + /** + * @description Specifies invoicing frequency. Either `day`, `week`, `month` or `year`. + * @enum {string} + */ interval: "day" | "month" | "week" | "year"; /** @description The number of intervals between invoices. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). */ interval_count: number; @@ -9224,7 +9884,10 @@ export interface components { Partial & Partial; default_settings: components["schemas"]["subscription_schedules_resource_default_settings"]; - /** @description Behavior of the subscription schedule and underlying subscription when it ends. */ + /** + * @description Behavior of the subscription schedule and underlying subscription when it ends. + * @enum {string} + */ end_behavior: "cancel" | "none" | "release" | "renew"; /** @description Unique identifier for the object. */ id: string; @@ -9232,7 +9895,10 @@ export interface components { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata?: { [key: string]: string } | null; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "subscription_schedule"; /** @description Configuration for the subscription schedule's phases. */ phases: components["schemas"]["subscription_schedule_phase_configuration"][]; @@ -9243,7 +9909,10 @@ export interface components { released_at?: number | null; /** @description ID of the subscription once managed by the subscription schedule (if it is released). */ released_subscription?: string | null; - /** @description The present status of the subscription schedule. Possible values are `not_started`, `active`, `completed`, `released`, and `canceled`. You can read more about the different states in our [behavior guide](https://stripe.com/docs/billing/subscriptions/subscription-schedules). */ + /** + * @description The present status of the subscription schedule. Possible values are `not_started`, `active`, `completed`, `released`, and `canceled`. You can read more about the different states in our [behavior guide](https://stripe.com/docs/billing/subscriptions/subscription-schedules). + * @enum {string} + */ status: "active" | "canceled" | "completed" | "not_started" | "released"; /** @description ID of the subscription managed by the subscription schedule. */ subscription?: (Partial & Partial) | null; @@ -9284,7 +9953,10 @@ export interface components { application_fee_percent?: number | null; /** @description Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period */ billing_thresholds?: Partial | null; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. + * @enum {string|null} + */ collection_method?: ("charge_automatically" | "send_invoice") | null; /** @description ID of the coupon to use during this phase of the subscription schedule. */ coupon?: @@ -9305,7 +9977,10 @@ export interface components { invoice_settings?: Partial | null; /** @description Plans to subscribe during this phase of the subscription schedule. */ plans: components["schemas"]["subscription_schedule_configuration_item"][]; - /** @description Controls whether or not the subscription schedule will prorate when transitioning to this phase. Values are `create_prorations` and `none`. */ + /** + * @description Controls whether or not the subscription schedule will prorate when transitioning to this phase. Values are `create_prorations` and `none`. + * @enum {string|null} + */ proration_behavior?: ("always_invoice" | "create_prorations" | "none") | null; /** * Format: unix-time @@ -9324,7 +9999,10 @@ export interface components { subscription_schedules_resource_default_settings: { /** @description Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period */ billing_thresholds?: Partial | null; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. + * @enum {string|null} + */ collection_method?: ("charge_automatically" | "send_invoice") | null; /** @description ID of the default payment method for the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings. */ default_payment_method?: (Partial & Partial) | null; @@ -9337,7 +10015,10 @@ export interface components { * should be paused. */ subscriptions_resource_pause_collection: { - /** @description The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`. */ + /** + * @description The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`. + * @enum {string} + */ behavior: "keep_as_draft" | "mark_uncollectible" | "void"; /** * Format: unix-time @@ -9375,7 +10056,10 @@ export interface components { tax_deducted_at_source: { /** @description Unique identifier for the object. */ id: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "tax_deducted_at_source"; /** * Format: unix-time @@ -9411,9 +10095,15 @@ export interface components { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "tax_id"; - /** @description Type of the tax ID, one of `au_abn`, `ca_bn`, `ca_qst`, `ch_vat`, `es_cif`, `eu_vat`, `hk_br`, `in_gst`, `jp_cn`, `kr_brn`, `li_uid`, `mx_rfc`, `my_itn`, `my_sst`, `no_vat`, `nz_gst`, `ru_inn`, `sg_gst`, `sg_uen`, `th_vat`, `tw_vat`, `us_ein`, or `za_vat`. Note that some legacy tax IDs have type `unknown` */ + /** + * @description Type of the tax ID, one of `au_abn`, `ca_bn`, `ca_qst`, `ch_vat`, `es_cif`, `eu_vat`, `hk_br`, `in_gst`, `jp_cn`, `kr_brn`, `li_uid`, `mx_rfc`, `my_itn`, `my_sst`, `no_vat`, `nz_gst`, `ru_inn`, `sg_gst`, `sg_uen`, `th_vat`, `tw_vat`, `us_ein`, or `za_vat`. Note that some legacy tax IDs have type `unknown` + * @enum {string} + */ type: | "au_abn" | "ca_bn" @@ -9445,7 +10135,10 @@ export interface components { }; /** tax_id_verification */ tax_id_verification: { - /** @description Verification status, one of `pending`, `verified`, `unverified`, or `unavailable`. */ + /** + * @description Verification status, one of `pending`, `verified`, `unverified`, or `unavailable`. + * @enum {string} + */ status: "pending" | "unavailable" | "unverified" | "verified"; /** @description Verified address. */ verified_address?: string | null; @@ -9480,7 +10173,10 @@ export interface components { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "tax_rate"; /** @description This represents the tax rate percent out of 100. */ percentage: number; @@ -9494,7 +10190,10 @@ export interface components { "terminal.connection_token": { /** @description The id of the location that this connection token is scoped to. */ location?: string; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "terminal.connection_token"; /** @description Your application should pass this token to the Stripe Terminal SDK. */ secret: string; @@ -9515,7 +10214,10 @@ export interface components { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "terminal.location"; }; /** @@ -9527,7 +10229,10 @@ export interface components { "terminal.reader": { /** @description The current software version of the reader. */ device_sw_version?: string | null; - /** @description Type of reader, one of `bbpos_chipper2x` or `verifone_P400`. */ + /** + * @description Type of reader, one of `bbpos_chipper2x` or `verifone_P400`. + * @enum {string} + */ device_type: "bbpos_chipper2x" | "verifone_P400"; /** @description Unique identifier for the object. */ id: string; @@ -9541,7 +10246,10 @@ export interface components { location?: string | null; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "terminal.reader"; /** @description Serial number of the reader. */ serial_number: string; @@ -9571,7 +10279,10 @@ export interface components { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "three_d_secure"; /** @description If present, this is the URL that you should send the cardholder to for authentication. If you are going to use Stripe.js to display the authentication page in an iframe, you should use the value "_callback". */ redirect_url?: string | null; @@ -9631,7 +10342,10 @@ export interface components { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "token"; /** @description Type of the token: `account`, `bank_account`, `card`, or `pii`. */ type: string; @@ -9672,12 +10386,18 @@ export interface components { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "topup"; source: components["schemas"]["source"]; /** @description Extra information about a top-up. This will appear on your source's bank statement. It must contain at least one letter. */ statement_descriptor?: string | null; - /** @description The status of the top-up is either `canceled`, `failed`, `pending`, `reversed`, or `succeeded`. */ + /** + * @description The status of the top-up is either `canceled`, `failed`, `pending`, `reversed`, or `succeeded`. + * @enum {string} + */ status: "canceled" | "failed" | "pending" | "reversed" | "succeeded"; /** @description A string that identifies this top-up as part of a group. */ transfer_group?: string | null; @@ -9721,7 +10441,10 @@ export interface components { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "transfer"; /** * TransferReversalList @@ -9732,7 +10455,10 @@ export interface components { data: components["schemas"]["transfer_reversal"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -9791,7 +10517,10 @@ export interface components { id: string; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "transfer_reversal"; /** @description ID of the refund responsible for the transfer reversal. */ source_refund?: (Partial & Partial) | null; @@ -9813,7 +10542,10 @@ export interface components { transform_usage: { /** @description Divide usage by this number. */ divide_by: number; - /** @description After division, either round the result `up` or `down`. */ + /** + * @description After division, either round the result `up` or `down`. + * @enum {string} + */ round: "down" | "up"; }; /** @@ -9828,7 +10560,10 @@ export interface components { id: string; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "usage_record"; /** @description The usage quantity for the specified date. */ quantity: number; @@ -9848,7 +10583,10 @@ export interface components { invoice?: string | null; /** @description Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. */ livemode: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "usage_record_summary"; period: components["schemas"]["period"]; /** @description The ID of the subscription item this summary is describing. */ @@ -9886,7 +10624,10 @@ export interface components { livemode: boolean; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata: { [key: string]: string }; - /** @description String representing the object's type. Objects of the same type share the same value. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. + * @enum {string} + */ object: "webhook_endpoint"; /** @description The endpoint's secret, used to generate [webhook signatures](https://stripe.com/docs/webhooks/signatures). Only returned at creation. */ secret?: string; @@ -10021,10 +10762,12 @@ export interface operations { /** @description Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js), or a dictionary containing a user's bank account details. */ bank_account?: Partial<{ account_holder_name?: string; + /** @enum {string} */ account_holder_type?: "company" | "individual"; account_number: string; country: string; currency?: string; + /** @enum {string} */ object?: "bank_account"; routing_number?: string; }> & @@ -10042,7 +10785,10 @@ export interface operations { support_url?: string; url?: string; }; - /** @description The business type. */ + /** + * @description The business type. + * @enum {string} + */ business_type?: "company" | "government_entity" | "individual" | "non_profit"; /** * company_specs @@ -10085,6 +10831,7 @@ export interface operations { name_kanji?: string; owners_provided?: boolean; phone?: string; + /** @enum {string} */ structure?: | "" | "government_instrumentality" @@ -10234,8 +10981,10 @@ export interface operations { /** transfer_schedule_specs */ schedule?: { delay_days?: Partial<"minimum"> & Partial; + /** @enum {string} */ interval?: "daily" | "manual" | "monthly" | "weekly"; monthly_anchor?: number; + /** @enum {string} */ weekly_anchor?: "friday" | "monday" | "saturday" | "sunday" | "thursday" | "tuesday" | "wednesday"; }; statement_descriptor?: string; @@ -10307,10 +11056,12 @@ export interface operations { /** @description Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js), or a dictionary containing a user's bank account details. */ bank_account?: Partial<{ account_holder_name?: string; + /** @enum {string} */ account_holder_type?: "company" | "individual"; account_number: string; country: string; currency?: string; + /** @enum {string} */ object?: "bank_account"; routing_number?: string; }> & @@ -10387,7 +11138,10 @@ export interface operations { "application/x-www-form-urlencoded": { /** @description The name of the person or business that owns the bank account. */ account_holder_name?: string; - /** @description The type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description The type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string} + */ account_holder_type?: "" | "company" | "individual"; /** @description City/District/Suburb/Town/Village. */ address_city?: string; @@ -10460,7 +11214,10 @@ export interface operations { data: components["schemas"]["capability"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -10566,7 +11323,10 @@ export interface operations { data: (Partial & Partial)[]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -10608,10 +11368,12 @@ export interface operations { /** @description Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js), or a dictionary containing a user's bank account details. */ bank_account?: Partial<{ account_holder_name?: string; + /** @enum {string} */ account_holder_type?: "company" | "individual"; account_number: string; country: string; currency?: string; + /** @enum {string} */ object?: "bank_account"; routing_number?: string; }> & @@ -10688,7 +11450,10 @@ export interface operations { "application/x-www-form-urlencoded": { /** @description The name of the person or business that owns the bank account. */ account_holder_name?: string; - /** @description The type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description The type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string} + */ account_holder_type?: "" | "company" | "individual"; /** @description City/District/Suburb/Town/Village. */ address_city?: string; @@ -10836,7 +11601,10 @@ export interface operations { data: components["schemas"]["person"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -11202,7 +11970,10 @@ export interface operations { data: components["schemas"]["person"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -11560,7 +12331,10 @@ export interface operations { "application/x-www-form-urlencoded": { /** @description The identifier of the account to create an account link for. */ account: string; - /** @description Which information the platform needs to collect from the user. One of `currently_due` or `eventually_due`. Default is `currently_due`. */ + /** + * @description Which information the platform needs to collect from the user. One of `currently_due` or `eventually_due`. Default is `currently_due`. + * @enum {string} + */ collect?: "currently_due" | "eventually_due"; /** @description Specifies which fields in the response should be expanded. */ expand?: string[]; @@ -11568,7 +12342,10 @@ export interface operations { failure_url: string; /** @description The URL that the user will be redirected to upon leaving or completing the linked flow successfully. */ success_url: string; - /** @description The type of account link the user is requesting. Possible values are `custom_account_verification` or `custom_account_update`. */ + /** + * @description The type of account link the user is requesting. Possible values are `custom_account_verification` or `custom_account_update`. + * @enum {string} + */ type: "custom_account_update" | "custom_account_verification"; }; }; @@ -11603,7 +12380,10 @@ export interface operations { data: components["schemas"]["account"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -11653,10 +12433,12 @@ export interface operations { /** @description Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js), or a dictionary containing a user's bank account details. */ bank_account?: Partial<{ account_holder_name?: string; + /** @enum {string} */ account_holder_type?: "company" | "individual"; account_number: string; country: string; currency?: string; + /** @enum {string} */ object?: "bank_account"; routing_number?: string; }> & @@ -11674,7 +12456,10 @@ export interface operations { support_url?: string; url?: string; }; - /** @description The business type. */ + /** + * @description The business type. + * @enum {string} + */ business_type?: "company" | "government_entity" | "individual" | "non_profit"; /** * company_specs @@ -11717,6 +12502,7 @@ export interface operations { name_kanji?: string; owners_provided?: boolean; phone?: string; + /** @enum {string} */ structure?: | "" | "government_instrumentality" @@ -11868,8 +12654,10 @@ export interface operations { /** transfer_schedule_specs */ schedule?: { delay_days?: Partial<"minimum"> & Partial; + /** @enum {string} */ interval?: "daily" | "manual" | "monthly" | "weekly"; monthly_anchor?: number; + /** @enum {string} */ weekly_anchor?: "friday" | "monday" | "saturday" | "sunday" | "thursday" | "tuesday" | "wednesday"; }; statement_descriptor?: string; @@ -11885,7 +12673,10 @@ export interface operations { ip?: string; user_agent?: string; }; - /** @description The type of Stripe account to create. Currently must be `custom`, as only [Custom accounts](https://stripe.com/docs/connect/custom-accounts) may be created via the API. */ + /** + * @description The type of Stripe account to create. Currently must be `custom`, as only [Custom accounts](https://stripe.com/docs/connect/custom-accounts) may be created via the API. + * @enum {string} + */ type?: "custom" | "express" | "standard"; }; }; @@ -11955,10 +12746,12 @@ export interface operations { /** @description Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js), or a dictionary containing a user's bank account details. */ bank_account?: Partial<{ account_holder_name?: string; + /** @enum {string} */ account_holder_type?: "company" | "individual"; account_number: string; country: string; currency?: string; + /** @enum {string} */ object?: "bank_account"; routing_number?: string; }> & @@ -11976,7 +12769,10 @@ export interface operations { support_url?: string; url?: string; }; - /** @description The business type. */ + /** + * @description The business type. + * @enum {string} + */ business_type?: "company" | "government_entity" | "individual" | "non_profit"; /** * company_specs @@ -12019,6 +12815,7 @@ export interface operations { name_kanji?: string; owners_provided?: boolean; phone?: string; + /** @enum {string} */ structure?: | "" | "government_instrumentality" @@ -12168,8 +12965,10 @@ export interface operations { /** transfer_schedule_specs */ schedule?: { delay_days?: Partial<"minimum"> & Partial; + /** @enum {string} */ interval?: "daily" | "manual" | "monthly" | "weekly"; monthly_anchor?: number; + /** @enum {string} */ weekly_anchor?: "friday" | "monday" | "saturday" | "sunday" | "thursday" | "tuesday" | "wednesday"; }; statement_descriptor?: string; @@ -12249,10 +13048,12 @@ export interface operations { /** @description Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js), or a dictionary containing a user's bank account details. */ bank_account?: Partial<{ account_holder_name?: string; + /** @enum {string} */ account_holder_type?: "company" | "individual"; account_number: string; country: string; currency?: string; + /** @enum {string} */ object?: "bank_account"; routing_number?: string; }> & @@ -12331,7 +13132,10 @@ export interface operations { "application/x-www-form-urlencoded": { /** @description The name of the person or business that owns the bank account. */ account_holder_name?: string; - /** @description The type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description The type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string} + */ account_holder_type?: "" | "company" | "individual"; /** @description City/District/Suburb/Town/Village. */ address_city?: string; @@ -12408,7 +13212,10 @@ export interface operations { data: components["schemas"]["capability"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -12519,7 +13326,10 @@ export interface operations { data: (Partial & Partial)[]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -12566,10 +13376,12 @@ export interface operations { /** @description Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js), or a dictionary containing a user's bank account details. */ bank_account?: Partial<{ account_holder_name?: string; + /** @enum {string} */ account_holder_type?: "company" | "individual"; account_number: string; country: string; currency?: string; + /** @enum {string} */ object?: "bank_account"; routing_number?: string; }> & @@ -12648,7 +13460,10 @@ export interface operations { "application/x-www-form-urlencoded": { /** @description The name of the person or business that owns the bank account. */ account_holder_name?: string; - /** @description The type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description The type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string} + */ account_holder_type?: "" | "company" | "individual"; /** @description City/District/Suburb/Town/Village. */ address_city?: string; @@ -12808,7 +13623,10 @@ export interface operations { data: components["schemas"]["person"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -13183,7 +14001,10 @@ export interface operations { data: components["schemas"]["person"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -13585,7 +14406,10 @@ export interface operations { data: components["schemas"]["apple_pay_domain"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -13720,7 +14544,10 @@ export interface operations { data: components["schemas"]["application_fee"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -13897,7 +14724,10 @@ export interface operations { data: components["schemas"]["fee_refund"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -14040,7 +14870,10 @@ export interface operations { data: components["schemas"]["balance_transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -14143,7 +14976,10 @@ export interface operations { data: components["schemas"]["balance_transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -14255,7 +15091,10 @@ export interface operations { data: components["schemas"]["bitcoin_receiver"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -14334,7 +15173,10 @@ export interface operations { data: components["schemas"]["bitcoin_transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -14380,7 +15222,10 @@ export interface operations { data: components["schemas"]["bitcoin_transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -14435,7 +15280,10 @@ export interface operations { data: components["schemas"]["charge"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -14495,6 +15343,7 @@ export interface operations { metadata?: { [key: string]: string }; name?: string; number: string; + /** @enum {string} */ object?: "card"; }> & Partial; @@ -14622,6 +15471,7 @@ export interface operations { * @description A set of key-value pairs you can attach to a charge giving information about its riskiness. If you believe a charge is fraudulent, include a `user_report` key with a value of `fraudulent`. If you believe a charge is safe, include a `user_report` key with a value of `safe`. Stripe will use the information you send to improve our fraud detection algorithms. */ fraud_details?: { + /** @enum {string} */ user_report: "" | "fraudulent" | "safe"; }; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ @@ -14876,6 +15726,7 @@ export interface operations { /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ metadata?: Partial<{ [key: string]: string }> & Partial<"">; payment_intent?: string; + /** @enum {string} */ reason?: "duplicate" | "fraudulent" | "requested_by_customer"; refund_application_fee?: boolean; reverse_transfer?: boolean; @@ -14909,7 +15760,10 @@ export interface operations { data: components["schemas"]["refund"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -14959,6 +15813,7 @@ export interface operations { /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ metadata?: Partial<{ [key: string]: string }> & Partial<"">; payment_intent?: string; + /** @enum {string} */ reason?: "duplicate" | "fraudulent" | "requested_by_customer"; refund_application_fee?: boolean; reverse_transfer?: boolean; @@ -15056,7 +15911,10 @@ export interface operations { data: components["schemas"]["checkout.session"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -15095,7 +15953,10 @@ export interface operations { requestBody: { content: { "application/x-www-form-urlencoded": { - /** @description Specify whether Checkout should collect the customer's billing address. */ + /** + * @description Specify whether Checkout should collect the customer's billing address. + * @enum {string} + */ billing_address_collection?: "auto" | "required"; /** @description The URL the customer will be directed to if they decide to cancel payment and return to your website. */ cancel_url: string; @@ -15139,7 +16000,10 @@ export interface operations { quantity: number; tax_rates?: string[]; }[]; - /** @description The IETF language tag of the locale Checkout is displayed in. If blank or `auto`, the browser's locale is used. */ + /** + * @description The IETF language tag of the locale Checkout is displayed in. If blank or `auto`, the browser's locale is used. + * @enum {string} + */ locale?: | "auto" | "da" @@ -15160,7 +16024,10 @@ export interface operations { | "zh"; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ metadata?: { [key: string]: string }; - /** @description The mode of the Checkout Session, one of `payment`, `setup`, or `subscription`. */ + /** + * @description The mode of the Checkout Session, one of `payment`, `setup`, or `subscription`. + * @enum {string} + */ mode?: "payment" | "setup" | "subscription"; /** * payment_intent_data_params @@ -15168,11 +16035,13 @@ export interface operations { */ payment_intent_data?: { application_fee_amount?: number; + /** @enum {string} */ capture_method?: "automatic" | "manual"; description?: string; metadata?: { [key: string]: string }; on_behalf_of?: string; receipt_email?: string; + /** @enum {string} */ setup_future_usage?: "off_session" | "on_session"; /** shipping */ shipping?: { @@ -15459,6 +16328,7 @@ export interface operations { * relevant text on the page, such as the submit button. `submit_type` can only be * specified on Checkout Sessions in `payment` mode, but not Checkout Sessions * in `subscription` or `setup` mode. + * @enum {string} */ submit_type?: "auto" | "book" | "donate" | "pay"; /** @@ -15544,7 +16414,10 @@ export interface operations { data: components["schemas"]["country_spec"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -15625,7 +16498,10 @@ export interface operations { data: components["schemas"]["coupon"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -15672,7 +16548,10 @@ export interface operations { amount_off?: number; /** @description Three-letter [ISO code for the currency](https://stripe.com/docs/currencies) of the `amount_off` parameter (required if `amount_off` is passed). */ currency?: string; - /** @description Specifies how long the discount will be in effect. Can be `forever`, `once`, or `repeating`. */ + /** + * @description Specifies how long the discount will be in effect. Can be `forever`, `once`, or `repeating`. + * @enum {string} + */ duration: "forever" | "once" | "repeating"; /** @description Required only if `duration` is `repeating`, in which case it must be a positive integer that specifies the number of months the discount will be in effect. */ duration_in_months?: number; @@ -15815,7 +16694,10 @@ export interface operations { data: components["schemas"]["credit_note"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -15884,6 +16766,7 @@ export interface operations { invoice_line_item?: string; quantity?: number; tax_rates?: Partial & Partial<"">; + /** @enum {string} */ type: "custom_line_item" | "invoice_line_item"; unit_amount?: number; /** Format: decimal */ @@ -15895,7 +16778,10 @@ export interface operations { metadata?: { [key: string]: string }; /** @description The integer amount in **%s** representing the amount that is credited outside of Stripe. */ out_of_band_amount?: number; - /** @description Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory` */ + /** + * @description Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory` + * @enum {string} + */ reason?: "duplicate" | "fraudulent" | "order_change" | "product_unsatisfactory"; /** @description ID of an existing refund to link this credit note to. */ refund?: string; @@ -15924,6 +16810,7 @@ export interface operations { invoice_line_item?: string; quantity?: number; tax_rates?: Partial & Partial<"">; + /** @enum {string} */ type: "custom_line_item" | "invoice_line_item"; unit_amount?: number; /** Format: decimal */ @@ -15986,6 +16873,7 @@ export interface operations { invoice_line_item?: string; quantity?: number; tax_rates?: Partial & Partial<"">; + /** @enum {string} */ type: "custom_line_item" | "invoice_line_item"; unit_amount?: number; /** Format: decimal */ @@ -16016,7 +16904,10 @@ export interface operations { data: components["schemas"]["credit_note_line_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -16062,7 +16953,10 @@ export interface operations { data: components["schemas"]["credit_note_line_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -16208,7 +17102,10 @@ export interface operations { data: components["schemas"]["customer"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -16310,10 +17207,14 @@ export interface operations { }> & Partial<"">; source?: string; - /** @description The customer's tax exemption. One of `none`, `exempt`, or `reverse`. */ + /** + * @description The customer's tax exemption. One of `none`, `exempt`, or `reverse`. + * @enum {string} + */ tax_exempt?: "" | "exempt" | "none" | "reverse"; /** @description The customer's tax IDs. */ tax_id_data?: { + /** @enum {string} */ type: | "au_abn" | "ca_bn" @@ -16419,10 +17320,12 @@ export interface operations { /** @description Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js), or a dictionary containing a user's bank account details. */ bank_account?: Partial<{ account_holder_name?: string; + /** @enum {string} */ account_holder_type?: "company" | "individual"; account_number: string; country: string; currency?: string; + /** @enum {string} */ object?: "bank_account"; routing_number?: string; }> & @@ -16441,6 +17344,7 @@ export interface operations { metadata?: { [key: string]: string }; name?: string; number: string; + /** @enum {string} */ object?: "card"; }> & Partial; @@ -16508,7 +17412,10 @@ export interface operations { }> & Partial<"">; source?: string; - /** @description The customer's tax exemption. One of `none`, `exempt`, or `reverse`. */ + /** + * @description The customer's tax exemption. One of `none`, `exempt`, or `reverse`. + * @enum {string} + */ tax_exempt?: "" | "exempt" | "none" | "reverse"; /** @description Unix timestamp representing the end of the trial period the customer will get before being charged for the first time. This will always overwrite any trials that might apply via a subscribed plan. If set, trial_end will override the default trial period of the plan the customer is being subscribed to. The special value `now` can be provided to end the customer's trial immediately. Can be at most two years from `billing_cycle_anchor`. */ trial_end?: Partial<"now"> & Partial; @@ -16569,7 +17476,10 @@ export interface operations { data: components["schemas"]["customer_balance_transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -16720,7 +17630,10 @@ export interface operations { data: components["schemas"]["bank_account"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -16775,10 +17688,12 @@ export interface operations { /** @description Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js), or a dictionary containing a user's bank account details. */ bank_account?: Partial<{ account_holder_name?: string; + /** @enum {string} */ account_holder_type?: "company" | "individual"; account_number: string; country: string; currency?: string; + /** @enum {string} */ object?: "bank_account"; routing_number?: string; }> & @@ -16797,6 +17712,7 @@ export interface operations { metadata?: { [key: string]: string }; name?: string; number: string; + /** @enum {string} */ object?: "card"; }> & Partial; @@ -16871,7 +17787,10 @@ export interface operations { "application/x-www-form-urlencoded": { /** @description The name of the person or business that owns the bank account. */ account_holder_name?: string; - /** @description The type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description The type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string} + */ account_holder_type?: "company" | "individual"; /** @description City/District/Suburb/Town/Village. */ address_city?: string; @@ -17008,7 +17927,10 @@ export interface operations { data: components["schemas"]["card"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -17063,10 +17985,12 @@ export interface operations { /** @description Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js), or a dictionary containing a user's bank account details. */ bank_account?: Partial<{ account_holder_name?: string; + /** @enum {string} */ account_holder_type?: "company" | "individual"; account_number: string; country: string; currency?: string; + /** @enum {string} */ object?: "bank_account"; routing_number?: string; }> & @@ -17085,6 +18009,7 @@ export interface operations { metadata?: { [key: string]: string }; name?: string; number: string; + /** @enum {string} */ object?: "card"; }> & Partial; @@ -17159,7 +18084,10 @@ export interface operations { "application/x-www-form-urlencoded": { /** @description The name of the person or business that owns the bank account. */ account_holder_name?: string; - /** @description The type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description The type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string} + */ account_holder_type?: "company" | "individual"; /** @description City/District/Suburb/Town/Village. */ address_city?: string; @@ -17323,7 +18251,10 @@ export interface operations { Partial)[]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -17378,10 +18309,12 @@ export interface operations { /** @description Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js), or a dictionary containing a user's bank account details. */ bank_account?: Partial<{ account_holder_name?: string; + /** @enum {string} */ account_holder_type?: "company" | "individual"; account_number: string; country: string; currency?: string; + /** @enum {string} */ object?: "bank_account"; routing_number?: string; }> & @@ -17400,6 +18333,7 @@ export interface operations { metadata?: { [key: string]: string }; name?: string; number: string; + /** @enum {string} */ object?: "card"; }> & Partial; @@ -17474,7 +18408,10 @@ export interface operations { "application/x-www-form-urlencoded": { /** @description The name of the person or business that owns the bank account. */ account_holder_name?: string; - /** @description The type of entity that holds the account. This can be either `individual` or `company`. */ + /** + * @description The type of entity that holds the account. This can be either `individual` or `company`. + * @enum {string} + */ account_holder_type?: "company" | "individual"; /** @description City/District/Suburb/Town/Village. */ address_city?: string; @@ -17608,7 +18545,10 @@ export interface operations { data: components["schemas"]["subscription"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -17677,7 +18617,10 @@ export interface operations { cancel_at?: number; /** @description Boolean indicating whether this subscription should cancel at the end of the current period. */ cancel_at_period_end?: boolean; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. + * @enum {string} + */ collection_method?: "charge_automatically" | "send_invoice"; /** @description The code of the coupon to apply to this subscription. A coupon applied to a subscription will only affect invoices created for that particular subscription. */ coupon?: string; @@ -17712,10 +18655,12 @@ export interface operations { * Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not create a subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more. * * `pending_if_incomplete` is only used with updates and cannot be passed when creating a subscription. + * @enum {string} */ payment_behavior?: "allow_incomplete" | "error_if_incomplete" | "pending_if_incomplete"; /** @description Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval. */ pending_invoice_item_interval?: Partial<{ + /** @enum {string} */ interval: "day" | "month" | "week" | "year"; interval_count?: number; }> & @@ -17726,6 +18671,7 @@ export interface operations { * @description Determines how to handle [prorations](https://stripe.com/docs/subscriptions/billing-cycle#prorations) resulting from the `billing_cycle_anchor`. Valid values are `create_prorations` or `none`. * * Passing `create_prorations` will cause proration invoice items to be created when applicable. Prorations can be disabled by passing `none`. If no value is passed, the default is `create_prorations`. + * @enum {string} */ proration_behavior?: "always_invoice" | "create_prorations" | "none"; /** @description A non-negative decimal (with at most four decimal places) between 0 and 100. This represents the percentage of the subscription invoice subtotal that will be calculated and added as tax to the final amount in each billing period. For example, a plan which charges $10/month with a `tax_percent` of `20.0` will charge $12 per invoice. To unset a previously-set value, pass an empty string. This field has been deprecated and will be removed in a future API version, for further information view the [migration docs](https://stripe.com/docs/billing/migration/taxes) for `tax_rates`. */ @@ -17799,7 +18745,10 @@ export interface operations { "application/x-www-form-urlencoded": { /** @description A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice subtotal that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions). */ application_fee_percent?: number; - /** @description Either `now` or `unchanged`. Setting the value to `now` resets the subscription's billing cycle anchor to the current time. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle). */ + /** + * @description Either `now` or `unchanged`. Setting the value to `now` resets the subscription's billing cycle anchor to the current time. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle). + * @enum {string} + */ billing_cycle_anchor?: "now" | "unchanged"; /** @description Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds. */ billing_thresholds?: Partial<{ @@ -17811,7 +18760,10 @@ export interface operations { cancel_at?: Partial & Partial<"">; /** @description Boolean indicating whether this subscription should cancel at the end of the current period. */ cancel_at_period_end?: boolean; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. + * @enum {string} + */ collection_method?: "charge_automatically" | "send_invoice"; /** @description The code of the coupon to apply to this subscription. A coupon applied to a subscription will only affect invoices created for that particular subscription. */ coupon?: string; @@ -17845,6 +18797,7 @@ export interface operations { off_session?: boolean; /** @description If specified, payment collection for this subscription will be paused. */ pause_collection?: Partial<{ + /** @enum {string} */ behavior: "keep_as_draft" | "mark_uncollectible" | "void"; /** Format: unix-time */ resumes_at?: number; @@ -17856,10 +18809,12 @@ export interface operations { * Use `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes). * * Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not create a subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more. + * @enum {string} */ payment_behavior?: "allow_incomplete" | "error_if_incomplete" | "pending_if_incomplete"; /** @description Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval. */ pending_invoice_item_interval?: Partial<{ + /** @enum {string} */ interval: "day" | "month" | "week" | "year"; interval_count?: number; }> & @@ -17872,6 +18827,7 @@ export interface operations { * Passing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`. * * Prorations can be disabled by passing `none`. + * @enum {string} */ proration_behavior?: "always_invoice" | "create_prorations" | "none"; /** @@ -18015,7 +18971,10 @@ export interface operations { data: components["schemas"]["tax_id"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -18061,7 +19020,10 @@ export interface operations { "application/x-www-form-urlencoded": { /** @description Specifies which fields in the response should be expanded. */ expand?: string[]; - /** @description Type of the tax ID, one of `eu_vat`, `nz_gst`, `au_abn`, `in_gst`, `no_vat`, `za_vat`, `ch_vat`, `mx_rfc`, `sg_uen`, `ru_inn`, `ca_bn`, `hk_br`, `es_cif`, `tw_vat`, `th_vat`, `jp_cn`, `li_uid`, `my_itn`, `us_ein`, `kr_brn`, `ca_qst`, `my_sst`, or `sg_gst` */ + /** + * @description Type of the tax ID, one of `eu_vat`, `nz_gst`, `au_abn`, `in_gst`, `no_vat`, `za_vat`, `ch_vat`, `mx_rfc`, `sg_uen`, `ru_inn`, `ca_bn`, `hk_br`, `es_cif`, `tw_vat`, `th_vat`, `jp_cn`, `li_uid`, `my_itn`, `us_ein`, `kr_brn`, `ca_qst`, `my_sst`, or `sg_gst` + * @enum {string} + */ type: | "au_abn" | "ca_bn" @@ -18185,7 +19147,10 @@ export interface operations { data: components["schemas"]["dispute"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -18435,7 +19400,10 @@ export interface operations { data: components["schemas"]["event"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -18508,7 +19476,10 @@ export interface operations { data: components["schemas"]["exchange_rate"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -18592,7 +19563,10 @@ export interface operations { data: components["schemas"]["file_link"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -18752,7 +19726,10 @@ export interface operations { data: components["schemas"]["file"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -18809,7 +19786,10 @@ export interface operations { expires_at?: number; metadata?: Partial<{ [key: string]: string }> & Partial<"">; }; - /** @description The purpose of the uploaded file. Possible values are `additional_verification`, `business_icon`, `business_logo`, `customer_signature`, `dispute_evidence`, `identity_document`, `pci_document`, or `tax_document_user_upload`. */ + /** + * @description The purpose of the uploaded file. Possible values are `additional_verification`, `business_icon`, `business_logo`, `customer_signature`, `dispute_evidence`, `identity_document`, `pci_document`, or `tax_document_user_upload`. + * @enum {string} + */ purpose: | "additional_verification" | "business_icon" @@ -18889,7 +19869,10 @@ export interface operations { data: components["schemas"]["invoiceitem"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -19132,7 +20115,10 @@ export interface operations { data: components["schemas"]["invoice"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -19175,7 +20161,10 @@ export interface operations { application_fee_amount?: number; /** @description Controls whether Stripe will perform [automatic collection](https://stripe.com/docs/billing/invoices/workflow/#auto_advance) of the invoice. When `false`, the invoice's state will not automatically advance without an explicit action. */ auto_advance?: boolean; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this invoice using the default source attached to the customer. When sending an invoice, Stripe will email this invoice to the customer with payment instructions. Defaults to `charge_automatically`. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this invoice using the default source attached to the customer. When sending an invoice, Stripe will email this invoice to the customer with payment instructions. Defaults to `charge_automatically`. + * @enum {string} + */ collection_method?: "charge_automatically" | "send_invoice"; /** @description A list of up to 4 custom fields to be displayed on the invoice. */ custom_fields?: Partial< @@ -19421,7 +20410,10 @@ export interface operations { data: components["schemas"]["line_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -19507,7 +20499,10 @@ export interface operations { application_fee_amount?: number; /** @description Controls whether Stripe will perform [automatic collection](https://stripe.com/docs/billing/invoices/workflow/#auto_advance) of the invoice. */ auto_advance?: boolean; - /** @description Either `charge_automatically` or `send_invoice`. This field can be updated only on `draft` invoices. */ + /** + * @description Either `charge_automatically` or `send_invoice`. This field can be updated only on `draft` invoices. + * @enum {string} + */ collection_method?: "charge_automatically" | "send_invoice"; /** @description A list of up to 4 custom fields to be displayed on the invoice. If a value for `custom_fields` is specified, the list specified will replace the existing custom field list on this invoice. Pass an empty string to remove previously-defined fields. */ custom_fields?: Partial< @@ -19631,7 +20626,10 @@ export interface operations { data: components["schemas"]["line_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -19813,7 +20811,10 @@ export interface operations { data: components["schemas"]["issuer_fraud_record"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -19904,7 +20905,10 @@ export interface operations { data: components["schemas"]["issuing.authorization"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -20091,7 +21095,10 @@ export interface operations { data: components["schemas"]["issuing.cardholder"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -21061,13 +22068,20 @@ export interface operations { | "womens_ready_to_wear_stores" | "wrecking_and_salvage_yards" )[]; + /** @enum {string} */ interval: "all_time" | "daily" | "monthly" | "per_authorization" | "weekly" | "yearly"; }[]; spending_limits_currency?: string; }; - /** @description Specifies whether to permit authorizations on this cardholder's cards. Defaults to `active`. */ + /** + * @description Specifies whether to permit authorizations on this cardholder's cards. Defaults to `active`. + * @enum {string} + */ status?: "active" | "inactive"; - /** @description One of `individual` or `company`. */ + /** + * @description One of `individual` or `company`. + * @enum {string} + */ type: "company" | "individual"; }; }; @@ -22057,11 +23071,15 @@ export interface operations { | "womens_ready_to_wear_stores" | "wrecking_and_salvage_yards" )[]; + /** @enum {string} */ interval: "all_time" | "daily" | "monthly" | "per_authorization" | "weekly" | "yearly"; }[]; spending_limits_currency?: string; }; - /** @description Specifies whether to permit authorizations on this cardholder's cards. */ + /** + * @description Specifies whether to permit authorizations on this cardholder's cards. + * @enum {string} + */ status?: "active" | "inactive"; }; }; @@ -22109,7 +23127,10 @@ export interface operations { data: components["schemas"]["issuing.card"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -22158,7 +23179,10 @@ export interface operations { metadata?: { [key: string]: string }; /** @description The card this is meant to be a replacement for (if any). */ replacement_for?: string; - /** @description If `replacement_for` is specified, this should indicate why that card is being replaced. */ + /** + * @description If `replacement_for` is specified, this should indicate why that card is being replaced. + * @enum {string} + */ replacement_reason?: "damaged" | "expired" | "lost" | "stolen"; /** * shipping_specs @@ -22175,7 +23199,9 @@ export interface operations { state?: string; }; name: string; + /** @enum {string} */ service?: "express" | "priority" | "standard"; + /** @enum {string} */ type?: "bulk" | "individual"; }; /** @@ -23055,12 +24081,19 @@ export interface operations { | "womens_ready_to_wear_stores" | "wrecking_and_salvage_yards" )[]; + /** @enum {string} */ interval: "all_time" | "daily" | "monthly" | "per_authorization" | "weekly" | "yearly"; }[]; }; - /** @description Whether authorizations can be approved on this card. Defaults to `inactive`. */ + /** + * @description Whether authorizations can be approved on this card. Defaults to `inactive`. + * @enum {string} + */ status?: "active" | "inactive"; - /** @description The type of card to issue. Possible values are `physical` or `virtual`. */ + /** + * @description The type of card to issue. Possible values are `physical` or `virtual`. + * @enum {string} + */ type: "physical" | "virtual"; }; }; @@ -23121,7 +24154,10 @@ export interface operations { requestBody: { content: { "application/x-www-form-urlencoded": { - /** @description Reason why the `status` of this card is `canceled`. */ + /** + * @description Reason why the `status` of this card is `canceled`. + * @enum {string} + */ cancellation_reason?: "lost" | "stolen"; /** @description Specifies which fields in the response should be expanded. */ expand?: string[]; @@ -24004,10 +25040,14 @@ export interface operations { | "womens_ready_to_wear_stores" | "wrecking_and_salvage_yards" )[]; + /** @enum {string} */ interval: "all_time" | "daily" | "monthly" | "per_authorization" | "weekly" | "yearly"; }[]; }; - /** @description Dictates whether authorizations can be approved on this card. If this card is being canceled because it was lost or stolen, this information should be provided as `cancellation_reason`. */ + /** + * @description Dictates whether authorizations can be approved on this card. If this card is being canceled because it was lost or stolen, this information should be provided as `cancellation_reason`. + * @enum {string} + */ status?: "active" | "canceled" | "inactive"; }; }; @@ -24035,7 +25075,10 @@ export interface operations { data: components["schemas"]["issuing.dispute"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -24175,7 +25218,10 @@ export interface operations { data: components["schemas"]["issuing.settlement"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -24292,7 +25338,10 @@ export interface operations { data: components["schemas"]["issuing.transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -24438,7 +25487,10 @@ export interface operations { data: components["schemas"]["order_return"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -24558,7 +25610,10 @@ export interface operations { data: components["schemas"]["order"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -24614,6 +25669,7 @@ export interface operations { description?: string; parent?: string; quantity?: number; + /** @enum {string} */ type?: "discount" | "shipping" | "sku" | "tax"; }[]; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ @@ -24710,7 +25766,10 @@ export interface operations { carrier: string; tracking_number: string; }; - /** @description Current order status. One of `created`, `paid`, `canceled`, `fulfilled`, or `returned`. More detail in the [Orders Guide](https://stripe.com/docs/orders/guide#understanding-order-statuses). */ + /** + * @description Current order status. One of `created`, `paid`, `canceled`, `fulfilled`, or `returned`. More detail in the [Orders Guide](https://stripe.com/docs/orders/guide#understanding-order-statuses). + * @enum {string} + */ status?: "canceled" | "created" | "fulfilled" | "paid" | "returned"; }; }; @@ -24789,6 +25848,7 @@ export interface operations { description?: string; parent?: string; quantity?: number; + /** @enum {string} */ type?: "discount" | "shipping" | "sku" | "tax"; }[] > & @@ -24829,7 +25889,10 @@ export interface operations { data: components["schemas"]["payment_intent"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -24887,10 +25950,14 @@ export interface operations { * more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts). */ application_fee_amount?: number; - /** @description Controls when the funds will be captured from the customer's account. */ + /** + * @description Controls when the funds will be captured from the customer's account. + * @enum {string} + */ capture_method?: "automatic" | "manual"; /** @description Set to `true` to attempt to [confirm](https://stripe.com/docs/api/payment_intents/confirm) this PaymentIntent immediately. This parameter defaults to `false`. When creating and confirming a PaymentIntent at the same time, parameters available in the [confirm](https://stripe.com/docs/api/payment_intents/confirm) API may also be provided. */ confirm?: boolean; + /** @enum {string} */ confirmation_method?: "automatic" | "manual"; /** @description Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). */ currency: string; @@ -24926,6 +25993,7 @@ export interface operations { ip_address: string; user_agent: string; }; + /** @enum {string} */ type: "offline" | "online"; }; }; @@ -24952,11 +26020,14 @@ export interface operations { enabled?: boolean; plan?: Partial<{ count: number; + /** @enum {string} */ interval: "month"; + /** @enum {string} */ type: "fixed_count"; }> & Partial<"">; }; + /** @enum {string} */ request_three_d_secure?: "any" | "automatic"; }> & Partial<"">; @@ -24973,6 +26044,7 @@ export interface operations { * Providing this parameter will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any required actions from the user are complete. If no Customer was provided, the payment method can still be [attached](https://stripe.com/docs/api/payment_methods/attach) to a Customer after the transaction completes. * * When processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication). + * @enum {string} */ setup_future_usage?: "off_session" | "on_session"; /** @@ -25119,11 +26191,14 @@ export interface operations { enabled?: boolean; plan?: Partial<{ count: number; + /** @enum {string} */ interval: "month"; + /** @enum {string} */ type: "fixed_count"; }> & Partial<"">; }; + /** @enum {string} */ request_three_d_secure?: "any" | "automatic"; }> & Partial<"">; @@ -25140,6 +26215,7 @@ export interface operations { * When processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication). * * If `setup_future_usage` is already set and you are performing a request using a publishable key, you may only update the value from `on_session` to `off_session`. + * @enum {string} */ setup_future_usage?: "" | "off_session" | "on_session"; /** @description Shipping information for this PaymentIntent. */ @@ -25204,7 +26280,10 @@ export interface operations { requestBody: { content: { "application/x-www-form-urlencoded": { - /** @description Reason for canceling this PaymentIntent. Possible values are `duplicate`, `fraudulent`, `requested_by_customer`, or `abandoned` */ + /** + * @description Reason for canceling this PaymentIntent. Possible values are `duplicate`, `fraudulent`, `requested_by_customer`, or `abandoned` + * @enum {string} + */ cancellation_reason?: "abandoned" | "duplicate" | "fraudulent" | "requested_by_customer"; /** @description Specifies which fields in the response should be expanded. */ expand?: string[]; @@ -25339,6 +26418,7 @@ export interface operations { ip_address: string; user_agent: string; }; + /** @enum {string} */ type: "offline" | "online"; }; }> & @@ -25350,6 +26430,7 @@ export interface operations { ip_address?: string; user_agent?: string; }; + /** @enum {string} */ type: "online"; }; }>; @@ -25368,11 +26449,14 @@ export interface operations { enabled?: boolean; plan?: Partial<{ count: number; + /** @enum {string} */ interval: "month"; + /** @enum {string} */ type: "fixed_count"; }> & Partial<"">; }; + /** @enum {string} */ request_three_d_secure?: "any" | "automatic"; }> & Partial<"">; @@ -25395,6 +26479,7 @@ export interface operations { * When processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication). * * If `setup_future_usage` is already set and you are performing a request using a publishable key, you may only update the value from `on_session` to `off_session`. + * @enum {string} */ setup_future_usage?: "" | "off_session" | "on_session"; /** @description Shipping information for this PaymentIntent. */ @@ -25446,7 +26531,10 @@ export interface operations { data: components["schemas"]["payment_method"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -25530,6 +26618,7 @@ export interface operations { * @description If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method. */ fpx?: { + /** @enum {string} */ bank: | "affin_bank" | "alliance_bank" @@ -25557,6 +26646,7 @@ export interface operations { * @description If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method. */ ideal?: { + /** @enum {string} */ bank?: | "abn_amro" | "asn_bank" @@ -25582,7 +26672,10 @@ export interface operations { sepa_debit?: { iban: string; }; - /** @description The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type. Required unless `payment_method` is specified (see the [Cloning PaymentMethods](https://stripe.com/docs/payments/payment-methods/connect#cloning-payment-methods) guide) */ + /** + * @description The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type. Required unless `payment_method` is specified (see the [Cloning PaymentMethods](https://stripe.com/docs/payments/payment-methods/connect#cloning-payment-methods) guide) + * @enum {string} + */ type?: "au_becs_debit" | "card" | "fpx" | "ideal" | "sepa_debit"; }; }; @@ -25796,7 +26889,10 @@ export interface operations { data: components["schemas"]["payout"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -25853,9 +26949,15 @@ export interface operations { expand?: string[]; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ metadata?: { [key: string]: string }; - /** @description The method used to send this payout, which can be `standard` or `instant`. `instant` is only supported for payouts to debit cards. (See [Instant payouts for marketplaces for more information](https://stripe.com/blog/instant-payouts-for-marketplaces).) */ + /** + * @description The method used to send this payout, which can be `standard` or `instant`. `instant` is only supported for payouts to debit cards. (See [Instant payouts for marketplaces for more information](https://stripe.com/blog/instant-payouts-for-marketplaces).) + * @enum {string} + */ method?: "instant" | "standard"; - /** @description The balance type of your Stripe balance to draw this payout from. Balances for different payment sources are kept separately. You can find the amounts with the balances API. One of `bank_account`, `card`, or `fpx`. */ + /** + * @description The balance type of your Stripe balance to draw this payout from. Balances for different payment sources are kept separately. You can find the amounts with the balances API. One of `bank_account`, `card`, or `fpx`. + * @enum {string} + */ source_type?: "bank_account" | "card" | "fpx"; /** @description A string to be displayed on the recipient's bank or card statement. This may be at most 22 characters. Attempting to use a `statement_descriptor` longer than 22 characters will return an error. Note: Most banks will truncate this information and/or display it inconsistently. Some may not display it at all. */ statement_descriptor?: string; @@ -25990,7 +27092,10 @@ export interface operations { data: components["schemas"]["plan"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -26031,7 +27136,10 @@ export interface operations { "application/x-www-form-urlencoded": { /** @description Whether the plan is currently available for new subscriptions. Defaults to `true`. */ active?: boolean; - /** @description Specifies a usage aggregation strategy for plans of `usage_type=metered`. Allowed values are `sum` for summing up all usage during a period, `last_during_period` for using the last usage record reported within a period, `last_ever` for using the last usage record ever (across period bounds) or `max` which uses the usage record with the maximum reported usage during a period. Defaults to `sum`. */ + /** + * @description Specifies a usage aggregation strategy for plans of `usage_type=metered`. Allowed values are `sum` for summing up all usage during a period, `last_during_period` for using the last usage record reported within a period, `last_ever` for using the last usage record ever (across period bounds) or `max` which uses the usage record with the maximum reported usage during a period. Defaults to `sum`. + * @enum {string} + */ aggregate_usage?: "last_during_period" | "last_ever" | "max" | "sum"; /** @description A positive integer in %s (or 0 for a free plan) representing how much to charge on a recurring basis. */ amount?: number; @@ -26040,7 +27148,10 @@ export interface operations { * @description Same as `amount`, but accepts a decimal value with at most 12 decimal places. Only one of `amount` and `amount_decimal` can be set. */ amount_decimal?: string; - /** @description Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `amount`) will be charged per unit in `quantity` (for plans with `usage_type=licensed`), or per unit of total usage (for plans with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes. */ + /** + * @description Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `amount`) will be charged per unit in `quantity` (for plans with `usage_type=licensed`), or per unit of total usage (for plans with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes. + * @enum {string} + */ billing_scheme?: "per_unit" | "tiered"; /** @description Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). */ currency: string; @@ -26048,7 +27159,10 @@ export interface operations { expand?: string[]; /** @description An identifier randomly generated by Stripe. Used to identify this plan when subscribing a customer. You can optionally override this ID, but the ID must be unique across all plans in your Stripe account. You can, however, use the same plan ID in both live and test modes. */ id?: string; - /** @description Specifies billing frequency. Either `day`, `week`, `month` or `year`. */ + /** + * @description Specifies billing frequency. Either `day`, `week`, `month` or `year`. + * @enum {string} + */ interval: "day" | "month" | "week" | "year"; /** @description The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). */ interval_count?: number; @@ -26075,7 +27189,10 @@ export interface operations { unit_amount_decimal?: string; up_to: Partial<"inf"> & Partial; }[]; - /** @description Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price, in `graduated` tiering pricing can successively change as the quantity grows. */ + /** + * @description Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price, in `graduated` tiering pricing can successively change as the quantity grows. + * @enum {string} + */ tiers_mode?: "graduated" | "volume"; /** * transform_usage_param @@ -26083,11 +27200,15 @@ export interface operations { */ transform_usage?: { divide_by: number; + /** @enum {string} */ round: "down" | "up"; }; /** @description Default number of trial days when subscribing a customer to this plan using [`trial_from_plan=true`](https://stripe.com/docs/api#create_subscription-trial_from_plan). */ trial_period_days?: number; - /** @description Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`. */ + /** + * @description Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`. + * @enum {string} + */ usage_type?: "licensed" | "metered"; }; }; @@ -26231,7 +27352,10 @@ export interface operations { data: components["schemas"]["product"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -26309,7 +27433,10 @@ export interface operations { * It must contain at least one letter. */ statement_descriptor?: string; - /** @description The type of the product. Defaults to `service` if not explicitly specified, enabling use of this product with Subscriptions and Plans. Set this parameter to `good` to use this product with Orders and SKUs. On API versions before `2018-02-05`, this field defaults to `good` for compatibility reasons. */ + /** + * @description The type of the product. Defaults to `service` if not explicitly specified, enabling use of this product with Subscriptions and Plans. Set this parameter to `good` to use this product with Orders and SKUs. On API versions before `2018-02-05`, this field defaults to `good` for compatibility reasons. + * @enum {string} + */ type?: "good" | "service"; /** @description A label that represents units of this product in Stripe and on customers’ receipts and invoices. When set, this will be included in associated invoice line item descriptions. */ unit_label?: string; @@ -26468,7 +27595,10 @@ export interface operations { data: components["schemas"]["radar.early_fraud_warning"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -26556,7 +27686,10 @@ export interface operations { data: components["schemas"]["radar.value_list_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -26696,7 +27829,10 @@ export interface operations { data: components["schemas"]["radar.value_list"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -26739,7 +27875,10 @@ export interface operations { alias: string; /** @description Specifies which fields in the response should be expanded. */ expand?: string[]; - /** @description Type of the items in the value list. One of `card_fingerprint`, `card_bin`, `email`, `ip_address`, `country`, `string`, or `case_sensitive_string`. Use `string` if the item type is unknown or mixed. */ + /** + * @description Type of the items in the value list. One of `card_fingerprint`, `card_bin`, `email`, `ip_address`, `country`, `string`, or `case_sensitive_string`. Use `string` if the item type is unknown or mixed. + * @enum {string} + */ item_type?: | "card_bin" | "card_fingerprint" @@ -26882,7 +28021,10 @@ export interface operations { data: components["schemas"]["recipient"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -27090,7 +28232,10 @@ export interface operations { data: components["schemas"]["refund"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -27136,6 +28281,7 @@ export interface operations { /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ metadata?: Partial<{ [key: string]: string }> & Partial<"">; payment_intent?: string; + /** @enum {string} */ reason?: "duplicate" | "fraudulent" | "requested_by_customer"; refund_application_fee?: boolean; reverse_transfer?: boolean; @@ -27239,7 +28385,10 @@ export interface operations { data: components["schemas"]["reporting.report_run"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -27293,6 +28442,7 @@ export interface operations { /** Format: unix-time */ interval_start?: number; payout?: string; + /** @enum {string} */ reporting_category?: | "advance" | "advance_funding" @@ -27325,6 +28475,7 @@ export interface operations { | "topup_reversal" | "transfer" | "transfer_reversal"; + /** @enum {string} */ timezone?: | "Africa/Abidjan" | "Africa/Accra" @@ -27974,7 +29125,10 @@ export interface operations { data: components["schemas"]["reporting.report_type"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -28054,7 +29208,10 @@ export interface operations { data: components["schemas"]["review"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -28169,7 +29326,10 @@ export interface operations { data: components["schemas"]["setup_intent"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -28241,6 +29401,7 @@ export interface operations { ip_address: string; user_agent: string; }; + /** @enum {string} */ type: "offline" | "online"; }; }; @@ -28257,6 +29418,7 @@ export interface operations { payment_method_options?: { /** setup_intent_param */ card?: { + /** @enum {string} */ request_three_d_secure?: "any" | "automatic"; }; }; @@ -28272,7 +29434,10 @@ export interface operations { amount: number; currency: string; }; - /** @description Indicates how the payment method is intended to be used in the future. If not provided, this value defaults to `off_session`. */ + /** + * @description Indicates how the payment method is intended to be used in the future. If not provided, this value defaults to `off_session`. + * @enum {string} + */ usage?: "off_session" | "on_session"; }; }; @@ -28362,6 +29527,7 @@ export interface operations { payment_method_options?: { /** setup_intent_param */ card?: { + /** @enum {string} */ request_three_d_secure?: "any" | "automatic"; }; }; @@ -28399,7 +29565,10 @@ export interface operations { requestBody: { content: { "application/x-www-form-urlencoded": { - /** @description Reason for canceling this SetupIntent. Possible values are `abandoned`, `requested_by_customer`, or `duplicate` */ + /** + * @description Reason for canceling this SetupIntent. Possible values are `abandoned`, `requested_by_customer`, or `duplicate` + * @enum {string} + */ cancellation_reason?: "abandoned" | "duplicate" | "requested_by_customer"; /** @description Specifies which fields in the response should be expanded. */ expand?: string[]; @@ -28462,6 +29631,7 @@ export interface operations { ip_address: string; user_agent: string; }; + /** @enum {string} */ type: "offline" | "online"; }; }> & @@ -28473,6 +29643,7 @@ export interface operations { ip_address?: string; user_agent?: string; }; + /** @enum {string} */ type: "online"; }; }>; @@ -28485,6 +29656,7 @@ export interface operations { payment_method_options?: { /** setup_intent_param */ card?: { + /** @enum {string} */ request_three_d_secure?: "any" | "automatic"; }; }; @@ -28520,7 +29692,10 @@ export interface operations { data: components["schemas"]["scheduled_query_run"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -28603,7 +29778,10 @@ export interface operations { data: components["schemas"]["sku"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -28660,7 +29838,9 @@ export interface operations { */ inventory: { quantity?: number; + /** @enum {string} */ type?: "bucket" | "finite" | "infinite"; + /** @enum {string} */ value?: "" | "in_stock" | "limited" | "out_of_stock"; }; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ @@ -28758,7 +29938,9 @@ export interface operations { */ inventory?: { quantity?: number; + /** @enum {string} */ type?: "bucket" | "finite" | "infinite"; + /** @enum {string} */ value?: "" | "in_stock" | "limited" | "out_of_stock"; }; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ @@ -28833,7 +30015,10 @@ export interface operations { customer?: string; /** @description Specifies which fields in the response should be expanded. */ expand?: string[]; - /** @description The authentication `flow` of the source to create. `flow` is one of `redirect`, `receiver`, `code_verification`, `none`. It is generally inferred unless a type supports multiple flows. */ + /** + * @description The authentication `flow` of the source to create. `flow` is one of `redirect`, `receiver`, `code_verification`, `none`. It is generally inferred unless a type supports multiple flows. + * @enum {string} + */ flow?: "code_verification" | "none" | "receiver" | "redirect"; /** * mandate_params @@ -28856,13 +30041,17 @@ export interface operations { ip?: string; user_agent?: string; }; + /** @enum {string} */ status: "accepted" | "pending" | "refused" | "revoked"; + /** @enum {string} */ type?: "offline" | "online"; user_agent?: string; }; amount?: Partial & Partial<"">; currency?: string; + /** @enum {string} */ interval?: "one_time" | "scheduled" | "variable"; + /** @enum {string} */ notification_method?: "deprecated_none" | "email" | "manual" | "none" | "stripe_email"; }; metadata?: { [key: string]: string }; @@ -28891,6 +30080,7 @@ export interface operations { * @description Optional parameters for the receiver flow. Can be set only if the source is a receiver (`flow` is `receiver`). */ receiver?: { + /** @enum {string} */ refund_attributes_method?: "email" | "manual" | "none"; }; /** @@ -28911,6 +30101,7 @@ export interface operations { description?: string; parent?: string; quantity?: number; + /** @enum {string} */ type?: "discount" | "shipping" | "sku" | "tax"; }[]; /** order_shipping */ @@ -28936,6 +30127,7 @@ export interface operations { token?: string; /** @description The `type` of the source to create. Required unless `customer` and `original_source` are specified (see the [Cloning card Sources](https://stripe.com/docs/sources/connect#cloning-card-sources) guide) */ type?: string; + /** @enum {string} */ usage?: "reusable" | "single_use"; }; }; @@ -29027,13 +30219,17 @@ export interface operations { ip?: string; user_agent?: string; }; + /** @enum {string} */ status: "accepted" | "pending" | "refused" | "revoked"; + /** @enum {string} */ type?: "offline" | "online"; user_agent?: string; }; amount?: Partial & Partial<"">; currency?: string; + /** @enum {string} */ interval?: "one_time" | "scheduled" | "variable"; + /** @enum {string} */ notification_method?: "deprecated_none" | "email" | "manual" | "none" | "stripe_email"; }; /** @description Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ @@ -29067,6 +30263,7 @@ export interface operations { description?: string; parent?: string; quantity?: number; + /** @enum {string} */ type?: "discount" | "shipping" | "sku" | "tax"; }[]; /** order_shipping */ @@ -29147,7 +30344,10 @@ export interface operations { data: components["schemas"]["source_transaction"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -29255,7 +30455,10 @@ export interface operations { data: components["schemas"]["subscription_item"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -29309,6 +30512,7 @@ export interface operations { * Use `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes). * * Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not create a subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more. + * @enum {string} */ payment_behavior?: "allow_incomplete" | "error_if_incomplete" | "pending_if_incomplete"; /** @description The identifier of the plan to add to the subscription. */ @@ -29321,6 +30525,7 @@ export interface operations { * Passing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`. * * Prorations can be disabled by passing `none`. + * @enum {string} */ proration_behavior?: "always_invoice" | "create_prorations" | "none"; /** @@ -29410,6 +30615,7 @@ export interface operations { * Use `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes). * * Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not create a subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more. + * @enum {string} */ payment_behavior?: "allow_incomplete" | "error_if_incomplete" | "pending_if_incomplete"; /** @description The identifier of the new plan for this subscription item. */ @@ -29422,6 +30628,7 @@ export interface operations { * Passing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`. * * Prorations can be disabled by passing `none`. + * @enum {string} */ proration_behavior?: "always_invoice" | "create_prorations" | "none"; /** @@ -29471,6 +30678,7 @@ export interface operations { * Passing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`. * * Prorations can be disabled by passing `none`. + * @enum {string} */ proration_behavior?: "always_invoice" | "create_prorations" | "none"; /** @@ -29511,7 +30719,10 @@ export interface operations { data: components["schemas"]["usage_record_summary"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -29563,7 +30774,10 @@ export interface operations { requestBody: { content: { "application/x-www-form-urlencoded": { - /** @description Valid values are `increment` (default) or `set`. When using `increment` the specified `quantity` will be added to the usage at the specified timestamp. The `set` action will overwrite the usage quantity at that timestamp. If the subscription has [billing thresholds](https://stripe.com/docs/api/subscriptions/object#subscription_object-billing_thresholds), `increment` is the only allowed value. */ + /** + * @description Valid values are `increment` (default) or `set`. When using `increment` the specified `quantity` will be added to the usage at the specified timestamp. The `set` action will overwrite the usage quantity at that timestamp. If the subscription has [billing thresholds](https://stripe.com/docs/api/subscriptions/object#subscription_object-billing_thresholds), `increment` is the only allowed value. + * @enum {string} + */ action?: "increment" | "set"; /** @description Specifies which fields in the response should be expanded. */ expand?: string[]; @@ -29633,7 +30847,10 @@ export interface operations { data: components["schemas"]["subscription_schedule"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -29684,6 +30901,7 @@ export interface operations { reset_billing_cycle_anchor?: boolean; }> & Partial<"">; + /** @enum {string} */ collection_method?: "charge_automatically" | "send_invoice"; default_payment_method?: string; /** subscription_schedules_param */ @@ -29691,7 +30909,10 @@ export interface operations { days_until_due?: number; }; }; - /** @description Configures how the subscription schedule behaves when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running.`cancel` will end the subscription schedule and cancel the underlying subscription. */ + /** + * @description Configures how the subscription schedule behaves when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running.`cancel` will end the subscription schedule and cancel the underlying subscription. + * @enum {string} + */ end_behavior?: "cancel" | "none" | "release" | "renew"; /** @description Specifies which fields in the response should be expanded. */ expand?: string[]; @@ -29707,6 +30928,7 @@ export interface operations { reset_billing_cycle_anchor?: boolean; }> & Partial<"">; + /** @enum {string} */ collection_method?: "charge_automatically" | "send_invoice"; coupon?: string; default_payment_method?: string; @@ -29727,6 +30949,7 @@ export interface operations { quantity?: number; tax_rates?: Partial & Partial<"">; }[]; + /** @enum {string} */ proration_behavior?: "always_invoice" | "create_prorations" | "none"; tax_percent?: number; trial?: boolean; @@ -29804,6 +31027,7 @@ export interface operations { reset_billing_cycle_anchor?: boolean; }> & Partial<"">; + /** @enum {string} */ collection_method?: "charge_automatically" | "send_invoice"; default_payment_method?: string; /** subscription_schedules_param */ @@ -29811,7 +31035,10 @@ export interface operations { days_until_due?: number; }; }; - /** @description Configures how the subscription schedule behaves when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running.`cancel` will end the subscription schedule and cancel the underlying subscription. */ + /** + * @description Configures how the subscription schedule behaves when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running.`cancel` will end the subscription schedule and cancel the underlying subscription. + * @enum {string} + */ end_behavior?: "cancel" | "none" | "release" | "renew"; /** @description Specifies which fields in the response should be expanded. */ expand?: string[]; @@ -29825,6 +31052,7 @@ export interface operations { reset_billing_cycle_anchor?: boolean; }> & Partial<"">; + /** @enum {string} */ collection_method?: "charge_automatically" | "send_invoice"; coupon?: string; default_payment_method?: string; @@ -29844,6 +31072,7 @@ export interface operations { quantity?: number; tax_rates?: Partial & Partial<"">; }[]; + /** @enum {string} */ proration_behavior?: "always_invoice" | "create_prorations" | "none"; start_date?: Partial & Partial<"now">; tax_percent?: number; @@ -29852,7 +31081,10 @@ export interface operations { }[]; /** @description This field has been renamed to `proration_behavior`. `prorate=true` can be replaced with `proration_behavior=create_prorations` and `prorate=false` can be replaced with `proration_behavior=none`. */ prorate?: boolean; - /** @description If the update changes the current phase, indicates if the changes should be prorated. Valid values are `create_prorations` or `none`, and the default value is `create_prorations`. */ + /** + * @description If the update changes the current phase, indicates if the changes should be prorated. Valid values are `create_prorations` or `none`, and the default value is `create_prorations`. + * @enum {string} + */ proration_behavior?: "always_invoice" | "create_prorations" | "none"; }; }; @@ -29984,7 +31216,10 @@ export interface operations { data: components["schemas"]["subscription"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -30048,7 +31283,10 @@ export interface operations { cancel_at?: number; /** @description Boolean indicating whether this subscription should cancel at the end of the current period. */ cancel_at_period_end?: boolean; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. + * @enum {string} + */ collection_method?: "charge_automatically" | "send_invoice"; /** @description The code of the coupon to apply to this subscription. A coupon applied to a subscription will only affect invoices created for that particular subscription. */ coupon?: string; @@ -30085,10 +31323,12 @@ export interface operations { * Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not create a subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more. * * `pending_if_incomplete` is only used with updates and cannot be passed when creating a subscription. + * @enum {string} */ payment_behavior?: "allow_incomplete" | "error_if_incomplete" | "pending_if_incomplete"; /** @description Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval. */ pending_invoice_item_interval?: Partial<{ + /** @enum {string} */ interval: "day" | "month" | "week" | "year"; interval_count?: number; }> & @@ -30099,6 +31339,7 @@ export interface operations { * @description Determines how to handle [prorations](https://stripe.com/docs/subscriptions/billing-cycle#prorations) resulting from the `billing_cycle_anchor`. Valid values are `create_prorations` or `none`. * * Passing `create_prorations` will cause proration invoice items to be created when applicable. Prorations can be disabled by passing `none`. If no value is passed, the default is `create_prorations`. + * @enum {string} */ proration_behavior?: "always_invoice" | "create_prorations" | "none"; /** @description A non-negative decimal (with at most four decimal places) between 0 and 100. This represents the percentage of the subscription invoice subtotal that will be calculated and added as tax to the final amount in each billing period. For example, a plan which charges $10/month with a `tax_percent` of `20.0` will charge $12 per invoice. To unset a previously-set value, pass an empty string. This field has been deprecated and will be removed in a future API version, for further information view the [migration docs](https://stripe.com/docs/billing/migration/taxes) for `tax_rates`. */ @@ -30170,7 +31411,10 @@ export interface operations { "application/x-www-form-urlencoded": { /** @description A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice subtotal that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions). */ application_fee_percent?: number; - /** @description Either `now` or `unchanged`. Setting the value to `now` resets the subscription's billing cycle anchor to the current time. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle). */ + /** + * @description Either `now` or `unchanged`. Setting the value to `now` resets the subscription's billing cycle anchor to the current time. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle). + * @enum {string} + */ billing_cycle_anchor?: "now" | "unchanged"; /** @description Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds. */ billing_thresholds?: Partial<{ @@ -30182,7 +31426,10 @@ export interface operations { cancel_at?: Partial & Partial<"">; /** @description Boolean indicating whether this subscription should cancel at the end of the current period. */ cancel_at_period_end?: boolean; - /** @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. */ + /** + * @description Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`. + * @enum {string} + */ collection_method?: "charge_automatically" | "send_invoice"; /** @description The code of the coupon to apply to this subscription. A coupon applied to a subscription will only affect invoices created for that particular subscription. */ coupon?: string; @@ -30216,6 +31463,7 @@ export interface operations { off_session?: boolean; /** @description If specified, payment collection for this subscription will be paused. */ pause_collection?: Partial<{ + /** @enum {string} */ behavior: "keep_as_draft" | "mark_uncollectible" | "void"; /** Format: unix-time */ resumes_at?: number; @@ -30227,10 +31475,12 @@ export interface operations { * Use `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes). * * Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not create a subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more. + * @enum {string} */ payment_behavior?: "allow_incomplete" | "error_if_incomplete" | "pending_if_incomplete"; /** @description Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval. */ pending_invoice_item_interval?: Partial<{ + /** @enum {string} */ interval: "day" | "month" | "week" | "year"; interval_count?: number; }> & @@ -30243,6 +31493,7 @@ export interface operations { * Passing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`. * * Prorations can be disabled by passing `none`. + * @enum {string} */ proration_behavior?: "always_invoice" | "create_prorations" | "none"; /** @@ -30361,7 +31612,10 @@ export interface operations { data: components["schemas"]["tax_rate"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -30540,7 +31794,10 @@ export interface operations { data: components["schemas"]["terminal.location"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -30734,7 +31991,10 @@ export interface operations { data: components["schemas"]["terminal.reader"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -30906,6 +32166,7 @@ export interface operations { * @description Information for the account this token will represent. */ account?: { + /** @enum {string} */ business_type?: "company" | "government_entity" | "individual" | "non_profit"; /** company_specs */ company?: { @@ -30945,6 +32206,7 @@ export interface operations { name_kanji?: string; owners_provided?: boolean; phone?: string; + /** @enum {string} */ structure?: | "" | "government_instrumentality" @@ -31046,6 +32308,7 @@ export interface operations { */ bank_account?: { account_holder_name?: string; + /** @enum {string} */ account_holder_type?: "company" | "individual"; account_number: string; country: string; @@ -31229,7 +32492,10 @@ export interface operations { data: components["schemas"]["topup"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -31417,7 +32683,10 @@ export interface operations { data: components["schemas"]["transfer"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -31470,7 +32739,10 @@ export interface operations { metadata?: { [key: string]: string }; /** @description You can use this parameter to transfer funds from a charge before they are added to your available balance. A pending balance will transfer immediately but the funds will not become available until the original charge becomes available. [See the Connect documentation](https://stripe.com/docs/connect/charges-transfers#transfer-availability) for details. */ source_transaction?: string; - /** @description The source balance to use for this transfer. One of `bank_account`, `card`, or `fpx`. For most users, this will default to `card`. */ + /** + * @description The source balance to use for this transfer. One of `bank_account`, `card`, or `fpx`. For most users, this will default to `card`. + * @enum {string} + */ source_type?: "bank_account" | "card" | "fpx"; /** @description A string that identifies this transaction as part of a group. See the [Connect documentation](https://stripe.com/docs/connect/charges-transfers#transfer-options) for details. */ transfer_group?: string; @@ -31504,7 +32776,10 @@ export interface operations { data: components["schemas"]["transfer_reversal"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -31728,7 +33003,10 @@ export interface operations { data: components["schemas"]["webhook_endpoint"][]; /** @description True if this list has another page of items after this one that can be fetched. */ has_more: boolean; - /** @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. */ + /** + * @description String representing the object's type. Objects of the same type share the same value. Always has the value `list`. + * @enum {string} + */ object: "list"; /** @description The URL where this list can be accessed. */ url: string; @@ -31767,7 +33045,10 @@ export interface operations { requestBody: { content: { "application/x-www-form-urlencoded": { - /** @description Events sent to this endpoint will be generated with this Stripe Version instead of your account's default Stripe Version. */ + /** + * @description Events sent to this endpoint will be generated with this Stripe Version instead of your account's default Stripe Version. + * @enum {string} + */ api_version?: | "2011-01-01" | "2011-06-21" diff --git a/test/v3/specs/consts-enums.yaml b/test/v3/specs/consts-enums.yaml new file mode 100644 index 000000000..56f19a9d9 --- /dev/null +++ b/test/v3/specs/consts-enums.yaml @@ -0,0 +1,31 @@ +openapi: 3.0 +paths: + /test: + get: + tags: + - test + summary: "Just a test path" + responses: + 200: + description: A list of types. +components: + schemas: + MyType: + description: Enum with null and nullable + type: object + properties: + myEnumTestFieldNullable: + type: string + enum: ["foo", "bar", null] + nullable: true + myEnumTestField: + type: string + enum: ["foo", "bar", null] + nullable: true + myConstTestField: + type: string + const: "constant-value" + myConstTestFieldNullable: + type: number + const: 4 + nullable: true \ No newline at end of file