API Reference

Create Context Pack

Creating a new context pack requires a name, everything else is optional. The context pack will be created along with its first version, which becomes the context pack's primary version by default.

Endpoint
POST https://api.zatomic.ai/v1/context/packs

Endpoint Request

Request Properties
name
string
Name of the context pack.
description
string, optional
Description for the context pack.
sources
list of context source objects

Properties for the context source object:

context_source_id
string
The ID of the context source to include in the context pack.
version_id
string
The ID of the version of the context source to include in the context pack.
prompts
list of prompt objects, optional

Properties for the prompt object:

prompt_id
string
The ID of the prompt to include in the context pack.
version_id
string
The ID of the version of the prompt to include in the context pack.
version_name
string, optional
Name for the context pack version.
Request Body
{
   "name": "Context pack name",
   "description": "Context pack description.",
   "sources": [
      {
         "context_source_id": "Context source ID",
         "version_id": "Context source version ID"
      }
   ],
   "prompts": [
      {
         "prompt_id": "Prompt ID",
         "version_id": "Prompt version ID"
      }
   ],
   "version_name": "Context pack version name"
}

Endpoint Response

A successful call returns a 201 status code with a response that contains the context pack object.

HTTP Status Codes
201 Created The context pack was created.
400 Bad Request The context pack name was not provided in the request.
500 Internal Server Error Something went wrong on Zatomic's end.