> ## Documentation Index
> Fetch the complete documentation index at: https://direct-api.reap.global/llms.txt
> Use this file to discover all available pages before exploring further.

# Quickstart

> Go from a new API key to your first card in a few calls: check the key, find a cardholder, create a card, reveal it, then clean up.

> [!WARNING]
>
> There is no sandbox. Every call you make is production. Use a low spend cap
> on test cards and terminate them when you're done.

The steps below are a worked example of the flow described in [Get access and
API keys](https://direct-api.reap.global/getting-started/access-and-api-keys.md): a new key goes to a first
card in a few calls: check the key, find a cardholder, create a card, reveal
it, then clean up.

**1. Get access**

Business Account API access is granted per business. See [Get access and
API keys](https://direct-api.reap.global/getting-started/access-and-api-keys.md) for who can request it and
how.

**2. Create a key**

In the Business Account dashboard, a team administrator creates an API key
with the `team_members:read`, `cards:read`, `cards:write` and
`cards:read_vault` scopes, and adds your server's IP to the key's
allowlist. The secret is shown once, so store it in a secrets manager.

```bash theme={"system"}
export REAP_API="https://api.global.direct.reap.global/2026-07-13"
export REAP_KEY="your-api-key"
```

**3. Check the key**

```bash theme={"system"}
curl "$REAP_API/health" -H "x-api-key: $REAP_KEY"
```

A `200` means the key works. A `401` means it's missing or invalid; a `403`
with `API_KEY_IP_NOT_ALLOWED` means your server's IP isn't on the key's
allowlist.

**4. Find a cardholder**

Cards belong to team members. List them and pick one with
`inviteStatus: "approved"`:

```bash theme={"system"}
curl "$REAP_API/team-members" -H "x-api-key: $REAP_KEY"
```

```json theme={"system"}
{
  "items": [
    {
      "userId": "user_01JZ2Q1J4Y8P7M6N5K3H2G1F0E",
      "name": "Ada Lovelace",
      "email": "ada@example.com",
      "teamGroupName": "Marketing",
      "inviteStatus": "approved"
    }
  ],
  "meta": { "totalItems": 1, "itemCount": 1, "itemsPerPage": 20, "totalPages": 1, "currentPage": 1 }
}
```

Keep the `userId`; it's the `cardholderId` on the next call.

**5. Create a test card**

Create a virtual card with a small top-up budget. Set `category` to an
`id` from `GET /cards/categories`. Send an `Idempotency-Key` so a retry
can never create a second card.

```bash theme={"system"}
curl -X POST "$REAP_API/cards" \
  -H "x-api-key: $REAP_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: quickstart-first-card" \
  -d '{
    "type": "virtual",
    "title": "Quickstart test card",
    "cardholderId": "user_01JZ2Q1J4Y8P7M6N5K3H2G1F0E",
    "category": "acfb3669-e27d-4930-a65c-fd371e4d4715",
    "planType": "topUp",
    "spendCap": { "amount": "10.00", "currency": "USD" }
  }'
```

There are three outcomes:

* **`201` with `status: "active"`**: the card is ready. Store its `id`.
* **`201` with `status: "pending"`**: created, still being set up. Poll
  the `Location` response header until it's `active`.
* **`202` with `status: "pendingApproval"`**: your business uses
  Approvals; an approver accepts the request in the dashboard first. See
  [Approvals](https://direct-api.reap.global/concepts/approvals.md).

**6. Show the card details**

Card numbers never pass through your servers. Request a short-lived link
to a Reap-hosted view instead:

```bash theme={"system"}
curl -X POST "$REAP_API/cards/{cardId}/reveal" -H "x-api-key: $REAP_KEY"
```

```json theme={"system"}
{ "accessUrl": "https://secure.card.reap.global/api/card/show-card-info?auth=..." }
```

The `accessUrl` is valid for 1 minute. Open it to see the card number,
expiry and CVV. See [Card details](https://direct-api.reap.global/concepts/card-details.md) for the rules.

**7. Clean up**

Terminate the test card:

```bash theme={"system"}
curl -X DELETE "$REAP_API/cards/{cardId}" -H "x-api-key: $REAP_KEY"
```

## Next steps

> [card] [Use cases](https://direct-api.reap.global/guides/issue-cards-to-your-team.md)
>
> End-to-end flows for team cards, advertising and Treasury funding.

> [card] [Concepts](https://direct-api.reap.global/concepts/cards.md)
>
> Statuses, funding plans, approvals and balances explained.

> [card] [Errors](https://direct-api.reap.global/api-reference/errors.md)
>
> The error envelope, every error code and retry guidance.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.