> ## Documentation Index
> Fetch the complete documentation index at: https://docs.tented.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Connecting Clay

> Create a personalized page for every Clay row with two columns: Tented Start and Tented Result

Two HTTP API columns in your Clay table give every prospect a personalized landing page:

| Column            | What it does                                                                       |
| ----------------- | ---------------------------------------------------------------------------------- |
| **Tented Start**  | Sends the row to Tented. Tented starts building the page.                          |
| **Tented Result** | Three minutes later, fetches the page URL, your outreach sentences, and a summary. |

Your campaign reads the **Tented Result** column. No Clay API key is needed.

<img src="https://mintcdn.com/tented/oMZu9opT8sRMYidM/images/clay-two-column-table.png?fit=max&auto=format&n=oMZu9opT8sRMYidM&q=85&s=3afb0a7ac30346ab8002d0956e5a3d2a" alt="A Clay table with the Tented Start and Tented Result columns filled in." width="1272" height="92" data-path="images/clay-two-column-table.png" />

## Before you start

You need admin access to Tented, an approved [tent template](/working-with-tents/tent-templates), AI credits, and a Clay plan with **HTTP API** columns and **Delay Runs**. Each new page uses half a Tented AI credit. Your Clay table needs an email column; first name, last name, company name, job title, and website columns make the page more personal.

## 1. Connect Clay in Tented

1. Open **Settings → Integrations** and select **Connect** on the Clay tile.

<img src="https://mintcdn.com/tented/oMZu9opT8sRMYidM/images/clay-integrations-page.png?fit=max&auto=format&n=oMZu9opT8sRMYidM&q=85&s=9038e99e84de3fd61952ceba03252c2f" alt="The Clay tile with its Connect button." width="400" height="358" data-path="images/clay-integrations-page.png" />

2. In **Pages**, choose the approved template each page starts from.

<img src="https://mintcdn.com/tented/QCkYHCPzkkUhAHTD/images/clay-connect-pages.png?fit=max&auto=format&n=QCkYHCPzkkUhAHTD&q=85&s=2989ae47d274a549d3a4000157bf8f0d" alt="The Pages tab with a template selected." width="640" height="557" data-path="images/clay-connect-pages.png" />

3. Optionally, in **Messages**, edit the link sentence and follow-up sentence that Tented returns for your emails.

<img src="https://mintcdn.com/tented/snBBdL6bM6jkSrP1/images/clay-settings-messages.png?fit=max&auto=format&n=snBBdL6bM6jkSrP1&q=85&s=253d760af8d5de8f69a042fa0f13ed5b" alt="The Messages tab with both outreach sentences." width="640" height="654" data-path="images/clay-settings-messages.png" />

4. Select **Connect & get settings**. The **Clay connection** tab repeats the steps below with copy buttons for every value you need.

<img src="https://mintcdn.com/tented/MhbQXUKJtMVjdi3D/images/clay-settings-connection.png?fit=max&auto=format&n=MhbQXUKJtMVjdi3D&q=85&s=429b8078077e3a7ff2377bd219aa4b27" alt="The Clay connection tab with the four setup steps." width="640" height="672" data-path="images/clay-settings-connection.png" />

## 2. Save your connection in Clay

In Clay, open **Settings → Connections → Create → HTTP API (Headers)**. Name the account **Tented page generation** and add one header:

| Key                       | Value                                |
| ------------------------- | ------------------------------------ |
| `x-tented-webhook-secret` | The header secret copied from Tented |

You will select this account in both columns. Keep the secret private.

## 3. Add Tented Start

In your Clay table, select **Add column → Add enrichment**, search for **HTTP API**, and open the **Configure** tab. Name the column **Tented Start**.

<img src="https://mintcdn.com/tented/oMZu9opT8sRMYidM/images/clay-http-api-search.png?fit=max&auto=format&n=oMZu9opT8sRMYidM&q=85&s=ac528685d430f378c2a4f991809c7864" alt="Clay's enrichment search showing the HTTP API enrichment." width="494" height="500" data-path="images/clay-http-api-search.png" />

| Setting                   | Value                               |
| ------------------------- | ----------------------------------- |
| Account                   | **Tented page generation**          |
| Method                    | **POST**                            |
| Endpoint                  | The endpoint URL copied from Tented |
| Body                      | The JSON below                      |
| Response values to return | The six tags below                  |

```json theme={null}
{
  "email": "",
  "first_name": "",
  "last_name": "",
  "company_name": "",
  "job_title": "",
  "website": ""
}
```

Paste the body, then click between each pair of quotes, type `/`, and pick the matching Clay column. Email is required; the other fields personalize the page and can be left out.

<img src="https://mintcdn.com/tented/oMZu9opT8sRMYidM/images/clay-column-config-body.png?fit=max&auto=format&n=oMZu9opT8sRMYidM&q=85&s=8efe7014fad84d2232cd1ceca7dcb31a" alt="The body with a column chip inside each value." width="426" height="376" data-path="images/clay-column-config-body.png" />

Under **Response values to return**, type each of these names and press **Enter** after each one:

`status` `tented_url` `tented_page_offer` `tented_page_reference` `tented_page_summary` `status_url`

<img src="https://mintcdn.com/tented/oMZu9opT8sRMYidM/images/clay-start-response.png?fit=max&auto=format&n=oMZu9opT8sRMYidM&q=85&s=950657dd68d968aaee34ff93f8b359ed" alt="What Start returns for a new row: status generating, the reserved page URL, and your sentences." width="322" height="364" data-path="images/clay-start-response.png" />

Leave **Run settings** on Auto-run and Run immediately. Open the arrow next to **Save** and choose **Save and don't run**.

<img src="https://mintcdn.com/tented/oMZu9opT8sRMYidM/images/clay-save-menu.png?fit=max&auto=format&n=oMZu9opT8sRMYidM&q=85&s=9837dbbaf5c93eaf7b72687077b797a2" alt="The Save menu with Save and don't run." width="356" height="196" data-path="images/clay-save-menu.png" />

## 4. Add Tented Result

Add a second **HTTP API** column named **Tented Result**.

| Setting                   | Value                                                     |
| ------------------------- | --------------------------------------------------------- |
| Account                   | **Tented page generation**                                |
| Method                    | **GET**                                                   |
| Endpoint                  | Type `/`, open **Tented Start**, and pick **status\_url** |
| Response values to return | The same six tags as Start                                |
| Delay run                 | **Run after delay**, **180** seconds                      |

<img src="https://mintcdn.com/tented/oMZu9opT8sRMYidM/images/clay-result-config.png?fit=max&auto=format&n=oMZu9opT8sRMYidM&q=85&s=a44386d3e1d19cb6f6a065294b02ffad" alt="The Result column: method GET and the endpoint set to Tented Start's status_url." width="312" height="332" data-path="images/clay-result-config.png" />

<img src="https://mintcdn.com/tented/oMZu9opT8sRMYidM/images/clay-result-run-settings.png?fit=max&auto=format&n=oMZu9opT8sRMYidM&q=85&s=04aea2be590ac264bad750cb90ac9416" alt="The Result column's run settings: Auto-run on and a 180 second delay." width="312" height="230" data-path="images/clay-result-run-settings.png" />

Result waits for Start, then runs once after the delay. Choose **Save and don't run**.

## 5. Test it

1. Turn on table **Auto-run** from the button at the top left of the table, keeping existing results.

2. Add a test row. Fill in the name and company first and the email last. Start runs as soon as the email is in, and Result starts its three-minute countdown.

<img src="https://mintcdn.com/tented/oMZu9opT8sRMYidM/images/clay-result-delayed.png?fit=max&auto=format&n=oMZu9opT8sRMYidM&q=85&s=4fccf0c5f17865c1e0b87bdfb0928e16" alt="Start has finished and Result is counting down." width="1272" height="92" data-path="images/clay-result-delayed.png" />

3. After three minutes, open the **Tented Result** cell. `status` is `ready` and `tented_url` opens the finished page.

<img src="https://mintcdn.com/tented/oMZu9opT8sRMYidM/images/clay-result-response.png?fit=max&auto=format&n=oMZu9opT8sRMYidM&q=85&s=1c184f423c9cf7eb637eb1a829862cc6" alt="Result's response: status ready, the page URL, the sentences, and the summary." width="322" height="404" data-path="images/clay-result-response.png" />

New and changed rows now run on their own.

## Using the result in a campaign

Map the URL, the link sentence, the follow-up sentence, and the summary from **Tented Result**:

| Field                   | What it holds                             |
| ----------------------- | ----------------------------------------- |
| `tented_url`            | The page URL                              |
| `tented_page_offer`     | Your link sentence with the URL filled in |
| `tented_page_reference` | Your follow-up sentence                   |
| `tented_page_summary`   | A one-line summary of the page            |
| `status`                | `ready`, `generating`, or `failed`        |

Only send when the page is ready. In the campaign action's **Only run if** formula editor, paste:

```javascript theme={null}
{{Tented Result}}?.status === "ready"
```

## If a page is not ready

| Result status | What it means                                         | What to do                                                                                                   |
| ------------- | ----------------------------------------------------- | ------------------------------------------------------------------------------------------------------------ |
| `generating`  | The page was still building at the three-minute mark. | Run that Result cell again later. Check **View activity** on the Clay tile in Tented if it stays generating. |
| `failed`      | Tented could not build the page.                      | Check **View activity** for the reason, fix it, then run Start again for the row.                            |
| `unavailable` | The page was unpublished or deleted in Tented.        | Republish it, then run Result again.                                                                         |

Running Result never uses credits or rebuilds a page. Running Start again for a prospect who already has a page returns the existing page without charging for a new one.

## After connecting

The Clay tile shows the template, the last sync, and a **View activity** link.

<img src="https://mintcdn.com/tented/oMZu9opT8sRMYidM/images/clay-card-connected.png?fit=max&auto=format&n=oMZu9opT8sRMYidM&q=85&s=18eae7ab5332f9395f2727c37ef0ac82" alt="The Clay tile after connecting." width="400" height="358" data-path="images/clay-card-connected.png" />

**Activity** lists each run with the pages published and credits used.

<img src="https://mintcdn.com/tented/oMZu9opT8sRMYidM/images/clay-activity.png?fit=max&auto=format&n=oMZu9opT8sRMYidM&q=85&s=a43214efe0084fb064f7f884a3eafeb0" alt="The Clay activity dialog." width="722" height="234" data-path="images/clay-activity.png" />

Generated pages appear in your Tents list with **Clay Integration** as the creator. Use **Filter → Hide integration-created** to keep them out of the way.

<img src="https://mintcdn.com/tented/oMZu9opT8sRMYidM/images/clay-tents-list.png?fit=max&auto=format&n=oMZu9opT8sRMYidM&q=85&s=defd2ae4c54b4549700b5a84cdee5427" alt="The Tents list with Clay Integration as the creator." width="1246" height="178" data-path="images/clay-tents-list.png" />

Each page is built from your template and the row's fields:

<img src="https://mintcdn.com/tented/q03XjDhzBtbAm2hJ/images/clay-published-page.png?fit=max&auto=format&n=q03XjDhzBtbAm2hJ&q=85&s=2145bb68656bd4d2033abe8a694c2813" alt="A published page personalized for a Clay row." width="1568" height="732" data-path="images/clay-published-page.png" />

Page URLs are readable, for example `https://your-domain/for-bryan-from-acme-co`. Email identifies the prospect: the same email always gets the same page, even from another Clay table.

## Changing settings

Select **Edit settings** on the Clay tile. **Pages** changes the template for new pages, **Messages** changes the sentences returned on future rows, and **Clay connection** shows the setup steps, endpoint, and header secret again.

<img src="https://mintcdn.com/tented/QCkYHCPzkkUhAHTD/images/clay-settings-pages.png?fit=max&auto=format&n=QCkYHCPzkkUhAHTD&q=85&s=00fcad508245f258c1f0601528661afb" alt="The Edit settings Pages tab." width="640" height="581" data-path="images/clay-settings-pages.png" />

## Disconnecting

Select **Disable** on the Clay tile. Published pages stay live. To reconnect later, connect again in Tented, then update the Start column's endpoint and the saved account's header secret in Clay with the new values.

## Troubleshooting

| What you see                              | What to do                                                                                                                 |
| ----------------------------------------- | -------------------------------------------------------------------------------------------------------------------------- |
| Start: **The row needs an email address** | Put the cursor inside the quotes after `"email":`, type `/`, and pick the email column. Make sure the row has an email.    |
| Start or Result: **401**                  | Select the **Tented page generation** account in the column and check its header name and secret against Tented.           |
| Start: **410**                            | The connection was disabled in Tented. Connect again and update the endpoint and secret in Clay.                           |
| Start: **Body must be a JSON object**     | Paste the body from the setup tab again.                                                                                   |
| Response values show as one long text     | Clear the field, open its gear icon, choose **Text with tokens**, and enter the tags again.                                |
| Result never runs                         | Check that table Auto-run is on, the column's Auto-run is on, and the endpoint is the **Tented Start → status\_url** chip. |
