Metadata-Version: 2.1
Name: waylay-sdk-core
Version: 0.2.0
Summary: Waylay Python SDK.
Author-email: Waylay <info@waylay.io>
License: ISC License (ISC)
        Copyright 2020, Waylay
        
        Permission to use, copy, modify, and/or distribute this software for any purpose 
        with or without fee is hereby granted, provided that the above copyright notice 
        and this permission notice appear in all copies.
        
        THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH 
        REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND 
        FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, 
        OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, 
        DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS 
        ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
        
Project-URL: Homepage, https://www.waylay.io/
Project-URL: Documentation, https://docs.waylay.io/#/
Project-URL: Repository, https://github.com/waylayio/waylay-sdk-py.git
Keywords: waylay,sdk
Requires-Python: >=3.9
Description-Content-Type: text/markdown
License-File: LICENSE.txt
Requires-Dist: httpx
Requires-Dist: appdirs
Requires-Dist: python-jose
Requires-Dist: python_dateutil
Requires-Dist: typing_extensions>=4.10.0
Requires-Dist: typeguard
Requires-Dist: jsonpath-ng
Requires-Dist: pydantic>=2.6.0
Requires-Dist: eval-type-backport~=0.1.3; python_version < "3.10"
Requires-Dist: waylay-beta==9.9.9b9
Provides-Extra: dev
Requires-Dist: pytest; extra == "dev"
Requires-Dist: pytest-cov; extra == "dev"
Requires-Dist: pytest-mock; extra == "dev"
Requires-Dist: pytest-httpx; extra == "dev"
Requires-Dist: pytest-asyncio; extra == "dev"
Requires-Dist: starlette; extra == "dev"
Requires-Dist: syrupy; extra == "dev"
Requires-Dist: ruff; extra == "dev"
Requires-Dist: mypy; extra == "dev"
Requires-Dist: types-python-jose; extra == "dev"
Requires-Dist: types-appdirs; extra == "dev"
Requires-Dist: types-python-dateutil; extra == "dev"
Requires-Dist: docformatter; extra == "dev"
Requires-Dist: pre-commit; extra == "dev"
Requires-Dist: sse-starlette; extra == "dev"

# Waylay Python SDK

Python SDK for the Waylay Platform.

This `waylay-sdk-core` package provides a basic SDK client for the [Waylay REST apis](https://docs.waylay.io/#/api/?id=openapi-docs). 

See [Waylay Docs](https://docs.waylay.io/#/api/sdk/python) for documentation.

## Installation

This package requires a python runtime `3.9` or higher.

The basic client can be installed with
```bash
pip install waylay-sdk-core
```

This client provides configuration, authorization and plugin features for the SDK.

It includes a generic http client to make authenticated calls to the services available on your _Waylay_ gateway endpoint.

Support for specific Waylay services or tools is provided by separate extension packages.

See [`waylay-sdk`](https://pypi.org/project/waylay-sdk) to install a client that includes the recommended extensions.

## Basic usage

### Interactive Authentication

When used outside the Waylay platform (e.g. in a _python notebook_) the client requires you to provide
* the gateway endpoint: `api.waylay.io` for Enterprise users,
* an API key-secret pair: see [Waylay Console](console.waylay.io) at _>Settings>Authentication keys_.

```python
from waylay.sdk import WaylayClient

# this will interactively request the gateway and credentials on first usage.
client = WaylayClient.from_profile()

# list the available service packages
client.services

# use the generic api client to see the status page of the 'registry' service.
resp = await client.api_client.request('GET', '/registry/v2')
```

Credentials and endpoints are stored in a local _profile_ file (you can have multiple such profiles).
Other authentication methods are available (JWToken, pass apiKey/Secret directly)

