Spaces:
Running
Running
File size: 400 Bytes
9e27976 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 |
import { Hono } from "hono"
import { getCopilotUsage } from "~/services/github/get-copilot-usage"
export const usageRoute = new Hono()
usageRoute.get("/", async (c) => {
try {
const usage = await getCopilotUsage()
return c.json(usage)
} catch (error) {
console.error("Error fetching Copilot usage:", error)
return c.json({ error: "Failed to fetch Copilot usage" }, 500)
}
})
|