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

# List Farms

> Returns farm information associated with the workspace. The information includes farm ID and name



## OpenAPI

````yaml /api-reference/openapi.json get /private-api/v1/{workspace_id}/farms
openapi: 3.1.0
info:
  title: Nonce Private API
  description: |-
    Nonce Private API documentation - Internal endpoints for system integration

    Generated by NestJS Swagger Module with nestjs-zod
    Scope: Private API endpoints only (/private-api/*)
    Do not edit this file manually - regenerate with: pnpm run docs:openapi
  version: 1.0.0
  contact: {}
servers:
  - url: https://api.nonce.app
    description: Production server
security: []
tags: []
paths:
  /private-api/v1/{workspace_id}/farms:
    get:
      tags:
        - Private API
        - Workspace
      summary: List Farms
      description: >-
        Returns farm information associated with the workspace. The information
        includes farm ID and name
      operationId: ListFarms
      parameters:
        - name: workspace_id
          required: true
          in: path
          schema:
            type: string
        - name: page
          required: false
          in: query
          description: 'Page number (default: 1)'
          schema:
            minimum: 1
            example: 1
            type: number
        - name: pageSize
          required: false
          in: query
          description: 'Number of items per page (default: 10, max: 10000)'
          schema:
            minimum: 1
            maximum: 10000
            example: 10
            type: number
      responses:
        '200':
          description: Successfully retrieved farms
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                    example: true
                    description: Indicates if the request was successful
                  data:
                    type: array
                    description: Array of items
                    items:
                      type: object
                      properties:
                        id:
                          type: string
                          description: Farm Id (uuid generated by nonce system)
                          example: xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
                        name:
                          description: Farm Name
                          example: Farm Name
                          type:
                            - string
                            - 'null'
                        description:
                          description: Farm Description
                          example: Main mining facility
                          type:
                            - string
                            - 'null'
                        location:
                          description: Farm Location
                          example: Texas, US
                          type:
                            - string
                            - 'null'
                        workspace_id:
                          type: string
                          description: Workspace Id
                          example: org_xxxxxxxxxxxxxxxxxxxxxxxxxxx
                        status:
                          type: string
                          enum:
                            - running
                            - shutdown
                            - leasing
                            - maintenance
                            - decommissioning
                            - decommissioned
                          description: Farm operational status
                          example: running
                        archived:
                          type: boolean
                          description: Whether the farm is archived
                          example: false
                        hosting_fee:
                          description: Hosting fee (electricity price) in USD per kWh
                          example: 0.065
                          type:
                            - number
                            - 'null'
                      required:
                        - id
                        - name
                        - description
                        - location
                        - workspace_id
                        - status
                        - archived
                        - hosting_fee
                      title: Farm
                  pagination:
                    type: object
                    description: Pagination metadata
                    properties:
                      total:
                        type: number
                        example: 50
                        description: Total number of items
                      limit:
                        type: number
                        example: 10
                        description: Maximum number of items per page
                      offset:
                        type: number
                        example: 0
                        description: Number of items to skip
                      hasNext:
                        type: boolean
                        example: true
                        description: Whether there are more items after this page
                      hasPrevious:
                        type: boolean
                        example: false
                        description: Whether there are items before this page
                    required:
                      - total
                      - limit
                      - offset
                      - hasNext
                      - hasPrevious
                  error:
                    type: 'null'
                    example: null
                    description: Error object (null on success)
                required:
                  - success
                  - data
                  - pagination
                  - error
        '400':
          description: Bad Request - Invalid parameters
          content:
            application/json:
              schema:
                type: object
                properties:
                  statusCode:
                    type: number
                    description: HTTP status code
                    example: 400
                  message:
                    type: string
                    description: Error message
                    example: Invalid request parameters
                  error:
                    type: string
                    description: Error type
                    example: Bad Request
                required:
                  - statusCode
                  - message
                  - error
        '401':
          description: Unauthorized - Invalid or missing API key
          content:
            application/json:
              schema:
                type: object
                properties:
                  statusCode:
                    type: number
                    description: HTTP status code
                    example: 401
                  message:
                    type: string
                    description: Error message
                    example: Invalid or missing API key
                  error:
                    type: string
                    description: Error type
                    example: Unauthorized
                required:
                  - statusCode
                  - message
                  - error
        '403':
          description: Forbidden - Valid API key but insufficient permissions
          content:
            application/json:
              schema:
                type: object
                properties:
                  statusCode:
                    type: number
                    description: HTTP status code
                    example: 403
                  message:
                    type: string
                    description: Error message
                    example: Access denied to workspace
                  error:
                    type: string
                    description: Error type
                    example: Forbidden
                required:
                  - statusCode
                  - message
                  - error
      security:
        - clerk-api-key: []
components:
  securitySchemes:
    clerk-api-key:
      scheme: bearer
      bearerFormat: API Key
      type: http
      description: Clerk Machine API Key for authentication

````