Skip to main content
POST
/
context-documents
/
tree
/
{tree_id}
/
publish-tier
Publish a specific tier of a context document tree
curl --request POST \
  --url https://api.hyperspell.com/context-documents/tree/{tree_id}/publish-tier \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "tier": "<string>"
}
'
{
  "tree_id": "<string>",
  "status": "<string>",
  "version": 123,
  "files": [
    {
      "path": "<string>",
      "content": "<string>",
      "tier": "<string>",
      "team": "<string>",
      "updated_at": "<string>"
    }
  ],
  "error": "<string>",
  "created_at": "2023-11-07T05:31:56Z",
  "completed_at": "2023-11-07T05:31:56Z",
  "meta": {}
}

Authorizations

Authorization
string
header
required

API Key or JWT User Token. If using an API Key, set the X-As-User header to act as a specific user. A JWT User Token is always scoped to a specific user.

Path Parameters

tree_id
string
required

Body

application/json

Request body for per-tier publishing.

tier
string
required

Tier to publish: 'company', 'team', 'skills', or 'personal'

Response

Successful Response

tree_id
string
required
status
string
required
version
integer
required
files
TreeFile · object[] | null
required
error
string | null
required
created_at
string<date-time>
required
completed_at
string<date-time> | null
required
meta
Meta · object
required