Skip to main content
POST
/
ssh_keys
Create a new SSH Key
curl --request POST \
  --url https://api.cloud.onidel.com/ssh_keys \
  --header 'Authorization: <api-key>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "team_id": "c1d45377-b2a9-4407-ab8d-6909c34dfaac",
  "name": "Production Server Key",
  "ssh_key": "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQC... user@hostname"
}
'
{
  "ssh_key": {
    "id": "a3f2e5d8-1234-4abc-9876-543210fedcba",
    "created": "2024-01-15T10:30:00Z",
    "name": "Production Server Key",
    "ssh_key": "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQC... user@hostname"
  }
}

Authorizations

Authorization
string
header
required

Provide the value as: Token <your-api-token>

Body

application/json
team_id
string<uuid>
required
Example:

"c1d45377-b2a9-4407-ab8d-6909c34dfaac"

name
string
required
Example:

"Production Server Key"

ssh_key
string
required
Example:

"ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQC... user@hostname"

Response

SSH key created successfully

ssh_key
object