Webhooks
SSH key collection sessions support these webhook events:
| Event | When it fires |
|---|---|
new_connection | A user connects to the collection session. |
key_collected | SSHVerify collects a public key from the connection. |
status_changed | The session status changes, for example from pending to completed. |
If a webhook has an empty events list, all collection events trigger it.
Common payload fields
Section titled “Common payload fields”Every collection event payload contains:
| Field | Description |
|---|---|
collect_session_id | ID of the collection session. |
collect_session_external_id | Optional external ID configured on the session. |
collect_session_connection_identifier | SSH username used to connect to the session. |
These fields are nested inside the shared webhook envelope described in Webhooks.
new_connection
Section titled “new_connection”The new_connection payload includes connection metadata:
{ "collect_session_id": "session_id", "collect_session_external_id": "user_123", "collect_session_connection_identifier": "connection_identifier", "collect_session_connection_id": "connection_id", "ip_address": "203.0.113.10", "client_version": "SSH-2.0-OpenSSH_9.6"}key_collected
Section titled “key_collected”The key_collected payload includes the collected key and fingerprints:
{ "collect_session_id": "session_id", "collect_session_external_id": "user_123", "collect_session_connection_identifier": "connection_identifier", "collect_session_connection_id": "connection_id", "collect_session_key_id": "key_id", "public_key_ssh": "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAA...", "public_key_pem": "-----BEGIN PUBLIC KEY-----\n...\n-----END PUBLIC KEY-----", "public_key_md5": "MD5:...", "public_key_sha256": "SHA256:...", "public_key_algorithm": "ssh-ed25519"}status_changed
Section titled “status_changed”The status_changed payload includes the new session status:
{ "collect_session_id": "session_id", "collect_session_external_id": "user_123", "collect_session_connection_identifier": "connection_identifier", "collect_session_status": "completed"}