Skip to content
This repository has been archived by the owner on Sep 20, 2024. It is now read-only.

Facebook share button integration #545

Closed
PierreMarieRiviere opened this issue Dec 10, 2016 · 6 comments
Closed

Facebook share button integration #545

PierreMarieRiviere opened this issue Dec 10, 2016 · 6 comments

Comments

@PierreMarieRiviere
Copy link

It should be very easy but for some reason I can't make it work. Any idea?

var controller = Botkit.facebookbot({
    receive_via_postback: true, 
    require_delivery: false,
});
convo.ask({
            attachment: {
                'type': 'template',
                'payload': {
                    'template_type': 'generic',
                    'text': 'message text',
                    'elements':[
                      {
                        'title':'title',
                'image_url':'https://pbs.twimg.com/profile_images/560691888085168128/cLnDcYTB.jpeg',
                        'buttons':[{
                            'type':'postback',
                            'title': 'title',
                            'payload': 'payload',
                        },
                          {
                            'type':'element_share'
                          }              
                        ]
                      }
                    ]
                  }
              }
        }, function(response, convo) {
            convo.say("Awesome.");
            nextTopic(response, convo);
            convo.next();
        });
};
@jonchurch
Copy link
Contributor

What exactly is not working?

@PierreMarieRiviere
Copy link
Author

The share button does not display

@PierreMarieRiviere
Copy link
Author

PierreMarieRiviere commented Dec 13, 2016

@jonchurch sorry I don't have more detail, everything in the convo is firing normally except the share button, as if it was just ignored. Am I the only one facing the issue?

@PierreMarieRiviere
Copy link
Author

I could make it work just following Facebook Guidelines

Sorry and closed!

@jonchurch
Copy link
Contributor

@devhaoy No worries. Just curious, what was it that you had to fix?

@PierreMarieRiviere
Copy link
Author

@jonchurch not too sure really, I just copy pasted the Facebook example and it worked - I haven't tried to understand why my code wasn't firing the button.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants