export async function main(url: string, body: object) {
let resp = await fetch(url, {
method: "PUT",
headers: {
"Content-Type": "application/json",
},
body,
});
return { "response": await resp.text() }
}
Submitted by rossmccrann 871 days ago
export async function main() {
const body = `{"name": "Deno"}`;
let resp = await fetch("https://example.com", {
method: "PUT",
headers: {
"Content-Type": "application/json",
},
body,
});
return { "response": await resp.text() }
}
Submitted by rossmccrann 898 days ago