Gets all the invoice one time line items of an invoice for a customer, using pagination.

GET /v1/Invoices/{id}/customer-onetime-lineitems

Returns a subset of the invoice one time line items of an invoice on each request for the customer. Pass the continuation token in the headers to obtain the remaining items.

Headers

  • This header should not be set when the first page is desired. For the second page and onwards, pass the continuation token received in the response body.

  • X-Tenant string Required

    The domain used to access the portal.

  • Authorization string Required

    JWT Authorization header using the Bearer scheme. Example: "Authorization: Bearer {token}"

    Default value is Bearer eyJ0eXAiO....

  • X-Correlation-Id string(UUID)

    This header is optional and by setting it you can correlate the audit logs made by this request.

Path parameters

  • id string(uuid) Required

    The id of the invoice.

Query parameters

  • pageSize integer(int32) Required

    The number of items to be returned at max per page. The size can range between 1 and 2000.

  • resellerId string(uuid)

    The id of a specific reseller. If you are a CSP you can set this to filter by reseller, otherwise don't send a value.

  • customerId string(uuid)

    The id of the customer. Use this if you are a CSP or a reseller to filter by customer. Otherwise this should be not set.

Responses

  • The request completed with success and returns the line items and the continuation token (if applicable).

    Hide response attributes Show response attributes object
    • items array[object] | null

      The items in this particular seek operation.

      Hide items attributes Show items attributes object
      • customerId string(uuid) | null

        The id of the customer associated to this charge. Can be null.

      • customerName string | null

        The company name of the customer.

      • customerCountry string | null

        The country in which the customer is located.

      • orderDate string(date-time) | null

        The date the order was placed.

      • chargeType string | null

        The type of charge on this line item. Possible values for the Microsoft provider include:

        • new: When you buy a new subscription.
        • renew: When you renew your subscription.
        • cycleCharge: Regular recurring charges for your subscription.
        • addQuantity: Refunds and charges when you add seats.
        • removeQuantity: Refunds and charges when you remove seats.
        • moveQuantity: When you upgrade to an existing subscription.
        • cancelImmediate: When you cancel your subscription.
        • convert: When you change from a free trial to a paid subscription or upgrade to a new subscription.
        • changeBillingPlan: Changing from monthly to yearly billing or vice versa.
        • customerCredit: Credits for Azure, SLA, among others.
        • extendTerm: When you are given a longer trial period.
      • quantity number(double)

        The quantity of the subscription associated to the charge.

      • currency string | null

        The currency associated with the line item.

      • The subscription description associated with this purchase.

      • subscriptionId string(uuid) | null

        The id of the subscription associated to the charge. Can be null.

      • chargeStartDate string(date-time)

        The billing start date for this charge.

      • chargeEndDate string(date-time)

        The billing end date for this charge.

      • termAndBillingCycle string | null

        The term and billing cycle associated with this purchase.

      • unitType string | null

        The type of the unit.

      • unitPriceForCustomer number(double) | null

        The unit price for customer.

      • subtotalForCustomer number(double) | null

        The total before taxes for the customer.

      • taxTotalForCustomer number(double) | null

        The tax value for the customer.

      • totalForCustomer number(double) | null

        The total for customer after taxes.

      • id string(uuid)

        The id that uniquely identifies a one time invoice line item.

      • billableQuantity number(double)

        The amount of units billed.

      • billingFrequency string | null

        The billing frequency of the subscription associated to the charge. Can also be empty.

      • pricingCurrency string | null

        The currency of the UnitPriceForReseller and UnitPriceForCustomer. This currency may differ from the invoice billing currency.

      • productType string | null

        The type of the offer associated with this charge. Possible values:

        • license.
        • softwaresubscription.
        • perpetualsoftware.
        • azureplan.
        • azurereservation.
        • azurelegacy.
        • azuresavingsplan.
      • subscriptionStartDate string(date-time) | null

        The start date of billing for the subscription. This value can change once a subscription renews. If it renews, then on the next invoice this property is updated too.

      • subscriptionEndDate string(date-time) | null

        The end date of the term of the subscription.

      • offerProviderId string | null

        The offer id on the provider's side that identifies the subscription associated to the charge.

      • The id of the subscription associated to this charge on the provider's side.

      • The purchase order number of the subscription associated with this charge.

      • subscriptionName string | null

        The friendly name of the subscription associated with this charge.

      • providerData object | null

        A dictionary that maps from strings to strings that contains specific provider invoice data.

        If this line item is associated to a Microsoft invoice then there are a set of properties that are common to each charge: CustomerDomainName: The domain of the customer. ProductId: The id of the product of the line item. SkuId: The id of the sku of the line item. AvailabilityId: The id of the availability of the line item. ProductName: The name of the product. SkuName: The name of the sku. PublisherName: The name of the publisher of the sku. PublisherId: The id of the publisher of the sku. AlternateId: The alternate id. MeterDescription: The description of the meter of the line item.

        The following properties only appear in some types of charges, see below: ReservationOrderId: For Azure Savings Plan this property corresponds to the savings plan order id on the Azure platform, example: "2D0D3389-D0D9-44D2-8BB4-441F5CD6D8CC". For Azure reservations this is the reservation order id, example: "8A05BC26-0542-4B6F-B97F-ECA5BAC54E9E".

        For Azure savings plan the properties are: ReservationOrderId. For Azure reservation the properties are: ReservationOrderId.

        Hide providerData attribute Show providerData attribute object | null
        • * string Additional properties
    • continuationToken string | null

      The token to continue to retrieve the paginated items. Should not be set if the first page of items is desired.

    Hide response attributes Show response attributes object
    • items array[object] | null

      The items in this particular seek operation.

      Hide items attributes Show items attributes object
      • customerId string(uuid) | null

        The id of the customer associated to this charge. Can be null.

      • customerName string | null

        The company name of the customer.

      • customerCountry string | null

        The country in which the customer is located.

      • orderDate string(date-time) | null

        The date the order was placed.

      • chargeType string | null

        The type of charge on this line item. Possible values for the Microsoft provider include:

        • new: When you buy a new subscription.
        • renew: When you renew your subscription.
        • cycleCharge: Regular recurring charges for your subscription.
        • addQuantity: Refunds and charges when you add seats.
        • removeQuantity: Refunds and charges when you remove seats.
        • moveQuantity: When you upgrade to an existing subscription.
        • cancelImmediate: When you cancel your subscription.
        • convert: When you change from a free trial to a paid subscription or upgrade to a new subscription.
        • changeBillingPlan: Changing from monthly to yearly billing or vice versa.
        • customerCredit: Credits for Azure, SLA, among others.
        • extendTerm: When you are given a longer trial period.
      • quantity number(double)

        The quantity of the subscription associated to the charge.

      • currency string | null

        The currency associated with the line item.

      • The subscription description associated with this purchase.

      • subscriptionId string(uuid) | null

        The id of the subscription associated to the charge. Can be null.

      • chargeStartDate string(date-time)

        The billing start date for this charge.

      • chargeEndDate string(date-time)

        The billing end date for this charge.

      • termAndBillingCycle string | null

        The term and billing cycle associated with this purchase.

      • unitType string | null

        The type of the unit.

      • unitPriceForCustomer number(double) | null

        The unit price for customer.

      • subtotalForCustomer number(double) | null

        The total before taxes for the customer.

      • taxTotalForCustomer number(double) | null

        The tax value for the customer.

      • totalForCustomer number(double) | null

        The total for customer after taxes.

      • id string(uuid)

        The id that uniquely identifies a one time invoice line item.

      • billableQuantity number(double)

        The amount of units billed.

      • billingFrequency string | null

        The billing frequency of the subscription associated to the charge. Can also be empty.

      • pricingCurrency string | null

        The currency of the UnitPriceForReseller and UnitPriceForCustomer. This currency may differ from the invoice billing currency.

      • productType string | null

        The type of the offer associated with this charge. Possible values:

        • license.
        • softwaresubscription.
        • perpetualsoftware.
        • azureplan.
        • azurereservation.
        • azurelegacy.
        • azuresavingsplan.
      • subscriptionStartDate string(date-time) | null

        The start date of billing for the subscription. This value can change once a subscription renews. If it renews, then on the next invoice this property is updated too.

      • subscriptionEndDate string(date-time) | null

        The end date of the term of the subscription.

      • offerProviderId string | null

        The offer id on the provider's side that identifies the subscription associated to the charge.

      • The id of the subscription associated to this charge on the provider's side.

      • The purchase order number of the subscription associated with this charge.

      • subscriptionName string | null

        The friendly name of the subscription associated with this charge.

      • providerData object | null

        A dictionary that maps from strings to strings that contains specific provider invoice data.

        If this line item is associated to a Microsoft invoice then there are a set of properties that are common to each charge: CustomerDomainName: The domain of the customer. ProductId: The id of the product of the line item. SkuId: The id of the sku of the line item. AvailabilityId: The id of the availability of the line item. ProductName: The name of the product. SkuName: The name of the sku. PublisherName: The name of the publisher of the sku. PublisherId: The id of the publisher of the sku. AlternateId: The alternate id. MeterDescription: The description of the meter of the line item.

        The following properties only appear in some types of charges, see below: ReservationOrderId: For Azure Savings Plan this property corresponds to the savings plan order id on the Azure platform, example: "2D0D3389-D0D9-44D2-8BB4-441F5CD6D8CC". For Azure reservations this is the reservation order id, example: "8A05BC26-0542-4B6F-B97F-ECA5BAC54E9E".

        For Azure savings plan the properties are: ReservationOrderId. For Azure reservation the properties are: ReservationOrderId.

        Hide providerData attribute Show providerData attribute object | null
        • * string Additional properties
    • continuationToken string | null

      The token to continue to retrieve the paginated items. Should not be set if the first page of items is desired.

    Hide response attributes Show response attributes object
    • items array[object] | null

      The items in this particular seek operation.

      Hide items attributes Show items attributes object
      • customerId string(uuid) | null

        The id of the customer associated to this charge. Can be null.

      • customerName string | null

        The company name of the customer.

      • customerCountry string | null

        The country in which the customer is located.

      • orderDate string(date-time) | null

        The date the order was placed.

      • chargeType string | null

        The type of charge on this line item. Possible values for the Microsoft provider include:

        • new: When you buy a new subscription.
        • renew: When you renew your subscription.
        • cycleCharge: Regular recurring charges for your subscription.
        • addQuantity: Refunds and charges when you add seats.
        • removeQuantity: Refunds and charges when you remove seats.
        • moveQuantity: When you upgrade to an existing subscription.
        • cancelImmediate: When you cancel your subscription.
        • convert: When you change from a free trial to a paid subscription or upgrade to a new subscription.
        • changeBillingPlan: Changing from monthly to yearly billing or vice versa.
        • customerCredit: Credits for Azure, SLA, among others.
        • extendTerm: When you are given a longer trial period.
      • quantity number(double)

        The quantity of the subscription associated to the charge.

      • currency string | null

        The currency associated with the line item.

      • The subscription description associated with this purchase.

      • subscriptionId string(uuid) | null

        The id of the subscription associated to the charge. Can be null.

      • chargeStartDate string(date-time)

        The billing start date for this charge.

      • chargeEndDate string(date-time)

        The billing end date for this charge.

      • termAndBillingCycle string | null

        The term and billing cycle associated with this purchase.

      • unitType string | null

        The type of the unit.

      • unitPriceForCustomer number(double) | null

        The unit price for customer.

      • subtotalForCustomer number(double) | null

        The total before taxes for the customer.

      • taxTotalForCustomer number(double) | null

        The tax value for the customer.

      • totalForCustomer number(double) | null

        The total for customer after taxes.

      • id string(uuid)

        The id that uniquely identifies a one time invoice line item.

      • billableQuantity number(double)

        The amount of units billed.

      • billingFrequency string | null

        The billing frequency of the subscription associated to the charge. Can also be empty.

      • pricingCurrency string | null

        The currency of the UnitPriceForReseller and UnitPriceForCustomer. This currency may differ from the invoice billing currency.

      • productType string | null

        The type of the offer associated with this charge. Possible values:

        • license.
        • softwaresubscription.
        • perpetualsoftware.
        • azureplan.
        • azurereservation.
        • azurelegacy.
        • azuresavingsplan.
      • subscriptionStartDate string(date-time) | null

        The start date of billing for the subscription. This value can change once a subscription renews. If it renews, then on the next invoice this property is updated too.

      • subscriptionEndDate string(date-time) | null

        The end date of the term of the subscription.

      • offerProviderId string | null

        The offer id on the provider's side that identifies the subscription associated to the charge.

      • The id of the subscription associated to this charge on the provider's side.

      • The purchase order number of the subscription associated with this charge.

      • subscriptionName string | null

        The friendly name of the subscription associated with this charge.

      • providerData object | null

        A dictionary that maps from strings to strings that contains specific provider invoice data.

        If this line item is associated to a Microsoft invoice then there are a set of properties that are common to each charge: CustomerDomainName: The domain of the customer. ProductId: The id of the product of the line item. SkuId: The id of the sku of the line item. AvailabilityId: The id of the availability of the line item. ProductName: The name of the product. SkuName: The name of the sku. PublisherName: The name of the publisher of the sku. PublisherId: The id of the publisher of the sku. AlternateId: The alternate id. MeterDescription: The description of the meter of the line item.

        The following properties only appear in some types of charges, see below: ReservationOrderId: For Azure Savings Plan this property corresponds to the savings plan order id on the Azure platform, example: "2D0D3389-D0D9-44D2-8BB4-441F5CD6D8CC". For Azure reservations this is the reservation order id, example: "8A05BC26-0542-4B6F-B97F-ECA5BAC54E9E".

        For Azure savings plan the properties are: ReservationOrderId. For Azure reservation the properties are: ReservationOrderId.

        Hide providerData attribute Show providerData attribute object | null
        • * string Additional properties
    • continuationToken string | null

      The token to continue to retrieve the paginated items. Should not be set if the first page of items is desired.

  • There is an error in the parameters sent in the request.

    Hide response attributes Show response attributes object
    • statusCode integer(int32)

      The HTTP status code that represents a specific error scenario.

    • type string | null

      The type of error that occurred.

    • description string | null

      Describes the error scenario that occurred.

    • correlationId string | null

      The correlationId of the request that originated the error.

    Hide response attributes Show response attributes object
    • statusCode integer(int32)

      The HTTP status code that represents a specific error scenario.

    • type string | null

      The type of error that occurred.

    • description string | null

      Describes the error scenario that occurred.

    • correlationId string | null

      The correlationId of the request that originated the error.

    Hide response attributes Show response attributes object
    • statusCode integer(int32)

      The HTTP status code that represents a specific error scenario.

    • type string | null

      The type of error that occurred.

    • description string | null

      Describes the error scenario that occurred.

    • correlationId string | null

      The correlationId of the request that originated the error.

  • Please use a valid authorization token.

  • You don't have enough permissions to access this information.

  • The requested onetime invoice does not exist. Any line items previously obtained should be discarded.

    Hide response attributes Show response attributes object
    • statusCode integer(int32)

      The HTTP status code that represents a specific error scenario.

    • type string | null

      The type of error that occurred.

    • description string | null

      Describes the error scenario that occurred.

    • correlationId string | null

      The correlationId of the request that originated the error.

    Hide response attributes Show response attributes object
    • statusCode integer(int32)

      The HTTP status code that represents a specific error scenario.

    • type string | null

      The type of error that occurred.

    • description string | null

      Describes the error scenario that occurred.

    • correlationId string | null

      The correlationId of the request that originated the error.

    Hide response attributes Show response attributes object
    • statusCode integer(int32)

      The HTTP status code that represents a specific error scenario.

    • type string | null

      The type of error that occurred.

    • description string | null

      Describes the error scenario that occurred.

    • correlationId string | null

      The correlationId of the request that originated the error.

  • A server error has happened during the request. Please try again later or contact support.

    Hide response attributes Show response attributes object
    • statusCode integer(int32)

      The HTTP status code that represents a specific error scenario.

    • type string | null

      The type of error that occurred.

    • description string | null

      Describes the error scenario that occurred.

    • correlationId string | null

      The correlationId of the request that originated the error.

    Hide response attributes Show response attributes object
    • statusCode integer(int32)

      The HTTP status code that represents a specific error scenario.

    • type string | null

      The type of error that occurred.

    • description string | null

      Describes the error scenario that occurred.

    • correlationId string | null

      The correlationId of the request that originated the error.

    Hide response attributes Show response attributes object
    • statusCode integer(int32)

      The HTTP status code that represents a specific error scenario.

    • type string | null

      The type of error that occurred.

    • description string | null

      Describes the error scenario that occurred.

    • correlationId string | null

      The correlationId of the request that originated the error.

GET /v1/Invoices/{id}/customer-onetime-lineitems
curl \
 -X GET https://app-cloudcockpitapi-prod-01.azurewebsites.net/v1/Invoices/{id}/customer-onetime-lineitems?pageSize=42 \
 -H "X-ContinuationToken: string" \
 -H "X-Tenant: portal.cloudcockpit.com" \
 -H "Authorization: Bearer eyJ0eXAiO..." \
 -H "X-Correlation-Id: string"
Response examples (200)
{
  "items": [
    {
      "customerId": "2C741C83-E111-4A77-BC5F-C2F065275FA9",
      "customerName": "Customer name",
      "customerCountry": "IE",
      "orderDate": "2023-05-03T21:25:51.6916741",
      "chargeType": "cycleCharge",
      "quantity": 4,
      "currency": "EUR",
      "subscriptionDescription": "Azure Plan",
      "subscriptionId": "03DE5ECE-EC93-42A9-8F15-9A770AC1F832",
      "chargeStartDate": "2023-04-01T00:00:00",
      "chargeEndDate": "2023-04-30T23:59:59",
      "termAndBillingCycle": "10K Read Operations",
      "unitType": "1 Hour",
      "unitPriceForCustomer": 2.72,
      "subtotalForCustomer": 2.72,
      "taxTotalForCustomer": 0,
      "totalForCustomer": 2.72,
      "id": "7828D90D-2AC6-4F20-A95B-EE850BCD32A0",
      "billableQuantity": 1,
      "billingFrequency": "Monthly",
      "pricingCurrency": "USD",
      "productType": "license",
      "subscriptionStartDate": "2023-04-01T00:00:00",
      "subscriptionEndDate": "2023-04-30T23:59:59",
      "offerProviderId": "DZH318Z0BQJ7:01DJ",
      "subscriptionProviderId": "FA2A91FD-7286-4DCD-9718-20048CCA832A",
      "subscriptionPONumber": "8543943821",
      "subscriptionName": "string",
      "providerData": {
        "ReservationOrderId": "A202A58B-7041-46EE-D5BC-2D0F6FD22106"
      }
    }
  ],
  "continuationToken": "string"
}
Response examples (200)
{
  "items": [
    {
      "customerId": "2C741C83-E111-4A77-BC5F-C2F065275FA9",
      "customerName": "Customer name",
      "customerCountry": "IE",
      "orderDate": "2023-05-03T21:25:51.6916741",
      "chargeType": "cycleCharge",
      "quantity": 4,
      "currency": "EUR",
      "subscriptionDescription": "Azure Plan",
      "subscriptionId": "03DE5ECE-EC93-42A9-8F15-9A770AC1F832",
      "chargeStartDate": "2023-04-01T00:00:00",
      "chargeEndDate": "2023-04-30T23:59:59",
      "termAndBillingCycle": "10K Read Operations",
      "unitType": "1 Hour",
      "unitPriceForCustomer": 2.72,
      "subtotalForCustomer": 2.72,
      "taxTotalForCustomer": 0,
      "totalForCustomer": 2.72,
      "id": "7828D90D-2AC6-4F20-A95B-EE850BCD32A0",
      "billableQuantity": 1,
      "billingFrequency": "Monthly",
      "pricingCurrency": "USD",
      "productType": "license",
      "subscriptionStartDate": "2023-04-01T00:00:00",
      "subscriptionEndDate": "2023-04-30T23:59:59",
      "offerProviderId": "DZH318Z0BQJ7:01DJ",
      "subscriptionProviderId": "FA2A91FD-7286-4DCD-9718-20048CCA832A",
      "subscriptionPONumber": "8543943821",
      "subscriptionName": "string",
      "providerData": {
        "ReservationOrderId": "A202A58B-7041-46EE-D5BC-2D0F6FD22106"
      }
    }
  ],
  "continuationToken": "string"
}
Response examples (400)
{
  "statusCode": 400,
  "type": "ValidationException",
  "description": "Validation failed: \\n -- PageSize: The page size must be between 1 and 2000 Severity: Error",
  "correlationId": "685043EA-6D49-4ACE-8BDB-CCE9D3E2DBD0"
}
Response examples (400)
{
  "statusCode": 400,
  "type": "ValidationException",
  "description": "Validation failed: \\n -- PageSize: The page size must be between 1 and 2000 Severity: Error",
  "correlationId": "685043EA-6D49-4ACE-8BDB-CCE9D3E2DBD0"
}
Response examples (404)
{
  "statusCode": 404,
  "type": "EntityNotFoundException",
  "description": "No providers found for the tenant.",
  "correlationId": "685043EA-6D49-4ACE-8BDB-CCE9D3E2DBD0"
}
Response examples (404)
{
  "statusCode": 404,
  "type": "EntityNotFoundException",
  "description": "No providers found for the tenant.",
  "correlationId": "685043EA-6D49-4ACE-8BDB-CCE9D3E2DBD0"
}
Response examples (500)
{
  "statusCode": 500,
  "type": "NullReferenceException",
  "description": "An error happened processing your request. Please contact support.",
  "correlationId": "685043EA-6D49-4ACE-8BDB-CCE9D3E2DBD0"
}
Response examples (500)
{
  "statusCode": 500,
  "type": "NullReferenceException",
  "description": "An error happened processing your request. Please contact support.",
  "correlationId": "685043EA-6D49-4ACE-8BDB-CCE9D3E2DBD0"
}