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

# Get infrastructure limits

> Returns the account's infrastructure tier, its limits, and current usage against them. Storage values are in bytes.



## OpenAPI

````yaml https://api.tinfoil.sh/openapi.yaml get /api/infrastructure/limits
openapi: 3.2.0
info:
  title: Tinfoil Controlplane API
  version: 0.1.0
  description: >-
    Manage inference API keys, read usage and invoices, and manage Tinfoil
    confidential containers, their configuration, and the organization resources
    they use. Authenticate with an admin API key sent as a bearer token.
servers:
  - url: https://api.tinfoil.sh
security:
  - apiKey: []
tags:
  - name: Account
    description: >-
      The identity and organization behind the API key, and the token usage and
      invoices of the personal account or organization.
  - name: API keys
    parent: Account
    description: Inference API keys of the personal account or organization.
  - name: Containers
    description: Create, deploy, and stop confidential containers.
  - name: Container updates
    description: >-
      Move a container to a new release, and promote or cancel an update that is
      held for review.
  - name: Projects
    description: Groups of containers deployed from the same config source.
  - name: Volumes
    description: Encrypted persistent volumes that attach to containers.
  - name: Secrets
    description: >-
      Organization secrets available to containers, and secrets scoped to a
      single GitHub repository.
  - name: Access
    description: >-
      SSH public keys for attested SSH access to containers, custom domains that
      route to containers, and credentials for pulling images from private
      registries. An organization can store one ecr and one custom registry
      connection, each identified by its hostname.
  - name: GitHub & models
    description: >-
      Repository config and image builds through the Tinfoil GitHub app, and
      packaging Hugging Face models for use in containers. Packaging models
      requires a GPU entitlement or model access for the organization.
  - name: Config registry
    description: >-
      Publish tinfoil-config.yml revisions, read published configs, and resolve
      the endorsements that let clients verify them.
  - name: Bunkers
    description: Bunker owner keys and owner attestation.
paths:
  /api/infrastructure/limits:
    get:
      tags:
        - Account
      summary: Get infrastructure limits
      description: >-
        Returns the account's infrastructure tier, its limits, and current usage
        against them. Storage values are in bytes.
      operationId: getInfrastructureLimits
      responses:
        '200':
          description: Tier, limits and usage
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/InfrastructureLimits'
        '401':
          $ref: '#/components/responses/Error'
          description: Missing or invalid credentials
        '403':
          $ref: '#/components/responses/Error'
          description: Not permitted
        '404':
          $ref: '#/components/responses/Error'
          description: Not found
        '500':
          $ref: '#/components/responses/Error'
          description: Server error
      security:
        - apiKey:
            - infrastructure.limits.read
components:
  schemas:
    InfrastructureLimits:
      type: object
      required:
        - owner_type
        - tier
        - tier_source
        - lifetime_paid_dollars
        - tiers
        - limits
        - usage
        - sandboxes_enabled
        - workspace_sizes_gb
        - default_workspace_size_gb
      properties:
        owner_type:
          type: string
          enum:
            - organization
            - user
        tier:
          type: integer
          description: The account's current tier.
        tier_source:
          type: string
          enum:
            - spend
            - gpu_access
            - pinned
          description: >-
            What sets the tier. spend is the lifetime paid total, gpu_access is
            an organization with GPU access, and pinned is set by Tinfoil.
        lifetime_paid_dollars:
          type: number
          description: Lifetime paid total in US dollars.
        tiers:
          type: array
          description: Every tier and the limits it grants.
          items:
            type: object
            required:
              - tier
              - name
              - min_lifetime_paid_dollars
              - max_containers
              - max_sandboxes
              - max_storage_bytes
            properties:
              tier:
                type: integer
              name:
                type: string
              min_lifetime_paid_dollars:
                type: number
              max_containers:
                type: integer
              max_sandboxes:
                type: integer
              max_storage_bytes:
                type: integer
                format: int64
        limits:
          type: object
          description: >-
            The limits that apply. They can be higher than the tier's when
            Tinfoil has raised them for the account.
          required:
            - max_containers
            - max_sandboxes
            - max_storage_bytes
          properties:
            max_containers:
              type: integer
            max_sandboxes:
              type: integer
            max_storage_bytes:
              type: integer
              format: int64
        usage:
          type: object
          description: What currently counts against the limits.
          required:
            - containers
            - sandboxes
            - storage_bytes
          properties:
            containers:
              type: integer
            sandboxes:
              type: integer
            storage_bytes:
              type: integer
              format: int64
        sandboxes_enabled:
          type: boolean
          description: Whether the account can create Bunkers. Enabled by default.
        workspace_sizes_gb:
          type: array
          description: Bunker workspace sizes that can be chosen, in GB.
          items:
            type: integer
        default_workspace_size_gb:
          type: integer
    Error:
      type: object
      required:
        - error
      properties:
        error:
          type: string
          description: Human-readable error message.
        code:
          type: string
          description: Stable machine-readable error code.
      additionalProperties: true
  responses:
    Error:
      description: The request failed.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
  securitySchemes:
    apiKey:
      type: http
      scheme: bearer
      description: >-
        An admin API key. Personal admin keys reach the API key, billing and
        Account endpoints for the creator's personal account; the other
        endpoints need an organization admin key. Security requirement entries
        list the permission a scoped key needs for the operation.

````

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