Easily redirect from any iOS app or website, directly into the Payment app to get paid.
The iOS Payment app recognizes the URL schema starting with:
payment://new?amount=2000¤cy=usd&description=Cat+sweater&name=John+Doe&email=john@doe.com
At the moment, Payment can only populate new charges.
payment://new?
Add an amount, in cents:
payment://new?amount=2000
Choose a supported currency:
payment://new?currency=usd
Add a URL encoded description for the charge:
payment://new?description=Cat+Sweater
Add an URL encoded name for the customer:
payment://new?name=John+Doe
Provide an email address for a receipt:
payment://new?email=john@doe.com
Supported in iOS v5.04 or later. Upon a successful transaction, the Payment app will return to your app.
payment://new?callback=https://foo.bar.com/hook
In addition to iOS automatically dropping you back to your website, we'll also return a few bits of information including:
{
"success" : true,
"amount" : 2000,
"currency" : "usd",
"chargeId" : "pi_xxxxxx" // from Stripe
}
From there, you'll be able to retrieve the charge ID, or do any processing and messaging you may need for your customers.
In the event of an error, you may receive a message formatted as:
{
"error" : {
"message" : "Generic error message",
}
}