HomeDocumentationAPI Reference
Log In
API Reference

Remove or deduplicate an SSH key across all hosts

Performs an SSH key response action (remove or deduplicate) across all hosts and users where the key is deployed. Requires the responder role. Creates one order per affected host, each containing one action per affected user. Can be disabled server-wide with SF_DISABLE_RESPONSES and at the node level with SF_NODE_DISABLE_RESPONSES. For 'remove' actions, a last-key protection safety check denies the request with HTTP 409 if any affected host would be left with zero SSH keys known to Sandfly; set allow_last_key_removal=true in the request body to override.

Path Params
int32
required

SSH public key ID (integer) from SSH Hunter.

string
enum
required

Action to perform: 'sshkey_remove' deletes all copies, 'sshkey_dedup' removes duplicates leaving one copy.

Allowed:
Body Params

Optional JSON body for an SSH key response action request. An empty body is equivalent to setting the allow_last_key_removal property to false.

boolean

When true, override the last-key protection safety check. Without this flag set, a 'sshkey_remove' action that would leave any affected host with zero SSH keys known to Sandfly is denied with HTTP 409. Has no effect for the 'sshkey_dedup' action.

Responses

Language
Credentials
Bearer
JWT
URL
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json