Policy pack

Hosted gateway (HTTP)

Requests through a hosted gateway, by method and path: hold or block a POST, PUT, PATCH or DELETE before it reaches your API.

Key
hosted_gateway_http
Version
hosted-gateway-http-v1
Rules
3
Domain
OPERATIONS

Rules, in the order the evaluator tries them

Highest priority first. The first rule whose conditions all hold decides; with none, the decision is a REVIEW.

  1. Delete on an admin or internal path

    priority 100

    hosted_gateway_admin_delete · *

    When
    • transaction_type matches "^[a-z][a-z0-9._:-]*$"
    • agent_safe.action.parameters.method = "DELETE"
    • agent_safe.action.parameters.path matches "^/(admin|internal)/"
    Then

    AUTO_REJECT → REJECT · urgent

    A DELETE on an /admin/ or /internal/ path is blocked before it reaches the API.

  2. Retry of a request whose outcome is unknown

    priority 90

    hosted_gateway_retry_of_indeterminate · *

    When
    • agent_safe.retry_of_indeterminate = true
    Then

    ESCALATE → ESCALATE

    The earlier attempt may already have reached the API. A person confirms before it runs again.

  3. Every other request

    priority 0

    hosted_gateway_allow · *

    When
      Then

      AUTO_APPROVE → APPROVE

      Requests no earlier rule holds or blocks go through.

    Evaluate under it

    Locally, with @decionis/mcp: the payload becomes the request's context, and its action the decision type. On the hosted protocol, once the bundle is stored for your organization, name vertical_pack, policy_version and require_exact_policy_version: true. @decionis/mcp 0.4.0 does not carry this pack: the hosted protocol decides a hosted gateway's requests under it.

    decionis_evaluate arguments

    { "policy_pack": "hosted_gateway_http", "payload": { "action": "<decision type>" } }

    In a hosted evaluate-decision request

    "vertical_pack": "hosted_gateway_http",
    "policy_version": "hosted-gateway-http-v1",
    "require_exact_policy_version": true

    What its rules read

    transaction_type is a field of the request itself, not of its context. A value put only in the context is discarded, and the evaluator holds the decision as an ESCALATE rather than decide without it. @decionis/mcp puts the whole payload in the context, so a payload that carries transaction_type is held.

    • agent_safe.action.parameters.method
    • agent_safe.action.parameters.path
    • agent_safe.retry_of_indeterminate
    • transaction_typerequest

    Signals it maps

    • decision_latency_msapp