{
"error": {
"message": "Invalid URL: URL must be publicly accessible. Consider using a tool like the Stripe CLI to test webhooks locally: https://github.com/stripe/stripe-cli",
"param": "url",
"type": "invalid_request_error"
}
}
pair stripe-cli with stripe account $ stripe login
you will be prompted with a pairing code and a URL
visit the URL and allow access
set your stripe-cli to listen stripe listen --forward-to http://localhost:2368/members/webhooks/stripe/
you will be prompted with a webhook signing secret
finally, start your ghost enviroment with your individual webhook secret WEBHOOK_SECRET=whsec_1234567890abcdefg ghost start
important: stripe listen has to run in it’s own terminal window, so don’t close it. Start ghost with the webhook in a new terminal window/tab instead.
For recurring sessions, you only need to start the stripe listen process in window 1 and start ghost with webhook in window 2. stripe login is only needed the first time.
Thank you very much for the reply. I was following exactly same as you described but the issue was something else.
I am on Windows. The issue in not in the steps actually the issue is in the windows command prompt or my adaptation of the command in Windows environment.
If anyone face this problem in future, for them the following explanation.
I’m using Windows 10 aswell.
You should definitely check out WSL2 (Windows Subsystem for Linux)
It’s free and can be installed on every Windows 10 Version 2004, Build 19041 or newer.
It let’s you run Linux Distributions inside windows with a full linux kernel, which should give you greater performance compared to a standard VM.
Useful if you want to run apps natively in linux, like ghost on an ubuntu distro.