Skip to main content

Capsule plugin for Hermes — forwards hook events to the Capsule agentsecurity service for centralized policy enforcement and audit.

Project description

capsule-hermes

Capsule plugin for the Hermes autonomous AI agent runtime. Forwards Hermes hook events to the Capsule agentsecurity service for centralized policy enforcement and audit.

Install

pip install capsule-hermes

Configure

Register the plugin in your Hermes runtime config (e.g. hermes.yaml):

plugins:
  - module: capsule_hermes
    config:
      endpoint: "https://agents.capsulesecurity.io/v1/hermes/hooks/events"
      token: ${CAPSULE_HERMES_TOKEN}

The endpoint and token values are issued by Capsule when you install the Hermes integration in the Capsule portal (Integrations → Hermes).

Optional config

Key Default Description
block_on_risk true Apply server block verdicts. Set to false to run the plugin in observe-only mode.
fail_open true Allow the event through if Capsule is unreachable or returns a non-2xx response. Set to false to fail closed.
timeout_ms 5000 Per-request HTTP timeout in milliseconds.

Hooks covered

The plugin registers handlers for the Hermes runtime hooks Capsule supports:

  • Blocking: pre_tool_call, pre_llm_call, pre_gateway_dispatch, pre_approval_request
  • Observation: post_tool_call, post_llm_call, post_approval_response, subagent_stop, on_session_start, on_session_end, on_session_finalize, on_session_reset

Blocking hooks await Capsule's verdict and return {"action": "block", "message": ...} to Hermes when the server denies the action. Observation hooks dispatch fire-and-forget so telemetry never stalls the agent.

License

Apache-2.0.

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

capsule_hermes-0.4.1.tar.gz (8.7 kB view details)

Uploaded Source

Built Distribution

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

capsule_hermes-0.4.1-py3-none-any.whl (9.7 kB view details)

Uploaded Python 3

File details

Details for the file capsule_hermes-0.4.1.tar.gz.

File metadata

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

File hashes

Hashes for capsule_hermes-0.4.1.tar.gz
Algorithm Hash digest
SHA256 47d30784b4f33e0062a81e986e1667fb32bdc5d4ffb983ce090a7c6d827cb924
MD5 1089766d5695340c56adecff50ed1694
BLAKE2b-256 4c7ef307c89679a308c2bbeb35313f9ea9134a8b1d4c3ae291cceaf4e58d26b9

See more details on using hashes here.

File details

Details for the file capsule_hermes-0.4.1-py3-none-any.whl.

File metadata

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

File hashes

Hashes for capsule_hermes-0.4.1-py3-none-any.whl
Algorithm Hash digest
SHA256 7f48c189f2af88f9955c927fa6b62bdfed6e5161b537e174ae8e6eea6d5b9a28
MD5 029ba653d7c42f72d49fca3e61358fa2
BLAKE2b-256 640e29c7165d11af1f5fabed93724fd9642d9350628257c82bb847c998bebd66

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