diff --git a/openapi.yaml b/openapi.yaml index 04296fa5..2a388718 100644 --- a/openapi.yaml +++ b/openapi.yaml @@ -114,6 +114,8 @@ tags: description: List and manage capabilities for MCP Servers. - name: MCP Servers > User Access description: List and manage user access for MCP Servers. + - name: MCP Servers > Connections + description: List and manage user connections for MCP Servers. - name: Api-Keys description: Create, List, Retrieve, Update, and Delete your Portkey API keys. - name: Logs Export @@ -16091,6 +16093,76 @@ paths: schema: $ref: "#/components/schemas/McpServerUserAccessBulkUpdateResponse" + /mcp-servers/{mcpServerId}/connections: + servers: *ControlPlaneServers + parameters: + - name: mcpServerId + in: path + required: true + schema: + type: string + description: MCP Server ID (UUID) or slug + get: + operationId: McpServerConnections_list + tags: + - MCP Servers > Connections + summary: List MCP Server Connections + parameters: + - name: user_id + in: query + schema: + type: string + description: Optional. UUID of the user whose connections to list. If not provided, defaults to the current user for user API keys, and returns all connections on the MCP server for service API keys. + - name: workspace_id + in: query + schema: + type: string + description: Workspace ID or slug. Required when using org admin API key; optional when API key is workspace-scoped. + - name: current_page + in: query + schema: + type: integer + minimum: 0 + default: 0 + - name: page_size + in: query + schema: + type: integer + minimum: 1 + maximum: 500 + default: 100 + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/McpServerConnectionsListResponse" + delete: + operationId: McpServerConnections_delete + tags: + - MCP Servers > Connections + summary: Delete MCP Server Connection + parameters: + - name: user_id + in: query + schema: + type: string + format: uuid + description: The UUID of the user to disconnect. Required when using a service API key; optional when using a user API key (the user ID is derived from the key if not provided). + - name: workspace_id + in: query + schema: + type: string + description: Workspace ID or slug. Required when using org admin API key; optional when API key is workspace-scoped. + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/McpServerConnectionDeleteResponse" + /logs: servers: *DataPlaneServers post: @@ -37135,6 +37207,40 @@ components: type: boolean example: true + McpServerConnectionItem: + type: object + properties: + user_id: + type: string + format: uuid + connected: + type: boolean + created_at: + type: string + format: date-time + last_updated_at: + type: string + format: date-time + + McpServerConnectionsListResponse: + type: object + properties: + data: + type: array + items: + $ref: "#/components/schemas/McpServerConnectionItem" + total: + type: integer + has_more: + type: boolean + + McpServerConnectionDeleteResponse: + type: object + properties: + success: + type: boolean + example: true + security: - Portkey-Key: []