Notes API

Notes provide a way to add comments, observations, and other text information to resources within the GridLogs platform. This API allows you to create, retrieve, update, and delete notes.

Create Note

POST /v1/notes

Creates a new note.

Request

content
string
required

Content of the note

businessCaseId
string

ID of the associated business case

consumerCaseId
string

ID of the associated consumer case

taskId
string

ID of the associated task

documentId
string

ID of the associated document

Response

id
string

Unique identifier for the note

content
string

Content of the note

businessCaseId
string

ID of the associated business case

consumerCaseId
string

ID of the associated consumer case

taskId
string

ID of the associated task

documentId
string

ID of the associated document

createdBy
string

ID of the user who created the note

createdAt
string

Creation timestamp

updatedAt
string

Last update timestamp

Examples

curl -X POST https://api.gridlogs.co/v1/notes \
  -H "X-API-Key: your_api_key_here" \
  -H "Content-Type: application/json" \
  -d '{
    "content": "Requested additional documentation from the business.",
    "businessCaseId": "bc_12345"
  }'

List Notes

GET /v1/notes

Returns a paginated list of notes.

Query Parameters

page
number

Page number for pagination (default: 1)

limit
number

Number of items per page (default: 10)

businessCaseId
string

Filter notes by business case ID

consumerCaseId
string

Filter notes by consumer case ID

taskId
string

Filter notes by task ID

documentId
string

Filter notes by document ID

Search term to filter results by content

Response

items
array

Array of note objects

meta
object

Pagination metadata

meta.total
number

Total number of notes

meta.page
number

Current page number

meta.limit
number

Number of items per page

meta.totalPages
number

Total number of pages

Examples

curl -X GET "https://api.gridlogs.co/v1/notes?page=1&limit=10&businessCaseId=bc_12345" \
  -H "X-API-Key: your_api_key_here"

Get Note

GET /v1/notes/{id}

Retrieves a specific note by ID.

Path Parameters

id
string
required

Note ID

Response

Returns a note object with all its properties.

Examples

curl -X GET "https://api.gridlogs.co/v1/notes/note_12345" \
  -H "X-API-Key: your_api_key_here"

Update Note

PUT /v1/notes/{id}

Updates a specific note.

Path Parameters

id
string
required

Note ID

Request

content
string
required

Updated content of the note

Response

Returns the updated note object.

Examples

curl -X PUT "https://api.gridlogs.co/v1/notes/note_12345" \
  -H "X-API-Key: your_api_key_here" \
  -H "Content-Type: application/json" \
  -d '{
    "content": "Updated: Received requested documentation from business."
  }'

Delete Note

DELETE /v1/notes/{id}

Deletes a specific note.

Path Parameters

id
string
required

Note ID

Response

Returns the deleted note object.

Examples

curl -X DELETE "https://api.gridlogs.co/v1/notes/note_12345" \
  -H "X-API-Key: your_api_key_here"