Payment Links

curl --location 'https://onionpay.herokuapp.com/api/d1/payment-pages'
{
  "success": true,
  "pages": [
    {
      "p_id": "1674223761668",
      "active": true,
      "m_id": "v13V07H15Y00B19B19B19V07V07R03Y00v01v01",
      "url": "https://onionpay.com/pay/aabgDJ2",
      "title": "Payment Page Title",
      "fixed": true,
      "link": "aabgDJ2",
      "b_id": "1674222669488",
      "amount": 5700
    },
    {
      "title": "Test Payment Page",
      "b_id": "1674222669488",
      "p_id": "1674223792756",
      "m_id": "v13V07H15Y00B19B19B19V07V07R03Y00v01v01",
      "link": "aabgDJ3",
      "active": true,
      "url": "https://onionpay.com/pay/aabgDJ3",
      "amount": 2700,
      "fixed": true
    },
    {
      "fixed": true,
      "b_id": "1674222669488",
      "active": true,
      "url": "https://onionpay.com/pay/aabgDJ4",
      "amount": 8000,
      "p_id": "1674223806860",
      "title": "New Payment Page",
      "link": "aabgDJ4",
      "m_id": "v13V07H15Y00B19B19B19V07V07R03Y00v01v01"
    }
  ]
}

There are two types of payment pages:

  1. Fixed payment page

  2. Variable payment page

Fixed payment page

In a fixed payment page, when you see a fixed price attached to a product, the price is non-negotiable, and you are required to pay that exact amount to purchase the product. The price will be clearly displayed, and there will be no room for bargaining or negotiation.

For example, if you see a book for sale with a fixed price of ₦2,000, you will need to pay ₦2,000 to purchase the book. The price will not change based on negotiations or any other factors.

Variable payment page

In a variable payment page, the price is not fixed or pre-determined, and it can vary based on the items or services being purchased. The exact amount to be paid may not be clear from the outset, and negotiation may be required.

For example, if you visit a flea market, the merchant may not have a fixed price for each item, and you may be able to bargain for a lower price. Alternatively, the merchant may offer you a package deal for a group of items, where the exact amount to be paid is not clear upfront. In this case, you may agree to pay a certain amount for the items, and then sort out which items you are purchasing with the merchant afterwards.

When a payment link is used to make a payment, a receipt is sent to the client and then a notification is sent to the merchant.

Last updated