Skip to content

Commit 1f01c99

Browse files
Merge pull request #2657 from stripe/latest-codegen-private-preview
Update generated code for private-preview
2 parents e93f5bb + b9d8824 commit 1f01c99

23 files changed

+1429
-295
lines changed

CODEGEN_VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
cc139a3b30d5b2f0f971548b8e7f169da0b982f7
1+
2c60f902831f969f228cecd1f52a81ca240c433c

OPENAPI_VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
v2218
1+
v2229

src/Error.ts

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,8 @@ export const generateV2Error = (
7373
return new AlreadyExistsError(rawStripeError);
7474
case 'blocked_by_stripe':
7575
return new BlockedByStripeError(rawStripeError);
76+
case 'cannot_proceed':
77+
return new CannotProceedError(rawStripeError);
7678
case 'controlled_by_alternate_resource':
7779
return new ControlledByAlternateResourceError(rawStripeError);
7880
case 'controlled_by_dashboard':
@@ -362,6 +364,14 @@ export class BlockedByStripeError extends StripeError {
362364
super(rawStripeError, 'BlockedByStripeError');
363365
}
364366
}
367+
export class CannotProceedError extends StripeError {
368+
reason: string;
369+
constructor(rawStripeError: StripeRawError) {
370+
super(rawStripeError, 'CannotProceedError');
371+
// @ts-ignore
372+
this.reason = this.raw.reason;
373+
}
374+
}
365375
export class ControlledByAlternateResourceError extends StripeError {
366376
constructor(rawStripeError: StripeRawError = {}) {
367377
super(rawStripeError, 'ControlledByAlternateResourceError');

src/Types.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,7 @@ export type RawErrorType =
6363
| 'already_canceled'
6464
| 'already_exists'
6565
| 'blocked_by_stripe'
66+
| 'cannot_proceed'
6667
| 'controlled_by_alternate_resource'
6768
| 'controlled_by_dashboard'
6869
| 'feature_not_enabled'

src/apiVersion.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
// File generated from our OpenAPI spec
22

3-
export const ApiVersion = '2026-04-01.preview';
3+
export const ApiVersion = '2026-04-08.preview';

src/resources/ApplicationFees.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -224,6 +224,11 @@ export namespace ApplicationFee {
224224
* Type of object that created the application fee.
225225
*/
226226
type: FeeSource.Type;
227+
228+
/**
229+
* PaymentRecord ID that created this application fee.
230+
*/
231+
payment_record?: string;
227232
}
228233

229234
export interface FundingSource {

src/resources/Charges.ts

Lines changed: 232 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3847,7 +3847,7 @@ export namespace ChargeUpdateParams {
38473847
/**
38483848
* The type of money services transaction.
38493849
*/
3850-
transaction_type?: 'account_funding';
3850+
transaction_type?: Emptyable<'account_funding'>;
38513851
}
38523852

38533853
export namespace CarRental {
@@ -5294,7 +5294,121 @@ export namespace ChargeUpdateParams {
52945294
}
52955295

52965296
export namespace MoneyServices {
5297-
export interface AccountFunding {}
5297+
export interface AccountFunding {
5298+
/**
5299+
* ID of the Account representing the beneficiary in this account funding transaction.
5300+
*/
5301+
beneficiary_account?: string;
5302+
5303+
/**
5304+
* Inline identity details for the beneficiary of this account funding transaction.
5305+
*/
5306+
beneficiary_details?: Emptyable<AccountFunding.BeneficiaryDetails>;
5307+
5308+
/**
5309+
* ID of the Account representing the sender in this account funding transaction.
5310+
*/
5311+
sender_account?: string;
5312+
5313+
/**
5314+
* Inline identity details for the sender of this account funding transaction.
5315+
*/
5316+
sender_details?: Emptyable<AccountFunding.SenderDetails>;
5317+
}
5318+
5319+
export namespace AccountFunding {
5320+
export interface BeneficiaryDetails {
5321+
/**
5322+
* Address.
5323+
*/
5324+
address?: AddressParam;
5325+
5326+
/**
5327+
* Date of birth.
5328+
*/
5329+
date_of_birth?: BeneficiaryDetails.DateOfBirth;
5330+
5331+
/**
5332+
* Email address.
5333+
*/
5334+
email?: string;
5335+
5336+
/**
5337+
* Full name.
5338+
*/
5339+
name?: string;
5340+
5341+
/**
5342+
* Phone number.
5343+
*/
5344+
phone?: string;
5345+
}
5346+
5347+
export interface SenderDetails {
5348+
/**
5349+
* Address.
5350+
*/
5351+
address?: AddressParam;
5352+
5353+
/**
5354+
* Date of birth.
5355+
*/
5356+
date_of_birth?: SenderDetails.DateOfBirth;
5357+
5358+
/**
5359+
* Email address.
5360+
*/
5361+
email?: string;
5362+
5363+
/**
5364+
* Full name.
5365+
*/
5366+
name?: string;
5367+
5368+
/**
5369+
* Phone number.
5370+
*/
5371+
phone?: string;
5372+
}
5373+
5374+
export namespace BeneficiaryDetails {
5375+
export interface DateOfBirth {
5376+
/**
5377+
* Day of birth, between 1 and 31.
5378+
*/
5379+
day: number;
5380+
5381+
/**
5382+
* Month of birth, between 1 and 12.
5383+
*/
5384+
month: number;
5385+
5386+
/**
5387+
* Four-digit year of birth.
5388+
*/
5389+
year: number;
5390+
}
5391+
}
5392+
5393+
export namespace SenderDetails {
5394+
export interface DateOfBirth {
5395+
/**
5396+
* Day of birth, between 1 and 31.
5397+
*/
5398+
day: number;
5399+
5400+
/**
5401+
* Month of birth, between 1 and 12.
5402+
*/
5403+
month: number;
5404+
5405+
/**
5406+
* Four-digit year of birth.
5407+
*/
5408+
year: number;
5409+
}
5410+
}
5411+
}
52985412
}
52995413

53005414
export namespace Subscription {
@@ -6049,7 +6163,7 @@ export namespace ChargeCaptureParams {
60496163
/**
60506164
* The type of money services transaction.
60516165
*/
6052-
transaction_type?: 'account_funding';
6166+
transaction_type?: Emptyable<'account_funding'>;
60536167
}
60546168

60556169
export namespace CarRental {
@@ -7496,7 +7610,121 @@ export namespace ChargeCaptureParams {
74967610
}
74977611

74987612
export namespace MoneyServices {
7499-
export interface AccountFunding {}
7613+
export interface AccountFunding {
7614+
/**
7615+
* ID of the Account representing the beneficiary in this account funding transaction.
7616+
*/
7617+
beneficiary_account?: string;
7618+
7619+
/**
7620+
* Inline identity details for the beneficiary of this account funding transaction.
7621+
*/
7622+
beneficiary_details?: Emptyable<AccountFunding.BeneficiaryDetails>;
7623+
7624+
/**
7625+
* ID of the Account representing the sender in this account funding transaction.
7626+
*/
7627+
sender_account?: string;
7628+
7629+
/**
7630+
* Inline identity details for the sender of this account funding transaction.
7631+
*/
7632+
sender_details?: Emptyable<AccountFunding.SenderDetails>;
7633+
}
7634+
7635+
export namespace AccountFunding {
7636+
export interface BeneficiaryDetails {
7637+
/**
7638+
* Address.
7639+
*/
7640+
address?: AddressParam;
7641+
7642+
/**
7643+
* Date of birth.
7644+
*/
7645+
date_of_birth?: BeneficiaryDetails.DateOfBirth;
7646+
7647+
/**
7648+
* Email address.
7649+
*/
7650+
email?: string;
7651+
7652+
/**
7653+
* Full name.
7654+
*/
7655+
name?: string;
7656+
7657+
/**
7658+
* Phone number.
7659+
*/
7660+
phone?: string;
7661+
}
7662+
7663+
export interface SenderDetails {
7664+
/**
7665+
* Address.
7666+
*/
7667+
address?: AddressParam;
7668+
7669+
/**
7670+
* Date of birth.
7671+
*/
7672+
date_of_birth?: SenderDetails.DateOfBirth;
7673+
7674+
/**
7675+
* Email address.
7676+
*/
7677+
email?: string;
7678+
7679+
/**
7680+
* Full name.
7681+
*/
7682+
name?: string;
7683+
7684+
/**
7685+
* Phone number.
7686+
*/
7687+
phone?: string;
7688+
}
7689+
7690+
export namespace BeneficiaryDetails {
7691+
export interface DateOfBirth {
7692+
/**
7693+
* Day of birth, between 1 and 31.
7694+
*/
7695+
day: number;
7696+
7697+
/**
7698+
* Month of birth, between 1 and 12.
7699+
*/
7700+
month: number;
7701+
7702+
/**
7703+
* Four-digit year of birth.
7704+
*/
7705+
year: number;
7706+
}
7707+
}
7708+
7709+
export namespace SenderDetails {
7710+
export interface DateOfBirth {
7711+
/**
7712+
* Day of birth, between 1 and 31.
7713+
*/
7714+
day: number;
7715+
7716+
/**
7717+
* Month of birth, between 1 and 12.
7718+
*/
7719+
month: number;
7720+
7721+
/**
7722+
* Four-digit year of birth.
7723+
*/
7724+
year: number;
7725+
}
7726+
}
7727+
}
75007728
}
75017729

75027730
export namespace Subscription {

0 commit comments

Comments
 (0)