Back to APIs list![stevekrouse avatar](https://images.clerk.dev/uploaded/img_2PqHa2Gsy93xQrjh2w78Xu0cChW.jpeg)
![rcurtiss avatar](https://img.clerk.com/eyJ0eXBlIjoicHJveHkiLCJzcmMiOiJodHRwczovL2ltYWdlcy5jbGVyay5kZXYvb2F1dGhfZ2l0aHViL2ltZ18yWXl1UURVdXVqeFNBclNQN3lCek50SWRiS0gifQ)
![fil avatar](https://img.clerk.com/eyJ0eXBlIjoicHJveHkiLCJzcmMiOiJodHRwczovL2ltYWdlcy5jbGVyay5kZXYvdXBsb2FkZWQvaW1nXzJVVnNveGQxSFhEY1F1SjAzQ0tBcGd3SENoWC5wbmcifQ)
Bluesky API examples & templates
Use these vals as a playground to view and fork Bluesky API examples and templates on Val Town. Run any example below or find templates that can be used as a pre-built solution.
![stevekrouse avatar](https://images.clerk.dev/uploaded/img_2PqHa2Gsy93xQrjh2w78Xu0cChW.jpeg)
blueskyAlert
@stevekrouse
Script
Bluesky keyword alerts Custom notifications for when you, your company, or anything you care about is mentioned on Bluesky. 1. Query Specify your queries in the queries variable. Bluesky doesn't support boolean OR yet so we do a separate search for each keyword. 2. Notification Below I'm sending these mentions to a private channel in our company Discord, but you can customize that to whatever you want, @std/email, Slack, Telegram, whatever.
bsky_rss_poll
@rcurtiss
Script
Bluesky RSS bot This is a bot that polls an RSS feed for a new item every hour and posts it to Bluesky. It's split into three parts: bsky_rss_poll This function runs every hour and polls the provided RSS feed, turns it into XML and runs the check. If there is a new post, it tell rss_to_bsky to post a link (and the title) to Bluesky latest_rss This is a stored object that keeps the latest object for the poll to test against rss_to_bsky This function turns the text post into a rich text post and posts it to Bluesky
cron_rezo_rss2bsky
@fil
Cron
Passerelle RSS vers BlueSky Ce script tourne une fois par heure et reposte les news de https://rezo.net/ vers le compte https://bsky.app/profile/rezo.net Il utilise 3 éléments: l'URL du flux RSS une variable de stockage de l'état, qu'il faut créer initialement comme let storage_rss_rezo = {} et qui sera mise à jour par le script les secrets du compte (username et mot de passe de l'application) Il appelle @me.bsky_rss_poll qui lit le flux, vérifie avec l'état s'il y a du nouveau, et au besoin nettoie le post, puis l'envoie avec le script @me.post_to_bsky . Sans oublier de mettre à jour l'état pour le prochain run. C'est un premier jet. Merci à @steve.krouse pour val.town et à @jordan pour ses scripts que j'ai bidouillés ici. À faire éventuellement: améliorer la logique; poster vers twitter .