Skip to main content

openai-agents-agentphone

PyPI version License: MIT

AgentPhone tools for the OpenAI Agents SDK — let your AI agents send SMS messages, make phone calls, and manage phone numbers.

Installation

pip install openai-agents-agentphone

Setup

Get your API key from agentphone.to and set it as an environment variable:

export AGENTPHONE_API_KEY="your-api-key"

Quick Start

Use all tools

from agents import Agent
from openai_agents_agentphone import get_tools

agent = Agent(
    name="Phone Assistant",
    instructions="You help users manage phone numbers, send messages, and make calls.",
    tools=get_tools(),
)

Use specific tools

from openai_agents_agentphone import get_tools

tools = get_tools(selected=["send_sms", "list_numbers", "make_call"])

Use individual tools

from agents import Agent
from openai_agents_agentphone import agentphone_send_sms, agentphone_make_call

agent = Agent(
    name="Outbound Agent",
    instructions="You make calls and send messages on behalf of the user.",
    tools=[agentphone_send_sms, agentphone_make_call],
)

Configure API key in code

from openai_agents_agentphone import configure

configure(api_key="your-api-key")

Full example with Runner

import asyncio
from agents import Agent, Runner
from openai_agents_agentphone import configure, get_tools

configure(api_key="your-api-key")

agent = Agent(
    name="Phone Assistant",
    instructions="You help users with phone calls and messages via AgentPhone.",
    tools=get_tools(),
)

async def main():
    result = await Runner.run(agent, "List my phone numbers")
    print(result.final_output)

asyncio.run(main())

Available Tools

Tool Name Description
agentphone_send_sms Send SMS Send an SMS message from an agent's phone number
agentphone_make_call Make Call Make an AI-powered outbound phone call
agentphone_get_transcript Get Transcript Get the full transcript of a call
agentphone_list_calls List Calls List recent phone calls with filters
agentphone_list_conversations List Conversations List SMS conversation threads
agentphone_get_conversation Get Conversation Get a conversation with messages
agentphone_buy_number Buy Number Buy a new phone number
agentphone_list_numbers List Numbers List all phone numbers
agentphone_create_agent Create Agent Create a new AI phone agent
agentphone_list_agents List Agents List all AI phone agents
agentphone_create_contact Create Contact Create a new contact
agentphone_list_contacts List Contacts List contacts

API Reference

See the AgentPhone documentation for full API details.

Metadata

Release files for openai-agents-agentphone 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for openai-agents-agentphone 0.1.0
File Size Uploaded
openai_agents_agentphone-0.1.0.tar.gz 5.1 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for openai-agents-agentphone 0.1.0
File Interpreter ABI Platform
openai_agents_agentphone-0.1.0-py3-none-any.whl Python 3 none any Details

Total release size: 11.2 kB

Release files / openai_agents_agentphone-0.1.0.tar.gz

Download URL openai_agents_agentphone-0.1.0.tar.gz
Size 5.1 kB
Tags Source
SHA-256 checksum
How to use checksums
762f148a442e02efc4580c05e44125ab8b940ec58be09e838a3fd9945400c77e
BLAKE2b-256 checksum
How to use checksums
bf2dedea71b3fbd95e3f1a2bd5858f895ab475a0b07ed4d3b55afa36b5fcf46c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.14.4

Release files / openai_agents_agentphone-0.1.0-py3-none-any.whl

Download URL openai_agents_agentphone-0.1.0-py3-none-any.whl
Size 6.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
70ae14e1e5f9179268a408ac120e9b839e101ed08166e5fb299e45d0a21539ec
BLAKE2b-256 checksum
How to use checksums
f890f38f66a4683d9d8a0c06605ee22fdc08d6a61b80c2dbf9ab665726e37254
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.14.4

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page