Forums OroCRM OroCRM – Installation/Technical Issues or Problems Create user via api fails on null password field

This topic contains 2 replies, has 2 voices, and was last updated by  Vova Soroka 1 year, 2 months ago.

  • Creator
  • #24777


    Trying to create user via api, I have hit this roadblock.

    The error stems from the password field. Not having the password field in the attributes array throws this exception:

    When called with password in attribute array, we get this tidbit:

    I have tried the passwordPlain attribute, inspired by RestUsersTest::testCreateUser(), but this also throws the ‘extra field’ error.

    It seems the field cannot be null, yet the api constraint disallows the password attribute.

    Is there a workaround for this?

    The request payload I send is as follow:



    Dream, in a pragmatic way.
    — Aldous Huxley

Viewing 2 replies - 1 through 2 (of 2 total)
  • Author
  • #24778


    I have resolved this by implementing a listener on doctrine. On account creation if account is not active and password is null, we add a dummy password so account creation can be processed.

    Dream, in a pragmatic way.
    — Aldous Huxley


    Vova Soroka

    Hello @stef,

    Unfortunately there is a bug in API for creation of User entity in the currently released version of the platform.
    We have already fixed it in the master branch and the fix will be released in the platform 2.0.

    Thank you for the feedback.

Viewing 2 replies - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.