How to modify event payload to make it compatible to webhook? | Community
Skip to main content
Level 2
January 3, 2022
Question

How to modify event payload to make it compatible to webhook?

Hi,

 

I'm trying to setup Adobe IO events to post notification on Slack for assets created, deleted and so on. However, OOTB if I do, the payload is not compatible to Slack as it requires to have a mandatory property text for Slack which is not part of Adobe IO event payload. 

So, how can I customise the payload to have event posted on Slack?

Best regards,
Himanshu Singhal

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.

3 replies

Employee
January 4, 2022

Hi @zeiss_hs,

You cannot directly use a Slack webook with Adobe I/O Events, because of the same constraint you mentioned. You will need a webhook to proxy your event payload to Slack in a compatible format. This can be achieved by a simple Adobe I/O Runtime action (or any other serverless function). Below is a sample repository for inspiration:

https://github.com/hirenoble/webhook_server#update-slack-incoming-webhook 

Translate
zeiss_hsAuthor
Level 2
January 24, 2022

Thank you so much and it works well. I've got a question though....Isn't there anyway to have this modification done in Adobe I/O platform? or we can deploy the project there instead of having maintained it on a separate server?

Translate
Employee
January 27, 2022

@zeiss_hs I am not sure if I fully understand your question, but let me take a stab at it.

If you have Adobe I/O Runtime enabled in your org, then you can deploy a Runtime action that essentially does the same modification. You can then use Runtime Action as a Webhook against your events integration and achieve the same goal.

Hope this helps.

Translate