> ## Documentation Index
> Fetch the complete documentation index at: https://docs.lighton.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Get a company's month-to-date storage cost

> Instance-admin view of `GET /api/v3/storage/cost` for a specific company: the storage charge accrued so far this month, the quantities behind it (`peak_bytes`, `free_gib`, `billable_gib`), and the same footprint priced at the pay-as-you-go allowance.

**Authorization:** the authenticated user must have instance-level company-view permission (SysAdmin, Account Manager, or DPO Admin).



## OpenAPI

````yaml /api-reference/openapi-v3-instance.yaml get /api/v3/instance/companies/{id}/storage/cost
openapi: 3.1.0
info:
  title: LightOn API
  version: 3.15.0 (v3-instance)
  description: >-
    LightOn gives you an API to search, parse, and ingest documents at scale.
    Build knowledge-retrieval pipelines without managing vector databases or OCR
    models.
servers:
  - url: https://paradigm.lighton.ai
security: []
tags:
  - name: Models
    description: Operations about AI models
  - name: Workspaces
    description: Operations about workspaces
  - name: Users
    description: Operations about users
  - name: User Groups
    description: Operations about user groups
  - name: Companies
    description: Operations about companies
paths:
  /api/v3/instance/companies/{id}/storage/cost:
    get:
      tags:
        - Usage
      summary: Get a company's month-to-date storage cost
      description: >-
        Instance-admin view of `GET /api/v3/storage/cost` for a specific
        company: the storage charge accrued so far this month, the quantities
        behind it (`peak_bytes`, `free_gib`, `billable_gib`), and the same
        footprint priced at the pay-as-you-go allowance.


        **Authorization:** the authenticated user must have instance-level
        company-view permission (SysAdmin, Account Manager, or DPO Admin).
      operationId: api_v3_instance_companies_storage_cost_retrieve
      parameters:
        - in: path
          name: id
          schema:
            type: integer
          required: true
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CompanyStorageCostResponse'
          description: ''
        '401':
          description: Unauthenticated - missing or invalid API key.
        '403':
          description: Forbidden - instance company-view permission required.
        '404':
          description: Not Found - company does not exist.
        '503':
          description: >-
            API is under maintenance. Check `GET /api/v3/system/status` for
            active periods and retry.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ServiceMaintenance503'
      security:
        - bearerAuth: []
components:
  schemas:
    CompanyStorageCostResponse:
      type: object
      properties:
        currency:
          type: string
          description: ISO 4217 code applied to `cost`
        period_start:
          type: string
          format: date
          description: First day of the current billing month (UTC)
        cost:
          type: string
          format: decimal
          description: Storage charge accrued so far this month, in `currency`
        billable_gib:
          type: integer
          minimum: 0
          description: >-
            Whole GiB billed: the month's peak rounded up, minus `free_gib`. 0
            when within the allowance
        free_gib:
          type: integer
          minimum: 0
          description: Storage allowance included at no charge, in GiB
        peak_bytes:
          type: integer
          minimum: 0
          description: >-
            Highest storage footprint reached this month, in bytes. The charge
            follows the peak, not the current footprint — deleting files
            mid-month does not reduce it
        pay_as_you_go:
          allOf:
            - $ref: '#/components/schemas/StorageCostOnPlanResponse'
          description: >-
            The same `peak_bytes` priced against the pay-as-you-go allowance, so
            a company on a larger plan can be shown what downgrading would cost.
            Identical to the top-level figures while every tier shares one
            allowance
      required:
        - billable_gib
        - cost
        - currency
        - free_gib
        - pay_as_you_go
        - peak_bytes
        - period_start
    ServiceMaintenance503:
      type: object
      description: >-
        Returned by the maintenance middleware when the requested endpoint is
        blocked.
      required:
        - detail
        - error
        - mode
      properties:
        detail:
          type: string
          example: System is under maintenance.
        error:
          type: string
          example: service_maintenance
        mode:
          type: string
          enum:
            - full_shutdown
            - warning_banner
          description: >-
            `full_shutdown` blocks all traffic; `warning_banner` also blocks and
            shows a dismissible toast.
        reason:
          type: string
          description: Operator-supplied maintenance reason, if any.
        started_at:
          type: string
          format: date-time
        endpoint_category_names:
          type: array
          items:
            type: string
          description: >-
            Non-empty only for category-scoped periods. Empty means all
            endpoints are affected.
    StorageCostOnPlanResponse:
      type: object
      properties:
        cost:
          type: string
          format: decimal
          description: What this month's storage would cost on that plan
        billable_gib:
          type: integer
          minimum: 0
          description: Whole GiB that would be billed on that plan
        free_gib:
          type: integer
          minimum: 0
          description: That plan's included storage allowance, in GiB
      required:
        - billable_gib
        - cost
        - free_gib
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        Bearer authentication header of the form `Bearer <token>`, where
        `<token>` is your auth token.

````