Pay action

Initializes a payment request

API endpoint: https://api.payson.se/1.0/Pay/

Pay request parameters

RequiredParameterData typeDescription
RequiredreturnUrlstring (2048)URL to which the customer’s browser is redirected after the payment is completed.Note: This includes both successful and unsuccessful payments.
RequiredcancelUrlstring (2048)URL to which the customer is redirected if the payment is manually canceled by the user before it is completed.
RecommendedipnNotificationUrlstring (2048)The URL for receiving an Instant Payment Notification about this payment.Note: This parameter has been made optional due to backward compatability. Read more about the use of it here ยป
Requiredmemostring (128)Description of items the customer is purchasing.
RequiredsenderEmailstring (128)Email address of the person sending money. This is the Payson account where the settled amount is transferred from.
RequiredsenderFirstNamestring (128)First name of the buyer as entered during checkout.
RequiredsenderLastNamestring (128)Last name of the buyer as entered during checkout.
OptionallocaleCodeLocaleCodeLocale of pages displayed by Payson during payment.
Default: SE
OptionalcurrencyCodeCurrencyCodeThe currency used for the payment.
Default: SEK
OptionalfundingList.fundingConstraint (0..N).constraintFundingConstraintSpecifies a list of allowed funding options for the payment.
If this field is omitted, the payment can be funded by any funding type that is supported for the merchant (excluding invoice).
OptionalfeesPayerFeesPayerThe payer of the Payson fees.
Default: PRIMARYRECEIVER
OptionalinvoiceFeedecimalAn invoice fee that will be added as an order item.

  • Must be in the range 0 to 40

Note: This amount should be included in amount specified for the primary receiver

Optionalcustomstring (256)A free-form field for your own use. This will be returned in requests to the PaymentDetails API endpoint.
OptionaltrackingIdstring (128)Your own tracking id. This will be returned in requests to the PaymentDetails API endpoint.
OptionalguaranteeOfferedGuaranteeOfferedWhether Payson Guarantee is offered or not.
Default: OPTIONAL
OptionalshowReceiptPageboolWhether to show the receipt page in Paysons checkout. Default: true

Receiver Details

The list of receivers. If you have more than one receiver you must specify exactly one as primary.

RequiredreceiverList.receiver (0..N).emailstring (128)Email address of the receiver.
RequiredreceiverList.receiver (0..N).amountdecimalThe amount (including VAT) to transfer to this recipient.Note: If you have more than one receiver, the primary receiver’s amount must still be the full amount of the payment.
OptionalreceiverList.receiver (0..N).primaryboolWhether this receiver is the primary receiver. This only applies if there is more than one receiver.

Order Item Details

Note: Order Items are required for Invoice, and optional for all other payments types.
For each orderItem, you must specify all or none of the parameters sku, quantity, unitPrice & taxPercentage.
RequiredorderItemList.orderItem (0..N).descriptionstring (128)Description of this item.
OptionalorderItemList.orderItem (0..N).skustring (128)SKU of this item.
OptionalorderItemList.orderItem (0..N).quantitydecimalQuantity of this item.
OptionalorderItemList.orderItem (0..N).unitPricedecimalThe unit price of this item not including VAT. Can also be a negative amount for a discount.
OptionalorderItemList.orderItem (0..N).taxPercentagedecimalTax percentage for this item.
Note: Must be a decimal value and not an actual percentage. E.g. for a 25% tax percentage use 0.25.

Pay Response Parameters

ParameterData typeDescription
responseEnvelope.ackAckCodeAcknowledge code indicating the overall success of the request.
responseEnvelope.timestampDateTimeTimestamp that identifies when the response was sent.
TOKENGuidA token by which you identify to Payson that you are processing this payment.