You are using an unsupported browser. Please update your browser to the latest version on or before July 31, 2020.
close
You are viewing the article in preview mode. It is not live at the moment.
Our offices will be closed from Tuesday, December 24th through Wednesday, January 1st. We will reopen on Thursday, January 2nd. During this time, we will continue to monitor and handle critical support items, but responses to most tickets and inquiries will likely be delayed.
Getting Started
print icon
This article is intended to support our customers using BenchPrep GraphQL API. If you’re interested in leveraging this service, or if you would like to learn more about it, contact your BenchPrep Customer Success Manager today for pricing!

 

GraphQL is an API standard that provides a more efficient, powerful, and flexible alternative to REST. You can read more about it and why we chose it in our Intro to GraphQL guide.

 

In that guide, we recommended using a great tool called GraphQL Playground that will allow you to see the schema, documentation as well as connect and execute GraphQL calls. We will use GraphQL Playground in this guide to get you started with the BenchPrep GraphQL API.

 

Authentication & Authorization

Our default Production GraphQL endpoint is https://benchprep.com/api/graphql (non-production endpoints are available in our API documentation). Remember, to see the schema and documentation you don't need authentication, however, in order to make queries, mutations, and subscriptions you will need to provide a valid Bearer token. Additionally, that token must have valid roles and permissions depending on what you are trying to achieve.

 

You can generate your token from the Settings->API Access page of our Console application. For a more detailed description, read this article.

 

After you obtain your token you can launch your GraphQL Playground and start by populating the endpoint:

 


On the next screen, you can write your query on the left, supply your input to the query on the bottom left (QUERY VARIABLES tab), and provide your authorization header (HTTP HEADERS tab). You will see responses on the right section. Additionally, you can find DOCS and SCHEMA tabs on the right . which will help you navigate schema and available documentation.

 



Start by supplying valid a Authorization HTTP header:

{"Authorization": "Bearer YOUR_TOKEN"}

...where YOUR_TOKEN is the token you obtained from the Console Application or from the CSM representative.

 

 

Putting it all together should allow you to get a valid result. Other guides in our Knowledge Base will help you build more complex queries and mutations.

 

Rate Limiting

Your requests will be subject to the Rate Limiting. The default across a tenant is 100 requests per second. Your limit configuration will be mutually established as you will get access to the API based on the needs, expected and peak usage. We will be happy to adjust your configuration as these needs or usage changes.

Feedback
2 out of 2 found this helpful

scroll to top icon