Generating an API Key

Messari API Key Generation Interface
1

Access the API Dashboard

Navigate to the API Access page in your Messari account
2

Create New Key

Click the “Generate API Key” button
3

Secure Your Key

Store your API key in a secure location - it won’t be shown again

Using the API Key

The API key must be included in the request headers using the x-messari-api-key header field:
{
  "headers": {
    "x-messari-api-key": "YOUR_API_KEY_HERE"
  }
}

Permissions

API access is tiered based on your subscription level. By default, all users have access to the Metrics, News, Assets, Market Data API endpoints, as well as metered access to the AI Toolkit dependent on your subscription tier. For access to additional services like Token Unlocks, Fundraising data or more, please contact api@messari.io to discuss enterprise options.

Example Request (cURL)

The following example demonstrates how to send a request to the Messari API using cURL with the x-messari-api-key header:
curl --location 'https://api.messari.io/ai/v1/chat/completions' \
--header 'x-messari-api-key: YOUR_API_KEY_HERE' \
--header 'Content-Type: application/json' \
--data '{
    "messages": [
        {
            "role": "user",
            "content": "Briefly explain what the Hyperliquid HyperEVM is"
        }
    ],
    "verbosity": "succinct",
    "response_format": "markdown"
}'

Security Best Practices

Secure Storage

Never share your API key publicly or commit it to version control

Environment Variables

Store API keys in environment variables rather than hardcoding them

Regular Rotation

Periodically update your API key for security purposes