v1
latestOpenAPI 3.1.02026-07-241080412.6 KBCreate an order
To create an order, you use orders resource. Order resources are used to handle customers' payments of previously defined offers. Orders expire after 24 hours unless the payment is captured. Payment method is required in order entity for payment but can be added in update order.
You should add paymentOperation and subscriptionId parameters for recurring orders.
post/orders
Headers
Content-Typestring
X-Publisher-Tokenstring required
Request body
Response
200
Example response
{
"success": true,
"order": {
"id": 159026691,
"customerId": 771994569,
"customer": {
"locale": "en_US",
"email": "test@test.com"
},
"publisherId": 167631863,
"offerId": "S398236333_PL",
"offer": {
"title": "Title",
"price": 4.065,
"currency": "EUR"
},
"totalPrice": 9.3217,
"priceBreakdown": {
"offerPrice": 4.74,
"discountAmount": 0.95,
"discountedPrice": 3.79,
"taxValue": 0.87,
"paymentMethodFee": 4.6617
},
"taxRate": 0.23,
"currency": "USD",
"country": "PL",
"paymentMethodId": 399207736,
"expirationDate": 1574333220,
"billingAddress": {
"billingStreetName": "street",
"billingStreetNumber": "123",
"billingPostalCode": "62-025"
},
"couponId": 7,
"discount": {
"applied": true,
"type": "coupon",
"periods": 10
},
"requiredPaymentDetails": true
},
"message": "Order created successfully"
}