GoodMemGoodMem
ReferenceSecurity

Operations and Selectors

Catalog of authorization operations, selectors, and the rule syntax accepted by grants, role capabilities, and API-key ceilings.

Operations and Selectors

Every unit of authority in GoodMem is a rule: one operation paired with one selector. Rules appear in three places — direct grants, the capabilities of built-in roles, and the permission ceilings of scoped API keys. This page catalogs the operations and selectors and the syntax for writing rules. For how the pieces combine into an authorization decision, see Roles, Grants, and Selectors.

Selectors

SelectorMeaningExample
ANYEvery resource the operation can apply to, regardless of owner.READ_SPACE:ANY — read every space.
OWNResources whose authorization owner is the subject.DELETE_SPACE:OWN — delete spaces you own.
EXACTExactly one named resource.READ_SPACE:EXACT:SPACE:<uuid> — read that space.
DIRECT_MEMBERS_OFDirect members of one named container, present and future.READ_MEMORY:DIRECT_MEMBERS_OF:SPACE:<uuid> — read every memory in that space.

DIRECT_MEMBERS_OF covers a container's members without covering the container itself. A rule on the direct members of space Y says nothing about Y, about another space's memories, or about resources Y merely references, such as its embedders.

Operations

Operation numbers are stable identifiers shared by the API, the database, and the server implementation. The resource kind is what the operation acts on: an EXACT rule names one resource of that kind, and a DIRECT_MEMBERS_OF rule names a container whose direct members are of that kind.

Users

Operation#AuthorizesResource kind
CREATE_USER101Create a human userUSER
READ_USER102Read a user recordUSER
UPDATE_USER103Update a user's profile or labelsUSER
DELETE_USER104Permanently soft-delete a userUSER
LIST_USER105Enumerate the user collectionINSTANCE
MANAGE_USER_ENROLLMENT106Create, read, list, rotate, or revoke a user's enrollment credentialUSER

MANAGE_USER_ENROLLMENT targets the user being enrolled. It can be granted only to a concrete principal, with the ANY or EXACT selector, and an EXACT grant must name a USER resource. Completing an enrollment is authenticated by the enrollment credential itself and does not evaluate this operation.

Service Identities

Operation#AuthorizesResource kind
CREATE_SERVICE_IDENTITY201Create a service identitySERVICE_IDENTITY
READ_SERVICE_IDENTITY202Read a service identitySERVICE_IDENTITY
UPDATE_SERVICE_IDENTITY203Update a service identity's profile or labelsSERVICE_IDENTITY
DELETE_SERVICE_IDENTITY204Permanently soft-delete a service identitySERVICE_IDENTITY
LIST_SERVICE_IDENTITY205Enumerate the service-identity collectionINSTANCE

Spaces

Operation#AuthorizesResource kind
CREATE_SPACE301Create a memory spaceSPACE
READ_SPACE302Read a spaceSPACE
UPDATE_SPACE303Update a spaceSPACE
DELETE_SPACE304Delete a spaceSPACE
LIST_SPACE305Enumerate the space catalogINSTANCE

API Keys

Operation#AuthorizesResource kind
CREATE_API_KEY401Issue an API keyAPI_KEY
READ_API_KEY402Read an API-key recordAPI_KEY
UPDATE_API_KEY403Update an API key's mutable metadataAPI_KEY
DELETE_API_KEY404Revoke an API keyAPI_KEY
LIST_API_KEY405Enumerate API-key recordsAPI_KEY

Embedders

Operation#AuthorizesResource kind
CREATE_EMBEDDER501Register an embedderEMBEDDER
READ_EMBEDDER502Read an embedder's configurationEMBEDDER
UPDATE_EMBEDDER503Update an embedderEMBEDDER
DELETE_EMBEDDER504Delete an embedderEMBEDDER
LIST_EMBEDDER505Enumerate the embedder catalogINSTANCE
PING_EMBEDDER506Health-check an embedder endpointEMBEDDER
EXECUTE_EMBEDDER507Run inference through an embedderEMBEDDER
READ_EMBEDDER_CREDENTIALS508Read an embedder's stored upstream credentialsEMBEDDER

Rerankers

Operation#AuthorizesResource kind
CREATE_RERANKER601Register a rerankerRERANKER
READ_RERANKER602Read a reranker's configurationRERANKER
UPDATE_RERANKER603Update a rerankerRERANKER
DELETE_RERANKER604Delete a rerankerRERANKER
LIST_RERANKER605Enumerate the reranker catalogINSTANCE
PING_RERANKER606Health-check a reranker endpointRERANKER
EXECUTE_RERANKER607Run inference through a rerankerRERANKER
READ_RERANKER_CREDENTIALS608Read a reranker's stored upstream credentialsRERANKER

LLMs

Operation#AuthorizesResource kind
CREATE_LLM701Register an LLMLLM
READ_LLM702Read an LLM's configurationLLM
UPDATE_LLM703Update an LLMLLM
DELETE_LLM704Delete an LLMLLM
LIST_LLM705Enumerate the LLM catalogINSTANCE
PING_LLM706Health-check an LLM endpointLLM
EXECUTE_LLM707Run inference through an LLMLLM
READ_LLM_CREDENTIALS708Read an LLM's stored upstream credentialsLLM

The READ_*_CREDENTIALS operations are separate from the ordinary READ_* operations. Reading a provider's configuration does not reveal its stored credentials, and direct grants cannot confer credential-read authority.

Inference

Operation#AuthorizesResource kind
PROXY_INFERENCE_TARGET801Proxy a request through an embedder, reranker, or LLMembedder, reranker, or LLM
OCR_DOCUMENT802Run the instance-level OCR utilityINSTANCE

Memories

Operation#AuthorizesResource kind
CREATE_MEMORY901Create a memoryMEMORY
READ_MEMORY902Read a memoryMEMORY
DELETE_MEMORY903Delete a memoryMEMORY
LIST_MEMORY904Search or enumerate a space's memory collectionSPACE

There is no UPDATE_MEMORY; a memory is deleted and recreated. LIST_MEMORY targets the space whose collection is searched, so an EXACT rule for it names a space. Semantic retrieval requires both LIST_MEMORY on each requested space and READ_MEMORY on the returned memories.

Extensions

Operation#AuthorizesResource kind
CREATE_EXTENSION1001Register an extensionEXTENSION
READ_EXTENSION1002Read an extensionEXTENSION
UPDATE_EXTENSION1003Update an extensionEXTENSION
DELETE_EXTENSION1004Delete an extensionEXTENSION
LIST_EXTENSION1005Enumerate the extension catalogINSTANCE
DOWNLOAD_EXTENSION1006Download an extension's artifactEXTENSION

Instance and Ownership

Operation#AuthorizesResource kind
READ_INSTANCE1101Read the singleton GoodMem instance recordINSTANCE
TRANSFER_INSTANCE_OWNERSHIP1102Transfer ownership of the instanceINSTANCE
TRANSFER_RESOURCE_OWNERSHIP1103Transfer ownership of an ordinary owned resourceany owned resource

The two transfer operations cannot appear in direct grants. Transfer authority comes from current ownership, from instance ownership, or — for ordinary resources — from the instance ADMIN role.

Server Administration

Operation#AuthorizesResource kind
RELOAD_LICENSE1401Reload the instance's license materialINSTANCE
DRAIN_SERVER1402Start a graceful drain of the serverINSTANCE
PURGE_BACKGROUND_JOBS1403Purge completed background jobsINSTANCE

RetrieveMemory Log Policies

Operation#AuthorizesResource kind
CREATE_RETRIEVE_MEMORY_LOG_POLICY1501Create a query-logging policyRETRIEVE_MEMORY_LOG_POLICY
READ_RETRIEVE_MEMORY_LOG_POLICY1502Read a query-logging policyRETRIEVE_MEMORY_LOG_POLICY
LIST_RETRIEVE_MEMORY_LOG_POLICY1503Enumerate query-logging policiesRETRIEVE_MEMORY_LOG_POLICY
DELETE_RETRIEVE_MEMORY_LOG_POLICY1504Delete a query-logging policyRETRIEVE_MEMORY_LOG_POLICY

See RetrieveMemory Query Logging for the policy model.

Access Administration

Operation#AuthorizesResource kind
MANAGE_ACCESS1601Read and change a resource's grants and role assignmentsany resource

The protected target is the resource whose policy changes rather than a grant or role-assignment row. Like MANAGE_USER_ENROLLMENT, this operation can be granted only to a concrete principal with the ANY or EXACT selector.

Rule Syntax

The CLI flags that accept whole rules — --ceiling on goodmem apikey create and --grant on goodmem service-identity onboard — use one colon-delimited grammar:

OPERATION:SELECTOR[:RESOURCE_KIND[:RESOURCE_UUID]]
  • ANY and OWN rules take exactly two segments. Adding a resource kind or UUID is an error.
  • EXACT and DIRECT_MEMBERS_OF rules require a resource-kind segment. The kind INSTANCE forbids a UUID segment; every other kind requires one.
  • Tokens are case-insensitive and accept kebab-case or underscores. The long enum prefixes (ACCESS_POLICY_OPERATION_, ACCESS_POLICY_SELECTOR_, ACCESS_POLICY_RESOURCE_KIND_) are optional. MEMORY_SPACE is accepted as an alias for SPACE.

Valid resource-kind tokens: INSTANCE, USER, SERVICE_IDENTITY, SPACE, API_KEY, EMBEDDER, RERANKER, LLM, MEMORY, EXTENSION, RETRIEVE_MEMORY_LOG_POLICY.

Examples:

READ_SPACE:ANY
CREATE_API_KEY:OWN
READ_SPACE:EXACT:SPACE:70e025f6-76ca-4cbe-b8fc-7dab8e84590a
READ_MEMORY:DIRECT_MEMBERS_OF:SPACE:70e025f6-76ca-4cbe-b8fc-7dab8e84590a
LIST_SPACE:EXACT:INSTANCE

The goodmem access-policy grant create and role-assignment assign commands take the same vocabulary as separate --operation, --selector, --resource-kind, and --resource-id flags.

Grant creation enforces a few shape rules on the server:

  • Grants to the all-authenticated audience require EXACT or DIRECT_MEMBERS_OF.
  • Direct grants cannot confer credential-read (READ_*_CREDENTIALS) or ownership-transfer authority.
  • MANAGE_ACCESS and MANAGE_USER_ENROLLMENT grants require a concrete principal audience and the ANY or EXACT selector.

Role capabilities are fixed in code; the per-role rule lists are in Built-in Roles.