#rnash-connect-webhooks
1 messages · Page 1 of 1 (latest)
as far as i know, it's a different webhook style
you can click the checkbox when you make the webhook
what about when using the cli for testing locally?
I started the listener like so: stripe listen --forward-connect-to https://localhost:{PORT}/webhook
and when I do that, my endpoint doesn't get hit at all
Do you have an example event that you're expecting to be sent to your connect endpoint that isn't working?
Sorry let me clarify - do you have an event ID? Something like evt_xxx?
Can you try this out (not the added --live at the end)
stripe listen --forward-connect-to https://localhost/%7BPORT%7D/webhook --live
this: "stripe listen --forward-connect-to https://localhost/{PORT}/webhook" is what I am using currently
Yes, but try adding --live to the end and then triggering a new test webhook event on the connect account
ah
unfortunately that didn't seem to change anything
in regards to the endpoint getting hit
That's strange - what's the most recent event you tried to listen for?
stripe trigger --stripe-account acct_XXXXXXXXXX charge.succeeded
I'm using ACH on the connect account side for charges
because that has a ~5 day pending period, I need to know when it's succeeded
Can you do me a favor and re-run the stripe listen command with the --live flag, and try the trigger commands again?
I've done that
stripe listen --forward-connect-to https://localhost:XXXX/webhook --live
That's so strange - from what I see on my end this should be working. What version of the CLI are you using?
homebrew on macOS
What do you see when you run stripe -v
stripe version 1.7.6
Can you add --log-level debug to your listen command? That should give us some more clues about what specifically is failling
ok
on it
[Mon, 08 Nov 2021 14:18:15 CST] DEBUG proxy.Proxy.processWebhookEvent: Processing webhook event webhook_converesation_id=1636402695-wc_uagK2iegsIcKex webhook_id=1636402695-wh_ImyqEaDQayTCOA
[Mon, 08 Nov 2021 14:18:15 CST] DEBUG proxy.Proxy.filterWebhookEvent: Received event with non-default API version, ignoring api_version=2020-08-27
there's some more stuff there
not sure what all you would like to see
looks like the webhook attempt isnt being fired
evt_1JteOvL8ajwDdEQrUK4MLv5Z
^that event is actually from my project code
and doesn't seem to have fired off any webhook events
Thanks, that is helpful
any idea what I'm missing?
.net
What version of that library?
39.73.0
Can you share more of the output from the stripe listen command with us? Also, just to eliminate some possibilities, do you see it come through successfully when you don't forward it (removing forward-connect-to)?
Interesting - so it's the --forward-connect-to that's the problem. Is what you sent over the output when it's not working, or when it is working?
when it's not working
i did push my code up to my test environment and try registering an endpoint that way
and using the test button in the dashboard seems to work, but as soon as I send off a test charge, i get nothing
When you registered your endpoint did you do so in live mode or test mode? You should be registering a live webhook endopint, since the connected account in question is only connected to the platform in live mode and will only send it's webhook events to a livemode connect endpoint
If you want to be able to use a testmode connect webhook endpoint for this connect account you also need to connect it to your platform in test mode then.
hmm.. I'm not sure I understand
how am I able to create users and charges through the connect account in test if it's not already connected in test
?
I know it's all a bit confusing - I need to leave so @gilded flower is going to take over, but let me leave some detail that will hopefully clear this up:
- Accounts can be connected to a platform in Live and/or Test mode
- When an Account is connected in Test mode, you can only make test requests on it's behalf and the events that occur on that account are only sent to your testmode connect webhooks
- When an Account is connected in Live mode, you can make both test and live mode requests for it. These events will by sent to your livemode connect webhooks (which will receive both live and test mode connect events since you can do bothen when connected in live mode)
@prisma garnet
but as soon as I send off a test charge, i get nothing
what happens? an API request is made? your code runs? there's an error?
my code runs, the charge is created on the connect account side and the application fee shows up on the platform account side
however no webhook fires
send me an Event ID that you see in your Dashboard but never got your webhook handler triggered for it?
sure
evt_1Jtf8PL8ajwDdEQret0XR1kY
evt_1Jtf8JL8ajwDdEQrzFo4JuAV
probably should have reversed that order
thanks looking
ok so taking evt_1Jtf8PL8ajwDdEQret0XR1kY for example
from what I can see from my end is that it was sent to your Stripe CLI listener
looking at something else
hmm I'm wondering if you've instantiated Stripe CLI as the Connect account and not as the Platform account (referring to the stripe login part)
for those two events, I was not using the CLI
those are from my test server
so not local
so I fired off a test charge via the Stripe .Net library in my code (pointing to test via the keys)
after having registered the endpoint via the webhook dashboard
for those two events, I was not using the CLI
sure it doesn't matter if the event was created from Stripe CLI or not, if you havestripe listengoing on on a machine, it will trigger even if the event results from an API request
after having registered the endpoint via the webhook dashboard
ok great, can you send me the WebhookEndpoint ID for that? it would be in the detail page of that webhook endpoint
in the Dashboard
I did not have stripe listen running
fair, so if you can get me the Webhook Endpoint ID (it would be something like we_123) and I can look
we_1JteeMLXrJfhQyEps6fbfmM5
thanks, checking
Hello! I'm taking over for @gilded flower, let me get caught up...
ok thanks
Okay, so you expected evt_1Jtf8PL8ajwDdEQret0XR1kY which is a charge.succeeded to be sent to webhook endpoint we_1JteeMLXrJfhQyEps6fbfmM5 but it wasn't, right?
yes
That webhook endpoint is a test mode Connect webhook endpoint, meaning it will only get test mode events from accounts connected to your platform in test mode. The account where the charge.succeeded event came from is connected to your platform in live mode only, not test mode, which is why it wasn't delivered.
Connect webhook event delivery can be tricky. This might help:
The scenario here is in the bottom left corner.
so in order to connect the account in test mode, I just need to setup the account the same way as I did for live, but while that test switch is flipped?
wait
nevermind
is there a trick to setting up the connect account in test or can I do that like I describe above?
I don't think there's any particular trick to it. Are you running into an issue?
Another question: You should be getting both test and live events sent to your Connect webhook endpoint in live mode; do you really need to get test mode running as well?
ah
that I did not know
Thanks so much for everyone's help
I think I have what I need at this point
Best Regards!