OpenMeter Customers

Create a credit adjustment

A credit adjustment can be used to make manual adjustments to a customer's credit balance.

Supported use-cases:

  • Usage correction
post/openmeter/customers/{customerId}/credits/adjustments

Path parameters

customerIdstring required

ULID (Universally Unique Lexicographically Sortable Identifier).

Example:01G65Z755AFWAKHE12NY0CQ9FH

Request body

namestring required

Display name of the resource.

Between 1 and 256 characters.

descriptionstring

Optional description of the resource.

Maximum 1024 characters.

labelsLabels

Labels store metadata of an entity that can be used for filtering an entity list or for searching across entity types.

Keys must be of length 1-63 characters, and cannot start with "kong", "konnect", "mesh", "kic", or "_".

amountstring required

Numeric represents an arbitrary precision number.

Example request

{
  "labels": {
    "env": "test"
  },
  "currency": "USD"
}

Response

CreditAdjustment created response.

namestring required

Display name of the resource.

Between 1 and 256 characters.

descriptionstring

Optional description of the resource.

Maximum 1024 characters.

labelsLabels

Labels store metadata of an entity that can be used for filtering an entity list or for searching across entity types.

Keys must be of length 1-63 characters, and cannot start with "kong", "konnect", "mesh", "kic", or "_".

Example response

{
  "labels": {
    "env": "test"
  }
}

Changes

Changed in 2 of the 62 revisions of this API.212

  • v3bd7fb102768411See the full diff
    • removed CurrencyCode BillingCurrencyCodeCustom from the currency/allOf[BillingCurrencyCode]/ request property anyOf list

      request-property-any-of-removed

    • added CurrencyCode BillingCurrencyCodeCustom to the currency/allOf[BillingCurrencyCode]/ request property oneOf list

      request-property-one-of-added

  • v3b4f5102c436d111See the full diff
    • the currency/allOf[BillingCurrencyCode]/ request property type/format changed from string/ to /

      request-property-type-changed

    • removed CurrencyCode from the currency/allOf[BillingCurrencyCode]/ request property allOf list

      request-property-all-of-removed

    • added CurrencyCode BillingCurrencyCodeCustom to the currency/allOf[BillingCurrencyCode]/ request property anyOf list

      request-property-any-of-added