Retrieving a Company

The following example looks up a fictional company (Acme, Inc.) from an example BaseCMS API. This query outlines how to make a request to retrieve company fields.

Retrieve a company by ID

POST https://<instance>.base-staging.parameter1.com/graphql

This Query allows you to return company data after looking it up by its identifier.

Headers

Name
Type
Description

X-Tenant-Key

string

The Tenant Key used to access your data.

Authentication

string

If specified, the user that should be attributed with this request.

Request Body

Name
Type
Description

operationName

string

The name of the GraphQL query

variables

object

The GraphQL variables to inject into the query.

query

string

The GraphQL query text to execute

{
  "data": {
    "contentCompany": {
      "id": 21112606,
      "name": "Acme, Inc."
    }
  }
}

Query

Query

query RetrieveCompanyByID($input: ContentCompanyQueryInput!) {
  contentCompany(input: $input) {
    id
    name
  }
}

Variables

{
  "input": {
    "id": 21112606
  }
}

Last updated