Integration API (GraphQL)
An overviewIntegration API uses GraphQL for querying and manipulating data.
What is GraphQL?
GraphQL is a trending alternative to RESTful APIs that pulls all requested data for multiple entities with a single request. It improves client-server interactions and reduces the latency that makes the app much more responsive to the user.
GraphQL is used to Send a query to Centra API and get exactly what you need, nothing more and nothing less. GraphQL queries always return predictable results. Apps using GraphQL are fast and stable because they control the data they get, not the server.
Content Type
GraphQL Operates on JSON objects and therefore such content type should also be used for requests' payload:
POST *base*/graphql
Content-Type: application/json
Requirements
- Access to Centra AMS
- Authentication token - see section Authorization to learn how to obtain one
- Correct permissions
Read more
We recommend a further reading before starting using the GraphQL API:
- https://graphql.org/ - Official GraphQL website. A canonical source of knowledge.
- https://www.howtographql.com/ - Alternative introduction to GraphQL.
- https://relay.dev/graphql/connections.htm - One of approaches for handling pagination in GraphQL (used by this API).
Introduction
GraphQL Access Token
An access token is a credential that is bound to certain set of permissions. The set of permissions is decided during token generation. It is not bound to any specific user by the application, but it might b...
Read moreSchema
Schema
GraphQL relies heavily on self-documentation and introspection mechanism to provide API user with comprehensive knowledge about the API itself. Separate documentation is not necessary as every mature enough GraphQL client...
Read moreCentra APIs rate limits
How does rate limiting work in Centra APIs, and how to avoid API rate limits issues
Read moreDocumentation
Click to jump to our auto-generated documentation for GraphQL
Read moreExamples of GQL queries and mutations
Read moreProduct Media upload
Uploading product media using AWS S3 pre-signed POST:
AWS Pre-signed POST data enables direct uploads to S3 storage in a controlled and safe way.
The client makes request for obtaining pre-signed POST Policy containing URL and...
Read moreID conversion
How to use the ID conversation feature in Centra, using your internal reference numbers for Centra objects.
Read moreEvents system
How to use the events system feature in Centra, allowing you to monitor for changes in Centra data relevant to your integration.
Read more