Create client profile
Creates new client profile.
You can send custom fields in the request body and they will be saved as part of your document. Therefore, the schema and examples presented below may differ from yours. Your integration must be adapted accordingly.
The id field returned by this request is the profileId used to retrieve information on a specific profile later.
Learn more about the Profile System and its other API endpoints.
⚠️ The Profile System is only compatible with stores using the PII data architecture from Data Protection Plus, which is in closed beta phase, only available in select regions.
This feature is part of VTEX Shield. If you are already a VTEX customer and want to adopt VTEX Shield for your business, please contact Commercial Support. Additional fees may apply. If you are not yet a customer but are interested in this solution, please complete our contact form.
Permissions
Any user or API key must have at least one of the appropriate License Manager resources to be able to successfully run this request. Otherwise they will receive a status code 403 error. These are the applicable resources for this endpoint:
| Product | Category | Resource |
|---|---|---|
| Profile System | Documents | Get Item |
| Profile System | Documents | Save and Update Item |
| Profile System | Documents | Delete Item |
There are no applicable predefined roles for this resource list. You must create a custom role and add at least one of the resources above in order to use this endpoint.To learn more about machine authentication at VTEX, see Authentication overview.
❗ To prevent integrations from having excessive permissions, consider the best practices for managing API keys when assigning License Manager roles to integrations.
Query parameters
This parameter sets the the Time To Live (TTL), in days, of the specific document being created or updated with this request. After this period of time from the moment of the request, the document is deleted. By sending this parameter you override the TTL set for the schema.
Currently, the available default document schemas have no TTL. This means that documents are stored indefinitely, unless a TTL is sent when creating or updating.
Headers
Type of the content being sent.
HTTP Client Negotiation Accept Header. Indicates the types of responses the client can understand.
Request body
Example request
{
"firstName": "John",
"lastName": "Doe",
"email": "john.doe@example.com",
"birthDate": "1925-11-17",
"document": "12345678900",
"documentType": "CPF",
"{customField}": "{value}"
}Response
Created
Example response
{
"document": {
"firstName": "John",
"lastName": "Doe",
"email": "john.doe@example.com",
"birthDate": "1925-11-17",
"document": "12345678900",
"documentType": "CPF",
"{customField}": "{value}"
}
}