Skip to main content

The Armis SDK is a package that encapsulates common use-cases for interacting with the Armis platform.

Project description

Armis SDK for Python 3.9+

Run tests Run formatter Run linter

The Armis SDK is a package that encapsulates common use-cases for interacting with the Armis platform.

Installation

Use your favourite package manager to install the SDK, for example:

pip install armis_sdk

Documentation

For full documentation, please visit our dedicated site.

Usage

All interaction with the SDK happens through the ArmisSdk class. You'll need 3 things:

  1. Tenant name: The name of the tenant you want to interact with.
  2. Secret key: The secret key associated with the tenant, obtained from the tenant itself.
  3. Client id: A unique identifier for you application. Currently, this can be any string.

You can either provide these values using the environment variables ARMIS_TENANT, ARMIS_SECRET_KEY, and ARMIS_CLIENT_ID:

from armis_sdk import ArmisSdk

armis_sdk = ArmisSdk()

or by passing them explicitly:

from armis_sdk import ArmisSdk

armis_sdk = ArmisSdk(tenant="<tenant>", secret_key="<secret_key>", client_id="<client_id>")

[!TIP] If you're building an application that interacts with multiple tenants, you can populae only the ARMIS_CLIENT_ID environment variable and pass the tenant and secret_key explicitly:

from armis_sdk import ArmisSdk

armis_sdk = ArmisSdk(tenant="<tenant>", secret_key="<secret_key>")

Entity clients

Once you have an instance of ArmisSdk, you can start interacting with the various clients, each handles use-cases of a specific entity.

[!NOTE] Note that all functions in this SDK that eventually make HTTP requests are asynchronous.

However, for convenience, all public asynchronous functions can also be executed in a synchronous way.

For example, if you want to update a site's location:

import asyncio

from armis_sdk import ArmisSdk
from armis_sdk.entities.site import Site

armis_sdk = ArmisSdk()

async def main():
    site = Site(id="1", location="new location")
    await armis_sdk.sites.update(site)

asyncio.run(main())

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

armis_sdk-0.3.0.tar.gz (10.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

armis_sdk-0.3.0-py3-none-any.whl (15.8 kB view details)

Uploaded Python 3

File details

Details for the file armis_sdk-0.3.0.tar.gz.

File metadata

  • Download URL: armis_sdk-0.3.0.tar.gz
  • Upload date:
  • Size: 10.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for armis_sdk-0.3.0.tar.gz
Algorithm Hash digest
SHA256 f836466b21f6ad2b1a8cd2174b570d0915d3940495d55d7e364a40fe2bf63dd3
MD5 30553afa7004eccb4a70c99cb4459792
BLAKE2b-256 8597953bc2b730c0b98ddc25a2ff30da65cc272b229ba9b86e3e546688cb28a1

See more details on using hashes here.

Provenance

The following attestation bundles were made for armis_sdk-0.3.0.tar.gz:

Publisher: publish.yml on ArmisSecurity/armis-sdk-python

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file armis_sdk-0.3.0-py3-none-any.whl.

File metadata

  • Download URL: armis_sdk-0.3.0-py3-none-any.whl
  • Upload date:
  • Size: 15.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for armis_sdk-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 38efb434484d462e78adcd9a5d987dc8f6d0ee311eca32bbda379abae77e2065
MD5 e5b5b047019baf6c1a960c57ff9db30b
BLAKE2b-256 6f3e922fad60213982c0996995da65a1b63bb8a0a3f09cb85067b9d1b401151c

See more details on using hashes here.

Provenance

The following attestation bundles were made for armis_sdk-0.3.0-py3-none-any.whl:

Publisher: publish.yml on ArmisSecurity/armis-sdk-python

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

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