Join the conversation

Sign in to join this conversation, and others like it, in the communities you care about.

Wekan

Wekan is an open-source kanban board (Trello like) which allows a card-based task and to-do management.

Wekan / General

Is there a way to create user with oauth2 authentication via API?

Is there a way to create user with oauth2 authentication via API?

Wekan/General · March 10, 2020 at 8:26am

Is there a way to create user with oauth2 authentication via API?

Wekan / General · March 10, 2020 at 8:26am

I need to create users via API so they can be assigned tasks before they ever log into Wekan, but we're using oauth2 authentication (Keycloak). API methods here (https://github.com/wekan/wekan/wiki/REST-API) require password, but i can't provide it.

Load previous messages

March 10, 2020 at 5:26pm

Authentication method is at Users collection/table: https://github.com/wekan/wekan/blob/master/models/users.js#L277 so you can make it editable like with REST API parameter like action here, similar for authenticationMethod https://github.com/wekan/wekan/blob/master/models/users.js#L1216 and similarly when adding a new user, by adding parameter of authenticationMethod https://github.com/wekan/wekan/blob/master/models/users.js#L1397 as pull request.

    • reply
    • like

    March 11, 2020 at 6:56am

    @xet7 thanks for the info! If I call /api/users/id - i can see there are a lot of data associated with the user like password.bcrypt, email.verificationTokens, oidc. If i just pass authenticationMethod: oauth2 - will Wekan be able to figure out all these parameters later, or i have to provide them in some way?

      • reply
      • like

      March 11, 2020 at 9:11am

      @nidu I would quess that it requires adding code for authenticationMethod

        • reply
        • like

        @nidu Sure you could test, I don't know does it work

          • reply
          • like