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

# Authentication

> How to authenticate requests to the NeuralVerge API.

# Authentication

Most NeuralVerge API endpoints require a bearer token.

## Authorization header

Send your access token in this format:

`Authorization: Bearer YOUR_ACCESS_TOKEN`

## Common headers

For most `POST` requests, include:

* `Authorization: Bearer YOUR_ACCESS_TOKEN`
* `Content-Type: application/json`

## Example request

```bash theme={null}
curl -X POST "https://api.neuralverge.ai/functions/v1/run-search" \
  -H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "query": "OpenAI pricing",
    "settings": {
      "country": "us",
      "language": "en",
      "max_results": 10
    }
  }'
```

## When you get `401 Unauthorized`

A request can fail with `401` when:

* the `Authorization` header is missing
* the token format is invalid
* the token has expired
* the token does not have access to the requested resource

## Best practices

* Do not expose private tokens in public frontend code
* Store tokens in a secure backend environment
* Avoid logging full tokens
* Use separate credentials for different integrations when needed
