Skip to main content
This is the API reference for integrating Nomad Pay’s “API Order” method.

Base URL

All API requests should be sent to: https://api.nomadpay.io

Create a Payment

This endpoint is used to initiate a payment request and generate a payment URL for the user.
  • Endpoint: POST /v1/payments
  • Method: POST
  • Content-Type: application/json
  • Signature Algorithm: Ed25519

Request Headers

Request Body

The request body must be a JSON object. Example Request Body:

Generating the Signature

To create the x-signature, you must sign the raw JSON request body using your Ed25519 Secret Key (Private Key). Process:
  1. Serialize the Body: Convert your JSON request body into a raw string, with no extra spaces or line breaks.
  2. Sign the String: Use your Ed25519 private key (from your hex seed) to sign the byte array of the string from step 1.
  3. Encode the Signature: Convert the resulting signature into a Hex-encoded string.
  4. Set the Header: Place this Hex string into the x-signature header.
Example (Go):

Responses

Success Response
  • Code: HTTP 200 OK
  • Body:
  • Action: You must redirect your user to the payment_url provided.
Error Response
  • Code: HTTP 4xx/5xx
  • Body:
  • Error Codes:
    • 1001: Parameter validation failed
    • 1002: API key is required
    • 1003: Invalid signature
    • 1004: Nonce has already been used
    • 2001: Internal server error