Async Stripe

Quick Start

Get up and running as quickly as possible.

Welcome to the async-stripe documentation. This library provides strongly-typed, safe, and performant Rust bindings for the Stripe API. It is designed to be modular, allowing you to pull in only the specific Stripe resources you need for your application.

API Version

The current API version for async-stripe v1.0.0-alpha.8 is:

pub const VERSION: crate::ApiVersion = crate::ApiVersion::V2025_11_17_clover;

This means all API requests will use this version regardless of your Stripe account's default API version. This ensures consistent behavior and prevents breaking changes from affecting your application unexpectedly.

Compatibility

async-stripe is pinned to a specific Stripe API version. Each week, we sync against the official APIs and bump our types to match. It is critically important that you understand which version you're using, as mismatches between the library version and your expectations can lead to unexpected behavior, missing features, or parsing errors. As a result, you should when possible be regularly updating the both this library, and your Stripe account's api, to the latest available version.

We do not currently have the resources to backport fixes to older APIs.

Any webhooks received that to not match this version will publish a warning via tracing.

Quick Start

Here's a quick example of how to create a new Stripe Customer.

1. Add dependencies to your Cargo.toml

You'll need the main async-stripe crate for the client and a resource crate for the APIs you want to use (e.g., stripe-core for customers).

[dependencies]
async-stripe = "=1.0.0-alpha.8"
stripe-core = { version = "=1.0.0-alpha.8", features = ["customer"] }
tokio = { version = "1", features = ["full"] }

2. Create a Customer

The new API uses a builder pattern that flows naturally from request creation to sending.

let customer = CreateCustomer::new()
    .name("Alexander Lyon")
    .email("test@async-stripe.com")
    .description("A fake customer that is used to illustrate the examples in async-stripe.")
    .metadata([(String::from("async-stripe"), String::from("true"))])
    .send(client)
    .await?;
Have feedback? Let us know here