---
title: "PATCH /api/v1/app-connections/ssh/{connectionId}"
method: PATCH
path: "/api/v1/app-connections/ssh/{connectionId}"
tags: ["App Connections"]
---

# PATCH /api/v1/app-connections/ssh/{connectionId}

`PATCH /api/v1/app-connections/ssh/{connectionId}`

Update the specified SSH Connection.

## Path parameters

- `connectionId` string, uuid, required

## Request body

- object
  - `credentials` union — The credentials used to connect with SSH.
    - object
      - `host` string, required — The hostname or IP address of the SSH server.
      - `port` integer, required — The port number of the SSH server (default: 22).
      - `username` string, required — The username for SSH authentication.
      - `password` string, required — The password for SSH authentication (required when authMethod is 'password').
    - object
      - `host` string, required — The hostname or IP address of the SSH server.
      - `port` integer, required — The port number of the SSH server (default: 22).
      - `username` string, required — The username for SSH authentication.
      - `privateKey` string, required — The private key in PEM format for SSH authentication (required when authMethod is 'ssh-key').
      - `passphrase` string — The passphrase for the private key, if encrypted (optional, only for 'ssh-key' authMethod).
  - `configuration` object
    - `blockedUsers` string — A comma-separated list of usernames that are blocked from being used in operations like secret rotation (e.g., 'root,admin,ubuntu').
  - `name` string — The updated name of the SSH Connection. Must be slug-friendly.
  - `description` string, nullable — The updated description of the SSH Connection.
  - `isPlatformManagedCredentials` false — Not supported for SSH Connections.
  - `gatewayId` string, uuid, nullable — The Gateway ID to use for this connection.
  - `gatewayPoolId` string, uuid, nullable — The Gateway Pool ID to use for this connection.
  - `isAutoRotationEnabled` false — Not supported for SSH Connections.
  - `rotation` 'null', nullable — Not supported for SSH Connections.

## Response `200`

Default Response

- object
  - `appConnection` union, required
    - object
      - `id` string, uuid, required
      - `name` string, required
      - `description` string, nullable
      - `version` number
      - `orgId` string, uuid, required
      - `createdAt` string, date-time, required
      - `updatedAt` string, date-time, required
      - `isPlatformManagedCredentials` boolean, nullable
      - `gatewayId` string, uuid, nullable
      - `projectId` string, nullable
      - `isAutoRotationEnabled` boolean
      - `gatewayPoolId` string, uuid, nullable
      - `rotation` object — The credential rotation configuration, if configured.
        - `lastRotationMessage` string, nullable — The message from the last rotation attempt.
        - `rotationInterval` number, required — The interval in days between credential rotations.
        - `nextRotationAt` string, date-time, nullable — The next scheduled rotation time.
        - `rotationStatus` 'success' | 'failed', required — The status of the last rotation attempt.
        - `rotateAtUtc` object, required — The UTC time of day at which rotation should occur.
          - `hours` number, required — The hour (0-23) at which to rotate.
          - `minutes` number, required — The minute (0-59) at which to rotate.
      - `credentialsHash` string
      - `project` object, nullable
        - `name` string, required
        - `id` string, required
        - `type` string, required
        - `slug` string, required
      - `app` 'ssh', required
      - `method` 'password', required
      - `credentials` object, required
        - `host` string, required
        - `port` number, required
        - `username` string, required
      - `configuration` object
        - `blockedUsers` string — A comma-separated list of usernames that are blocked from being used in operations like secret rotation (e.g., 'root,admin,ubuntu').
    - object
      - `id` string, uuid, required
      - `name` string, required
      - `description` string, nullable
      - `version` number
      - `orgId` string, uuid, required
      - `createdAt` string, date-time, required
      - `updatedAt` string, date-time, required
      - `isPlatformManagedCredentials` boolean, nullable
      - `gatewayId` string, uuid, nullable
      - `projectId` string, nullable
      - `isAutoRotationEnabled` boolean
      - `gatewayPoolId` string, uuid, nullable
      - `rotation` object — The credential rotation configuration, if configured.
        - `lastRotationMessage` string, nullable — The message from the last rotation attempt.
        - `rotationInterval` number, required — The interval in days between credential rotations.
        - `nextRotationAt` string, date-time, nullable — The next scheduled rotation time.
        - `rotationStatus` 'success' | 'failed', required — The status of the last rotation attempt.
        - `rotateAtUtc` object, required — The UTC time of day at which rotation should occur.
          - `hours` number, required — The hour (0-23) at which to rotate.
          - `minutes` number, required — The minute (0-59) at which to rotate.
      - `credentialsHash` string
      - `project` object, nullable
        - `name` string, required
        - `id` string, required
        - `type` string, required
        - `slug` string, required
      - `app` 'ssh', required
      - `method` 'ssh-key', required
      - `credentials` object, required
        - `host` string, required
        - `port` number, required
        - `username` string, required
      - `configuration` object
        - `blockedUsers` string — A comma-separated list of usernames that are blocked from being used in operations like secret rotation (e.g., 'root,admin,ubuntu').

## Other responses

- `400` — Default Response
- `401` — Default Response
- `403` — Default Response
- `404` — Default Response
- `422` — Default Response
- `500` — Default Response

---

[API](https://skmtc.net/infisical/apis/infisical-api.md) · [All operations](https://skmtc.net/infisical/apis/infisical-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/infisical/infisical-api/versions/f10a4f8c1d41/schema)
