{"section":"tutorials","requestedLocale":"en","requestedSlug":"erasing-customer-data","locale":"en","slug":"erasing-customer-data","path":"docs/en/tutorials/security/store-security/erasing-customer-data.md","branch":"main","content":"Under data protection regulations such as the EU's General Data Protection Regulation (GDPR) and the Brazilian General Data Protection Law (LGPD) companies that store customer personal data must accept customer requests to delete their information. VTEX allows merchants to request the deletion of data directly through Copilot.\n\n## 1. Checking data stored in Master Data\n\nBefore [requesting customer data deletion via Copilot](#requesting-customer-data-deletion-via-copilot), follow these steps:\n\n1. **Identify where the data is stored:** Check the [Master Data](/en/docs/tutorials/master-data) entities that store customer data in your operation.\n2. **Delete custom entities manually:** If your store keeps customer data in custom entities, delete it manually before requesting data deletion via Copilot. For instructions, see the [Custom data entities](#custom-data-entities) section. Follow this process only for custom entities. Don't delete the Master Data [native entities](#master-data-native-entities) CL and AD.\n\n### Master Data native entities\n\nOnce you've submitted your [deletion request](#requesting-customer-data-deletion-via-copilot), VTEX will delete the data from the native data entities **CL** and **AD**. It's important you don't delete data from these entities on your side.\n\n### Custom data entities\n\nIf your store keeps customer data in custom data entities (CL and AD), you must manually delete this data before requesting customer data deletion via Copilot. You can manually delete customer data using the Master Data API:\n\n1. Search for the document using the [Search document](https://developers.vtex.com/vtex-rest-api/reference/searchdocuments-1) endpoint. \n2. Delete the document using the [Delete document](https://developers.vtex.com/vtex-rest-api/reference/deletedocument-1) endpoint.\n\n> ❗ Don't do this for the native entities **CL** and **AD**.\n\n## 2. Configuring the GDPR role\n\nTo request data deletion, create a [custom role](/en/tutorial/criar-perfil-de-acesso) named **General Data Protection Law** with the following resources from [License Manager](/en/docs/tutorials/license-manager-resources):\n\n- **Write user rights requests** (from the **User Rights** product)\n- **Open Support Ticket** (from the **VTEX Support** product)\n\n![perfil-de-acesso-gdpr](https://cdn.statically.io/gh/vtexdocs/help-center-content/refs/heads/main/docs/en/tutorials/security/store-security/erasing-customer-data_1.jpg)\n\nNext, assign this role to the user who will request customer data deletion.\n\n## 3. Requesting customer data deletion via Copilot\n\nAfter checking the data and configuring the role, follow these steps to submit the request via Copilot:\n\n1. Log in to the VTEX Admin with a user that has the **General Data Protection Law** role, configured in [2. Configuring the GDPR role](#2-configuring-the-gdpr-role).\n2. Go to **Copilot > Chat** in the VTEX Admin.\n3. Send the message: `I want to delete a user from the VTEX platform.`\n    ![copilot-excluir-cliente-en](https://cdn.statically.io/gh/vtexdocs/help-center-content/refs/heads/main/docs/en/tutorials/security/store-security/erasing-customer-data_2.gif)\n4. When requested, provide the email of the user you want to delete. You can delete data for only one shopper per request. Submit the email address of a single shopper at a time.\n\nAfter this step, the request will be forwarded to VTEX Support, and you'll receive the support ticket ID to follow up.\n\nOnce your ticket is closed, VTEX will send a deletion certificate to the email used to open the ticket, confirming that the data has been deleted."}