## REST over HTTPS

Pixii’s API is built using REST. Requests use standard HTTP verbs, return JSON, and must always be made over HTTPS.

## Base URL

All API requests are made to the following base URL:

```
https://api.pixii.ai
```

All requests must use HTTPS — plain HTTP requests are rejected.

## Authentication

The Pixii API uses API keys to authenticate requests.

Pass your API key in the `Authorization` header of every request as a Bearer token. See [Authentication](/content/api-docs/authentication/index.html) for the full guide, including the difference between live and test keys.

## Error handling

Pixii uses conventional HTTP response codes to indicate the success or failure of an API request:

- Codes in the **2xx** range indicate success.
- Codes in the **4xx** range indicate an error with the information you provided.
- Codes in the **5xx** range indicate an error with Pixii’s servers.

Every error response is JSON with a consistent shape so you can handle errors programmatically. See the [errors reference](/content/api-docs/errors/index.html) for the full list of codes.

## Next

Continue to [Authentication](/content/api-docs/authentication/index.html) to learn how to issue and use your API keys.
