JWT with guest role not working from external clients

I have been having an issue (this used to work) where Im selecting from a table using jwt with a role set to guest. As a test, I created a new black table with some data, ensured the guest role exists in SB, granted select access to the guest role to the new table, and Im able to set role and get back a row of data from the SB SQL Editor. But when I try to do this from my Next.js app or Postman (set the Auth Bearer header as the jwt, and Ive even tried to mint a new jwt), I consistently get this error:

{
"code": "42501",
"details": null,
"hint": null,
"message": "permission denied to set role "guest""
}

Postman is giving a 403

Seems SB wont allow setting the role from external clients, but it works fine from inside DB. I dont think the issue is the JWT as I used to have this working.

Any ideas much appreciated.

Thanks!
Was this page helpful?