# SendGrid

## Setting up a SendGrid instance

If you don't already have a SendGrid account, you'll need to set one up before integrating. Follow the steps below:

1. Sign up for a membership depending on your use case and using the pricing model found [here](https://sendgrid.com/pricing/).
2. Next you will need to login to SendGrid and create a sender identity. SendGrid should automatically prompt you to do so or you can navigate to the link [here](https://app.sendgrid.com/guide). SendGrid will provide you with two sender identity options:
   * **Authenticate a domain -** Allows you to authenticate a domain and send from any address on that domain. This is the industry standard but requires access to the DNS settings of your domain.
   * **Single Sender** - Allows you to set up one email to send emails from. Only recommended for testing as email service providers will append "via sendgrid.net" to the sender.&#x20;
   * Read more about these two options [here](https://docs.sendgrid.com/for-developers/sending-email/sender-identity).
3. Connect your SendGrid account to Absolute Labs using the API Key. Navigate to Settings --> API Keys and click **Create API Key**. Required permissions level - Restricted Access (See the necessary permission list below). \
   Once you have created the key copy it to clipboard.<br>

   <figure><img src="/files/3oy60UMMl9txRiSwF49K" alt=""><figcaption></figcaption></figure>

   <figure><img src="/files/883CBl3yGIPafC3AlUqD" alt=""><figcaption></figcaption></figure>
4. Navigate back to your Absolute Labs account and in the top right corner click your account name then Settings. In settings you will see an Email sections with two text boxes:

* **SendGrid API Key -** This is where you paste the API key from the SendGrid account
* **Sender Email -** This is the email that will be used as the sender. Make sure that the email provided here is allowed given the sender identity setup in step 2.

5. At this point, you are ready to start building email templates in SendGrid. \
   Absolute Labs supports **Dynamic Templates -** Learn about creating and editing a dynamic template [here](https://docs.sendgrid.com/ui/sending-email/how-to-send-an-email-with-dynamic-templates).
6. Whenever you create a template, it will be automatically synced over to Absolute Labs and available on the Email block.


---

# Agent Instructions: 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 current page URL with the `ask` query parameter:

```
GET https://docs.absolutelabs.io/use-cases/sendgrid.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
