将 CUSTOM 变量发送到 CreateRecurringPaymentsProfile
Send CUSTOM variable to CreateRecurringPaymentsProfile
我正在实施循环快速结账。创建配置文件的代码正在运行。我现在要做的是给它传递一个自定义值。
我们可以通过
和
使用以下名称
PAYMENTREQUEST_n_CUSTOM
我想为 CreateRecurringPaymentsProfile 做同样的事情,以便我可以在 IPN 中访问它。
CRPP 不像其他 API 请求那样包含自定义参数,但是,它包含 PROFILEREFERENCE 参数,该参数将被视为发票 ID。您在此处传递的任何值都将作为 rp_invoice_id.
在 IPN 中返回
所以您可以做的是在您的数据库中保存本地发票记录,其中包括您需要的任何相关数据,然后将该 ID 传递到您的 CRPP 请求的 profilereference 参数中。然后在您的 IPN 脚本中,您从 rp_invoice_id 中提取此值,然后使用该 ID 值从您的数据库中提取您需要的关于该发票的任何额外详细信息。
这是一个包含 rp_invoice_id.
的 IPN 示例
Array
(
[mc_gross] => 6.45
[period_type] => Regular
[outstanding_balance] => 0.00
[next_payment_date] => 02:00:00 Feb 12, 2015 PST
[protection_eligibility] => Eligible
[payment_cycle] => Monthly
[address_status] => confirmed
[tax] => 0.00
[payer_id] => Q33PGJHM6K38Q
[address_street] => 375 HWY 21 n
[payment_date] => 02:12:06 Jan 12, 2015 PST
[payment_status] => Completed
[product_name] => USBSwiper Monthly Subscription
[charset] => windows-1252
[rp_invoice_id] => 1935
[recurring_payment_id] => I-FWEAAAAXPVJ
[address_zip] => 72616
[first_name] => Tester
[mc_fee] => 0.44
[address_country_code] => US
[address_name] => KARShop
[notify_version] => 3.8
[amount_per_cycle] => 6.45
[payer_status] => verified
[currency_code] => USD
[business] => payments@domain.com
[address_country] => United States
[address_city] => Berryville
[verify_sign] => AtjWedapewmudDbf6C3S0..Z.7glAyXhJISOoiYcafN1Zb.VrOX7O8VH
[payer_email] => tester@gmail.com
[initial_payment_amount] => 0.00
[profile_status] => Active
[amount] => 6.45
[txn_id] => 5G2211475Y5810638
[payment_type] => instant
[payer_business_name] => Testers, LLC
[last_name] => Testerson
[address_state] => AR
[receiver_email] => payments@domain.com
[payment_fee] => 0.44
[receiver_id] => M5VRAQYEFCSK6
[txn_type] => recurring_payment
[mc_currency] => USD
[residence_country] => US
[transaction_subject] => USBSwiper Monthly Subscription
[payment_gross] => 6.45
[shipping] => 0.00
[product_type] => 1
[time_created] => 14:56:25 Apr 12, 2011 PDT
[ipn_track_id] => 9318cc3589f1b
)
我正在实施循环快速结账。创建配置文件的代码正在运行。我现在要做的是给它传递一个自定义值。
我们可以通过
和
使用以下名称
PAYMENTREQUEST_n_CUSTOM
我想为 CreateRecurringPaymentsProfile 做同样的事情,以便我可以在 IPN 中访问它。
CRPP 不像其他 API 请求那样包含自定义参数,但是,它包含 PROFILEREFERENCE 参数,该参数将被视为发票 ID。您在此处传递的任何值都将作为 rp_invoice_id.
在 IPN 中返回所以您可以做的是在您的数据库中保存本地发票记录,其中包括您需要的任何相关数据,然后将该 ID 传递到您的 CRPP 请求的 profilereference 参数中。然后在您的 IPN 脚本中,您从 rp_invoice_id 中提取此值,然后使用该 ID 值从您的数据库中提取您需要的关于该发票的任何额外详细信息。
这是一个包含 rp_invoice_id.
的 IPN 示例Array
(
[mc_gross] => 6.45
[period_type] => Regular
[outstanding_balance] => 0.00
[next_payment_date] => 02:00:00 Feb 12, 2015 PST
[protection_eligibility] => Eligible
[payment_cycle] => Monthly
[address_status] => confirmed
[tax] => 0.00
[payer_id] => Q33PGJHM6K38Q
[address_street] => 375 HWY 21 n
[payment_date] => 02:12:06 Jan 12, 2015 PST
[payment_status] => Completed
[product_name] => USBSwiper Monthly Subscription
[charset] => windows-1252
[rp_invoice_id] => 1935
[recurring_payment_id] => I-FWEAAAAXPVJ
[address_zip] => 72616
[first_name] => Tester
[mc_fee] => 0.44
[address_country_code] => US
[address_name] => KARShop
[notify_version] => 3.8
[amount_per_cycle] => 6.45
[payer_status] => verified
[currency_code] => USD
[business] => payments@domain.com
[address_country] => United States
[address_city] => Berryville
[verify_sign] => AtjWedapewmudDbf6C3S0..Z.7glAyXhJISOoiYcafN1Zb.VrOX7O8VH
[payer_email] => tester@gmail.com
[initial_payment_amount] => 0.00
[profile_status] => Active
[amount] => 6.45
[txn_id] => 5G2211475Y5810638
[payment_type] => instant
[payer_business_name] => Testers, LLC
[last_name] => Testerson
[address_state] => AR
[receiver_email] => payments@domain.com
[payment_fee] => 0.44
[receiver_id] => M5VRAQYEFCSK6
[txn_type] => recurring_payment
[mc_currency] => USD
[residence_country] => US
[transaction_subject] => USBSwiper Monthly Subscription
[payment_gross] => 6.45
[shipping] => 0.00
[product_type] => 1
[time_created] => 14:56:25 Apr 12, 2011 PDT
[ipn_track_id] => 9318cc3589f1b
)