Metrics

Update a billable metric

Changed on

Partially update metric fields. Code and aggregation_type are immutable.

patch/api/v1/metrics/{metric_id}

Request

  • The document declares no server URL.
  • Auth
    HTTP bearer

Path parameters

metric_idstring MeteroidId required
Example:bm_7n42DGM5Tflk9n8mt7Fhc7

Metric ID

Request body

descriptionstring nullable
namestring nullable

Response

Metric updated

aggregation_keystring nullable
aggregation_type'COUNT' | 'LATEST' | 'MAX' | 'MIN' | 'MEAN' | 'SUM' | 'COUNT_DISTINCT' required
archived_atstring date-time nullable
codestring required
created_atstring date-time required
descriptionstring nullable
idstring MeteroidId required
namestring required
product_family_idstring MeteroidId required
product_idstring MeteroidId
usage_group_keystring nullable

Example response

{
  "id": "bm_7n42DGM5Tflk9n8mt7Fhc7",
  "product_family_id": "pf_7n42DGM5Tflk9n8mt7Fhc7",
  "product_id": "prd_7n42DGM5Tflk9n8mt7Fhc7"
}

Changes

    • breaking

      removed subschema #2 subschema #3 from the //// request property oneOf list

    • breaking

      added to the //// response property oneOf list for the response status

    • info

      added DOUBLE LINKED discriminator mapping keys to the //// request property

    • info

      request discriminator property name changed for //// request property from discriminator to type

    • info

      added to the //// request property oneOf list

    • info

      added DOUBLE LINKED discriminator mapping keys to the //// response property for the response status

    • info

      response discriminator property name changed for //// response property from discriminator to type for the response status

    • info

      removed subschema #2 subschema #3 from the //// response property oneOf list for the response status

    • warning

      added the new TOO_MANY_REQUESTS enum value to the response property for the response status

    • warning

      added the new TOO_MANY_REQUESTS enum value to the response property for the response status

    • warning

      added the new TOO_MANY_REQUESTS enum value to the response property for the response status

    • info

      added the non-success response with the status