# Authentication

### ApiKeyAuth

All API requests must include the API key. You have to pass it in the request header with the `x-api-key` parameter.

{% hint style="info" %}
Header parameter name: `x-api-key`
{% endhint %}

### BearerAuth

There are some API requests that a session token can be used instead of an API key such as fetching a checkout order. You have to pass it in the request header with `Authorization: Bearer` parameter.

This authorization method is intended for client applications (frontend) where this token is generated on request and is not secure to use an API key.

{% hint style="info" %}
HTTP Authorization Scheme: Bearer

Format: "JWT"
{% endhint %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.cryptum.io/english/products/crypto-checkout/checkout-api/authentication.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
