Skip to main content

🕸️ Iris Python Client

Tests Coverage PyPI

Minimalist Python client for the Iris API, built on top of Authlib and httpx.

Installation

pip install dioptra-iris-client

Usage

from iris_client import IrisClient, AsyncIrisClient

base_url = "https://api.iris.dioptra.io"
username = "user@example.org"
password = "password"

# Synchronous client
with IrisClient(base_url, username, password) as client:
    measurements = client.get("/measurements/").json()

# Asynchronous client
async with AsyncIrisClient(base_url, username, password) as client:
    measurements = (await client.get("/measurements/")).json()

# Helper function to fetch all the results from a paginated endpoint,
# available for both clients:
all_measurements = client.all("/measurements/")

Credential provider chain

The Iris client looks for credentials in a way similar to the AWS SDK:

  1. If one of base_url, username or password is specified, these values will be used.
  2. If none of the previous values are specified, and one of IRIS_BASE_URL, IRIS_USERNAME or IRIS_PASSWORD environment variables are present, these values will be used.
  3. If none of the previous values are specified, and the file ~/.config/iris/credentials.json exists, the fields base_url, username and password will be used.

Metadata

Release files for dioptra-iris-client 0.5.11

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for dioptra-iris-client 0.5.11
File Size Uploaded Provenance Actions
dioptra_iris_client-0.5.11.tar.gz 3.7 kB Without provenance Details for dioptra_iris_client-0.5.11.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for dioptra-iris-client 0.5.11
File Interpreter ABI Platform Actions
dioptra_iris_client-0.5.11-py3-none-any.whl Python 3 none any Details for dioptra_iris_client-0.5.11-py3-none-any.whl

Total release size: 8.6 kB

Release files / dioptra_iris_client-0.5.11.tar.gz

Download URL dioptra_iris_client-0.5.11.tar.gz
Size 3.7 kB
Tags Source
SHA-256 checksum
How to use checksums
4e675c2b5d7f6c4a03ebaf99480d219281951932fce2d5ed2a0144b18edd33d4
BLAKE2b-256 checksum
How to use checksums
712b0ddd7aca71de999aa117e653fafb508d484a14fa1ae097372095210fb9d6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.15.2

Release files / dioptra_iris_client-0.5.11-py3-none-any.whl

Download URL dioptra_iris_client-0.5.11-py3-none-any.whl
Size 4.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
446fcf0aaacf0d130f57b1d5c1e2b6d724afa4d0a44b6a56af230052d04ce0f9
BLAKE2b-256 checksum
How to use checksums
07bc26e2463c12850ef996557470596f0479e3c0b766a29d029b0a61778f0128
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.15.2

Security for dioptra-iris-client 0.5.11

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page