https://supabase.com/ logo
Join Discord
Powered by
# help
  • m

    Mihai Andrei

    08/10/2021, 7:56 PM
    With any jwt library like passport
  • m

    Mihai Andrei

    08/10/2021, 7:56 PM
    You just need the secret key from@supabase Dashboard
  • b

    Breci

    08/10/2021, 7:57 PM
    It would be using gotrue too?
  • m

    Mihai Andrei

    08/10/2021, 7:57 PM
    Can you explain a bit ehat is your usecase
  • m

    Mihai Andrei

    08/10/2021, 7:57 PM
    So, you have another custom server?
  • m

    Mihai Andrei

    08/10/2021, 7:58 PM
    And you eant to generate the token there and send to frontend?
  • b

    Breci

    08/10/2021, 8:01 PM
    So I make Twitch extensions. Twitch extension front-end are hosted by Twitch and displayed in iframes When they load they provide a JWT token to the user that can be validated using a secret key, this JWT contains the userId. So the idea is to call an endpoint with this JWT token. The endpoint validates the token with the secret Twitch provided, if it's valid it either create the user in supabase (without an email), or return a supabase token created using supabase secret Then the front-end can auth to supabase and use it
  • m

    Mihai Andrei

    08/10/2021, 8:02 PM
    Got it
  • m

    Mihai Andrei

    08/10/2021, 8:03 PM
    Im not sure you can create it without the email
  • m

    Mihai Andrei

    08/10/2021, 8:03 PM
    Thats the tricky part
  • m

    Mihai Andrei

    08/10/2021, 8:08 PM
    I dont know a way. Maybe someone else knows if this is possible
  • m

    Mihai Andrei

    08/10/2021, 8:08 PM
    You can for sure generate the tokens yourself
  • m

    Mihai Andrei

    08/10/2021, 8:08 PM
    Eith jwt and supabase secret
  • m

    Mihai Andrei

    08/10/2021, 8:08 PM
    But i dont think you can add the user
  • m

    Mihai Andrei

    08/10/2021, 8:08 PM
    Without email
  • b

    Breci

    08/10/2021, 8:09 PM
    Ho I see 🙂 firestore allow
    anonymous
    auth, so that's what I used but I'll look around or submit fetaure requests 😄
  • t

    tiredbear

    08/10/2021, 9:23 PM
    Supabase keeps throwing a 500 error when I try to change the primary key column's data type.
    s
    • 2
    • 3
  • t

    tiredbear

    08/10/2021, 9:24 PM
    Anyone experience this?
  • k

    Khan W

    08/10/2021, 9:41 PM
    I'm based in the Central time zone in the US. Which one of these should I create my supabase project in?
    s
    • 2
    • 2
  • k

    Khan W

    08/10/2021, 9:41 PM
    Is Canada the okay region to go with here? Idk how that might work with most of my requests coming from the US
  • t

    tiredbear

    08/10/2021, 9:43 PM
    I get a toast that shows up in the UI that says,
  • f

    fenix

    08/10/2021, 9:49 PM
    Is it possible to make supabase use
    https
    instead of
    http
    on docker?
    s
    • 2
    • 5
  • s

    ShaneTheKing

    08/10/2021, 9:54 PM
    zones
  • s

    swiss

    08/10/2021, 10:51 PM
    @User @User Thanks for the help! I'll give that a shot 🙂
  • u

    user

    08/10/2021, 11:42 PM
    hey! Apologies if this isn't an appropriate channel. What's the best resource to learn postgres? I already know SQL but would like to learn about migrations, best practices for table design, migrations, etc 🙂
  • s

    swiss

    08/11/2021, 12:20 AM
    Should supabase be used to make graphql api's? I'm wondering how my Next app should work, right now I use supabase inside api routes to do queries/mutations, but fetching it on the client with SWR is a little unintuitive imo. Wondering what's the best way to update data on the client side with supabase, maybe I just drop in supabase and skip SWR altogether?
  • d

    donpuerto

    08/11/2021, 1:24 AM
    How to insert data to multiple tables? Hi Im trying to add ID to the related tables, since I have multiple tables, I need to insert/upsert into multiple tables. I don't know if this is the right pattern. Let me know ie user has one to one relationship profile user has one to many relationship to address
  • s

    Scott P

    08/11/2021, 1:29 AM
    Using a Postgres trigger (https://www.postgresqltutorial.com/postgresql-triggers/) might work. For example, when you insert data to 1 table, the trigger will run and insert data on another table. Alternatively, a Postgres function (https://www.postgresqltutorial.com/postgresql-create-function/) could be used. You'd then call the function with the
    .rpc()
    method, passing the function name and parameters.
  • d

    donpuerto

    08/11/2021, 1:31 AM
    @User How to call function in runtime?
  • d

    donpuerto

    08/11/2021, 1:33 AM
    How to right function here?
1...444546...316Latest