Public
Script
stevekrouse avatar
resyAuth
@stevekrouse
Script
Forked from vtdocs/resyAuth
kora avatar
redAnglerfish
@kora
Script
Fetch Learn how to use proxied fetch
johndturn avatar
quotableApiProxy
@johndturn
HTTP
Quotable API Proxy Small HTTP proxy to the Quotable API ( https://api.quotable.io ). I built this due to some DNSSEC issues that the Quotable API is currently experiencing. See this Github issue here for more information.
weaverwhale avatar
GistGPT
@weaverwhale
HTTP (deprecated)
GistGPT A helpful assistant who provides the gist of a gist How to use / and /gist - Default response is to explain this file. I believe this is effectively real-time recursion ? /gist?url={URL} - Provide a RAW file URL from Github, BitBucket, GitLab, Val Town, etc. and GistGPT will provide you the gist of the code. /about - "Tell me a little bit about yourself"
vtdocs avatar
resyBookSlot
@vtdocs
Script
(Part of: https://www.val.town/v/vtdocs.resyBot) Given a valid booking token, this val attempts to make a reservation for the booking token's slot. There is some retry logic as the API route (rarely) returns an internal server error.
pranjaldotdev avatar
pushover
@pranjaldotdev
Script
// Send a pushover message.
pomdtr avatar
raw
@pomdtr
HTTP (deprecated)
Fetch the source of a val This val was created before the introduction of https://esm.town Usage curl https://pomdtr-raw.web.val.run/v/<author>/<name>.<extension>[?v=<version>] To see the code of this val, use https://pomdtr-raw.web.val.run/v/pomdtr/raw.ts Examples Fetching the val code $ curl https://pomdtr-raw.web.val.run/v/pomdtr/add.tsx You can also use js , jsx and ts extension (only the content-type change, there is no transpilation). Fetching private val Pass an api token as an username $ curl "https://<token>@pomdtr-raw.web.val.run/v/pomdtr/privateVal.ts" Fetching the val README $ curl https://pomdtr-raw.web.val.run/v/pomdtr/add.md Getting an image $ curl https://pomdtr-raw.web.val.run/v/pomdtr/add.png Fetching a specific version of a val $ curl https://pomdtr-raw.web.val.run/v/pomdtr/raw.ts?v=66 You need to be authenticated to use this method. Fetching the val metadata $ curl https://pomdtr-raw.web.val.run/v/pomdtr/add.json Running vals locally using Deno Create a new val.ts file referencing the @pomdtr.add import { add } from "https://pomdtr-raw.web.val.run/v/pomdtr/add.ts"; console.log(add(1, 2)); then use deno run $ deno run ./val.ts 3 If you val accept a request and return a response, you can pass it to Deno.Serve to run it locally! import {raw} from "https://pomdtr-raw.web.val.run/v/pomdtr/raw.ts"; Deno.serve(raw); If your val is private, you can set the DENO_AUTH_TOKENS env. DENO_AUTH_TOKENS=<val-town-token>@pomdtr-raw.web.val.run deno run val.ts
karfau avatar
githubEmoji
@karfau
HTTP (deprecated)
Usage import {githubEmojiUrl} from "https://esm.town/v/karfau/githubEmoji"; console.log(githubEmojiUrl('+1')) //"https://github.githubassets.com/images/icons/emoji/unicode/1f44d.png?v8" or in a browser <img src="https://karfau-githubEmoji.web.val.run/+1"></img> Looks like in the preview. curl https://karfau-githubEmoji.web.val.run/+1 (prints "https://github.githubassets.com/images/icons/emoji/unicode/1f44d.png?v8" ) If the name you pass (as argument or in the request path) is not in the list, it returns The list of names can be accessed using githubEmojiNames or by calling https://karfau-githubemoji.web.val.run/names
tempguy avatar
copperScorpion
@tempguy
HTTP (deprecated)
An interactive, runnable TypeScript val by tempguy
abhudson3 avatar
tanCrane
@abhudson3
HTTP (deprecated)
Forked from abhudson3/webscrapeMinhaBibliotecaCatolicaBoxList
byjp avatar
addShortlink
@byjp
Express
Shortlinks for the decentralised web This is a script to allow API-based updating of the shortlinks/redirects in an IPFS-based shortlink repo (using val.town). I've written up how all this works on my blog at https://byjp.me/posts/link-shortener
janpaul123 avatar
valwriter_output
@janpaul123
Script
// This approach fetches weather data for Brooklyn, NY from the Open Meteo API
tempguy avatar
amberPig
@tempguy
Script
An interactive, runnable TypeScript val by tempguy
yawnxyz avatar
unpaywall
@yawnxyz
HTTP (deprecated)
// Unpaywall DOI access function
vladimyr avatar
fetch_impl_examples
@vladimyr
Script
An interactive, runnable TypeScript val by vladimyr
stevekrouse avatar
discordWebhook
@stevekrouse
Script
Send a Discord message Send a message to a Discord channel from Val Town. It's useful for notifying your team or community when someone interesting happens, like a user signup, Stripe payment, mention on social media, etc. import { discordWebhook } from "https://esm.town/v/stevekrouse/discordWebhook"; await discordWebhook({ url: Deno.env.get("engDiscord"), content: "Hi from val town!", }); Example val: https://www.val.town/v/stevekrouse.discordWebhookEx Setup 1. Create a Discord Webhook Follow the instructions here: https://support.discord.com/hc/en-us/articles/228383668-Intro-to-Webhooks It really only takes 2 minutes. 2. Copy webhook URL Paste it into your secrets as discordWebhook . 3. Send a message! import { discordWebhook } from "https://esm.town/v/stevekrouse/discordWebhook"; await discordWebhook({ url: Deno.env.get("engDiscord"), content: "Hi from val town!", }); Example val: https://www.val.town/v/stevekrouse.discordWebhookEx
April 3, 2024