Skip to main content
PUT
/
v1
/
orgs
/
{org_id}
/
knowledge
/
collections
/
{collection_id}
/
agents
Set Collection Agents
curl --request PUT \
  --url https://api.letpiper.com/v1/orgs/{org_id}/knowledge/collections/{collection_id}/agents \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "agentIds": [
    "3c90c3cc-0d44-4b50-8888-8dd25736052a"
  ]
}
'
{
  "accessMode": "all",
  "agentIds": [
    "3c90c3cc-0d44-4b50-8888-8dd25736052a"
  ]
}

Authorizations

Authorization
string
header
required

Platform token (starts with pat_)

Path Parameters

org_id
string<uuid>
required
collection_id
string<uuid>
required

Body

application/json

Request to set which agents can access a collection.

agentIds
string<uuid>[]
required

List of agent IDs that should have access. Empty list means no agents have access.

Response

Successful Response

Response showing which agents can access a collection.

accessMode
enum<string>
required

Whether all agents have access or only specific ones

Available options:
all,
specific
agentIds
string<uuid>[] | null

List of agent IDs with access (only present when access_mode is 'specific')