---
title: "Announce that an MCP client has launched with this key. Fire-and-forget; records presence, not usage."
method: POST
path: "/api/v1/connection/handshake"
tags: ["connection"]
---

# Announce that an MCP client has launched with this key. Fire-and-forget; records presence, not usage.

`POST /api/v1/connection/handshake`

Called automatically by @pathmode/mcp-server 1.9.0+ once per launch, on the MCP oninitialized callback. Stamps client_first_seen_at (first time) and client_seen_at, and emits exactly one event, mcp_client_launched; never touches last_used_at, because a client starting up is not an agent doing work. Body is optional and all fields are untrusted client-reported strings. Clients must treat failures as non-fatal.

## Request body

- object
  - `client` string — Client name reported by the MCP client (e.g. claude-code). Truncated to 80 chars; used only as an analytics dimension.
  - `clientVersion` string — Client version reported by the MCP client. Truncated to 80 chars.
  - `serverVersion` string — Version of @pathmode/mcp-server making the call. Truncated to 80 chars.

## Response `200`

OK — handshake recorded

- object

## Other responses

- `401` — Invalid/expired API key, or no Bearer key and no valid session cookie

## Changes

- **2026-08-23** `155c812b368b` — 1 info
  - added the optional property `details` to the response with the `401` status
- **2026-08-22** `2ca78ad5552f` — 1 info
  - endpoint added

[Change history](https://skmtc.dev/pathmode/apis/pathmode-api/changes/api/v1/connection/handshake/post.md)

---

[API](https://skmtc.dev/pathmode/apis/pathmode-api.md) · [All operations](https://skmtc.dev/pathmode/apis/pathmode-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/pathmode/pathmode-api/revisions/e419abb0a327/schema)
