we use token to access the webhook from broker, I ...
# pact-broker
d
we use token to access the webhook from broker, I discovered that the previous config got the token wrong in the broker. Is there a way to correct the token setting in the broker?
m
What do you mean by "accessing the webhooks"?
Do you mean there is a token in the webhook you need to update?
d
yep
I just realized that the original value was wrong, from a different consumer
m
how did you create the webhook in the first place? Via the API, HAL browser or CLI?
I’d use the CLI to create or update the webhook
d
TBH, I don't really know how it was created in the first place
I guess it's via api tho
m
I’d use the HAL browser to find your existing webhook, and then update that using the HAL browser, CLI or APIs above
or use Pactflow - we have a UI 🙂
d
I think we have our own pact broker tho 😞
I am reading this doc: https://docs.pact.io/pact_broker/api/webhooks, so if I only need to update the token, should I just specify the updated token to "request" -> "url" ?
m
I’m not sure what you mean by that, sorry
what do you actually need to do, in the webhook?
d
Copy code
HTTP/1.1 POST <https://avrdevjenkins00n.ndmad2.tripadvisor.com/generic-webhook-trigger/invoke?token=aaaaaa&BRANCH=develop&PACT_CONSUMER_TAG=bugfix>
that's from the hal browser, the aaaaaa is wrong I will need to update it to bbbbbb
m
right, then yes that sounds about right
I think we have our own pact broker tho
You can always migrate 😉
I’d look to get those webhooks as code
d
any detail example on the pact-cli? I guess I need something like
Copy code
Usage: "broker create-or-update-webhook URL --uuid=UUID -X, --request=METHOD -b, --broker-base-url=BROKER_BASE_URL"
is there a way to ignore ssl for the pact cli ?
m
I believe there is, but you shouldn’t do that - if you have SSL somebody presumably cares about it. See the standard Open SSL env flags here: https://github.com/pact-foundation/pact-ruby-standalone/releases
I believe you can set
DISABLE_SSL_VERIFICATION=true
d
I am using the docker version cli, this
DISABLE_SSL_VERIFICATION=true
, is that an environment variable?
looks like it's
PACT_DISABLE_SSL_VERIFICATION
👍 1