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

# List Tunnels Endpoint

> List all active tunnels for the current user.

## Rate Limit

300 requests per 60 seconds per user.


## OpenAPI

````yaml https://api.primeintellect.ai/openapi.json get /api/v1/tunnel
openapi: 3.1.0
info:
  title: PI API
  version: 0.1.0
servers:
  - url: https://api.primeintellect.ai
security: []
paths:
  /api/v1/tunnel:
    get:
      tags:
        - Tunnel
      summary: List Tunnels Endpoint
      description: List all active tunnels for the current user.
      operationId: list_tunnels_endpoint_api_v1_tunnel_get
      parameters:
        - name: teamId
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Teamid
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TunnelListResponse'
        '401':
          description: Authorization failed
        '422':
          description: Invalid request data
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
      security:
        - HTTPBearer: []
components:
  schemas:
    TunnelListResponse:
      properties:
        tunnels:
          items:
            $ref: '#/components/schemas/TunnelStatusResponse'
          type: array
          title: Tunnels
          description: List of active tunnels
        total:
          type: integer
          title: Total
          description: Total number of tunnels
      type: object
      required:
        - total
      title: TunnelListResponse
      description: Response containing list of tunnels.
    ErrorResponse:
      properties:
        errors:
          items:
            $ref: '#/components/schemas/ErrorDetail'
          type: array
          title: Errors
      type: object
      required:
        - errors
      title: ErrorResponse
    TunnelStatusResponse:
      properties:
        tunnel_id:
          type: string
          title: Tunnel Id
          description: Unique tunnel identifier
        name:
          anyOf:
            - type: string
            - type: 'null'
          title: Name
          description: Friendly name if set
        status:
          $ref: '#/components/schemas/TunnelStatus'
          description: Current tunnel status
        hostname:
          type: string
          title: Hostname
          description: Tunnel hostname
        url:
          type: string
          title: Url
          description: Full HTTPS URL
        created_at:
          type: string
          format: date-time
          title: Created At
          description: Tunnel creation time
        connected_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Connected At
          description: When the client connected
        expires_at:
          type: string
          format: date-time
          title: Expires At
          description: Token expiration time
        user_id:
          type: string
          title: User Id
          description: Owner user ID
        team_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Team Id
          description: Team ID if applicable
      type: object
      required:
        - tunnel_id
        - status
        - hostname
        - url
        - created_at
        - expires_at
        - user_id
      title: TunnelStatusResponse
      description: Response containing tunnel status information.
    ErrorDetail:
      properties:
        param:
          type: string
          title: Param
        details:
          type: string
          title: Details
      type: object
      required:
        - param
        - details
      title: ErrorDetail
    TunnelStatus:
      type: string
      enum:
        - pending
        - connected
        - disconnected
        - expired
      title: TunnelStatus
  securitySchemes:
    HTTPBearer:
      type: http
      scheme: bearer

````