# Set up Twilio Integration

## Fetching Your Twilio API Credentials

Your Twilio API credentials allow CrossEngage to connect to your Twilio account. Once connected, you will be able to send Twilio messages from your CrossEngage account.

* [Log in](https://www.twilio.com/login) to your Twilio account.
* In the top right corner of the screen, open the Account menu and choose General Settings.
* From the Menu on the left, choose API Keys & Tokens.
* Your Account SID and Primary Token (which you can make visible by clicking on the eye icon) can be found here. Leave the tab open as you will need to copy and paste these credentials for your CrossEngage integration in a later step.

<figure><img src="/files/7t3pi525E2OT4uaGTUsY" alt=""><figcaption></figcaption></figure>

## Configuring a Twilio Integration in CrossEngage

* In the CrossEngage app, navigate to `Settings` > `Integrations`.
* Click the `Add new integration` button in the top right corner of the page.

<figure><img src="/files/zfWLFaM1kVBGbSAJoguR" alt=""><figcaption></figcaption></figure>

* Search for Twilio, then click `Set Up`.

<figure><img src="/files/qffqLebQXvLjN8cCvTrH" alt=""><figcaption></figcaption></figure>

## The "SMS via Twilio" form <a href="#the-sms-via-twilio-form" id="the-sms-via-twilio-form"></a>

* Give the integration a descriptive name.
* Copy your Account SID from the Twilio tab you have open and paste it into the Account SID field.
* Copy your Primary Token from the Twilio tab you have open and paste it into the API key field.
* Click `Connect`.

<figure><img src="/files/zlJhhXUDCvpTsizf89Hx" alt=""><figcaption></figcaption></figure>

* Choose the user attribute that contains your recipient's phone number.

{% hint style="info" %}
The traits.phone user attribute is a string type attribute created by default in CrossEngage. That means that if you haven not made your own custom user attribute with the same function, the default attribute "traits.phone" will be the user attribute that contains your recipient's phone number.‌
{% endhint %}

* When ready, click `Apply` to save the integration.

<figure><img src="/files/zlJhhXUDCvpTsizf89Hx" alt=""><figcaption></figcaption></figure>


---

# 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://documentation.crossengage.io/data-and-engagement-platform/messages/integrations/channels/sms/twilio/set-up-twilio-integration.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.
