Skip to main content

Get measurements help

The Measurements API is deployed for each Kraken. This means that your output may be unique to your environment and require additional eyes on the Kraken side.

Follow the format below to make sure Kraken developers have everything they would need to diagnose your problem and issue a fix.




Problem statement

The measurements API is returning X when it should be returning Y.

Environment

Which client are you seeing the issue in? Is this Production or Test?

Query

A GraphiQL link here would be ideal. It will save your query and inputs when you share the link. Otherwise, include the fully query you used.

query getMeasurements(
  $accountNumber: String!,
  $first: Int!,
  $utilityFilters: [UtilityFiltersInput!],
  $startOn: Date,
  $endOn: Date,
  $startAt: DateTime,
  $endAt: DateTime,
  $timezone: String,
  $cursor: String
) {
  account(accountNumber: $accountNumber) {
    properties {
      id
      measurements(
        first: $first,
        utilityFilters: $utilityFilters,
        startOn: $startOn,
        endOn: $endOn,
        startAt: $startAt,
        endAt: $endAt,
        timezone: $timezone,
        after: $cursor
    ) {
        edges {
          node {
            value
            unit
            ... on IntervalMeasurementType {
              startAt
              endAt
              __typename
            }
            metaData {
              statistics {
                costExclTax {
                  costCurrency
                  estimatedAmount
                  __typename
                }
                value
                description
                label
                type
                __typename
              }
              __typename
            }
            __typename
          }
          __typename
        }
        pageInfo {
          hasNextPage
          hasPreviousPage
          startCursor
          endCursor
          __typename
        }
        __typename
      }
      __typename
    }
    __typename
  }
}

Input variables

This part is the most important. Each Kraken has its own Account instances, its own valid marketSupplyPointIds, and its own Cost of Usage implementation.

We will be unable to reproduce your output without these inputs.

{
  "accountNumber": "A-F523797D",
  "first": 1000,
  "startAt": "2024-10-01T00:00:00.000",
  "endAt": "2024-10-07T00:00:00.000",
  "timezone": "Europe/London",
  "utilityFilters": [
    {
      "electricityFilters": {
        "readingFrequencyType": "DAY_INTERVAL",
        "marketSupplyPointId": "2700008749510",
        "readingDirection": "GENERATION",
        "deviceId": "30-EB-5A-FF-FF-E0-91-E8"
      }
    }
  ]
}

Providing us with the following will be enough for us to create a valid input:

  1. Account number or a link to the account on your Support Site
  2. marketSupplyPointId
  3. startAt
  4. endAt
  5. readingDirection
  6. registerId if applicable
  7. deviceId if applicable


Consistency

Does your query give the expected output with a different account and marketSupplyPointId? Providing an example of working inputs will greatly help Kraken developers because we can compare the differences between the two accounts and supply points.


Cost of usage

Measurements invokes Kraken's charging and costing domain to calculate cost of usage on measurements. The charging and costing/billing team for your client likely has more to offer with respect to cost of usage issues. It's worth flagging for the Measurements team; however, the fix for cost of usage bugs likely will come from developers in the charging and costing domain.