Skip to main content

All Questions

Tagged with
0 votes
0 answers
62 views

Next.js 14 Supabase Auth: Private Page Access Issue

I followed Supabase's Setting up Server-Side Auth for Next.js guide (https://supabase.com/docs/guides/auth/server-side/nextjs) to set up a basic Next.js application with a user authentication system. ...
Mehdi Saqlen's user avatar
1 vote
1 answer
292 views

TypeError: supabase.from is not a function

I have a Next.js application, which I am trying to integrate with Supabase. Below is the initialisation of Supabase utils/supabase/server.js 'use server' import { createServerClient } from "@...
mukunda's user avatar
  • 475
-3 votes
1 answer
422 views

GET http://localhost:3000/ 500 (Internal Server Error)

Yesterday I had to add some changes to my database table and all the data was lost, which it wasn't a problem because I'm just developing the project. The problem arises after I did that. I started to ...
Nolan's user avatar
  • 1
0 votes
0 answers
437 views

Supabase and Next.js - How to make change password page accessible only to authenticated users

I have a next.js application and I am following the documentation for allowing users to reset passwords. So far, I built the password reset page and made it publicly accessible with a form asking for ...
AbedDoesCode's user avatar
1 vote
1 answer
238 views

Next.js Adding Port 80 to redirect URL after Google Aunthetication

I'm creating a web app using Nextjs 14 with a Supabase backend. However, after successful authentication, there's port 80 being appended on my URL which causes an error to be thrown. The URL after ...
Alvin's user avatar
  • 1,211
0 votes
1 answer
104 views

How to solve Argument of type 'any[] | null' is not assignable to parameter of type 'SetStateAction<never[]>'. in nextjs 13

my project was created by Nextjs 13 based on Supabase database, am trying to fetch some data from supabase and use usestate to assign it to an variable ,, but am getting this error : Argument of type '...
Ahmed Wagdi's user avatar
  • 4,185
0 votes
0 answers
217 views

Unable to make operations in supabase when stripe webhook fires

My ultimate goal is to do the following: have user choose stripe subscription and sign up (works successfully) when the invoice.payment_succeeded event fires, I want to increment a value in the db ...
COMMAND CENTER's user avatar
0 votes
1 answer
290 views

What is the right way to do a PUT in NextJS 13.4 API? (Response, NextAPIResponse, NextResponse) using the new App Router

What is the right way to do a simple PUT in NextJS 13.4 in the new App Router? The previous way of doing delete with using NextAPIRequest, NextAPIResponse, using if (req.method === 'PUT') , pulling ...
Octo Palm Tree's user avatar
3 votes
1 answer
409 views

What is the right way to do GET (all items or by a specific ID) in NextJS 13.4? (Response, NextAPIResponse, or NextResponse) using the new App Router?

What is the right way to do a GET (either getting all items or by a specific ID) in NextJS 13.4 in the new App Router? The previous way of doing delete with using NextAPIRequest, NextAPIResponse, ...
Octo Palm Tree's user avatar
1 vote
1 answer
3k views

What is the right way to do a DELETE in NextJS 13.4 API? (Response, NextAPIResponse, NextResponse) using the new App Router

What is the right way to do a simple DELETE in NextJS 13.4 in the new App Router? The previous way of doing delete with using NextAPIRequest, NextAPIResponse, using if (req.method === 'DELETE') , ...
Octo Palm Tree's user avatar
0 votes
0 answers
169 views

Redirect issue when accessing protected routes with an active session supabase

I am currently working on a middleware function in my Next.js application that handles authentication and redirects users based on their session status in supabase. However, I am encountering an issue ...
Abdulhameed Mustapha's user avatar
0 votes
1 answer
268 views

NextJS & Supabase - Wrong redirecting in auth routes

I have my app with nextjs and supabase deployed on render.com. All works as expected in local, but in prod, supabase redirects to http://localhost:10000 after login. Actually all my auth routes after ...
Carlos del Río Francés's user avatar
0 votes
0 answers
408 views

Authentication with Supabase and NextJS - getSession returns null at first, which leads to incorrect content rendering

I'm using supabase-js v2 for authentication inside a NextJS project. On page load/reload i always see a login page (for 2 seconds before render the correct component) even if a user is logged. The ...
vmaltarello's user avatar
8 votes
1 answer
944 views

Next JS - Supabase Error: AuthApiError: Invalid Refresh Token: Already Used

I'm trying to implement Supabase Auth in a Next JS project Now I'm encounter the following error which keeps repeating when I npm run dev: [AuthApiError: Invalid Refresh Token: Already Used]{ ...
Emad Naeim's user avatar
0 votes
1 answer
261 views

Supabase Auth with the Next.js App Router tutorial throwing server error on createMiddlewareClient({req,res})

When following the Supabase Auth with the Next.js App Router tutorial, the initial development of the server throws an error My .env.local file is initialized with the correct url and key. Here is my ...
Nephter's user avatar
  • 147

15 30 50 per page