Skip to main content

Notes API

Facade API Backend for Epilot Notes feature

Quick Startโ€‹

# List available operations
epilot notes

# Call an operation
epilot notes createNote

Common Flagsโ€‹

FlagDescription
-p key=valueSet a named parameter
-d '{...}'Request body JSON
-H 'Key: Value'Custom header
-t, --token <token>Bearer token for authentication
--profile <name>Use a named profile
-s, --server <url>Override server base URL
-i, --includeInclude response headers in output
--jsonOutput raw JSON (no formatting)
-v, --verboseVerbose output (show request details)
--jsonata <expr>JSONata expression to transform response
--definition <file>Override OpenAPI spec file/URL
--guidedPrompt for all parameters interactively
--no-interactiveDisable interactive prompts

Operationsโ€‹

Notes

  • createNote โ€” Creates a new Note entry
  • getNote โ€” Retrieves a single Note entry based on it's Entity ID
  • updateNote โ€” Updates an existing Note entry
  • patchNote โ€” Updates an existing Note entry
  • deleteNote โ€” Deletes a single Note entry based on it's Entity ID
  • searchNotesByContext โ€” Search for a paginated list of Notes based on one or more contexts
  • getNoteContexts โ€” Gets all the Entity and non-Entity records the Note is contextually attached to

Pinning

  • pinNote โ€” Pins a single Note entry based on it's Entity ID

Reactions

  • addNoteReaction โ€” Adds an emoji reaction to a note
  • removeNoteReaction โ€” Removes an emoji reaction from a note
  • toggleNoteReactions โ€” Toggles multiple emoji reactions on a note. If a user has already reacted with an emoji, it removes the reaction. If a u

createNoteโ€‹

Creates a new Note entry

POST /v1/note

Request Body

Sample Call

epilot notes createNote

With request body:

epilot notes createNote \
-d '{
"_tags": ["string"],
"type": "string",
"entity_id": "string",
"parent_id": "string",
"contexts": [
{
"type": "workflow_execution",
"id": "string"
}
],
"additional_contexts": [
{
"type": "workflow_execution",
"id": "string"
}
],
"content": "string",
"attachments": ["string"],
"read_by": ["string"]
}'

Using stdin pipe:

cat body.json | epilot notes createNote

With JSONata filter:

epilot notes createNote --jsonata 'context_entities'

getNoteโ€‹

Retrieves a single Note entry based on it's Entity ID

GET /v1/note/{id}

Parameters

NameInTypeRequiredDescription
idpathstringYesThe Entity ID of the Note entry to retrieve
hydratequerybooleanNoWhether to hydrate the Note's relation attributes

Sample Call

epilot notes getNote \
-p id=123e4567-e89b-12d3-a456-426614174000

Using positional args for path parameters:

epilot notes getNote 123e4567-e89b-12d3-a456-426614174000

With JSONata filter:

epilot notes getNote -p id=123e4567-e89b-12d3-a456-426614174000 --jsonata 'context_entities'

updateNoteโ€‹

Updates an existing Note entry

PUT /v1/note/{id}

Parameters

NameInTypeRequiredDescription
idpathstringYesThe Entity ID of the Note entry to update

Request Body

Sample Call

epilot notes updateNote \
-p id=123e4567-e89b-12d3-a456-426614174000

With request body:

epilot notes updateNote \
-p id=123e4567-e89b-12d3-a456-426614174000 \
-d '{
"_id": "string",
"_org": "string",
"_schema": "string",
"_created_at": "1970-01-01T00:00:00.000Z",
"_updated_at": "1970-01-01T00:00:00.000Z",
"_created_by": "string",
"_tags": ["string"],
"_acl": {},
"_owners": [
{
"org_id": "string",
"user_id": "string"
}
],
"type": "string",
"context_entities": {
"$relation": [
{
"entity_id": "string"
}
]
},
"parent": {
"$relation": [
{
"entity_id": "string"
}
]
},
"attachments": {
"$relation": [
{
"entity_id": "string"
}
]
},
"content": "string",
"contexts": [
{
"type": "workflow_execution",
"id": "string"
}
],
"pinned_at": "1970-01-01T00:00:00.000Z",
"created_by": {
"type": "user",
"user_id": "string",
"display_name": "string",
"org_id": "string",
"email": "string",
"phone": "string"
},
"read_by": ["string"],
"reactions": {}
}'

Using positional args for path parameters:

epilot notes updateNote 123e4567-e89b-12d3-a456-426614174000

Using stdin pipe:

cat body.json | epilot notes updateNote -p id=123e4567-e89b-12d3-a456-426614174000

With JSONata filter:

epilot notes updateNote -p id=123e4567-e89b-12d3-a456-426614174000 --jsonata 'context_entities'

patchNoteโ€‹

Updates an existing Note entry

PATCH /v1/note/{id}

Parameters

NameInTypeRequiredDescription
idpathstringYesThe Entity ID of the Note entry to update

Request Body

Sample Call

epilot notes patchNote \
-p id=123e4567-e89b-12d3-a456-426614174000

Using positional args for path parameters:

epilot notes patchNote 123e4567-e89b-12d3-a456-426614174000

Using stdin pipe:

cat body.json | epilot notes patchNote -p id=123e4567-e89b-12d3-a456-426614174000

With JSONata filter:

epilot notes patchNote -p id=123e4567-e89b-12d3-a456-426614174000 --jsonata 'context_entities'

deleteNoteโ€‹

Deletes a single Note entry based on it's Entity ID

DELETE /v1/note/{id}

Parameters

NameInTypeRequiredDescription
idpathstringYesThe Entity ID of the Note entry to delete

Sample Call

epilot notes deleteNote \
-p id=123e4567-e89b-12d3-a456-426614174000

Using positional args for path parameters:

epilot notes deleteNote 123e4567-e89b-12d3-a456-426614174000

With JSONata filter:

epilot notes deleteNote -p id=123e4567-e89b-12d3-a456-426614174000 --jsonata '$'

searchNotesByContextโ€‹

Search for a paginated list of Notes based on one or more contexts

POST /v1/notes:search

Request Body

Sample Call

epilot notes searchNotesByContext \
-d '{"contexts":[{"type":"workflow_execution","id":"string"}],"from":0,"size":10}'

Using stdin pipe:

cat body.json | epilot notes searchNotesByContext

With JSONata filter:

epilot notes searchNotesByContext --jsonata 'results[0]'

pinNoteโ€‹

Pins a single Note entry based on it's Entity ID

POST /v1/note/{id}/pin

Parameters

NameInTypeRequiredDescription
idpathstringYesThe Entity ID of the Note entry to pin

Sample Call

epilot notes pinNote \
-p id=123e4567-e89b-12d3-a456-426614174000

Using positional args for path parameters:

epilot notes pinNote 123e4567-e89b-12d3-a456-426614174000

With JSONata filter:

epilot notes pinNote -p id=123e4567-e89b-12d3-a456-426614174000 --jsonata '$'

getNoteContextsโ€‹

Gets all the Entity and non-Entity records the Note is contextually attached to

GET /v1/note/{id}/context

Parameters

NameInTypeRequiredDescription
idpathstringYesThe Entity ID of the Note entry to get contexts for

Sample Call

epilot notes getNoteContexts \
-p id=123e4567-e89b-12d3-a456-426614174000

Using positional args for path parameters:

epilot notes getNoteContexts 123e4567-e89b-12d3-a456-426614174000

With JSONata filter:

epilot notes getNoteContexts -p id=123e4567-e89b-12d3-a456-426614174000 --jsonata '$'
Sample Response
[
{
"type": "workflow_execution",
"context": {
"_id": "string",
"_org": "string",
"_schema": "string",
"_created_at": "1970-01-01T00:00:00.000Z",
"_updated_at": "1970-01-01T00:00:00.000Z",
"_created_by": "string",
"_tags": ["string"],
"_acl": {},
"_owners": [
{
"org_id": "string",
"user_id": "string"
}
],
"type": "string"
}
}
]

addNoteReactionโ€‹

Adds an emoji reaction to a note

POST /v1/note/{id}/reaction

Parameters

NameInTypeRequiredDescription
idpathstringYesThe Entity ID of the Note entry to add reaction to

Request Body

Sample Call

epilot notes addNoteReaction \
-p id=123e4567-e89b-12d3-a456-426614174000 \
-d '{"emoji":"thumbs-up"}'

Using positional args for path parameters:

epilot notes addNoteReaction 123e4567-e89b-12d3-a456-426614174000

Using stdin pipe:

cat body.json | epilot notes addNoteReaction -p id=123e4567-e89b-12d3-a456-426614174000

With JSONata filter:

epilot notes addNoteReaction -p id=123e4567-e89b-12d3-a456-426614174000 --jsonata 'context_entities'

removeNoteReactionโ€‹

Removes an emoji reaction from a note

DELETE /v1/note/{id}/reaction/{emoji_shortcode}

Parameters

NameInTypeRequiredDescription
idpathstringYesThe Entity ID of the Note entry to remove reaction from
emoji_shortcodepathstringYesThe emoji to remove from the note

Sample Call

epilot notes removeNoteReaction \
-p id=123e4567-e89b-12d3-a456-426614174000 \
-p emoji_shortcode=example

Using positional args for path parameters:

epilot notes removeNoteReaction 123e4567-e89b-12d3-a456-426614174000 example

With JSONata filter:

epilot notes removeNoteReaction -p id=123e4567-e89b-12d3-a456-426614174000 -p emoji_shortcode=example --jsonata 'context_entities'

toggleNoteReactionsโ€‹

Toggles multiple emoji reactions on a note. If a user has already reacted with an emoji, it removes the reaction. If a u

POST /v1/note/{id}/reactions/toggle

Parameters

NameInTypeRequiredDescription
idpathstringYesThe Entity ID of the Note entry to toggle reactions on

Request Body

Sample Call

epilot notes toggleNoteReactions \
-p id=123e4567-e89b-12d3-a456-426614174000 \
-d '{"emojis":["thumbs-up","heart"]}'

Using positional args for path parameters:

epilot notes toggleNoteReactions 123e4567-e89b-12d3-a456-426614174000

Using stdin pipe:

cat body.json | epilot notes toggleNoteReactions -p id=123e4567-e89b-12d3-a456-426614174000

With JSONata filter:

epilot notes toggleNoteReactions -p id=123e4567-e89b-12d3-a456-426614174000 --jsonata 'context_entities'