jamstack-comments-engine icon indicating copy to clipboard operation
jamstack-comments-engine copied to clipboard

Need more detailed instructions

Open i-bsd opened this issue 5 years ago • 9 comments

Really appreciate the work you've done here but is it possible to add some more detail to the instructions you've listed? Trying to set this up for some Gatsby sites urgently and mostly stuck trying to decipher some of the instructions.

Thanks.

i-bsd avatar Oct 29 '19 03:10 i-bsd

For example, what is APPROVED_COMMENTS_FORM_ID referring to? Where is that ID set?

i-bsd avatar Oct 29 '19 03:10 i-bsd

It looks like in order to create the approved-comments form, you need to actually have a form on your site but hidden. Is that correct? I don't see a way to manually add an approved-comments form in the Netlify dashboard for approved comments. I just don't see it anywhere in your code so not sure how you've done it.

i-bsd avatar Oct 29 '19 03:10 i-bsd

Ok almost there. Got Slack notifications working.

But - when I click Approve or Delete Comment it does nothing.

i-bsd avatar Oct 29 '19 04:10 i-bsd

I got to the same point when trying this out. Did you make any further progress @i-bsd ?

I think I followed all the steps (some are a little cryptic), though possibly not number 2, because I don't know what it means to "configure a Slack integration on your Slack account".

smth avatar Dec 08 '19 11:12 smth

The error I get in Slack is chat.attachmentAction not ok: invalid_action_url.

smth avatar Dec 13 '19 16:12 smth

Is this project dead? Running into the same issue here.

adamtaylor13 avatar Jul 28 '20 23:07 adamtaylor13

Not dead. Works great (e.g. I set it up here: https://www.yearlyglot.com/dont-use-flashcards#comments and here: https://donovannagel.com/mdx). Just takes a bit of work to set up correctly.

However, for a new project we're working on, I had to rewrite a lot of this to handle comment replies and multi-level comment threads. The only thing I haven't figured out is setting up a serverless function for email notifications of replies (to the parent commenter).

i-bsd avatar Jul 28 '20 23:07 i-bsd

But - when I click Approve or Delete Comment it does nothing.

@i-bsd How did you end up resolving this? I got to the exact same spot and I can't figure out how to get the button responses to work.

adamtaylor13 avatar Jul 30 '20 02:07 adamtaylor13

Hi at @smth and @adamtaylor13 I figured it out. If you open the network tab when pressing the buttons you should see chat.attachmentAction and if you open that file the following json should show:

{
    "ok": false,
    "error": "invalid_action_url",
    "is_temp": true,
    "response": "Hmm, that didn't work, because this app is missing a request URL. Define one here: <https://api.slack.com/apps/<some_random_hash>interactive-messages|<your_slack_app_name>",
    "is_api_error": false
}

and if you follow the link, and add in your request url; https://yourcoolsite.com/.netlify/functions/comment-action then it should work!

EDIT:

I wrote a post about setting it up with step-by-step instructions Jamstack Engine Guide

Peter-Lankton avatar Sep 25 '20 13:09 Peter-Lankton