Skip to main content

POST /storedCredentials

Use this method to create a stored credential.

Important
Lenovo XClarity Administrator does not validate the user name and password that you specify for the stored credential. It is your responsibility to ensure that specified information corresponds to an active user account on the local device or LDAP server (if the managed device is configured to use Microsoft Active Directory or OpenLDAP for authentication).

Authentication

Authentication with username and password is required.

Request URL

POST https://{management_server_IP}/storedCredentials

Query parameters

None

Request body

AttributesRequired / OptionalTypeDescription
descriptionOptionalStringDescription of the stored-credential account
Tip
Use this attribute to differentiate between accounts when users and stored credentials have the same name.
passwordRequiredStringPassword for the stored-credential account
userNameRequiredStringName of the stored-credential account

You must specify a user name for management, OS-management, and local user accounts. For other stored credential type, the user name is optional.

The following example creates a stored credential.
{
"description": "CME44",
"password: "passwr0d"
"userName": "USERID"
}

Response codes

CodeDescriptionComments
200OKThe request completed successfully.
400Bad RequestA query parameter or request attribute is missing or not valid, or the operation is not supported. A descriptive error message is returned in the response body.
404Not foundA specified resource cannot be found. A descriptive error message is returned in the response body.
409ConflictThere is a conflict with the current state of the resource. A descriptive error message is returned in the response body.
500Internal Server ErrorAn internal error occurred. A descriptive error message is returned in the response body.

Response body

AttributesTypeDescription
idStringThe stored credential ID.
The following example is returned if the request is successful.
{
"id":"605"
}