--- title: "API: updateRole" slug: "api-updaterole" updated: 2022-08-30T20:05:28Z published: 2022-08-30T20:05:28Z canonical: "support.smarteru.com/api-updaterole" --- > ## Documentation Index > Fetch the complete documentation index at: https://support.smarteru.com/llms.txt > Use this file to discover all available pages before exploring further. # API: updateRole - SmarterU requires all API calls to POST to HTTPS. Any POST to HTTP will result in the SU:01 error (i.e., No POST data detected.). - If you are viewing the help in a language other than English, please change your language to English before copying and pasting any code. All API attributes and functions are in English. - Tags are required unless specified. ## **Description** [Learning Plans](https://support.smarteru.com/docs/learning-plans) were previously referred to as *roles*.  The updateRole method [edits a learning plan](/v1/docs/editing-a-learning-plan). ## **Who Has Access** The following users have access to the updateRole method: - Users with the [Manage Learning Plans, Certifications, and Requirements](/v1/docs/account-permission-manage-learning-plans-certifications-and-requirements) account permission. - [Administrators and owners](/v1/docs/user-profile-information#access-level). ## **API Call XML Package** ```markup updateRole - OR - ``` ## Role Tag Group The Role tag group is a container for the learning plan's details. ```markup - OR - ``` The Role tag may contain the following. The Identifier tag contains the information for the learning plan you want to update. The remaining tags in the Role tag group specify the updates to the learning plan.  ### **Identifier** The identifier of the learning plan you want to update. This tag contains the following. | Tag | Description | | --- | --- | | **Name** | The [learning plan's name](/v1/docs/learning-plan-main#name). This tag is mutually exclusive with the RoleID tag. | | **RoleID** | The [learning plan's user-specified identifier](/v1/docs/learning-plan-main#learning-plan-id). This tag is mutually exclusive with the Name tag. This is the RoleID returned by the [listRoles](/v1/docs/api-listroles) method. | ### **Name** (optional) The [learning plan's name](/v1/docs/learning-plan-main#name). ### **RoleID** (optional) The [learning plan's user-specified identifier](/v1/docs/learning-plan-main#learning-plan-id). ### **Status** (optional) The [learning plan's status](/v1/docs/learning-plan-main#status). Acceptable values are *Active* or *Inactive*. ### **Description** (optional) The [learning plan's description](/v1/docs/learning-plan-main#description). ### **Certifications** (optional) A container for [assigning certifications to or removing certifications from the learning plan](/v1/docs/assigning-certifications-to-a-learning-plan). Refer to [Certifications Tag Group](/v1/docs/api-updaterole#certifications-tag-group-optional). ## **Certifications Tag Group (Optional)** The Certifications tag group is a container for [assigning certifications](/v1/docs/assigning-certifications-to-a-learning-plan) to or removing certifications from the learning plan. ```markup ``` Each certification is contained in a Certification tag and contains the following. ### CertificationName The [certification's name](/v1/docs/certification-main#name). ### MandateLevel The certification's mandate level. Acceptable values are: - *Mandatory* - The certification is required for the learning plan. - *Recommended* - The certification is not required, but recommended for the learning plan. - *Optional* - The certification is optional for the learning plan. ### CertificationAction Indicates the action you are taking on the learning plan's certification. Acceptable values are: - *Add* - You're adding the certification to the learning plan, or updating a certification that was previously added to the learning plan. - *Remove* - You're removing the certification from the learning plan. ## API Response XML Package The [API response XML package](/v1/docs/api-response-xml-package) will always include a Result, Info, and [Errors](/v1/docs/api-updaterole#error-codes) tag. ```markup ``` The response may also contain the following. ### Role The [learning plan's name](/v1/docs/learning-plan-main#name). ### RoleID The [learning plan's user-specified identifier](/v1/docs/learning-plan-main#learning-plan-id). ### Example API Response XML Package Below is an example of an API response XML package. ```markup Success ``` ## **Error Codes** | Error Code | Message | | --- | --- | | UR:01 | The name provided is not valid. | | UR:02 | The learning plan ID provided is not valid. | | UR:03 | The status provided is not valid. | | UR:04 | The description provided is not valid. | | UR:05 | The certification name provided is not valid. | | UR:06 | The certification action provided is not valid. | | UR:07 | The mandate level provided is not valid. | | UR:08 | The required permissions are not met to call the updateRole method. | | UR:09 | The requested learning plan does not exist. | | UR:10 | The status provided is not valid. Acceptable values are *Active* or *Inactive*. | | UR:11 | One or more of the certification names provided are not valid. | | UR:12 | A certification mandate level must be provided when adding a certification to a role. | | UR:13 | One or more mandate levels provided are not valid. Acceptable values are *Mandatory*, *Optional*, or *Recommended*. | | UR:15 | The certification action provided is not valid. Acceptable values are *Add* or *Remove*. | | UR:16 | Learning plan name cannot be used. | | UR:17 | Learning plan ID cannot be used. | | UR:18 | The required permissions are not met to call the updateRole method. | ## Related - [API: createRole](/api-createrole.md) - [API: getRole](/api-getrole.md) - [API: listRoles](/api-listroles.md) - [Assigning Certifications to a Learning Plan](/assigning-certifications-to-a-learning-plan.md) - [Editing a Learning Plan](/editing-a-learning-plan.md) - [Learning Plans](/learning-plans.md)