Val Town Code SearchReturn to Val Town

API Access

You can access search results via JSON API by adding format=json to your query:

https://codesearch.val.run/image-url.jpg%20%22Optional%20title%22?q=api&page=44&format=json

For typeahead suggestions, use the /typeahead endpoint:

https://codesearch.val.run/typeahead?q=api

Returns an array of strings in format "username" or "username/projectName"

Found 21430 results for "api"(3243ms)

slackBotExamplemain.tsx1 match

@stevekrouse•Updated 6 days ago
31 if (body.event?.type === "app_mention") {
32 try {
33 const result = await fetch("https://slack.com/api/chat.postMessage", {
34 method: "POST",
35 headers: {

slackBotExampleREADME.md1 match

@stevekrouse•Updated 6 days ago
4
5This guide walks you through creating a Slack bot that replies when mentioned in
6a channel. You'll use Val Town to host your bot and Slack's API to connect it to
7your workspace.
8

password_authREADME.md1 match

@thebigmacmurray•Updated 6 days ago
15```
16
17If you want to use an [api token](https://www.val.town/settings/api) to authenticate:
18
19```ts

sqliteExplorerAppREADME.md1 match

@thebigmacmurray•Updated 6 days ago
13## Authentication
14
15Login to your SQLite Explorer with [password authentication](https://www.val.town/v/pomdtr/password_auth) with your [Val Town API Token](https://www.val.town/settings/api) as the password.
16
17## Todos / Plans

sqliteExplorerAppmain.tsx2 matches

@thebigmacmurray•Updated 6 days ago
27 <head>
28 <title>SQLite Explorer</title>
29 <link rel="preconnect" href="https://fonts.googleapis.com" />
30
31 <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
32 <link
33 href="https://fonts.googleapis.com/css2?family=Fira+Code:wght@300..700&family=Source+Sans+3:ital,wght@0,200..900;1,200..900&display=swap"
34 rel="stylesheet"
35 />

find_first_reserve_codemain.tsx7 matches

@giroramos•Updated 6 days ago
6const BASE_URL = "https://amanda.reservame.cl/r/?e=";
7const TARGET_PHRASE = "inscripción a reserva de"; // ¡en minúsculas!
8const WEBHOOK_URL = "https://hooks.zapier.com/hooks/catch/22027915/2cqwxr6/";
9
10const BATCH_DEFAULT = 400; // nÂş de cĂłdigos por llamada
56
57/* ------------------------------------------------------------------ *
58 * 3. ENVĂŤO A ZAPIER *
59 * ------------------------------------------------------------------ */
60async function sendToZapierWebhook(payload: unknown) {
61 try {
62 const res = await fetch(WEBHOOK_URL, {
66 });
67 if (!res.ok) {
68 console.error("Zapier webhook response not OK:", await res.text());
69 }
70 } catch (err) {
71 console.error("Error sending to Zapier webhook:", err);
72 }
73}
102 }
103
104 // Preparar payload para Zapier
105 const payload = {
106 timestamp: new Date().toISOString(),
111 : { status: "not_found" },
112 };
113 await sendToZapierWebhook(payload);
114
115 /* ------------------------------------------ *

scratchk8s-alerts.tsx6 matches

@maxm•Updated 6 days ago
18 path: "deployment";
19 type: string;
20 apiObj: {
21 kind: "Deployment";
22 };
24 path: "pod";
25 type: string;
26 apiObj: {
27 kind: "Pod";
28 status: {
66) {
67 if (payload.path === "pod") {
68 const containerStatus = payload.apiObj.status.containerStatuses?.at(0);
69 if (
70 payload.path === "pod" &&
71 payload.apiObj.metadata.deletionTimestamp === undefined &&
72 (containerStatus && "terminated" in containerStatus.state &&
73 containerStatus.state.terminated.exitCode !== 0)
75 await email({
76 subject: `Container terminated`,
77 text: `${payload.apiObj.metadata.labels["commit-hash"]} ${
78 JSON.stringify(payload.apiObj.status, null, 2)
79 }`,
80 });

Sonarneynar.ts4 matches

@moe•Updated 6 days ago
1const NEYNAR_API_KEY = Deno.env.get('NEYNAR_API_KEY') || 'NEYNAR_API_DOCS'
2const headers = {
3 'Content-Type': 'application/json',
4 'x-api-key': NEYNAR_API_KEY,
5}
6
7export const fetchNeynarGet = async (path: string) => {
8 return await fetch('https://api.neynar.com/v2/farcaster/' + path, {
9 method: 'GET',
10 headers: headers,
13
14export const fetchNeynarPost = async (path: string, body: any) => {
15 return await fetch('https://api.neynar.com/v2/farcaster/' + path, {
16 method: 'POST',
17 headers: headers,

sqlite_adminREADME.md1 match

@shriharip•Updated 6 days ago
9To use it on your own Val Town SQLite database, [fork it](https://www.val.town/v/stevekrouse/sqlite_admin/fork) to your account.
10
11It uses [basic authentication](https://www.val.town/v/pomdtr/basicAuth) with your [Val Town API Token](https://www.val.town/settings/api) as the password (leave the username field blank).
12
13Migrated from folder: utils/sqlite_admin/sqlite_admin

offlinemain.tsx2 matches

@cashlessman•Updated 6 days ago
13
14 const data = await response.json();
15 console.log("API Response:", data);
16 } catch (error) {
17 console.error("Error fetching API:", error);
18 }
19}

custom-domains-val-api

@nbbaier•Updated 4 hours ago

custom-domains-val-api

@stevekrouse•Updated 6 hours ago
fiberplane
Purveyors of Hono tooling, API Playground enthusiasts, and creators of 🪿 HONC 🪿 (https://honc.dev)
api