> For the complete documentation index, see [llms.txt](https://docs.growsurf.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.growsurf.com/integrations/sendgrid.md).

# SendGrid

Update/add SendGrid contacts with their unique share link and referrer information.

## Sync with your SendGrid List <a href="#sync-with-your-mailerlite-group" id="sync-with-your-mailerlite-group"></a>

**Step 1:** Log in to SendGrid and [create a new SendGrid API key](https://sendgrid.com/docs/ui/account-and-settings/api-keys/#creating-an-api-key). Make sure the API key has *Full Access* to *Marketing:*

<figure><img src="https://2794996218-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LeklWo0yn03AhWro2Ux%2Fuploads%2FF6E029Aqw2SwpcLjKXth%2Fimage.png?alt=media&amp;token=e61756f4-fc78-4b6f-bba1-dd0a5a02e37b" alt=""><figcaption></figcaption></figure>

**Step 2:** In GrowSurf *Program Editor > 4. Options > Integrations*, open the SendGrid integration card and enter your SendGrid API key.

{% hint style="info" %}
Connect SendGrid before importing participants. If participants are already in your program, follow [these ESP sync options](https://support.growsurf.com/article/385-how-can-i-sync-my-growsurf-participants-to-my-esp) to send their GrowSurf data to SendGrid.
{% endhint %}

![](https://2794996218-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LeklWo0yn03AhWro2Ux%2F-MSylFLKJQ6Zo5HhZwYI%2F-MSzLYu1ttwnTO4O_rL6%2FScreen%20Shot%202021-02-07%20at%2010.29.01%20PM.png?alt=media\&token=c9dd7594-0408-4d22-b6dd-e844bccf7481)

{% hint style="danger" %}
**Getting an error while connecting your API key?**\
As of August 8, 2025, SendGrid requires separate purchases for their *Marketing Campaigns* and *Email API* products. Please make sure that you have paid access to their *Marketing Campaigns* product. Note that if you have purchased both products, you can use the same account (and API key) to send via the *Email API* or through *Marketing Campaigns.*
{% endhint %}

**Step 3:** Once connected, choose the SendGrid list that you want to automatically sync to. GrowSurf will add/update your SendGrid contacts every time a new participant is added or referred to your referral or affiliate program.

**Step 4:** Save changes. You should now see a screen that looks like the one below:

![](https://2794996218-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LeklWo0yn03AhWro2Ux%2F-MSzQtfI-9zkK17asR_4%2F-MSzRKzivWABpzMDOP1q%2FScreen%20Shot%202021-02-07%20at%2011.20.23%20PM.png?alt=media\&token=fcecb16c-1ef1-4b9f-9216-86c476cfa86b)

## Examples

[View our SendGrid tutorials](https://docs.growsurf.com/additional-integrations/sendgrid/tutorials) to see different kinds of examples that you can copy/paste into your email templates.

## **Custom Fields** <a href="#subscriber-fields" id="subscriber-fields"></a>

GrowSurf will automatically create these new custom fields for your SendGrid contacts.

| **Custom fields**                        | **FIELD NAME**                         | **FIELD TYPE** | **Description**                                                                                                                                                                                           | **Example**                                                |
| ---------------------------------------- | -------------------------------------- | -------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------- |
| **GrowSurf Share URL**                   | `growsurf_share_url`                   | text           | The participant's unique referral link                                                                                                                                                                    | <https://growsurf.com?grsf=absc123>                        |
| **GrowSurf Participant ID**              | `growsurf_participant_id`              | text           | The participant's unique GrowSurf ID                                                                                                                                                                      | abc123                                                     |
| **GrowSurf Referral Status**             | `growsurf_referral_status`             | text           | The referral status of the participant\*                                                                                                                                                                  |                                                            |
| **GrowSurf Participant First Name**      | `growsurf_participant_first_name`      | text           | The participant's first name                                                                                                                                                                              | Bob                                                        |
| **GrowSurf Participant Last Name**       | `growsurf_participant_last_name`       | text           | The participant's last name                                                                                                                                                                               | Loblaw                                                     |
| **GrowSurf Referrer First Name**         | `growsurf_referrer_first_name`         | text           | The first name of the participant's referrer (if applicable)                                                                                                                                              | Gavin                                                      |
| **GrowSurf Referrer Last Name**          | `growsurf_referrer_last_name`          | text           | The last name of the participant's referrer (if applicable)                                                                                                                                               | Belson                                                     |
| **GrowSurf Referrer Email**              | `growsurf_referrer_first_email`        | text           | The email address of the participant's referrer (if applicable)                                                                                                                                           | <gavin.belson@hoolie.io>                                   |
| **GrowSurf Total Referral Count**        | `growsurf_total_referral_count`        | number         | The participant's all-time referral count                                                                                                                                                                 | 0                                                          |
| **GrowSurf Lead Count**                  | `growsurf_lead_count`                  | number         | The participant's current lead count (pending referrals that have not converted yet)                                                                                                                      | 0                                                          |
| **GrowSurf Monthly Referral Count**      | `growsurf_monthly_referral_count`      | number         | The participant's current month referral count                                                                                                                                                            | 19                                                         |
| **GrowSurf Prev Monthly Referral Count** | `growsurf_prev_monthly_referral_count` | number         | The participant's previous month referral count                                                                                                                                                           | 20                                                         |
| **GrowSurf Next Milestone**              | `growsurf_next_milestone`              | text           | The text for the next/upcoming milestone reward (only applies to milestone rewards. [See an example here](https://docs.growsurf.com/developer-tools/embeddable-elements#embedded-next-milestone))         | You are only 2 referrals away from winning a free t-shirt! |
| **GrowSurf Next Monthly Milestone**      | `growsurf_next_monthly_milestone`      | text           | The text for the next/upcoming monthly milestone reward (only applies to milestone rewards. [See an example here](https://docs.growsurf.com/developer-tools/embeddable-elements#embedded-next-milestone)) | You are only 2 referrals away from winning a free t-shirt! |
| **GrowSurf Total Invite Count**          | `growsurf_total_invite_count`          | number         | The participant's all-time invite count                                                                                                                                                                   | 112                                                        |
| **GrowSurf Total Impression Count**      | `growsurf_total_impression_count`      | number         | The participant's all-time impression count                                                                                                                                                               | 150                                                        |

\**GrowSurf Referral Status* can have one of these values:

* `CREDIT_PENDING`: The participant must trigger a referral before their referrer receives credit.
* `CREDIT_AWARDED`: The participant triggered a referral, and their referrer received credit.
* `CREDIT_EXPIRED`: The participant did not trigger a referral before the referral credit expired.

You can use these new properties in your SendGrid email templates. For example, use `growsurf_share_url` to add each participant's unique referral link.

[​Click here to learn more about how to create custom fields in SendGrid.​](https://sendgrid.com/docs/ui/managing-contacts/custom-fields/#creating-custom-fields)

## **Troubleshooting Tips** <a href="#troubleshooting-tips" id="troubleshooting-tips"></a>

* Check the participant's activity logs if they do not sync. GrowSurf retries failed syncs for up to 7 days.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.growsurf.com/integrations/sendgrid.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `build a script that syncs our docs to a CMS` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
