AlmondTill/G3N API

search

query · in the family Reading your records

What it does

Name search across your records — type-ahead by caption within your own group.

Caption typeahead within the caller's OWN org-group family; requires authentication.

Before you call

A bearer session from an API key (see Authentication and key hygiene) or a signed-in user.

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

Roles that may call it:

Arguments

NameTypeRequiredNotes
typeSearchableType SearchableType!yesOne of the values of [SearchableType](/types/SearchableType/).
prefixString String!yes
limitIntnoHow many records to answer at most; a page may hold fewer.

Returns

SearchHit [SearchHit!]! — One caption-search typeahead hit — the display projection of a matched construct.

Example request

graphql
query ExampleSearch($type: SearchableType!, $prefix: String!, $limit: Int) {
  search(type: $type, prefix: $prefix, limit: $limit) {
    id
    type
    rootId
    caption
    status
    sysId
  }
}

Variables:

json
{
  "type": "User",
  "prefix": "blue",
  "limit": 10
}

Example response

json
{
  "data": {
    "search": [
      {
        "id": "01900000-0000-7000-8000-37386ae00000",
        "type": "User",
        "rootId": "01900000-0000-7000-8000-a1295a650000",
        "caption": "Blue jeans",
        "status": "active",
        "sysId": "US-EXMP-0000-000F"
      }
    ]
  },
  "extensions": {
    "at": {
      "callId": "01EXAMPLE-CALL-ID",
      "version": {
        "requested": null,
        "serviced": {
          "name": "genesis",
          "number": 0
        }
      }
    }
  }
}

Errors this call can answer