# 2. Add Donor
source: https://developer.mastercard.com/donations/documentation/use-cases/enroll-donor/add_donor/index.md

## Overview {#overview}

The **Create (Register) Donor** endpoint creates a new donor from your cardholders having associated cards-on-file.

They must accept your **Terms and Conditions** and **Privacy Policy** before they can enroll. They can also choose to receive cause-related marketing campaigns. To enroll a donor, you must submit the cardholder's **email address** and their **accepted consents** . The endpoint then adds a donor with the email ID and generates a unique `donorId`.

A successful request returns the `HTTP 200 OK` status and a JSON response body with the `donorId` and the **email address** sent in the request. Mastercard Donate adds the donor only once and returns the `donorId` in subsequent requests.

### Terms and Conditions {#terms-and-conditions}

Your legal consents must ensure that your **Terms and Conditions** and your **Privacy Policy** conform to all applicable laws. Also track any changes to your legal agreements and record the version with the date and time of their consent.

If your service enrolls cardholders:

* In the European Union (EU), ensure that your legal agreements comply with [General Data Protection Regulation (GDPR)](https://en.wikipedia.org/wiki/General_Data_Protection_Regulation) requirements.

* In California, ensure that the cardholder consents to the Terms and Conditions and Privacy Policy that comply with the [California Consumer Privacy Act (CCPA)](https://en.wikipedia.org/wiki/California_Consumer_Privacy_Act).

## Sequence Diagram {#sequence-diagram}

The following outlines the sequence of events:
Diagram add-donor

## Execution Steps {#execution-steps}

The following details the steps in the above sequence diagram:

1. The cardholder chooses to register as a donor.
2. The partner user interface displays the registration screen to the cardholder.
3. The cardholder enters the personal information like the *name, identification, locale, email ID* , and *acceptedConsents* in the form displayed by the partner user interface.
4. The partner user interface forwards the data to the partner server.
5. The partner server invokes the `POST /donations/donors` endpoint and provides the cardholder data in the endpoint request.
6. The Mastercard Donate Service checks if a donor already exists in the system.  
7. The Mastercard Donate Service processes the data, stores it, and generates a unique `donorId`, if an associated donor does not exist.  
8. The Mastercard Donate Service returns the `donorId` to the partner server.  
9. The partner server stores the data and the `donorId`.  
10. The partner server sends the registration details to the partner user interface.  
11. The partner server also sends a confirmation to the cardholder that the registration was successful.  
12. The Mastercard Donate Service sends the error message 'Username already exists' to the partner server, if it finds an existing donor.  
13. The partner server forwards the error message 'Username already exists' to the partner user interface.  
14. The partner user interface displays the error message to the donor.

## Endpoints {#endpoints}


API Reference: `POST /donors`

## Endpoint Parameters {#endpoint-parameters}

For more details on the endpoint parameters, refer to the [Parameters to Create a Donor](https://developer.mastercard.com/donations/documentation/parameters/enroll-manage-donor-param/enroll-donors-param/index.md) section.

## Sample Request and Response {#sample-request-and-response}

For more details, refer to the [Create donor](https://developer.mastercard.com/donations/tutorial/donation-api-details/donorsapi/index.md#post-donors) tutorial.
