Link Auth0 user with my postgresql database

Hello everyone, thanks for start reading. I have finished my front and back configuration with Auth0, I am developing the frontend with Angular and the backend with Go (golang). So, What is wrong? nothing, I just want to know how to link my Aunth0 user with the data in my own Postgresql database. I have some thoughs about how figure it out like commit the data with the auth0 userid as foreign key but I wondering if that way is correct.

Some extra inforamtion:

  • I don’t need to edit the user data (name, email, photo, etc).
  • I just want to link the user with a table to make queries.

For example:
I want to link a user with cars that are her/his property


Thanks a lot for reading until the end.

Hi @aristotekean

Welcome to the Auth0 Community!

Thank you for posting your question. Based on your description, you are definitely on the correct path. With many to one relations between these tables storing auth0_id as a foreign key, it is a perfectly valid way to have this relationship between tables. I would recommend going with that pattern.



This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.