Skip to main content

dial-langchain

Official LangChain tools for Dial — phone numbers, SMS, WhatsApp, and AI voice calls for AI agents.

Install

pip install dial-langchain
# or
uv add dial-langchain

This pulls in dial-sdk and langchain-core automatically. Requires Python 3.11+.

Quickstart

Build one DialClient, hand it to DialToolkit, and call get_tools() to give an agent the full set — no per-tool imports. Every tool shares that one client (a single connection pool):

from dial_sdk import DialClient, DialConfig
from dial_langchain import DialToolkit
from langchain.chat_models import init_chat_model
from langgraph.prebuilt import create_react_agent

model = init_chat_model("claude-sonnet-4-6", model_provider="anthropic")

dial = DialClient(DialConfig(api_key="sk_live_..."))
toolkit = DialToolkit(client=dial)
agent = create_react_agent(model, toolkit.get_tools())

DialToolkit is a standard LangChain BaseToolkit, so get_tools() works anywhere a list of tools is expected. DialConfig also takes an optional base_url (defaults to https://api.getdial.ai; override it for local or self-hosted setups).

Pick individual tools

When you only want a subset, import the tools directly and pass them the same client. Each Dial capability is a LangChain BaseTool:

from dial_sdk import DialClient, DialConfig
from dial_langchain import (
    ListNumbersTool,
    SendMessageTool,
    MakeCallTool,
    ListCallsTool,
    GetCallTool,
    WaitForMessageTool,
)

dial = DialClient(DialConfig(api_key="sk_live_..."))
tools = [
    ListNumbersTool(client=dial),
    SendMessageTool(client=dial),
    MakeCallTool(client=dial),
]

# Drop into any LangChain agent:
from langchain.agents import create_react_agent
agent = create_react_agent(model, tools, prompt)

The tools are async — LangChain calls them via ainvoke.

Available tools

Tool Tool name (for the LLM)
ListNumbersTool list_numbers
PurchaseNumberTool purchase_number
SetNumberPropertiesTool set_number_properties
ListMessagesTool list_messages
ListContactsTool list_contacts
SendMessageTool send_message
ReplyToMessageTool reply_to_message
ListCallsTool list_calls
MakeCallTool make_call
GetCallTool get_call
WaitForMessageTool wait_for_message

Each tool wraps the corresponding dial-sdk call under the hood. DialToolkit.get_tools() returns all of them.

Release files for dial-langchain 0.23.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 dial-langchain 0.23.0
File Size Uploaded
dial_langchain-0.23.0.tar.gz 139.6 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for dial-langchain 0.23.0
File Interpreter ABI Platform
dial_langchain-0.23.0-py3-none-any.whl Python 3 none any Details

Total release size: 151.7 kB

Release files / dial_langchain-0.23.0.tar.gz

Download URL dial_langchain-0.23.0.tar.gz
Size 139.6 kB
Tags Source
SHA-256 checksum
How to use checksums
9257e2d8856f101d76f5393242681721b964a1fca2c2a496a49f45899be05fc1
BLAKE2b-256 checksum
How to use checksums
09e62bda94f0a4d816b5232f72330b7841add9cd0c8cfccfc6cada1dba33be7a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 23, 2026.

Transparency log

Release files / dial_langchain-0.23.0-py3-none-any.whl

Download URL dial_langchain-0.23.0-py3-none-any.whl
Size 12.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
36875b01bf5f6d60b7a995cf849aea78500cafdcd4e7612f5f0534c789067b3c
BLAKE2b-256 checksum
How to use checksums
0f4e9d74f21d2bcd5453f1d08edc4926fae812360f50b1e0e77e5d441b52e8b9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 23, 2026.

Transparency log

Release history Release notifications | RSS feed

0.25.0

2 release files

0.24.0

2 release files

This release

0.23.0 This release

2 release files

0.22.0

2 release files

0.21.2

2 release files

0.21.1

2 release files

0.21.0

2 release files

0.20.0

2 release files

0.17.0

2 release files

0.13.0

2 release files

0.12.0

2 release files

0.11.0

2 release files

0.10.0

2 release files

0.9.2

2 release files

0.9.1

2 release files

0.9.0

2 release files

0.7.0

2 release files

0.6.0

2 release files

0.5.0

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