Payment flow with Free orders
Last updated: 06-Oct-2020
Rate this article:
Overview
The FREE payment method is ideal for free orders, where you do not require any payment information from your customers.
Availability
Available for all 2Checkout accounts.
Requirements
Free orders are available only for catalog products. The final order price has to be 0. You can either use products with 0 prices, or add a promotion for 100% of the total order price. It's mandatory to set RecurringEnabled to 'False'.
Request example
The full JSON used to place an order with credit cards would look like:
{
"Language":"en",
"Country":"US",
"CustomerIP":"10.10.10.10",
"Source":"Website",
"ExternalCustomerReference":"externalCustomerId",
"Currency":"USD",
"MachineId":"123456789",
"Items":[
{
"Code":"FREE_PRODUCT_CODE",
"Quantity":1
}
],
"BillingDetails":{
"FirstName":"Customer First Name",
"LastName":"Customer Last Name",
"CountryCode":"US",
"State":"California",
"City":"San Francisco",
"Address1":"Example Street",
"Zip":"90210",
"Email":"example@email.com"
},
"PaymentDetails":{
"Type":"FREE",
"Currency":"USD",
"PaymentMethod":{
"RecurringEnabled":false
}
}
}
Integrate test cases
- Build a request in order to place a new order, with all the relevant information. Make sure that when the order is sent in the API the response contains an order object (order was placed successfully).
- If you have any additional webhook integrations, make sure that the webhooks are correctly configured and that the notifications are received and processed successfully.
Rate this article: