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

# Get SSH settings

> Whether Direct SSH is on, and the host, port, user and command to connect.

Returns the computer's [Direct SSH](/guides/ssh.md) settings. When SSH is on, `ssh_command` is the command to connect, `ssh -p <port> root@<host>`. The keys themselves are never returned.

Direct SSH is for Linux computers. Owners and editors of the workspace can read it.

> [!NOTE]
>
> Use `ipv4_port`. Port 22 on `ipv4_host` is not your computer.

After SSH is turned off, the last port and command can still be returned. Check `enabled` before you use them.

If the computer moves to another server, its host and port can change, so read them again rather than caching them.


## OpenAPI

````yaml GET /computers/{id}/ssh
openapi: 3.1.0
info:
  title: Orgo API
  description: >-
    Launch cloud computers that AI agents can control and interact with. Create
    workspaces, provision computers, and control them programmatically.
  version: 2.0.0
  contact:
    name: Orgo Support
    email: spencer@orgo.ai
    url: https://orgo.ai
servers:
  - url: https://www.orgo.ai/api
    description: Production
security:
  - bearerAuth: []
tags:
  - name: Support
    description: >-
      Orgo’s support agent, for programs: ask how to do something in Orgo and
      get an answer with full URLs and copyable commands.
  - name: Account
    description: >-
      Account capacity: how many computers an account may run, and adding or
      giving back more.
  - name: Agent accounts
    description: >-
      Accounts an AI agent makes for itself, and the claim link a person uses to
      take one over.
  - name: Clients
    description: >-
      Run Orgo for your clients from your own app: a workspace and scoped key
      each, billed to you or to them.
  - name: Workspaces
    description: Organize computers into named workspaces
  - name: Computers
    description: Provision and manage virtual computers
  - name: Computer Lifecycle
    description: Start, stop, and restart computers
  - name: Computer Actions
    description: Control mouse, keyboard, and execute commands
  - name: Screens
    description: >-
      More than one desktop on a single computer. Each screen is its own X
      server with its own cursor and window manager, so an agent working on one
      cannot disturb another.
  - name: Files
    description: Upload and download files
  - name: Templates
    description: Author, build, and launch reproducible computers from templates
  - name: Chat
    description: Run an agent on a computer through OpenAI-compatible chat completions.
paths:
  /computers/{id}/ssh:
    get:
      tags:
        - Computers
      summary: Get SSH settings
      description: >-
        Returns whether Direct SSH is on and the host, port, user and command to
        connect. Direct SSH is for Linux computers; on Windows, Android and
        iPhone computers this answers with `enabled: false`. Owners and editors
        can read it; view only members and share link guests cannot.
      operationId: getComputerSsh
      parameters:
        - name: id
          in: path
          required: true
          description: Computer ID. Accepts the computer's UUID or its `instance_id`.
          schema:
            type: string
      responses:
        '200':
          description: SSH settings
          content:
            application/json:
              schema:
                type: object
                properties:
                  enabled:
                    type: boolean
                    description: Whether SSH is on.
                  authorized_key_set:
                    type: boolean
                    description: >-
                      Whether a public key is saved. The keys themselves are
                      never returned.
                  ipv4_host:
                    type:
                      - string
                      - 'null'
                    description: >-
                      The address to connect to: the server the computer runs
                      on.
                  ipv4_port:
                    type:
                      - integer
                      - 'null'
                    description: >-
                      The computer's SSH port. Null until SSH has been turned on
                      once. It is kept after SSH is turned off, so check
                      `enabled`.
                  ipv6_address:
                    type:
                      - string
                      - 'null'
                    description: Always null for now.
                  ssh_user:
                    type: string
                    description: >-
                      The user to log in as: `root` on Linux. Can be absent on
                      some dedicated computers.
                  ssh_command:
                    type:
                      - string
                      - 'null'
                    description: >-
                      The command to connect, `ssh -p <port> root@<host>`. Null
                      until SSH has been turned on once. It is still filled in
                      after SSH is turned off, so check `enabled` before you use
                      it.
              example:
                enabled: true
                authorized_key_set: true
                ipv4_host: 203.0.113.10
                ipv4_port: 20314
                ipv6_address: null
                ssh_user: root
                ssh_command: ssh -p 20314 root@203.0.113.10
        '400':
          description: Direct SSH isn't available on this Mac.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
              example:
                error: Direct SSH isn’t supported on macOS computers.
                code: SSH_UNSUPPORTED_OS
        '401':
          $ref: '#/components/responses/Unauthorized'
        '402':
          $ref: '#/components/responses/TrialInactive'
        '403':
          description: >-
            A share link guest, a view only member, someone outside the
            computer's workspace, or an API key scoped to another workspace.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
              examples:
                view-only:
                  summary: View only member
                  value:
                    error: >-
                      This workspace is view-only. Ask the owner for write
                      access (workspace_read_only).
                no-access:
                  summary: Not in the workspace
                  value:
                    error: You do not have access to this workspace.
                scoped-key:
                  summary: Key for another workspace
                  value:
                    error: >-
                      This API key cannot access this workspace
                      (workspace_scope_mismatch).
                guest:
                  summary: Share link guest
                  value:
                    error: Sign up to create your own workspace.
                    code: GUEST_RESTRICTED
        '404':
          description: No computer with this ID.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
              example:
                error: Desktop not found
        '409':
          description: >-
            The computer is asleep. SSH connects once it wakes. The body also
            carries `enabled` and `authorized_key_set`, with the connection
            fields null.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
              example:
                error: This computer is asleep. SSH connects once it wakes.
                code: computer_asleep
        '500':
          description: The lookup failed.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
              example:
                error: Failed to read SSH
        '503':
          $ref: '#/components/responses/AuthUnavailable'
components:
  schemas:
    Error:
      type: object
      description: >-
        The base error body. Every failure carries `error`; individual endpoints
        add the fields named in the schemas below.
      required:
        - error
      properties:
        error:
          type: string
          description: Human-readable message.
          example: Access denied
        code:
          type: string
          description: >-
            Machine-readable reason. Present on the failures that define one,
            absent otherwise.
  responses:
    Unauthorized:
      description: 'No usable credential. Send `Authorization: Bearer $ORGO_API_KEY`.'
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          examples:
            invalid-key:
              summary: The key is not one of yours
              value:
                error: Invalid API key
            no-credential:
              summary: No key and no session
              value:
                error: Authentication required
    TrialInactive:
      description: >-
        The computer is a free trial computer whose trial is no longer active,
        or it is paid for by its own subscription or dedicated purchase and that
        payment has lapsed.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          examples:
            trial:
              summary: Trial no longer active
              value:
                error: Choose a plan to continue.
            payment:
              summary: The computer's own payment has lapsed
              value:
                error: Manage this computer’s payment in Account → Usage.
    AuthUnavailable:
      description: >-
        Orgo could not verify the credential because of a server-side fault,
        such as a database outage. Retry after `Retry-After`. Do not rotate the
        key.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            error: >-
              Service temporarily unavailable. The database is not accepting
              requests. Retry shortly.
      headers:
        Retry-After:
          description: Seconds to wait before retrying. Always `5`.
          schema:
            type: string
            example: '5'
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: API key authentication. Get your key at orgo.ai/workspaces

````

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