5 const { default: axios } = await import("npm:axios");
6 const url =
7 "https://sapphire.api.microsoftapp.net/config/api/v1/get?setmkt=en-us&setplatform=android&setchannel=production&settenant=sapphire-bing";
8 try {
9 const response = await fetch(url, {
5sending an email each time. I'm using this to send this information
6to an RSVP sheet. */
7export let weddingAPI = (guest, yesno, count, additional, email) => {
8 const gsheet_append_example = gsheet_call(
9 process.env.google_service_account, // This is the file you download from the service account in Google. Just paste it in.
1import { myApi as myApi2 } from "https://esm.town/v/parweb/myApi";
2
3export function myApi(name) {
4 return myApi2("chris");
5}
2
3// Send a pushover message.
4// token, user, and other opts are as specified at https://pushover.net/api
5export async function pushover({ token, user, message, title, url, ...opts }) {
6 return await fetch("https://api.pushover.net/1/messages.json", {
7 method: "POST",
8 body: JSON.stringify({
1export function myApi(name) {
2 return "hello " + name + " 🎉";
3}
1export function myApi(name) {
2 return "hi " + name;
3}
3// GitHub repos
4export let githubRepos = fetchJSON(
5 "https://api.github.com/users/stevekrouse/repos"
6);
3export let getSeattleSubwayTweets = async (request: Request): Promise<Response> => {
4 let data = await fetch(
5 `https://api.apify.com/v2/acts/quacker~twitter-url-scraper/runs/last/dataset/items?token=apify_api_wi6mnWH8aJ5yiwv3ePmYV7BI31yTE13ameye`,
6 );
7 let jsonData = await data.json();
1export function myApi(name) {
2 return "hi " + name;
3}
17 // stars for user
18 if (!repo) {
19 stars = await fetch(`https://api.github.com/users/${user}/repos`)
20 .then((r) => r.json())
21 .then((d) =>
26 else {
27 const res = await fetch(
28 `https://api.github.com/search/repositories?q=${user}/${repo}`,
29 );
30 const data = await res.json();