ndeipipayments APIv1 · 0.1.0-draftAPI reference

API reference

Rates and routes

What can move where, at what price and within what limits. Read routes at run time instead of hard-coding rails.

List supported routes

GET/v1/routes

Every source the server accepts, with the destinations it reaches, amount limits, precision and settlement estimates. Rails appear only as data here; Don't hard-code them. Not paginated.

Returns a list of Route objects.

Query parameters

kindstring

One of user_to_user, conversion, onramp, offramp.

countrystring

ISO 3166-1 alpha-2 country code.

Responses

  • 200All routes matching the filters.
  • 401The API key is missing, invalid or revoked.
  • 429The key is over its rate limit.
  • 5XXServer error. Safe to retry with the same idempotency key.
Request
curl "https://sandbox.api.ndeipi.example/v1/routes?kind=onramp" \
  -H "Api-Key: $NDEIPI_API_KEY"
Response 200
{
  "data": [
    {
      "kind": "onramp",
      "source": {
        "type": "fiat",
        "currency": "zar",
        "rail": "absa_eft",
        "country": "ZA",
        "decimals": 2
      },
      "destination": {
        "type": "wallet",
        "asset": "ndeipi-points",
        "decimals": 2
      },
      "min_amount": "10.00",
      "max_amount": "50000.00",
      "settlement_time_seconds": 86400,
      "available": true
    }
  ]
}

Get the price of points in a currency

GET/v1/rates

Returns Rate.

Query parameters

fromstringrequired

Source currency or asset.

tostringrequired

Destination currency or asset.

Responses

  • 200The current rate.
  • 400The request is malformed.
  • 401The API key is missing, invalid or revoked.
  • 422The request is well formed but fails validation or a business rule.
  • 429The key is over its rate limit.
  • 503The on-ramp or off-ramp provider is unavailable and the request was refused rather than queued. Code provider_unavailable. User-to-user transfers never return this.
  • 5XXServer error. Safe to retry with the same idempotency key.
Request
curl "https://sandbox.api.ndeipi.example/v1/rates?from=zar&to=ndeipi-points" \
  -H "Api-Key: $NDEIPI_API_KEY"
Response 200
{
  "object": "rate",
  "from": "zar",
  "to": "ndeipi-points",
  "rate": "1",
  "type": "fixed",
  "as_of": "2026-10-16T09:30:00Z",
  "expires_at": null
}

Lock a price for a conversion

POST/v1/quotes

Locks the price for converting an amount between Ndeipi Points and NdeipiCoin, for a short time (expires_at, 30 seconds by default). Pass its id as quote_id on the conversion transfer. The price includes Ndeipi's spread, shown separately in fees.

NdeipiCoin is bought for Ndeipi's stock through a manual OTC desk, so the price comes from what Ndeipi last paid and is refreshed by its treasury team. A quote larger than Ndeipi's stock, or than the treasury can back with new points, returns 422 insufficient_liquidity.

Returns Quote.

Headers

Idempotency-Keyheaderrequired

A unique key for this write, up to 255 characters. Send the same key to retry safely; see idempotency.

Body

source_wallet_idstringrequired

The wallet paying, in points to buy NdeipiCoin or in NdeipiCoin to sell it.

Starts with wal_.

destination_wallet_idstringrequired

The same user's wallet in the other asset.

Starts with wal_.

amountstringrequired

In the source wallet's asset.

Responses

  • 201Quote locked.
  • 400The request is malformed.
  • 401The API key is missing, invalid or revoked.
  • 403The key may not perform this action, or the user is not approved.
  • 404The object does not exist or belongs to another integrator.
  • 422The request is well formed but fails validation or a business rule.
  • 429The key is over its rate limit.
  • 503NdeipiCoin has no current price: no OTC trade has been recorded, or the last one is older than Ndeipi allows quoting from. Code provider_unavailable. Retry later.
  • 5XXServer error. Safe to retry with the same idempotency key.
Request
curl -X POST "https://sandbox.api.ndeipi.example/v1/quotes" \
  -H "Api-Key: $NDEIPI_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{
    "source_wallet_id": "wal_01JA8Z4K2V9QW3H6Y7XKD2M0RS",
    "destination_wallet_id": "wal_01JA8Z9X1Y2Z3A4B5C6D7E8F9G",
    "amount": "50.00"
  }'
Response 201
{
  "id": "qt_01JA8ZJ6XS3V8E1C9B6A5Z4Y3X",
  "object": "quote",
  "source_wallet_id": "wal_01JA8Z4K2V9QW3H6Y7XKD2M0RS",
  "destination_wallet_id": "wal_01JA8Z9X1Y2Z3A4B5C6D7E8F9G",
  "from": "ndeipi-points",
  "to": "ndeipi-coin",
  "amount": "50.00",
  "rate": "0.0890625",
  "amount_out": "4.45312500",
  "fees": [
    {
      "type": "ndeipi",
      "amount": "0.75",
      "unit": "ndeipi-points"
    }
  ],
  "status": "open",
  "transfer_id": null,
  "expires_at": "2026-10-16T09:30:30Z",
  "created_at": "2026-10-16T09:30:00Z"
}

Get a quote

GET/v1/quotes/{quote_id}

Returns Quote.

Path parameters

quote_idstringrequired

Starts with qt_.

Responses

  • 200The quote.
  • 401The API key is missing, invalid or revoked.
  • 404The object does not exist or belongs to another integrator.
  • 429The key is over its rate limit.
  • 5XXServer error. Safe to retry with the same idempotency key.
Request
curl "https://sandbox.api.ndeipi.example/v1/quotes/qt_01JA8ZJ6XS3V8E1C9B6A5Z4Y3X" \
  -H "Api-Key: $NDEIPI_API_KEY"
Response 200
{
  "id": "qt_01JA8ZJ6XS3V8E1C9B6A5Z4Y3X",
  "object": "quote",
  "source_wallet_id": "wal_01JA8Z4K2V9QW3H6Y7XKD2M0RS",
  "destination_wallet_id": "wal_01JA8Z9X1Y2Z3A4B5C6D7E8F9G",
  "from": "ndeipi-points",
  "to": "ndeipi-coin",
  "amount": "50.00",
  "rate": "0.0890625",
  "amount_out": "4.45312500",
  "fees": [
    {
      "type": "ndeipi",
      "amount": "0.75",
      "unit": "ndeipi-points"
    }
  ],
  "status": "open",
  "transfer_id": null,
  "expires_at": "2026-10-16T09:30:30Z",
  "created_at": "2026-10-16T09:30:00Z"
}