Create Payment
Last updated
Last updated
Creating a payment requires a simple request, containing just API keys as authorisation and the payment parameters.
POST
https://api.piecard.app/payment
Name | Type | Description |
---|---|---|
Test Mode: You can set sandbox mode to true to easily test you integration. Please see here for test mode usage.
From the POST /payment endpoint, you will receive a payment ID.
To initiate the payment, you must redirect the user to 'https://piecard.app/pay/YOUR_PAYMENT_ID'
amount*
number
The amount of Pi being requested. This includes the transaction fee.
memo*
string
Something to describe the payment to the user.
successURL*
string
The redirect URL for a successful payment.
cancelURL*
string
The redirect URL for a failed payment.
metadata
object
Any set object-key pairs for the developer's use. This will be included in the webhook.
sandbox
boolean
Set to true for testing you payment integration. Default is false.