Skip to main content

A library to interact with the Ambient Labs Event Bus.

Project description

Ambient Event Bus Client

Typical usage example

from ambient_event_bus_client import Client, ClientOptions

options = ClientOptions(
    event_api_url="http://localhost:8000",
    connection_service_url="http://localhost:8001",
    api_token = "my_token"
)
client = Client(options)
await client.init_client() # ensure you are in an async context

# add subscriptions
await client.add_subscription(topic="test")

# read messages from subscriptions
async for message in client.subscribe():
    print(message)

# publish a message
message = MessageCreate(topic="my_topic", message="my_message")
await client.publish(message)

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

ambient_event_bus_client-0.1.6.tar.gz (4.4 kB view details)

Uploaded Source

Built Distribution

ambient_event_bus_client-0.1.6-py3-none-any.whl (5.8 kB view details)

Uploaded Python 3

File details

Details for the file ambient_event_bus_client-0.1.6.tar.gz.

File metadata

File hashes

Hashes for ambient_event_bus_client-0.1.6.tar.gz
Algorithm Hash digest
SHA256 9c7f1f29119f7b1b212b8d0daccfa6e4b517be095a2f019e2740cbed8498679a
MD5 5a773df4c85670e3602c1e15983f800c
BLAKE2b-256 96cb508b827ba7927bd0940549f414d39dfc704b4f6d4e28fb42b6cd49e568dc

See more details on using hashes here.

File details

Details for the file ambient_event_bus_client-0.1.6-py3-none-any.whl.

File metadata

File hashes

Hashes for ambient_event_bus_client-0.1.6-py3-none-any.whl
Algorithm Hash digest
SHA256 99d5bc241f381983f56605ecd7ec8787e72871db1794a8396ca316cc6cca56b3
MD5 8cb35957bc7fc87c03437823e4fa5bd8
BLAKE2b-256 768c73715a0a2b7423b0e69ac248da382880ea4231b7b17f0e62d8658fb3733b

See more details on using hashes here.

Supported by

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