End an MCP session

DELETE https://{controlplane_path}/api/1/rest/public/platform_mcp/mcp

Overview

This API terminates an active MCP session and releases any associated server-side resources.

Call this endpoint when your client has finished using the Platform MCP Server. After the session is terminated, the Mcp-Session-Id is no longer valid and any open SSE stream for the session is closed.

Prerequisites

Request

DELETE https://{controlplane_path}/api/1/rest/public/platform_mcp/mcp[/{toolset}]
      

Path parameters

Key Description
controlplane_path Required. The path to the SnapLogic control plane: elastic.snaplogic.com
For the UAT or EMEA control plane, substitute the name for elastic. For example:
  • uat.elastic.snaplogic.com
  • emea.snaplogic.com
toolset Optional. The toolset used when the session was initialized (pygen or platform). Must match the toolset path used in the original POST request.

Request headers

Key Type Description
Authorization String Required. SLToken or HTTP Basic credentials.
Mcp-Session-Id String Required. The session identifier to terminate.

Request body

None.

Response

A successful request returns 200 OK with no response body.

HTTP status codes:

Key Description
200 OK The session was terminated successfully.
400 Bad Request The toolset value in the URL path is not recognized.
401 Unauthorized The request is missing a valid Authorization header.
502 Bad Gateway The Platform MCP Server is unreachable.

Examples

DELETE https://cdn.elastic.snaplogic.com/api/1/rest/public/platform_mcp/mcp
Authorization: SLToken <your_token>
Mcp-Session-Id: <session_id>