wooden-beard-40210
11/17/2024, 7:52 AMclever-exabyte-40857
11/22/2024, 3:36 PMbreezy-piano-23067
11/29/2024, 6:17 AMbrainy-pizza-50024
12/03/2024, 6:04 AMechoing-notebook-80704
12/05/2024, 11:17 PMwooden-beard-40210
12/18/2024, 6:56 AMwooden-beard-40210
01/01/2025, 11:48 AMwhite-eve-51159
01/03/2025, 11:58 PMaverage-librarian-16523
01/12/2025, 10:24 AMacceptable-kangaroo-64719
01/13/2025, 6:23 AMnice-twilight-90450
01/14/2025, 2:05 PMwhite-nest-40686
02/27/2025, 5:27 AMcalm-processor-37645
02/27/2025, 8:27 AMtall-van-36880
03/28/2025, 8:55 AMechoing-notebook-80704
03/31/2025, 2:10 PMfew-restaurant-54584
04/12/2025, 10:16 PMbroad-knife-66298
04/22/2025, 3:56 PMprehistoric-airplane-85682
05/12/2025, 9:30 PMhallowed-book-52721
05/20/2025, 9:32 PMprehistoric-airplane-85682
05/22/2025, 8:10 PMhallowed-book-52721
05/24/2025, 4:53 AMhallowed-book-52721
05/24/2025, 10:07 PMprehistoric-airplane-85682
06/16/2025, 8:08 PMjs
const botId = '<your-bot-id>' // Replace with your actual bot ID (found in the URL)
const botpressApiUrl = 'https://api.botpress.cloud/v1/chat/conversations'
const botpressApiKey = env.PERSONAL_ACCESS_TOKEN // Create the variable in bot settings under Configuration Variables
// Create the PAT in the dashboard
const response = await axios.get(botpressApiUrl, {
headers: {
Authorization: `Bearer ${botpressApiKey}`,
'x-bot-id': botId
}
})
// Optional: Log the list of conversations
console.log(response.data)
response.data.conversations.forEach((conversation) => {
const conversationId = conversation.id
client.createMessage({
conversationId,
userId: botId,
tags: {},
type: 'text',
payload: {
text: "Don't forget to drink water!", // Your reminder message
},
})
})
📌 Notes:
* Secure your token: Always use env.PERSONAL_ACCESS_TOKEN, never hardcode it.
* Customize your schedule: You can run the Fixed Schedule card every few minutes, hourly, or daily.
* Conversation-aware logic: Want to only message certain users? Add filters inside the forEach loop.
https://cdn.discordapp.com/attachments/1384263331694776531/1384263331938041906/Screenshot_2025-06-16_at_2.55.25_PM.png?ex=6851cb30&is=685079b0&hm=e1b67b6c137d93218245587deeb2b44cc342e28d8c31055b117f7823a52dd5bf&prehistoric-airplane-85682
06/18/2025, 9:17 PMprehistoric-airplane-85682
06/20/2025, 4:02 PM