Versioning 

About the API
Versioning

Each major release, such as Acacia, includes changes that aren’t backward-compatible with previous releases. Upgrading to a new major release can require updates to existing code. Each monthly release includes only backward-compatible changes, and uses the same name as the last major release. You can safely upgrade to a new monthly release without breaking any existing code. The current version is 2025-08-27.basil. For information on all API versions, view our API changelog.

Because stripe-go is strongly typed, the requests you send align with the API version current at your stripe-go version’s release time. If you want to use a newer or older API version, consider upgrading or downgrading your stripe-go version. Use the stripe-go changelog to find which versions include the API version you need.

Webhook events use the API version that’s set during your webhook’s endpoint creation. Otherwise, they use your Stripe account’s default API version (controlled in Workbench). Create a webhook endpoint with an API version equal to the version that’s pinned by your version of stripe-go, which you can determine through the stripe.apiversion property.

You can upgrade your API version in Workbench. As a precaution, use API versioning to test a new API version before committing to an upgrade.

stripe.Key = "sk_test_BQokikJ...2HlWgH4olfQ2sk_test_BQokikJOvBiI2HlWgH4olfQ2"
// Since Go is strongly typed,
// the version is fixed in the library.