Metadata-Version: 2.4
Name: synauson-api
Version: 1.0.1
Summary: Generated Python code for the synauson gRPC API
License-Expression: Apache-2.0
Project-URL: Homepage, https://synauson.com
Project-URL: Source, https://github.com/synauson/api
Project-URL: Documentation, https://github.com/synauson/api/blob/v1.0.1/docs/api.md
Project-URL: Changelog, https://github.com/synauson/api/blob/v1.0.1/CHANGELOG.md
Classifier: Development Status :: 5 - Production/Stable
Classifier: Intended Audience :: Developers
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3 :: Only
Classifier: Topic :: Communications :: Telephony
Classifier: Topic :: Multimedia :: Sound/Audio :: Speech
Classifier: Typing :: Typed
Requires-Python: >=3.11
Description-Content-Type: text/markdown
License-File: LICENSE
License-File: NOTICE
Requires-Dist: grpcio>=1.80.0
Requires-Dist: protobuf<8,>=6.31.1
Provides-Extra: status
Requires-Dist: grpcio-status>=1.80.0; extra == "status"
Requires-Dist: googleapis-common-protos>=1.69.2; extra == "status"
Dynamic: license-file

# synauson-api

Python code generated from the [synauson API](https://github.com/synauson/api)
protos (package `synauson.v1`), for clients of the
[Synauson](https://synauson.com) gRPC server. Python 3.11 or newer.

```sh
pip install "synauson-api[status]"
```

The `status` extra adds `grpcio-status` and `googleapis-common-protos`, which read
the `google.rpc.ErrorInfo` every error carries. The package ships type stubs for
the messages and the service stubs; the README below says how to type-check
against them.

```python
import asyncio

import grpc

from synauson.v1 import capabilities_pb2, synauson_pb2_grpc


async def main() -> None:
    async with grpc.aio.insecure_channel("localhost:50051") as channel:
        stub = synauson_pb2_grpc.SynStub(channel)
        caps = await stub.GetCapabilities(capabilities_pb2.GetCapabilitiesRequest(), timeout=10)
        print("server", caps.server_version, "API", caps.api_version)


asyncio.run(main())
```

The version is the API's: `synauson-api 1.0.1` is tag `v1.0.1` of
synauson/api. The [README](https://github.com/synauson/api/blob/v1.0.1/README.md)
has a longer example, how to write a client and the compatibility rules, and
[docs/api.md](https://github.com/synauson/api/blob/v1.0.1/docs/api.md) the
reference.
