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

Facebook share button integration #545

@PierreMarieRiviere

Description

@PierreMarieRiviere

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();
        });
};

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions