#Callum - webhooks
1 messages · Page 1 of 1 (latest)
👋 Thanks for reaching out
Do you mean how/can Stripe sends customers details(name, email, address...) to your wordpress API via webhooks ?
Yes I believe so
You can create a Webhook that listens to these events customer.created and customer.updated
https://stripe.com/docs/api/events/types#event_types-customer.created
https://stripe.com/docs/webhooks
does this webhook get data rather than stripe posting to our api?
Stripe uses webhooks to notify your application when an event happens in your account.
In your case once a customer is created in your Stripe Accout (via Dashbaord or APIs), Stripe notifies your Application via API with the created customer using webhooks
Just to be clear, stripe notifies my application via the stripe api or my api?
Does stripe send the name, email, address parameters via webhook / api?
I have created the webhook.php file in the wordpress theme file so the server receives the notification. But does not create a customer
How are you creating customers in your integration ?
our api receives the http json post request and submits a form entry in a wordpress plugin called gravity forms
one of our clients takes payment for membership services via stripe. they want to pass over their personal details over to our api to create a member in our gravity forms database.
id be happy to talk this over a call?
We don't do calls I'm afraid. Can you share with me the ID of a Payment Intent from your account?
pi_xxx
Trying to understand how you integrate with Stripe before advising which webhook events you need
You can't specify which fields are sent in a webhook, its just the fields/object that reflect the event you're receiving
so I can send over all fields to the target URL, but only have the API process the meta data that I need?
cus_MIrl8uGfsCEh4M
Yes, that's how it can work. You'd write the code/logic to process the fields you need from the webhook event
I have already set up the webhook end point to our api address. And created the webhook.php file in our wordpress theme folder. Is this correct? if so are there further steps?
Looks like you have a test webhook setup to receive customer.created events, yep
Correct
Looks like its working to me: https://dashboard.stripe.com/test/events/evt_1LaG2NJtaQtPYYK4fNQo9Or8
Sign in to the Stripe Dashboard to manage business payments and operations in your account. Manage payments and refunds, respond to disputes and more.
So I am receiving them, then how do I send the data over to my sites API?
That's logic that you'd write in your webhook.php file