Cloud Cruiser became HPE Consumption Analytics on Nov. 1st. You'll still see the old name in places while we update this site.

 

 

Consumption Analytics Documentation

Home > Cloud Cruiser 4 > REST API reference > Rate plans > Get rate plan summaries

Get rate plan summaries

Retrieves summary information for the rate plans specified by the query parameters. If no parameters are supplied, retrieves summary information for all rate plans.

This method is available in HPE Consumption Analytics Portal version 4.1 and later.

Resource URL

GET http://<ccServerURL>/rest/v2/ratePlans/summaries

Request

Parameters
  Name Type Description
URL query parameters (optional) count integer The number of rate plans to retrieve in output order. The default is -1, which retrieves all rate plans with an output order of startFrom or higher.
custHdrId integer The ID of a specific customer for whom to retrieve the associated rate plan
customerid string The account ID of a specific customer for whom to retrieve the associated rate plan
planId integer The ID of a specific rate plan to retrieve
planName string The name of a specific rate plan to retrieve
startFrom integer The output order of the first rate plan to retrieve. The default is 1.
withCustomers boolean Whether to include a list of associated customers for each rate plan in the retrieved information. The default is false.
withRevisions boolean Whether to include a list of effective date ranges for each rate plan. The default is false.
Body

None

Response

Content-Type

application/xml

Body

Summary information for the specified rate plans, as XML text with the root element RatePlanSummaryList or JAXB type com.cloudcruiser.server.webservices.v2.dto.rateplan.RatePlanSummaryList.

Schema

Version 4.0
Version 4.1 and later

For HPE Consumption Analytics Portal 4.1 and later, this XML schema describes rate plans and their contained effective date ranges.

<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:ns1="http://www.cloudcruiser.com/webservices/v2/Common" xmlns:tns="http://www.cloudcruiser.com/webservices/v2/Rateplan" attributeFormDefault="unqualified" elementFormDefault="qualified" targetNamespace="http://www.cloudcruiser.com/webservices/v2/Rateplan">
  <xs:import namespace="http://www.cloudcruiser.com/webservices/v2/Common"/>
  <xs:import/>
  <xs:element name="ratePlan" type="tns:RatePlan"/>
  <xs:element name="ratePlanList" type="tns:RatePlanList"/>
  <xs:element name="ratePlanSummaryList" type="tns:RatePlanSummaryList"/>
  <xs:element name="revision" type="tns:Revision"/>
  <xs:element name="revisions" type="tns:Revisions"/>
  <xs:element name="serviceRate" type="tns:ServiceRate"/>
  <xs:complexType name="RatePlan">
    <xs:sequence>
      <xs:element name="planName" type="xs:string"/>
      <xs:element minOccurs="0" name="description" type="xs:string"/>
      <xs:element default="false" name="defaultPlan" type="xs:boolean"/>
      <xs:element default="false" name="costPlan" type="xs:boolean"/>
      <xs:element default="true" name="valid" type="xs:boolean"/>
      <xs:element maxOccurs="unbounded" ref="tns:revision"/>
      <xs:element maxOccurs="unbounded" minOccurs="0" name="associatedCustomer" type="tns:AssociatedCustomer"/>
    </xs:sequence>
    <xs:attribute name="id" type="xs:int"/>
  </xs:complexType>
  <xs:complexType name="Revision">
    <xs:sequence>
      <xs:element minOccurs="0" name="ratePlan">
        <xs:complexType>
          <xs:sequence/>
          <xs:attribute name="name" type="xs:string"/>
          <xs:attribute name="id" type="xs:int"/>
        </xs:complexType>
      </xs:element>
      <xs:element name="startDate" type="ns1:StartOfDay"/>
      <xs:element name="endDate" type="ns1:EndOfDay"/>
      <xs:element maxOccurs="unbounded" minOccurs="0" ref="tns:serviceRate"/>
    </xs:sequence>
    <xs:attribute name="id" type="xs:int"/>
  </xs:complexType>
  <xs:complexType name="ServiceRate">
    <xs:sequence>
      <xs:element name="service" type="ns1:Service"/>
      <xs:element minOccurs="0" name="serviceRateDesc" type="xs:string"/>
      <xs:element default="4" name="priceDecimals" type="xs:short"/>
      <xs:element minOccurs="0" name="minimumCommit">
        <xs:complexType>
          <xs:sequence>
            <xs:element name="value" type="xs:double"/>
            <xs:element name="interval" type="xs:string"/>
          </xs:sequence>
        </xs:complexType>
      </xs:element>
      <xs:element minOccurs="0" name="targetAccountField" type="xs:string"/>
      <xs:element maxOccurs="unbounded" minOccurs="0" name="tag">
        <xs:complexType>
          <xs:sequence/>
          <xs:attribute name="name" type="xs:string" use="required"/>
          <xs:attribute name="value" type="xs:string" use="required"/>
        </xs:complexType>
      </xs:element>
      <xs:element maxOccurs="unbounded" name="rateItem" type="tns:RateItem"/>
    </xs:sequence>
  </xs:complexType>
  <xs:complexType abstract="true" name="RateItem">
    <xs:sequence>
      <xs:element minOccurs="0" name="rate" type="xs:double"/>
      <xs:element minOccurs="0" name="fixedCharge" type="xs:double"/>
    </xs:sequence>
  </xs:complexType>
  <xs:complexType name="PassthroughRateItem">
    <xs:complexContent>
      <xs:extension base="tns:RateItem">
        <xs:sequence/>
      </xs:extension>
    </xs:complexContent>
  </xs:complexType>
  <xs:complexType name="BasicRateItem">
    <xs:complexContent>
      <xs:extension base="tns:RateItem">
        <xs:sequence>
          <xs:element minOccurs="0" name="minUnits" type="xs:double"/>
        </xs:sequence>
      </xs:extension>
    </xs:complexContent>
  </xs:complexType>
  <xs:complexType abstract="true" name="TierRateItem">
    <xs:complexContent>
      <xs:extension base="tns:RateItem">
        <xs:sequence>
          <xs:element name="tierName" type="xs:string"/>
          <xs:element name="lowRange" type="xs:double"/>
          <xs:element minOccurs="0" name="highRange" type="xs:double"/>
        </xs:sequence>
      </xs:extension>
    </xs:complexContent>
  </xs:complexType>
  <xs:complexType name="PerTierRateItem">
    <xs:complexContent>
      <xs:extension base="tns:TierRateItem">
        <xs:sequence/>
      </xs:extension>
    </xs:complexContent>
  </xs:complexType>
  <xs:complexType name="HighTierMeteredRateItem">
    <xs:complexContent>
      <xs:extension base="tns:TierRateItem">
        <xs:sequence/>
      </xs:extension>
    </xs:complexContent>
  </xs:complexType>
  <xs:complexType name="HighTierAllocatedRateItem">
    <xs:complexContent>
      <xs:extension base="tns:TierRateItem">
        <xs:sequence/>
      </xs:extension>
    </xs:complexContent>
  </xs:complexType>
  <xs:complexType name="PerTierAllocatedRateItem">
    <xs:complexContent>
      <xs:extension base="tns:TierRateItem">
        <xs:sequence/>
      </xs:extension>
    </xs:complexContent>
  </xs:complexType>
  <xs:complexType name="HighTierRateItem">
    <xs:complexContent>
      <xs:extension base="tns:TierRateItem">
        <xs:sequence/>
      </xs:extension>
    </xs:complexContent>
  </xs:complexType>
  <xs:complexType name="PerTierMeteredRateItem">
    <xs:complexContent>
      <xs:extension base="tns:TierRateItem">
        <xs:sequence/>
      </xs:extension>
    </xs:complexContent>
  </xs:complexType>
  <xs:complexType name="AssociatedCustomer">
    <xs:sequence/>
    <xs:attribute name="id" type="xs:int"/>
    <xs:attribute name="customerid" type="xs:string"/>
  </xs:complexType>
  <xs:complexType name="RatePlanSummaryList">
    <xs:sequence>
      <xs:element maxOccurs="unbounded" minOccurs="0" name="ratePlanSummary" type="tns:RatePlanSummary"/>
    </xs:sequence>
    <xs:attribute name="totalPlans" type="xs:int"/>
    <xs:attribute name="retrievedPlans" type="xs:int"/>
    <xs:attribute name="startFrom" type="xs:int"/>
  </xs:complexType>
  <xs:complexType name="RatePlanSummary">
    <xs:sequence>
      <xs:element name="planName" type="xs:string"/>
      <xs:element minOccurs="0" name="description" type="xs:string"/>
      <xs:element maxOccurs="unbounded" name="revisionSummary">
        <xs:complexType>
          <xs:sequence/>
          <xs:attribute name="id" type="xs:int" use="required"/>
          <xs:attribute name="startDate" type="xs:string" use="required"/>
          <xs:attribute name="endDate" type="xs:string" use="required"/>
          <xs:attribute name="serviceCount" type="xs:int"/>
        </xs:complexType>
      </xs:element>
      <xs:element maxOccurs="unbounded" minOccurs="0" name="associatedCustomer" type="tns:AssociatedCustomer"/>
    </xs:sequence>
    <xs:attribute name="id" type="xs:int" use="required"/>
    <xs:attribute name="defaultPlan" type="xs:boolean"/>
    <xs:attribute name="costPlan" type="xs:boolean"/>
    <xs:attribute name="valid" type="xs:boolean"/>
  </xs:complexType>
  <xs:complexType name="Revisions">
    <xs:sequence>
      <xs:element maxOccurs="unbounded" minOccurs="0" ref="tns:revision"/>
    </xs:sequence>
  </xs:complexType>
  <xs:complexType name="RatePlanList">
    <xs:sequence>
      <xs:element maxOccurs="unbounded" minOccurs="0" ref="tns:ratePlan"/>
    </xs:sequence>
    <xs:attribute name="totalPlans" type="xs:int"/>
    <xs:attribute name="retrievedPlans" type="xs:int"/>
  </xs:complexType>
</xs:schema>

Examples

Get by order

URL invocation

GET http://localhost:8080/rest/v2/ratePlans/summaries?startFrom=2&count=3

Response body
<ratePlanSummaryList xmlns="http://www.cloudcruiser.com/webservices/v2/Rateplan" totalPlans="11" retrievedPlans="3" startFrom="2">
  <ratePlanSummary id="10101" defaultPlan="false" costPlan="false" valid="true">
    <planName>test-plan-11</planName>
    <description>test plan 11</description>
  </ratePlanSummary>
  <ratePlanSummary id="10102" defaultPlan="false" costPlan="false" valid="true">
    <planName>new-test-1</planName>
    <description/>
  </ratePlanSummary>
  <ratePlanSummary id="10200" defaultPlan="false" costPlan="false" valid="true">
    <planName>test-plan-12</planName>
    <description>test plan 12</description>
  </ratePlanSummary>
</ratePlanSummaryList>

Get by rate plan name, include date ranges and customers

URL invocation

GET http://localhost:8080/rest/v2/ratePlans/summaries?planName=test-plan-12&withRevisions=true&withCustomers=true

Response body
<ratePlanSummaryList xmlns="http://www.cloudcruiser.com/webservices/v2/Rateplan" totalPlans="11" retrievedPlans="1" startFrom="1">
  <ratePlanSummary id="10200" defaultPlan="false" costPlan="false" valid="true">
    <planName>test-plan-12</planName>
    <description>test plan 12</description>
    <revisionSummary id="10300" startDate="20000101" endDate="20141231" serviceCount="4"/>
    <revisionSummary id="10301" startDate="20150101" endDate="20161231" serviceCount="3"/>
    <revisionSummary id="10400" startDate="20170101" endDate="29991231" serviceCount="4"/>
    <associatedCustomer id="135" customerid="E|DD"/>
  </ratePlanSummary>
</ratePlanSummaryList>

Get by customer, include customers

URL invocation

GET http://localhost:8080/rest/v2/ratePlans/summaries?customerid=E|AA&withRevisions=true&withCustomers=true

Response body
<ratePlanSummaryList xmlns="http://www.cloudcruiser.com/webservices/v2/Rateplan" totalPlans="11" retrievedPlans="1" startFrom="1">
  <ratePlanSummary id="10101" defaultPlan="false" costPlan="false" valid="true">
    <planName>test-plan-11</planName>
    <description>test plan 11</description>
    <revisionSummary id="10103" startDate="20000101" endDate="20140831" serviceCount="4"/>
    <revisionSummary id="10104" startDate="20140901" endDate="20140930" serviceCount="4"/>
    <revisionSummary id="10200" startDate="20141001" endDate="20141231" serviceCount="4"/>
    <revisionSummary id="10201" startDate="20150101" endDate="29991231" serviceCount="4"/>
    <associatedCustomer id="132" customerid="E|AA"/>
  </ratePlanSummary>
</ratePlanSummaryList>
Last modified

Tags

Classifications

This page has no classifications.
© Copyright 2018 Hewlett Packard Enterprise Development LP