slack-api

Slack outgoing webhook :URL(s)

蓝咒 提交于 2019-12-12 23:27:47
问题 Can anyone please explain the URL(s) in slack outgoing webhooks configurations? Thanks 回答1: The URLs in outgoing webhooks are locations that you control where, when certain conditions are met, Slack's servers will send a HTTP POST to the URL with the data described in the outgoing webhooks docs and you'll have a chance to respond with a simple messsage. You'll need a server or service that is reachable by Slack to work with outgoing webhooks. Here's another good overview of outgoing webhooks.

Combine message menu and message button in slack

▼魔方 西西 提交于 2019-12-12 20:17:21
问题 I want to combine message menu and message button in my slack app.This is the workflow I am trying to achieve. 1) User fires a slack slash command to display the menu. This menu will have one dropdown and three buttons. This I am able to achieve. 2) I want user to select an option from dropdown and press any of the action button.Then only the action should be triggered Problem is that when i select any option from dropdown, it triggers the action. I do not want the action to be triggered this

Slack Slash Command - Image Not Unfurling

北战南征 提交于 2019-12-12 18:23:53
问题 I have written a custom Slash command that takes in a query from the user and returns an image. The Server side which receives the Slash command retrieves the query from the user, and forms the Image URL http://example.com/file1.png and it sends back the response as <http://example.com/file1.png> . This is shown as a link in the response and is not unfurled. What could be the problem? I even tried the following: 1) I sent back a JSON payload as given below: { "text":"http://example.com/file1

Upload a file to slack with files.upload in PHP

旧街凉风 提交于 2019-12-12 18:17:57
问题 I'm trying to use the files.upload method to upload a file to Slack, but I only got a blank message so far. This is the code, I found this script on the internet, but it's not working. <?php include '../connessione.php'; $slacktoken = "myToken"; //this is not the real token ofc $header = array(); $header[] = 'Content-Type: multipart/form-data'; $file = new CurlFile('../tmp/slack_icon.png', 'image/png'); $postitems = array( 'token' => $slacktoken, 'channels' => "test_channel", 'file' => $file,

Send Hyperlink to call an api in Slack message

怎甘沉沦 提交于 2019-12-12 18:04:55
问题 my question is very simple. I want to send a link/button with a slack message and when receiver click on that link it calls an api to perform some task. here is my code: $msg = "hey! click to approve <a href='http://api2342.in/API/api.php'>Approve</a>"; self::sendSlackMessage($slackId,$msg); I have this sendSlackMessage API to send a message to the Slack user which receives two parameters, and its working fine. I just need to figure out how to send a link to call an API to perform a certain

How to find (and possibly delete) personal files

℡╲_俬逩灬. 提交于 2019-12-12 16:04:49
问题 Slack API has a method files.list , however this seems to list only files shared on public channels, not in private conversations. As a team admin I would like to delete old files (I don't need to see them). I could ask team members to delete them manually, but this is a very slow and laborious process for them. BTW, I am using a script based on this one 回答1: I am afraid that is not possible. Even as primary owner (the highest possible level) a user has no access to private channels or direct

Delete interactive message (command response) just with Slack Commands API

梦想的初衷 提交于 2019-12-12 12:36:57
问题 So I'm building a slack app in Node that responds to some user commands. It usually responds with an interactive message that has some attachments and buttons. For certain buttons, I return different types of texts or other attachments, but I also want to have a "Cancel" button that would basically cancel the current command - delete it from the user's chat. The thing is that I want to do it without having to request the chat:write:user scope or without having to create a bot . By asking for

“Sign in with Slack” keeps prompting user for permission every time

久未见 提交于 2019-12-12 11:25:15
问题 I'm doing the Slack integration for my website, including allowing users to log in using the "Sign in with Slack" button. Ideally I would expect it only asks users to grant the identity.* permissions once, then next times when they click "Sign in with Slack", the authorization screen should only flashes then redirect to the next step (like with Facebook for example), but it keeps showing the authorization screen and users have to click the "Continue" button to grant the permission again and

Call Slack API via VBScript Rule in Outlook

无人久伴 提交于 2019-12-12 09:47:30
问题 I'm trying to run a rule in Outlook that runs a VBScript which calls a Slack.com webservice and updates one of my Slack Channels with a specific message. Current state -- i just want it to post a static message. Future state i'm going to try to use RegEx to parse out certain data from the email and post it to my slack channel. From frankensteining a few scripts i found online, this is what i have (but doesn't quite work) Hoping someone can help... Function ProcessSend() Set oXMLHTTP =

can't open Slack dialog through google apps scripts

好久不见. 提交于 2019-12-12 08:57:26
问题 I'm trying to use google apps scripts and slack to automate my work. And I wish to enter some text with the Slack dialog to modify my google spreadsheet with google apps scripts. However, with the below code, I can't open a Dialog via Slack-API's Slash command . Is my code have some problems? function doPost(e){ var params = e.parameter; var token = params.token; var text = params.text; var trigger_id = params.trigger_id; var slackUrl = ["https://slack.com/api/dialog.open"]; if (token == "