AlmondTill/G3N API

On this page

notes

query · in the family Reading your records

What it does

The notes attached to one record.

ONE construct's note thread, OLDEST-FIRST + born-paginated. targetConstructId is the REQUIRED anchor (tenant-scoped — a cross-tenant/missing target refuses NOT_FOUND). Requires authentication.

Who may call it

Capability area: Reading your records — Looking up and listing the records of your organization.

Arguments

NameTypeRequiredNotes
targetConstructIdID ID!yesNo further notes.
limitIntnoHow many records to answer at most; a page may hold fewer.
nextTokenStringnoThe cursor from the previous page, passed back exactly as received.

Returns

NotePage NotePage! — One page of a construct's note thread.

This is a page: items holds the records and nextToken the cursor for the next page — pass it back verbatim until it is null. See paging.

Example request

query ExampleNotes($targetConstructId: ID!, $limit: Int) {
  notes(targetConstructId: $targetConstructId, limit: $limit) {
    items {
      id
      type
      caption
      status
      parentId
      rootId
      createdAt
      updatedAt
      revisionNum
      revision
      targetType
      authorId
      parentNoteId
      title
      kind
      body
      labelIds
      taskId
    }
    nextToken
  }
}

Variables:

{
  "targetConstructId": "01900000-0000-7000-8000-79e077380000",
  "limit": 1
}

Example response

{
  "data": {
    "notes": {
      "items": [
        {
          "id": "01900000-0000-7000-8000-37386ae00000",
          "type": "<type>",
          "caption": "Blue jeans",
          "status": "<status>",
          "parentId": "01900000-0000-7000-8000-065235280000",
          "rootId": "01900000-0000-7000-8000-a093dd800000",
          "createdAt": "2027-01-31T00:00:00.000Z",
          "updatedAt": "2027-01-31T00:00:00.000Z",
          "revisionNum": 1,
          "revision": "01900000-0000-7000-8000-b7960e180000",
          "targetType": "<target type>",
          "authorId": "01900000-0000-7000-8000-0046e40b0000",
          "parentNoteId": "01900000-0000-7000-8000-907baa100000",
          "title": "Blue jeans",
          "kind": "<kind>",
          "body": "Restock before the weekend.",
          "labelIds": [
            "01900000-0000-7000-8000-a235e7410000"
          ],
          "taskId": "01900000-0000-7000-8000-6ceba5410000"
        }
      ],
      "nextToken": "<the cursor from the previous page>"
    }
  },
  "extensions": {
    "at": {
      "callId": "01EXAMPLE-CALL-ID",
      "version": {
        "requested": null,
        "serviced": {
          "name": "genesis",
          "number": 0
        }
      }
    }
  }
}

Errors this call can answer