> For the complete documentation index, see [llms.txt](https://docs.bloxroute.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.bloxroute.com/solana/trader-api/introduction/authorization.md).

# Authorization

{% hint style="info" %}
Each request to any Trader API endpoint should include your authorization header. For HTTP, gRPC, and WebSocket connections, your authorization should be included in the request headers. For QUIC/HTTP3 connections, your authorization is derived from your account's certificate over mTLS.
{% endhint %}

## Obtaining an Auth Header

If you're an existing bloXroute customer, you can use the same authorization header as you would use for any other Cloud API offering from bloXroute.

If you are not a bloXroute customer, you can create an account and you can find your header from our [account portal](https://portal.bloxroute.com/).

<figure><img src="https://content.gitbook.com/content/ZgMW6iwGsmn9ejYuG9vP/blobs/5HjtguFbZ1D0062M7jS2/Screen%20Shot%202020-12-28%20at%201.43.47%20PM.png" alt=""><figcaption></figcaption></figure>

### Using the header

You should include the authorization header upon establishing any connection with the Trader API.

{% tabs %}
{% tab title="HTTP" %}

```http
curl --header "Authorization: <YOUR-AUTHORIZATION-HEADER" https://ny.solana.dex.blxrbdn.com/api/v2/rate-limit
```

{% endtab %}

{% tab title="WebSocket" %}

```zsh
wscat -c wss://ny.solana.dex.blxrbdn.com/ws --header "Authorization: <YOUR-AUTHORIZATION-HEADER>"
```

{% endtab %}

{% tab title="gRPC" %}

```zsh
# Protobuf definitions available at https://github.com/bloXroute-Labs/solana-trader-proto/tree/develop
grpcurl -plaintext -import-path . \
  -proto api.proto \
  -H "Authorization: <YOUR-AUTHORIZATION-HEADER>" \
  -d '{}' \
  ny.solana.dex.blxrbdn.com:80 api.Api/GetRateLimit
```

{% endtab %}

{% tab title="QUIC" %}
{% hint style="info" %}
QUIC connections use mTLS authentication via your account's certificate/key pair, downloadable from your user portal. Please refer to our QUIC documentation for more information.
{% endhint %}
{% endtab %}
{% endtabs %}

### Client SDKs

By default, you can set the environment variable `AUTH_HEADER` to have our client SDKs automatically load the value for connections you make to the Trader API. You can also specify this manually –– consult each SDK's documentation for more details.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

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

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.bloxroute.com/solana/trader-api/introduction/authorization.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

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.
