Skip to content

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

1 Commit

Folders and files

Repository files navigation

Vatly for Rust

Rust crates for Vatly, the European Merchant of Record for AI, software and digital products. You just ship. Vatly is the legal seller on every sale and handles payments, tax and compliance, from Europe.

Alpha — under active development. Every alpha release may include breaking changes. Lock the version you install and review the release notes before upgrading.

Crate Import as Mirrors Use it for
vatly-api vatly_api vatly/vatly-api-php The typed async API client, webhook verification and typed webhook events.
vatly-fluent vatly_fluent vatly/vatly-fluent-php Checkout and subscription builders, customer bindings, and verified webhooks synced into storage you implement.
vatly-laravel-rust vatly_laravel vatly/vatly-laravel Laravel for Rust apps: a service provider, migrations, the webhook route, events, and a Billable trait.

Each layer builds on the one above it, like the PHP packages. Pick the highest one that fits:

  • Laravel for Rust app: vatly-laravel-rust. It wires Fluent for you.
  • Axum, Actix or another framework: vatly-fluent. You supply routes and storage.
  • Only direct API requests: vatly-api.

A complete Laravel for Rust application using these crates lives in vatly/vatly-laravel-rust-demo.

Naming

The crate names follow Vatly's package names (vatly-api-*, vatly-fluent-*, vatly-laravel) and crates.io conventions (kebab-case package names, snake_case library names):

  • vatly-api and vatly-fluent drop the language suffix the PHP packages carry, because on crates.io the registry already says Rust, as stripe and reqwest do.
  • vatly-laravel-rust keeps -rust, following the framework's own ecosystem: laravel-rust (imported as laravel), inertia-laravel-rust (inertia) and laravel-vite-rust (vite). It also leaves vatly-laravel free on crates.io, where it would be mistaken for the PHP package. Its library is vatly_laravel, so code reads use vatly_laravel::VatlyServiceProvider, next to use laravel::....

Tests

cargo test --workspace --features vatly-laravel-rust/database-sqlite

The suites run against vatly-mock, an in-memory mock of the Vatly API written from the OpenAPI spec. It answers over real HTTP, replays idempotency keys, and sends signed webhooks. With a test-mode key, one more suite runs against the real API:

VATLY_TEST_API_KEY=test_... cargo test -p vatly-fluent --test live_testmode -- --nocapture

vatly-mock is not published.

License

MIT

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages