SynapSynapDocs
Hub REST API

Profiles

The Profiles operations of the Hub REST API (6 operations).

For BuildersOpen-source podSynap CloudGenerated from Synap-core/backend@c31e261ab (main)

List entity profiles

GET
/profiles

Authorization

bearerAuth
headerAuthorizationBearer <API key>

Pod API key (Bearer) issued via /api/hub/setup/agent or pod admin tooling. Browser/web clients may use the X-Session-Token header instead. See GET /api/hub/auth/status to introspect the calling key.

Query Parameters

userId*string
workspaceId*string
detail?"full"

Pass detail=full to receive the complete profile row including renderer/hint columns. Omit for the lightweight digest (default).

Value in"full"

Response Body

Array of profiles. Default: lightweight digest (id, slug, displayName, entityScope, scope, description, icon, profileKind, applicableKinds). scope = visibility (who can use the type); entityScope = placement (where its entities live). Pass ?detail=full for the complete row.

application/json
  1. response
[index: integer]?
Example Request
curl -X GET 'https://pod.example.com/api/hub/profiles?userId=string&workspaceId=string'
Example Response
[  {    "id": "string",    "slug": "string",    "displayName": "string",    "entityScope": "pod",    "scope": "system",    "description": "string",    "icon": "string",    "profileKind": "kind",    "applicableKinds": [      "string"    ]  }]

Define a kind or a role

POST
/profiles

Authorization

bearerAuth
headerAuthorizationBearer <API key>

Pod API key (Bearer) issued via /api/hub/setup/agent or pod admin tooling. Browser/web clients may use the X-Session-Token header instead. See GET /api/hub/auth/status to introspect the calling key.

Request Body

application/json
  1. body
userId*string
workspaceId*string
slug*string

Stable lower-kebab profile identifier.

displayName*string
description?string
defaultValues?
parentProfileId?string

Parent profile to inherit properties from.

uiHints?
reasoning?string
agentUserId?string
sourceMessageId?string
profileKind?string

'kind' (default) = a primary entity type; 'role' = an attachable facet type (client, sponsor…).

Value in"kind""role"
applicableKinds?array<string>

For a role: base-kind slugs it attaches to. Omitted → company, person.

roleCategory?string

For a role: category key clustering related roles.

entityScope?string

Where entities of this type live. Omit to let the pod decide (kind → pod, role → workspace).

Value in"pod""workspace"
icon?string
fields?array<>

Field definitions ({ slug, valueType, displayName?, required?, defaultValue?, constraints?, uiHints?, displayOrder?, overlay? }). Added once the profile exists; deferred while it is proposed. Each field reports its own result.

Response Body

Created profile

application/json
  1. response
id*string
slug*string
displayName*string
description?string|null
parentProfileId?string|null
entityScope?string
Value in"pod""workspace"
scope?|

Visibility — who can use this profile type. Distinct from entityScope (placement).

Value in"system""shared""workspace""user"null
workspaceId?string|null
defaultValues?
uiHints?
icon?string|null
color?string|null
profileKind?string

kind = primary entity type; role = attachable facet on an existing entity.

Value in"kind""role"
applicableKinds?array<string>|

For role profiles, the primary-kind slugs this facet may attach to.

createdAt?string|
updatedAt?string|
Example Request
curl -X POST 'https://pod.example.com/api/hub/profiles' \  -H 'Content-Type: application/json' \  -d '{  "userId": "string",  "workspaceId": "string",  "slug": "string",  "displayName": "string"}'
Example Response
{  "id": "string",  "slug": "string",  "displayName": "string",  "description": "string",  "parentProfileId": "string",  "entityScope": "pod",  "scope": "system",  "workspaceId": "string",  "defaultValues": {    "property1": null,    "property2": null  },  "uiHints": {    "property1": null,    "property2": null  },  "icon": "string",  "color": "string",  "profileKind": "kind",  "applicableKinds": [    "string"  ],  "createdAt": "string",  "updatedAt": "string"}
GET
/property-defs

Authorization

bearerAuth
headerAuthorizationBearer <API key>

Pod API key (Bearer) issued via /api/hub/setup/agent or pod admin tooling. Browser/web clients may use the X-Session-Token header instead. See GET /api/hub/auth/status to introspect the calling key.

Query Parameters

userId*string
workspaceId*string
profileId?string

Filter to defs attached to a specific profile.

Response Body

Array of property definitions

application/json
  1. response
[index: integer]?
Example Request
curl -X GET 'https://pod.example.com/api/hub/property-defs?userId=string&workspaceId=string'
Example Response
[  {    "id": "string",    "profileId": "string",    "workspaceId": "string",    "slug": "string",    "valueType": "string",    "constraints": {      "property1": null,      "property2": null    },    "uiHints": {      "property1": null,      "property2": null    },    "createdAt": "string"  }]
POST
/property-defs

Authorization

bearerAuth
headerAuthorizationBearer <API key>

Pod API key (Bearer) issued via /api/hub/setup/agent or pod admin tooling. Browser/web clients may use the X-Session-Token header instead. See GET /api/hub/auth/status to introspect the calling key.

Request Body

application/json
  1. body
userId*string
workspaceId*string
profileId?string
slug*string
valueType*string

Logical type — e.g. text, number, date, boolean, select, multi_select, relation.

constraints?
uiHints?
agentUserId?string
sourceMessageId?string
overlay?boolean

When true, create a workspace-scoped overlay def invisible to other workspaces using the same profile. Defaults to false (base def).

Response Body

Created property def

application/json
  1. response
id*string
profileId?string|null
workspaceId?string|null
slug*string
valueType*string
constraints?
uiHints?
createdAt?string|
Example Request
curl -X POST 'https://pod.example.com/api/hub/property-defs' \  -H 'Content-Type: application/json' \  -d '{  "userId": "string",  "workspaceId": "string",  "slug": "string",  "valueType": "string"}'
Example Response
{  "id": "string",  "profileId": "string",  "workspaceId": "string",  "slug": "string",  "valueType": "string",  "constraints": {    "property1": null,    "property2": null  },  "uiHints": {    "property1": null,    "property2": null  },  "createdAt": "string"}
PATCH
/property-defs/{id}

Authorization

bearerAuth
headerAuthorizationBearer <API key>

Pod API key (Bearer) issued via /api/hub/setup/agent or pod admin tooling. Browser/web clients may use the X-Session-Token header instead. See GET /api/hub/auth/status to introspect the calling key.

Request Body

application/json
  1. body
userId*string
workspaceId*string
slug?string

Rename. Normalised to kebab-case by the one slugifier.

valueType?string
constraints?
uiHints?
agentUserId?string
sourceMessageId?string
reasoning?string

Response Body

Updated property def

application/json
  1. response
id*string
profileId?string|null
workspaceId?string|null
slug*string
valueType*string
constraints?
uiHints?
createdAt?string|
Example Request
curl -X PATCH 'https://pod.example.com/api/hub/property-defs/{id}' \  -H 'Content-Type: application/json' \  -d '{  "userId": "string",  "workspaceId": "string"}'
Example Response
{  "id": "string",  "profileId": "string",  "workspaceId": "string",  "slug": "string",  "valueType": "string",  "constraints": {    "property1": null,    "property2": null  },  "uiHints": {    "property1": null,    "property2": null  },  "createdAt": "string"}
GET
/profiles/{slug}/renderers

Authorization

bearerAuth
headerAuthorizationBearer <API key>

Pod API key (Bearer) issued via /api/hub/setup/agent or pod admin tooling. Browser/web clients may use the X-Session-Token header instead. See GET /api/hub/auth/status to introspect the calling key.

Query Parameters

userId*string
workspaceId*string
Formatuuid
contentKind?string
Value in"entity-detail""entity-card""entity-profile""collection"
slot?string

Deprecated alias: list → entity-profile, detail → entity-detail, dashboard → collection.

Value in"list""detail""dashboard"

Response Body

ContentKind-keyed renderer map. Unrequested kinds are null when contentKind is supplied.

application/json
  1. response
entity-detail*|null
entity-profile*|null
collection*|null
userChoice*|

The caller's explicit choice for entity-detail: 'source' (open in the source app), 'synap' (render in Synap, including after unbinding), null (never chose).

Value in"source""synap"null
Example Request
curl -X GET 'https://pod.example.com/api/hub/profiles/{slug}/renderers?userId=string&workspaceId=497f6eca-6276-4993-bfeb-53cbbbba6f08'
Example Response
{  "entity-detail": {    "property1": null,    "property2": null  },  "entity-profile": {    "property1": null,    "property2": null  },  "collection": {    "property1": null,    "property2": null  },  "userChoice": "source"}