OpenAPI Specification
openapi: 3.0.3
info:
title: Octane REST Admin Measurements API
description: REST API for managing meters, customers, pricing plans, subscriptions, measurements, and real-time usage data for usage-based billing workflows. Octane enables infrastructure and SaaS companies to implement flexible pay-as-you-go billing similar to Snowflake and AWS.
version: 1.0.0
contact:
name: Octane Support
url: https://www.getoctane.io
servers:
- url: https://api.getoctane.io
description: Octane Production API
security:
- BearerApiKeyAuth: []
tags:
- name: Measurements
description: Submit usage measurements for customers
paths:
/measurements:
post:
summary: Send Measurement
description: Submit a single usage measurement for a customer.
operationId: measurementsPost
tags:
- Measurements
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/Measurement'
responses:
'200':
description: Created measurement
content:
application/json:
schema:
$ref: '#/components/schemas/Measurement'
/measurements/multi:
post:
summary: Send Batched Measurements
description: Submit multiple usage measurements in a single request.
operationId: measurementsMultiPost
tags:
- Measurements
requestBody:
required: true
content:
application/json:
schema:
type: array
items:
$ref: '#/components/schemas/Measurement'
responses:
'200':
description: Created measurements
content:
application/json:
schema:
type: array
items:
$ref: '#/components/schemas/Measurement'
components:
schemas:
Measurement:
type: object
required:
- value
properties:
id:
type: string
description: Unique identifier for the measurement.
meter_name:
type: string
description: Name of the meter this measurement belongs to.
customer_name:
type: string
description: Name of the customer this measurement belongs to.
event_name:
type: string
description: Name of the event that generated this measurement.
value:
type: number
description: The measured value.
time:
type: string
format: date-time
description: Timestamp of when the measurement occurred.
labels:
type: object
additionalProperties:
type: string
description: Key-value labels associated with the measurement.
reset_total:
type: boolean
description: Whether to reset the running total.
securitySchemes:
BearerApiKeyAuth:
type: http
scheme: bearer
description: API key passed as a Bearer token in the Authorization header.