Take a single payment

Get started

Taking a single payment works in the same way for partners and uses dedicated endpoints and an additional parameter. Start by familiarising yourself with single payments, including how to request a single payment and single payment status updates.

Once you're familiar with the process, you can recreate the steps with some minor differences.

Partner payment requests

Create a PIR. Send an HTTP POST request to the relevant endpoint + /api/v1/partners/payments/ including the header Authorization: Bearer <payment_token>.

Remember to include the additional mandatory parameter 'merchantId'.

Request

{
    "merchant": "1f7rhste5rj0unf6",     
    "amount": "5.95",
    "currency": "GBP",
    "destinationAccount": "GBP1",
    "description": "Web payment",
    "callbackUrl": "yoursite.com/payment-outcome-page",
    "mediaType": "URL",
    "countries": ["GB"],
    "customerReference": "P739570946",
    "merchantReference": "76FG7JQ"
}

Parameter

Description

merchant

16 digit alphanumeric merchant identifier - used to signify the merchant account you wish to request payment for.

See all available single payment parameters here.

Response

Using partner webhook notifications

When Vyne provides webhooks of payment status updates, as described here, an additional parameter will be included in the body.

Parameter

Description

merchant

The unique identifier of the merchant to whom the payment belongs.

See all available webhook parameters here.

Using partner payment status calls

You can request a status update on any payment at any time by sending an HTTP GET request to the relevant base URL + /api/v1/partners/payments/ including the headers Authorization: Bearer <payment_token>. Generate a fresh payment token for the <payment_token>.

Request

curl --location --request GET 'https://uat.app.payvyne.com/api/v1/partners/payments/<paymentId>' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer <payment_token>'

Response

{
    "merchant": "1f7rhste5rj0unf6", 
    "id": "b0175ff11f6f5752",
    "amount": "1.00",
    "currency": "GBP",
    "description": "Test payment",
    "status": "COMPLETED",
    "type": "ONE_OFF",
    "destinationAccount": "GBP3",
    "createdAt": "2021-09-27T11:22:58.203",
    "updatedAt": "2021-09-27T11:22:58.203",
    "bank": "Monzo",      
    "customerReference": "jgdw74jg",
    "merchantReference": "yegdt6t67g",
    "refundedAmount": "0.00"
}

Using partner payer details webhook notifications

If enabled for any of your merchant accounts, we will provide details of the payer's account upon confirmation of funds received. Follow the instructions on how to setup webhook notifications for payer details here.

Use the merchant parameter to identify the merchant for which the payment has been completed.

{
  "type": "PAYER_DETAILS",
  "paymentId": "628eeb4cc58f60a4",
  "merchant": "4c5539c128022dea",
  "payerName": "Jane Bloggs",
  "accountDetails": {
    "iban": "LT34 3250 0909 3475 7655",
    "accountType": "IBAN"
  },
  "timestamp": 1654694419857
}

See all available webhook parameters here.


Did this page help you?