> For the complete documentation index, see [llms.txt](https://docs.stammer.ai/stammer.ai-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.stammer.ai/stammer.ai-docs/white-label/white-label-api/examples/white-label-api-x-zapier-x-slack-example.md).

# White Label API x Zapier X Slack Example

{% embed url="<https://youtu.be/6VxJgW9MaG0>" %}

Goal: Create an A.I. Chatbot in Slack

Implementation: Connect Slack and Stammer.ai together with Zapier![](https://s3.amazonaws.com/cdn.freshdesk.com/data/helpdesk/attachments/production/150026544841/original/_9dD2QswiJpATAxw9dfz-u8tXnkRvzWmoQ.png?1692970985)

**Step 1: Setup the Zap:**&#x20;

* You can use the Zapier A.I. builder and type in "New Slack Message to Webhook to Slack Message"
* Or manually create a 3 step Zapier where the trigger is "New Message" which sends the data to the Stammer.ai API and gets the A.I. chatbot response.&#x20;

![](https://s3.amazonaws.com/cdn.freshdesk.com/data/helpdesk/attachments/production/150026542390/original/3XDjihLqMouJ0FY-Ehc_Mpi2dR1bPqBd0g.jpg?1692970037)

High level, this is what the Zap should look like.

\
![](https://s3.amazonaws.com/cdn.freshdesk.com/data/helpdesk/attachments/production/150026542398/original/eahNbPfvIH1LTSSsN2MFosn0NBgiRYPmeA.jpg?1692970046)

**Step 2: Setup the New Message Trigger**

* Sign into your Slack account
* Select the channel/ user you want messages to be received from and sent to the A.I. chatbot\
  &#x20;![](https://s3.amazonaws.com/cdn.freshdesk.com/data/helpdesk/attachments/production/150026542603/original/uuwItAT9wKjUe42s_o3d_jSJesunBNZrwA.jpg?1692970122)

**Step 3. Send the new user message to the Zapier webhook**&#x20;

* Under the dropdown menu for Event and select POST

![](https://s3.amazonaws.com/cdn.freshdesk.com/data/helpdesk/attachments/production/150026542698/original/l4ce3zR1x16qp4urEySGZ6hMgTgeK9wjFg.jpg?1692970142)

**Step 4. Setup the Action Step**

* URL: Paste in your white label webhook URL
* Payload Type: JSON
* Data: Add two fields with the following information
  * chatbot\_uuid - \[paste in the chatbot UUID found in the chatbot settings]
  * query - \[Select the message that was received in the first Zap step]
  * user\_key - \[select a unique ID to identify each user's conversation]
* Wrap Request in Array: No
* File: Leave Empty
* Unflatten: Yes
* Basic Auth: Leave empty<br>
* Headers: Add one field
  * Authorization - Token \[paste in your API Key]

\
![](https://s3.amazonaws.com/cdn.freshdesk.com/data/helpdesk/attachments/production/150032664223/original/qvxNO5bK0JVN3iPyWDfVAeC_EH2eiQSt4g.jpg?1697124408)

**Step 5: Send A.I. response back to user in Slack**

* Event: Send Channel Message

![](https://s3.amazonaws.com/cdn.freshdesk.com/data/helpdesk/attachments/production/150026569829/original/iVm_QoqDsj6YJWylAQExyoZ4tHl9hvRz7g.jpg?1692979681)

* Select the the Answer field as the response to send back to a user in Slack

![](https://s3.amazonaws.com/cdn.freshdesk.com/data/helpdesk/attachments/production/150026569947/original/MC6B9OGDisDcnjQ6xK8FxOUTCcvaDTv2SA.jpg?1692979746)

And that's it you're done!

Your completed Zapier should look something like this:

![](https://s3.amazonaws.com/cdn.freshdesk.com/data/helpdesk/attachments/production/150026544679/original/y9szspWtXzyF6ySZO-Wt0wm6igRgW0jSXg.jpg?1692970923)
