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

# Read the finance report

> Investor-style profit and loss: revenue, costs, net result and margin, the previous period for comparison, revenue and cost breakdowns, a daily (or monthly, beyond 92 days) series, highlights and current cash. Requires the opt-in finance:read scope and costs 20 rows. Defaults to the last 30 days. Results refresh about once a minute.



## OpenAPI

````yaml /virtual-airlines/openapi.json get /api/v1/va/finance
openapi: 3.1.0
info:
  title: FlyHub Virtual Airlines API
  version: '2026-10-25'
  description: >-
    Read-only airline information and Discord notification payloads for Virtual
    Airlines integrations. Resources are scoped to the airline that issued the
    fhva_live bearer key.
servers:
  - url: https://flyhub.app
    description: FlyHub production API
security: []
tags:
  - name: public-api
    description: >-
      Read-only resources for airline websites, dashboards, and private
      integrations.
    x-group: Public VA API
  - name: discord-webhooks
    description: Discord notification payloads for selected airline activity.
    x-group: Discord webhooks
paths:
  /api/v1/va/finance:
    get:
      tags:
        - public-api
      summary: Read the finance report
      description: >-
        Investor-style profit and loss: revenue, costs, net result and margin,
        the previous period for comparison, revenue and cost breakdowns, a daily
        (or monthly, beyond 92 days) series, highlights and current cash.
        Requires the opt-in finance:read scope and costs 20 rows. Defaults to
        the last 30 days. Results refresh about once a minute.
      operationId: getVaFinance
      parameters:
        - name: period
          in: query
          description: >-
            Reporting period. month is the current UTC calendar month to date;
            7d to 365d are rolling; all starts at the first recorded
            transaction. Defaults to 30d.
          schema:
            type: string
            enum:
              - all
              - month
              - 7d
              - 30d
              - 90d
              - 365d
            default: 30d
        - $ref: '#/components/parameters/IfNoneMatch'
      responses:
        '200':
          $ref: '#/components/responses/FinanceResponse'
        '304':
          $ref: '#/components/responses/NotModified'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
        '429':
          $ref: '#/components/responses/RateLimited'
        '503':
          $ref: '#/components/responses/ServiceUnavailable'
      security:
        - vaApiKey: []
components:
  parameters:
    IfNoneMatch:
      name: If-None-Match
      in: header
      description: >-
        ETag from an earlier response. When the body is unchanged the API
        returns 304 and charges one row.
      schema:
        type: string
  responses:
    FinanceResponse:
      description: Airline finance report.
      headers:
        Cache-Control:
          $ref: '#/components/headers/CacheControl'
        X-RateLimit-Limit:
          $ref: '#/components/headers/RateLimitLimit'
        X-RateLimit-Remaining:
          $ref: '#/components/headers/RateLimitRemaining'
        X-RateLimit-Reset:
          $ref: '#/components/headers/RateLimitReset'
        ETag:
          $ref: '#/components/headers/ETag'
        X-RateLimit-Row-Limit:
          $ref: '#/components/headers/RateLimitRowLimit'
        X-RateLimit-Row-Remaining:
          $ref: '#/components/headers/RateLimitRowRemaining'
        X-RateLimit-Row-Reset:
          $ref: '#/components/headers/RateLimitRowReset'
        X-RateLimit-Row-Cost:
          $ref: '#/components/headers/RateLimitRowCost'
      content:
        application/json:
          schema:
            type: object
            required:
              - data
              - meta
            properties:
              data:
                $ref: '#/components/schemas/Finance'
              meta:
                $ref: '#/components/schemas/Meta'
    NotModified:
      description: >-
        The body has not changed since the ETag sent in If-None-Match. Costs one
        row.
    Unauthorized:
      description: A valid FlyHub VA API key is required.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    Forbidden:
      description: The key does not include the required read scope.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    RateLimited:
      description: The request rate is temporarily limited.
      headers:
        Retry-After:
          $ref: '#/components/headers/RetryAfter'
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    ServiceUnavailable:
      description: FlyHub cannot safely serve the request at the moment.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
  headers:
    CacheControl:
      description: >-
        The response is private and should not be stored as a shared cache
        entry.
      schema:
        type: string
        example: private, no-store
    RateLimitLimit:
      description: Requests allowed in the current public API window.
      schema:
        type: integer
    RateLimitRemaining:
      description: Requests remaining in the current public API window.
      schema:
        type: integer
    RateLimitReset:
      description: ISO timestamp when the public API request window resets.
      schema:
        type: string
        format: date-time
    ETag:
      description: >-
        Weak validator of the response body. Send it back in If-None-Match; an
        unchanged body returns 304 and costs one row.
      schema:
        type: string
        example: W/"q8ZK2yE0p3l6tB0mXx1cWQ9dTnR4aSfh"
    RateLimitRowLimit:
      description: Rows one API key can read per hour.
      schema:
        type: integer
    RateLimitRowRemaining:
      description: Rows left this hour, the lower of the key and its airline allowance.
      schema:
        type: integer
    RateLimitRowReset:
      description: ISO timestamp when the hourly row window resets.
      schema:
        type: string
        format: date-time
    RateLimitRowCost:
      description: >-
        Rows this response consumed: the rows returned for a list, a fixed cost
        for single objects, 1 for a 304.
      schema:
        type: integer
    RetryAfter:
      description: Seconds to wait before retrying after a rate limit.
      schema:
        type: integer
  schemas:
    Finance:
      type: object
      description: >-
        Profit and loss from the airline ledger, in the same group scope as
        statistics: a flagship key covers the whole group. Launch capital and
        group transfers are excluded because they are not performance.
      required:
        - period
        - currency
        - from
        - to
        - bucket
        - summary
        - previous
        - cashBalance
        - revenueBreakdown
        - costBreakdown
        - series
        - highlights
      properties:
        period:
          type: string
          enum:
            - all
            - month
            - 7d
            - 30d
            - 90d
            - 365d
        currency:
          type: string
          const: FH$
        from:
          type: string
          format: date
          description: First UTC day included.
        to:
          type: string
          format: date
          description: Last UTC day included (today).
        bucket:
          type: string
          enum:
            - day
            - month
          description: 'Size of each series entry: days up to 92 days, months beyond.'
        summary:
          type: object
          required:
            - revenue
            - costs
            - netResult
            - operatingMarginPercent
          properties:
            revenue:
              type: number
              description: Amount in FH$.
            costs:
              type: number
              description: Amount in FH$.
            netResult:
              type: number
              description: Revenue minus costs, in FH$.
            operatingMarginPercent:
              type:
                - number
                - 'null'
              description: >-
                Net result as a share of revenue; null when there was no
                revenue.
        previous:
          type:
            - object
            - 'null'
          required:
            - revenue
            - costs
            - netResult
            - operatingMarginPercent
          properties:
            revenue:
              type: number
              description: Amount in FH$.
            costs:
              type: number
              description: Amount in FH$.
            netResult:
              type: number
              description: Revenue minus costs, in FH$.
            operatingMarginPercent:
              type:
                - number
                - 'null'
              description: >-
                Net result as a share of revenue; null when there was no
                revenue.
          description: >-
            The same length of time just before; month compares with the same
            days of last month. Null for all.
        cashBalance:
          type:
            - number
            - 'null'
          description: Current airline cash in FH$ (shared across a group).
        revenueBreakdown:
          type: array
          items:
            type: object
            required:
              - key
              - label
              - amount
              - sharePercent
            properties:
              key:
                type: string
              label:
                type: string
              amount:
                type: number
                description: Amount in FH$.
              sharePercent:
                type: number
                description: Share of total revenue or costs.
          description: >-
            Revenue by source, largest first: passengers, cargo, ancillary,
            contracts.
        costBreakdown:
          type: array
          items:
            type: object
            required:
              - key
              - label
              - amount
              - sharePercent
            properties:
              key:
                type: string
              label:
                type: string
              amount:
                type: number
                description: Amount in FH$.
              sharePercent:
                type: number
                description: Share of total revenue or costs.
          description: >-
            Costs by group, largest first: fleet, fuel, routes and schedules,
            airports, crew/handling/service, operating programs, penalties and
            incidents, other.
        series:
          type: array
          items:
            type: object
            required:
              - period
              - revenue
              - costs
              - netResult
            properties:
              period:
                type: string
                description: YYYY-MM-DD for day buckets, YYYY-MM for month buckets.
              revenue:
                type: number
                description: Amount in FH$.
              costs:
                type: number
                description: Amount in FH$.
              netResult:
                type: number
                description: Amount in FH$.
        highlights:
          type: object
          required:
            - bestDay
            - worstDay
            - profitableDays
            - totalDays
            - averageDailyResult
          properties:
            bestDay:
              type:
                - object
                - 'null'
              required:
                - date
                - netResult
              properties:
                date:
                  type: string
                  format: date
                netResult:
                  type: number
                  description: Amount in FH$.
            worstDay:
              type:
                - object
                - 'null'
              required:
                - date
                - netResult
              properties:
                date:
                  type: string
                  format: date
                netResult:
                  type: number
                  description: Amount in FH$.
            profitableDays:
              type: integer
              minimum: 0
            totalDays:
              type: integer
              minimum: 1
            averageDailyResult:
              type: number
              description: Amount in FH$.
    Meta:
      type: object
      required:
        - apiVersion
      properties:
        apiVersion:
          type: string
          example: '2026-10-25'
    Error:
      type: object
      required:
        - error
      properties:
        error:
          type: object
          required:
            - code
            - message
          properties:
            code:
              type: string
            message:
              type: string
  securitySchemes:
    vaApiKey:
      type: http
      scheme: bearer
      bearerFormat: fhva_live_...
      description: >-
        A read-only FlyHub VA API key created from Ownership. Keep it on your
        integration server.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.