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

# Try the API

> Test Nomba APIs instantly — no account or credentials required

<Tip>
  No sign-up needed. Call the sandbox endpoints below directly — skip the `Authorization` header and `accountId` entirely. This is the fastest way to see Nomba APIs in action.
</Tip>

All examples on this page point to `https://sandbox.nomba.com`. No real money moves — it's a fully isolated test environment.

***

## Option 1 — Try it directly in the API Reference

The quickest way to test with zero setup. No terminal, no code.

<Steps>
  <Step title="Go to the API Reference">
    Navigate to the [API Reference](/nomba-api-reference/introduction) section in the sidebar, then pick any endpoint — for example [Transfer](/nomba-api-reference/transfers/perform-bank-account-transfer-from-the-parent-account), [Create Virtual Account](/nomba-api-reference/virtual-accounts/create-virtual-account), or [Create Checkout Order](/nomba-api-reference/online-checkout/create-an-online-checkout-order).
  </Step>

  <Step title="Click 'Try it'">
    On the endpoint page, click the **Try it** button to open the interactive request panel.
  </Step>

  <Step title="Select Sandbox from the base URL dropdown">
    At the top of the request panel, open the base URL dropdown and select **Sandbox** (`https://sandbox.nomba.com`).
  </Step>

  <Step title="Leave the auth fields blank">
    You will see fields for **Bearer Token** and **accountId** — leave both completely empty. You do not need credentials to test.
  </Step>

  <Step title="Fill in the request body and send">
    Enter your request body fields and click **Send**. The live response will appear directly on the page.
  </Step>
</Steps>

<Note>
  The API Reference playground sends requests directly to `https://sandbox.nomba.com`. Leaving the auth fields empty is intentional — it is how the no-account test mode works.
</Note>

***

## Option 2 — Run it from your terminal

## Transfer to a bank account

Send money to any Nigerian bank account.

<CodeGroup>
  ```bash cURL theme={null}
  curl --request POST \
    --url https://sandbox.nomba.com/v2/transfers/bank \
    --header 'Content-Type: application/json' \
    --data '{
      "amount": 3500,
      "accountNumber": "055472814",
      "accountName": "M.A Animashaun",
      "bankCode": "058",
      "merchantTxRef": "UNQ_test_001",
      "senderName": "Test Sender",
      "narration": "Test transfer"
    }'
  ```

  ```javascript Node.js theme={null}
  const response = await fetch('https://sandbox.nomba.com/v2/transfers/bank', {
    method: 'POST',
    headers: { 'Content-Type': 'application/json' },
    body: JSON.stringify({
      amount: 3500,
      accountNumber: '055472814',
      accountName: 'M.A Animashaun',
      bankCode: '058',
      merchantTxRef: 'UNQ_test_001',
      senderName: 'Test Sender',
      narration: 'Test transfer',
    }),
  });
  const data = await response.json();
  console.log(data);
  ```

  ```python Python theme={null}
  import requests

  response = requests.post(
      'https://sandbox.nomba.com/v2/transfers/bank',
      headers={'Content-Type': 'application/json'},
      json={
          'amount': 3500,
          'accountNumber': '055472814',
          'accountName': 'M.A Animashaun',
          'bankCode': '058',
          'merchantTxRef': 'UNQ_test_001',
          'senderName': 'Test Sender',
          'narration': 'Test transfer',
      },
  )
  print(response.json())
  ```
</CodeGroup>

```json Response theme={null}
{
  "code": "00",
  "description": "Success",
  "data": {
    "id": "txn_abc123",
    "status": "SUCCESS",
    "amount": 3500,
    "accountNumber": "055472814",
    "bankCode": "058",
    "merchantTxRef": "UNQ_test_001"
  }
}
```

***

## Create a virtual account

Generate a unique account number to receive payments.

<CodeGroup>
  ```bash cURL theme={null}
  curl --request POST \
    --url https://sandbox.nomba.com/v1/accounts/virtual \
    --header 'Content-Type: application/json' \
    --data '{
      "accountRef": "ref_test_001",
      "accountName": "John Doe",
      "currency": "NGN"
    }'
  ```

  ```javascript Node.js theme={null}
  const response = await fetch('https://sandbox.nomba.com/v1/accounts/virtual', {
    method: 'POST',
    headers: { 'Content-Type': 'application/json' },
    body: JSON.stringify({
      accountRef: 'ref_test_001',
      accountName: 'John Doe',
      currency: 'NGN',
    }),
  });
  const data = await response.json();
  console.log(data);
  ```

  ```python Python theme={null}
  import requests

  response = requests.post(
      'https://sandbox.nomba.com/v1/accounts/virtual',
      headers={'Content-Type': 'application/json'},
      json={
          'accountRef': 'ref_test_001',
          'accountName': 'John Doe',
          'currency': 'NGN',
      },
  )
  print(response.json())
  ```
</CodeGroup>

```json Response theme={null}
{
  "code": "00",
  "description": "Success",
  "data": {
    "accountNumber": "9900012345",
    "accountName": "John Doe",
    "bankName": "Nomba",
    "bankCode": "000026",
    "accountRef": "ref_test_001",
    "currency": "NGN"
  }
}
```

***

## Create a checkout order

Generate a payment link your customers can use to pay.

<CodeGroup>
  ```bash cURL theme={null}
  curl --request POST \
    --url https://sandbox.nomba.com/v1/checkout/order \
    --header 'Content-Type: application/json' \
    --data '{
      "order": {
        "orderReference": "order_test_001",
        "amount": "10000.00",
        "currency": "NGN",
        "customerEmail": "test@example.com",
        "callbackUrl": "https://merchant.com/callback"
      }
    }'
  ```

  ```javascript Node.js theme={null}
  const response = await fetch('https://sandbox.nomba.com/v1/checkout/order', {
    method: 'POST',
    headers: { 'Content-Type': 'application/json' },
    body: JSON.stringify({
      order: {
        orderReference: 'order_test_001',
        amount: '10000.00',
        currency: 'NGN',
        customerEmail: 'test@example.com',
        callbackUrl: 'https://merchant.com/callback',
      },
    }),
  });
  const data = await response.json();
  console.log(data);
  ```

  ```python Python theme={null}
  import requests

  response = requests.post(
      'https://sandbox.nomba.com/v1/checkout/order',
      headers={'Content-Type': 'application/json'},
      json={
          'order': {
              'orderReference': 'order_test_001',
              'amount': '10000.00',
              'currency': 'NGN',
              'customerEmail': 'test@example.com',
              'callbackUrl': 'https://merchant.com/callback',
          }
      },
  )
  print(response.json())
  ```
</CodeGroup>

```json Response theme={null}
{
  "code": "00",
  "description": "Success",
  "data": {
    "checkoutLink": "https://checkout.nomba.com/sandbox/<encrypted-ref>",
    "orderReference": "order_test_001"
  }
}
```

Open the `checkoutLink` in your browser to see the full payment UI. Use the [test cards](/docs/products/accept-payment/sandbox-testing#test-card-numbers) to simulate different payment outcomes.

***

## Ready to go further?

Once you've explored the sandbox, create a free Nomba account to get your own credentials and go live.

<CardGroup cols={2}>
  <Card title="Create an account" icon="user-plus" href="https://dashboard.nomba.com/signup">
    Get your API keys and start building in minutes.
  </Card>

  <Card title="Full sandbox guide" icon="flask" href="/docs/products/accept-payment/sandbox-testing">
    Test cards, webhooks, and error simulation for Checkout.
  </Card>

  <Card title="Authentication" icon="shield-check" href="/docs/getting-started/authentication">
    Learn how bearer tokens and accountId work.
  </Card>

  <Card title="API Reference" icon="code" href="/nomba-api-reference/introduction">
    Browse all available endpoints.
  </Card>
</CardGroup>
