Back to APIs list

Slack API examples & templates

Use these vals as a playground to view and fork Slack API examples and templates on Val Town. Run any example below or find templates that can be used as a pre-built solution.
templateRedditAlert
charmaine
templateRedditAlert
Remix of: valdottown/templateRedditAlert
Cron
redditAlert
charmaine
redditAlert
Remix of: valdottown/templateRedditAlert
Cron
dailySlackRoundup
Scripted
dailySlackRoundup
Remix of: mikker/dailySlackRoundup
valTownInspoList
rodrigotello
valTownInspoList
Val Town inspiration & use cases list List [as object] used in Val Town's use cases and inspiration. Check it out at in /examples/use-cases and /docs/tutorial/4
valTownInspoList
charmaine
valTownInspoList
Remix of: rodrigotello/valTownInspoList
townieIllustratorPrompt
charmaine
townieIllustratorPrompt
Add this to Townie's System prompt by going into Townie's Settings — First ask a user what app they would like you to illustrate. Then create an app outline generator for any app that is requested that produces a simplified, visual representation of the app's interface. Core Functionality - Accept an app name as input (e.g., "Zoom", "Slack", "Discord") - Generate a single val that renders a minimal, branded mockup of the app's main interface - Allow the user to export a png screenshot with transparent background with rounded corners (8px radius) - Move the `html2canvas` import inside the `client()` function. - Wrap the `exportAsPNG` function in a `useEffect` hook to ensure it's only defined on the client-side. - Use dynamic import for `html2canvas` inside the `exportAsPNG` function. - Make sure html2canvas is only loaded and used on the client-side Visual Requirements - Match the app's primary brand colors (limit to 2-3 colors) - Do light or dark mode of the app depending on which is the default for that app - Use placeholder blocks in light gray (#E5E5E5) for text and controls - Include key structural elements specific to the app (e.g., sidebars, headers, content areas), refrain from including text - Use SVG for any icons or logos, built into the component, if needed. - Apply consistent spacing (16px grid) - Ensure the generated outline is compact (around 280x220 pixels) for easy sharing and quick visualization.
templateRedditAlert
valdottown
templateRedditAlert
Reddit Keyword Alerts [TEMPLATE] Get notifications when specific keywords appear in Reddit posts. This template will help you: Search Reddit for specific keywords within a defined time range. Send notifications to your preferred platform (Discord, Slack, email, etc.) Reddit does not have an API that allows users to scrape data, so we are doing this with the Google Search API, Serp . Example This val tracks mentions of "Val Town" and related terms on Reddit, filtering results from the last 7 days and sending alerts to a Discord webhook. Set Up 1. Fork this Val To start using this template, fork this val by clicking the fork button at the top-right corner of the page. 2. View Source Code The CODE box shows you the the full source code of this val, you may need to scroll down to see it. 3. Get a SerpApi Key This template requires a SerpApi key to search Reddit posts via Google search results. Get a SerpApi key : Sign up at SerpApi to create an account. Generate an API key from your account dashboard. Add the SerpApi key to your environment variables : Go to your Val Town environment variables . Add a new key: Key: SERP_API_KEY Value: Your SERP API key. Without this key, the val will not function correctly. 4. Customize Keyword In the CODE box below, update the terms or phrases you want to track: const KEYWORDS = "\"node\" OR \"node.js\""; 5. Set Up Your Notification Method This template uses a Discord webhook for notifications. You can update this to your preferred platform: Create a Discord webhook following this guide . Save your webhook URL in your Val Town environment variables: Key: mentionsDiscord Value: Your Discord webhook URL. Notifications will be sent using this function: await discordWebhook({ url: Deno.env.get("mentionsDiscord"), content, }); To switch to another platform (e.g., Slack, email, or custom webhooks), replace the discordWebhook call with the appropriate integration ((e.g., @std/email , Slack , or anywhere else ) 🎉 Congrats! You now have a val running that ensures you never miss another Reddit mention. 🎉 NOTE: Usage Limits SerpApi: Free SerpApi accounts have monthly call limits.
Cron
humbleBlushSeahorse
charmainetest
humbleBlushSeahorse
Remix of: valdottown/templateRedditAlert
Cron
redditAlert
charmainetest
redditAlert
Remix of: valdottown/templateRedditAlert
Cron
grandCoffeeSquirrel
charmainetest
grandCoffeeSquirrel
Remix of: valdottown/templateRedditAlert
Cron
tangibleBlackTiger
charmainetest
tangibleBlackTiger
Remix of: valdottown/templateRedditAlert
Cron
honestMagentaCrane
charmaine
honestMagentaCrane
Remix of: valdottown/templateRedditAlert
Cron
blueskyAlert
ianvph
blueskyAlert
Remix of: ianv/blueskyAlert
Cron
scholarlyIvoryMosquito
charmainetest
scholarlyIvoryMosquito
Remix of: valdottown/templateRedditAlert
Cron
templateRedditAlert
charmainetest
templateRedditAlert
Remix of: valdottown/templateRedditAlert
Cron
twitterAlert
charmainetest
twitterAlert
Remix of: valdottown/templateTwitterAlert
Cron