payit/internal/stripe/types.go
Ruidy 7e1e6e1df9
feat(stripe): add Stripe Checkout session API and tests
- Integrate Stripe Go SDK and implement a checkout service for creating
  Stripe Checkout sessions for a demo product.
- Add request/response types for checkout sessions.
- Create HTTP handler for /api/checkout to initiate sessions via POST.
- Provide comprehensive unit tests for Stripe client and web handler.
- Wire Stripe-backed endpoint in server setup.
2025-09-27 11:32:34 +02:00

12 lines
345 B
Go

package stripe
// CheckoutSessionRequest captures optional inputs for creating a checkout session.
type CheckoutSessionRequest struct {
Quantity int64 `json:"quantity"`
}
// CheckoutSessionResult contains the data returned to callers initiating checkout.
type CheckoutSessionResult struct {
ID string `json:"id"`
URL string `json:"url"`
}