PATCH
/
api
/
v1
/
ssh
/
hosts
/
{sshHostId}
cURL
curl --request PATCH \
  --url https://us.infisical.com/api/v1/ssh/hosts/{sshHostId} \
  --header 'Content-Type: application/json' \
  --data '{
  "hostname": "<string>",
  "alias": "<string>",
  "userCertTtl": "<string>",
  "hostCertTtl": "<string>",
  "loginMappings": [
    {
      "loginUser": "<string>",
      "allowedPrincipals": {
        "usernames": [
          "<string>"
        ],
        "groups": [
          "<string>"
        ]
      }
    }
  ]
}'
{
  "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "projectId": "<string>",
  "hostname": "<string>",
  "alias": "<string>",
  "userCertTtl": "<string>",
  "hostCertTtl": "<string>",
  "userSshCaId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "hostSshCaId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "loginMappings": [
    {
      "loginUser": "<string>",
      "allowedPrincipals": {
        "usernames": [
          "<string>"
        ],
        "groups": [
          "<string>"
        ]
      },
      "source": "host"
    }
  ]
}

Path Parameters

sshHostId
string
required

The ID of the SSH host to update.

Body

application/json
hostname
string

The hostname of the SSH host to update to.

Minimum length: 1
alias
string

The alias for the SSH host to update to.

Maximum length: 64
userCertTtl
string

The time to live for user certificates issued under this host to update to.

hostCertTtl
string

The time to live for host certificates issued under this host to update to.

loginMappings
object[]

A list of login mappings for the SSH host. Each login mapping contains a login user and a list of corresponding allowed principals being usernames of users or groups slugs in the Infisical SSH project.

Response

Default Response

id
string<uuid>
required
projectId
string
required
hostname
string
required
userCertTtl
string
required
hostCertTtl
string
required
userSshCaId
string<uuid>
required
hostSshCaId
string<uuid>
required
loginMappings
object[]
required
alias
string | null