NovyPay Token

Overview

NovyPay Tokens act like virtual debit/credit cards but operate with USDC instead of fiat currency. Merchants can use the NovyPay API to collect USDC payments by initializing a payment and redirecting users to confirm.

Step 1: Create a NovyPay Token

Before initiating any payment, the user must have a NovyPay Token. This token represents their USDC "card" and allows them to authorize payments.

🔗 Go to https://novypay.app and create a token under your dashboard.

Step 2: Initialize a Payment

Endpoint

POST https://burntpay-u44m.onrender.com/payments/novypay-token/initialize/

Request Body (JSON)

{
  "amount": 20.00,
  "currency": "GBP",
  "merchant_reference": "ORDER-12345",
  "callback_url": "https://google.com" //optional
}
Field
Type
Description

amount

float

Total amount in fiat currency (e.g., GBP).

currency

string

ISO currency code (e.g., USD, GBP, EUR).

merchant_reference

string

Unique identifier for the transaction.

callback_url

string

URL to redirect users to after successful payment

Response (Success)

{
  "status": "success",
  "device": {
    "ip_address": "127.0.0.1",
    "device_info": "PostmanRuntime/7.45.0",
    "location_info": {
      "city": null,
      "region": null,
      "country": null,
      "latitude": null,
      "longitude": null,
      "org": null
    }
  },
  "message": "NovyPay Token payment initialized. Redirect user for confirmation.",
  "payment_reference": "62ba4311-a69d-4f45-83b4-e12428caf75c",
  "amount": 20.0,
  "currency": "GBP",
  "usdc_amount": 26.6,
  "token": "USDC",
  "merchant_xion_address": "xion1styv0nwtgr8ay4hy4u2gzh9c0qxjxsz4gd8vlg",
  "redirect_url": "https://novypay.app/payments/cards?reference=62ba4311-a69d-4f45-83b4-e12428caf75c"
}
Field
Description

payment_reference

Unique ID for tracking the payment.

usdc_amount

The equivalent USDC amount based on current exchange rate.

redirect_url

Redirect your user here to confirm the payment.

merchant_xion_address

Your receiving Xion address.

Step 3: Redirect the User

Immediately redirect the user to the redirect_url returned in the response:

https://novypay.app/payments/cards?reference=62ba4311-a69d-4f45-83b4-e12428caf75c

They will confirm and authorize the payment using their NovyPay Token.

While waiting for the callback, it's recommended to poll the payment status using the payment_reference to ensure payment validity.

Endpoint

GET https://burntpay-u44m.onrender.com/payments/verify/{payment_reference}

Example

GET https://burntpay-u44m.onrender.com/payments/verify/bb16cec9-8102-4ff7-a54c-f0b50f231006

Response

{
    "status": "success",
    "data": {
        "reference": "bb16cec9-8102-4ff7-a54c-f0b50f231006",
        "payment_status": "completed",
        "blockchain_data":{...}
        }
}
Field
Description

payment_status

Possible values: pending, confirmed, failed.

Security Notes

  • Always validate callbacks via signature or token headers.

  • Never assume success without verifying payment status using payment status endpoint.

  • Log all interactions and references for dispute resolution.

Last updated