Tell Stack who is paying
If your customer is already signed in to your app, you know their email. Pass it when you create the payment, and the Stack sheet skips the “Enter your email” step: it sends the code as it opens and starts at “Enter your code”.
const intent = await stack.paymentIntents.create({ amount: 250_000, currency: 'NGN', customer: { email: user.email },});- It’s a hint, not a sign-in. The customer still has to enter the code from their inbox, so knowing an email doesn’t let anyone pay as that person.
- The customer can change it. “Use a different email” is always there, with your address filled in.
- A different account already signed in in your app gets a “Not you?” prompt, so a shared phone or browser doesn’t pay from the wrong account.
- Receipts. Card and bank receipts go to this email when the customer’s Stack account doesn’t have one.
- Server only. Set it when your server creates the payment. It can’t be set from an app.
Sign-in is by email only for now, so only email is used. A customer.phone is accepted
and stored, but the sheet ignores it until phone sign-in arrives.