I have been developing Ghost Themes for a while now, and since v3 implementing membership or simply adding a subscribe button has been proven impossible.
I do everything as the documentation says, I can even copy the code on the documentation page and paste it on my theme and it won’t work. It doesn’t work on localhost nor the production online. It didn’t work on v3 and with v4 I hoped this could change but it still a difficult process.
Can someone help me with this? I have searched everywhere and nothing could put me in the right direction.
The “401 Unauthenticated” is expected, it’s the API saying there’s no member logged in.
Could you explain what exactly isn’t working? There’s nothing in your topic that explains what you are expecting and how what you are seeing doesn’t match
I’m using Namecheap for the domain and am self hosting ghost. Why do regular gmail addresses not work here? It looks like this may be a recurring issue?
Upgrading from Ghost v3 to v4 with mailgun properly set up does not recognize gmail domains as valid email addresses for subscriptions (note I did not previously have subscriptions set up).
Confirmation requests sent to email addresses that are recognized as valid are sent to the SPAM folder.
I can confirm that my mailgun account is set up correctly because when I CURL the API, I am able to send an email to myself that does not get flagged as SPAM.
Alrighty, so after burning 4 hours on this I finally managed to get subscriptions working. For those reading in the future - what I am about to say applies to self hosted ghost installations on Digital Ocean… perhaps specifically after migrating from v3 to v4. This may apply more generally.
Set up mailgun
After mailgun confirms that you set up your domain correctly then you wont need to do any further configuration on their service. You’ll know you’re good to go once you get an email like this:
At this point you will have a strong temptation to configure the API credentials for mailgun under the subscriptions tab. Go ahead and do that. At this point you will believe that you’re integration is complete but you’re wrong (as verified by@Sarah_Hein ).
At this point the "secureConnection" key is currently set to true. Taking a tip from@joncojonathan , change the "secureConnection" key to false. (Having it true didn’t work for me).
Then Hit control-s to save and then control-x to quit nano.
Finally, now that you’re back on the command line, run ghost restart to put your changes into effect.
Thank you
Just wanted to give a big shout out to the ghost developers for making Ghost an amazing - if not the most amazing - blogging platform on the Internet. And I am also very thankful to the ghost user community who took time to document parts of their solutions without which I would not have been able to get this feature working. Thank you all!!