getBlockFeesmain.tsx1 match
23export default async function(req: Request): Promise<Response> {
4const blockFeesResp = await fetch("https://mempool.space/api/v1/mining/blocks/fees/3y");
5const blockFees = await blockFeesResp.json();
6
getHashratemain.tsx1 match
23export const handler = async () => {
4const resp = await fetch("https://mempool.space/api/v1/mining/hashrate/3y");
5const { difficulty, hashrates } = await resp.json();
6
traced_http_valmain.tsx1 match
4traced_handler,
5} from "https://esm.town/v/saolsen/tracing?v=126";
6import { trace } from "npm:@opentelemetry/api";
78init("traced_http_val");
45I've been using `saolsen.val-name`.
6Note that there is no auth for the plausible events API, so if somebody forks the val it'll still work but
7track all their val page loads in your dashboard which is kinda weird but also kinda cool, idk.
8
testFetchCommentsValmain.tsx15 matches
6export const testFetchCommentsVal = async () => {
7const urls = [
8"https://www.readtangle.com/members/api/comments/?post_id=0%3A6",
9"https://www.readtangle.com/members/api/comments/?post_id=0%3A6",
10"https://www.readtangle.com/members/api/comments/?post_id=0%3A6",
11"https://www.readtangle.com/members/api/comments/?post_id=0%3A6",
12"https://www.readtangle.com/members/api/comments/?post_id=0%3A6",
13"https://www.readtangle.com/members/api/comments/?post_id=0%3A6",
14"https://www.readtangle.com/members/api/comments/?post_id=0%3A6",
15"https://www.readtangle.com/members/api/comments/?post_id=0%3A6",
16"https://www.readtangle.com/members/api/comments/?post_id=0%3A6",
17"https://www.readtangle.com/members/api/comments/?post_id=0%3A6",
18"https://www.readtangle.com/members/api/comments/?post_id=0%3A6",
19"https://www.readtangle.com/members/api/comments/?post_id=0%3A6",
20"https://www.readtangle.com/members/api/comments/?post_id=0%3A6",
21"https://www.readtangle.com/members/api/comments/?post_id=0%3A6",
22"https://www.readtangle.com/members/api/comments/?post_id=0%3A6",
23]; // Await the resolution of the promise from testUrlConstructionVal
24await fetchComments(urls); // Now urls is an array, so it can be passed to fetchComments
27}
2829const gist = await fetchJSON(`https://api.github.com/gists/${id}`);
30if (gist.owner.login != author) {
31return new Response("Unauthorized", {
1let { userCount } = await import("https://esm.town/v/chrisk_7777/userCount");
23export function myApi(name) {
4if (!userCount) {
5userCount = [];
connect4_mcts_agentmain.tsx1 match
1import { init, traced_handler } from "https://esm.town/v/saolsen/tracing?v=109";
2import { trace } from "npm:@opentelemetry/api";
3init("connect4_mcts_agent");
4const tracer = trace.getTracer("connect4_mcts_agent");
zohoDeskApimain.tsx1 match
28): Promise<{ data: Ticket[] }> => {
29const responseDesk = await axios.get(
30`https://desk.zoho.com/api/v1/tickets`,
31{
32params: {
twitterWrappermain.tsx2 matches
1314let url = new URL(req.url);
15console.log("https://api.twitter.com" + url.pathname + url.search);
16return Response.json(
17await twitterJSON({
18url: "https://api.twitter.com/" + url.pathname + url.search,
19bearerToken: Deno.env.get("twitter"),
20}),