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

# Get a cluster's cost estimate (bearer twin)

> A cluster's latest cost snapshot with its daily trend and namespace allocation, in the caller's display currency, or its readiness when no estimate exists yet (`ankra cost cluster`). Bearer-PAT twin of the browser route of the same name under /org; the console's session cookie is not accepted here and the browser route answers a token with a login redirect.



## OpenAPI

````yaml https://platform.ankra.app/openapi.json get /api/v1/org/clusters/{cluster_id}/cost
openapi: 3.1.0
info:
  title: FastAPI
  version: 0.1.0
servers:
  - url: https://platform.ankra.app
security: []
paths:
  /api/v1/org/clusters/{cluster_id}/cost:
    get:
      tags:
        - Cost
        - cli
      summary: Get a cluster's cost estimate (bearer twin)
      description: >-
        A cluster's latest cost snapshot with its daily trend and namespace
        allocation, in the caller's display currency, or its readiness when no
        estimate exists yet (`ankra cost cluster`). Bearer-PAT twin of the
        browser route of the same name under /org; the console's session cookie
        is not accepted here and the browser route answers a token with a login
        redirect.
      operationId: cluster_cost_api_v1_org_clusters_get
      parameters:
        - description: PAT organisation override.
          in: header
          name: x-ankra-organisation-id
          required: false
          schema:
            type: string
        - in: path
          name: cluster_id
          required: true
          schema:
            format: uuid
            type: string
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ClusterCostResponse'
          description: Successful response
        '400':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ContractDetailError'
          description: >-
            Missing or malformed Authorization header, or business validation
            error
        '401':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ContractDetailError'
          description: Unknown, expired, or revoked API token
        '403':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ContractDetailError'
          description: >-
            Token may not use this surface (MCP-scoped token or service account
            restriction)
        '404':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ContractDetailError'
          description: Cluster not found in the token's organisation
        '422':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
          description: Request validation error
        '500':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ContractDetailError'
          description: Internal server error
      security:
        - BearerAuth: []
components:
  schemas:
    ClusterCostResponse:
      properties:
        has_data:
          type: boolean
        namespaces:
          items:
            $ref: '#/components/schemas/NamespaceCost'
          type: array
        readiness:
          $ref: '#/components/schemas/CostReadiness'
        summary:
          anyOf:
            - $ref: '#/components/schemas/ClusterCostSummary'
            - type: 'null'
        trend:
          items:
            $ref: '#/components/schemas/CostTrendPoint'
          type: array
      required:
        - has_data
        - summary
        - trend
        - namespaces
        - readiness
      title: ClusterCostResponse
      type: object
    ContractDetailError:
      example:
        detail: Cluster not found
      properties:
        detail:
          oneOf:
            - type: string
            - additionalProperties: true
              properties: {}
              type: object
      required:
        - detail
      type: object
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          title: Detail
          type: array
      title: HTTPValidationError
      type: object
    NamespaceCost:
      properties:
        allocated_compute_monthly_cents:
          type: integer
        allocated_hourly_cents:
          type: integer
        allocated_monthly_cents:
          type: integer
        allocated_storage_monthly_cents:
          type: integer
        allocation_source:
          type: string
        cpu_share:
          type: number
        memory_share:
          type: number
        namespace:
          type: string
        stack_id:
          anyOf:
            - format: uuid
              type: string
            - type: 'null'
      required:
        - namespace
        - stack_id
        - allocated_hourly_cents
        - allocated_monthly_cents
        - allocated_compute_monthly_cents
        - allocated_storage_monthly_cents
        - cpu_share
        - memory_share
        - allocation_source
      title: NamespaceCost
      type: object
    CostReadiness:
      properties:
        cluster_online:
          type: boolean
        has_cloud_credential:
          type: boolean
        nodes_synced:
          type: boolean
        pricing_available:
          type: boolean
        provider:
          anyOf:
            - type: string
            - type: 'null'
        state:
          type: string
      required:
        - state
        - provider
        - has_cloud_credential
        - nodes_synced
        - cluster_online
        - pricing_available
      title: CostReadiness
      type: object
    ClusterCostSummary:
      properties:
        applied_discount_pct:
          type: number
        compute_on_demand_cents:
          type: integer
        compute_spot_cents:
          type: integer
        confidence_level:
          type: string
        control_plane_cents:
          type: integer
        coverage_incomplete:
          type: boolean
        currency:
          type: string
        hourly_cost_cents:
          type: integer
        idle_hourly_cents:
          type: integer
        infrastructure_cents:
          type: integer
        is_estimated:
          type: boolean
        month_to_date_cents:
          type: integer
        monthly_cost_estimate_cents:
          type: integer
        network_cents:
          type: integer
        on_demand_node_count:
          type: integer
        priced_node_count:
          type: integer
        projected_month_end_cents:
          type: integer
        provider:
          type: string
        snapshot_at:
          format: date-time
          type: string
        spot_node_count:
          type: integer
        storage_cents:
          type: integer
        storage_volume_count:
          type: integer
        total_node_count:
          type: integer
        unallocated_hourly_cents:
          type: integer
        unpriced_volume_count:
          type: integer
      required:
        - provider
        - currency
        - total_node_count
        - priced_node_count
        - coverage_incomplete
        - hourly_cost_cents
        - monthly_cost_estimate_cents
        - month_to_date_cents
        - projected_month_end_cents
        - confidence_level
        - is_estimated
        - snapshot_at
        - compute_on_demand_cents
        - compute_spot_cents
        - storage_cents
        - network_cents
        - control_plane_cents
        - infrastructure_cents
        - idle_hourly_cents
        - unallocated_hourly_cents
        - spot_node_count
        - on_demand_node_count
        - storage_volume_count
        - unpriced_volume_count
        - applied_discount_pct
      title: ClusterCostSummary
      type: object
    CostTrendPoint:
      properties:
        day:
          format: date-time
          type: string
        monthly_cost_estimate_cents:
          type: integer
      required:
        - day
        - monthly_cost_estimate_cents
      title: CostTrendPoint
      type: object
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          title: Location
          type: array
        msg:
          title: Message
          type: string
        type:
          title: Error Type
          type: string
      required:
        - loc
        - msg
        - type
      title: ValidationError
      type: object
  securitySchemes:
    BearerAuth:
      bearerFormat: PAT
      scheme: bearer
      type: http

````