i-am-bee / bee-api

API backend for Bee
Apache License 2.0
20 stars 8 forks source link

Ability to update user name #56

Open mmurad2 opened 1 week ago

mmurad2 commented 1 week ago

Problem description When I start the bee-stack I am greeted with "Hi Test" and there is no way to update this setting to my name.

Desired solution An easy way to configure Test to username.

xjacka commented 1 week ago

The current problem is, that the username is encoded in the JWT token. The only way how to change the username is to change the token. Can we use a better but static name? For example 'Hi beekeeper'.

mmurad2 commented 1 week ago

That could be a good interim solution but eventually there should be a way to update the username. Is there a way to document updating the JWT token for advanced users who want to host the OS UI so others can interact with it?

xjacka commented 1 week ago

Updating JWT is not possible, they need to know a private key. We can add an endpoint to edit a user name but the default will be the same.

mmurad2 commented 1 week ago

Could that endpoint be exposed in the ui or as part of the bee-stack set-up process?

matoushavlena commented 3 hours ago

I think we could allow the user name to be undefined and let the UI deal with it. With something like "Hey there, ...". Because the identity providers cannot guarantee that we actually get user's name. I know we are talking about bee-stack now, but generally this can happen and would solve both problems.