Orb

Orb Metrics API

The Metrics API from Orb — 2 operation(s) for metrics.

Documentation

Specifications

Other Resources

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/orb-billing-metrics-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no email required.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

orb-billing-metrics-api-openapi.yml Raw ↑
openapi: 3.1.0
info:
  title: Orb Alerts Metrics API
  description: Orb is a usage-based billing and metering platform. The REST API ingests timestamped usage events, models customers, plans, prices, items, and billable metrics, manages subscriptions, and automates invoicing, credit ledgers, coupons, alerts, and webhooks. All endpoints are served over HTTPS at https://api.withorb.com/v1 and authenticated with a Bearer API key.
  termsOfService: https://www.withorb.com/legal/terms-of-service
  contact:
    name: Orb Support
    url: https://www.withorb.com
    email: team@withorb.com
  version: '1.0'
servers:
- url: https://api.withorb.com/v1
  description: Orb production API
security:
- bearerAuth: []
tags:
- name: Metrics
paths:
  /metrics:
    get:
      operationId: listMetrics
      tags:
      - Metrics
      summary: List metrics
      parameters:
      - $ref: '#/components/parameters/Cursor'
      - $ref: '#/components/parameters/Limit'
      responses:
        '200':
          description: A paginated list of billable metrics.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/MetricList'
    post:
      operationId: createMetric
      tags:
      - Metrics
      summary: Create metric
      description: Creates a billable metric defined by a SQL expression over events.
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/MetricCreate'
      responses:
        '201':
          description: The newly created metric.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Metric'
  /metrics/{metric_id}:
    parameters:
    - name: metric_id
      in: path
      required: true
      schema:
        type: string
    get:
      operationId: getMetric
      tags:
      - Metrics
      summary: Get metric
      responses:
        '200':
          description: The requested metric.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Metric'
components:
  parameters:
    Limit:
      name: limit
      in: query
      description: The number of items to return per page (default 20, max 100).
      schema:
        type: integer
        default: 20
        maximum: 100
    Cursor:
      name: cursor
      in: query
      description: An opaque cursor for the next page of results.
      schema:
        type: string
  schemas:
    PaginationMetadata:
      type: object
      properties:
        has_more:
          type: boolean
        next_cursor:
          type: string
          nullable: true
    Metric:
      type: object
      properties:
        id:
          type: string
        name:
          type: string
        description:
          type: string
          nullable: true
        status:
          type: string
          enum:
          - active
          - draft
          - archived
        item:
          $ref: '#/components/schemas/Item'
        metadata:
          type: object
          additionalProperties:
            type: string
    Item:
      type: object
      properties:
        id:
          type: string
        name:
          type: string
        external_connections:
          type: array
          items:
            type: object
            properties:
              external_connection_name:
                type: string
              external_entity_id:
                type: string
        created_at:
          type: string
          format: date-time
    MetricCreate:
      type: object
      required:
      - name
      - sql
      - item_id
      properties:
        name:
          type: string
        description:
          type: string
        sql:
          type: string
          description: The SQL expression that aggregates events into a billable quantity.
        item_id:
          type: string
    MetricList:
      type: object
      properties:
        data:
          type: array
          items:
            $ref: '#/components/schemas/Metric'
        pagination_metadata:
          $ref: '#/components/schemas/PaginationMetadata'
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: 'Authenticate with an Orb API key sent as a Bearer token in the Authorization header: `Authorization: Bearer <ORB_API_KEY>`.'