Skip to main content

Python SDK for the NexBasira public API — sessions, evidence, whiteboards, webhooks, branding, custom domains.

Project description

nexbasira — Python SDK

Python 3.10+ client for the NexBasira public API. Mirrors the Node SDK's resource surface for ERP/CRM backends written in Python (Odoo, Django, FastAPI).

Install

pip install nexbasira

Quickstart

import os
from nexbasira import NexBasira

nb = NexBasira(
    public_key="nb_pub_...",
    secret=os.environ["NB_SECRET"],
)

# Create a session + mint a field-join URL.
session = nb.sessions.create(notes="Roof inspection — 14 Rue de Lille")
invite = nb.sessions.create_participant_invite(
    session["id"],
    role="field",
    recipient_email="field-tech@acme.com",
)
print(invite["join_url"])

# Iterate evidence (auto-paginated).
for ev in nb.evidence.list(session["id"]):
    print(ev["kind"], ev["sha256"])

# List saved whiteboards.
for wb in nb.whiteboards.list(session["id"]):
    print(wb["id"], wb["byte_size"])

Webhook verification

from nexbasira import construct_event, InvalidSignatureError

@app.post("/nb-webhook")
def handle_webhook(request):
    try:
        event = construct_event(
            request.body,
            request.headers["nb-signature"],
            os.environ["NB_WEBHOOK_SECRET"],
        )
    except InvalidSignatureError:
        return 400
    if event["type"] == "session.completed":
        ...

Errors

NexBasiraError and its subclasses AuthenticationError (401), PermissionError (403), NotFoundError (404), RateLimitError (429, .retry_after_seconds), InvalidSignatureError (webhook).

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

nexbasira-0.1.1.tar.gz (12.1 kB view details)

Uploaded Source

Built Distribution

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

nexbasira-0.1.1-py3-none-any.whl (12.4 kB view details)

Uploaded Python 3

File details

Details for the file nexbasira-0.1.1.tar.gz.

File metadata

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

File hashes

Hashes for nexbasira-0.1.1.tar.gz
Algorithm Hash digest
SHA256 7b63f8e8ce26bc211b25bc93773c5e7e7d19bf5fe65a040af085403deed02580
MD5 dc3b9e279ec43c5605cfed3f5ad622fa
BLAKE2b-256 1bd19896bfb19869b4c17796fe6852eb8e78f0f91bb4ddd944c0a66271971168

See more details on using hashes here.

Provenance

The following attestation bundles were made for nexbasira-0.1.1.tar.gz:

Publisher: sdk-publish-python.yml on codelounge-io/certivisiopro_backend

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

File details

Details for the file nexbasira-0.1.1-py3-none-any.whl.

File metadata

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

File hashes

Hashes for nexbasira-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 0b04751075e69f26815774f0e8cf455a816a115e7121d9849310126946b49611
MD5 032af2784df60342e9623e620ae51df2
BLAKE2b-256 062e266d65a26dd22540e726417c10bde44e00b33f043aa1a85bd79f0a797723

See more details on using hashes here.

Provenance

The following attestation bundles were made for nexbasira-0.1.1-py3-none-any.whl:

Publisher: sdk-publish-python.yml on codelounge-io/certivisiopro_backend

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