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/$%7Bart_info.art.src%7D?q=api&page=910&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 12894 results for "api"(2661ms)

socialDataUpdatemain.tsx1 match

@charmaineUpdated 7 months ago
1// This val fetches recent tweets about @SnapAR or Lens Studio, removes duplicates,
2// and displays them as embedded tweets with preview images on a dark background.
3// Updated to use Social Data instead of Twitter API
4
5import { socialDataSearch } from "https://esm.town/v/stevekrouse/socialDataSearch?v=5";

buildagencymain.tsx1 match

@elliotbraemUpdated 7 months ago
40 <title>Build Agency - NEAR Ecosystem</title>
41 <meta name="viewport" content="width=device-width, initial-scale=1">
42 <link href="https://fonts.googleapis.com/css2?family=Poppins:wght@400;700&display=swap" rel="stylesheet">
43 <style>${css}</style>
44 </head>

weekly_mortgage_ratesmain.tsx3 matches

@bleikampUpdated 7 months ago
10 percentageChange: number;
11}
12const FRED_API_KEY = process.env.FRED_API_KEY;
13
14// Function to fetch rate data from FRED API
15async function getRateData(seriesId: string): Promise<RateData> {
16 const url =
17 `https://api.stlouisfed.org/fred/series/observations?series_id=${seriesId}&api_key=${FRED_API_KEY}&file_type=json&sort_order=desc&limit=2`;
18
19 const response = await fetch(url);

smoothBluePanthermain.tsx2 matches

@stevekrouseUpdated 7 months ago
12 const updateHtml = async () => {
13 try {
14 const response = await fetch("/api/modify", {
15 method: "POST",
16 headers: { "Content-Type": "application/json" },
99
100async function server(request: Request): Promise<Response> {
101 if (request.method === "POST" && new URL(request.url).pathname === "/api/modify") {
102 const { html, silliness, slang } = await request.json();
103 const client = new Cerebras();

ThreadmarkLISTFetcher2main.tsx10 matches

@willthereaderUpdated 7 months ago
140
141async function fetchThreadmarksFromServer(url, chapterTitles) {
142 const response = await fetch("/api/threadmarks", {
143 method: "POST",
144 headers: {
154}
155
156async function getThreadmarkUrls(baseUrl, apiKey) {
157 versionLogger(import.meta.url);
158 const startTime = Date.now();
166 console.log(`[INFO] Constructing URL for category ${category}: ${threadmarkUrl}`);
167
168 const scrapingBeeUrl = `https://app.scrapingbee.com/api/v1/?api_key=${apiKey}&url=${
169 encodeURIComponent(threadmarkUrl)
170 }&render_js=false`;
171
172 const requestStartTime = Date.now();
173 const response = await fetch(scrapingBeeUrl);
174 const requestDuration = Date.now() - requestStartTime;
175
311 console.log(`Received ${request.method} request for path: ${new URL(request.url).pathname}`);
312
313 if (request.method === "POST" && new URL(request.url).pathname === "/api/threadmarks") {
314 const apiKey = Deno.env.get("ScrapingBeeAPIkey");
315 if (!apiKey) {
316 console.error("[ERROR] API key not found in environment variables");
317 return new Response(JSON.stringify({ error: "API key not found in environment variables" }), {
318 status: 500,
319 headers: { "Content-Type": "application/json" },
324 const { url, chapterTitles } = await request.json();
325 // console.log(`[INFO] Received request to fetch threadmarks for URL: ${url}`);
326 const threadmarks = await getThreadmarkUrls(url, apiKey);
327 console.log(`[INFO] Retrieved ${threadmarks.length} threadmarks`);
328

spotifyPlaylistSearchmain.tsx1 match

@trobUpdated 7 months ago
124
125 if (!response.ok) {
126 throw new Error(`iTunes API error: ${response.status}`);
127 }
128

socialDataSearchREADME.md1 match

@stevekrouseUpdated 7 months ago
1Helper function to call [SocialData](https://socialdata.tools) Twitter Search API, via my proxy: @stevekrouse/socialDataProxy
2
3Migrated from folder: social_data/socialDataSearch

effortlessCrimsonDolphinmain.tsx2 matches

@stevekrouseUpdated 7 months ago
3
4const query = "\"val.town\" OR \"val.run\" OR \"val town\" -_ValTown_ -is:retweet -from:valenzuelacity";
5const url = new URL("https://api.socialdata.tools/twitter/search");
6
7export async function twitterAlert({ lastRunAt }: Interval) {
10 url.searchParams.append("query", query + " since_time:" + since);
11 const { tweets } = await fetchJSON(url.toString(), {
12 bearer: Deno.env.get("SOCIAL_DATA_API_KEY"),
13 });
14

effortlessCrimsonDolphinREADME.md3 matches

@stevekrouseUpdated 7 months ago
5## 1. Authentication
6
7This val gets data from the https://socialdata.tools/ API.
8
9You'll need to make an account and pre-load your wallet with ~$10.
10
11Add your `SOCIAL_DATA_API_KEY` to your [Val Town Envionrment Variables](https://www.val.town/settings/environment-variables).
12
13## 2. Query
15Change the `query` variable for what you want to get notified for.
16
17You can use [Twitter's search operators](https://developer.twitter.com/en/docs/twitter-api/v1/rules-and-filtering/search-operators) to customize your query, for some collection of keywords, filtering out others, and much more!
18
19## 3. Notification

ThreadmarkLISTFetcher2README.md1 match

@willthereaderUpdated 7 months ago
1Migrated from folder: fanficSearcher/ScrapingBeeAttempt/ThreadmarkLISTFetcher2

vapi-minutes-db1 file match

@henrywilliamsUpdated 1 day ago

vapi-minutes-db2 file matches

@henrywilliamsUpdated 1 day 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