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

# Authentication

> Authenticate Merchant API requests.

Every Merchant API request must include your API key in the `x-api-key` header.

## Header

```http theme={null}
x-api-key: YOUR_API_KEY
```

## Example

```bash theme={null}
curl https://serviceapi.sarafa.ss/v3/profile \
  -H "x-api-key: YOUR_API_KEY" \
  -H "environment: sandbox"
```

## Authentication errors

| Status | Meaning                                                              |
| ------ | -------------------------------------------------------------------- |
| `401`  | The API key is missing or invalid.                                   |
| `403`  | The merchant profile or account is not active or could not be found. |

If you receive an authentication error, confirm that you copied the correct key and are using the intended environment.
