Search
  • Michael Gena

Slack Notification from Nuxeo


Slack is nowadays the #1 collaborative tool. It simplifies and makes it fun to work together as a team.

One feature that is really convenient is its capability to integrate with other systems and let you receive notifications on specific channels.

In our CCM (Customer Content Management) tool we have Deals that have different states. And lucky for us most of the time we close deals :) (by closing I mean winning of course).

So the need was to notify the team on Slack whenever someone wins a deal so that we can all celebrate together.


Different Steps

It turns out, it is pretty simple to do. First I created an app on Slack by following the tutorial here.


Then I created a Webhook that will enable me to push notification on the channel #general.

Once you have your Webhook ready you are almost there.


You can even try the simple Hello, World! by using the curl command.


Now, all I needed to do is post a message to the Webhook from our CCM, which is based on nuxeo.

Nuxeo lets you make an HTTP POST call from an automation script (more detail about it here).

So, all you have to do is listen to your document modification event and add the following code and the magic will happen!

RunScript(null,{script:'HTTP.call(null,null,"POST",     
                "https://hooks.slack.com/services/XXX/XXX",'+
                '"{\\"text\\":\\"'+input.title+' Deal for '+input['opportunity:amount']+' € Won!\\"}");'});


As you could see you currently need to get a little bit your hands dirty to get there. We are planning to simplify this and provide a user-friendly UI to be able to add a webhook within your business rules process. Stay tuned...

0 views

© 2020 Qualitified. 

  • Grey LinkedIn Icon
  • Grey Facebook Icon