267});
268
269export default app.fetch;
1import dayjs from "npm:dayjs";
2
3// fetch("https://portal.permit.pcta.org/availability/mexican-border.php").then(resp => console.log(resp.body));
4// import { fetchText } from "https://esm.town/v/stevekrouse/fetchText?v=6";
5// import { load } from "npm:cheerio";
6
7// const html = await fetchText(
8// "https://portal.permit.pcta.org/availability/mexican-border.php",
9// );
1import { email } from "https://esm.town/v/std/email?v=11";
2import { fetch } from "https://esm.town/v/std/fetch";
3import { OpenAI } from "npm:openai";
4
5let location = "shenzhen";
6let lang = "zh";
7const weather = await fetch(
8 `https://wttr.in/${location}?lang=${lang}&format=j1`,
9).then(r => r.json());
29
30export async function weatherGPT() {
31 const result = await fetch(`https://hello.liaolile.com/test/weather`, {
32 method: "POST",
33 body: JSON.stringify({
1export async function umdImport(url: string | URL, globals = {}) {
2 const res = await fetch(url);
3 if (!res.ok) throw new Error(await res.text());
4 let code = await res.text();
97});
98
99export default app.fetch;
1import { shortenURL } from "https://esm.town/v/vladimyr/dubShortenURL";
2import { fetchVal } from "https://esm.town/v/vladimyr/fetchVal";
3import { newValURL } from "https://esm.town/v/vladimyr/newValURL";
4
5const { code } = await fetchVal("vladimyr", "newValURL");
6const valURL = newValURL(code);
7console.log(valURL.href);
28app.post("/execute", toHonoHandler(sqliteServer.handleExecute));
29app.post("/batch", toHonoHandler(sqliteServer.handleBatch));
30export default app.fetch;
31
32export const { httpEndpoint: ENDPOINT } = extractValInfo(import.meta.url);
207});
208
209export default app.fetch;
23
24async function execute(statement: InStatement): Promise<ResultSet> {
25 const res = await fetch(`${ENDPOINT}/execute`, {
26 method: "POST",
27 body: JSON.stringify({ statement }),
34
35async function batch(statements: InStatement[]): Promise<ResultSet[]> {
36 const res = await fetch(`${ENDPOINT}/batch`, {
37 method: "POST",
38 body: JSON.stringify({ statements }),
61});
62
63export default app.fetch;
3 AspeURI,
4 calculateFingerprint,
5 fetchASP,
6 formatFingerprint,
7 getKeyId,
87 let fingerprint;
88 if ("keyId" in aspeURI) {
89 const asp = await fetchASP(aspeURI.keyId, aspeURI.hostname);
90 fingerprint = calculateFingerprint(asp);
91 } else {