Giter Site home page Giter Site logo

Comments (5)

qadirsuh avatar qadirsuh commented on May 30, 2024 1

OK. thanks for this.

from smooch-bot-example.

mspensieri avatar mspensieri commented on May 30, 2024

If you configure your Smooch webhook with the message:appMaker trigger, then your bot will be able to process messages received from Slack or Front. Your bot should make sure to check the role of the message to know whether it was sent by the user, or a member of your team before deciding how to handle the message.

from smooch-bot-example.

qadirsuh avatar qadirsuh commented on May 30, 2024

I did it. Thanks for pointing this out.
here What I did in heroku/index.js

app.post('/slack', function(req, res, next) {

    const trigger = req.body.trigger;

    switch (trigger) {
        case 'message:appMaker':
            console.log('message:appMaker');
            handleBusinessMessages(req, res);
            break;

        default:
            console.log('Ignoring unknown webhook trigger: /slack', trigger);
    }
});

in smooch configuration
https://www.dropbox.com/s/6hqaalmau0na3gh/Screenshot%202017-01-10%2015.27.46.png?dl=0

Now I can pass the message from the slack/front through my code. BUT

Can we control this i.e . The message (from slack/front) should not be displayed/rendered to our customer unless we process it. Right now its got received to our customers immediately once we send it from slack/Front. Like is there any method bot.say("bla bla bla") i.e appMaker.say("bla bla") etc ;)

from smooch-bot-example.

mspensieri avatar mspensieri commented on May 30, 2024

Any message you send through Slack/Front will be added to the conversation history (and visible by the user) - there isn't currently a way to prevent this behaviour

from smooch-bot-example.

qadirsuh avatar qadirsuh commented on May 30, 2024

Is there currently a way to prevent this? In other words: Smooch as a reverse proxy would be very nice.

from smooch-bot-example.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.