a lightweight, read-only Python wrapper for the OTX AlienVault API.
uv add git+https://github.com/ey3tech/otx-pyfrom otx_py import OTXClient
client = OTXClient(api_key="your-api-key")base url is https://otx.alienvault.com/api/v1 unless otherwise stated
# list pulses, https://otx.alienvault.com/otxapi/pulses
client.get_pulses(limit=25)
# get a pulse by id, /pulses/{pulse_id}
client.get_pulse_by_id("pulse-id")
# get indicators for a pulse, /pulses/{pulse_id}/indicators
client.get_pulse_indicators("pulse-id", limit=50)# search users, /search/users
client.search_users("query", page=1, limit=20)
# search pulses, /search/pulses
client.search_pulses("query", page=1, limit=20)# get indicator types, /pulses/indicators/types
client.get_indicator_types()
# get user details, /users/{username}
client.get_user("username", detail=True)this wrapper only has two dependencies: httpx and msgspec. httpx is a modern http library, and msgspec provides high-speed json decoding and structs.
just clone the repository and run uv sync (or use another package manager)