Radial Integration | 2016
The Payments element in OrderCreateRequest can contain different element
types depending on the payment methods. Each of these types have different
information that is expected. This page will cover some examples of the
different payment types. 
The How to Build an Order Create API Request page uses a visa credit card in its example.
An American Express credit card requires some extra data that other credit
cards do not require. A PhoneResponseCode, NameResponseCode, and EmailResponseCode
come back from CreditCardAuthReply; these elements must be copied as-is to the
OrderCreateRequest for fraud processing. See
mapping.
<OrderCreateRequest xmlns="http://api.gsicommerce.com/schema/checkout/1.0"
        requestId="123456789">
    <Order customerOrderId="12345">
        ...
        <Payment>
            ...
            <Payments>
                <CreditCard>
                    <PaymentContext>
                        <PaymentSessionId>12345</PaymentSessionId>                        <TenderType>AM</TenderType>                        <PaymentAccountUniqueId isToken="true">123abc</PaymentAccountUniqueId>                    </PaymentContext>                    <PaymentRequestId>456xyz</PaymentRequestId>                    <CreateTimeStamp>2016-02-12T23:08:20+00:00</CreateTimeStamp>                    <Amount>12.34</Amount>                    <Authorization>                        <ResponseCode>APPROVED</ResponseCode>                        <BankAuthorizationCode>123456</BankAuthorizationCode>                        <CVV2ResponseCode>M</CVV2ResponseCode>                        <AVSResponseCode>AM</AVSResponseCode>                        <PhoneResponseCode>U</PhoneResponseCode> (1)
                        <NameResponseCode>Y</NameResponseCode> (2)
                        <EmailResponseCode>N</EmailResponseCode> (3)
                        <AmountAuthorized>12.34</AmountAuthorized>
                    </Authorization>
                    <ExpirationDate>2020-01</ExpirationDate>
                </CreditCard>
            </Payments>
        </Payment>
        ...
    </Order>
    ...
</OrderCreateRequest>| 1 | The extra required PhoneResponseCodefor Amex cards. | 
| 2 | The extra required NameResponseCodefor Amex cards. | 
| 3 | The extra required EmailResponseCodefor Amex cards. | 
PayPal can be a payment method and shares some information from
PayPalDoAuthorizationReply. See
mapping.
<OrderCreateRequest xmlns="http://api.gsicommerce.com/schema/checkout/1.0"
        requestId="123456789">
    <Order customerOrderId="12345">
        ...
        <Payment>
            ...
            <Payments>
                <PayPal>
                    <Amount>12.34</Amount> (1)
                    <AmountAuthorized>12.34</AmountAuthorized> (2)
                    <PaymentContext>
                        <PaymentSessionId>123456</PaymentSessionId> (3)
                        <TenderType>PY</TenderType> (4)
                        <PaymentAccountUniqueId isToken="true">PAYPAL</PaymentAccountUniqueId> (5)
                    </PaymentContext>
                    <CreateTimeStamp>2016-02-01T04:58:34</CreateTimeStamp> (6)
                    <PaymentRequestId>123456abcdef</PaymentRequestId> (7)
                    <Authorization>
                        <ResponseCode>APPROVED</ResponseCode> (8)
                    </Authorization>
                </PayPal>
            </Payments>
        </Payment>
        ...
    </Order>
    ...
</OrderCreateRequest>| 1 | The amount this payment method is for (should match with AmountAuthorized)
(required). | 
| 2 | The amount authorized to use this payment method for (should match with Amount) (required). | 
| 3 | The PaymentSessionIdshould always be the orderId (required). | 
| 4 | The TenderTypeshould bePY, for PayPal (required). | 
| 5 | The PaymentAccountUniqueIdshould haveisTokenset to true and the valuePAYPAL(required). | 
| 6 | The time this payment was authorized (required). | 
| 7 | The PaymentRequestIdis the same as you sent in thePayPalDoAuthorizationRequest(required). | 
| 8 | The ResponseCodeshould beAPPROVEDif the response code fromPayPalDoAuthorizationReplywas Success, otherwise the payment method shouldn’t
be used (required). | 
Stored value cards like physical gift cards or online gift cards can be used as
payment methods. A stored value card should only be used if a
StoredValueRedeemReply returned a Success response code. See
mapping.
<OrderCreateRequest xmlns="http://api.gsicommerce.com/schema/checkout/1.0"
        requestId="123456789">
    <Order customerOrderId="12345">
        ...
        <Payment>
            ...
            <Payments>
                <StoredValueCard>
                    <PaymentContext>
                        <PaymentSessionId>123456</PaymentSessionId> (1)
                        <TenderType>SP</TenderType> (2)
                        <PaymentAccountUniqueId isToken="true">123abc</PaymentAccountUniqueId>  (3)
                    </PaymentContext>
                    <PaymentRequestId>456xyz</PaymentRequestId>  (3)
                    <CreateTimeStamp>2016-02-17T18:02:28+00:00</CreateTimeStamp>  (4)
                    <Pin>1234</Pin>  (5)
                    <Amount>12.34</Amount>  (6)
                </StoredValueCard>
            </Payments>
        </Payment>
        ...
    </Order>
    ...
</OrderCreateRequest>| 1 | The PaymentSessionIdshould always be the orderId (required). | 
| 2 | The tender type for a gift card is provider specific (required). | 
| 3 | The PaymentAccountUniqueIdcomes from theStoredValueRedeemReply(required). See
mapping. | 
| 4 | The time this payment was authorized (required). | 
| 5 | The code associated with the gift card or gift certificate. | 
| 6 | The amount being redeemed on the stored value card (required). | 
Copyright © 2017 Radial. All rights reserved.