Accepting Your First Payment

To have your shoppers pay through the Confirmo gateway you have to redirect them to the hosted checkout with an invoice URL. To get the invoice URL you need to make a REST POST request to the https://confirmo.net/api/v3/invoices endpoint.

curl --location 'https://confirmo.net/api/v3/invoices' \
--header 'Authorization: Bearer [YOUR_CONFIRMO_API_KEY]' \
--header 'Content-Type: application/json' \
--data '@data.json'

The request body can look like in the example below.

data = {
    "invoice": {
        "currencyFrom": "USD",
        "amount": 100
    },
    "settlement": { "currency": "USDC" },
    "product": { "name": "example product" },
    "returnUrl": "https://yourEShop.com/orderReceived",
    "notifyUrl": "https://yourEShop.com/orderReceived"
};

In Confirmo’s checkout the shopper will choose their preferred cryptocurrency and blockchain to complete the payment. The amount of the cryptocurrency in the invoice will correspond to the base amount in fiat you have created the payment for. This information is derived from the invoice object and the fields amount and currencyFrom. For request detail see the endpoint documentation.

The currency specified in the settlement object is the currency that will be settled to your Confirmo account. If set to null the invoice will be credited to the merchant account in the same crypto asset as the customer used for the payment.

To properly receive all webhook notifications regarding to this payment don’t forget to pass the notifyUrl. To redirect the shopper back to your order confirmation page after they have successfully paid you need to fill in the returnUrl parameter.

Finally, don’t forget to properly handle the required Travel rule documentation for a smooth checkout experience for your shopper.



What’s Next