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

# Start browser pairing for a machine

> Unauthenticated, rate-limited per client address. Returns an RFC 8628-style device code for polling and a user code that the signed-in user approves at verificationUriComplete, choosing the team. Pairing again with the same installId after revocation restores the same machine. All responses use Cache-Control: no-store.



## OpenAPI

````yaml /openapi/v1.json post /hosts/pairings
openapi: 3.1.0
info:
  title: Felan API
  description: >-
    Team-scoped access to Felan sessions, members, invitations, integrations,
    environments, environment variables, automations, skills, custom subagents,
    and inbound events.
  version: 1.0.0
  contact:
    name: Felan Support
    url: https://felan.ai
servers:
  - url: https://app.felan.ai/api/v1
    description: Production
security:
  - bearerAuth: []
tags:
  - name: Hosts
  - name: Teams
  - name: Integrations
  - name: Environments
  - name: Environment Variables
  - name: Automations
  - name: Skills
  - name: Subagents
  - name: Sessions
  - name: Events
  - name: OpenAPI
paths:
  /hosts/pairings:
    post:
      tags:
        - Hosts
      summary: Start browser pairing for a machine
      description: >-
        Unauthenticated, rate-limited per client address. Returns an RFC
        8628-style device code for polling and a user code that the signed-in
        user approves at verificationUriComplete, choosing the team. Pairing
        again with the same installId after revocation restores the same
        machine. All responses use Cache-Control: no-store.
      operationId: startHostPairing
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/HostTokenRequest'
      responses:
        '200':
          description: >-
            Pairing started; poll POST /hosts/pairings/poll no faster than
            interval seconds until expiresAt.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HostPairingStartResponse'
        '400':
          description: Malformed JSON or invalid registration.
        '426':
          description: >-
            unsupported_schema: protocol or row schema version is not supported;
            supported lists accepted versions.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HostPairingError'
        '429':
          description: 'rate_limited: retry with backoff according to Retry-After.'
          headers:
            Retry-After:
              description: Seconds until the rate limit resets.
              schema:
                type: integer
                minimum: 1
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HostPairingError'
        '500':
          description: Retry with backoff.
      security: []
components:
  schemas:
    HostTokenRequest:
      type: object
      required:
        - installId
        - name
        - daemonVersion
        - protocol
        - rowSchemaVersion
      properties:
        installId:
          type: string
          pattern: >-
            ^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$
        name:
          type: string
          minLength: 1
          maxLength: 128
          x-maxBytes: 128
        daemonVersion:
          type: string
          minLength: 1
          maxLength: 128
          x-maxBytes: 128
        protocol:
          type: number
          const: 1
        rowSchemaVersion:
          type: integer
          minimum: 0
          maximum: 9007199254740991
    HostPairingStartResponse:
      type: object
      required:
        - deviceCode
        - userCode
        - verificationUri
        - verificationUriComplete
        - interval
        - expiresAt
      properties:
        deviceCode:
          type: string
          pattern: ^[A-Za-z0-9_-]{32,128}$
          description: Secret polling code. Never display or log it.
        userCode:
          type: string
          pattern: ^[BCDFGHJKLMNPQRSTVWXZ]{4}-[BCDFGHJKLMNPQRSTVWXZ]{4}$
          description: Code the user confirms in the browser.
        verificationUri:
          type: string
          minLength: 1
          maxLength: 2048
          x-maxBytes: 2048
        verificationUriComplete:
          type: string
          minLength: 1
          maxLength: 2048
          x-maxBytes: 2048
        interval:
          type: integer
          minimum: 1
          maximum: 60
          description: Minimum seconds between polls.
        expiresAt:
          type: integer
          minimum: 0
          maximum: 9007199254740991
          description: Expiry as Unix epoch milliseconds.
    HostPairingError:
      type: object
      required:
        - code
        - message
      properties:
        code:
          type: string
          enum:
            - authorization_pending
            - slow_down
            - access_denied
            - expired_token
            - unsupported_schema
            - rate_limited
        message:
          type: string
          minLength: 0
          maxLength: 4096
          x-maxBytes: 4096
          pattern: "^[^\0-\x1F\x7F-\x9F]*$"
        supported:
          type: object
          required:
            - protocol
            - rowSchemaVersion
          properties:
            protocol:
              type: array
              items:
                type: integer
                minimum: 0
                maximum: 9007199254740991
            rowSchemaVersion:
              type: array
              items:
                type: integer
                minimum: 0
                maximum: 9007199254740991
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: Team API key. Current keys retain the bzy_team_ compatibility prefix.

````

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