MAPI Manual

NAME

UPDATE_USER

FUNCTION

Update an existing user within an organisation

SYNOPSIS

DESCRIPTION

This function updates an existing user within an organisation. A user of any role can update his/her own profile. Admin users are allowed to update Manager users within the same organisation. Account managers can update all Admin users.

Required Parameters

* action: UPDATE_USER.
* mcp_user_id: user ID. This value is the primary key and cannot be updated.
* first_name: firstname of the user.
* middle_name: middle name.
* last_name: lastname of the user.
* is_active: status of the user account. "1" means active; "0" otherwise.

* role: user role. Values are "manager", "admin" and "accountmanager".

* org_id: organisation ID. This value cannot be updated.

* access_control: specifies the access rights. Value is "1".
* access_apps_control: controls the access rights to the apps. Value is "MCPTYPE_ALL".
* mcp_language_id: language ID. To get the list of supported languages, see LIST_LANGUAGES.

* mcp_location_id: location ID. To get the list of countries, see LIST_LOCATIONS.

* tz_abbr: the time zone abbreviation. To get the list of time zones, see LIST_TIMEZONES.

* fax_number: fax number.
* mobile: mobile number.
* org_department: department of the organisation.
* org_position: position in the organisation.

RETURN DATA

The response contains the following attribute:
* msg: a string indicating the user has been updated successfully.

ROLE PERMITTED

Manager, Admin, Account Manager

EXAMPLES

The following example shows a successful HTTP GET request and response.

Request:

http://app02.yvntech.com/MapIHttpS/MapIS?action=UPDATE_USER&mcp_user_id=1001000&first_name=stephen&last_name=smith&is_active=1&role=manager&org_id=9000&access_control=1&access_apps_control=MCPTYPE_ALL&mcp_language_id=1&mcp_location_id=61&mobile=%2B61422222222&tz_abbr=TZ89&login_name=Admin@example.com&login_passwd=1111

Response:

<result tftype='1' infotype='0'>
    <field name='msg'>SUCCESS</field>
</result>


TIPS

ENVIRONMENT

AUTHOR

YVN Tech

SEE ALSO

ADD_USER, GET_USER_INFO

Mweb v2.0 YVNTECH 2014