v2
Swagger 2.02026-08-01331211921.0 KBSSH
Add a new SSH key
Adds a new SSH public key to the specified user account and returns the resulting key.
Example:
$ curl -X POST -H "Content-Type: application/json" -d '{"key": "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIKqP3Cr632C2dNhhgKVcon4ldUSAeKiku2yP9O9/bDtY user@myhost"}' https://api.bitbucket.org/2.0/users/{ed08f5e1-605b-4f4a-aee4-6c97628a673e}/ssh-keys
post/users/{selected_user}/ssh-keys
Query parameters
expires_onstring
The date or date-time of when the key will expire, in ISO-8601 format. Example: YYYY-MM-DDTHH:mm:ss.sssZ
Request body
Response
The newly created SSH key.