Skip to main content

POST /aicc/service/sftp/locks

Use this method to start (enable) the SFTP service for a specific function and acquire an SFTP service lock by creating a lock ID.

Note
  • You must be a member of a user group to which the predefined Supervisor role is assigned.
  • This REST API requires Lenovo XClarity Administrator v4.1.0 or later.

Authentication

Authentication with username and password is required.

Request URL

POST https://{management_server_IP}/aicc/service/sftp/locks

Query parameters

None

Request body

AttributesRequired / OptionalTypeDescription
componentRequiredStringPredefined Lenovo XClarity Administrator component ID. This can be one of the following values.
  • CN. Console
  • CP. Server configuration patterns
  • CR. Virtual appliance
  • DI. Discovery and Inventory
  • DM. Data management
  • DS. Debug Shell
  • EM. Events and monitoring
  • FC. Operating-system deployment
  • JM. Jobs management
  • MF. Metric data collection and forwarders
  • MI. Data migration
  • NM. Network management
  • RC. Remote Control
  • SE. Security
  • SP. Switch ports
  • SS. Service and support
  • ST. Storage management
  • TS. ThinkServer and Thinksystem management
  • UP. Updates
  • UI. User Interface
expirationTimeOutRequiredIntegerAmount of time, in seconds, after which the lock expires

When the lock expires, the lock ID is deleted and if there are no other locks, the SFTP service is stopped (disabled).

The following example starts the SFTP service for the updates function and deletes the lock ID after 20 minutes.
{
"component": "UP",
"expirationTimeOut": 1200
}

Response codes

CodeDescriptionComments
201CreatedOne or more new resources were successfully created.
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.
401UnauthorizedThe user cannot be authenticated. Authentication has not been provided or has failed. A descriptive error message is returned in the response body.
403ForbiddenThe orchestrator server was prevented from fulfilling the request. A descriptive error message is returned in the response body. Ensure that you have privileges to perform the request.

For XClarity Administrator advanced functions, ensure that you have active licenses for each managed server that supports the advanced functions.

500Internal Server ErrorAn internal error occurred. A descriptive error message is returned in the response body.

Response header

If the SFTP service is successfully locked, the lock ID is returned in the location field in response header, for example:

location:/aicc/service/sftp/locks/FE3L4N5L6N9D8FVLSDLS0S223JSNLSE3

Response body

AttributesTypeDescription
messagesArray of objectsInformation about one or more messages
 idStringMessage identifier of a returned message
 textStringMessage text associated with the message identifier
 explanationStringAdditional information to clarify the reason for the message
 recoveryArray of objectsRecovery information
  textStringUser actions that can be taken to recover from the event
  URLStringLink to the help system for more information, if available
The following example is returned if the request is successful.
{
"result": "success",
"messages": [{
"id": "FQXHMSE0001I",
"explanation": "",
"text": "The request completed successfully.",
"recovery": {
"text": "Information only. No action is required.",
"URL": ""
}
}]
}