FruxonDocs
AgentsCollaborators

Adds or updates a collaborator's access to an agent.

Grants the given user the specified role on this agent, or upgrades/downgrades their existing role. Requires Admin on the agent; admins cannot demote the last remaining Admin. Roles map to capabilities as: Viewer (read only), Editor (read + edit draft + deploy revisions), Admin (everything including managing collaborators, budgets, and deletion). To remove access entirely use `DELETE /v1/tenants/{tenant}/agents/{agent}/collaborators/{user}`.

PUT
/v1/tenants/{tenant}/agents/{agent}/collaborators
AuthorizationBearer <token>

JWT Authorization header using the Bearer scheme. Enter 'Bearer' [space] and then your token.

In: header

Path Parameters

agent*string

The agent ID.

tenant*string

The tenant identifier

The collaborator details.

userId*string|null

The FruxonUser ID to grant access to.

role?string

Defines the access level a collaborator has for an agent. Wire form is UPPER_SNAKE per project convention; Unspecified = 0 is the AIP-126 zero-sentinel.

Value in"UNSPECIFIED" | "VIEWER" | "EDITOR" | "ADMIN"
alertPreferences?

Per-collaborator alert preferences stored as JSONB on AgentCollaborator: for each Fruxon.Model.Agents.AlertType, the set of Fruxon.Model.Agents.AlertChannels the collaborator wants that alert delivered on. An empty channel list means the alert type is muted; an absent entry falls back to the registry default, so an alert type added after a collaborator last saved their preferences still reaches them.

To add a new alert type, add an Fruxon.Model.Agents.AlertType value and register a descriptor in Fruxon.Model.Agents.AlertTypeRegistry. To add a new channel, add an Fruxon.Model.Agents.AlertChannel value and a descriptor in Fruxon.Model.Agents.AlertChannelRegistry.

[key: string]?never

Response Body

curl -X PUT "https://api.fruxon.com/v1/tenants/string/agents/string/collaborators" \  -H "Content-Type: application/json" \  -d '{    "userId": "string"  }'
{
  "agentId": "string",
  "userId": "string",
  "role": "VIEWER",
  "status": "PENDING",
  "alertPreferences": {
    "channels": {}
  },
  "createdAt": 0,
  "modifiedAt": 0,
  "tenantId": "00000000-0000-0000-0000-000000000000"
}
Empty
Empty
Empty
Empty