Our mission is to make paying with Nano simple & affordable

This section will explain how to use MakeNanoWork to use it on your application. For legal and other information, please contact us.

Disclaimer

Some regions might require KYC or AMF procedures to be put in place before customers send any form of cryptocurrency to your platform. If you operate in such an area, it is your responsibility to ensure the compliance of your application with these regulations.

Access

After verifying your business through KYB, you will be authorized on your API management portal.

By logging in, I consent to the use of cookies for authentication purposes.

Payment Process Overview

When a customer initiates a checkout process within your application, it is necessary to prepare the payment for their order. MakeNanoWork supports two distinct scenarios: a balance refill, where the amount received can vary, or a strict expected amount, where the payment must match a predefined value. In both cases, the payment flow follows the same structure.

As outlined in the Terms and Conditions, it is the seller's responsibility to ensure that the customer fully understands the steps required to complete the payment. MakeNanoWork is not liable for any issues arising from customer errors, such as sending funds multiple times, using an incorrect address, utilizing an expired payment link, or any misuse of your application. Refunds will not be issued under these circumstances. MakeNanoWork assumes no responsibility for any problems occurring within your application.
In the event of a technical issue, please contact our support team immediately, and we will do all we can to resolve the issue promptly.

MakeNanoWork operates as a server API and is intended for use exclusively with your backend server. Exposing your API key to client-side applications will most certainly compromise the security of your account.

The payment process begins with a request to MakeNanoWork for a temporary payment address. Customers must send their payment to this address to ensure proper identification. These temporary addresses, referred to as "links," can be customized with additional data to help identify the order, basket, or user associated with the transaction. Each link has a maximum lifespan of 30 minutes and includes a unique Nano account address, which should be used only once. You should not explicitly forbid payments links with a past expiration date, as MakeNanoWork might grant grace periods in case a user initiates a payment close to a link expiration date. Please note that MakeNanoWork only supports transactions with a minimum value of 0.1 XNO. Any amount below this threshold will be irretrievably lost. Similarly, MakeNanoWork will not accept payments above 1000XNO without prior consultation.

Through your management panel, you can configure a forward address and a webhook URL. Once funds are received from your customers, MakeNanoWork will forward 99% of the payment to the designated forward address. Upon successful transfer, a webhook will be triggered once. If your server fails to receive the webhook, you can verify the status of your payment links using our REST API. Each link is assigned a unique ID, which should be stored in your database for future reference and interaction with the REST API.

A payment is considered accepted if it meets the following criteria:
1. The amount exceeds the minimum threshold of 0.1 XNO.
2. If the link was created with an expected amount, the received amount must match exactly.
3. If the link was created with a maximum amount, the received amount must be less than or equal to the specified value.
4. The transaction blocks on the blockchain are confirmed.
Full refunds will be issued to customers in two scenarios: if the Nano forward address is removed during the payment process, or if the customer sends an amount that does not match the required value.

sequence diagram

* (1) Include Relevant Metadata: Please provide any metadata that will assist in identifying the cart, customer, or invoice associated with the transaction being processed.
* (2) Webhook Notification on Success: The webhook will be triggered exclusively upon successful processing. It will include the same data as the GET API response, including any additional metadata submitted as part of the initial request (as outlined in point 1).
* (3) Polling for Processing Status: To monitor the status of the transaction, you may poll the designated API endpoint. It is advisable to limit polling to instances where the customer is actively awaiting the completion of the process. A polling interval of every 2 seconds is recommended for optimal performance. Once the funds have been received by MakeNanoWork (received_at), it is recommended to conceal the XNO account to prevent the customer from inadvertently sending multiple payments.

Authentication and preface

To authenticate your requests, use the header "x-api-key". Its value must correspond to your API key.

All dates used in responses are at UTC time.

API endpoints

Creating a link

Creating a link will generate work on the node. Because of that, please only generate a link when you are certain your customer will make a purchase with Nano. Requesting too many operations requiring work can slow down operations.

Request:
POST https://www.makenano.work/api/links

{
    metadata: Json, // Any JSON value that will help you identify the purchase made. You can also set a secret for the Webhook call. Can be an object.
    expires_at: Date or Null, // By default, links have a lifespan of 30 minutes. Allowed values are from 10 to 40 minutes from current time.
    expected_amount: Float // If you are expecting a specific amount to be paid for the purchase set this value here in Nano (>= 0,1). This value will be truncated to two decimals maximum.
    maximum_amount: Float // If you want to cap the amount to be received, use this field (>= 0.1, <= 1000).
}
                            
Response:
{
    id: Uuid, // Unique identifier of your payment link
    exposed_xno_account_address: String, // The Nano account your customer must send the currency to, as string
    metadata: Value, // The same data that you sent in the metadata field during the request
    expires_at: Date, // Date at which the link will expire. Funds sent after this date will be disregarded.
    expected_amount_raw: String or Null, // Same value than expected_amount in the request in raw
    received_at: Date or Null, // If the customer's payment has been received by MakeNanoWork, this field will contain the reception date. Funds sent after this date will be disregarded.
    forwarded_at: Date or Null, // If the customer's payment was successful, this is the date at which the send block to your forward account has been created
    refunded_at: Date or Null, // If the customer was refunded for any reason, this is the date at which the refund was sent.
    transaction_finished_at: Date or Null, // Independently of the success of the payment, this value is set when the flow finishes
    maximum_amount_raw: String, // The maximum amount this link will accept in raw
}
                            

Getting a link

Constant polling of a link for tracking progress is not recommended. You can poll a link every few seconds if your customer is actively waiting for updates on the payment. For general use, it is highly recommended to use the Webhook to base your business logic on.
GET https://www.makenano.work/api/links/{uuid}

{
    id: Uuid, // Unique identifier of your payment link
    exposed_xno_account_address: String, // The Nano account your customer must send the currency to, as string
    metadata: Value, // The same data that you sent in the metadata field during the request
    expires_at: Date, // Date at which the link will expire. Funds sent after this date will be disregarded.
    expected_amount_raw: String or Null, // Same value than expected_amount in the request in raw
    received_at: Date or Null, // If the customer's payment has been received by MakeNanoWork, this field will contain the reception date. Funds sent after this date will be disregarded.
    forwarded_at: Date or Null, // If the customer's payment was successful, this is the date at which the send block to your forward account has been created
    refunded_at: Date or Null, // If the customer was refunded for any reason, this is the date at which the refund was sent.
    transaction_finished_at: Date or Null, // Independently of the success of the payment, this value is set when the flow finishes
    qrcode: String, // Same as exposed_xno_account_address as a base64 encoded PNG
    received_amount: Float or Null, // If a payment from the customer has been received and is valid, this is the amount received by MakeNanoWork in Nano
    received_amount_raw: String or Null // If a payment from the customer has been received and is valid, this is the amount received by MakeNanoWork in raw Nano
    maximum_amount_raw: String, // The maximum amount this link will accept in raw
}
                            

Webhooks

Upon successful payment, currency will be transferred to your forward address. Then, two values are saved, as you can see on the REST API: "forwarded_at" and "transaction_finished_at" are set to the current date.
It is also at this moment, and only this moment, that a webhook is triggered. Responding to this call with a code 200 within 5 seconds will mark it as succeeded.
POST {your-webhook-url}

{
    id: Uuid, // Unique identifier of your payment link
    exposed_xno_account_address: String, // The Nano account your customer must send the currency to, as string
    metadata: Value, // The same data that you sent in the metadata field during the request
    expires_at: Date, // Date at which the link will expire. Funds sent after this date will be disregarded.
    expected_amount_raw: String or Null, // Same value than expected_amount in the request in raw
    received_at: Date or Null, // If the customer's payment has been received by MakeNanoWork, this field will contain the reception date. Funds sent after this date will be disregarded.
    forwarded_at: Date or Null, // If the customer's payment was successful, this is the date at which the send block to your forward account has been created
    refunded_at: Date or Null, // If the customer was refunded for any reason, this is the date at which the refund was sent.
    transaction_finished_at: Date or Null, // Independently of the success of the payment, this value is set when the flow finishes
    received_amount: Float or Null, // If a payment from the customer has been received and is valid, this is the amount received by MakeNanoWork in Nano
    received_amount_raw: String or Null // If a payment from the customer has been received and is valid, this is the amount received by MakeNanoWork in raw Nano
    maximum_amount_raw: String, // The maximum amount this link will accept in raw
}