Upsert user
Look up an Uptop user by `email` and create it if it doesn't exist. A wallet is provisioned automatically on creation. Cache the returned `id` — it's the only key the rest of the API takes.
/v1/users:upsertRequest body
| Field | Type | Required | Description |
|---|---|---|---|
| string (email) | required | Primary identifier. Upsert is idempotent on this. Also required for virtual card issuance. | |
| phoneNumber | string (E.164) | — | User's phone number in E.164 format, e.g. `+12025551234`. **Required for virtual card issuance.** Kept in sync — re-upsert with a new value to update it. |
| externalUserId | string | — | Your partner-side identifier for this user. Optional. When supplied it's linked to the matched/created record so subsequent partner lookups by it work too. |
| firstName | string | — | User's first name. **Required for virtual card issuance** — used as the cardholder billing name on the virtual card. Kept in sync on every upsert. |
| lastName | string | — | User's last name. **Required for virtual card issuance** — used as the cardholder billing name on the virtual card. Kept in sync on every upsert. |
{
"email": "fan@example.com",
"phoneNumber": "+12025551234",
"externalUserId": "partner-user-001",
"firstName": "Taylor",
"lastName": "Fan"
}Response — 200
Click the type for the full field-by-field shape.
{
"id": "65f3a91d6f3a4b0012ab34cd",
"email": "fan@example.com",
"phoneNumber": "+12025551234",
"externalUserId": "partner-user-001",
"firstName": "Taylor",
"lastName": "Fan",
"createdAt": "2026-05-22T15:00:00.000Z"
}Errors
- UNAUTHORIZED401— Missing or invalid `Api-Key`.
- VALIDATION_ERROR400— `email` missing or malformed, or `phoneNumber` supplied but not valid E.164.
Notes
- **All four fields are required to issue a virtual card: `email`, `phoneNumber`, `firstName`, and `lastName`.** These are used as the cardholder identity on the card record. A user missing any of them cannot be issued a virtual card — pass all four on first upsert.
- **No formal KYC is performed.** These fields are used for card issuance purposes only. Uptop does not run identity verification or background checks on this information. Wallets are capped at $1,000, which falls below the threshold that would require KYC.
Try it (curl)
$UPTOP_API_KEY in the curl will be substituted for it on send.Edit anything above, then send through the local proxy.