lib/services/consumptionManagement/lib/operations/usageDetails.js
/**
   * Lists the usage details by billingAccountId for a scope by current billing
   * period. Usage details are available via this API only for May 1, 2014 or
   * later.
   *
   * @param {string} billingAccountId BillingAccount ID
   *
   * @param {object} [options] Optional Parameters.
   *
   * @param {string} [options.expand] May be used to expand the
   * properties/additionalProperties or properties/meterDetails within a list of
   * usage details. By default, these fields are not included when listing usage
   * details.
   *
   * @param {string} [options.filter] May be used to filter usageDetails by
   * properties/usageEnd (Utc time), properties/usageStart (Utc time),
   * properties/resourceGroup, properties/instanceName, properties/instanceId or
   * tags. The filter supports 'eq', 'lt', 'gt', 'le', 'ge', and 'and'. It does
   * not currently support 'ne', 'or', or 'not'. Tag filter is a key value pair
   * string where key and value is separated by a colon (:).
   *
   * @param {string} [options.skiptoken] Skiptoken is only used if a previous
   * operation returned a partial result. If a previous response contains a
   * nextLink element, the value of the nextLink element will include a skiptoken
   * parameter that specifies a starting point to use for subsequent calls.
   *
   * @param {number} [options.top] May be used to limit the number of results to
   * the most recent N usageDetails.
   *
   * @param {object} [options.queryOptions] Additional parameters for the
   * operation
   *
   * @param {string} [options.queryOptions.apply] OData apply expression to
   * aggregate usageDetails by tags or (tags and properties/usageStart)
   *
   * @param {object} [options.customHeaders] Headers that will be added to the
   * request
   *
   * @returns {Promise} A promise is returned
   *
   * @resolve {HttpOperationResponse<UsageDetailsListResult>} - The deserialized result object.
   *
   * @reject {Error} - The error object.
   */
Lists the usage details by billingAccountId for a scope by current billing
period. Usage details are available via this API only for May 1, 2014 or
later.



@param {object} [options] Optional Parameters.

@param {string} [options.expand] May be used to expand the
properties/additionalProperties or properties/meterDetails within a list of
usage details. By default, these fields are not included when listing usage
details.



@param {string} [options.skiptoken] Skiptoken is only used if a previous
operation returned a partial result. If a previous response contains a
nextLink element, the value of the nextLink element will include a skiptoken
parameter that specifies a starting point to use for subsequent calls.

@param {number} [options.top] May be used to limit the number of results to
the most recent N usageDetails.

@param {object} [options.queryOptions] Additional parameters for the
operation

@param {string} [options.queryOptions.apply] OData apply expression to
aggregate usageDetails by tags or (tags and properties/usageStart)

@param {object} [options.customHeaders] Headers that will be added to the
request

@returns {Promise} A promise is returned

@resolve {HttpOperationResponse} - The deserialized result object.

@reject {Error} - The error object.
Lists the usage details by billingAccountId for a scope by current billing period . Usage details are available via this API only for May 1 2014 or later . @param { object } [ options ] Optional Parameters . @param { string } [ options . expand ] May be used to expand the properties / additionalProperties or properties / meterDetails within a list of usage details . By default these fields are not included when listing usage details . @param { string } [ options . skiptoken ] Skiptoken is only used if a previous operation returned a partial result . If a previous response contains a nextLink element the value of the nextLink element will include a skiptoken parameter that specifies a starting point to use for subsequent calls . @param { number } [ options . top ] May be used to limit the number of results to the most recent N usageDetails . @param { object } [ options . queryOptions ] Additional parameters for the operation @param { string } [ options . queryOptions . apply ] OData apply expression to aggregate usageDetails by tags or ( tags and properties / usageStart ) @param { object } [ options . customHeaders ] Headers that will be added to the request @returns { Promise } A promise is returned @resolve { HttpOperationResponse } - The deserialized result object . @reject { Error } - The error object .
listByBillingAccountWithHttpOperationResponse(billingAccountId, options) {
    let client = this.client;
    let self = this;
    return new Promise((resolve, reject) => {
      self._listByBillingAccount(billingAccountId, options, (err, result, request, response) => {
        let httpOperationResponse = new msRest.HttpOperationResponse(request, response);
        httpOperationResponse.body = result;
        if (err) { reject(err); }
        else { resolve(httpOperationResponse); }
        return;
      });
    });
  }
listByBillingAccountWithHttpOperationResponse ( billingAccountId , options ) { let client = this . client ; let self = this ; return new Promise ( ( resolve , reject ) => { self . _listByBillingAccount ( billingAccountId , options , ( err , result , request , response ) => { let httpOperationResponse = new msRest . HttpOperationResponse ( request , response ) ; httpOperationResponse . body = result ; if ( err ) { reject ( err ) ; } else { resolve ( httpOperationResponse ) ; } return ; } ) ; } ) ; }
Lists the usage details by billingAccountId for a scope by current billing
 period.
Lists the usage details by billingAccountId for a scope by current billing period .