#robert-cli-webhook

1 messages ยท Page 1 of 1 (latest)

safe willow
#

@austere saddle it depends on the event you are trying to test

austere saddle
#

Hello again.

#

I am testing

#

invoice.payment_succeeded

#

and failed

safe willow
#

this "fixture" is the sequence of calls we use to trigger the event, so it starts by creating a customer

#

so what you could do is make your own fixture (or change that one) to not use the existing customer and instead pass a hardcoded customer id to the next call (or use --add)

#

but at this point my advice is to just use the API instead of the CLI to trigger a specific version of the event, way faster/more flexible

austere saddle
#

Yes I would but I am using firebase emulators locally and functions are not yet deployed ๐Ÿ˜„ so I need to test locally

#

I will try the --add option that you suggested

safe willow
#

sure but you can easily try locally with code still in any language you're familiar with

#

and you can't just use --add you need to modify the fixture

austere saddle
#

ok, any guide on how to modify it :D?

#

I need to edit the cli file itself from what I see :

safe willow
#

I don't have a specific guide sorry

#

we're back to: way faster to write code :p

#

or sequence calls of the CLI

austere saddle
#

ok, then the API it is then ๐Ÿ˜„

#

Thank you for your help :), Have a nice day!

#

As a sidenote I think I can use those fast forwarded clocks.

#

But need a publicly available function ๐Ÿ˜ฆ

safe willow
#

what does that mean "need a publicly available function"?

austere saddle
#

well so I can access it with the webhook call

safe willow
#

I'm sorry I just don't follow

#

Can you take a small step back and explain what you need that is missing?

#

fast forwarded clocks exist and have been public for a while

austere saddle
#

Noooo

#

My endpoint needs to be public ๐Ÿ™‚

#

I was not refering to the clocks

safe willow
#

ah gotcha

austere saddle
#

Thank you!