Skip to main content

Official Python SDK for PatchOps Guard (patchguard.ai)

Project description

patchguard-ai — PatchOps Guard Python SDK

Official Python client for the PatchOps Guard API.

Installation

pip install patchguard-ai

Distribution name is patchguard-ai but the import name is patchguard (Django-style split — patchguard alone is taken on PyPI).

Quick start

from patchguard import PatchopsClient

with PatchopsClient(
    base_url="https://patchguard.ai",
    api_key="pk_live_...",
) as client:
    health = client.health.check()
    print(health)  # {"status": "ok", "db": True, "redis": True}

    findings = client.findings.list_unified(kind="cve", limit=50)
    for f in findings.items:
        print(f"{f.severity:8s} {f.title}")

    lb = client.benchmark.leaderboard()
    print(lb["vendors"][0]["name"])

Resources

  • client.health.check() — ping /health
  • client.findings.list_unified(kind=, severity=, limit=, offset=) — unified findings across all 10 Lanes
  • client.benchmark.leaderboard() — full vendor comparison

Errors

All API errors raise PatchopsError(status_code, detail).

License

MIT. See 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

patchguard_ai-0.1.0.tar.gz (4.0 kB view details)

Uploaded Source

Built Distribution

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

patchguard_ai-0.1.0-py3-none-any.whl (4.6 kB view details)

Uploaded Python 3

File details

Details for the file patchguard_ai-0.1.0.tar.gz.

File metadata

  • Download URL: patchguard_ai-0.1.0.tar.gz
  • Upload date:
  • Size: 4.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.3

File hashes

Hashes for patchguard_ai-0.1.0.tar.gz
Algorithm Hash digest
SHA256 6767a73f46086eed77c5f0d1da0d5d717d99521f8458b0f8100d763d4d312364
MD5 27b9f616ea7feaec9e608d42e0e20e6e
BLAKE2b-256 8a30ff201dde929b973444bcc1f8964464665e9c15bd387f1e79aca943b2faa1

See more details on using hashes here.

File details

Details for the file patchguard_ai-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: patchguard_ai-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 4.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.3

File hashes

Hashes for patchguard_ai-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 8682dcde1494761236a0a5e5d6a2778e16cef2251f2014da3d2256e5984f2471
MD5 eb14949e54046f3313fb3fac5f328c13
BLAKE2b-256 319c10fede10e366ab7af6e31d588a4cad2bc0e63ca41d2fe8872a1dc2649778

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