To be able to perform any kind of operation with a workflow, you must find that workflow in the Orchestrator inventory and retrieve its definition. The definition lists the workflow input and output parameters, and contains links to the available workflow runs, the workflow presentation, and other objects.

Verify that you have imported the sample workflows package in Orchestrator. The package is included in the Orchestrator sample applications ZIP file that you can download from the Orchestrator documentation page.

1

Find the inventory item of the workflow.

If you have the full name of the workflow or a key word from the name, make a GET request at the URL of the Workflow service by applying a filter:

GET https://{vcoHost}:{port}/api/workflows?conditions=name={workflowFullName}

GET https://{vcoHost}:{port}/api/workflows?conditions=name~{keyWord}

Search for the workflow through the Catalog or the Inventory service by making a GET request at the URL that is an entry point for the workflow inventory items:

GET https://{vcoHost}:{port}/api/catalog/System/Workflow/

GET https://{vcoHost}:{port}/api/inventory/System/Workflows/
2

Retrieve the inventory item of the workflow by making a GET request at its URL:

GET https://{vcoHost}:{port}/api/catalog/System/Workflow/{workflowID}/
3

Retrieve the definition of the workflow by making a GET request at the URL of the definition:

GET https://{vcoHost}:{port}/api/workflows/{workflowID}/

You can find the Send Hello workflow and retrieve its definition:

1

To find the Send Hello workflow, make a GET request at the URL of the Workflow service by applying a filter:

GET https://localhost:8281/api/workflows?conditions=name~Hello

You receive a list of the workflows that contain Hello in their names:

<xml version="1.0" encoding="UTF-8" standalone="yes">
<inventory-items xmlns="http://www.vmware.com/vco" total="2">
   <link rel="down"
      href="https://localhost:8281/api/catalog/System/Workflow/CF808080808080808080808080808080E6808080013086668236014a0614d16e1/">
       <attributes>
          <attribute name="id" value="CF808080808080808080808080808080E6808080013086668236014a0614d16e1"/>
          <attribute name="canExecute" value="true" />
          <attribute name="description" value="" />
          <attribute name="name" value="Interactive Hello World" />
          <attribute name="type" value="Workflow"/>
          <attribute name="canEdit" value="true"/>
      </attributes>
    </link>
    <link rel="down"
      href="https://localhost:8281/api/catalog/System/Workflow/CF808080808080808080808080808080DA808080013086668236014a0614d16e1/">
      <attributes>
          <attribute name="id" value="CF808080808080808080808080808080DA808080013086668236014a0614d16e1"/>
          <attribute name="canExecute" value="true" />
          <attribute name="description" value="" />
          <attribute name="name" value="Send Hello" />
          <attribute name="type" value="Workflow"/>
          <attribute name="canEdit" value="true"/>
      </attributes>
   </link>
</inventory-items>
2

Make a GET request at the URL of the inventory item of the Send Hello workflow:

GET https://localhost:8281/api/catalog/System/Workflow/CF808080808080808080808080808080DA808080013086668236014a0614d16e1/

You receive the inventory item of the Send Hello workflow in the response body:

<xml version="1.0" encoding="UTF-8" standalone="yes">
<inventory-item xmlns="http://www.vmware.com/vco"
   href="https://localhost:8281/api/catalog/System/Workflow/CF808080808080808080808080808080DA808080013086668236014a0614d16e1/">
   <relations>
      <link rel="down"
       href="https://localhost:8281/api/workflows/CF808080808080808080808080808080DA808080013086668236014a0614d16e1/" />
	  </relations>
   <attributes>
      <attribute name="id" value="CF808080808080808080808080808080DA808080013086668236014a0614d16e1"/>
      <attribute name="canExecute" value="true" />
      <attribute name="description" value="" />
      <attribute name="name" value="Send Hello" />
      <attribute name="type" value="Workflow"/>
      <attribute name="canEdit" value="true"/>
   </attributes>
</inventory-item>
3

To retrieve the workflow's definition make a GET request at its URL:

GET https://localhost:8281/api/workflows/CF808080808080808080808080808080DA808080013086668236014a0614d16e1/

You receive the definition of the Send Hello workflow in the response body:

<xml version="1.0" encoding="UTF-8" standalone="yes">
<workflow xmlns="http://www.vmware.com/vco" customized-icon="false"
   href="https://localhost:8281/api/workflows/CF808080808080808080808080808080DA808080013086668236014a0614d16e1/">
   <relations>
      <link rel="up"
         href="https://localhost:8281/api/inventory/System/Workflows/Samples/HelloWorld/" />
        <link rel="add"
            href="https://localhost:8281/api/workflows/CF808080808080808080808080808080DA808080013086668236014a0614d16e1/executions/" />
        <link rel="down"
            href="https://localhost:8281/api/workflows/CF808080808080808080808080808080DA808080013086668236014a0614d16e1/executions/" />
        <link rel="down"
            href="https://localhost:8281/api/workflows/CF808080808080808080808080808080DA808080013086668236014a0614d16e1/presentation/" />
        <link rel="down"
            href="https://localhost:8281/api/workflows/CF808080808080808080808080808080DA808080013086668236014a0614d16e1/tasks/" />
        <link rel="down"
            href="https://localhost:8281/api/workflows/CF808080808080808080808080808080DA808080013086668236014a0614d16e1/icon/" />
   </relations>
   <input-parameters>
      <parameter name="name" type="string" />
   </input-parameters>
   <output-parameters>
      <parameter name="message" type="string" />
   </output-parameters>
   <name>Send Hello</name>
	  <description></description>
</workflow>