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

# Introduction

> Welcome to the Afriex Business API

## Welcome to the Afriex Business API

The Afriex Business API enables you to manage customers, process payments, handle payouts, and receive real-time notifications via webhooks. This documentation provides comprehensive guides and API reference for integrating with our platform.

<CardGroup cols={2}>
  <Card title="OpenAPI spec" icon="file-code" href="https://api.afriex.com/api/docs.json">
    Get the full OpenAPI spec at this endpoint for code generation, SDKs, and API tooling.
  </Card>

  <Card title="MCP server" icon="plug" href="/mcp/introduction">
    Add the Afriex Business API to your MCP client and search the docs from Cursor, Claude Code, and other MCP-enabled tools.
  </Card>
</CardGroup>

## Base URLs

The API is available on two environments:

| Environment | Base URL                         |
| ----------- | -------------------------------- |
| Staging     | `https://sandbox.api.afriex.com` |
| Production  | `https://api.afriex.com`         |

## Authentication

All API endpoints require authentication using an API key. Include your API key in the `x-api-key` header:

```
x-api-key: your-api-key-here
```

Obtain your API key from the [Afriex Dashboard](https://business.afriex.com/).

### API key permissions

A business can provision **multiple API keys**, each scoped to a configurable set of **permissions** (for example, read transactions or create deposits). Permissions are chosen per key at creation time and can be revoked by deleting the key. Manage your keys and their permissions under **Developer → API keys** in the dashboard.

* A key that is missing the permission required by an endpoint is rejected with `403 Forbidden`.
* An unrecognised, malformed, or revoked key returns `401 Unauthorized`.

### Request signing

Some businesses have payload signing enabled. When it is, send the request signature in the optional `x-api-signature` header:

```
x-api-signature: your-request-signature
```

If signing is not enabled for your business, this header is not required. Contact [support@afriex.com](mailto:support@afriex.com) to enable it.

## API Versioning

The API supports versioning via the `x-api-version` header:

```
x-api-version: 2025-12-28
```

If not specified, the API defaults to the latest stable version.

## Core Resources

The API provides the following core resources:

<CardGroup cols={2}>
  <Card title="Customers" icon="users" href="/api-reference/endpoint/customers/create">
    Create and manage customer profiles with optional KYC information.
  </Card>

  <Card title="Payment Methods" icon="credit-card" href="/api-reference/endpoint/payment-methods/create">
    Set up bank accounts, mobile money, and crypto wallets for payouts.
  </Card>

  <Card title="Transactions" icon="money-bill-transfer" href="/api-reference/endpoint/transactions/create">
    Process deposits and withdraws with real-time status tracking.
  </Card>

  <Card title="Webhooks" icon="bell" href="/api-reference/endpoint/webhooks/introduction">
    Receive real-time notifications for customer, payment method, and transaction events.
  </Card>
</CardGroup>

<Info>
  **Webhook firewall requirement:** If you plan to receive webhooks, allowlist the following Afriex IP addresses on your server:

  * Sandbox: `34.234.189.210`
  * Production: `34.197.33.100`

  See [Webhook IP addresses](/api-reference/endpoint/webhooks/introduction#afriex-ip-addresses) for details.
</Info>

## Quick Links

* [Quickstart Guide](/quickstart) - Get up and running in minutes
* [Customer API](/api-reference/endpoint/customers/create) - Manage customer profiles
* [Transaction API](/api-reference/endpoint/transactions/create) - Process payments
* [Webhook Events](/api-reference/endpoint/webhooks/introduction) - Handle notifications

## Support

Need help? Contact us at [support@afriex.com](mailto:support@afriex.com).
