Query feature cost

Query the cost of a feature.

post

Path Parameters

featureIdstringrequired

ULID (Universally Unique Lexicographically Sortable Identifier).

Match pattern:^[0-7][0-9A-HJKMNP-TV-Z]{25}$

Example:01G65Z755AFWAKHE12NY0CQ9FH

Body

application/json

MeterQueryRequest

A meter query request.

fromstring(date-time)

The start of the period the usage is queried from.

Example:2023-01-01T01:01:01.001Z

tostring(date-time)

The end of the period the usage is queried to.

Example:2023-01-01T01:01:01.001Z

granularitystring

The size of the time buckets to group the usage into.
If not specified, the usage is aggregated over the entire period.

Allowed values:PT1MPT1HP1DP1M

time_zonestring

The value is the name of the time zone as defined in the IANA Time Zone Database (http://www.iana.org/time-zones).
The time zone is used to determine the start and end of the time buckets.
If not specified, the UTC timezone will be used.

Default:UTC

group_by_dimensionsarray[string]

The dimensions to group the results by.

<= 100 items

Example:["model","type"]

filtersobject

Filters to apply to the query.

Show Child Parameters

Response

application/json

The request has succeeded.

FeatureCostQueryResult

Result of a feature cost query.

fromstring(date-time)

Start of the queried period.

Example:2023-01-01T01:01:01.001Z

tostring(date-time)

End of the queried period.

Example:2023-01-01T01:01:01.001Z

dataarray[object]required

A row in the result of a feature cost query.

Show Child Parameters
post/openmeter/features/{featureId}/cost/query

Body

{ "from": "2023-01-01T00:00:00Z", "to": "2023-01-02T00:00:00Z", "granularity": "P1D", "time_zone": "UTC" }
 
application/json

OpenMeter Tax

Tax codes are used to calculate taxes for customers.

Create tax code

post

Body

application/json

CreateTaxCodeRequest

TaxCode create request.

namestringrequired

Display name of the resource.

Between 1 and 256 characters.

>= 1 characters<= 256 characters

descriptionstring

Optional description of the resource.

Maximum 1024 characters.

<= 1024 characters

labelsobject

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:{"env":"test"}

keystringrequired

A key is a unique string that is used to identify a resource.

Match pattern:^[a-z0-9]+(?:_[a-z0-9]+)*$

>= 1 characters<= 64 characters

Example:resource_key

app_mappingsarray[object]required

Mapping of app types to tax codes.

Show Child Parameters

Response

application/json

TaxCode created response.

BillingTaxCode

Tax codes by provider.

idstringrequiredread-only

ULID (Universally Unique Lexicographically Sortable Identifier).

Match pattern:^[0-7][0-9A-HJKMNP-TV-Z]{25}$

Example:01G65Z755AFWAKHE12NY0CQ9FH

namestringrequired

Display name of the resource.

Between 1 and 256 characters.

>= 1 characters<= 256 characters

descriptionstring

Optional description of the resource.

Maximum 1024 characters.

<= 1024 characters

labelsobject

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:{"env":"test"}

created_atstring(date-time)read-only

An ISO-8601 timestamp representation of entity creation date.

Example:2023-01-01T01:01:01.001Z

updated_atstring(date-time)read-only

An ISO-8601 timestamp representation of entity last update date.

Example:2023-01-01T01:01:01.001Z

deleted_atstring(date-time)read-only

An ISO-8601 timestamp representation of entity deletion date.

Example:2023-01-01T01:01:01.001Z

keystringrequired

A key is a unique string that is used to identify a resource.

Match pattern:^[a-z0-9]+(?:_[a-z0-9]+)*$

>= 1 characters<= 64 characters

Example:resource_key

app_mappingsarray[object]required

Mapping of app types to tax codes.

Show Child Parameters
post/openmeter/tax-codes

Body

{ "name": "name", "key": "resource_key", "app_mappings": [ { "app_type": "sandbox", "tax_code": "tax_code" } ] }
 
application/json

List tax codes

get

Query Parameters

pageobject

Determines which page of the collection to retrieve.

Show Child Parameters
include_deletedboolean

Include deleted tax codes in the response.

Response

application/json

Page paginated response.

TaxCodePagePaginatedResponse

Page paginated response.

dataarray[object]required

Tax codes by provider.

Show Child Parameters
metaobjectrequired

returns the pagination information

Show Child Parameters
get/openmeter/tax-codes
 
application/json

Get tax code

get

Path Parameters

taxCodeIdstringrequired

ULID (Universally Unique Lexicographically Sortable Identifier).

Match pattern:^[0-7][0-9A-HJKMNP-TV-Z]{25}$

Example:01G65Z755AFWAKHE12NY0CQ9FH

Response

application/json

TaxCode response.

BillingTaxCode

Tax codes by provider.

idstringrequiredread-only

ULID (Universally Unique Lexicographically Sortable Identifier).

Match pattern:^[0-7][0-9A-HJKMNP-TV-Z]{25}$

Example:01G65Z755AFWAKHE12NY0CQ9FH

namestringrequired

Display name of the resource.

Between 1 and 256 characters.

>= 1 characters<= 256 characters

descriptionstring

Optional description of the resource.

Maximum 1024 characters.

<= 1024 characters

labelsobject

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:{"env":"test"}

created_atstring(date-time)read-only

An ISO-8601 timestamp representation of entity creation date.

Example:2023-01-01T01:01:01.001Z

updated_atstring(date-time)read-only

An ISO-8601 timestamp representation of entity last update date.

Example:2023-01-01T01:01:01.001Z

deleted_atstring(date-time)read-only

An ISO-8601 timestamp representation of entity deletion date.

Example:2023-01-01T01:01:01.001Z

keystringrequired

A key is a unique string that is used to identify a resource.

Match pattern:^[a-z0-9]+(?:_[a-z0-9]+)*$

>= 1 characters<= 64 characters

Example:resource_key

app_mappingsarray[object]required

Mapping of app types to tax codes.

Show Child Parameters
get/openmeter/tax-codes/{taxCodeId}
 
application/json