Hyperstruck
Platform

Access control (FGA and RBAC)

How Hyperstruck combines API key scopes, organization roles, and fine-grained authorization to control who can read, run, and curate agents and learnings.

In one line

Every request passes two gates: a scope check (what the caller is allowed to do in general) and a fine-grained access check (whether they may touch this specific agent or space). Both must pass.

Hyperstruck uses a Zanzibar-style authorization model — the same family of design Google uses for consistent, relationship-based access at scale — on top of tenant-scoped API key scopes and portal membership roles. This page is the permissions reference for tenant-facing APIs. Platform-admin scopes and internal admin endpoints are out of scope here.

Two layers, one decision

LayerWhat it checksWho it applies to
ScopesCoarse capability (agents:read, claims:curate, …)API keys and portal sessions
Fine-grained accessObject-level permission on a specific agent or spaceEvery authenticated caller

A caller needs the right scope and the right object-level permission. For example, dispatching a goal requires agents:execute and execute access to that agent. Listing agents requires agents:read and returns only agents in spaces the caller can view.

Portal sessions never carry client-supplied scopes. The backend derives scopes from the user's organization membership role (owner, admin, developer, or viewer).

Organization roles

Roles sync from your identity provider into the tenant organization. Higher roles inherit lower ones.

RoleInheritsTypical use
owneradmin, developer, viewerFull tenant administration
admindeveloper, viewerManage credentials, API keys, and org-wide settings
developerviewerBuild and run agents, curate claims
viewerRead-only access to agents, runs, learnings, and usage

Org admins and owners reach every agent in the tenant. Developers and viewers only reach agents and spaces where they hold an explicit relationship.

Portal role → API scopes

These scopes apply to dashboard sessions. API keys use the grantable scope list in the next section instead.

RoleScopes
vieweragents:read, usage:read, apikeys:read, claims:read
developeragents:write, credentials:read, usage:read, apikeys:read, claims:read, claims:curate
adminagents:write, credentials:write, usage:read, apikeys:read, apikeys:write, claims:read, claims:curate, claims:erase
ownerSame as admin today

agents:write implies agents:execute and agents:read. claims:curate and claims:erase do not imply each other or any agents:* scope.

Spaces and kinds

A space is the permissions container for shared learnings. Every agent has exactly one home space — the space where its learnings are born and where stewardship is anchored. Spaces are flexible: use them to group agents and learnings by department, workload, product area, or individual ownership. There is no fixed org chart you must follow.

Learning recall and agent inventory are filtered to spaces the caller can view. When you create an agent, you pick a home space you can publish to (defaults to commons).

Space roles

Each space has explicit roles that control who can read, publish, or run agents homed there.

RoleGranted toEffect
stewardExplicit user, or org adminFull space stewardship
contributorUser, department member, or API key with write reachCan publish agents and learnings to the space
subscriberSame principals as contributorRead-only access to the space
executorAPI keys with execute reachCan run agents homed in the space

Stewards and contributors can publish. Subscribers can view content in the space but cannot publish or run agents unless they also hold a separate grant.

Space kinds

KindWhat it is forDefault accessExample
commonsOrg-wide default homeEvery org member is a contributorGeneral-purpose agents, shared operational knowledge
personalPer-user private spaceCreator is stewardA developer's experimental agent they administer alone
departmentTeam-scoped spaceDepartment members are contributorsEngineering team's incident-response agents, synced from your directory group
domainCurated org containerOrg admins steward"HR knowledge base" or "Sales playbooks" — flexible naming, admin-curated

Practical patterns

  • Department workloads — Create department spaces for each team. Home team agents there so learnings stay team-scoped. Give the team an API key limited to those space IDs for CI or automation.
  • Personal sandboxes — Home experimental agents in a personal space. The creator is steward and can administer without granting org-wide access.
  • Domain curation — Use domain spaces for cross-cutting knowledge bases (compliance, onboarding, product specs). Org admins steward; contributors publish approved agents.
  • Commons for shared defaults — Agents without an explicit home land in commons. Viewer read-only enforcement is the scope gate (agents:read without agents:write).

List spaces with GET /spaces (scope: agents:read). Results include only spaces you can view.

API key scopes

API keys carry explicit scopes stored on the key. Space reach on the key determines which spaces the key can access.

Grantable scopes

These scopes can be assigned to programmatic API keys:

ScopeMeaning
agents:readRead agents, runs, sessions, learnings, plans, and spaces
agents:writeCreate and update agents; store and reinforce learnings
agents:executeDispatch goals and resume suspended runs
credentials:readList and view provider credentials
credentials:writeCreate, update, and delete provider credentials
claims:readRead claim curation data
claims:curatePromote, adopt, or correct claims
claims:eraseIrreversible claim erasure
usage:readTenant usage and billing summary

Portal-only scopes (apikeys:read, apikeys:write) are never grantable on API keys.

Scope implications

Only the agents:* family has an implication ladder:

agents:write  ⇒  agents:execute  ⇒  agents:read

claims:* scopes are flat — nothing implies claims:curate or claims:erase.

Separation of duty

A single API key cannot combine dispatch scopes with curation scopes:

  • Dispatch: agents:execute, agents:write
  • Curation: claims:curate, claims:erase

Agent runtimes replay the scopes of the key that dispatched them. Combining dispatch and curation would let an agent approve content it ingested. Issue separate keys for running agents and for curating claims.

API key space reach

When creating a key, choose space reach:

ModeAccess reachWhen to use
All spacesOrg-wide read, execute, or write tierPlatform integrations, org-wide automation
Selected spaces (up to 25)Per-space access by tierTeam CI keys, department-scoped automation

Key tiers map to space roles:

TierSpace roleCan dispatch runsCan curate learnings
readsubscriberNoNo
executeexecutorYes (with agents:execute)No
writecontributor + executorYes (with agents:execute or agents:write)Yes (with agents:write)

API keys operate through space reach and optional per-agent operator grants. Human stewards and org admins administer agent configuration directly; keys do not receive admin or write access to agent configuration on their own.

Agent access

Agents split home (where learnings live) from use (who can run the agent). Every agent is homed in exactly one space.

  • Read — View agent config, runs, sessions, and learnings.
  • Execute — Dispatch goals and resume runs.
  • Write — Update agent configuration.
  • Admin — Delete agent, change home space, grant operators.
  • Curate — Store, reinforce, and curate learnings and claims.

A home-space subscriber can read an agent but cannot execute it unless they are also an operator. Visibility in a space does not grant run access.

Permissions matrix

By action

ActionRequired scopeRequired access
List agents / spacesagents:readView on readable spaces
Create agentagents:writePublish on target home space
Get agent / list runsagents:readRead on agent
Update agentagents:writeWrite on agent
Delete agentagents:writeAdmin on agent
Dispatch goalagents:executeExecute on agent
Resume runagents:executeExecute on agent
Read learningsagents:readRead on agent
Store / reinforce learningagents:writeCurate on agent
Delete all learningsagents:writeAdmin on agent
Read claimsclaims:readRead on agent
Curate claimsclaims:curateCurate on agent
Erase claimsclaims:eraseAdmin on agent
Read credentialscredentials:readOrg developer+ or API key
Write credentialscredentials:writeOrg admin+ or API key
Usage summaryusage:readTenant-scoped
MCP resolveagents:readValid active API key
MCP complete_runagents:writeValid active API key

Org role reach (no explicit space grant)

PrincipalOrg adminSpace stewardAgent executeAgent admin
OwnerYesYesYesYes
AdminYesYesYesYes
Developer (no operator)NoNoNoNo
ViewerNoNoNoNo

Developers need an explicit operator grant, home-space stewardship, or a matching API key to run an agent.

Home visibility vs agent use

PrincipalReadExecute
Home-space subscriber (not operator)YesNo
OperatorYesYes

Curation vs configuration

PrincipalCurateWrite (config)
Org-wide write keyYesNo
Home-space contributor keyYes (agents in space)No
Execute-tier keyNoNo
Org adminYesYes
Home-space stewardYesYes

MCP access

The hosted MCP server reuses tenant API key scopes — there is no separate MCP scope namespace.

GateRequirement
Transport (connect)Active key with agents:read or agents:write
resolve toolagents:read
complete_run toolagents:write

For end-to-end MCP usage (resolve before a task, complete after), issue a key with both scopes or use agents:write (which implies read). Space reach on the key applies the same way as REST calls.

See MCP server for connection setup.