Skip to main content

Python SDK for Circle.so - Admin V2, Headless Auth, and Headless Client V1 APIs

Project description

circle-so-python-sdk

CI

Python SDK for Circle.so covering three APIs:

  • Headless Auth API -- token management for headless integrations
  • Admin API V2 -- server-side community management (~120 endpoints)
  • Headless Client API V1 -- member-facing operations (~100 endpoints)

Installation

pip install circle-so-python-sdk

Quick Start

from circle import CircleClient

# Admin API usage
client = CircleClient(api_token="YOUR_ADMIN_TOKEN")
community = client.admin.get_community()

# Headless Auth -- get member tokens
token = client.auth.create_auth_token(email="member@example.com")

# Headless Client -- use member access token
headless = CircleClient(api_token=token.access_token, community_url="https://your-community.circle.so")
spaces = headless.headless.list_spaces()

Async Support

from circle import AsyncCircleClient

async with AsyncCircleClient(api_token="YOUR_TOKEN") as client:
    members = await client.admin.list_community_members()

API Coverage

API Endpoints Sync Async
Headless Auth 4 Yes Yes
Admin V2 ~118 Yes Yes
Headless Client V1 ~101 Yes Yes

Documentation

  • Quickstart -- install, auth, basic usage
  • Admin API -- all admin endpoints with examples
  • Headless API -- all headless endpoints with examples
  • Auth API -- headless auth token management
  • Models -- complete models reference
  • Webhooks -- signature verification and payload parsing

Project Structure

src/circle/
  __init__.py           # Public API exports
  client.py             # CircleClient / AsyncCircleClient facade
  http.py               # Sync/Async HTTP transport with retry
  exceptions.py         # Typed exceptions (401/403/404/422/429)
  pagination.py         # Auto-pagination helpers
  rate_limit.py         # Token bucket rate limiter
  validation.py         # Request body validation models
  webhooks.py           # Webhook signature verification
  models/
    auth.py             # HeadlessAuthToken, RefreshedAccessToken
    admin/              # ~35 Pydantic models for Admin API
    headless/           # ~40 Pydantic models for Headless API
  api/
    auth.py             # Headless Auth client (4 endpoints)
    admin_*.py          # 8 Admin API client modules
    headless_*.py       # 3 Headless API client modules

Contributing

  1. Clone the repo and install in dev mode: pip install -e .[dev]
  2. Run tests: pytest tests/ -v --ignore=tests/integration
  3. Follow conventional commit format for commit messages

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

circle_so_python_sdk-0.1.0.tar.gz (44.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

circle_so_python_sdk-0.1.0-py3-none-any.whl (48.1 kB view details)

Uploaded Python 3

File details

Details for the file circle_so_python_sdk-0.1.0.tar.gz.

File metadata

  • Download URL: circle_so_python_sdk-0.1.0.tar.gz
  • Upload date:
  • Size: 44.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for circle_so_python_sdk-0.1.0.tar.gz
Algorithm Hash digest
SHA256 1ac3bf91a439a2b1d54240e71456fbcedab3dcf52f640e19a5b8cec8e9580432
MD5 e48b9873b84f3407f8aa10bba26d6caa
BLAKE2b-256 238d462b385e94bae585914d01689c1e38bd85e0d3f0f186593e85809390e4c5

See more details on using hashes here.

Provenance

The following attestation bundles were made for circle_so_python_sdk-0.1.0.tar.gz:

Publisher: publish.yml on boiyelove/circle-so-python-sdk

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file circle_so_python_sdk-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for circle_so_python_sdk-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 b475da388574873c1f5a4940a63918e6b83d996faf164cd53da14b37a98a28f6
MD5 b854f7b7ceea8c8343e8ab082444772d
BLAKE2b-256 d1ae7e5fdee83f805d8ff40180431251f229d6438ce8b4c1332ce47bec641cd4

See more details on using hashes here.

Provenance

The following attestation bundles were made for circle_so_python_sdk-0.1.0-py3-none-any.whl:

Publisher: publish.yml on boiyelove/circle-so-python-sdk

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page