Skip to content

docs(policies): add multi-approver across-tags example with per-tag m… - #746

Open
am-hernandez wants to merge 1 commit into
mainfrom
am/CUS-233/add-policy-example-to-access-control-docs
Open

docs(policies): add multi-approver across-tags example with per-tag m…#746
am-hernandez wants to merge 1 commit into
mainfrom
am/CUS-233/add-policy-example-to-access-control-docs

Conversation

@am-hernandez

Copy link
Copy Markdown
Contributor

What

Adds Access control policy example for multi-approvers.

Closes CUS-233

@mintlify

mintlify Bot commented Jul 28, 2026

Copy link
Copy Markdown
Contributor

Preview deployment for your docs. Learn more about Mintlify Previews.

Project Status Preview Updated (UTC)
turnkey-docs 🟢 Ready View Preview Jul 28, 2026, 3:30 AM

💡 Tip: Enable Workflows to automatically generate PRs for you.


#### Require multiple approvers across tags, with per-tag minimums

This policy allows the activity only when every approver holds at least one of three tags, with **at least 1** approver from Tag A and **at least 2** approvers from Tag B or Tag C. The leading `approvers.any(...)` establishes the eligible voter set (Tag A, B, or C), and the `approvers.filter(...).count()` clauses enforce each minimum.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I feel that we're colliding multiple concepts with the 3 tag example - perhaps we should stick to only 2 ?
And also use practical tags ex:

Require at least 1 approver tagged <SECURITY_TAG_ID> and at least 2 approvers tagged <OPS_TAG_ID> to change policies.

{
  "policyName": "Require 1 security + 2 ops approvers for policy changes",
  "effect": "EFFECT_ALLOW",
  "consensus": "approvers.any(user, user.tags.contains('<SECURITY_TAG_ID>') || user.tags.contains('<OPS_TAG_ID>')) && (approvers.filter(user, user.tags.contains('<SECURITY_TAG_ID>')).count() >= 1 && approvers.filter(user, user.tags.contains('<OPS_TAG_ID>')).count() >= 2)",
  "condition": "activity.resource == 'POLICY' && (activity.action == 'CREATE' || activity.action == 'UPDATE' || activity.action == 'DELETE')"
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants