This release changes the pinned API version to 2026-03-25.dahlia and contains breaking changes (prefixed with ⚠️ below). There's also a detailed migration guide to simplify your upgrade process.
Please review details for the breaking changes and alternatives in the Stripe API changelog before upgrading.
-
⚠️ Breaking change: #2301 Make unmarshalJSONVerbose unexported and context-aware
- Unexported
BackendImplementation.UnmarshalJSONVerbose(nowunmarshalJSONVerbose) and added acontext.Contextparameter for proper context propagation in error logging.
- Unexported
-
⚠️ Breaking change: #2324 Fix MinimumBalanceByCurrency map value type to support clearing
MinimumBalanceByCurrencychanged frommap[string]int64tomap[string]*int64onBalanceSettingsPaymentsPayoutsParamsandBalanceSettingsUpdatePaymentsPayoutsParams. This field now supports clearing a value in the map by assigning null to the map key.
-
⚠️ Breaking change: #2320 Throw an error when using the wrong webhook parsing method
-
⚠️ Breaking change: #2310 Regenerate with decimal_string enabled for v2 APIs
- V2 API decimal fields changed type from
stringtofloat64withjson:",string"andform:",high_precision"struct tags. Code that passes these fields asstringwill need to usefloat64instead. Affected fields:- V2CoreAccountIdentityIndividualRelationship:
PercentOwnership - V2CoreAccountPersonRelationship:
PercentOwnership - Params:
V2CoreAccountIdentityIndividualRelationshipParams,V2CoreAccountCreateIdentityIndividualRelationshipParams,V2CoreAccountUpdateIdentityIndividualRelationshipParams,V2CoreAccountTokenIdentityIndividualRelationshipParams,V2CoreAccountTokenCreateIdentityIndividualRelationshipParams,V2CoreAccountsPersonRelationshipParams,V2CoreAccountsPersonCreateRelationshipParams,V2CoreAccountsPersonUpdateRelationshipParams,V2CoreAccountsPersonTokenRelationshipParams,V2CoreAccountsPersonTokenCreateRelationshipParams
- V2CoreAccountIdentityIndividualRelationship:
- V2 API decimal fields changed type from
-
⚠️ Breaking change: #2309 Drop support for Go < 1.22
-
⚠️ Breaking change: #2179 [Breaking] Update
ListandSearchmethods withstripe.Clientto return astructListandSearchmethods usingstripe.Clientnow return astructinstead ofSeq2. This is a backwards incompatible change, and you will need to add an additional call to.All(ctx)in yourforloop. E.g.
-for c, err := range sc.V1Customers.List(ctx, nil) { +for c, err := range sc.V1Customers.List(ctx, nil).All(ctx) { // handle err // do something }
- For manual pagination use cases, you can access the API call's
errorby callinglist.Err(), a page's data usinglist.Data(), and its metadata by callinglist.Meta().
-
⚠️ Breaking change: #2260 Fix typo in V2RawError struct field name
- Fixes misspelling in
V2RawError.UserMesage-->V2RawError.UserMessage
- Fixes misspelling in
-
#2263 Add helpers in preparation for BatchJobs public preview support
-
#2322 Add
UnsetFieldsfor clearing field values in v1 and v2 API requests- Added
UnsetFieldsfield andAddUnsetFieldmethod toParamsfor explicitly clearing field values in API requests. For v2 JSON requests, listed fields are sent as"field": null. For v1 form requests, listed fields are sent asfield=(empty string). - Nested params structs with emptyable fields carry their own
UnsetFieldsslice, enabling clearing of nested fields (e.g.params.CancellationDetails.AddUnsetField(...)). - Generated
UnsetFieldstring enum types provide type-safe constants for each clearable field (e.g.SubscriptionUpdateParamsUnsetFieldDescription).
- Added