Metadata-Version: 2.4
Name: pjdev-armis-sdk
Version: 5.1.10
Summary: Async Python SDK for the Armis API
Project-URL: Documentation, https://gitlab.purplejay.io/keystone/python/-/tree/main/pjdev-armis-sdk/README.md
Project-URL: Issues, https://gitlab.purplejay.io/keystone/python/-/issues
Project-URL: Source, https://gitlab.purplejay.io/keystone/python
Author-email: Purple Jay LLC <developers@purplejay.io>
License-Expression: MIT
License-File: LICENSE.txt
Classifier: Development Status :: 4 - Beta
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: Implementation :: CPython
Classifier: Programming Language :: Python :: Implementation :: PyPy
Requires-Python: >=3.12
Requires-Dist: httpx
Requires-Dist: loguru
Requires-Dist: pydantic-settings>=2.13.1
Requires-Dist: pydantic>=2.12.5
Provides-Extra: dev
Requires-Dist: ruff; extra == 'dev'
Provides-Extra: test
Requires-Dist: coverage; extra == 'test'
Requires-Dist: pytest; extra == 'test'
Requires-Dist: pytest-asyncio; extra == 'test'
Requires-Dist: respx; extra == 'test'
Description-Content-Type: text/markdown

# pjdev-armis-sdk

[![PyPI - Version](https://img.shields.io/pypi/v/pjdev-armis-sdk.svg)](https://pypi.org/project/pjdev-armis-sdk)
[![PyPI - Python Version](https://img.shields.io/pypi/pyversions/pjdev-armis-sdk.svg)](https://pypi.org/project/pjdev-armis-sdk)

-----

Async Python SDK for the [Armis](https://www.armis.com/) API, built on `httpx` and `pydantic`.

## Table of Contents

- [Installation](#installation)
- [Usage](#usage)
- [License](#license)

## Installation

```console
pip install pjdev-armis-sdk
```

## Usage

Configure once at startup (reads from environment variables prefixed with `ARMIS_`):

```python
from pjdev_armis_sdk import config_service

config_service.init(
    instance_url="https://your-tenant.armis.com",
    secret_key="your-secret-key",
)
```

Then call any of the resource modules:

```python
from pjdev_armis_sdk import devices, search

# AQL search
result = await search.aql_search("in:devices type:MOBILE_PHONE")

# Lookup a single device by id
device = await devices.get_device(id=12345)
```

Auth (`Authorization` header with a temporary access token) is handled automatically
by the underlying `httpx.AsyncClient`. Tokens are refreshed on the fly when they expire
or when the API returns 401.

## License

`pjdev-armis-sdk` is distributed under the terms of the [MIT](https://spdx.org/licenses/MIT.html) license.
