Processing response data - immediate payment with PayPal

Here is an example of analysis to guide you through processing the response data.

  1. Identify the payment result by testing the value of the vads_trans_status field
    Table 1. Values associated with the vads_trans_status field
    Field name Description Value
    vads_trans_status

    Status of the payment

    Possible values:
    • CAPTURED
      Captured

      The transaction has been captured by the bank.

    • CANCELLED
      Canceled
      Cancellation by the buyer, the acquirer or the payment gateway.
    • REFUSED
      Declined
    • EXPIRED
      Expired

      The expiry date of the authorization request has passed and the merchant has not validated the transaction. The account of the cardholder will, therefore, not be debited.

    • UNDER_VERIFICATION
      Control in progress

      For PayPal transactions, this value means that PayPal withholds the transaction for suspected fraud.

      The payment will remain in the Transactions in progress tab until the verification process has been completed. The transaction will then take one of the following statuses: AUTHORISED or CANCELED.

      A notification will be sent to the merchant to warn them about the status change (Instant Payment Notification on batch change).

  2. Record the order while identifying the value of the vads_order_id field if you have transmitted it to the payment gateway.
  3. Record the payment reference while identifying the value of the vads_trans_id field.
  4. Analyze the vads_payment_config field to make sure that it is an immediate payment (single payment).
  5. Store the value of the vads_trans_date field to identify the payment date.
  6. Save the amount and the used currency. To do this, retrieve the values of the following fields:
    Table 2. Fields for analyzing the payment amount and currency
    Field name Description
    vads_amount Payment amount in the smallest currency unit.
    vads_currency Code of the currency used for the payment.
    vads_change_rate Used exchange rate.
    vads_effective_amount Payment amount in the currency used for the capture by the bank.
  7. Record the mode and the result of the authorization. To do this:
    1. Store the value of the vads_auth_mode field to identify the mode of the authorization request.
      Table 3. Values of the vads_auth_mode field
      Value Description
      FULL An authorization request has been made for the full amount.
      MARK A pre-authorization request for 1 EUR (or information request about the CB network if the acquirer supports it) has been made to verify the validity of the card.
    2. Note the value of the vads_auth_result field to identify the result of the authorization request.

    For an accepted authorization, the vads_auth_result field is set to 00.

    All other results indicate that the authorization has been rejected.

    Here is a list of frequently returned codes to help you understand the reason of the rejection:

    Table 4. Values of the vads_auth_result field
    Value Description
    0 Transaction accepted
    10001 Internal error
    10009 Transaction refused for one of the following reasons:
    • The partial refund amount must be less than or equal to the original transaction amount.
    • The partial refund must be the same currency as the original transaction.
    • This transaction has already been fully refunded.
    • You are over the time limit to perform a refund on this transaction (60 days).
    10422 Customer must choose new funding sources. The customer must return to PayPal to select new funding sources.
    10486 This transaction couldn't be completed. Please redirect your customer to PayPal.
    13113 The Buyer cannot pay with PayPal for this transaction. Inform the buyer that PayPal declined the transaction and to contact PayPal Customer Service.
  8. Record the used payment method by retrieving the value of the vads_payment_card field.
  9. Save all the details of the order, buyer and shipping.
    These details will be provided in the response only of they have been transmitted in the payment form.
    Their values is identical to the values submitted in the form.
  10. Save the value of the vads_authent_paypal_protection_eligibility field to identify the type of protection used for the transaction.
    Three values are possible:
    • ELIGIBLE
      Merchant is protected by PayPal's Seller Protection Policy for unauthorized payments and Item Not Received.
    • PARTIALLY_ELIGIBLE
      Merchant is protected by PayPal's Seller Protection Policy for Item Not Received.
    • INELIGIBLE
      Merchant is not protected by PayPal's Seller Protection Policy for Item Not Received.
Example of a form:
vads_capture_delay = 0  
vads_ctx_mode = TEST
vads_contract_used = merch_1284129052_biz@my-company.com  
vads_auth_result = 00  
vads_threeds_cavv =  
vads_cust_country = FR
vads_operation_type = DEBIT  
vads_threeds_cavvAlgorithm =
vads_threeds_exit_status =
vads_cust_name = My-company
vads_threeds_enrolled =  
vads_currency = 978   
vads_language = en  
vads_sequence_number = 1
vads_trans_id = 502840  
vads_pays_ip = FR
vads_payment_src = EC  
vads_trans_date = 20170217100817  
vads_amount = 4000  
vads_auth_number:
vads_auth_mode = FULL
vads_version = V2  
vads_payment_certificate = 4e3b2536e2aea84fa6cbbdc7694095d823910a48
signature = 1d03e967c14abb853c1ae2ba98495c2cc40628ca  
vads_threeds_eci =    
vads_card_country = 
vads_ship_to_street_number = street number in the shipping address
vads_cust_address_number = street number
vads_ship_to_name = name in the shipping address
vads_cust_address = street name
vads_effective_amount = 4000  
vads_ext_trans_id = 3GE25312T3314040N  
vads_validation_mode = 0  
vads_site_id = 91335531
vads_card_brand = PAYPAL_SB  
vads_threeds_sign_valid =
vads_threeds_status =  
vads_ship_to_zip = 31670 
vads_cust_city = city name
vads_ship_to_street2 = street in the shipping address
vads_ship_to_country = FR
vads_page_action = PAYMENT  
vads_ship_to_city = city in the shipping address
vads_cust_zip = 31670
vads_card_number = cust2_1282667599_per@my-email.com  
vads_payment_config = SINGLE  
vads_authent_paypal_protection_eligibility = ELIGIBLE
vads_trans_status = CAPTURED  
vads_order_id = nkj-055
vads_effective_creation_date = 20170217100817
vads_presentation_date = 20170217100817
vads_warranty_result = NO  
vads_cust_email = trash@my-email.com  
vads_result = 00 
vads_ship_to_status = PRIVATE 
vads_ship_to_street = street in the shipping address
vads_risk_control = CARD_FRAUD=OK;COMMERCIAL_CARD=OK  
vads_action_mode = INTERACTIVE  
vads_extra_result = 00
vads_threeds_xid =   
vads_threeds_error_code =