Bind a group of the identity provider to a named policy

People only, with a fresh second factor.

POST/v1/group-policies

Not available yet Pod's API does not answer this call yet.

People only, with a fresh second factor. The rules of the policy are added to the own table of every sandbox in this project made by a person in the group, cut to the ceiling as a sandbox's own rules are; a rule that reaches another policy domain is cut. Every such sandbox is compiled before the answer, and one that would not pass refuses the binding (invalid, naming it). Name the group by its id, or, for a directory of sign-in tokens, by the name the identity provider writes in the groups claim (the group is made if no one in it has signed in yet). At most 100 group bindings a project.

For people only: a signed-in person with a fresh second factor makes this call, from the dashboard. Any API key is refused with person_required.

Request

curl -X POST "https://api.pod.mapier.ai/v1/group-policies?project=example" \
  -H "Authorization: Bearer $POD_PERSON_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"policy":"example"}'

Parameters

NameInTypeRequiredWhat it is
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

Name the group by group or by group_name, exactly one.

FieldTypeRequiredWhat it is
groupstringNoA group of the organization's directory.
group_namestringNo
policystringYes

Answer

201. The group binding, and how many sandboxes were compiled with it.

201
{
  "group_policy": {
    "id": "example",
    "group": "example",
    "group_name": "example",
    "policy": "example",
    "created_at": "2026-11-23T12:00:00.000Z",
    "created_by": "example"
  },
  "sandboxes": 0,
  "tables": 0
}
FieldTypeAlwaysWhat it is
group_policyGroupPolicyYes
sandboxesintegerYesSandboxes compiled with the binding. At least 0.
tablesintegerYesNew tables queued for the publisher. At least 0.

Errors

The refusals this call is known for: invalid, unauthorized, person_required, 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.