Best answer

How to access to the snippet data in Slack ?

  • 29 August 2023
  • 3 replies
  • 154 views

Userlevel 1

Hello everyone,

I would like to retrieve data from Slack. These are in a Slack text snippet because, even though it's text, there are a lot of characters.
If you don't know, the text snippet is a feature present in Slack and which allows, among other things, to send a large number of lines of text (like code).



On Zapier, I would like to use the "New Message Posted to Private Channel in Slack" or "New File in Slack" function but I cannot access the data that is in the Slack text snippet... Anyone have an idea?

Thanks in advance

icon

Best answer by SamB 30 August 2023, 13:36

View original

This post has been closed for comments. Please create a new post if you need help or have a question about this topic.

3 replies

Userlevel 7
Badge +11

Hi there @Damdam! 👋

I’ve been looking into this but couldn’t find any existing feature requests for the ability to have the content of a text snippet returned with either of the New Message Posted to Private Channel or New File Slack triggers. I’m unable to open up a feature request for this on your behalf so I’d recommend reaching out to our Support team about this. They’ll be able to submit a new feature request for the Slack app and add your vote to it.

In the meantime, if Slack allows you to set up a webhook on their end, that happens to send the contents of the text snippet, you could get it to send that webhook to a Zap. So instead of using Slack as the trigger, you’d use the Webhooks by Zapier app as the trigger - see: Trigger Zaps from webhooks. It looks like Slack has an Events API that you might be able to use for this: https://api.slack.com/apis/connections/events-api. I’ve not used it myself to access the contents of a text snippet before so I can’t fully guarantee it’s definitely possible but thought it worth suggesting just in case it works! 🙂 

Userlevel 1

Hi @SamB

Thank you for your answer !
I will contact the support team and also try to use a Webhook!


Have a nice day 🙂

Userlevel 7
Badge +11

You are most welcome, @Damdam. 🤗

Should you run into any issues on setting that up just let us know - the Community is always here and happy to help!