allow list and an optional deny list. A
profile selects up to eight roles, and every agent on that
profile gets exactly that access, on top of the core tools
and any pack floor.
Selector grammar
Every selector is at most 176 bytes.tool:* is the only unqualified form;
every other selector names the tool’s owner:
Use
builtin for tools Matrices ships, managed for managed providers, and
workspace for toolsets your workspace registered.
A namespace is lowercase, starts with a letter or digit, and runs up to 32
characters of [a-z0-9_-]. Partial wildcards (tool:workspace:bill*),
unqualified selectors (tool:billing.*), bare names
(billing.lookup_invoice), and duplicates are rejected.
deny accepts only unconditioned built-in selectors: tool:builtin:*, one
built-in namespace, or one exact built-in tool. Conditional objects, tool:*,
level selectors, and managed or workspace selectors are rejected.
Levels
Every built-in tool a role can grant, and every managed tool, has a level:
Each built-in’s level is in the Level column of
Built-in tools. A level selector picks every tool
at or below its level, including tools that ship later. Only
read and
write have one: admin is spelled as a namespace or source
(tool:builtin:agents.*, tool:builtin:*), so every selection has exactly
one spelling.
- Levels exist for
builtinandmanagedonly. Workspace toolsets have none, sotool:workspace:billing@readis rejected. - A level selector takes no
whereand can’t appear indeny. - Providers whose tools run on a remote MCP server (
github,linear,notion,posthog,apollo) don’t level each tool. Every tool there counts aswrite, so@writeselects the whole namespace and@readselects none of it. - For
slackand the Google providers (gmail,calendar,drive,docs,sheets,slides), the highest level a role selects is also the ceiling for the connection tier. See Connection tiers.
Core tools and defaults
Core tools are always there:thread.list, thread.get, thread.create,
thread.send, thread.cancel, models.list, results.read, and wait. No
role can grant or deny them, so any selector inside the thread, models,
results, or wait namespaces is rejected, in allow or deny, with one
exception below. tool:builtin:* is fine; it just doesn’t reach them. See
Built-in tools.
thread.search is a default: every agent holds it as if an implicit role
granted it. It’s the one exact selector allowed inside a core namespace, so
tool:builtin:thread.search in deny takes it away (so does
tool:builtin:*).
Pack floors
A pack is platform-authored behavior a profile can carry. Setting up Slack putsslack-assistant on the profile it creates. Each pack has a floor: a few
exact tools every agent on that profile holds whatever its roles say. A deny
doesn’t remove a floor tool, and nobody can edit a floor.
A floor tool is still a managed tool, so it needs a
connection like any other.
Conditional allows
Anallow entry may be an object instead of a string:
where holds at most eight conditions and every one must match. The tool
can’t be a level selector. A path is one of two things:
input.<field>, evaluated against the tool input exactly as the model wrote it, before executor defaults. A field the model left out is missing, even if the tool would have filled it in.- A registered condition key, which Matrices resolves itself. Each one works only on the exact tools it lists.
An optional
quantifier of any or all applies the operator to each element
when path resolves to an array; all also needs the array to be non-empty.
exists and absent take no value and no quantifier. A missing path
never matches any other operator, negative ones included. There is no regex
and no type coercion.
One value is special. With path: "input.agentId" and eq or in, the string
"$self" stands for the calling agent’s ID:
agentId
to mean “me” doesn’t match, because the condition sees the input as written.
Stacking
Conditions narrow one grant; they never subtract from another. If a second role
on the same profile grants the same tool unconditionally, the call is allowed.
Denies only apply to built-in tools. Workspace and provider toolset namespaces
are controlled by positive allows alone.
Connection tiers
A managed provider’s connection may carry a tier. Roles decide which tools an agent may call; the tier decides which of them the login will serve.connections.connectrequiresaccessPreset(read_onlyorfull). For a provider with one tier, and for your own OAuth MCP toolsets, the value is ignored.- Asking for more than the ceiling fails. A role that selects only
readtools fromgmailcaps Gmail atread_only. - An agent’s connect only raises a tier: it never starts consent for a tier a ready connection already covers, and its consent never lowers the stored one.
- Slack’s default tier is
full. Both Slack tiers request the same OAuth scopes, so the tier is stored on the connection and the Slack tools enforce it. A role that selects onlytool:managed:slack@readstill caps it atread_only, unless the profile carriesslack-assistant: that pack’s floor,slack.post_message, is awritetool, so the ceiling isfull.
Attenuation
An agent usingroles.create, profiles.create, agents.create, or the
matching update tools can only produce something covered by its own live
authority. Every permission it writes must be covered by a permission it holds,
and roles.update may add denies but never remove them. tool:* does not
exempt an agent from this.
There is one asymmetry to watch for when an agent creates an agent with an
inline profile: omitting roleIds inherits the caller’s own profile roles,
so the child gets everything the parent had. Send roleIds: [] for a
tool-less child, or an explicit list for anything narrower. For an ordinary
API-key caller, omitting the field creates a profile with no roles at all.
Limits
Inspecting effective access
GET /v1/agents/{agentId}/effective-permissions resolves the agent’s profile
and roles right now and reports roles (each with its version), builtIns,
toolsets, and conditional grants. builtIns holds the exact role-controlled
built-ins, thread.search included; core tools are never listed. Level
selectors arrive expanded into the tools they select today.
GET /v1/agents/{agentId}/accounts reports, for each selected provider or
toolset that needs a login, whether a usable connection is behind it.