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

# Smallest AI Integration

> Connect a Smallest AI (Atoms) agent to Cekura to run phone-based simulations, import its configuration, and pull the Smallest AI transcript into every result.

## Overview

Cekura tests agents built on [Smallest AI Atoms](https://docs.smallest.ai) over the phone. Cekura dials the number attached to your agent, runs the scenario as a simulated caller, and then uses the Smallest AI API to find that call and fetch its transcript. The result shows the conversation as Smallest AI recorded it.

> [!NOTE]
>
> Smallest AI connects over **telephony only**. Cekura always places the call to your agent's number; the telephony connection is enabled automatically once the Smallest AI credentials are saved.

## Prerequisites

* A **Smallest AI API key** from the Atoms dashboard.
* A Smallest AI **agent** and its agent id.
* A **phone number** attached to that agent, with **inbound calls allowed** on the agent.

## Connect Smallest AI in Cekura

**1. Select Smallest AI**

In Cekura, go to **Agents**, create an agent, and select **Smallest AI** as the provider. If you don't see it, click **More options** to expand the full provider list.

**2. Enter the Smallest AI credentials**

Fill in the fields under **Integration Settings**:

| Field | Value |
| - | - |
| **Smallest AI Agent ID** | The id of your Smallest AI agent. Cekura uses it to find the calls that agent took. |
| **Smallest AI API Key** | Your Smallest AI API key. Stored encrypted and never shown again. |

**3. Add the phone number**

Under **Telephony Settings**, enter the phone number attached to your Smallest AI agent. Telephony is the only connection type for Smallest AI and is enabled automatically. Leave **Inbound** on so Cekura dials your number.

**4. Save the agent**

Save the agent. The key field shows **API Key Configured** once it is stored; use **Update** to rotate it later.

## Configure automatically

Select **Smallest AI** in the **Import directly from provider** panel, enter the agent id and API key, and click **Configure Agent**. Cekura imports the agent name, prompt, first message, language, phone number, and default variables from the agent's live configuration. Turn on **Auto-sync prompt** to keep the prompt in Cekura up to date with Smallest AI.

## Run a test

Open an evaluator, click **Run**, and start the run using the **Telephony** connection. Cekura dials your Smallest AI number and plays the scenario as the caller.

When the call ends, Cekura:

1. Lists the recent inbound calls on your Smallest AI agent and keeps the ones placed from the Cekura number and started within a few seconds of the test call.
2. Waits for Smallest AI to finish the call record.
3. Confirms the match by comparing the call duration and the conversation content, so parallel test calls to the same agent are each paired with the right Smallest AI call.
4. Replaces its own transcript with the Smallest AI one and attaches the Smallest AI call id to the result.

In the result, agent turns are labeled **Main Agent** and caller turns are labeled **Testing Agent**.

> [!NOTE]
>
> If Cekura cannot find a matching call, the result keeps Cekura's own transcript of the call. See the troubleshooting section below.

## Mock tools

Your agent's API call tools can be replaced with Cekura mock endpoints for a test, so the agent gets predictable answers and never touches your real systems.

**1. Fetch the agent's tools**

Open the agent's **Mock Tools** section and fetch the tools from Smallest AI. Cekura reads the API call tools on your agent's live configuration and creates a mock for each, with example inputs and outputs you can edit.

**2. Run with mocks**

In **Configure Run**, select the mock tools to use. For the duration of the run, Cekura points the matching tools on your agent at the mocks and publishes the change; when the run finishes, the original tools are published back.

Learn more in [Mock Tools](https://docs.cekura.ai/documentation/key-concepts/evaluators/mock-tools.md).

## Troubleshooting

* **Authentication fails**: check that the API key is active in the Smallest AI dashboard and belongs to the organization that owns the agent.
* **Agent did not answer**: make sure the phone number is attached to the agent and that the agent allows inbound calls. A number that does not reach the agent when dialed by hand will not work in a test either.
* **No Smallest AI transcript on the result**: confirm the **Smallest AI Agent ID** is the agent attached to the number under **Telephony Settings**. Cekura only considers calls answered by that agent.
* **Call not matched**: Cekura matches on the phone number it dialed from and the call's start time. Make sure the run used the **Telephony** connection.

## Configure through the API

When creating or updating an agent through the [API](https://docs.cekura.ai/api-reference/test_framework/create-agent.md), set the provider to `smallest` and pass the credentials:

```json theme={null}
{
  "transcript_provider": "smallest",
  "assistant_id": "6ad8b01751813d1c18618ff4",
  "smallest_api_key": "<api-key>",
  "contact_number": "+15551234567",
  "inbound": true
}
```

`assistant_id` is the Smallest AI agent id and is required whenever a key is set. The response never returns the key. Use the read-only `smallest_api_key_configured` field to check whether one is stored.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.