Usage Line Grouping Examples

Below are some examples of methodologies for grouping usage lines together into usage summaries

Group by Company

This is the grouping pattern recommended by Pax8 for the vast majority of our Vendors.

Below is an example grouping scenario for a Pax8 Partner that has 2 Companies under their account.

  • Company A uses:
    • 10 units of product 123
    • 15 units of Product 456
  • Company B uses:
    • 15 units of product 123
    • 15 units of product 789

When submitting usage lines:

  • summaryKey is set to the unique company id, which is often times a UUID,
  • summaryDisplayName is set to the company name
  • productId will be a UUID. It is set to a simple number for explanation purposes
curl --request POST \
     --url 'https://api.pax8.com/v2/usage/lines?subscriptionId=39039087-c1ab-480a-9395-4f78bb5a0340&billingPeriod=2025-08' \
     --header 'accept: */*' \
     --header 'authorization: Bearer TOKEN' \
     --header 'content-type: application/json' \
     --data '
[
  {
    "summaryKey": "company-A-id",
    "summaryDisplayName": "Company A",
    "quantity": 10,
    "productId": "123",
    "unitOfMeasurement": "unit"
  },
  {
    "summaryKey": "company-A-id",
    "summaryDisplayName": "Company A",
    "quantity": 15,
    "productId": "456",
    "unitOfMeasurement": "unit"
  },
  {
    "summaryKey": "company-B-id",
    "summaryDisplayName": "Company B",
    "quantity": 15,
    "productId": "123",
    "unitOfMeasurement": "unit"
  },
  {
    "summaryDisplayName": "Company B",
    "summaryKey": "company-B-id",
    "quantity": 15,
    "productId": "789",
    "unitOfMeasurement": "unit"
  }
]
'

In the Pax8 system, the user will see 2 groupings of usage lines. The first one will show 2 usage lines for Company A and the second group will show the 2 usage lines for Company B.

Group by Company and Product Type

This grouping pattern is an option if your offering includes a very large array of products that make sense to group by product type.
As a reminder, Pax8 recommends simply grouping by Company for the majority of cases.

Below is an example grouping scenario for a Pax8 Partner that has 1 Company under their account with multiple product types.

  • Company A uses 10 units of product 1, which is Type VM
  • Company A uses 20 units of product 2, which is Type VM
  • Company A uses 30 units of product 3, which is Type Storage

When submitting usage lines:

  • summaryKey is set to the concatenation of the unique company id, which is often times a UUID, and the product type
  • summaryDisplayName is set to the company name and product type, separated by a comma
  • productId will be a UUID. It is set to a simple number for explanation purposes
curl --request POST \
     --url 'https://api.pax8.com/v2/usage/lines?subscriptionId=39039087-c1ab-480a-9395-4f78bb5a0340&billingPeriod=2025-08' \
     --header 'accept: */*' \
     --header 'authorization: Bearer TOKEN' \
     --header 'content-type: application/json' \
     --data '
[
  {
    "summaryKey": "{company-A-id}-group-vm",
    "summaryDisplayName": "Company A, Group VM",
    "quantity": 10,
    "productId": "1",
    "unitOfMeasurement": "unit"
  },
  {
    "summaryKey": "{company-A-id}-group-vm",
    "summaryDisplayName": "Company A, Group VM",
    "quantity": 20,
    "productId": "2",
    "unitOfMeasurement": "unit"
  },
  {
    "summaryKey": "{company-A-id}-group-storage",
    "summaryDisplayName": "Company A, Group Storage",
    "quantity": 30,
    "productId": "3",
    "unitOfMeasurement": "unit"
  }
]
'

In the Pax8 system, the user will see 2 groupings of usage lines. The first one will show 2 usage lines related to Type VM and the second group will show the 1 usage line related to Type Storage.