Send WordPress User Meta To Zapier
In this example, you will learn how to send user meta to Zapier (WP Zapier v1.3+) whenever a user’s profile gets updated inside WordPress.
Sending user meta from WordPress to Zapier with WP Zapier requires a code snippet and a bit of PHP knowledge. This is done for safety reasons as we did not want to send unwanted sensitive data. We do plan to try and improve on this and make things even easier to send additional data in a future release.
Let’s have a look at the code:
In the code above, we’re using the default
get_user_meta() WordPress function. You can almost insert any code and add it to the
$array value to send data to Zapier. This could include custom data from tables, static data or removing data that’s not needed at all.
The example gets user meta that has a meta key of “spouse” and a value of “Cherie”.
Once this code has been added to your custom plugin / child theme’s functions.php this is what you would see when setting up your Zap in Zapier: