---
updatedAt: 2026-09-24T18:16:43.000Z
agentTools:
  projectIndex: https://docs.staxpayments.com/llms.txt
---

# Overview

The Stax API is organized around REST, providing predictable, resource-oriented URLs and standard HTTP response codes for indicating errors. This makes it easy to integrate with, whether you're a seasoned developer or just getting started.

# Getting Started

<Cards columns="2">
  <Card title="Base URL" icon="fa-globe">
    All API requests should be made to the following base URL:

    ```
    https://apiprod.fattlabs.com
    ```

    When using a live or sandbox API key, you will use the same production URL. However, your sandbox will be linked to a test gateway and will not use real money.
  </Card>

  <Card title="Authentication" icon="fa-key">
    To access the API, you need an API key. All requests must include this key in the `Authorization` header as a Bearer Token.

    ```
    Authorization: Bearer YOUR_SECRET_KEY
    ```

    **⚠️ Keep your API key secure and never expose it in client-side code or public repositories.**
  </Card>
</Cards>

### Example Request

```bash
curl -X GET "https://apiprod.fattlabs.com/"\
-H "Authorization: Bearer YOUR_SECRET_KEY"\
-H "Content-Type: application/json"
```

***

# API Features

<Cards columns="2">
  <Card title="Content-Type Header" icon="fa-code">
    The `Content-Type` header must always be set to:

    ```
    application/json
    ```

    This ensures the API understands your requests and responds with JSON.
  </Card>

  <Card title="HTTP Methods" icon="fa-exchange-alt">
    The Stax API supports standard HTTP methods:

    - **GET**: Retrieve a resource
    - **POST**: Create a new resource  
    - **PUT**: Update an existing resource
    - **DELETE**: Delete a resource
  </Card>
</Cards>

***

# Important Information

<Accordion title="Rate Limits" icon="fa-tachometer-alt">
  The API enforces a rate limit of **100 requests per minute**. If you exceed this limit, you'll receive a `429 Too Many Requests` response. 

  The `Retry-After` header in the response indicates when you can retry your request.
</Accordion>

<Accordion title="Error Handling" icon="fa-exclamation-triangle">
  The Stax API uses standard HTTP status codes to indicate the success or failure of requests:

  | Status Code | Meaning | Description |
  |-------------|---------|-------------|
  | **200 OK** | ✅ Success | The request was successful |
  | **400 Bad Request** | ❌ Client Error | Invalid request (missing parameters) |
  | **401 Unauthorized** | 🔒 Auth Error | Authentication failed (missing/incorrect API key) |
  | **404 Not Found** | 🔍 Not Found | The requested resource does not exist |
  | **429 Too Many Requests** | ⏰ Rate Limited | You've exceeded the rate limit |
  | **500 Internal Server Error** | 🔧 Server Error | Something went wrong on our end |
</Accordion>

<Accordion title="Cross-Origin Resource Sharing (CORS)" icon="fa-shield-alt">
  The Stax API supports CORS, allowing secure interaction from client-side applications. 

  **⚠️ Important:** Never expose your secret API key in public client-side code.
</Accordion>

***

# Need Help?

<Cards columns="1">
  <Card title="Support & Documentation" icon="fa-question-circle">
    If you have any questions or run into issues:
    
    - Check out our comprehensive API Documentation
    - Contact our support team for assistance
    - Review the examples and guides in this documentation
  </Card>
</Cards>