Skip to main content

Python SDK and CLI tool for the IDSecure API

Project description

IDSecure Python SDK & CLI

A Python client and CLI tool for interacting with the IDSecure API. This project provides a simple and intuitive interface to manage users, devices, and view logs within your IDSecure instance.

Installation

Install via pip:

pip install idsecure-cli

Or install from source:

git clone https://github.com/tsuriu/idsecure-cli.git
cd idsecure-cli
pip install .

CLI Usage

The package includes a command-line interface idsecure-cli.

Configuration

You can provide credentials via flags or environment variables:

  • --url / IDSECURE_BASE_URL
  • --user / IDSECURE_USERNAME
  • --password / IDSECURE_PASSWORD

Commands

# List all users
idsecure-cli list-users

# List all devices
idsecure-cli list-devices

# Get details for a specific user
idsecure-cli get-user --id 123

# Delete a user
idsecure-cli delete-user --id 123

SDK Usage

You can also use the IDSecureClient directly in your Python scripts.

Initialization

import asyncio
from idsecure_cli import IDSecureClient

async def main():
    # Initialize the client
    client = IDSecureClient(
        base_url="https://your-idsecure-instance.com", 
        username="your-username", 
        password="your-password"
    )

    # All client methods are asynchronous
    async with client:
        users = await client.list_users()
        print(f"Total users: {users.get('recordsTotal')}")

if __name__ == "__main__":
    asyncio.run(main())

Requirements

  • Python 3.8+
  • httpx
  • click
  • loguru

License

This project is licensed under the MIT License.

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

idsecure_cli-0.1.1.tar.gz (6.2 kB view details)

Uploaded Source

Built Distribution

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

idsecure_cli-0.1.1-py3-none-any.whl (6.9 kB view details)

Uploaded Python 3

File details

Details for the file idsecure_cli-0.1.1.tar.gz.

File metadata

  • Download URL: idsecure_cli-0.1.1.tar.gz
  • Upload date:
  • Size: 6.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.2

File hashes

Hashes for idsecure_cli-0.1.1.tar.gz
Algorithm Hash digest
SHA256 b45fb32c8f53f3092c32aa3080fb671ff15cc99877c9719c2f095cad24d2bd2e
MD5 2104c7c9df9a4e1446f5fb77b935b245
BLAKE2b-256 3130cda48a9cb346e54c2e5f32fe38abd25f31cf5398edd1586dd550aaa74c31

See more details on using hashes here.

File details

Details for the file idsecure_cli-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: idsecure_cli-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 6.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.2

File hashes

Hashes for idsecure_cli-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 79ba31de9fcab964236f3a33a4c5e9ddb0eeacadce021a102dfb4bfd1a4975dd
MD5 594fcbb5f09d9c5541e856c55c6b6718
BLAKE2b-256 943af2bf34062ae89307f94280b1ae7a0a0f4a78379feca1a0a247c3d6cc7df6

See more details on using hashes here.

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