Skip to main content

Python SDK for Webex Contact Center BYOVA / BYODS — Data Sources, Service App tokens, and Integration OAuth

Project description

webex-byova

Python SDK for Webex Contact Center BYOVA and the foundational Bring Your Own Data Source (BYODS) APIs.

Simplify Service App token management, Integration OAuth, DataSource CRUD, schema discovery, and JWS verification.

Install

pip install webex-byova

Quick start

import asyncio
from webex_byova import BYOVA
from webex_byova.models import IntegrationCredentials, ServiceAppCredentials

sdk = BYOVA(
    integration=IntegrationCredentials(
        client_id="YOUR_INTEGRATION_CLIENT_ID",
        client_secret="YOUR_INTEGRATION_CLIENT_SECRET",
        redirect_uri="http://127.0.0.1:8765/callback",
    ),
    service_app=ServiceAppCredentials(
        client_id="YOUR_SERVICE_APP_CLIENT_ID",
        client_secret="YOUR_SERVICE_APP_CLIENT_SECRET",
    ),
)

async def main():
  # Developer authorizes Integration (not customer admin)
  await sdk.integration.aauthorize(
      scopes=[
          "spark:applications_token",
          "application:webhooks_write",
          "application:webhooks_read",
      ],
      open_browser=True,
  )

  await sdk.webhooks.aensure_service_app_webhooks(
      target_url="https://your-app.example.com/webhooks/webex",
  )

asyncio.run(main())

After a customer admin authorizes your Service App in Control Hub, handle the webhook:

result = await sdk.ahandle_service_app_webhook(webhook_json)
client = await sdk.aget_client_for_org(result.org_id)
sources = await client.data_sources.alist()

Environment variables

export WEBEX_INTEGRATION_CLIENT_ID=...
export WEBEX_INTEGRATION_CLIENT_SECRET=...
export WEBEX_SA_CLIENT_ID=...
export WEBEX_SA_CLIENT_SECRET=...
export WEBEX_INTEGRATION_REDIRECT_URI=http://127.0.0.1:8765/callback
sdk = BYOVA.from_env()

Documentation

See the docs/ directory and CONTRIBUTING.md.

License

MIT — see LICENSE.

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

webex_byova-0.1.0.tar.gz (21.0 kB view details)

Uploaded Source

Built Distribution

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

webex_byova-0.1.0-py3-none-any.whl (22.3 kB view details)

Uploaded Python 3

File details

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

File metadata

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

File hashes

Hashes for webex_byova-0.1.0.tar.gz
Algorithm Hash digest
SHA256 39778acd6dc810e1d866b24357eb172a04cdd92f618d65411c5d8b28425e79b8
MD5 29231ab0d9c1ce60cc6175aeeea608f6
BLAKE2b-256 0edba8752c8b8c7db08351057510e0767dc2196c79a7219c85b6a02972159c73

See more details on using hashes here.

Provenance

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

Publisher: release.yml on Joezanini/byova-sdk-python

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

File details

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

File metadata

  • Download URL: webex_byova-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 22.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for webex_byova-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 e273b2ac69e80ed9ce5dba02b04726c0b65ff2f5e2510cae5f7c19dfd7c0e2ea
MD5 17f75d6cc6c2078156747094b71c96af
BLAKE2b-256 0fda4d16852f1c92cb2dfb2649445f64d9a3809519fa30c7dc61ff70cb889c05

See more details on using hashes here.

Provenance

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

Publisher: release.yml on Joezanini/byova-sdk-python

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