Metadata-Version: 2.4
Name: handset
Version: 0.10.0
Summary: A client library for accessing Handset API
License: MIT
Keywords: sms,voice,telephony,10dlc,phone-numbers,voicemail
Requires-Python: >=3.11,<4.0
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Programming Language :: Python :: 3.14
Requires-Dist: attrs (>=22.2.0)
Requires-Dist: httpx (>=0.23.1,<0.29.0)
Project-URL: Documentation, https://docs.handset.dev
Project-URL: Homepage, https://handset.dev
Description-Content-Type: text/markdown

# handset

The official Python SDK for [Handset](https://handset.dev) — the business
phone API. Compliant two-way SMS, inbound voice, voicemail with transcripts,
phone numbers, and 10DLC compliance for your platform's customers.

```bash
pip install handset
```

## Quickstart

```python
from handset import AuthenticatedClient
from handset.api.messaging import send_message
from handset.models import SendMessageBody

client = AuthenticatedClient(
    base_url="https://api.handset.dev/v1",
    token="hs_test_...",  # test mode: simulated carrier, free numbers
)

message = send_message.sync(
    client=client,
    body=SendMessageBody(
        from_="num_01kzv...",          # one of your tenant's numbers
        to="+14155550134",
        body="Your technician is 15 minutes out.",
    ),
)
print(message.id, message.status)      # msg_..., "queued"
```

Every endpoint lives under `handset.api.<area>` (`messaging`, `voice`,
`phone_numbers`, `tenants`, `compliance`, `webhooks`, `usage`) with `sync`,
`sync_detailed`, `asyncio`, and `asyncio_detailed` variants. All request and
response shapes are typed attrs models under `handset.models`.

## Test mode

Every account ships parallel live and test keys. Test keys (`hs_test_...`)
run against a simulated carrier — numbers are free and instant, compliance
approves immediately, and magic numbers let you rehearse failures. Start
there.

## Docs

- Guides: [docs.handset.dev](https://docs.handset.dev)
- API reference: [docs.handset.dev/api.html](https://docs.handset.dev/api.html)
- TypeScript SDK: [`@handset/sdk`](https://www.npmjs.com/package/@handset/sdk)

Questions: [developer@handset.dev](mailto:developer@handset.dev)

