Add SSH Key
Append an SSH public key to this webspace's authorized_keys. Supports ssh-ed25519, ssh-rsa, and ecdsa-*.
Append an SSH public key to this webspace's authorized_keys. Supports ssh-ed25519, ssh-rsa, and ecdsa-*.
Required scope: webspace:manage
| Header | Required | Value |
|---|---|---|
Authorization |
Yes | Bearer YOUR_API_KEY |
Content-Type |
Yes | application/json |
| Parameter | Required | Description |
|---|---|---|
publicKey |
Yes | Full public-key line (ssh-ed25519 AAA…). |
comment |
No | Optional label (defaults to the comment in the key line). |
{
"data": {
"id": "sha256-hQ0YFLi6TKgF...",
"type": "ssh-ed25519",
"publicKey": "ssh-ed25519 AAAA...",
"comment": "my-laptop"
}
}
| Status | Code | Description |
|---|---|---|
| 400 | MISSING_PUBLIC_KEY |
publicKey is missing. |
| 400 | INVALID_PUBLIC_KEY |
Public key could not be parsed. |
curl -X POST https://hosting.site.quest/api/v1/webspaces/69e80ac1.../ssh-keys \
-H "Authorization: Bearer sq_live_..." \
-H "Content-Type: application/json" \
-d '{ "publicKey": "ssh-ed25519 AAAA... my-laptop", "comment": "my-laptop" }'
This action is also available via the webspace_add_ssh_key MCP tool.