Page tree
Skip to end of metadata
Go to start of metadata

The Reservations API provides a way to execute Reservations. It is exposed by the Data Hub component, and therefore the web service is located on the BMC TrueSight Capacity Optimization Data Hub server.

RESTful API patterns

The RESTful API provides HTTP methods for search with the help of specific RESTful API URI (Uniform Resource Identifier) patterns.

HTTP method

URI pattern

Description

Required
Request
Parameters

Optional
Request
Parameters
Samples
Reservations

POST

rsv/reservations

Creates a new reservation

  • Name
  • Start date
  • Template (resourceTemplates,
    resourceSpecs, or Items)

Description 
End date 
External ID 
Owner
Priority 
Probability
Capacity Pool(s)
Realization Mode
High availability

Sample

GET
rsv/reservations/
{reservation-id}
Gets data for an existing reservationReservation ID 

Sample

PUT
rsv/reservations/
{reservation-id}
Updates an existing reservationReservation ID

Name  
Start date
Template (resourceTemplates,
resourceSpecs, or Items)
Description 
End date 
External ID
Owner
Priority 
Probability
Capacity Pool(s)
Realization Mode
High availability

Sample

DELETE
rsv/reservations/
{reservation-id}
Deletes an existing reservationReservation ID 

Sample

POST
rsv/search/
reservations
Searches for reservations that match query criteria 

Name
Status
CapacityPools
Startdate
Description
Enddate
ExternalID
Owner
Priority
Probability
Tenant

Sample

Templates
POST
rsv/systemtemplates
Creates a new system template

Name
System Type
Metric Name and Value
-Min required from
reservations
(VCPU_NUM,
REAL_MEM,DISK)

Description
Metric Name and Value

Sample
GETrsv/systemtemplates/{template-id}Gets information for system templateTemplate ID Sample
GETrsv/servicetemplates/{template-id}Gets information for service templateTemplate ID Sample
PUTrsv/systemtemplates/{template-id}Updates a system templateTemplate ID

Name
Description
Metric Name and Value

Sample
DELETErsv/systemtemplates/{template-id}Deletes a system templateTemplate ID Sample
POSTrsv/search/systemtemplatesSearches for system template(s) based on query criteria 

ID
Name 
SystemType
Lookupname
SystemType
ResourceSpec values for:
 cpuCores, cpuEntitledCapacity,
 cputTotalMHz, memTotal, storageTotal

Sample
POST
rsv/search/servicetemplates
Searches for service template(s) based on query criteria 

ID
Name

Sample
Reservation items
GETrsv/reservations/{reservation-id}/items/{item-id}Gets information for a reservation item

Reservation ID
Item ID

 Sample
PUTrsv/reservations/{reservation-id}/items/{item-id}Updates information for a reservation item

Reservation ID
Item ID

 Sample
DELETErsv/reservations/{reservation-id}/items/{item-id}Deletes a a reservation item

Reservation ID
Item ID

 Sample
Capacity Pool
GETrsv/capacitypools/{pool-id}Get data for an existing capacity poolCapacity Pool ID Sample
POSTrsv/search/capacitypoolsSearches for capacity pool's that match query criteria 

Name
Technology
Tags

Sample
Reservation Target
GETrsv/reservationTargets/{container-id}Get information for a Reservation TargetReservation Target ID Sample
POSTrsv/search/reservationTargetsSearches for Reservation Target's that match query criteria 

ID
Name
Enttypenm
CapacityPoolids

Sample
Onboarding
POSTrsv/onboardingsCreates a new onboarding

Name  
Onboarding date  
Template (resourceTemplates
or resourceSpecs)
Reservation Target OR
Capacity Pool (Onboarding on
hypothetical Reservation Target)

Description 
Offboarding date
Realization Mode

Sample
GETrsv/onboardings/{onboarding-id}Gets data for onboardingOnboarding ID Sample
PUTrsv/onboardings/{onboarding-id}Updates an existing onboarding

Onboarding ID
Name  
Onboarding date  
Template (resourceTemplates
or resourceSpecs)
Reservation Target OR
Capacity Pool (Onboarding on
hypothetical Reservation Target)

Description 
Offboarding date
Realization Mode

Sample
DELETErsv/onboardings/{onboarding-id}Deletes an existing onboardingOnboarding ID Sample
POSTrsv/search/onboardingsSearches for an existing onboarding based on query criteria 

OnboardingID
Name
Status
ReservationTarget

Sample
Offboarding
POST
rsv/offboardings
Creates a new offboarding

Name   
Offboarding date
Template (resourceTemplates
or resourceSpecs)
Reservation Target

Description
Realization Mode
Sample
GETrsv/offboardings/{offboarding-id}Get offboarding detailsOffboarding ID Sample
PUT
rsv/offboardings/{offboarding-id}
Update an existing offboarding

Offboarding ID
Name   
Offboarding date
Template (resourceTemplates
or resourceSpecs)
Reservation Target

Description
Realization Mode

Sample
DELETErsv/offboardings/{offboarding-id}Delete an existing offboardingOffboarding ID Sample
POSTrsv/search/offboardingsSearches for an existing offboarding based on query criteria 

OffboardingID
Name 
Status
ReservationTarget

Sample
Tenant
GETrsv/tenants/{tenant-id}Get tenant detailsTenant ID Sample
POSTrsv/search/tenantsSearches for tenants based on query criteria 

ID
Name
Description
Status

Sample

Sample request and response files

The following examples describe the type of searches that can be conducted using the Reservations API:

Reservations

Creating a Reservation

 Click here to view/hide the sample request file for adding a Reservation with resources...
{
    "name": "my_rsv",
    "startDate": "17/12/2014",
    "description": "Reserve resources for POC",
    "owner": "alan",
    "externalId": "co_user",
    "priority": "MEDIUM",
    "probability": 56,
    "realizationMode": "AUTOMATIC", 
	"highAvailability": "NO",
    "resources": {
        "resourceTemplates": [
            {
                "numItems": 1,
                "systemTemplateLookup": {
                    "id": "908"
                }
            },
            {
                "numItems": 1,
                "systemTemplateLookup": {
                    "name": "VMware.medium"
                }
            },
            {
                "numItems": 1,
                "serviceTemplateLookup": {
                    "id": "2222"
                }
            }
        ]
    },
    "capacityPools": [
        {
            "id": "2176"
        }
    ]
}
 Click here to view/hide the sample request file for adding a Reservation with items...
{
    "name": "my_rsv",
    "startDate": "17/12/2014",
    "description": "Reserve resources for POC",
    "owner": "alan",
    "externalId": "co_user",
    "priority": "MEDIUM",
    "probability": 56,
    "realizationMode": "AUTOMATIC",
    "items": [
        {
            "name": "DB_Server",
            "systemTemplateLookup": {
                "id": "2213"
            }
        },
        {
            "name": "Web_Server",
            "systemTemplateLookup": {
                "name": "VMware.small"
            }
        }
    ],
    "capacityPools": [
        {
            "id": "2211"
        }
    ]
}
 Click here to view/hide the sample response file for adding a Reservation with resources...
{
    "status": "OK",
    "message": "The reservation has been successfully created",
    "reservation": {
        "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/reservations/10157",
        "id": 10157,
        "name": "my_rsv",
        "startDate": "17/12/2014",
        "description": "Reserve resources for POC",
        "owner": "alan",
        "externalId": "co_user",
        "priority": "HIGH",
        "probability": 55,
        "realizationMode": "AUTOMATIC",
        "resourceRequirementSummary": {
            "vcpuNum": 4,
            "cpuTotalMHz": 9.044,
            "memTotal": 8589934592,
            "storageTotal": 51782668038
        },
        "resources": {
            "resourceTemplates": [
                {
                    "enttypenm": "gm:vmw",
                    "numItems": 1,
                    "systemTemplate": {
                        "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/systemtemplates/908",
                        "id": 908,
                        "name": "VMware.small"
                    }
                },
                {
                    "enttypenm": "gm:vmw",
                    "numItems": 1,
                    "systemTemplate": {
                        "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/systemtemplates/2217",
                        "id": 2217,
                        "name": "VMware.medium"
                    }
                },
                {
                    "enttypenm": "gm:vmw",
                    "numItems": 1,
                    "serviceTemplate": {
                        "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/servicetemplates/2222",
                        "id": 2222,
                        "name": "CMDBService"
                    }
                }
            ]
        },
        "items": [
            {
                "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/reservations/10155/items/354",
                "id": 354,
                "name": "VMware.small-0",
                "systemTemplate": {
                    "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/systemtemplates/2213",
                    "id": 2213,
                    "name": "VMware.small"
                },
                "serviceTemplate": {
                    "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/servicetemplates/2222",
                    "id": 2222,
                    "name": "CMDBService"
                }
            },
            {
                "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/reservations/10155/items/355",
                "id": 355,
                "name": "VMware.small-1",
                "systemTemplate": {
                    "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/systemtemplates/2213",
                    "id": 2213,
                    "name": "VMware.small"
                },
                "serviceTemplate": {
                    "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/servicetemplates/2222",
                    "id": 2222,
                    "name": "CMDBService"
                }
            },
            {
                "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/reservations/10157/items/356",
                "id": 356,
                "name": "VMware.small-2",
                "systemTemplate": {
                    "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/systemtemplates/908",
                    "id": 908,
                    "name": "VMware.small"
                }
            },
            {
                "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/reservations/10157/items/357",
                "id": 357,
                "name": "VMware.small-3",
                "systemTemplate": {
                    "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/systemtemplates/2217",
                    "id": 2217,
                    "name": "VMware.medium"
                }
            }
        ],
        "capacityPools": [
            {
                "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/capacitypools/2211",
                "id": 2211,
                "name": "NY capacity pool"
            }
        ]
    }
}
 Click here to view/hide the sample response file for adding a Reservation with items...
{
    "status": "OK",
    "message": "The reservation has been successfully created",
    "reservation": {
        "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/reservations/10157",
        "id": 10157,
        "name": "my_rsv",
        "startDate": "17/12/2014",
        "description": "Reserve resources for POC",
        "owner": "alan",
        "externalId": "co_user",
        "priority": "HIGH",
        "probability": 55,
        "realizationMode": "AUTOMATIC",
        "resourceRequirementSummary": {
            "vcpuNum": 4,
            "cpuTotalMHz": 9.044,
            "memTotal": 8589934592,
            "storageTotal": 51782668038
        },
        "resources": {
            "resourceTemplates": [
                {
                    "enttypenm": "gm:vmw",
                    "numItems": 1,
                    "systemTemplate": {
                        "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/systemtemplates/2213",
                        "id": 2213,
                        "name": "VMware.medium"
                    }
                },
                {
                    "enttypenm": "gm:vmw",
                    "numItems": 1,
                    "systemTemplate": {
                        "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/systemtemplates/2217",
                        "id": 2217,
                        "name": "VMware.small"
                    }
                }
            ]
        },
        "items": [
            {
                "href": " http://capacity-optimization-datahub:8280/dh-services/rsv/reservations/10157/items/367 ",
                "id": 367,
                "name": "DB_Server",
                "systemTemplate": {
                    "href": " http://capacity-optimization-datahub:8280/dh-services/rsv/systemtemplates/2213 ",
                    "id": 2213,
                    "name": "VMware.medium"
                }
            },
            {
                "href": "  http://capacity-optimization-datahub:8280/dh-services/rsv/reservations/10157/items/367  ",
                "id": 367,
                "name": "Web_Server",
                "systemTemplate": {
                    "href": "  http://capacity-optimization-datahub:8280/dh-services/rsv/systemtemplates/2217  ",
                    "id": 2217,
                    "name": "VMware.small"
                }
            }
        ],
        "capacityPools": [
            {
                "href": "  http://capacity-optimization-datahub:8280/dh-services/rsv/capacitypools/2211  ",
                "id": 2211,
                "name": "NY capacity pool"
            }
        ]
    }
}

Getting information for an existing Reservation

 Click here to view/hide the sample request file...
http://capacity-optimization-datahub:8280/dh-services/rsv/reservations/10028 
 Click here to view/hide the sample response file...
{
    "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/reservations/10155",
    "id": 10155,
    "name": "my_rsv",
    "startDate": "15/01/2015",
    "description": "Reserve resources for POC",
    "status": "PENDING",
    "owner": "alan",
    "priority": "HIGH",
    "probability": 45,
    "realizationMode": "AUTOMATIC",
    "resourceRequirementSummary": {
        "vcpuNum": 24,
        "cpuTotalMHz": 54.264,
        "memTotal": 51539607552,
        "storageTotal": 310696008228
    },
    "resources": {
        "resourceTemplates": [
            {
                "enttypenm": "svc",
                "numItems": 1,
                "serviceTemplate": {
                    "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/servicetemplates/2222",
                    "id": 2222,
                    "name": "CMDBService"
                }
            },
            {
                "enttypenm": "gm:vmw",
                "numItems": 1,
                "systemTemplate": {
                    "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/systemtemplates/695",
                    "id": 695,
                    "name": "VMware.medium"
                }
            }
        ]
    },
    "items": [
        {
            "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/reservations/10155/items/354",
            "id": 354,
            "name": "VMware.small-0",
            "systemTemplate": {
                "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/systemtemplates/2213",
                "id": 2213,
                "name": "VMware.small"
            },
            "serviceTemplate": {
                "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/servicetemplates/2222",
                "id": 2222,
                "name": "CMDBService"
            }
        },
        {
            "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/reservations/10155/items/355",
            "id": 355,
            "name": "VMware.small-1",
            "systemTemplate": {
                "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/systemtemplates/2213",
                "id": 2213,
                "name": "VMware.small"
            },
            "serviceTemplate": {
                "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/servicetemplates/2222",
                "id": 2222,
                "name": "CMDBService"
            }
        },
        {
            "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/reservations/10155/items/356",
            "id": 356,
            "name": "VMware.medium-0",
            "systemTemplate": {
                "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/systemtemplates/695",
                "id": 695,
                "name": "VMware.medium"
            }
        }
    ],
    "capacityPools": [
        {
            "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/capacitypools/2211",
            "id": 2211,
            "name": "NY capacity pool "
        }
    ]
}

Updating an existing Reservation

 Click here to view/hide the sample request file...
{
    "name": "my_rsv",
    "startDate": "17/12/2014",
    "description": "Reserve resources for POC",
    "owner": "alan",
    "externalId": "co_user",
    "priority": "MEDIUM",
    "probability": 56,
    "realizationMode": "AUTOMATIC",
    "highAvailability": "NO",
	"resources": {
        "resourceTemplates": [
            {
                "numItems": 1,
                "systemTemplateLookup": {
                    "id": "908"
                }
            }
        ]
    },
    "capacityPools": [
        {
            "id": "2176"
        }
    ]
}
 Click here to view/hide the sample response file...
{
    "status": "OK",
    "message": "The reservation has been successfully updated",
    "reservation" : {
    "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/reservations/10155",
    "id": 10155,
    "name": "my_rsv",
    "startDate": "15/01/2015",
    "description": "Reserve resources for POC",
    "status": "PENDING",
    "owner": "alan",
    "priority": "HIGH",
    "probability": 45,
    "realizationMode": "AUTOMATIC",
    "resourceRequirementSummary": {
        "vcpuNum": 24,
        "cpuTotalMHz": 54.264,
        "memTotal": 51539607552,
        "storageTotal": 310696008228
    },
    "resources": {
        "resourceTemplates": [
            {
                "enttypenm": "gm:vmw",
                "numItems": 1,
                "systemTemplate": {
                    "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/systemtemplates/908",
                    "id": 908,
                    "name": "VMware.medium"
                }
            }
        ]
    },
    "items": [
        {
            "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/reservations/10155/items/356",
            "id": 356,
            "name": "VMware.medium-0",
            "systemTemplate": {
                    "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/systemtemplates/908",
                    "id": 908,
                    "name": "VMware.medium"
                }
        }
    ],
    "capacityPools": [
        {
            "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/capacitypools/2211",
            "id": 2211,
            "name": "NY capacity pool "
        }
    ]
}
}

Deleting a Reservation

 Click here to view/hide the sample request file...
http://capacity-optimization-datahub:8280/dh-services/rsv/reservations/88
 Click here to view/hide the sample response file...
{
  "status" : "OK",
  "message" : "The reservation has been successfully deleted."
}

Searching a Reservation

 Click here to view/hide the sample request file...
{
  "filters" : [ {
    "field" : "name",
    "operator" : "EQUAL",
    "value" : "my_rsv"
  }, {
    "field" : "startDate",
    "operator" : "GREATER_THAN",
    "value" : "12/12/2014"
  }, {
    "field" : "status",
    "operator" : "IN",
    "value" : "ACCEPTED,PENDING"
  } ]
}
 Click here to view/hide the sample response file...
{
  "reservations" : [ {
    "href" : "http://capacity-optimization-datahub:8280/dh-services/rsv/reservations/10034",
    "id" : "10034",
    "name" : "rsv_34"
  }, {
    "href" : "http://capacity-optimization-datahub:8280/dh-services/rsv/reservations/10032",
    "id" : "10032",
    "name" : "my_test_rsv"
  } ]
}

Templates

Creating a new system template

 Click here to view/hide the sample request file...
{
    "name": "VMware.medium",
    "lookupName": "VMware.medium_spec5",
    "description": "VMware Virtual Machine system template (spec 5)",
    "enttypenm": "gm:vmw",
    "resourceSpec": {
        "cpuCores": 8,
        "cpuTotalMHz": 4000,
        "memTotal": 10737418240,
        "storageTotal": 42949672960,
        "os": "UNIX",
        "cpuUtilization": 0.1,
        "memUtilization": 0.9,
        "storageUtilization": 0.6
    }
}
 Click here to view/hide the sample response file...
{
    "status": "OK",
    "message": "The system template VMware.medium has been successfully created with sysid: 2395",
    "systemtemplate": {
        "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/systemtemplates/2395",
        "id": 2395,
        "name": "VMware.medium",
        "lookupName": "VMware.medium_spec5",
        "description": "VMware Virtual Machine system template (spec 5)",
        "enttypenm": "gm:vmw",
        "tags": [],
        "resourceSpec": {
            "cpuCores": 8,
            "cpuTotalMHz": 4000,
            "memTotal": 10737418240,
            "storageTotal": 42949672960,
            "os": "UNIX",
            "cpuUtilization": 0.1,
            "memUtilization": 0.9,
            "storageUtilization": 0.6
        }
    }
}

Getting information for a system template

 Click here to view/hide the sample request file...
 http://capacity-optimization-datahub:8280/dh-services/rsv/system-templates/345
 Click here to view/hide the sample response file...
 {
    "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/systemtemplates/2395",
    "id": 2395,
    "name": "VMware.medium",
    "lookupName": "VMware.medium_spec5",
    "description": "VMware Virtual Machine system template (spec 5)",
    "enttypenm": "gm:vmw",
    "tags": [
        {
            "name": "Virtualization Technology",
            "value": "VMware",
            "description": "VMware virtualization technology"
        },
        {
            "name": "OS Family",
            "value": "UNIX",
            "description": "The OS family of the system"
        }
    ],
    "resourceSpec": {
        "cpuCores": 8,
        "cpuTotalMHz": 20000,
        "memTotal": 10737418240,
        "storageTotal": 42949672960,
        "os": "UNIX",
        "cpuEntitledCapacity": 4,
        "cpuUtilization": 0.1,
        "memUtilization": 0.9,
        "storageUtilization": 0.6
    }
}

Getting information for a service template

 Click here to view/hide the sample request file...
 http://capacity-optimization-datahub:8280/dh-services/rsv/service-templates/876
 Click here to view/hide the sample response file...
 {
  "href" : "",
  "name" : "template_CapacityService",
  "lookupName" : "MyTemplateName1234", "description" : "Business Service for BCO",
  "resourceRequirementSummary" : {
    "cpuCores" : 4,
    "cpuTotalMHz" : 20000,
    "memTotal" : 2147483648,
    "storageTotal" : 64424509440
  },
  "resources" : {
    "resourceTemplates" : [ {
      "numItems" : 4,
      "systemTemplateLookup" : {
        "href" : "https://vl-pun-bco-dv21:8280/dh-services/rsv/systemtemplates/245",
        "id" : "245",
        "name" : "VMware.small"
      }
    }, {
      "numItems" : 4,
      "systemTemplateLookup" : {
        "href" : "https://vl-pun-bco-dv21:8280/dh-services/rsv/systemtemplates/445",
        "id" : "445",
        "name" : "VMware.small"
      }
    } ]
  }
}

Updating a system template

 Click here to view/hide the sample request file...
{
    "name": "VMware.medium",
    "lookupName": "VMware.medium_spec5",
    "description": "VMware Virtual Machine system template (spec 5)",
    "enttypenm": "gm:vmw",
    "resourceSpec": {
        "cpuCores": 4,
        "cpuTotalMHz": 8000,
        "memTotal": 10737418240,
        "storageTotal": 42949672960,
        "os": "UNIX",
        "cpuUtilization": 0.89,
        "memUtilization": 0.90,
        "storageUtilization": 0.75
    }
}
 Click here to view/hide the sample response file...
 {
    "status": "OK",
    "message": "The system template MyOtherTemplate[sysid:2399] has been successfully updated",
    "systemtemplate": {
        "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/systemtemplates/2395",
        "id": 2395,
        "name": "VMware.medium",
        "lookupName": "VMware.medium_spec5",
        "description": "VMware Virtual Machine system template (spec 5)",
        "enttypenm": "gm:vmw",
        "tags": [
            {
                "name": "Virtualization Technology",
                "value": "VMware",
                "description": "VMware virtualization technology"
            },
            {
                "name": "OS Family",
                "value": "UNIX",
                "description": "The OS family of the system"
            }
        ],
        "resourceSpec": {
            "cpuCores": 4,
            "cpuTotalMHz": 20000,
            "memTotal": 10737418240,
            "storageTotal": 42949672960,
            "os": "UNIX",
            "cpuEntitledCapacity": 4,
            "cpuUtilization": 0.1,
            "memUtilization": 0.9,
            "storageUtilization": 0.6
        }
    }
}

Deleting a system template

 Click here to view/hide the sample request file...
 http://capacity-optimization-datahub:8280/dh-services/rsv/system-templates/345
 Click here to view/hide the sample response file...
 {
  "status" : "OK",
  "message" : "The system template has been successfully deleted.",
}

Searching for a system template

 Click here to view/hide the sample request file...
 {
  "filters" : [ {
    "field" : "name",
    "operator" : "EQUAL",
    "value" : "sys_template"
  }, {
    "field" : "enttypenm",
    "operator" : "EQUAL",
    "value" : "gm:vmw"
  }, {
    "field": "lookupName",
    "operator": "EQUAL",
    "value" : "sys_templ_lk_1234"
  }]
}
 Click here to view/hide the sample response file...
 {
  "systemTemplates" : [ {
    "href" : "http://capacity-optimization-datahub:8280/dh-services/rsv/systemtemplates/566",
    "id" : "566",
    "name" : "template_vm-aus-bco-dv56"
  }, {
    "href" : "http://capacity-optimization-datahub:8280/dh-services/rsv/systemtemplates/78",
    "id" : "78",
    "name" : "template_vm-aus-bco-dv55"
  } ]
}

Searching for a service template

 Click here to view/hide the sample request file...
 {
    "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/servicetemplates/2221",
    "id": 2221,
    "name": "service_template",
    "resourceRequirementSummary": {
        "vcpuNum": 6,
        "cpuCores": 6,
        "cpuTotalMHz": 13642,
        "memTotal": 17179869184,
        "storageTotal": 123054081643
    },
    "systemTemplates": [
        {
            "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/systemtemplates/2214",
            "id": 2214,
            "name": "VMware.medium"
        },
        {
            "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/systemtemplates/2213",
            "id": 2213,
            "name": "VMware.small"
        }
    ]
}
 Click here to view/hide the sample response file...
 {
  "serviceTemplates" : [ {
    "href" : "http://capacity-optimization-datahub:8280/dh-services/rsv/servicetemplates/234",
    "id" : "234",
    "name" : "BCOService"
  }, {
    "href" : "http://capacity-optimization-datahub:8280/dh-services/rsv/servicetemplates/544",
    "id" : "544",
    "name" : "CLMService"
  } ]
}

Reservation items

Getting information for a Reservation item

 Click here to view/hide the sample request file...
http://capacity-optimization-datahub:8280/dh-services/rsv/reservations/312/items/213
 Click here to view/hide the sample response file...
{
    "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/reservations/10001/items/2",
    "id": 2,
    "name": "VMware.medium-1-custom",
    "systemTemplate": {
        "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/systemtemplates/2213",
        "id": 2213,
        "name": "VMware.medium"
    }
}

Updating a Reservation item

 Click here to view/hide the sample request file...
{
    "name": "VMware.medium-1-custom",
    "systemTemplate": {
        "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/systemtemplates/2213",
        "id": 2213,
        "name": "VMware.medium"
    }
}
 Click here to view/hide the sample response file...
{
    "status": "OK",
    "message": "The reservation item has been successfully updated",
    "item": {
        "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/reservations/10001/items/2",
        "id": 2,
        "name": "VMware.medium-1-custom",
        "systemTemplate": {
            "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/systemtemplates/2213",
            "id": 2213,
            "name": "VMware.medium"
        }
    }
}

Deleting a Reservation item

 Click here to view/hide the sample request file...
http://capacity-optimization-datahub:8280/dh-services/rsv/reservations/312/items/213
 Click here to view/hide the sample response file...
{
  "status" : "OK",
  "message" : "The item has been successfully deleted."
}

Capacity Pool

Getting information for a Capacity Pool

 Click here to view/hide the sample request file...
http://capacity-optimization-datahub:8280/dh-services/rsv/capacity-pools/386
 Click here to view/hide the sample response file...
{
    "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/capacitypools/2211",
    "id": 2211,
    "name": "NY capacity pool ",
    "enttypenm": "cp:vmwc",
    "technology": "VMWARE",
    "location": "UNKNOWN",
    "tags": [
        {
            "name": "Virtualization Technology",
            "value": "VMware",
            "description": "VMware virtualization technology"
        }
    ],
    "reservationTargets": [
        {
            "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/reservationtargets/2162",
            "id": 2162,
            "name": "Cluster-4"
        },
        {
            "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/reservationtargets/2220",
            "id": 2220,
            "name": "Hypothetical Reservation Target - Boston capacity pool "
        }
    ],
    "reservations": [
        {
            "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/reservations/10001",
            "id": 10001,
            "name": "my_rsv"
        },
        {
            "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/reservations/10005",
            "id": 10005,
            "name": "sample_rsv"
        }
    ],
    "onboardings": [
        {
            "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/onboardings/10037",
            "id": 10037,
            "name": "Onboarding_ESXHost"
        }
    ]
}

Searching a Capacity Pool

 Click here to view/hide the sample request file...
{
  "filters" : [ {
    "field" : "name",
    "operator" : "LIKE",
    "value" : "Milan%"
  }, {
    "field" : "technology",
    "operator" : "EQUAL",
    "value" : "VMware"
  } ]
}
 Click here to view/hide the sample response file...
 {
  "capacityPools" : [ {
    "href" : "http://capacity-optimization-datahub:8280/dh-services/rsv/capacitypools/386",
    "id" : "386",
    "name" : "Milan capacity pool"
  } ]
}

Reservation Target

Getting information for a Reservation Target

 Click here to view/hide the sample request file...
 http://capacity-optimization-datahub:8280/dh-services/rsv/capacity-containers/442
 Click here to view/hide the sample response file...
 {
    "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/reservationtargets/2162",
    "id": 2162,
    "name": "Cluster-4",
    "enttypenm": "vhc:vmw",
    "hypothetical": false,
    "capacityPools": [
        {
            "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/reservationtargets/2211",
            "id": 2211,
            "name": "NY Capacity Pool"
        }
    ],
    "reservations": [
        {
            "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/reservations/10001",
            "id": 10001,
            "name": "my_rsv"
        },
        {
            "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/reservations/10005",
            "id": 10005,
            "name": "sample_rsv"
        }
    ],
    "onboardings": [
        {
            "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/onboardings/10001",
            "id": 10001,
            "name": "Onboarding_ESXHost"
        },
        {
            "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/onboardings/10065",
            "id": 10065,
            "name": "Onboarding_ESXHost"
        }
    ],
    "offboardings": [
        {
            "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/offboardings/10001",
            "id": 10010,
            "name": "Offboarding_ESXHost"
        }
    ]
}

Searching for a Reservation Target

 Click here to view/hide the sample request file...
 {
  "filters" : [ {
    "field" : "name",
    "operator" : "LIKE",
    "value" : "CLM%"
  }, {
    "field" : "capacitypoolids",
    "operator" : "IN",
    "value" : "386,444"
  } ]
}
 Click here to view/hide the sample response file...
 {
  "reservationTargets" : [ {
    "href" : "http://capacity-optimization-datahub:8280/dh-services/rsv/reservationtargets/442",
    "id" : "442",
    "name" : "CLM-Cluster"
  } ]
}

Onboarding

Creating a new Onboarding

 Click here to view/hide the sample request file to add an onboarding item on a capacity container...
 {
    "name": "Onboarding_NewHost",
    "description": "Onboarding new ESX hosts",
    "onboardingDate": "16/01/2015",
    "offboardingDate": "16/02/2015",
    "resources": {
        "resourceTemplates": [
            {
                "numItems": 1,
                "systemTemplateLookup": {
                    "id": "2165"
                }
            }
        ]
    },
    "reservationTarget": {
        "id": 2162
    }
}
 Click here to view/hide the sample request file to add an onboarding item on a capacity pool...
 {
    "name": "Onboarding_NewHost",
    "description": "Onboarding new ESX hosts",
    "onboardingDate": "16/01/2015",
    "offboardingDate": "16/02/2015",
    "resources": {
        "resourceTemplates": [
            {
                "numItems": 1,
                "systemTemplateLookup": {
                    "id": "2165"
                }
            }
        ]
    },
    "capacityPool": {
        "id": 2211
    }
}
 Click here to view/hide the sample response file to a request for adding an onboarding item on a capacity container...
{
    "status": "OK",
    "message": "The onboarding has been successfully created",
    "onboarding": {
        "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/onboardings/10229",
        "id": 10229,
        "name": "Onboarding_NewHost",
        "description": "Onboarding new ESX hosts",
        "onboardingDate": "16/01/2015",
        "offboardingDate": "16/02/2015",
        "resourceRequirementSummary": {
            "numSystems": 3,
            "cpuCores": 24,
            "cpuTotalMHz": 55176,
            "memTotal": 206013726720,
            "storageTotal": 6080868384768
        },
        "resources": {
            "resourceTemplates": [
                {
                    "numItems": 1,
                    "systemTemplate": {
                        "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/systemtemplates/2216",
                        "id": 2216,
                        "name": "VMwareHost.medium"
                    }
                }
            ]
        },
        "reservationTarget": {
            "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/reservationtargets/2162",
            "id": 2162,
            "name": "Cluster-4"
        }
    }
}
 Click here to view/hide the sample response file to a request for adding an onboarding item on a capacity pool...
{
    "status": "OK",
    "message": "The onboarding has been successfully created",
    "onboarding": {
        "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/onboardings/10229",
        "id": 10229,
        "name": "Onboarding_NewHost",
        "description": "Onboarding new ESX hosts",
        "onboardingDate": "16/01/2015",
        "offboardingDate": "16/02/2015",
        "resourceRequirementSummary": {
            "numSystems": 3,
            "cpuCores": 24,
            "cpuTotalMHz": 55176,
            "memTotal": 206013726720,
            "storageTotal": 6080868384768
        },
        "resources": {
            "resourceTemplates": [
                {
                    "numItems": 1,
                    "systemTemplate": {
                        "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/systemtemplates/2216",
                        "id": 2216,
                        "name": "VMwareHost.medium"
                    }
                }
            ]
        },
        "capacityPool": {
            "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/reservationtargets/2211",
            "id": 2211,
            "name": "NY Capacity Pool"
        }
    }
}

Getting information for an Onboarding item

 Click here to view/hide the sample request file...
 http://capacity-optimization-datahub:8280/dh-services/rsv/onboardings/34
 Click here to view/hide the sample response file...
 {
    "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/onboardings/10231",
    "id": 10231,
    "name": "Onboarding_NewHost",
    "description": "Onboarding new ESX hosts",
    "onboardingDate": "16/01/2015",
    "offboardingDate": "16/02/2015",
    "resourceRequirementSummary": {
        "numSystems": 2,
        "cpuCores": 16,
        "cpuTotalMHz": 36784,
        "memTotal": 137342484480,
        "storageTotal": 4053912256512
    },
    "resources": {
        "resourceTemplates": [
            {
                "numItems": 1,
                "systemTemplate": {
                    "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/systemtemplates/2216",
                    "id": 2216,
                    "name": "template_pe-pun-bco-dv05"
                }
            }
        ]
    },
    "reservationTarget": {
        "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/reservationtargets/2162",
        "id": 2162,
        "name": "Cluster-4"
    }
}

Updating an Onboarding item

 Click here to view/hide the sample request file...
{
    "name": "Onboarding_NewHost",
    "description": "Onboarding new ESX hosts",
    "onboardingDate": "20/02/2015",
    "offboardingDate": "25/03/2015",
    "resources": {
        "resourceTemplates": [
            {
                "numItems": 1,
                "systemTemplateLookup": {
                    "id": "2216"
                }
            }
        ]
    },
    "reservationTarget": {
        "id": 2162
    }
}
 Click here to view/hide the sample response file...
{
    "status": "OK",
    "message": "The onboarding has been successfully updated",
    "onboarding": {
        "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/onboardings/10231",
        "id": 10231,
        "name": "Onboarding_NewHost",
        "description": "Onboarding new ESX hosts",
        "onboardingDate": "20/02/2015",
        "offboardingDate": "25/03/2015",
        "resourceRequirementSummary": {
            "numSystems": 2,
            "cpuCores": 16,
            "cpuTotalMHz": 36784,
            "memTotal": 137342484480,
            "storageTotal": 4053912256512
        },
        "resources": {
            "resourceTemplates": [
                {
                    "numItems": 1,
                    "systemTemplate": {
                        "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/systemtemplates/2216",
                        "id": 2216,
                        "name": "VMwareHost.medium"
                    }
                }
            ]
        },
        "reservationTarget": {
            "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/reservationtargets/2162",
            "id": 2162,
            "name": "Cluster-4"
        }
    }
}

Deleting an Onboarding item

 Click here to view/hide the sample request file...
 http://capacity-optimization-datahub:8280/dh-services/rsv/onboardings/449
 Click here to view/hide the sample response file...
 {
  "status" : "OK",
  "message" : "The onboarding has been successfully deleted."
}

Searching for an Onboarding item

 Click here to view/hide the sample request file...
 {
  "filters" : [ {
    "field" : "name",
    "operator" : "LIKE",
    "value" : "test_onboarding"
  }, {
    "field" : "status",
    "operator" : "IN",
    "value" : "COMMITTED,PENDING"
  } ]
}
 Click here to view/hide the sample response file...
 {
  "onboardings" : [ {
    "href" : "http://capacity-optimization-datahub:8280/dh-services/rsv/onboardings/34",
    "id" : "34",
    "name" : "my_test_onboarding"
  }, {
    "href" : "http://capacity-optimization-datahub:8280/dh-services/rsv/onboardings/553",
    "id" : "553",
    "name" : "onboardingDec"
  } ]
}

Offboarding

Creating a new Offboarding

 Click here to view/hide the sample request file...
{
    "name": "Offboarding_ESXHost",
    "offboardingDate": "20/01/2015",
    "resources": {
        "resourceTemplates": [
            {
                "numItems": 1,
                "systemTemplateLookup": {
                    "id": "2216"
                }
            }
        ]
    },
    "reservationTarget": {
        "id": 2158
    }
}
 Click here to view/hide the sample response file...
{
    "status": "OK",
    "message": "The offboarding has been successfully created",
    "offboarding": {
        "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/offboardings/10232",
        "id": 10232,
        "name": "Offboarding_ESXHost",
        "offboardingDate": "20/01/2015",
        "resourceRequirementSummary": {
            "numSystems": 1,
            "cpuCores": 8,
            "cpuTotalMHz": 18392,
            "memTotal": 68671242240,
            "storageTotal": 2026956128256
        },
        "resources": {
            "resourceTemplates": [
                {
                    "numItems": 1,
                    "systemTemplate": {
                        "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/systemtemplates/2216",
                        "id": 2216,
                        "name": "VMwareHost.medium"
                    }
                }
            ]
        },
        "reservationTarget": {
            "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/reservationtargets/2158",
            "id": 2158,
            "name": "Cluster-7"
        }
    }
}

Getting information for an Offboarding item

 Click here to view/hide the sample request file...
 http://capacity-optimization-datahub:8280/dh-services/rsv/onboardings/459
 Click here to view/hide the sample response file...
{
    "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/offboardings/10232",
    "id": 10232,
    "name": "Offboarding_ESXHost",
    "offboardingDate": "20/01/2015",
    "resourceRequirementSummary": {
        "numSystems": 1,
        "cpuCores": 8,
        "cpuTotalMHz": 18392,
        "memTotal": 68671242240,
        "storageTotal": 2026956128256
    },
    "resources": {
        "resourceTemplates": [
            {
                "numItems": 1,
                "systemTemplate": {
                    "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/systemtemplates/2216",
                    "id": 2216,
                    "name": "VMwareHost.medium"
                }
            }
        ]
    },
    "reservationTarget": {
        "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/reservationtargets/2158",
        "id": 2158,
        "name": "Cluster-7"
    }
}

Updating an Offboarding item

 Click here to view/hide the sample request file...
{
    "name": "Offboarding_ESXHost",
    "offboardingDate": "29/01/2015",
    "resources": {
        "resourceTemplates": [
            {
                "numItems": 1,
                "systemTemplateLookup": {
                    "id": "2216"
                }
            }
        ]
    },
    "reservationTarget": {
        "id": 2162
    }
}
 Click here to view/hide the sample response file...
{
    "status": "OK",
    "message": "The offboarding has been successfully updated",
    "offboarding": {
        "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/offboardings/10232",
        "id": 10232,
        "name": "Offboarding_ESXHost",
         "offboardingDate": "29/01/2015",
        "resourceRequirementSummary": {
            "numSystems": 1,
            "cpuCores": 8,
            "cpuTotalMHz": 18392,
            "memTotal": 68671242240,
            "storageTotal": 2026956128256
        },
        "resources": {
            "resourceTemplates": [
                {
                    "numItems": 1,
                    "systemTemplate": {
                        "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/systemtemplates/2216",
                        "id": 2216,
                        "name": "template_pe-pun-bco-dv05"
                    }
                }
            ]
        },
        "reservationTarget": {
            "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/reservationtargets/2162",
            "id": 2162,
            "name": "Cluster-4"
        }
    }
}

Deleting an Offboarding item

 Click here to view/hide the sample request file...
 http://capacity-optimization-datahub:8280/dh-services/rsv/onboardings/459
 Click here to view/hide the sample response file...
 {
  "status" : "OK",
  "message" : "The offboarding has been successfully deleted."
}

Searching for an Offboarding item

 Click here to view/hide the sample request file...
 {
  "filters" : [ {
    "field" : "offboardingDate",
    "operator" : "EQUAL",
    "value" : "12/12/2014"
  } ]
}
 Click here to view/hide the sample response file...
 {
  "offboardings" : [ {
    "href" : "http://capacity-optimization-datahub:8280/dh-services/rsv/onboardings/459",
    "id" : "459",
    "name" : "my_test_offboarding"
  } ]
}

Tenant

Getting information for a tenant

 Click here to view/hide the sample request file...
http://capacity-optimization-datahub:8280/dh-services/rsv/tenants/2450
 Click here to view/hide the sample response file...
{
    "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/tenants/3412",
    "id": 3412,
    "name": "Sales Division",
    "description": "Sales Division of ACME Services",
    "lookupName": "Sales Division",
    "lookupFields": [
        {
            "lookupField": "ENTTYPE",
            "lookupValue": "tnt"
        },
        {
            "lookupField": "GUID",
            "lookupValue": "OI-B5A2B476FD4C4AC8A55FD93A37261CA3"
        },
        {
            "lookupField": "NAME",
            "lookupValue": "Sales Division"
        }
    ],
    "parentTenant": {
        "href": "http://capacity-optimization-datahub:8280/dh-services/rsv/tenants/432",
        "id": 432,
        "name": "ACME Services"
    },
    "tenantQuota": {
        "numItems": 35,
        "cpuCores": 10,
        "cpuTotalMhz": 1800,
        "memTotal": 171798691840
    },
    "resourceRequirementSummary": {
        "numItems": 4,
        "cpuCores": 16,
        "cpuTotalMHz": 80000,
        "memTotal": 42949672960,
        "storageTotal": 171798691840,
        "cpuCoresUsed": 1.6,
        "cpuTotalMHzUsed": 8000,
        "memTotalUsed": 38654705664,
        "storageTotalUsed": 103079215104
    }
}

Searching for a Tenant

 Click here to view/hide the sample request file...
{
  "filters" : [ {
    "field" : "name",
    "operator" : "EQUAL",
    "value" : "Development"
  } ]
}
 Click here to view/hide the sample response file...
{
  "tenants" : [ {
    "href" : "http://capacity-optimization-datahub:8280/dh-services/rsv/tenants/1864874",
    "id" : 1864874,
    "name" : "Development"
  } ]
}