Use the SMS Verification API With Claude Code: A Setup Guide

Let Claude Code wire SMS verification into your project: give it the API skill, keep the key in an environment variable and review each purchase.

Claude Code can wire SMS verification into your project for you: give it the SMS Activate App API skill, keep your API key in an environment variable, and review every step that spends money.

This guide sets that up in about ten minutes. It works the same way with Codex, Cursor or any coding agent that reads files and runs commands.

What the agent can do with the API

With a key, a coding agent can do everything your own code can:

  • Search live numbers in a country and see your price.
  • Buy a private number for a 28-day term, with an Idempotency-Key so a retry never charges twice.
  • Read the SMS that arrive on it, and the calls: since November 2026 a short call comes with its text and the code read out in it.
  • Release a number or turn off its renewal.
  • Set up a webhook so codes reach your server without polling.

Typical tasks to hand over: an end-to-end test of your sign-up flow, a helper that waits for a code in CI, or a webhook receiver with signature checks.

Step 1: create a key and keep it out of the code

  • Create an account on the registration page and add balance.
  • Create a personal API key on the API keys tab of your account, or in the Telegram bot.
  • Put the key in your shell or your project's secret store, never in a file the agent commits:

The key spends your balance. Claude Code reads the variable when it runs a command; it does not need to see the value in the chat. If the key ever lands in a file, a commit or a log, revoke it in the account and create a new one.

Step 2: give Claude Code the skill

The site publishes a ready skill file for coding agents at /api-skill.md. It names the base URL, the routes, the limits and the errors to handle. Save it as a project skill:

Claude Code loads a skill when a task matches its description, for example "wait for the SMS code in my sign-up test". Commit the skill file if your team should share it; it contains no key.

No skill support in your agent? Open the API docs and press the button that copies the agent prompt. It carries the same rules in one block of text you can paste into any chat.

Step 3: set the house rules

Add a few lines to your project's CLAUDE.md, so every session follows them:

The second rule matters most. A purchase is final and non-refundable once a number is issued, so a person should see each one before it happens. Claude Code asks for permission before it runs a command; keep that on for commands that call the purchase route.

Step 4: give it a task

Ask for the result, not the calls. For example:

Add a pytest fixture that rents one US number through the SMS Activate App API, waits up to five minutes for an SMS on it and returns the code. Reuse one renewing number across runs instead of buying a new one each time.

A good result looks like this:

  • It searches with GET /v1/public/numbers/search?country=US and shows you the number and its price before buying.
  • It buys with POST /v1/public/numbers and an Idempotency-Key.
  • It polls GET /v1/public/numbers/{id}/sms every 5 to 15 seconds with a timeout, or sets a webhook.
  • It handles insufficientbalance, numberunavailable and rate_limited as answers, not as crashes.

If it guesses a route that is not in the skill, point it to the OpenAPI file and ask it to check.

Step 5: review before you merge

Before you merge what the agent wrote, check four things:

  • No key in the diff, the test output or the CI logs.
  • Every purchase sends an Idempotency-Key, and a retry reuses it.
  • Each wait has a timeout and a clear failure message that names the number.
  • The test does not buy a new number on every run when one renewing number would do.

Costs to know about

Each number is rented for 28 days at the price the search shows, and renews from the balance while auto-renew is on. Since November 2026 inbound calls (per minute) and SMS on a number are also charged to the balance, at a per-country price the API returns as usagePricing. Check pricing for the current numbers before you let an agent run a suite on a schedule.

When not to use it

The API receives SMS and calls; it does not send them. Use it for your own apps, accounts and tests. The platform you verify with, not us, decides whether it accepts a number, so check a number with your target service before you build a pipeline on it: how to check a number before you rent it.

Next steps