compactBlushGrasshoppermain.tsx4 matches
8dataHash: string | null;
9}
10interface APIResponse {
11name: string | null;
12image: string | null;
131}));
132133const apiResponse: APIResponse[] = [];
134for (const item of prosrcrcp) {
135console.log(item);
137switch (item.data.substring(0, 8)) {
138case "/rcp/":
139apiResponse.push({
140name: title,
141image: item.metadata.image,
147}
148}
149return apiResponse;
150}
151export default tmdbScrape;
197<title>Yeh To Hoga Gameshow</title>
198<meta name="viewport" content="width=device-width, initial-scale=1">
199<link href="https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@400;700&display=swap" rel="stylesheet">
200<style>${css}</style>
201</head>
twitterAlertREADME.md5 matches
14and the `excludes` for what you don't want to get notified for.
1516You 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!
1718## 2. Notification
22## Twitter Data & Limitations
2324The Twitter API has become unusable. This val gets Twitter data via [SocialData](https://socialdata.tools),
25an affordable Twitter scraping API. In order to make this val easy for
26you to fork & use without signing up for another API, I am proxying
27SocialData via @stevekrouse/socialDataProxy. Val Town Pro users can call this proxy
28100 times per day, so be sure not to set this cron to run more than once every 15 min.
2930If you want to run it more, get your own [SocialData](https://socialdata.tools)
31API token and pay for it directly.
remasterbackendmain.tsx2 matches
46extractedURL: "",
47accessHeaders: {
48Referer: `https://rapidplayers.com/e/${id}`,
49},
50fromCache: false,
53storyboard: [],
54};
55const baseUrl = "https://rapidplayers.com";
56const embed = await Fetcher(`${baseUrl}/e/${id}`, baseUrl);
57const pr = /p}\('(.*?)',(\d+),(\d+),'(.*?)'\.split/gm;
primewireUtilsmain.tsx2 matches
3import { getLinks } from "https://esm.town/v/tempdev/blue";
4import {
5primewireApiKey,
6primewireBase,
7} from "https://raw.githubusercontent.com/Ciarands/mw-providers/dev/src/providers/sources/primewire/common.ts";
89async function search(imdbId: string) {
10const searchResult = await fetch(`${primewireBase}/api/v1/show?key=${primewireApiKey}&imdb_id=${imdbId}`);
11return await searchResult.json().then((searchResult) => {
12return searchResult.id;
sqliteExplorerAppREADME.md1 match
13## Authentication
1415Login 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.
1617## Todos / Plans
sqliteExplorerAppmain.tsx2 matches
27<head>
28<title>SQLite Explorer</title>
29<link rel="preconnect" href="https://fonts.googleapis.com" />
3031<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
32<link
33href="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"
34rel="stylesheet"
35/>
weatherBasedActivityAlertingmain.tsx5 matches
10const precipitationUnit = Deno.env.get("WEATHER_PRECIPITATION_UNIT") || "inch";
11const timezone = Deno.env.get("WEATHER_TIMEZONE") || "America/Los_Angeles";
12// Activity weather criteria definitions using Open-Meteo API daily weather keys
13// All daily weather keys listed at https://open-meteo.com/en/docs
14const activities = {
51const metrics = extractUniqueMetrics(activities);
5253// Construct API URL with dynamic metrics
54const forecastUrl = new URL("https://api.open-meteo.com/v1/forecast");
55forecastUrl.searchParams.set("latitude", latitude.toString());
56forecastUrl.searchParams.set("longitude", longitude.toString());
6566if (!forecastResponse.ok) {
67throw new Error(`Weather API request failed: ${forecastResponse.statusText}`);
68}
6973metrics.forEach(metric => {
74if (!forecast.daily[metric]) {
75throw new Error(`Requested metric ${metric} not found in API response`);
76}
77});
blob_adminmain.tsx25 matches
73const menuRef = useRef(null);
74const isPublic = blob.key.startsWith("__public/");
75const publicUrl = isPublic ? `${window.location.origin}/api/public/${encodeURIComponent(blob.key.slice(9))}` : null;
7677useEffect(() => {
237setLoading(true);
238try {
239const response = await fetch(`/api/blobs?prefix=${encodeKey(searchPrefix)}&limit=${limit}`);
240const data = await response.json();
241setBlobs(data);
264setBlobContentLoading(true);
265try {
266const response = await fetch(`/api/blob?key=${encodeKey(clickedBlob.key)}`);
267const content = await response.text();
268setSelectedBlob({ ...clickedBlob, key: decodeKey(clickedBlob.key) });
278const handleSave = async () => {
279try {
280await fetch(`/api/blob?key=${encodeKey(selectedBlob.key)}`, {
281method: "PUT",
282body: editContent,
290const handleDelete = async (key) => {
291try {
292await fetch(`/api/blob?key=${encodeKey(key)}`, { method: "DELETE" });
293setBlobs(blobs.filter(b => b.key !== key));
294if (selectedBlob && selectedBlob.key === key) {
307const key = `${searchPrefix}${file.name}`;
308formData.append("key", encodeKey(key));
309await fetch("/api/blob", { method: "POST", body: formData });
310const newBlob = { key, size: file.size, lastModified: new Date().toISOString() };
311setBlobs([newBlob, ...blobs]);
329try {
330const fullKey = `${searchPrefix}${key}`;
331await fetch(`/api/blob?key=${encodeKey(fullKey)}`, {
332method: "PUT",
333body: "",
344const handleDownload = async (key) => {
345try {
346const response = await fetch(`/api/blob?key=${encodeKey(key)}`);
347const blob = await response.blob();
348const url = window.URL.createObjectURL(blob);
363if (newKey && newKey !== oldKey) {
364try {
365const response = await fetch(`/api/blob?key=${encodeKey(oldKey)}`);
366const content = await response.blob();
367await fetch(`/api/blob?key=${encodeKey(newKey)}`, {
368method: "PUT",
369body: content,
370});
371await fetch(`/api/blob?key=${encodeKey(oldKey)}`, { method: "DELETE" });
372setBlobs(blobs.map(b => b.key === oldKey ? { ...b, key: newKey } : b));
373if (selectedBlob && selectedBlob.key === oldKey) {
383const newKey = `__public/${key}`;
384try {
385const response = await fetch(`/api/blob?key=${encodeKey(key)}`);
386const content = await response.blob();
387await fetch(`/api/blob?key=${encodeKey(newKey)}`, {
388method: "PUT",
389body: content,
390});
391await fetch(`/api/blob?key=${encodeKey(key)}`, { method: "DELETE" });
392setBlobs(blobs.map(b => b.key === key ? { ...b, key: newKey } : b));
393if (selectedBlob && selectedBlob.key === key) {
402const newKey = key.slice(9); // Remove "__public/" prefix
403try {
404const response = await fetch(`/api/blob?key=${encodeKey(key)}`);
405const content = await response.blob();
406await fetch(`/api/blob?key=${encodeKey(newKey)}`, {
407method: "PUT",
408body: content,
409});
410await fetch(`/api/blob?key=${encodeKey(key)}`, { method: "DELETE" });
411setBlobs(blobs.map(b => b.key === key ? { ...b, key: newKey } : b));
412if (selectedBlob && selectedBlob.key === key) {
557onClick={() =>
558copyToClipboard(
559`${window.location.origin}/api/public/${encodeURIComponent(selectedBlob.key.slice(9))}`,
560)}
561className="text-blue-400 hover:text-blue-300 text-sm"
580>
581<img
582src={`/api/blob?key=${encodeKey(selectedBlob.key)}`}
583alt="Blob content"
584className="max-w-full h-auto"
660661// Public route without authentication
662app.get("/api/public/:id", async (c) => {
663const key = `__public/${c.req.param("id")}`;
664const { blob } = await import("https://esm.town/v/std/blob");
766};
767768app.get("/api/blobs", checkAuth, async (c) => {
769const prefix = c.req.query("prefix") || "";
770const limit = parseInt(c.req.query("limit") || "20", 10);
775});
776777app.get("/api/blob", checkAuth, async (c) => {
778const key = c.req.query("key");
779if (!key) return c.text("Missing key parameter", 400);
783});
784785app.put("/api/blob", checkAuth, async (c) => {
786const key = c.req.query("key");
787if (!key) return c.text("Missing key parameter", 400);
792});
793794app.delete("/api/blob", checkAuth, async (c) => {
795const key = c.req.query("key");
796if (!key) return c.text("Missing key parameter", 400);
800});
801802app.post("/api/blob", checkAuth, async (c) => {
803const { file, key } = await c.req.parseBody();
804if (!file || !key) return c.text("Missing file or key", 400);
valTownInspoListmain.tsx1 match
101"title": "Save HTML Form Data",
102"description":
103"Submit forms to Val Town using the Express API. <a href=\"https://docs.val.town/guides/save-html-form-data/\">Read full guide</a>.",
104"val": "@vtdocs.renderFormAndSaveData",
105image: