Create a contact
Create a new contact. At least one of email or phone_number is required.
If a contact with the same email or phone number already exists, a 409 Conflict
error is returned along with the id of the existing contact. Use the Update a contact endpoint to modify existing contacts.
If a previously deleted contact matches the provided email or phone number, the contact is restored with the new data.
When sms_consent is subscribed, Privy automatically sends a TCPA-required
welcome SMS to the contact. Pass send_welcome_sms: false to suppress this
message if you have already collected consent outside of Privy.
Required scope: contacts_write
Documentation Index
Fetch the complete documentation index at: https://help.privy.com/llms.txt
Use this file to discover all available pages before exploring further.
Authorizations
Send either an API token or an OAuth access token as
Authorization: Bearer <token>. See the Authentication page for details.
Body
At least one of email or phone_number is required.
Use email_consent and sms_consent to set the contact's marketing
consent status at creation time.
Contact's email address.
"jane@example.com"
Contact's phone number in E.164 format.
"+15551234567"
Contact's first name.
"Jane"
Contact's last name.
"Doe"
Tags to apply to the contact.
["vip", "repeat-buyer"]Flat key-value pairs. Nested objects are not allowed.
{ "loyalty_tier": "gold" }Email marketing consent status. If not provided, defaults to never_subscribed.
compliance_suppressed is read-only and cannot be set on create.
subscribed, unsubscribed, never_subscribed, suppressed "subscribed"
SMS marketing consent status. pending is read-only and cannot be set.
subscribed and single_opt_in require a valid phone_number from a
supported country. Cannot be unsubscribed for new contacts (no existing
consent to revoke).
subscribed, unsubscribed, never_subscribed, single_opt_in "never_subscribed"
When sms_consent is set to subscribed and the contact transitions
to a confirmed SMS opt-in state, Privy sends a TCPA-required welcome
SMS. Set to false to suppress this message when you have already
collected consent outside of Privy.
false
Response
Contact created successfully.