--- title: "Making requests" slug: "making-requests" updated: 2026-07-09T07:57:58Z published: 2026-07-09T07:57:58Z canonical: "docs.supermetrics.com/making-requests" --- > ## Documentation Index > Fetch the complete documentation index at: https://docs.supermetrics.com/llms.txt > Use this file to discover all available pages before exploring further. # Making requests This page contains general information that you might need, when making requests to Supermetrics API. - [Authentication](/v1-api/apidocs/making-requests#authentication) - [GET method](/v1-api/apidocs/making-requests#get-method) - [Pretty JSON](/v1-api/apidocs/making-requests#pretty-json) - [CORS support](/v1-api/apidocs/making-requests#cors-support) - [Postman examples](/v1-api/apidocs/making-requests#postman-examples) ## Authentication All endpoints that require authentication, accept either an [api_key](/v1-api/apidocs/managing-your-api-keys) parameter, or an Authorization header. Read more about [authentication](/v1-api/apidocs/authentication). ```plaintext Authorization: Bearer ``` ## GET method When the endpoint supports the GET method, you can choose to either use the traditional GET query parameters, as defined in [RFC 1738](http://www.faqs.org/rfcs/rfc1738.html), or a JSON string representing the query parameters, sent as the json parameter. The documentation shows examples mostly with the latter approach. Example: ```plaintext GET /enterprise/v2/query/data/json?json={  "api_key": "",  "ds_id": "GAWA",  "ds_accounts": "567890",  "start_date": "2024-01-01",  "end_date": "today",  "fields": "date, impressions",  "settings": {"no_headers": true},  "filter": "impressions > 0 AND impressions < 100",  "order_rows": "impressions desc,date desc",  "max_rows": 1000 } HTTP/1.1 Host: api.supermetrics.com Accept: */* Accept-Encoding: gzip,deflate) @fancy_anchor({"id": "post-method"}) #### POST method When endpoint supports the _POST_ method, you either choose to send the request body as POST fields with content type _application/x-www-form-urlencoded_, or as a JSON string with content type _application/json_. ###### Example @fancy_endpoint_example( POST /enterprise/v2/query/data/json HTTP/1.1 Content-Type: application/json; charset=utf-8 Host: api.supermetrics.com Accept: */* Accept-Encoding: gzip,deflate Authorization: Bearer {  "ds_id": "GAWA",  "ds_accounts": "567890",  "start_date": "2024-01-01",  "end_date": "today",  "fields": "date, impressions",  "settings": {"no_headers": true},  "filter": "impressions > 0 AND impressions < 100",  "order_rows": "impressions desc,date desc",  "max_rows": 1000 } ``` ## Pretty JSON URL query parameter pretty can be used to pretty-print JSON responses in a human-readable format. Please note that this also increases the response size, and it should not be used for automated requests. ```plaintext GET /enterprise/v2/query/data/json?json={...}&pretty=true ``` ## CORS support Currently, we discourage making authenticated requests to Supermetrics API from browser applications, as they are likely to expose credentials to end users. Therefore, we do not accept [cross-origin HTTP requests](https://developer.mozilla.org/en-US/docs/Web/HTTP/CORS) by default. Please [contact us](/v1-api/apidocs/support) if this behaviour is vital to your integration.