Creating Slack Notifications using Webhooks
Description description
You want to use Slack with webhooks to be able to customize the integration a bit more than using it as a Launchpoint service.
Resolution resolution
We will assume you have already created your App within the Slack API page; we will cover everything after that here.
-
Make sure you are logged in so you can access your App through the Slack API page.
-
Select your App:
-
From here you will want to select Incoming Webhooks from underneath Features:
-
Use the on/off toggle to the right of the title Activate Incoming Webhooks.
-
Select the Add New Webhook to Workspace button to create a new URL that we will use for our webhook within Marketo:
-
Select where you want to post, either at a specific user or channel:
-
Now we are directed back to the page we were on; hit the Copy button next to the Webhook URL to copy the URL as we will need it for a later step.
-
Log in to your Marketo instance and navigate to the Admin section.
-
Select Webhooks.
-
Select Create Webhook. For the following fields assign the appropriate values:
- Webhook Name* : whatever you want to name it
- Description: a description of what the webhook is used for
- URL* : here is where we paste the URL we copied before
- Request Type* :
POST - Template: this is the information you want to send to your Slack channel/user. It should be in the following format:
payload={"text": "DEVELOPER SITE ALERT: {{lead.First Name:default=edit me}} {{lead.Company:default=edit me}}, {{lead.Email Address:default=no email address}}"} - Request Encoding:
None(you can change this if you want) - Response Type:
None
-
Click Create and now we are ready to call our webhook and send necessary data to our users in Slack!