The first thing you'll need to use the GraphQL API is a deployed instance of DataHub with some metadata ingested.
For more information, please refer to [Datahub Quickstart Guide](/docs/quickstart.md).
## Querying the GraphQL API
DataHub's GraphQL endpoint is served at the path `/api/graphql`, e.g. `https://my-company.datahub.com/api/graphql`.
There are a few options when it comes to querying the GraphQL endpoint.
For **Testing**:
- GraphQL Explorer (GraphiQL)
- CURL
- Postman
For **Production**:
- GraphQL [Client SDK](https://graphql.org/code/) for the language of your choice
- Basic HTTP client
> Notice: The DataHub GraphQL endpoint only supports POST requests at this time.
### GraphQL Explorer (GraphiQL)
DataHub provides a browser-based GraphQL Explorer Tool ([GraphiQL](https://github.com/graphql/graphiql)) for live interaction with the GraphQL API. This tool is available at the path `/api/graphiql` (e.g. `https://my-company.datahub.com/api/graphiql`)
This interface allows you to easily craft queries and mutations against real metadata stored in your live DataHub deployment.
To experiment with GraphiQL before deploying it in your live DataHub deployment, you can access a demo site provided by DataHub at https://demo.datahub.com/api/graphiql.
--data-raw '{ "query": "mutation createTag { createTag(input: { name: \"Deprecated\", description: \"Having this tag means this column or table is deprecated.\" }) }", "variables":{}}'
```
### Postman
Postman is a popular API client that provides a graphical user interface for sending requests and viewing responses.
Within Postman, you can create a `POST` request and set the request URL to the `/api/graphql` endpoint.
In the request body, select the `GraphQL` option and enter your GraphQL query in the request body.
Please refer to [Querying with GraphQL](https://learning.postman.com/docs/sending-requests/graphql/graphql-overview/) in the Postman documentation for more information.
In general, you'll need to provide an [Access Token](../../authentication/personal-access-tokens.md) when querying the GraphQL by
providing an `Authorization` header containing a `Bearer` token. The header should take the following format:
```bash
Authorization: Bearer <access-token>
```
Authorization for actions exposed by the GraphQL endpoint will be performed based on the actor making the request.
For Personal Access Tokens, the token will carry the user's privileges. Please refer to [Access Token Management](/docs/api/graphql/token-management.md) for more information.
## What's Next?
Now that you are ready with GraphQL, how about browsing through some use cases?
Please refer to [Getting Started With GraphQL](/docs/api/graphql/getting-started.md) for more information.