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/?q=api&page=639&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 12044 results for "api"(1450ms)

OpenTownieREADME.md3 matches

@shouserUpdated 3 months ago
10## Getting Started
11
121. Create a [Val Town API token](https://www.val.town/settings/api) with Val read and write permissions
132. Paste the token into the input box and get started
14
15## Forking the Project
16
17You'll need to get an **Open Router API key**.
18We choose Open Router so we could easily switch between
19all models. We soon want to make it so you can choose your
20model from a dropdown, but we're having trouble formatting the api calls such that they work on all providers. Maybe we need to switch to the vercel sdk

surprisingEmbeddingsindex1 match

@tmcwUpdated 3 months ago
7// Create login schema with email and password
8const inputSchema = v.pipe(v.array(v.pipe(v.string(), v.minLength(1), v.maxLength(32))), v.minLength(1), v.maxLength())
9const client = new VoyageAIClient({ apiKey: Deno.env.get("VOYAGE_API_TOKEN") })
10
11let working = false

cerebras_coderREADME.md2 matches

@manyoneUpdated 3 months ago
6
71. Sign up for [Cerebras](https://cloud.cerebras.ai/)
82. Get a Cerebras API Key
93. Save it in a [Val Town environment variable](https://www.val.town/settings/environment-variables) called `CEREBRAS_API_KEY`

cerebras_codermain.tsx5 matches

@manyoneUpdated 3 months ago
212 } catch (error) {
213 Toastify({
214 text: "We may have hit our Cerebras Usage limits. Try again later or fork this and use your own API key.",
215 position: "center",
216 duration: 3000,
1024 };
1025 } else {
1026 const client = new Cerebras({ apiKey: Deno.env.get("CEREBRAS_API_KEY") });
1027 const completion = await client.chat.completions.create({
1028 messages: [
1149 <meta name="viewport" content="width=device-width, initial-scale=1.0">
1150 <title>CerebrasCoder</title>
1151 <link rel="preconnect" href="https://fonts.googleapis.com" />
1152 <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
1153 <link
1154 href="https://fonts.googleapis.com/css2?family=DM+Mono:ital,wght@0,300;0,400;0,500;1,300;1,400;1,500&family=DM+Sans:ital,opsz,wght@0,9..40,100..1000;1,9..40,100..1000&display=swap"
1155 rel="stylesheet"
1156 />
1165 <meta property="og:description" content="Turn your ideas into fully functional apps in less than a second – powered by Llama3.3-70b on Cerebras's super-fast wafer chips. Code is 100% open-source, hosted on Val Town."">
1166 <meta property="og:type" content="website">
1167 <meta property="og:image" content="https://stevekrouse-blob_admin.web.val.run/api/public/CerebrasCoderOG.jpg">
1168
1169

OpenTowniegenerateCode2 matches

@shouserUpdated 3 months ago
29
30 const openai = new OpenAI({
31 baseURL: "https://openrouter.ai/api/v1",
32 apiKey: Deno.env.get("OPEN_ROUTER_KEY"),
33 });
34 console.log(messages);

OpenTowniesystem_prompt.txt2 matches

@shouserUpdated 3 months ago
26 * DO NOT use the alert(), prompt(), or confirm() methods.
27
28 * If the user's app needs weather data, use open-meteo unless otherwise specified because it doesn't require any API keys.
29
30 * Tastefully add a view source link back to the user's val if there's a natural spot for it. Generate the val source url via `import.meta.url.replace("esm.town", "val.town")`. This link element should include a target="_top" attribute.
38 Val Town's client-side catch script automatically catches client-side errors to aid in debugging.
39
40 * Don't use any environment variables unless strictly necessary. For example use APIs that don't require a key.
41 If you need environment variables use `Deno.env.get('keyname')`
42

gemini_coderREADME.md2 matches

@SagarsahUpdated 3 months ago
6
71. Sign up for [Cerebras](https://cloud.cerebras.ai/)
82. Get a Cerebras API Key
93. Save it in a [Val Town environment variable](https://www.val.town/settings/environment-variables) called `CEREBRAS_API_KEY`
10
11# Todos

gemini_codermain.tsx3 matches

@SagarsahUpdated 3 months ago
211 } catch (error) {
212 Toastify({
213 text: "We may have hit our usage limits. Try again later or fork this and use your own API key.",
214 position: "center",
215 duration: 3000,
1093 <meta name="viewport" content="width=device-width, initial-scale=1.0">
1094 <title>Gemini Coder</title>
1095 <link rel="preconnect" href="https://fonts.googleapis.com" />
1096 <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
1097 <link
1098 href="https://fonts.googleapis.com/css2?family=DM+Mono:ital,wght@0,300;0,400;0,500;1,300;1,400;1,500&family=DM+Sans:ital,opsz,wght@0,9..40,100..1000;1,9..40,100..1000&display=swap"
1099 rel="stylesheet"
1100 />

surprisingEmbeddingsembeddingGetter1 match

@tmcwUpdated 3 months ago
4// Create login schema with email and password
5const inputSchema = v.pipe(v.array(v.pipe(v.string(), v.minLength(1), v.maxLength(32))), v.maxLength(4))
6const client = new VoyageAIClient({ apiKey: Deno.env.get("VOYAGE_API_TOKEN") })
7
8let working = false

generateBackendSchemamain.tsx1 match

@toowiredUpdated 3 months ago
51 });
52 } catch (error) {
53 console.error("Error calling OpenAI API:", error);
54 return new Response("Error generating schema. Please try again later.", { status: 500, headers });
55 }

social_data_api_project3 file matches

@tsuchi_yaUpdated 22 hours ago

simple-scrabble-api1 file match

@bryUpdated 4 days ago
papimark21
socialdata
Affordable & reliable alternative to Twitter API: ➡️ Access user profiles, tweets, followers & timeline data in real-time ➡️ Monitor profiles with nearly instant alerts for new tweets, follows & profile updates ➡️ Simple integration