For Individuals Sandbox Pricing FAQ Contact Us

API Documentation

In order to get paid via GiftPay for Business, make sure your business has its own website and someone who can read technical documentation

Add Your Business

Login here or Signup if you don't have an account.
Navigate to Settings -> GiftPay for Business
Click on Add your business, enter your Company name or Website name. This name will be displayed on payment screen for your customers when they pay you.
Then click on Add.
On next screen, you can upload a logo which is also going to be displayed on the payment screen. Recommended size is 600x200.
Webhook URL, Merchant code and Secret Token will be needed for API and explained in details below.

GiftPay for Business works only on Web at this moment, you can’t use mobile apps for this.

For Sandbox users

Sandbox works exactly the same way, you will simply need to replace:

https://giftpay.me/ with https://sandbox.giftpay.me/
and
https://api.giftpay.me/ with https://sandbox-api.giftpay.me/

Important! Don't forget to put production URLs, Merchant Code and Secret Token once everything is tested.

GiftPay Plugins

To make your life easier, we have created plugins for some e-commerce platforms.
They are really easy to use, read instructions for each one below.

We support:

Request a payment

There are 4 ways of getting paid via GiftPay Business depending on what kind of business you have:

1 - Page Redirect

This is the most popular and suitable for online business. Redirect your customer to your business page on GiftPay

https://giftpay.me/b/init?website_code={website_code}&amount={amount}&user_id={user_id}&unique_id={unique_id}¬es={notes}

Parameters:

{website_code} (required) - is a unique identifier of each business on GiftPay, it's provided immediately after you add your business.
{amount} (required) - integer amount in USD that your customer needs to pay.
{user_id} (required) - an identifier of the customer in your system, you can track payments with this identifier, can be any alphanumerical string.
{unique_id} (optional) - an identifier of the transaction in your system, it cannot be repeated, used to avoid duplicate payments for single invoice or order.
{notes} (optional) - notes to be shown on the payment screen.

2 - Payment Code

You can also generate a Payment code that can be entered on GiftPay App.

This method is less popular, but is a popular method for in person or over the phone transaction.

The person who wants to get paid, generates the Payment Code and the customer enters the code on GiftPay App to complete the payment.

3 - Scan QR Code

Similar to Payment Code, QR code is generated by the person who wants to get paid, this time the customer simply scans the QR and completes the payment.

QR code and Payment code are generated using the same REST API method:

https://api.giftpay.me/website-api/create-payment

POST: JSON object:

{
    "website_code": "{website_code}",
    "amount": "{amount}",
    "user_id": "{user_id}",
    "unique_id": "{unique_id}",
    "notes": "{notes}"
}
                    

4 - Merchant Code

You may not have programming skills but want to give your customers better experience by displaying your logo on payment screen.

In this case, instead of using traditional GiftPay, you can add your business and provide your Merchant Code to the customers.

Your customers can pay you by entering Merchant Code on the App, your logo and company name will be displayed on the payment screen.

Check our demo page to see how each method would look on your website.

Track Payments - Webhook URL

Each time you receive a payment or transaction status is changed, our system sends an HTTP request to the Webhook URL that you can set for each business in your account settings.

The request will be sent with order_id parameter that you should use to get detailed information about the payment.

https://your-website.com/page-where-you-put-the-logic?order_id={order_id}&nonce={nonce}

https://your-website.com/page-where-you-put-the-logic is your Webhook URL that you need to put in settings.

Order Details

Once you have the order_id, you will need to get the details by sending a POST request to our API.

URL:

https://api.giftpay.me/website-api/get-order-by-order-id

POST: JSON object:

{
    "website_code": "{website_code}",
    "order_id": "{order_id}"
}
                    

HTTP HEADER:

SECRET-TOKEN: Secret Token that is provided in business details

Response: JSON "Order" object

Search Orders

You can search transactions by user_id or unique_id that you provided while requesting a payment.

Search by user_id

URL:

https://api.giftpay.me/website-api/get-order-by-user-id

POST: JSON object:

{
    "website_code": "{website_code}",
    "user_id": "{user_id}"
}
                    

HTTP HEADER:

SECRET-TOKEN: Secret Token that is provided in business details

Response: List of JSON "Order" objects

Search by unique_id

URL:

https://api.giftpay.me/website-api/get-order-by-unique-id

POST: JSON object:

{
    "website_code": "{website_code}",
    "unique_id": "{unique_id}"
}
                    

HTTP HEADER:

SECRET-TOKEN: Secret Token that is provided in business details

Response: List of JSON "Order" objects

"Order" object

{
    "order_id": "id of the order",
    "amount_requested": "amount requested by you",
    "user_id": "user id that you provided",
    "unique_id": "unique id that you provided",
    "notes": "notes that you send",
    "amount_paid": "total amount that's paid by customer",
    "transaction_fee": "total standard transaction fee",
    "merchant_fee": "total merchant fee (extra fee for business accounts)",
    "amount_completed": "amount that is ready for withdrawal",
    "amount_pending": "amount that is paid, but can't be withdrawn yet",
    "transactions": [
        list of "Transaction" objects
    ]
}
                    

"Transaction" object

{
    "txn_id": "transaction id",
    "amount": "amount paid by customer",
    "transaction_fee": "standard transaction fee",
    "merchant_fee": "merchant fee (extra fee for business accounts)",
    "type": "how it was paid (coin/card/balance)",
    "status": "status of transaction (completed/pending/cancelled/rejected)",
    "coin_type":"type of cryptocurrency (BTC/LTC/USDT etc)", // filled only if "type" is "coin"
    "card_type":"type of gift card (walmart/target/apple etc)", // filled only if "type" is "card"
    "card_number":"**** 9999", // filled only if "type" is "card"
},