Simple Order API Example: Create Session Using
Line Items with XML
Simple Order API
Example: Create Session Using
Line Items with XMLRequest with Optional Line Items
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748<="urn:schemas-cybersource-com:transaction-data-1.213"> <merchantID>test_merchant</merchantID> <merchantReferenceCode>refnum-1234</merchantReferenceCode> <billTo> <firstName>John</firstName> <lastName>Smith</lastName> <street1>Peachtree St</street1> <city>Atlanta</city> <state>GA</state> <postalCode>33019</postalCode> <country>US</country> <email>test@cybs.com</email> </billTo> <shipTo> <firstName>John</firstName> <lastName>Smith</lastName> <street1>Peachtree St</street1> <city>Atlanta</city> <state>GA</state> <postalCode>30319</postalCode> <country>US</country> </shipTo> <item id="0"> <unitPrice>1</unitPrice> <quantity>10</quantity> <productCode>4564</productCode> <productName>TV</productName> <productSKU>testI</productSKU> <totalAmount>10</totalAmount> </item> <item id="1"> <unitPrice>15</unitPrice> <quantity>1</quantity> <productCode>65432</productCode> <productName>TV</productName> <productSKU>testJ</productSKU> <totalAmount>15</totalAmount> </item> <purchaseTotals> <currency>USD</currency> </purchaseTotals> <apPaymentType>AFP</apPaymentType> <apSessionsService run="true"> <cancelURL>https://www.test.com</cancelURL> <successURL>https://www.test1.com</successURL> <paymentMethod_name>afp</paymentMethod_name> </apSessionsService> </>
Response with Optional Line Items
1234567891011121314151617181920<:c="urn:schemas-cybersource-com:transaction-data-1.213"> <merchantReferenceCode>refnum-1234</merchantReferenceCode> <requestID>6977376246486503703007</requestID> <decision>ACCEPT</decision> <reasonCode>100</reasonCode> <requestToken>AxjnrwSTej6MCHSsbsHfAAUZYiy6ladJo2qFOEnkFtpem2kDJxDNyGTSTL0YwW2Lkm9H0YEOlY3YO+AAES2i</requestToken> <purchaseTotals> <currency>USD</currency> </purchaseTotals> <apSessionsReply> <reasonCode>100</reasonCode> <responseCode>00001</responseCode> <merchantURL>https://portal.sandbox.afterpay.com/us/checkout/?token=002.kfl0qoc9q5tarv41p34s1dvbrk62iflv382j1sd0ot7o5s82</merchantURL> <processorToken>0d97aa1b-a9dd-4e9c-b60c-b1157470d034</processorToken> <amount>25.00</amount> <reconciliationID>XEKTVNIQZPSB</reconciliationID> <status>PENDING</status> <dateTime>2023-10-19T17:47:05Z</dateTime> </apSessionsReply> </>