> ## Documentation Index
> Fetch the complete documentation index at: https://docs.requestly.com/llms.txt
> Use this file to discover all available pages before exploring further.

# GraphQL Request

> Requestly supports GraphQL requests, allowing you to send queries, mutations, and define variables

GraphQL requests work over HTTP just like REST, but instead of defining multiple endpoints, you typically interact with a **single endpoint** (e.g., `/graphql`) and specify the exact data you want. This gives you flexibility, reduces over-fetching, and makes debugging APIs much simpler.

<img src="https://mintcdn.com/requestly/Z9psaKI2OUaqbNe1/images/graphql-request/b393cc24-502b-4229-80e0-fd5b75a374cf.png?fit=max&auto=format&n=Z9psaKI2OUaqbNe1&q=85&s=e8628fa6787dbc4a6e776aca492f0acd" align="center" fullwidth="false" width="2156" height="1406" data-path="images/graphql-request/b393cc24-502b-4229-80e0-fd5b75a374cf.png" />

## Create your first GraphQL request

<Steps>
  <Step title="Open API Client and Create a New Request">
    Open **Requestly Desktop App**, then click the `+ New` button to create a new request and select **GraphQL request** from the menu.

    <img src="https://mintcdn.com/requestly/Z9psaKI2OUaqbNe1/images/graphql-request/9e445125-233d-4086-bbb1-913887d4edfd.png?fit=max&auto=format&n=Z9psaKI2OUaqbNe1&q=85&s=2224cfb28115309c133ce3812030bd83" align="center" fullwidth="false" width="2400" height="1368" data-path="images/graphql-request/9e445125-233d-4086-bbb1-913887d4edfd.png" />
  </Step>

  <Step title="Name Your API Request">
    Give a descriptive title for your request to make it easy to identify later

    <img src="https://mintcdn.com/requestly/Z9psaKI2OUaqbNe1/images/graphql-request/08acf961-0623-4ec8-a7a9-c9eebd57ca82.png?fit=max&auto=format&n=Z9psaKI2OUaqbNe1&q=85&s=d5d93cefd173c4a966c1c959d80fb9d3" align="center" fullwidth="false" width="2400" height="1368" data-path="images/graphql-request/08acf961-0623-4ec8-a7a9-c9eebd57ca82.png" />
  </Step>

  <Step title="Enter the GraphQL server URL">
    Add your GraphQL endpoint.

    <Info>
      It will automatically perform **schema introspection** so you can explore available queries, mutations, and types.
    </Info>

    <img src="https://mintcdn.com/requestly/Z9psaKI2OUaqbNe1/images/graphql-request/8c9a443f-86dc-489c-94e5-84e5f33a7c9c.png?fit=max&auto=format&n=Z9psaKI2OUaqbNe1&q=85&s=8e0250fd4795ceb846fca178af56951b" align="center" fullwidth="false" width="1958" height="1244" data-path="images/graphql-request/8c9a443f-86dc-489c-94e5-84e5f33a7c9c.png" />
  </Step>

  <Step title="Explore the schema">
    Under the **Query** tab, you’ll see three panels:

    * **Query/Mutation editor**: where you write or generate queries.

    * **Variables editor**: where you define variables in JSON format.

    * **Schema**: where you explore your API’s schema (Queries, Mutations, Subscriptions).

    <img src="https://mintcdn.com/requestly/Z9psaKI2OUaqbNe1/images/graphql-request/c674ba8c-8ead-4c18-95a2-8197e8dc460c.png?fit=max&auto=format&n=Z9psaKI2OUaqbNe1&q=85&s=87f2a6a40779e5f982e8f300a177a48b" align="center" fullwidth="false" width="1698" height="1276" data-path="images/graphql-request/c674ba8c-8ead-4c18-95a2-8197e8dc460c.png" />
  </Step>

  <Step title="Build your query">
    In the schema explorer, select a field and expand its arguments. A query will automatically appear in the **Query editor**.\
    Alternatively, you can write your query manually

    <img src="https://mintcdn.com/requestly/Z9psaKI2OUaqbNe1/images/graphql-request/468ee277-2628-4400-bfd1-06dcaaaa7583.png?fit=max&auto=format&n=Z9psaKI2OUaqbNe1&q=85&s=b35c1ca15fc5f8da06ed53c5f5272f63" align="center" fullwidth="false" width="1698" height="1170" data-path="images/graphql-request/468ee277-2628-4400-bfd1-06dcaaaa7583.png" />
  </Step>

  <Step title="Add variables (optional)">
    In the **Variables editor**, provide values in JSON format.

    <img src="https://mintcdn.com/requestly/Z9psaKI2OUaqbNe1/images/graphql-request/e547f084-420b-409b-8d51-dd0b925a5b39.png?fit=max&auto=format&n=Z9psaKI2OUaqbNe1&q=85&s=4dd2d365ee0c914c826adf314b9d8556" align="center" fullwidth="false" width="1698" height="1170" data-path="images/graphql-request/e547f084-420b-409b-8d51-dd0b925a5b39.png" />
  </Step>

  <Step title="Send the request">
    Click **Send** to execute your query and view the response.

    <img src="https://mintcdn.com/requestly/Z9psaKI2OUaqbNe1/images/graphql-request/6bbd5f6f-29c3-48d7-8e10-9384b2d86ff3.png?fit=max&auto=format&n=Z9psaKI2OUaqbNe1&q=85&s=0c7f587a0ca519bae8b6c0656524d8ae" align="center" fullwidth="false" width="2400" height="1368" data-path="images/graphql-request/6bbd5f6f-29c3-48d7-8e10-9384b2d86ff3.png" />
  </Step>
</Steps>

### Create a GraphQL request with multiple queries

<Steps>
  <Step title="Create a new request">
    Open **Requestly Desktop App**, then click the `+ New` button to create a new request and select **GraphQL request** from the menu.

    <img src="https://mintcdn.com/requestly/Z9psaKI2OUaqbNe1/images/graphql-request/9e445125-233d-4086-bbb1-913887d4edfd.png?fit=max&auto=format&n=Z9psaKI2OUaqbNe1&q=85&s=2224cfb28115309c133ce3812030bd83" align="center" fullwidth="false" width="2400" height="1368" data-path="images/graphql-request/9e445125-233d-4086-bbb1-913887d4edfd.png" />
  </Step>

  <Step title="Select multiple fields">
    From the schema explorer, select more than one field. Both queries will appear in the **Query editor**. Alternatively, you can manually add a new query / mutation.

    <img src="https://mintcdn.com/requestly/Z9psaKI2OUaqbNe1/images/graphql-request/c674ba8c-8ead-4c18-95a2-8197e8dc460c.png?fit=max&auto=format&n=Z9psaKI2OUaqbNe1&q=85&s=87f2a6a40779e5f982e8f300a177a48b" align="center" fullwidth="false" width="1698" height="1276" data-path="images/graphql-request/c674ba8c-8ead-4c18-95a2-8197e8dc460c.png" />
  </Step>

  <Step title="Choose a query to run">
    Only one query runs at a time. First, click the **Send** button, then select the query you want to run from the dropdown.

    To execute another query, click the Send button again and select the other query from the dropdown.

    <img src="https://mintcdn.com/requestly/Z9psaKI2OUaqbNe1/images/graphql-request/6f82178d-a478-40a6-9f99-03f066ee2cb4.png?fit=max&auto=format&n=Z9psaKI2OUaqbNe1&q=85&s=e55f21cab6f31d489d8091c549b3b29a" align="center" fullwidth="false" width="2400" height="1368" data-path="images/graphql-request/6f82178d-a478-40a6-9f99-03f066ee2cb4.png" />
  </Step>
</Steps>

## What's Next?

<CardGroup cols={3}>
  <Card title="Add Authorization" icon="shield" href="/api-client/send-api-request/authorization">
    Secure your GraphQL requests with API keys and tokens
  </Card>

  <Card title="Use Variables" icon="brackets-curly" href="/api-client/environments-and-variables">
    Make your GraphQL queries dynamic with environment variables
  </Card>

  <Card title="Organize in Collections" icon="folder" href="/api-client/api-collections">
    Group related GraphQL requests together
  </Card>
</CardGroup>
