Skip to content
gist.link ↗

companies

Query CRM API — POST https://crm.api.gist.link/graphql

The companies query on the CRM API.

crm:query:companies

The calling IAM key must hold this permission (or a wildcard that covers it: crm:query:* or crm:*) and the access token must have been minted with audience=crm. See Permissions.

type Query {
companies(filter: CompanyFilter, sort: SortInput, first: Int, after: String): CompanyConnection!
}
Argument Type Required Description
filter CompanyFilter No —
sort SortInput No —
first Int No —
after String No —

CompanyConnection! — see the CRM types reference.

Terminal window
curl https://crm.api.gist.link/graphql \
-H "Authorization: Bearer $ACCESS_TOKEN" \
-H 'Content-Type: application/json' \
-d @- <<'JSON'
{
"query": "query Companies($filter: CompanyFilter, $sort: SortInput, $first: Int, $after: String) { companies(filter: $filter, sort: $sort, first: $first, after: $after) { totalCount edges { cursor node { uuid name domains website industry size tags ownerUserUuid } } } }",
"variables": {
"filter": {
"search": "example",
"includeArchived": true
},
"sort": {
"field": "example",
"direction": "ASC"
},
"first": 10,
"after": "cursor"
}
}
JSON