MENU
    Mapping Users to User Groups
    • 1 Minute to read
    • Dark
    • PDF

    Mapping Users to User Groups

    • Dark
    • PDF

    Article summary

    Administrators need the ability to continually manage / update user groups. The MapToUserGroup call automatically updates user group mapping information.

    Format of API String

    bool MapToUserGroup(string userLogin, string userGroupCode,bool mapUser, string loginName, string password, string tenantCode)
    Shell

    Data That Needs to be Supplied to the API

    • userLogin (user ID) – in string format

    • userGroupCode – existing user group code in string format

    • mapUser – Boolean value – “False” unmaps the user to the user group and “True” maps the user to the user group

    • loginName, password and tenantCode – user credentials to authenticate the API connection

    Sample Calls

    (”klakshmi@planful.com”,”TestUserGroup”,true,”planfuluser@gmail.com”,”planfulusertest”,”QATenant”) → This call adds ‘klakshmi@planful.com’ to UserGroup ‘TestUSerGroup’.
    Shell
    (”klakshmi@planful.com”,”TestUserGroup”,false,”planfuluser@gmail.com”,”planfulusertest”,”QATenant”) → This call deletes ‘klakshmi@planful.com’ from UserGroup ‘TestUserGroup’ if they are already added to that group
    Shell
    <MapToUserGroupResult>
    	<Code>22</Code>
    	<Success>false</Success>
    	<message>Invalid user group code.</message>
    </MapToUserGroupResult>
    Shell
    <MapToUserGroupResult>
    	<Success>true</Success>
    	<message>User updated in user group successfully</message>
    </MapToUserGroupResult>
    Shell

    Invalid Cases

    • userLogin does not exist in Planful

    • userGroup code does not exist i in Planful


    Was this article helpful?