See Stacksync in action with a solution architect. Book a demo ↗
Genies

Genies

Create a genie

POST
/v1/workspaces/{workspace_id}/genies

The configuration's defaults are the web app's (every tool on); the description is written by Stacksync from the instructions. Send a configuration made by the genies setup wizard (genies.stacksync.com .../genies/wizard/generate-config) after filling the connection of each skill.

Authorization

Authorizationstringheaderrequired

Bearer <key>, where <key> is a workspace API key or a user API key. See Authentication.

Path Parameters

workspace_id*integer

The workspace. List the ones your key can reach with GET /v1/workspaces.

Query Parameters

region*Regions

Region of the genie: besg (Europe) or usnv (United States)

Value in"besg""usnv"

Header Parameters

Idempotency-Key?|

Makes the create retry-safe for 24 hours: a retry with the same key answers the resource the first call created, with the Idempotent-Replayed: true header, and creates nothing. 1 to 255 visible ASCII characters. The same key with a different request answers 422; while the first call still runs, 409.

Defaultnull

Request Body

application/json
  1. body
name*Name

Unique among the workspace's genies of the region

Length1 <= length <= 255
folder_id?|

The folder to create it in; the root when absent

Defaultnull
is_shared_with_workspace?Is Shared With Workspace

Whether every member of the workspace sees it

Defaulttrue
genie_config?
knowledge_bases?array<>
validate_only?Validate Only

Run every check of the write and answer 204 without writing: a refused write answers the error the write would

Defaultfalse

Response Body

Created

application/json
  1. response
genie_id*Genie Id
name*Name
region*Regions
Value in"besg""usnv"
folder_id?|
Defaultnull
status?|
Defaultnull
public_access_rights?|
Defaultnull
is_shared_with_workspace?|
Defaultnull
has_api_key*Has Api Key

Whether an LLM API key of yours is stored (the key itself is never returned)

genie_config*

What the genie does and how: its instructions, channels, skills, resources and tools

knowledge_bases*array<>
created_time?|
Defaultnull
last_modified_time?|
Defaultnull
Create a genie
curl -X POST 'https://api.stacksync.com/v1/workspaces/0/genies?region=besg' \  -H 'Content-Type: application/json' \  -d '{  "name": "<name>"}'
{  "genie_id": "<genie_id>",  "name": "<name>",  "region": "besg",  "folder_id": "<folder_id>",  "status": "<status>",  "public_access_rights": "<public_access_rights>",  "is_shared_with_workspace": false,  "has_api_key": false,  "genie_config": {    "master_prompt": "",    "description": "",    "model": "",    "interfaces": [      {        "id": "<id>",        "type": "<type>",        "details": "<details>",        "connection_id": "",        "connection_resource_id": ""      }    ],    "skills": [      {        "id": "<id>",        "name": "<name>",        "description": "",        "type": "Module",        "enabled": true,        "connection": "<connection>",        "connection_resource_id": "<connection_resource_id>",        "approval_policy": "always_allow"      }    ],    "app_descriptions": {},    "resources": [      {        "name": "<name>",        "type": "connection",        "value": "<value>",        "instructions": ""      }    ],    "teams": [      {        "id": "<id>",        "name": "<name>"      }    ],    "contacts": [      {        "id": "<id>",        "name": "<name>",        "email": "<email>"      }    ],    "tools": {      "web_search": true,      "execute_browser": true,      "api_call": true,      "code_execution": true,      "stacksync_ocr": true,      "modify_scheduled_task": true    }  },  "knowledge_bases": [    {      "knowledge_base_id": "3f6c1d2e-8a4b-4c7d-9e21-5b6f7a8c9d01",      "instructions": ""    }  ],  "created_time": "2027-01-15T09:00:00Z",  "last_modified_time": "2027-01-15T09:00:00Z"}