-
Notifications
You must be signed in to change notification settings - Fork 35
Description
The deno-slack
versions
"deno-slack-sdk/": "https://deno.land/x/[email protected]/",
"deno-slack-api/": "https://deno.land/x/[email protected]/",
Deno runtime version
deno 1.46.2 (stable, release, x86_64-unknown-linux-gnu)
v8 12.9.202.5-rusty
typescript 5.5.2
OS info
#25~24.04.1-Ubuntu SMP PREEMPT_DYNAMIC Tue Apr 15 17:20:50 UTC 2
Describe the bug
When developing a Slack app using the Slack CLI, the client.chat.scheduledMessages.list
method appears to silently fail inside Slack Functions. It returns a successful response, but the scheduled_messages list is empty—even immediately after a successful client.chat.scheduleMessage
call for the same channel.
Steps to reproduce
- Run your project with
slack run
- Trigger a function that schedules a message to a channel (client.chat.scheduleMessage)
- Get a successful API response for scheduling
- In the same function, call client.chat.ScheduledMessages.list for the same channel
- Get successful response but an empty list of scheduled messages
Minimal fuction to try this:
async function testScheduledMessages(
params: ChatScheduleMessageParams,
client: SlackAPIClient,
) {
// Trying to send a plaintext in the params
const plaintextPost = await client.chat.scheduleMessage({
channel: params.channel,
text: "THIS IS A TEST SCHEDULED MESSAGE",
post_at: params.post_at,
});
console.log("Plaintext Post Response:", plaintextPost);
// Show the scheduled message list
const scheduledMessages = await client.chat.scheduledMessages.list({
channel: params.channel,
});
console.log("List of Scheduled Messages:", scheduledMessages);
}
Expected result
After successfully scheduling the message and calling client.chat.scheduledMessages.list, it should be shown in the list of scheduled messages from the response.
Actual result
After successfully scheduling the message, the result of client.chat.scheduleMessages.list is successful, but the list is empty.
Requirements
Please read the Contributing guidelines and Code of Conduct before creating this issue or pull request. By submitting, you are agreeing to those rules.