Table of Contents Previous Next Index

IPN and PDT Variables

IPN and PDT Variables
 
IPN and PDT variables are case-sensitive. All values are lowercase, except those for payment_status, which have an initial capital letter.
In addition, values posted by IPN are URL-encoded. For example, a colon in http:// is encoded as %3A in the IPN post: http%3A//
About These Tables of Variables
The tables in this appendix group IPN variables by different characteristics:
l
l
l
l
l
l
l
l
l
l
l
l
Transaction-Specific Variable Values
Unless otherwise indicated in the table column labeled Possible Values, the value of an IPN or PDT variable is always specific to the transaction whose information is being posted.
test_ipn Variable in Sandbox
In the Sandbox environment, IPN includes the additional variable test_ipn with a value of 1 (one). The purpose of test_ipn is to provide testing programs a means to differentiate between Sandbox IPN and live IPN.
IPN Variables in All Posts
IPN Version: notify_version
The value of the notify_version variable is the version number of Instant Payment Notification that makes the post.
Note:
The value notify_version is a means for PayPal to track versions of IPN. There is no need for your programs to store this value or query it.
Security Information: verify_sign
The value of verify_sign is an encrypted string used to validate the authenticity of the transaction.
Buyer Information
 
Possible Values
Char Length
address_
country
address_
country_
code
address_
status
address_
street
payer_
business_
name
payer_
status
residence_
country
Basic Information
 
Possible Values
Char Length
Email address or account ID of the payment recipient (that is, the merchant). Equivalent to the values of receiver_email (if payment is sent to primary account) and business set in the Website Payment HTML.
Item name as passed by you, the merchant. Or, if not passed by you, as entered by your customer. If this is a shopping cart transaction, PayPal will append the number of the item (e.g., item_name_1, item_name_2, and so forth).
Pass-through variable for you to track purchases. It will get passed back to you at the completion of the payment. If omitted, no variable will be passed back to you.
Quantity as entered by your customer or as passed by you, the merchant. If this is a shopping cart transaction, PayPal appends the number of the item (e.g. quantity1, quantity2).
Primary email address of the payment recipient (that is, the merchant). If the payment is sent to a non-primary email address on your PayPal account, the receiver_email is still your primary email.
Unique account ID of the payment recipient (i.e., the merchant). This is the same as the recipient's referral ID.
Advanced and Custom Information
 
Possible Values
Char Length
Custom value as passed by you, the merchant. These are pass-through variables that are never presented to your customer
Passthrough variable you can use to identify your Invoice Number for this purchase. If omitted, no variable is passed back.
option_
name_1
option_
name_2
option_
selection1
option_
selection2
Website Payments Standard, Website Payments Pro, and Refund Information
 
Possible Values
Char Length
Transaction-specific
Transaction-specific
Transaction-specific
Transaction-specific for multiple currencies
The amount is in the currency of mc_currency, where x is the shopping cart detail item number. The sum of mc_gross_x should total mc_gross.
mc_
handling_x
Transaction-specific for multiple currencies
The x is the shopping cart detail item number. The handling_cart cart-wide Website Payments variable is also included in the mc_handling variable; for this reason, the sum of mc_handling_x might not be equal to mc_handling
mc_
shipping_x
Transaction-specific for multiple currencies
This is the combined total of shipping and shipping2 Website Payments Standard variables, where x is the shopping cart detail item number. The shippingx variable is only shown when the merchant applies a shipping amount for a specific item. Because profile shipping might apply, the sum of shippingx might not be equal to shipping.
option_
name1
PayPal appends the number of the item where x represents the number of the shopping cart detail item (e.g., option_name1, option_name2).
option_
name2
PayPal appends the number of the item where x represents the number of the shopping cart detail item (e.g., option_name2, option_name2).
option_
selection1_x
PayPal appends the number of the item (e.g., option_selection1, option_selection2), where x represents the number of the shopping cart detail item.
option_
selection2_x
PayPal appends the number of the item where x represents the number of the shopping cart detail item (e.g., option_selection1, option_selection2).
In the case of a refund, reversal, or canceled reversal, this variable contains the txn_id of the original transaction, while txn_id contains a new ID for the new transaction.
payment_
status
Canceled_
Reversal
Canceled_Reversal: A reversal has been canceled. For example, you won a dispute with the customer, and the funds for the transaction that was reversed have been returned to you.
Completed: The payment has been completed, and the funds have been added successfully to your account balance.
Denied: You denied the payment. This happens only if the payment was previously pending because of possible reasons described for the PendingReason element.
Expired: This authorization has expired and cannot be captured.
Failed: The payment has failed. This happens only if the payment was made from your customer’s bank account.
Pending: The payment is pending. See pending_reason for more information.
Refunded: You refunded the payment.
Reversed: A payment was reversed due to a chargeback or other type of reversal. The funds have been removed from your account balance and returned to the buyer. The reason for the reversal is specified in the ReasonCode element.
Processed: A payment has been accepted.
Voided: This authorization has been voided.
echeck: This payment was funded with an eCheck.
instant: This payment was funded with PayPal balance, credit card, or Instant Transfer.
pending_
reason
multi-currency
This variable is set only if payment_status = Pending.
address: The payment is pending because your customer did not include a confirmed shipping address and your Payment Receiving Preferences is set yo allow you to manually accept or deny each of these payments. To change your preference, go to the Preferences section of your Profile.
authorization: You set <PaymentAction> Authorization</PaymentAction> on SetExpressCheckoutRequest and have not yet captured funds.
echeck: The payment is pending because it was made by an eCheck that has not yet cleared.
intl: The payment is pending because you hold a non-U.S. account and do not have a withdrawal mechanism. You must manually accept or deny this payment from your Account Overview.
multi-currency: You do not have a balance in the currency sent, and you do not have your Payment Receiving Preferences set to automatically convert and accept this payment. You must manually accept or deny this payment.
unilateral: The payment is pending because it was made to an email address that is not yet registered or confirmed.
upgrade: The payment is pending because it was made via credit card and you must upgrade your account to Business or Premier status in order to receive the funds. upgrade can also mean that you have reached the monthly limit for transactions on your account.
verify: The payment is pending because you are not yet verified. You must verify your account before you can accept this payment.
other: The payment is pending for a reason other than those listed above. For more information, contact PayPal Customer Service.
buyer_
complaint
This variable is set if payment_status =Reversed, Refunded, or Cancelled_Reversal
chargeback: A reversal has occurred on this transaction due to a chargeback by your customer.
guarantee: A reversal has occurred on this transaction due to your customer triggering a money-back guarantee.
buyer-complaint: A reversal has occurred on this transaction due to a complaint about the transaction from your customer.
refund: A reversal has occurred on this transaction because you have given the customer a refund.
other: A reversal has occurred on this transaction due to a reason not listed above.
Transaction-specific
shipping_
method
Merchant-specific
The name of a shipping method from the Shipping Calculations section of the merchant's account profile. The buyer selected the named shipping method for this transaction.
Transaction-specific
PayPal appends the number of the item (e.g., item_name1, item_name2). The tax_x variable is included only if there was a specific tax amount applied to a particular shopping cart item. Because profile tax may apply to other items in the cart, the sum of tax_x might not total to tax.
express_
checkout
virtual_
terminal
cart: Transaction created by a customer:
express_checkout: Transaction created by Express Checkout when the customer’s cart contains a single item.
send-money: Transaction created by customer from the Send Money tab on the PayPal website.
virtual_terminal: Transaction created with Virtual Terminal.
web-accept: Transaction created by customer via Buy Now, Donation, or Auction Smart Logos.
Note:
In some cases, txn_type is blank when the variable reason_code is chargeback.
Currency and Currency Exchange
 
Possible Values
Char Length
Three-character currency code. See table of supported currencies.
For payment IPN notifications, this is the currency of the payment. For non-payment subscription IPN notifications, this is the currency of the subscription.
Transaction fee associated with the payment. mc_gross minus mc_fee equals the amount deposited into the receiver_email account. Equivalent to payment_fee for USD payments. If this amount is negative, it signifies a refund or reversal, and either of those payment statuses can be for the full or partial amount of the original transaction fee.
Full amount of the customer's payment, before transaction fee is subtracted. Equivalent to payment_gross for USD payments. If this amount is negative, it signifies a refund or reversal, and either of those payment statuses can be for the full or partial amount of the original transaction.
Transaction-specific for USD payments only
USD transaction fee associated with the payment. payment_gross minus payment_fee equals the amount deposited into the receiver email account. Is empty for non-USD payments. If this amount is negative, it signifies a refund or reversal, and either of those payment statuses can be for the full or partial amount of the original transaction fee.
Note:
Transaction-specific for USD payments only
Full USD amount of the customer’s payment, before transaction fee is subtracted. Will be empty for non-USD payments. This is a legacy field replaced by mc_gross. If this amount is negative, it signifies a refund or reversal, and either of those payment statuses can be for the full or partial amount of the original transaction.
settle_
amount
Amount that is deposited into the account’s primary balance after a currency conversion from automatic conversion (through your Payment Receiving Preferences) or manual conversion (through manually accepting a payment).
settle_
currency
Three-character currency code. See table of supported currencies.
Currency of settle_amount.
Auctions
 
Possible Values
Char Length
auction_
buyer_id
auction_
closing_
date
auction_
multi_item
The number of items purchased in multi-item auction payments. It allows you to count the mc_gross or payment_gross for the first IPN you receive from a multi-item auction (auction_multi_item), since each item from the auction will generate an Instant Payment Notification showing the amount for the entire auction.
This is an auction payment—payments made using Pay for eBay Items or Smart Logos—as well as Send Money/Money Request payments with the type eBay items or Auction Goods (non-eBay).
Mass Payment
 
Possible Values
Char Length
masspay_
txn_id_x
For Mass Payments, a unique transaction ID generated by the PayPal system, where x is the record number of the mass pay item
Transaction-specific for multiple currencies
Transaction-specific for multiple Currencies
For Mass Payments, the transaction fee associated with the payment, where x is the record number the mass pay item
Transaction-specific for Multiple Currencies
For Mass Payments, the first IPN is the date/time when the record set is processed and the second IPN is the date/time when all payments are completed/returned. Format: HH:MM:SS DD Mmm YY, YYYY PST
Transaction-specific for USD payments only
If the payment is USD, then the value is the same as that for mc_fee_x, where x is the record number; if the currency is not USD, then this is an empty string.
Note:
payment_
gross_x
Transaction-specific for USD payments only
If the payment is USD, then the value for this is the same as that for the mc_gross_x, where x is the record number the mass pay item. If the currency is not USD, this is an empty string.
Note:
payment_
status
Completed: For Mass Payments, this means that all of your payments have been claimed, or after a period of 30 days, unclaimed payments have been returned to you.
Denied: For Mass Payments, this means that your funds were not sent and the Mass Payment was not initiated. This may have been caused by lack of funds.
Processed: Your Mass Payment has been processed and all payments have been sent.
1001: Invalid UserID.
1003: Country of Residence check failure
1004: Country of Funding Source check failure
receiver_
email_x
For Mass Payments, the primary email address of the payment recipient, where x is the record number of the mass pay item
Completed: The payment has been processed, regardless of whether this was originally a unilateral payment
Failed: The payment failed because of insufficient PayPal balance.
Reversed: This is for unilateral payments that were not claimed after 30 days and have been returned to the sender. Or the funds have been returned because the Receiver’s account was locked.
Unclaimed: This is for unilateral payments that are unclaimed.
For Mass Payments, the unique ID from input, where x is the record number. This allows the merchant to cross-reference the payment
Subscriptions
Subscriptions Variables
Along with other IPN variables, the following variables are included in Subscriptions IPNs.
subscr-failed
subscr-
cancel
subscr-
payment
subscr-signup
subscr-
modify
subscr_signup: subscription sign-up.
subscr_cancel: subscription cancellation.
subscr_failed: subscription payment failure.
subscr_payment: subscription payment.
subscr_eot: subscription’s end-of-term.
subscr_modify: subscription modification.
Start date or cancellation date depending on whether transaction is subscr_signupor subscr_cancel.
Time/Date stamp generated by PayPal , in the following format: HH:MM:SS DD Mmm YY, YYYY PST
subscr_
effective
Date when the subscription modification will be effective (only for txn_type = subscr_modify).
Time/Date stamp generated by PayPal , in the following format: HH:MM:SS DD Mmm YY, YYYY PST
(optional) Trial subscription interval in days, weeks, months, years (example: a 4 day interval is “period1: 4 D”).
Amount of payment for trial period 1 for USD payments; otherwise blank (optional).
Amount of payment for trial period 2 for USD payments; otherwise blank (optional).
Amount of payment for regular subscription period for USD payments; otherwise blank.
See table of supported currencies.
For non-payment subscriptions IPNs (i.e., txn_type= signup, cancel, failed, eot, or modify), this is the currency of the subscription. For payment IPNs, it is the currency of the payment (i.e., txn_type = subscr_payment)
Indicates whether reattempts should occur upon payment failures (1 is yes, blank is no).
(optional) Username generated by PayPal and given to subscriber to access the subscription.
(optional) Password generated by PayPal and given to subscriber to access the subscription (password will be encrypted).
Variables for Each Subscription Event
The following table shows which variables are associated and can be included in IPN posts with each subscription event type.
About payment_status and txn_type with Subscription IPN
In IPN messages posted by Subscription events, the payment_status variable is sent when a payment or refund occurs. For all other events, the pertinent variable is txn_type.
Payment
(USD)
Payment
(Multi-Currency)
subscr_
signup
subscr_
cancel
subscr_
modify
subscr_
failed
subscr_
eot
address_
country
subscr_
effective
Dispute Notification Variables
 
Possible Values
new_case: A new case has been registered.
adjustment: A case has been resolved and closed.
The merchant’s original transaction identification number for the payment from the buyer, against which the case was registered.
Format: PP-nnn-nnn-nnn where n is any numeric character.
l
chargeback: A buyer has filed a chargeback with his credit card company, which has notified PayPal of the reason for the chargeback.
case_
creation_
date
Transaction-specific
Depends on value of case_type
Values for case_type set to complaint:
l
non_receipt: Buyer claims that he did not receive goods or service.
l
not_as_described: Buyer claims that the goods or service received differ from merchant’s description of the goods or service.
Values for case_type set to chargeback:
l
adjustment_reimburse: A case that has been resolved and close requires a reimbursement.
l
non_receipt: Buyer claims that he did not receive goods or service.
l
duplicate: Buyer claims that a possible duplicate payment was made to the merchant.
l
merchandise: Buyer claims that the received merchandise is unsatisfactory, defective, or damaged.
l
special: Some other reason. Usually, special indicates a credit card processing error for which the merchant is not responsible and for which no debit to the merchant will result. PayPal must review the documentation from the credit card company to determine the nature of the dispute and possibly contact the merchant to resolve it.
Miscellaneous and Fee-Related IPN Variables
 
Possible Values
Char Length
PDT-Specific Variables
The following variables apply only to PDT.
Table A.10