latest stable versions: v150827 (changelog)

Old Forums (READ-ONLY): The community now lives at WP Sharks™. If you have an s2Member® Pro question, please use our new Support System.

Subscription with Paypal IPN w. Proxy

Home Forums Community Forum Subscription with Paypal IPN w. Proxy

This topic contains 9 replies, has 4 voices. Last updated by  Abbe 4 years, 2 months ago.

Topic Author Topic
Posted: Wednesday Oct 24th, 2012 at 4:54 pm #29588
Abbe
Username: raptor

Hi!

I am trying to send messages and create a new subscription through the ‘Paypal IPN w/ Proxy Key’. I am following the instructions as described in the dashboard but unfortunately when watching the log nothing seems to happen. I get the message:
‘Ignoring this IPN request. The `txn_type/status` does NOT require any action on the part of s2Member.’

What am I missing?

* I am posting my POST variables through the alternate IPN URL:
http://www.myweb.com/?s2member_paypal_notify=1&s2member_paypal_proxy=sms&s2member_paypal_proxy_verification=d877664e12218c1122334119612c9977

* The following POST variables are posted:
txn_type: subscr_signup
custom: http://www.myweb.com
first_name: Test
last_name: Testuser
item_number: 1
payer_email: test@testing.com
payer_id: 123456
mc_amount3: 29.95
period3: 30 D
recurring:

=The result I am getting when watching the logs is the following:

‘txn_type’ => ‘subscr_signup’,
‘custom’ => ‘www.myweb.com’,
‘first_name’ => ‘Test’,
‘last_name’ => ‘Testuser’,
‘item_number’ => ‘1’,
‘payer_email’ => ‘test@testing.com’,
‘payer_id’ => ‘123456’,
‘mc_amount3’ => ‘29.95’,
‘period3’ => ‘3 D’,
‘recurring’ => ”,
‘proxy_verified’ => ‘sms’,
‘s2member_log’ =>
array (
0 => ‘IPN received on: Wed Oct 24, 2012 8:42:39 pm UTC’,
1 => ‘s2Member POST vars verified with a Proxy Key’,
2 => ‘s2Member originating domain ( `$_SERVER[“HTTP_HOST”]` ) validated.’,
3 => ‘Ignoring this IPN request. The `txn_type/status` does NOT require any action on the part of s2Member.’,
),
‘subscr_gateway’ => ‘sms’,
‘s2member_paypal_proxy’ => ‘sms’,
‘s2member_paypal_proxy_verification’ => ‘d8fa2a4e12218c04d3205119612c7ff8’,
)

Regards

List Of Topic Replies

Viewing 9 replies - 1 through 9 (of 9 total)
Author Replies
Author Replies
Posted: Thursday Oct 25th, 2012 at 1:37 pm #29665
Raam Dev
Username: Raam
Staff Member

Hello,

Are you using an s2Member-generated PayPal button or Pro-Form? s2Member handles all of the IPN communication in the background automatically.

Posted: Thursday Oct 25th, 2012 at 2:15 pm #29675
Abbe
Username: raptor

Hi Raam!

I am using none of the ones you describe. I am using the ‘IPN w/ Proxy Key methodology’ as found under:

‘s2Member -> PayPal Options -> IPN Integration -> IPN w/ Proxy Key’

Posted: Friday Oct 26th, 2012 at 12:50 pm #29821
Abbe
Username: raptor

Any more input on this one?

Posted: Friday Oct 26th, 2012 at 12:55 pm #29824
Raam Dev
Username: Raam
Staff Member

Hi Abbe,

Ah, I see now. Thank you for clarifying that. I took a look at your logs and compared them to a live log on my personal site and from what I can tell you’re doing it right. I’m not too familiar with that specific feature, so I’m going to forward this to the lead developer (Jason) and see if he can offer any suggestions.

Thank you for your patience.

Posted: Friday Oct 26th, 2012 at 1:03 pm #29828
Staff Member

Thanks for the heads up on this thread.

Add one of the following variables please.

txn_id = A unique transaction ID.
or... subscr_id = A unique subscription ID (recommended in this case).

See also: http://www.s2member.com/paypal-ipn-pdt-vars

Posted: Friday Oct 26th, 2012 at 6:17 pm #29877
Abbe
Username: raptor

Works perfectly, with both txn_id or subscr_id. Can now create subscriptions. Thanks Jason! :)

A follow up question. I also after successfully created a subscription tried to to perform a ‘subscr_cancel’ on it but failed. I have tried with different variables and looked at paypals documentation but cannot get it right. What variable am I missing in this case?

‘txn_type’ => ‘subscr_cancel’,
‘custom’ => ‘www.myweb.com,
‘first_name’ => ‘Test’,
‘last_name’ => ‘Testuser’,
‘username’ => ‘TEST’,
‘payer_email’ => ‘test@testing.com’,
‘txn_id’ => ‘1702362107’,
‘parent_txn_id’ => ‘0702362108’,
‘proxy_verified’ => ‘sms’,
‘s2member_log’ =>
array (
0 => ‘IPN received on: Fri Oct 26, 2012 10:04:46 pm UTC’,
1 => ‘s2Member POST vars verified with a Proxy Key’,
2 => ‘s2Member originating domain ( `$_SERVER[“HTTP_HOST”]` ) validated.’,
3 => ‘Ignoring this IPN request. The `txn_type/status` does NOT require any action on the part of s2Member.’

Posted: Friday Nov 2nd, 2012 at 6:53 am #30421
Staff Member

Thanks for the follow-up.

In the case of subscr_cancel, s2Member needs the following:

txn_type=subscr_cancel
custom=www.example.com
item_number=1 (i.e. the original item_number)
item_name=[name of product goes here]
period1=0 D (see PayPal documentation, only applicable if there was a trial period)
This is the length of a possible initial/trial period. 0 Days in this example.
period3=1 M (see PayPal documentation, this MUST always be provided)
This is the periodicity of the regular recurring period. 1 time each Month in this example.
subscr_id=0702362108 (i.e. original subscr_id value)
payer_email=john@example.com

Posted: Friday Nov 2nd, 2012 at 7:31 am #30426
Posted: Saturday Nov 3rd, 2012 at 5:34 pm #30567
Abbe
Username: raptor

Thanks Jason I now got create, cancel and modify subscription to work . . . Perfect :)

But now I have stumbled on another challenge. This is creating a subscription for a user that already exists in my wordpress blog. It might be a user that had a previous subscription and then got demoted and now has the ‘subscriber’ role (Level #0 user).

When I create a new subscription with txn_type=’subscr_signup’, s2Member sends the user that paid a mail telling him that payment was successful and link so that he can register. This is good and works for new Yet unregistered users.

But if I have a user that already is registered in my wordpress blog with the subscriber (Level #0 user) role it doesn’t work. Sending a transaction with txn_type=’subscr_signup’ doesn’t recognise that the user already exists, and will still send an e-mail with link to register. Unfortunately, this time the user cannot register as the user already exists.

I therefore tried to create a subscription with txn_type=’subscr_payment’ instead. I still failed though. See log below.

So my questions are.
1: What is the strategy to create an subscription for an already existing user so that s2Member recognises him and automatically associates the transaction with him?

2: If txn_type=’subscr_payment’ is the right way, what important field have I missed to get s2Member to recognise that the transaction belongs to an existing user?

Please se log below:

array (
‘first_name’ => ‘Test’,
‘last_name’ => ‘Testuser’,
‘payer_email’ => ‘test@testing.com’,
‘item_number’ => ‘1’,
‘item_name’ => ‘s2Member Level 1’,
‘mc_currency’ => ‘USD’,
‘mc_amount3’ => ‘29.95’,
‘mc_fee’ => ‘0.34’,
‘mc_gross’ => ‘9.34’,
‘txn_type’ => ‘subscr_payment’,
‘subscr_id’ => ‘0702362132’,
‘period3’ => ‘1 D’,
‘recurring’ => ”,
‘custom’ => ‘www.myweb.com’,
‘proxy_verified’ => ‘sms’,
‘s2member_log’ =>
array (
0 => ‘IPN received on: Sat Nov 3, 2012 9:14:35 pm UTC’,
1 => ‘s2Member POST vars verified with a Proxy Key’,
2 => ‘s2Member originating domain ( `$_SERVER[“HTTP_HOST”]` ) validated.’,
3 => ‘Ignoring this IPN request. The `txn_type/status` does NOT require any action on the part of s2Member.’,
),
‘subscr_gateway’ => ‘sms’,
‘s2member_paypal_proxy’ => ‘sms’,
‘s2member_paypal_proxy_verification’ => ‘d8fa2a4e12218c04d3205119612c7ff8’,
)

Viewing 9 replies - 1 through 9 (of 9 total)

This topic is closed to new replies. Topics with no replies for 2 weeks are closed automatically.

Old Forums (READ-ONLY): The community now lives at WP Sharks™. If you have an s2Member® Pro question, please use our new Support System.

Contacting s2Member: Please use our Support Center for bug reports, pre-sale questions & technical assistance.