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%22Image%20title%22?q=api&page=924&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 14776 results for "api"(1687ms)

cerebras_coderREADME.md2 matches

@Danap•Updated 4 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`

preciseScarletHerringmain.tsx5 matches

@stevekrouse•Updated 4 months ago
88 // Keep these comments so we remember not to change this
89 const client = new OpenAI({
90 apiKey: Deno.env.get("CEREBRAS_API_KEY"),
91 baseURL: "https://api.cerebras.ai/v1",
92 });
93
101 return Response.json({ message: generatedMessage });
102 } catch (error) {
103 console.error("Error calling Cerebras API:", error);
104
105 if (error.status === 429) {
106 return Response.json({ error: "Cerebras API rate limit reached. Please try again later." }, { status: 429 });
107 } else {
108 return Response.json({ error: `API Error: ${error.message}` }, { status: 500 });
109 }
110 }

preciseScarletHerringREADME.md6 matches

@stevekrouse•Updated 4 months ago
22
231. Sign up for [Cerebras](https://cloud.cerebras.ai/)
242. Get a Cerebras API Key
253. Save it in a [Val Town environment variable](https://www.val.town/settings/environment-variables) called `CEREBRAS_API_KEY`
26
27Once Cerebras is set up in your Val Town account, there are two ways to get started:
37const { OpenAI } = await import("https://esm.sh/openai");
38const client = new OpenAI({
39 apiKey: "YOUR_CEREBRAS_API_KEY",
40 baseURL: "https://api.cerebras.ai/v1"
41});
42const response = await client.chat.completions.create({
54## Sample apps
55
56* **[Cerebras Searcher](https://www.val.town/v/stevekrouse/cerebras_searcher)** - a Perplexity clone that uses the SerpAPI to do RAG
57and summaries with Cerebras (*requires a SerpAPI key*)
58* **[Cerebras Coder](https://www.val.town/v/stevekrouse/cerebras_coder)** - an app that
59generates websites in a second with Cerebras

r1README.md1 match

@sboesen•Updated 4 months ago
141. Copy this Val and save it as an Email Val (choose Val type in top-right corner of editor)
15
162. Add your Fireworks (or openai API compatible) API key to line 8 (or use an environment variable: https://docs.val.town/reference/environment-variables/)
17
183. Copy the email address of the Val (click 3 dots in top-right > Copy > Copy email address)

cerebrasTemplatemain.tsx5 matches

@stevekrouse•Updated 4 months ago
88 // Keep these comments so we remember not to change this
89 const client = new OpenAI({
90 apiKey: Deno.env.get("CEREBRAS_API_KEY"),
91 baseURL: "https://api.cerebras.ai/v1",
92 });
93
101 return Response.json({ message: generatedMessage });
102 } catch (error) {
103 console.error("Error calling Cerebras API:", error);
104
105 if (error.status === 429) {
106 return Response.json({ error: "Cerebras API rate limit reached. Please try again later." }, { status: 429 });
107 } else {
108 return Response.json({ error: `API Error: ${error.message}` }, { status: 500 });
109 }
110 }

victoriousGreenLynxmain.tsx2 matches

@stevekrouse•Updated 4 months ago
109 return Response.json({ message: generatedMessage });
110 } catch (error) {
111 console.error("Error calling OpenAI API:", error);
112
113 if (error.status === 429) {
143
144const css = `
145@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@400;700&display=swap');
146
147body {

victoriousGreenLynxREADME.md4 matches

@stevekrouse•Updated 4 months ago
31const { OpenAI } = await import("https://esm.sh/openai");
32const client = new OpenAI({
33 apiKey: "YOUR_CEREBRAS_API_KEY",
34 baseURL: "https://api.cerebras.ai/v1"
35});
36const response = await client.chat.completions.create({
48## Sample apps
49
50* **[Cerebras Searcher](https://www.val.town/v/stevekrouse/cerebras_searcher)** - a Perplexity clone that uses the SerpAPI to do RAG
51and summaries with Cerebras (*requires a SerpAPI key*)
52* **[Cerebras Coder](https://www.val.town/v/stevekrouse/cerebras_coder)** - an app that
53generates websites in a second with Cerebras

masterfulPeachHookwormmain.tsx5 matches

@stevekrouse•Updated 4 months ago
85 const { OpenAI } = await import("https://esm.sh/openai");
86 const client = new OpenAI({
87 apiKey: Deno.env.get("CEREBRAS_API_KEY"),
88 baseURL: "https://api.cerebras.ai/v1",
89 });
90
99 return Response.json({ message: generatedMessage });
100 } catch (error) {
101 console.error("Error calling Cerebras API:", error);
102
103 if (error.status === 429) {
104 return Response.json({ error: "Cerebras API rate limit reached. Please try again later." }, { status: 429 });
105 } else {
106 return Response.json({ error: `API Error: ${error.message}` }, { status: 500 });
107 }
108 }

masterfulPeachHookwormREADME.md4 matches

@stevekrouse•Updated 4 months ago
31const { OpenAI } = await import("https://esm.sh/openai");
32const client = new OpenAI({
33 apiKey: "YOUR_CEREBRAS_API_KEY",
34 baseURL: "https://api.cerebras.ai/v1"
35});
36const response = await client.chat.completions.create({
48## Sample apps
49
50* **[Cerebras Searcher](https://www.val.town/v/stevekrouse/cerebras_searcher)** - a Perplexity clone that uses the SerpAPI to do RAG
51and summaries with Cerebras (*requires a SerpAPI key*)
52* **[Cerebras Coder](https://www.val.town/v/stevekrouse/cerebras_coder)** - an app that
53generates websites in a second with Cerebras

knowledgeableTomatoCrawdadREADME.md4 matches

@stevekrouse•Updated 4 months ago
31const { OpenAI } = await import("https://esm.sh/openai");
32const client = new OpenAI({
33 apiKey: "YOUR_CEREBRAS_API_KEY",
34 baseURL: "https://api.cerebras.ai/v1"
35});
36const response = await client.chat.completions.create({
48## Sample apps
49
50* **[Cerebras Searcher](https://www.val.town/v/stevekrouse/cerebras_searcher)** - a Perplexity clone that uses the SerpAPI to do RAG
51and summaries with Cerebras (*requires a SerpAPI key*)
52* **[Cerebras Coder](https://www.val.town/v/stevekrouse/cerebras_coder)** - an app that
53generates websites in a second with Cerebras

book-lookup-notion6 file matches

@nucky•Updated 11 hours ago
use google book api to look up bibliographic metadata elements

openai_api_project_Pauline2 file matches

@Paulineseemann•Updated 11 hours ago
rapilot330
Kapil01