skillfed

azure-communication-phonenumbers

Microsoft Azure Communication Phone Numbers Client Library for Python

azure-communication-phonenumbers v1.4.0 168.7K downloads/30d#10,438 on PyPI5,588
Permissive license MIT License Active released

What it is and what it does

This package is the Python client library for Azure Communication Services' phone number management APIs. It provides two main clients: PhoneNumbersClient for acquiring and managing phone numbers (geographic, toll-free, and mobile types), and SipRoutingClient for configuring direct routing infrastructure. The package handles the full lifecycle of phone numbers—searching available numbers, reserving them temporarily, purchasing for your Azure resource, and releasing them when no longer needed. It also manages SIP trunk configuration and voice routing rules for connecting your existing telephony infrastructure to Azure.

The package depends on azure-core for authentication and HTTP transport, isodate for date/time handling, and typing-extensions for type hints. It requires Python 3.9 or later and integrates with Azure Identity for credential management, supporting both Azure Active Directory and connection-string authentication patterns.

Use it for:

  • Search and purchase phone numbers in specific countries and regions for your communication application.
  • Retrieve details about already-purchased phone numbers assigned to your Azure resource.
  • Set up SIP trunks and routing rules to connect your on-premises telephony system to Azure Communication Services.
  • Browse available phone numbers by country and type before committing to a purchase via the reservation API.
  • Release phone numbers that are no longer needed to free up capacity and reduce costs.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Manages Azure Communication Services phone numbers, including searching, purchasing, releasing, and configuring direct routing for geographic, toll-free, and mobile numbers.

Yes, if you are building on Azure Communication Services and need programmatic phone number management. The package is production-stable, actively maintained, has low install friction, and carries no known vulnerabilities. Install it only if you have an Azure subscription and a deployed Communication Services resource; without those prerequisites, the package cannot be used.

Install

azure-communication-phonenumbers on PyPI

pip

pip install azure-communication-phonenumbers

uv

uv add azure-communication-phonenumbers

poetry

poetry add azure-communication-phonenumbers

Installing azure-communication-phonenumbers

Before you install

Low install friction with three lightweight runtime dependencies. Active maintenance with recent commits and production-stable status; requires Python 3.9 or later.

License in practice

MIT License permits commercial and private use with minimal restrictions; suitable for most projects without licensing concerns.

Quickstart

pip install azure-communication-phonenumbers

from azure.communication.phonenumbers import PhoneNumbersClient
from azure.identity import DefaultAzureCredential

phone_numbers_client = PhoneNumbersClient(
    endpoint="https://<RESOURCE_NAME>.communication.azure.com",
    credential=DefaultAzureCredential()
)
purchased = phone_numbers_client.list_purchased_phone_numbers()

Requires an active Azure subscription and a deployed Azure Communication Services resource with endpoint and credentials configured.

Verify before relying

  • Whether browse and reservation operations are truly asynchronous or if async/await support is required in practice.
  • Specific rate limits or quota constraints for phone number search and purchase operations.
  • Whether SIP routing configuration persists across client reconnections or requires re-initialization.

Package facts

License MIT License (permissive)
Python support supports the current Python release (>=3.9)
Install friction low — pure-Python wheel
Runtime dependencies 3 — isodate, azure-core, typing-extensions
Maintenance actively maintained — 351 days since the last release
Last repo commit
First released
Downloads 168,718/month — #10,438 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: azure_communication_phonenumbers-1.4.0-py3-none-any.whl

Keywords: azure, azure sdk

Development Status :: 5 - Production/StableLicense :: OSI Approved :: MIT LicenseProgramming Language :: PythonProgramming Language :: Python :: 3Programming Language :: Python :: 3 :: OnlyProgramming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.9

Tags

azure phone numbers managementazure communication services clientphone number search and purchasesip routing configurationdirect routing telephonyazure phone number apitoll-free number management
azure-sdktelephonysip-routing

More Internet packages

botocore

Botocore provides low-level, data-driven access…

permissive · top 100 on PyPI

aiobotocore

Provides an async client for AWS services using…

permissive · top 100 on PyPI

pydantic

Pydantic validates Python data structures…

permissive · top 100 on PyPI

filelock

Provides a platform-independent file locking…

permissive · top 100 on PyPI

fastapi

FastAPI is a Python web framework for building…

permissive · top 100 on PyPI

googleapis-common-protos

Provides common Protocol Buffer message…

permissive · top 100 on PyPI

azure-communication-identity

Creates and manages user identities and access…

permissive · top 15,000 on PyPI

azure-communication-sms

Sends SMS messages through Azure Communication…

permissive · top 15,000 on PyPI

vonage-numbers

Provides Python bindings to Vonage's Numbers…

permissive · top 15,000 on PyPI

azure-mgmt-trafficmanager

Provides a Python client library to manage…

permissive · top 5,000 on PyPI

azure-communication-callautomation

Provides a Python SDK to build server-based…

permissive · top 15,000 on PyPI

azure-mgmt-reservations

Manages Azure Reservations and Savings Plans…

permissive · top 5,000 on PyPI

azure-communication-email

Sends emails via Azure Communication Services,…

permissive · top 5,000 on PyPI

phaxio

A Python client library for the Phaxio API that…

permissive · top 15,000 on PyPI

azure-communication-rooms

Manages Azure Communication Services rooms for…

permissive · top 15,000 on PyPI

bandwidth-sdk

Python client library for Bandwidth's…

unclear · top 15,000 on PyPI