POST /virtual_machines/:virtual_machine_id/reset_password 

Resets/replace password for specified VS

Sections:

Request Parameters

virtual_machine_id * - id of the VS, for which you want to reset password.

initial_root_password - the new root password for a VS. It can consist of 6-32 characters, letters [A-Za-z], digits [0-9], dash [ - ] and lower dash [ _ ]. You can use both lowercase and uppercase letters.

The following characters are not allowed for Windows-based virtual servers:

  • percent sign [%]
  • double quotation marks [“]
  • brackets [<,>]
  • vertical bar [|]
  • caret [^]
  • ampersand [&]
  • parentheses [(,)]

initial_root_password_encryption_key - specify the password encryption passphrase.

Response

Returns modified Virtual Machine.

JSON Request example

 curl -i -X POST -u user:userpass --url <api_url>/virtual_machines/:virtual_machine_id/reset_password.json -d '{"virtual_machine":{"initial_root_password":"qwaszx123", "initial_root_password_encryption_key":"property"}}' -H 'Accept:application/json' -H 'Content-type:application/json'

XML Request example

 curl -i -X POST -u user:userpass --url <api_url>/virtual_machines/:virtual_machine_id/reset_password.xml -d '<virtual_machine><initial_root_password>qwaszx321</initial_root_password><initial_root_password_encryption_key>property321</initial_root_password_encryption_key></virtual_machine>' -H 'Accept:application/xml' -H 'Content-type:application/xml'