saved_cards.use, so they can’t run this flow.
How it works
1
Invite the user by phone
Create an invitation for the user’s phone number that asks only for card access.
2
Send them the link with ?signup=card
The user enters a code, their name, and their card. Your agent is connected as soon as the card
is saved.
3
Open a card session for each purchase
Send the user the approval link with
?signin=phone. They enter a code, check the purchase, and
approve it with the card’s security code.4
Claim and check out
Claim the session and pay through the proxy.
1. Invite the user by phone
CallPOST /customers/invitations with a phone
recipient. Ask for these permissions and nothing else:
party.read is also allowed. Any other permission, or {"type":"ALL"}, needs a full account:
the user can’t accept it with a phone code.
- One agent per invitation. Each agent gets its own invitation (
adi_*), and the link connects only that one. redirectUrlis optional. It sends the user back to you after they save the card: anhttpsURL, an app deep link, or ansms:link back to a chat.- Expiry. Invitations last 30 days unless you set
expiresAt(up to 90). The user must sign up before then.
2. Send the user the link
Natural doesn’t send phone invitations. Add?signup=card to the invitation’s url and send it
yourself, wherever you talk to the user: a text, a chat, your app.
?signup=card, the link starts a normal signup with email and an identity check.
What the user sees
- Sign up. “Create an account with the phone number ending in 0123” and Continue with phone. There’s no email or Google option. They never type the number: we text the code to the number you invited.
- Enter the code.
- Approve your agent. They see your app and what it’s asking for.
- Enter their name.
- Add their card. The page reads “Add a card for Acme”, with your app’s name. They enter the card number, expiry and security code, and tap Save card. Natural stores the card number encrypted and never stores the security code.
- Done. “Your card is saved”. If you set
redirectUrl, they go there next.
Know when they’re done
The connection is live once the card is saved. You get theagent_delegation_invitation.accepted and delegation.activated webhooks, and the user appears
in GET /customers. Their id (pty_*) is the
customerPartyId you pass from now on.
3. Open a card session for each purchase
Find the card withGET /card-external-accounts?customerPartyId=pty_…, then open a session with
POST /card-sessions. Call it with your
agent’s key and an X-Instance-ID header.
cURL
approvalUrl. Add ?signin=phone and send it to the user:
What the user sees
- Sign in, if they’re signed out. We text them a code. They enter it and stay on the approval page.
- Check the purchase. “Your agent is asking to pay”, with the amount, merchant, card and the hosts that receive the card.
- Approve. They enter the card’s security code and tap Approve, or tap Decline.
4. Claim and check out
PollGET /card-sessions/{sessionId} until
status is approved. Then
claim it and check out through the proxy. See
Browser tokens for the claim and proxy setup.
What a phone-only user can do
Signing in with a phone code gives a limited session. The user can manage their saved cards, approve card purchases, and accept or remove card-only agent connections. Anything else, such as moving money or changing account details, asks them to sign in with email or Google, which a phone-only user doesn’t have yet. Phone-only users can’t use agent tokens.requestAgentToken has
no effect for them: pay through the proxy.
Limits
- Production only for now. Sandbox doesn’t accept phone recipients, so you can’t run the phone
signup there. Test the card session steps in Sandbox with
POST /simulations/invite-customer. - No VoIP numbers. Invite the number in E.164 format, such as
+14155550123. Natural blocks VoIP numbers, such as Google Voice, at signup. Creating the invitation doesn’t check this. - Card only. A phone-only user can’t accept an invitation that asks for more than card access. If your agent later needs to move money, the user needs a full account.