requestReturnMachines reference

The requestReturnMachines script raises an asynchronous request to return hosts to the cloud provider.

Calling convention

Linux®:
requestReturnMachines.sh -f input.json
Windows:
requestReturnMachines.bat -f input.json

Input

(Required) A JSON file in the following format:
{
  "machines":
      {"name": "(mandatory)(string) Host name of the machine that must be returned"}
}
For example:
{
  "machines":
      {"name": "hostskFVtVRMki"}
}
Find a sample requestReturnMachines at:
  • Linux: $EGO_TOP/hostfactory/1.2/samples/providers/custom/scripts/requestReturnMachines.sh.
  • Windows: Installation_top\hostfactory\1.2\samples\providers\custom\scripts\requestReturnMachines.bat.

Output

A JSON file in the following format:
{
  "message": "(optional)(string) Any additional message the caller should know", 
  "requestId": "(mandatory)(string) Unique ID to identify this request in the cloud provider"
}
For example:
{
  "message" : "Delete VM success.",
  "requestId" : "53ef32da-f4e0-424c-be56-5946922bb2cf"
}