All Questions

Tagged with
Filter by
Sorted by
Tagged with
6 votes
2 answers
3k views

Use Supabase with deno

I'm trying to use Supabase with deno. I used import { createClient } from "https://esm.sh/@supabase/supabase-js" but it only gives me errors like Module '"deno:///missing_dependency.d....
Programmer Developement's user avatar
6 votes
1 answer
2k views

Deno / Postgres "invalid peer certificate contents: invalid peer certificate" error

I'm using deno db to connect to a supabase postgres server. Here's the error from deno deploy. TLS connection failed with message: invalid peer certificate contents: invalid peer certificate: ...
ThomasReggi's user avatar
  • 57.4k
4 votes
1 answer
3k views

Error when trying to call a supabase edge function

I am trying to call a supabase edge function in javascript but I am getting this error: access to fetch at 'https:/blablala.functions.supabase.co/hello-world' from origin 'http://localhost:5173' has ...
Sebastian Trygg's user avatar
4 votes
1 answer
248 views

Deno Deploy --cert flag

How can I add --cert flag when my project run on deno deploy? I am using deno fresh and supabase postgres. When in local environment I use --cert flag to set certificate, but in deno deploy I didn't ...
Bilal Bera's user avatar
3 votes
2 answers
2k views

Deno import_map.json for supabase

I try to work with supabase edge functions in a Deno environment in IntelliJ Ultimate. The corresponding plugin is already installed but inside my supabase folder the functions I wanna create do not ...
Markus G.'s user avatar
  • 1,678
2 votes
1 answer
214 views

How to get width / height of a base64 image in deno?

This is a repeat of this question: Get image width and height from the Base64 code in JavaScript but I am asking with regards to deno. Deno does not have the new Image() that is used in all the ...
Alita's user avatar
  • 690
2 votes
1 answer
2k views

What are the Supabase Edge Functions Memory Limits

I created a Supabase Deno Edge Function that works perfectly well inside the Supabase Docker environment on my Mac, but whenever I execute it in production / the cloud I run into this error after a ...
Maximilian Lindsey's user avatar
2 votes
2 answers
499 views

GetStream with Supabase via Edge Function -- how to?

I need to write a Supabase Edge Function that interacts with GetStream. But as Supabase Edge Functions are running via Deno, I am importing the package via JS Deliver as follows: import { StreamChat } ...
boeledi's user avatar
  • 7,247
1 vote
1 answer
126 views

Is it possible to use the web-push library for node-js in a deno supabase edge function?

I tried to use/import the web-push library (https://github.com/web-push-libs/web-push) for node-js in a deno supabase edge function and it does not work. Is it possible to use the mentioned library ...
tobias hassebrock's user avatar
1 vote
1 answer
862 views

Supabase Edge Functions not recognizing import map passed in `npx supabase functions serve`

I have two edge functions namely create-payment-link and retrieve-payment-link but the import map they're using is /home/deno/flag_import_map.json, and not the import_map.json file in the functions ...
neil_ruaro's user avatar
1 vote
1 answer
1k views

Using Prisma Client with Supabase Edge Functions

I am trying to use the generated @prisma/client together with Supabase Edge functions. When running npx prisma generate the default location would be in my node_modules folder, which is a problem ...
Aaron3219's user avatar
  • 2,168
0 votes
1 answer
608 views

Can't deploy Supabase Edge Function (Stripe) - Relative import path "http" not prefixed with / or ./ or ../

I am trying to connect to Stripe through Supabase's Edge Functions, but I keep getting this error: Relative import path "http" not prefixed with / or ./ or ../ I've been digging and it ...
MIPB's user avatar
  • 2,159
0 votes
1 answer
397 views

What is a "unexpected EOF during chunk size line" error in Deno?

I'm developing an Edge Function from Supabase locally. It runs on Deno. When I execute the code below, the following error appears: CPU time limit reached. isolate: 16597602940236451129 CPU time used: ...
Leo Holanda's user avatar
0 votes
1 answer
253 views

Plaid client axios "export error" in Supabase Deno edge function

I'm attempting to implement Plaid using Supabase edge functions, which use Deno. The library is imported using an import map from https://esm.sh/[email protected]. The client instance is created ...
pete's user avatar
  • 2,789
0 votes
1 answer
316 views

Working in monorepo with React Client and deno in vscode

I am new to Supabase and deno Have anyone worked with supabase in mono-repo? My client is react and edge functions is deno. Enabling deno plugin, makes VScode not complete import statements, command-...
Alwaysblue's user avatar
  • 11.1k
0 votes
1 answer
27 views

Error Inserting into Supabase: Type of 'await' operand must either be a valid promise or must not contain a callable 'then' member

I'm getting this error Type of 'await' operand must either be a valid promise or must not contain a callable 'then' member.deno-ts(1320) In my Subapase Edge Function whose code is as follows: import {...
John Solly's user avatar
0 votes
2 answers
122 views

AWS tries to read config from file system

I'm trying to send an email using AWS SES from a Supabase cloud function. I've set up the AWS env variables, but it still tries to read the config from filesystem, which fails 'cause there's no ...
Inquisitor's user avatar
0 votes
1 answer
162 views

How to generate simple jwt using secret key for supabase

I'd like to generate a short lived service_role jwt key using the jwt secret, but I'm having trouble finding a simple example of this being done. here's my current code: import { getEnvOrExplode } ...
Alita's user avatar
  • 690
0 votes
1 answer
93 views

Database operations and changes not working in Supabase Edge Functions

Any database operation I perform inside an edge function is not working as expected. For example, if I insert a record, it will not persist to the database or if I select, it returns 0 records. I don'...
Ahmad Raza's user avatar
0 votes
0 answers
213 views

supabase edge function using only js not ts

I am trying to write a supabase edge function with deno. But I can see that when I run this command. create edge function npx supabase functions new FUNCTION-NAME It creates a function file called ...
Lonare's user avatar
  • 4,287
0 votes
1 answer
193 views

What is the url for AWS SDK v3 for esm?

Hi I am coding a supabase edge function. What I am trying to do is send email with AWS SES service. In order to do that I need to import AWS SDK v3 into the edge function. Now as we know supabase edge ...
Lonare's user avatar
  • 4,287
0 votes
1 answer
648 views

How to use JS client to pass formData to Supabase Edge function

I'm trying to call a Supabase edge function using the JS/TS client and pass audio from the client to the server. In doing this, I'm using formData on the client and trying to pass it in the body. Here'...
Brady Dowling's user avatar
0 votes
0 answers
281 views

How can i include a package that is in a node built in modules (Crypto) in a supabase edge function that use Deno

I am having problems when I deploy the function to supabase, locally the package works correctly using the node specifiers import * as crypton from "node:crypto" when i deploy Im getting ...
rivrez's user avatar
  • 1
0 votes
1 answer
138 views

Typescript complains of type only when variable is imported

I'm running a simple HTTP server, via Deno, on Supabase hosting. When I move the routes definition in external files, TypeScript kicks in and starts to complain about argument types. Note: I am not ...
Kamafeather's user avatar
  • 9,271
0 votes
0 answers
344 views

Unable to send PDF file from Supabase Edge Functions

serve(async (req) => {. const pdfDoc = await createPdf(); return new Response(pdfDoc, { headers: {. ...corsHeaders, "content-type": "...
Len's user avatar
  • 142
0 votes
1 answer
620 views

CORs error when calling a deployed edge function in supabase from the browser

I have an edge function deployed with the following code: import { serve } from "server" import * as cryptojs from "crypto-js"; import { config } from "dotenv"; // Load ...
neil_ruaro's user avatar
0 votes
1 answer
3k views

File upload works in Thunder Client and Chrome, but not Dio or MultipartRequest

I'm trying to create a flutter app that will allow a user to upload an image and a brief description of said image, and if I test my server code with either Thunder Client or Chrome, it works great, ...
foahchon's user avatar
-1 votes
1 answer
141 views

Supabase Edge Function Can't Send Email

I'm trying to send and email using SmtpClient from deno, and configuring it using gmail app password. strange thing is when i serve the function locally emails get sent but once deployed i get the ...
Kalagala Kapunda's user avatar
-1 votes
1 answer
154 views

How to send back multiple partial responses for an HTTP Post request?

I am implementing a Supabase Edge function, which runs on Deno runtime, and uses the Oak framework. During the processing of my HTTP POST request, I want to send back partial responses to the client. ...
sanket patel's user avatar