Startbutton Product API
  • Startbutton API doc
    • Get Started
    • Accept Payments
    • Server-to-Server Integration
      • S2S Integration for Virtual Accounts
        • S2S Virtual account (NGN)
        • S2S Virtual account (GHS)
        • S2S EFT (ZAR)
      • S2S Integration for Mobile Money
        • S2S MoMo (KES and GHS)
        • S2S MoMo (TZS and UGX)
        • S2S MoMo (RWF)
        • S2S MoMo XOF and XAF
    • Re-charge Card
    • Subscriptions
    • Payment Links
    • Currency Conversion
    • Get Wallet Balance
    • Transfer
      • Bank List
    • Security Measures.
      • IP Whitelisting
    • Webhook
    • Transaction Status
    • Get FX Rate
    • Under and Overpayments
    • Refunds
      • Refund Transaction Status (TSQ)
    • Available Currencies
    • FAQs
  • Advanced Security
    • Signed Payload for Transfer Requests.
Powered by GitBook
On this page
  1. Startbutton API doc

Payment Links

This feature helps you accept payment for your products or services from your customers seamlessly via a unique URL. Once the basic details described below are provided a unique link is generated and can be shared with your customers to make payment via any of our supported currencies.

Create payment link

BaseUrls

PROD : https://api.startbutton.tech

DEV/ Staging: https://api-dev.startbutton.tech

POST - {{baseurl}}/paymentlink

Authorization
Set value to `Bearer SECRET_KEY`

Content-type

Set value to application/json

Param
Required?
Description

title

Yes

This should be the name/title of the payment link

currency

Yes

Allowed values are: USD, NGN, GHS, KES or ZAR only

amount

Yes

This should be in fractional units (kobo for NGN, cents for USD). 300NGN will be passed as 30000

isFixedAmount

Yes

This should be either true or false.

If set to "true", your customers would be required to pay the amount in your request body.

If "false" it acts as a donation link; whereby the amount in your request will be displayed as a mere suggestion to your customers. However, your customers can enter their preferred payment amount.

type

Yes

This should always be passed as easy

purpose

No

This is a description of the payment link that should appear on the your dashboard when viewing the link

If the API call is successful, we will return a URL which you can share with your customers to input their payment information in order to complete the transaction.

Here's a sample request and response

Sample request:

{
  "title": "The test link",
  "currency": "NGN",
  "amount": 10000,
  "isFixedAmount": true,
  "type": "easy"
}
{
  "title": "The test link",
  "currency": "NGN",
  "amount": 10000,
  "isFixedAmount": true,
  "type": "easy",
  "purpose": "Collect semo payment"
}

Sample response:

{
    "success": true,
    "message": "success",
    "data": {
        "paymentLink": {
            "merchantId": "64c7bd870821e8xxxxxxxxxx",
            "link": "{paymentCode}",
            "title": "The test link",
            "currency": "NGN",
            "code": "8ad6d861ba6f",
            "amount": 10000,
            "isFixedAmount": true,
            "active": true,
            "deleted": false,
            "type": "easy",
            "customEmails": [],
            "_id": "65d387381c37d1xxxxxxxxxx",
            "createdAt": "2024-02-19T16:52:08.127Z",
            "updatedAt": "2024-02-19T16:52:08.127Z",
            "__v": 0
        }
    }
}
PreviousSubscriptionsNextCurrency Conversion

Last updated 2 months ago