- Incoming WebHooks - https://www.screencast.com/t/dIEjHL5kjhW
- Outgoing WebHooks - https://www.screencast.com/t/xV9csVvbdQsJ
Last active
April 20, 2020 17:21
-
-
Save easterncoder/fde3636211e81bf5837ff8da38d4a6ef to your computer and use it in GitHub Desktop.
WishList Member WebHooks Integration Technical Demo
This file contains hidden or 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
<?php | |
file_put_contents( __DIR__ . '/receive.log', print_r( $_POST, true ), FILE_APPEND ); |
This file contains hidden or 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
#!/bin/sh | |
curl \ | |
-H 'Content-type: application/json' \ | |
-d '{"email":"[email protected]"}' \ | |
'YOUR-WEBHOOK-URL' |
This file contains hidden or 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
<?php | |
$post_data = array( | |
'email' => '[email protected]', | |
'username' => '', | |
'password' => '', | |
'firstname' => '', | |
'lastname' => '', | |
); | |
$post_data = http_build_query($post_data); | |
$ch = curl_init( 'YOUR-WEBHOOK-URL' ); | |
curl_setopt( $ch, CURLOPT_POST, 1 ); | |
curl_setopt( $ch, CURLOPT_POSTFIELDS, $post_data ); | |
curl_exec( $ch ); |
This file contains hidden or 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
#!/bin/sh | |
curl \ | |
-d '[email protected]' \ | |
'YOUR-WEBHOOK-URL' |
This file contains hidden or 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
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>Webhooks Test</title> | |
<style type="text/css"> | |
input,h1 { | |
display: block; | |
width: 50%; | |
margin: 5px auto; | |
font-size: 20px; | |
padding: 10px; | |
} | |
</style> | |
</head> | |
<body> | |
<h1>Webhooks Test Form</h1> | |
<form method="post" action="YOUR-WEBHOOK-URL"> | |
<input type="text" name="email" placeholder="Email Address"> | |
<input type="text" name="username" placeholder="Username (Email will be used if empty)"> | |
<input type="text" name="password" placeholder="Password (Auto-generated if empty)"> | |
<input type="text" name="firstname" placeholder="First Name"> | |
<input type="text" name="lastname" placeholder="Last Name"> | |
<input type="text" name="redirect" placeholder="Redirect URL"> | |
<input type="submit" value="Submit"> | |
</form> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment