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

# Authentication

## Overview

This guide explains how to authenticate with our API using API keys. This authentication method is designed for server-to-server communication where your application needs to access API resources on its own behalf.

## Prerequisites

Before you begin, ensure you have an **API key**, which you can create at [https://console.engrate.io](https://console.engrate.io).

## Examples

### Making API requests

<CodeGroup>
  ```bash Request theme={null}
  curl --request GET \
    --url "https://api.engrate.io/cost-of-energy/v1/tariffs?system_operator_id=0199c317-25ec-7cf7-94cc-32a39f068433" \
    --header "authorization: $API_KEY" \
    --header "content-type: application/json"
  ```

  ```json Response theme={null}
  {
    "tariffs": [
      {
        "id": "0199c317-25ec-7cf7-94cc-32a39f068433",
        "name": "Säkringsabonnemang - 20 A",
        "summary": "Fuse-based tariff for 20A with energy tax and monthly subscription fee.",
        "available_from": "2024-01-01T00:00:00+01:00",
        "tariff_components": [
          {
            "name": "Energiskatt",
            "applicable_from": "2026-01-01T00:00:00+01:00",
            ...
          }
        ]
      }
    ]
  }
  ```
</CodeGroup>
