OSS-first docs

These docs teach the open system first: contracts, generated surfaces, runtimes, governance, and incremental adoption. Studio shows up as the operating layer on top, not as the source of truth.

usage.get

Get usage records for a subject.

  • Type: operation (query)
  • Version: 1.0.0
  • Stability: stable
  • Owners: platform.metering
  • Tags: metering, usage, get
  • File: packages/libs/metering/src/contracts/index.ts
  • field.key.label
    usage.get
    field.version.label
    1.0.0
    field.type.label
    operation (query)
    field.title.label
    usage.get
    field.description.label

    Get usage records for a subject.

  • Type: operation (query)
  • Version: 1.0.0
  • Stability: stable
  • Owners: platform.metering
  • Tags: metering, usage, get
  • File: packages/libs/metering/src/contracts/index.ts
  • field.tags.label
    metering,usage,get
    field.owners.label
    platform.metering
    field.stability.label
    stable

    Get usage records for a subject.

    Goal

    View detailed usage history.

    Context

    Called to analyze usage.

    Source Definition

    import { defineCommand, defineQuery } from '@lssm-tech/lib.contracts-spec';
    import { defineSchemaModel, ScalarTypeEnum } from '@lssm-tech/lib.schema';
    
    export const GetUsageContract = defineQuery({
    	meta: {
    		key: 'usage.get',
    		version: '1.0.0',
    		stability: 'stable',
    		owners: ['platform.metering'],
    		tags: ['metering', 'usage', 'get'],
    		description: 'Get usage records for a subject.',
    		goal: 'View detailed usage history.',
    		context: 'Called to analyze usage.',
    	},
    	io: {
    		input: GetUsageInput,
    		output: GetUsageOutput,
    	},
    	policy: {
    		auth: 'user',
    	},
    });