const db = await Deno.openKv();db.listenQueue(async (msg) => { const data = msg as { channel: string; text: string }; console.log("=== QUEUE MESSAGE === ", data); await db.set(["test-queues", data.channel], data.text); console.log("saved to kv ==== ",await db.get(["test-queues", data.channel]));});app.get('/test', async(c) => { try { const env = await load(); // const db = await Deno.openKv(); // db.listenQueue(async(msg) => { // const data = msg as { channel: string; text: string }; // console.log("=== QUEUE MESSAGE === ",data); // await db.set(["test-queues", data.channel], data.text); // }); await db.enqueue({ channel: "C123456", text: "Slack message" }, { delay: 0, }); return c.json({ env, }) } catch (error) { return c.text("error with queues === "+error.message, 401); }})