When someone purchases from you, you should apply a tag called, Performance of Contract in order to help be compliance with GDPR law. Performance of a contract means that the contact purchased a good or service from you and you feel that you have Lawfulness of Processing. You can do this quickly by simply adding a purchase action to tag automatically on successful purchase.
Go to E-Commerce > Settings
Click on Purchase Actions
Click Actions next to Successful Purchase Actions
Add an action to Apply tag
Add the Performance of contract tag and save