NestJS demo
Build a NestJS contribution service with a Svelte checkout. The server resolves the price and creates one order for all three payment modes.
What you’ll build
- NestJS controllers, dependency injection, and DTO validation
- Typed Product lookup and Order creation with the Inttegro TypeScript SDK
- A stable idempotency key and readable order number
- A Svelte 5 payment island using
@inttegro/svelte - Server-owned contribution tiers and safe errors
See the flow
The gallery shows one server-created order in each Checkout presentation. The browser cannot choose the price or use the API key.
- Desktop
- Mobile
Select any image to view it full screen.
Run the demo
Add your API key, Product ID, Price ID, and public origin. The released README has the local, Docker, build, and test commands.
Key files
src/checkout.service.tsvalidates the tier and creates the order.src/campaign.controller.tshandles validation, safe errors, and the response.client/CheckoutFlow.sveltemanages embedded and modal Checkout.client/main.tsmounts Svelte in the server-rendered page.
Before you ship
Store the contribution, idempotency key, and Inttegro order ID. Update totals and send receipts only after server-side payment verification.