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

# Build with an AI coding agent

> Paste one prompt into Claude Code, Cursor or Codex and it connects your voice agent platform to phone calls over SIP trunking, using the Plivo CLI and the Plivo SIP trunking skill.

Let your AI coding agent set up Session Initiation Protocol (SIP) trunking, which connects phone calls between Plivo and your voice-agent platform. Paste the prompt below into Claude Code, Cursor or Codex. The agent installs the Plivo CLI and its skills, then follows the SIP trunking skill step by step. It works with LiveKit, ElevenLabs, Retell, Vapi, xAI and self-hosted SIP platforms.

## Start

Paste this into your coding agent:

```text Prompt theme={null}
Install the Plivo CLI: curl -fsSL https://raw.githubusercontent.com/plivo/plivo-cli/main/install.sh | bash. Then run plivo skill install all and follow the plivo-sip-trunking skill to connect my voice agent platform to a phone number over SIP trunking.
```

You complete the browser sign-in. The skill asks you before anything that spends money or changes your account.

> [!NOTE]
>
> Already have the CLI? Run `plivo skill install cli` and `plivo skill install sip-trunking`. For Codex, add `--agent codex` to each command so the files go into its skills folder.

## What the agent does

1. **Checks readiness before writing code.** The number is rented and voice-enabled, India know your customer (KYC) compliance is accepted where required, it is attached to an inbound trunk, the trunk is enabled, and the origination URI's host, port and transport match what your platform documents. It checks that the platform's SIP host answers with `plivo sip test --uri`. Read-only: nothing on your account changes.
2. **Plans the connection.** For LiveKit, ElevenLabs, Retell and Vapi, it uses `plivo sip connect plan` and `--platform` presets. xAI and self-hosted platforms need explicit SIP values; they are not presets in v1.3.2. It also identifies the steps you must complete in the platform dashboard.
3. **Sets up both directions,** inbound so calls reach your agent and outbound so your agent can dial, using credentials or an IP list depending on the platform.
4. **Debugs from evidence.** It reads the Plivo call record and the platform's SIP response together, to distinguish Plivo's result from the platform's result before suggesting a change. The platform's final response comes from console SIP logs or platform logs, not the CLI's call-quality API. It uses `plivo sip calls insights` for call quality and `plivo sip calls diagnose` for a plain-English explanation. For example, ElevenLabs answering `404 Does not match any SIP Trunks` means the number is not imported on the platform.

## Keep it current

The skills are reference files bundled with the CLI. [Upgrade the CLI](https://plivo.com/docs/cli/install.md#upgrade) first, using `brew upgrade plivo` for Homebrew or `plivo upgrade` for a standalone install. Then preview and refresh installed skills:

```bash theme={null}
plivo skill update --dry-run
plivo skill update
```

`skill update` covers Codex too. To install the skills as a plugin in Claude Code, Gemini CLI, Codex or Antigravity, or into a project for your whole team, see [Use with a coding agent](https://plivo.com/docs/cli/agents.md).

## Related

> [card] [Audio Streaming skill](https://plivo.com/docs/audio-streaming/integration-guides/ai-coding-agent.md)
>
> For voice bots you host yourself over a WebSocket

> [card] [Your first agent call](https://plivo.com/docs/voice-agents/sip-trunking/getting-started/your-first-agent-call.md)
>
> The same setup done by hand, step by step

> [card] [Transfer calls to humans](https://plivo.com/docs/sip-trunking/concepts/sip-refer.md)
>
> SIP REFER, and where a transfer may point

> [card] [Test and connect a platform](https://plivo.com/docs/cli/voice-agent/connect-sip-platform.md)
>
> The CLI commands the skill drives, by hand
