Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions docs/content/docs/(guides)/apps/emails.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,8 @@ Stack Auth provides several built-in email templates for common authentication f
- **Magic Link**: `magic_link` - Sent for passwordless authentication
- **Team Invitation**: `team_invitation` - Sent when users are invited to teams
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Citation: New payment_receipt and payment_failed template IDs added in packages/stack-shared/src/helpers/emails.ts. Template definitions show they're used for transactional payment notifications.
View source

- **Sign-in Invitation**: `sign_in_invitation` - Sent to invite users to sign up
- **Payment Receipt**: `payment_receipt` - Sent when a payment succeeds (one-time or subscription)
- **Payment Failed**: `payment_failed` - Sent when a payment fails (one-time or subscription)

These templates can be customized through the admin interface or programmatically.

Expand Down
9 changes: 9 additions & 0 deletions docs/content/docs/(guides)/apps/payments.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -155,6 +155,15 @@ Click the refund button in a transaction row to issue a refund. Refunds are only

For USD transactions, you can issue full or partial refunds—just specify an amount greater than zero and up to the original charge. Non-USD transactions only support full refunds.

### Payment Emails
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Citation: Email sending logic in apps/backend/src/app/api/latest/integrations/stripe/webhooks/route.tsx shows templates are sent for both one-time purchases (payment_intent.succeeded/failed) and subscriptions (invoice.payment_succeeded/failed).
View source


Email notifications are sent automatically when payments are processed:

- **Payment Receipt**: Sent on successful payment with product details, amount, and receipt link
- **Payment Failed**: Sent on failed payment with product name, amount, and failure reason

These emails apply to both one-time purchases and subscription renewals. Customize them in the dashboard under **Emails → Templates**.

## Customer Types

Stack Auth supports three types of payment customers:
Expand Down
Loading