dto-btn / ssc-assistant

Second iteration of the SSC chatbot/assistant
MIT License
0 stars 0 forks source link

Create API scopes and configuration for the backend (OIDC) #104

Open GuillaumeTurcotte opened 1 month ago

GuillaumeTurcotte commented 1 month ago

We are now leveraging OpenID for the frontend and want to also leverage it for the backend (and future connections with other systems i.e; Archibus..)

The semi temp solution that decodes and verify the id token of the logged in user to store the oid and sub props from the jwt token in the database when logging messages/conversation.

We now should aim to:

  1. properly setup/modifiy an app registrsation with proper API scopes for our API
  2. remove the API dual validation of flask_httpauth to migrate from reading from two headers down to just the Authorization Bearer token.
  3. frontend would have the user request for a access token that would contain the proper scope(s) for the API
  4. setup necessary TF configuration for dev domain (along with everything so far) so we can replicate on "prod'