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

# Create a funding account

> Create a way for a customer to send NGN or crypto into Daya

<RequestExample>
  ```bash Create NGN funding account theme={null}
  curl --request POST \
    --url https://api.daya.co/v1/funding-accounts \
    --header 'Content-Type: application/json' \
    --header 'X-Api-Key: YOUR_API_KEY' \
    --header 'X-Idempotency-Key: create-funding-account-001' \
    --data '{
      "type": "TEMPORARY",
      "rail": "NGN_VIRTUAL_ACCOUNT",
      "customer": {
        "customer_id": "650e8400-e29b-41d4-a716-446655440000"
      },
      "currency": "NGN",
      "amount": 50000,
      "developer_fee": {
        "percentage": "2.5"
      },
      "settlement_destination": {
        "type": "ONCHAIN",
        "rate_id": "550e8400-e29b-41d4-a716-446655440000",
        "destination_asset": "USDC",
        "destination_chain": "BASE",
        "destination_address": "0x742d35cc6634c0532925a3b844bc9e7595f2bd18"
      }
    }'
  ```

  ```bash Create crypto funding account theme={null}
  curl --request POST \
    --url https://api.daya.co/v1/funding-accounts \
    --header 'Content-Type: application/json' \
    --header 'X-Api-Key: YOUR_API_KEY' \
    --header 'X-Idempotency-Key: create-funding-account-002' \
    --data '{
      "type": "PERMANENT",
      "rail": "CRYPTO_ADDRESS",
      "customer": {
        "customer_id": "650e8400-e29b-41d4-a716-446655440000"
      },
      "asset": "USDC",
      "chain": "BASE",
      "settlement_destination": {
        "type": "INTERNAL_BALANCE"
      }
    }'
  ```
</RequestExample>

## Overview

Create a funding account for an existing customer. The response includes the public funding account object and the payment details the customer can use once setup succeeds.

<Note>
  `customer.customer_id` is required. This endpoint does not create customers inline.
</Note>

## Authentication

<ParamField header="X-Api-Key" type="string" required>
  Your merchant API key
</ParamField>

<ParamField header="X-Idempotency-Key" type="string" required>
  Unique idempotency key for request deduplication
</ParamField>

## Request Body

<ParamField body="type" type="string" required>
  Funding account type. Allowed values: `TEMPORARY`, `PERMANENT`.
</ParamField>

<ParamField body="rail" type="string" required>
  Receive rail. Allowed values: `NGN_VIRTUAL_ACCOUNT`, `CRYPTO_ADDRESS`.
</ParamField>

<ParamField body="customer" type="object" required>
  Existing customer details. Include `customer_id`. For permanent NGN virtual accounts, the customer must have completed Tier 1 KYC.
</ParamField>

<ParamField body="currency" type="string">
  Required for `NGN_VIRTUAL_ACCOUNT`. Must be `NGN`.
</ParamField>

<ParamField body="asset" type="string">
  Required for `CRYPTO_ADDRESS`. Supported values: `USDC`, `USDT`.
</ParamField>

<ParamField body="chain" type="string">
  Required for `CRYPTO_ADDRESS`.
</ParamField>

<ParamField body="amount" type="integer">
  Required for temporary NGN virtual accounts. Accepted only for `TEMPORARY` accounts.
</ParamField>

<ParamField body="developer_fee" type="object">
  Optional fee that your merchant account keeps from each deposit received through this funding account. Omit to use `0%`.

  <Expandable title="developer_fee properties">
    <ParamField body="developer_fee.percentage" type="string" required>
      Percentage of each received deposit that your merchant account keeps. Use a decimal string from `0` to `50`. This is a percentage value, not basis points: `0.5` means `0.5%`, `2` means `2%`, and `50` means `50%`.

      **Example:** `"2.5"`
    </ParamField>
  </Expandable>
</ParamField>

### `settlement_destination`

`settlement_destination` is a nested object. Do not send dotted keys such as `settlement_destination.type`.

| Field                 | Type   | Required when                                                                                                                                                                                                                                                             |
| --------------------- | ------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `type`                | string | Always. Allowed values depend on the funding account `rail` and `type`; see the matrix below.                                                                                                                                                                             |
| `rate_id`             | string | Required for temporary funding accounts that use a quoted conversion: temporary `NGN_VIRTUAL_ACCOUNT` accounts settling to `INTERNAL_BALANCE` or `ONCHAIN`, and temporary `CRYPTO_ADDRESS` accounts settling through `NGN_PAYOUT`. Do not send it for permanent accounts. |
| `destination_asset`   | string | `rail` is `NGN_VIRTUAL_ACCOUNT` and `type` is `ONCHAIN`. Supported values: `USDC`, `USDT`.                                                                                                                                                                                |
| `destination_chain`   | string | `rail` is `NGN_VIRTUAL_ACCOUNT` and `type` is `ONCHAIN`.                                                                                                                                                                                                                  |
| `destination_address` | string | `rail` is `NGN_VIRTUAL_ACCOUNT` and `type` is `ONCHAIN`.                                                                                                                                                                                                                  |
| `destination_bank`    | object | `rail` is `CRYPTO_ADDRESS` and `type` is `NGN_PAYOUT`. Fixed request shape: `account_number`, `bank_code`.                                                                                                                                                                |

#### Allowed settlement destination types

| `rail`                | Funding account `type` | Allowed `settlement_destination.type` values |
| --------------------- | ---------------------- | -------------------------------------------- |
| `NGN_VIRTUAL_ACCOUNT` | `TEMPORARY`            | `INTERNAL_BALANCE`, `ONCHAIN`                |
| `NGN_VIRTUAL_ACCOUNT` | `PERMANENT`            | `INTERNAL_BALANCE`, `ONCHAIN`                |
| `CRYPTO_ADDRESS`      | `TEMPORARY`            | `NGN_PAYOUT`                                 |
| `CRYPTO_ADDRESS`      | `PERMANENT`            | `INTERNAL_BALANCE`, `NGN_PAYOUT`             |

Do not send `NGN_PAYOUT` for `NGN_VIRTUAL_ACCOUNT` funding accounts, and do not send `ONCHAIN` for `CRYPTO_ADDRESS` funding accounts.

#### `destination_bank`

| Field            | Type   | Required |
| ---------------- | ------ | -------- |
| `account_number` | string | Yes      |
| `bank_code`      | string | Yes      |

Before sending `destination_bank`, fetch supported banks with [`GET /v1/banks`](/api-reference/banks/list-banks), then verify the account with [`POST /v1/banks/resolve`](/api-reference/banks/resolve-bank-account). Use the verified `bank_code` and `account_number` in the funding account request. Do not send `account_name`; Daya returns the resolved account name in the funding account response.

## Settlement Destination Shapes

```json Internal balance theme={null}
{
  "settlement_destination": {
    "type": "INTERNAL_BALANCE",
    "rate_id": "550e8400-e29b-41d4-a716-446655440000"
  }
}
```

<Note>
  For temporary funding accounts, `rate_id` is required and the rate is locked for the temporary account's validity window. For permanent funding accounts, omit `rate_id`; the rate is applied when each deposit is processed.
</Note>

```json NGN virtual account to onchain settlement theme={null}
{
  "settlement_destination": {
    "type": "ONCHAIN",
    "rate_id": "550e8400-e29b-41d4-a716-446655440000",
    "destination_asset": "USDC",
    "destination_chain": "BASE",
    "destination_address": "0x742d35cc6634c0532925a3b844bc9e7595f2bd18"
  }
}
```

```json Crypto address to NGN payout settlement theme={null}
{
  "settlement_destination": {
    "type": "NGN_PAYOUT",
    "rate_id": "550e8400-e29b-41d4-a716-446655440000",
    "destination_bank": {
      "account_number": "0123456789",
      "bank_code": "058"
    }
  }
}
```

For `NGN_PAYOUT`, `destination_bank` has a fixed request shape: `account_number` and `bank_code`. Get the supported bank first, resolve the account, then send the verified details.

## Request Examples

<CodeGroup>
  ```json NGN temporary to onchain theme={null}
  {
    "type": "TEMPORARY",
    "rail": "NGN_VIRTUAL_ACCOUNT",
    "customer": {
      "customer_id": "650e8400-e29b-41d4-a716-446655440000"
    },
    "currency": "NGN",
    "amount": 50000,
    "developer_fee": {
      "percentage": "2.5"
    },
    "settlement_destination": {
      "type": "ONCHAIN",
      "rate_id": "550e8400-e29b-41d4-a716-446655440000",
      "destination_asset": "USDC",
      "destination_chain": "BASE",
      "destination_address": "0x742d35cc6634c0532925a3b844bc9e7595f2bd18"
    }
  }
  ```

  ```json Crypto permanent to balance theme={null}
  {
    "type": "PERMANENT",
    "rail": "CRYPTO_ADDRESS",
    "customer": {
      "customer_id": "650e8400-e29b-41d4-a716-446655440000"
    },
    "asset": "USDC",
    "chain": "BASE",
    "settlement_destination": {
      "type": "INTERNAL_BALANCE"
    }
  }
  ```
</CodeGroup>

## Response

Returns a `funding_account` object. For NGN funding accounts, the bank account the customer should pay into is returned in `instructions`.

```json NGN funding account response theme={null}
{
  "object": "funding_account",
  "id": "750e8400-e29b-41d4-a716-446655440000",
  "type": "TEMPORARY",
  "status": "ACTIVE",
  "rail": "NGN_VIRTUAL_ACCOUNT",
  "customer_id": "650e8400-e29b-41d4-a716-446655440000",
  "currency": "NGN",
  "amount": 50000,
  "developer_fee": {
    "percentage": "2.5"
  },
  "settlement_destination": {
    "type": "ONCHAIN",
    "rate_id": "550e8400-e29b-41d4-a716-446655440000",
    "destination_asset": "USDC",
    "destination_chain": "BASE",
    "destination_address": "0x742d35cc6634c0532925a3b844bc9e7595f2bd18"
  },
  "instructions": [
    {
      "type": "NGN_VIRTUAL_ACCOUNT",
      "status": "ACTIVE",
      "bank_name": "Wema Bank",
      "bank_code": "035",
      "account_number": "1234567890",
      "account_name": "Daya - Ada Lovelace",
      "currency": "NGN"
    }
  ],
  "created_at": "2026-01-05T15:04:05Z",
  "updated_at": "2026-01-05T15:04:10Z"
}
```

For crypto funding accounts, `asset` identifies the stablecoin the address should receive, `chain` identifies the network, and `instructions` contains the wallet address.
