Add rules for one sandbox, beneath the ceiling

Adds rules at the sandbox layer: they are added to the policy the sandbox runs under, and cut to the ceiling, the project's and the organization's policies.

POST/v1/bindings/{sandbox_id}/rules

Adds rules at the sandbox layer: they are added to the policy the sandbox runs under, and cut to the ceiling, the project's and the organization's policies. A rule cut is listed in cut and not stored. Mounting a folder through Pod's API calls this with a read or write rule. A rule can never share a folder with another policy domain or message one; only a person writes those, into a stored policy (invalid).

A key with the permissions:write scope.

Request

curl -X POST "https://api.pod.mapier.ai/v1/bindings/example/rules?project=example" \
  -H "Authorization: Bearer $POD_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"rules":"example","base_version":1}'

Parameters

NameInTypeRequiredWhat it is
sandbox_idpathstringYes
projectquerystringYesThe project the call is about. Every route is scoped to one.
Pod-OrganisationheaderstringNoThe organization, for a person who belongs to several. An API key's organization is its own, and a different one here is forbidden.
Idempotency-KeyheaderstringNoMakes a repeat of this call safe for 24 hours.

Body

FieldTypeRequiredWhat it is
rulesstringYesRules in the simple form, one a line: a verdict, an action and a thing (Allow net api.github.com GET /repos/*). At most 1,000 rules a policy.
base_versionintegerYesAt least 1.

Answer

200. The binding at its new version, and what was cut to the ceiling.

200
{
  "binding": {
    "sandbox": "example",
    "policy": null,
    "sandbox_rules": "example",
    "version": 1,
    "table_hash": null,
    "applied_version": null,
    "parent": null,
    "bound_at": "2026-11-23T12:00:00.000Z",
    "updated_at": "2026-11-23T12:00:00.000Z",
    "updated_by": "example",
    "person": null,
    "groups": [
      {
        "group_policy": "example",
        "group": "example",
        "group_name": "example",
        "policy": "example"
      }
    ],
    "matter": null,
    "cleared": null
  },
  "cut": [
    {
      "line": 1,
      "rule": "example",
      "reason": "example",
      "group": {
        "group_policy": "example",
        "group": "example",
        "group_name": "example",
        "policy": "example"
      },
      "matter": "example",
      "wall": false
    }
  ]
}
FieldTypeAlwaysWhat it is
bindingBindingYesThe policy one sandbox runs under, and its rules for that sandbox alone.
cutCutRule[]Yes

Errors

The refusals this call is known for: invalid, unauthorized, forbidden, not_found, conflict. Any call can also answer unauthorized, rate_limited, unavailable or internal; the error list says what each means and when to send the call again.