We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 0043eef commit 3261af4Copy full SHA for 3261af4
definitions/vite-supadata-runner/worker/userRoutes.ts
@@ -36,21 +36,10 @@ export function userRoutes(app: Hono<{ Bindings: any }>) {
36
app.post('/api/supadata/transcript', async (c) => {
37
let apiKey = ''
38
let e = {} as any
39
- const cookie = c.req.header('Cookie')
40
- try {
41
- // GET API KEY BY THIS METHOD. DO NOT GET API KEY FROM ENV.
42
- apiKey = await getUserAPIKey(c);
43
- } catch(e: any) {
44
- return c.json({
45
- success: false,
46
- cookie,
47
- error: e.message
48
- }, { status: 501 });
49
- }
50
try {
51
e = await c.req.json();
52
53
-
+ apiKey = await getUserAPIKey(c);
54
// Initialize the client
55
const supadata = new Supadata({
56
apiKey,
0 commit comments