-
-
Save JarrydLong/b8f58fcf908ed33a81f36fecb4452663 to your computer and use it in GitHub Desktop.
Test a Stripe Webhook Event with WordPress and Paid Memberships Pro
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Test Stripe webhook events | |
Add to a custom plugin, then visit /?teststripe=1 | |
*/ | |
function init_test_stripe() { | |
if(!empty($_REQUEST['teststripe'])) { | |
$_REQUEST['event_id'] = 'evt_9ktqwT5xFlKNOp'; //EDIT THIS to be the ID of an actual recurring payment event in your account | |
require_once(PMPRO_DIR . "/services/stripe-webhook.php"); | |
exit; | |
} | |
} | |
add_action('init', 'init_test_stripe'); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment