{"id":8666,"date":"2025-04-18T16:52:47","date_gmt":"2025-04-18T08:52:47","guid":{"rendered":"https:\/\/www.wsisp.com\/helps\/8666.html"},"modified":"2025-04-18T16:52:47","modified_gmt":"2025-04-18T08:52:47","slug":"%e5%85%b3%e4%ba%8emcp-sse-%e6%9c%8d%e5%8a%a1%e5%99%a8%e7%9a%84%e5%b7%a5%e4%bd%9c%e5%8e%9f%e7%90%86","status":"publish","type":"post","link":"https:\/\/www.wsisp.com\/helps\/8666.html","title":{"rendered":"\u5173\u4e8eMCP SSE \u670d\u52a1\u5668\u7684\u5de5\u4f5c\u539f\u7406"},"content":{"rendered":"<p>\u6a21\u578b\u4e0a\u4e0b\u6587\u534f\u8bae&#xff08;Model Context Protocol&#xff0c;\u7b80\u79f0MCP&#xff09; \u662f\u4e00\u79cd\u5168\u65b0\u7684\u5f00\u653e\u534f\u8bae&#xff0c;\u4e13\u95e8\u7528\u4e8e\u6807\u51c6\u5316\u5730\u4e3a\u5927\u8bed\u8a00\u6a21\u578b&#xff08;LLMs&#xff09;\u63d0\u4f9b\u5e94\u7528\u573a\u666f\u548c\u6570\u636e\u80cc\u666f\u3002 \u4f60\u53ef\u4ee5\u628aMCP\u60f3\u8c61\u6210AI\u9886\u57df\u7684\u201cUSB-C\u63a5\u53e3\u201d&#xff0c;\u5b83\u80fd\u8ba9\u4e0d\u540c\u7684AI\u6a21\u578b\u4e0e\u5916\u90e8\u5de5\u5177\u548c\u6570\u636e\u6e90\u8f7b\u677e\u8fde\u63a5<\/p>\n<p>\u8fd1\u6765\u5b66\u4e60\u4e86\u4e00\u4e0b&#xff0c;\u5148\u662f\u4f7f\u7528stdio\u7684\u65b9\u5f0f\u53ebcursor\u505a\u4e86\u4e00\u4e2a&#xff0c;\u5b8c\u5168\u6ca1\u6709\u95ee\u9898\u3002\u4f46\u662fsse\u7684\u65b9\u5f0f\u53ebcursor \u5e72\u59cb\u7ec8\u4e0d\u6210\u529f&#xff0c; \u627e\u4e86\u4e00\u8f6e&#xff0c;\u53d1\u73b0youtube\u7684\u6559\u7a0b\u89c6\u9891\u91cc\u4e3b\u6301&#xff0c;\u4e5f\u6ca1\u6709\u641e\u5b9asse\u7684\u670d\u52a1\u5668&#xff0c;balahblah\u8bf4\u4e86\u4e00\u5806&#xff0c;\u5c31\u8981move on &#8230;.\u4e8e\u662f\u7814\u7a76\u4e86\u4e00\u4e0b\u3002<\/p>\n<p>1. \u9996\u5148MCP SSE\u662f\u57fa\u4e8ehttp\u534f\u8bae\u7684\u4e00\u4e2a\u5e94\u7528,\u670d\u52a1\u5668\u548c\u5ba2\u6237\u7aef\u4e3b\u8981\u901a\u8fc7json rc\u7684\u65b9\u5f0f\u8fdb\u884c\u6c9f\u901a\u3002<\/p>\n<p>2. MCP SSE Client\u4f1a\u53d1\u8d77\u591a\u4e2a\u8fde\u63a5&#xff0c;\u4f46\u662f\u7b2c\u4e00\u4e2a\u8fde\u63a5\u662fhttp:\/\/yourhost:port\/sse,\u00a0 \u8fd9\u4e2a\u8fde\u63a5\u662f\u6c9f\u901a\u7684\u7b2c\u4e00\u6b65&#xff0c;\u5b83\u4f1a\u4f7f\u7528chunked\u7684\u56de\u4f20\u6570\u636e&#xff0c;\u610f\u601d\u662f\u4e0d\u544a\u8bc9client\u8fd9\u4e2a\u6570\u636e\u6709\u591a\u5c11&#xff0c;\u8fd9\u6837\u5c31\u5b83\u5c31\u53ef\u4ee5\u4e00\u76f4\u8fde\u7740\u4e86\u3002 \u6240\u4ee5\u8fd9\u4e2a\u94fe\u63a5\u5c31\u662f\u4e00\u4e2a\u7528\u6765\u901a\u77e5\u7684\u94fe\u63a5\u3002\u4f60\u73b0\u5728\u5c31\u660e\u767d\u4e86\u4e3a\u4ec0\u4e48 &#xff0c;\u5c31\u53ebSSE&#xff08;Server-Sent Events )\u3002 \u5b83\u9996\u5148\u6309\u4ee5\u4e0b\u683c\u5f0f\u4fe1\u606f\u7ed9client, \u7136\u540e\u5c31\u662f\u5b9a\u65f6\u7684ping\u5305\u4e86&#xff0c; \u6bcf\u6b21\u90fd\u53ea\u662f\u4e00\u4e2achunk&#xff0c;\u4f30\u8ba1\u540e\u671fserver\u4f1a\u6709\u63a8\u9001\u4e5f\u4f1a\u4f7f\u7528\u8fd9\u4e2a\u94fe\u63a5\u901a\u77e5client.<\/p>\n<p>event: \u4e8b\u4ef6\u7684\u540d\u5b57<br \/>\ndata:  \u4e8b\u4ef6\u7684\u6570\u636e<\/p>\n<p>\u00a0 \u00a0 \u00a0 2.1 \u7b2c\u4e00\u4e2aevent\u662f,\u8fd9\u4e2a\u76f4\u63a5\u8fd4\u56de&#xff0c;\u5c31\u662f\u7ed9client\u5206\u914d\u4e00\u4e2asession_id, \u65b9\u4fbf\u540e\u9762\u591a\u4e2a\u8fde\u63a5\u8fc7\u6765\u670d\u52a1\u5668\u53ef\u4ee5\u5206\u6e05\u8c01\u548c\u8c01\u3002<\/p>\n<p>51<br \/>\nevent: endpoint<br \/>\ndata: \/messages\/?session_id&#061;07aa8f90d79a49eaad802693cdd05b5b <\/p>\n<p>\u00a0 \u00a0 \u00a0 client\u6536\u5230\u8fd9\u4e2a&#xff0c;\u5c31\u4f1a\u4ee5http:\/\/yourhost:port\/messages\/?session_id&#061;07aa8f90d79a49eaad802693cdd05b5b &#xff0c; \u65b0\u53d1\u8d77\u4e00\u4e2a\u8fde\u63a5\u53bb\u8bf7\u6c42mcp sse server<\/p>\n<p>\u00a0 \u00a0 \u00a02.2 \u7b2c\u4e8c\u4e2aevent\u662fevent: message, \u8fd9\u4e2adata \u662f\u4e00\u4e2ajson\u6765\u7684&#xff0c;\u5c31\u662f\u544a\u8bc9client&#xff0c;\u5f53\u524dmcp server\u7684\u80fd\u529b&#xff0c;\u8fd8\u6709\u670d\u52a1\u5668\u7684\u57fa\u672c\u4fe1\u606f\u3002<\/p>\n<p>124<br \/>\nevent: message<br \/>\ndata: {<br \/>\n  &#034;jsonrpc&#034;: &#034;2.0&#034;,<br \/>\n  &#034;id&#034;: 0,<br \/>\n  &#034;result&#034;: {<br \/>\n    &#034;protocolVersion&#034;: &#034;2024-11-05&#034;,<br \/>\n    &#034;capabilities&#034;: {<br \/>\n      &#034;experimental&#034;: {},<br \/>\n      &#034;prompts&#034;: {<br \/>\n        &#034;listChanged&#034;: false<br \/>\n      },<br \/>\n      &#034;resources&#034;: {<br \/>\n        &#034;subscribe&#034;: false,<br \/>\n        &#034;listChanged&#034;: false<br \/>\n      },<br \/>\n      &#034;tools&#034;: {<br \/>\n        &#034;listChanged&#034;: false<br \/>\n      }<br \/>\n    },<br \/>\n    &#034;serverInfo&#034;: {<br \/>\n      &#034;name&#034;: &#034;mem0-mcp&#034;,<br \/>\n      &#034;version&#034;: &#034;1.3.0&#034;<br \/>\n    }<br \/>\n  }<br \/>\n} <\/p>\n<p>\u00a0 \u00a0 \u00a02.3 \u7b2c\u4e09\u4e2aevent\u4e5f\u662f\u4e00\u4e2amessage , \u7528\u6765\u544a\u8bc9client \u670d\u52a1\u5668\u63d0\u4f9b\u7684tools\u6709\u54ea\u4e9b\u3002<\/p>\n<p>{<br \/>\n  &#034;jsonrpc&#034;: &#034;2.0&#034;,<br \/>\n  &#034;id&#034;: 1,<br \/>\n  &#034;result&#034;: {<br \/>\n    &#034;tools&#034;: [<br \/>\n      {<br \/>\n        &#034;name&#034;: &#034;add_coding_preference&#034;,<br \/>\n        &#034;description&#034;: &#034;Add a new coding preference to mem0. This tool stores code snippets, implementation details,\\\\n    and coding patterns for future reference. Store every code snippet. When storing code, you should include:\\\\n    &#8211; Complete code with all necessary imports and dependencies\\\\n    &#8211; Language\/framework version information (e.g., \\\\&#034;Python 3.9\\\\&#034;, \\\\&#034;React 18\\\\&#034;)\\\\n    &#8211; Full implementation context and any required setup\/configuration\\\\n    &#8211; Detailed comments explaining the logic, especially for complex sections\\\\n    &#8211; Example usage or test cases demonstrating the code\\\\n    &#8211; Any known limitations, edge cases, or performance considerations\\\\n    &#8211; Related patterns or alternative approaches\\\\n    &#8211; Links to relevant documentation or resources\\\\n    &#8211; Environment setup requirements (if applicable)\\\\n    &#8211; Error handling and debugging tips\\\\n    The preference will be indexed for semantic search and can be retrieved later using natural language queries.&#034;,<br \/>\n        &#034;inputSchema&#034;: {<br \/>\n          &#034;properties&#034;: {<br \/>\n            &#034;text&#034;: {<br \/>\n              &#034;title&#034;: &#034;Text&#034;,<br \/>\n              &#034;type&#034;: &#034;string&#034;<br \/>\n            }<br \/>\n          },<br \/>\n          &#034;required&#034;: [<br \/>\n            &#034;text&#034;<br \/>\n          ],<br \/>\n          &#034;title&#034;: &#034;add_coding_preferenceArguments&#034;,<br \/>\n          &#034;type&#034;: &#034;object&#034;<br \/>\n        }<br \/>\n      },<br \/>\n      {<br \/>\n        &#034;name&#034;: &#034;get_all_coding_preferences&#034;,<br \/>\n        &#034;description&#034;: &#034;Retrieve all stored coding preferences for the default user. Call this tool when you need \\\\n    complete context of all previously stored preferences. This is useful when:\\\\n    &#8211; You need to analyze all available code patterns\\\\n    &#8211; You want to check all stored implementation examples\\\\n    &#8211; You need to review the full history of stored solutions\\\\n    &#8211; You want to ensure no relevant information is missed\\\\n    Returns a comprehensive list of:\\\\n    &#8211; Code snippets and implementation patterns\\\\n    &#8211; Programming knowledge and best practices\\\\n    &#8211; Technical documentation and examples\\\\n    &#8211; Setup and configuration guides\\\\n    Results are returned in JSON format with metadata.&#034;,<br \/>\n        &#034;inputSchema&#034;: {<br \/>\n          &#034;properties&#034;: {},<br \/>\n          &#034;title&#034;: &#034;get_all_coding_preferencesArguments&#034;,<br \/>\n          &#034;type&#034;: &#034;object&#034;<br \/>\n        }<br \/>\n      },<br \/>\n      {<br \/>\n        &#034;name&#034;: &#034;search_coding_preferences&#034;,<br \/>\n        &#034;description&#034;: &#034;Search through stored coding preferences using semantic search. This tool should be called \\\\n    for EVERY user query to find relevant code and implementation details. It helps find:\\\\n    &#8211; Specific code implementations or patterns\\\\n    &#8211; Solutions to programming problems\\\\n    &#8211; Best practices and coding standards\\\\n    &#8211; Setup and configuration guides\\\\n    &#8211; Technical documentation and examples\\\\n    The search uses natural language understanding to find relevant matches, so you can\\\\n    describe what you&#039;re looking for in plain English. Always search the preferences before \\\\n    providing answers to ensure you leverage existing knowledge.&#034;,<br \/>\n        &#034;inputSchema&#034;: {<br \/>\n          &#034;properties&#034;: {<br \/>\n            &#034;query&#034;: {<br \/>\n              &#034;title&#034;: &#034;Query&#034;,<br \/>\n              &#034;type&#034;: &#034;string&#034;<br \/>\n            }<br \/>\n          },<br \/>\n          &#034;required&#034;: [<br \/>\n            &#034;query&#034;<br \/>\n          ],<br \/>\n          &#034;title&#034;: &#034;search_coding_preferencesArguments&#034;,<br \/>\n          &#034;type&#034;: &#034;object&#034;<br \/>\n        }<br \/>\n      }<br \/>\n    ]<br \/>\n  }<br \/>\n} <\/p>\n<p>\u8ddf\u7740\u5c31\u662fping\u5305\u7684\u8fd4\u56de&#xff0c;\u9632\u6b62client\u6b7b\u4e86\u3002<\/p>\n<p>2d<br \/>\n: ping &#8211; 2025-03-12 08:16:23.071429&#043;00:00<\/p>\n<p>3. endpoint\u8bf7\u6c42<\/p>\n<p>\u00a0 \u00a0\u62ff\u5230endpont\u540e&#xff0c;client \u4f7f\u7528post\u7684\u8bf7\u6c42endpoint&#xff0c;\u00a0 \u8fd9\u4e2a\u53ea\u5904\u7406\u8bf7\u6c42&#xff0c;\u76ee\u524d\u770b\u00a0\u8fd4\u56de\u5219\u5728\u7b2c\u4e00\u4e2ahttp\u8fde\u63a5\u91cc\u3002<\/p>\n<p>\u7b2c\u4e8c\u4e2a\u94fe\u63a5 \u8bf7\u6c42\u5982\u4e0b&#xff1a;&#xff0c; \u8fd9\u4e2a\u8c03\u7528initialize&#xff0c;\u5bf9\u5e94\u4e0a\u9762\u7684\u7b2c\u4e00\u4e2amessage\u7684event.<\/p>\n<p>\u7b2c\u4e8c\u4e2a\u94fe\u63a5, \u8fd9\u4e2a\u53ea\u56de\u590d202 Accepted<\/p>\n<p>POST \/messages\/?session_id&#061;9aa12073a4494d5580a5c30ed54c4bfd HTTP\/1.1<br \/>\nhost: 10.0.105.64:8080<br \/>\nconnection: keep-alive<br \/>\ncontent-type: application\/json<br \/>\naccept: *\/*<br \/>\naccept-language: *<br \/>\nsec-fetch-mode: cors<br \/>\nuser-agent: node<br \/>\naccept-encoding: gzip, deflate<br \/>\ncontent-length: 253<\/p>\n<p>{&#034;method&#034;:&#034;initialize&#034;,&#034;params&#034;:{&#034;protocolVersion&#034;:&#034;2024-11-05&#034;,&#034;capabilities&#034;:{&#034;tools&#034;:true,&#034;prompts&#034;:false,&#034;resources&#034;:true,&#034;logging&#034;:false,&#034;roots&#034;:{&#034;listChanged&#034;:false}},&#034;clientInfo&#034;:{&#034;name&#034;:&#034;cursor-vscode&#034;,&#034;version&#034;:&#034;1.0.0&#034;}},&#034;jsonrpc&#034;:&#034;2.0&#034;,&#034;id&#034;:0}<br \/>\nHTTP\/1.1 202 Accepted<\/p>\n<p>date: Wed, 12 Mar 2025 08:08:32 GMT<br \/>\nserver: uvicorn<br \/>\ncontent-length: 8<\/p>\n<p>Accepted<\/p>\n<p>\u7b2c\u4e09\u4e2a\u94fe\u63a5&#xff0c;\u8bf7\u6c42\u5982\u4e0b&#xff1a;<\/p>\n<p>\u7b2c\u4e09\u4e2a\u94fe\u63a5,\u4ec5\u56de\u590d 202 Accepted<\/p>\n<p>POST \/messages\/?session_id&#061;9aa12073a4494d5580a5c30ed54c4bfd HTTP\/1.1<br \/>\nhost: 10.0.105.64:8080<br \/>\nconnection: keep-alive<br \/>\ncontent-type: application\/json<br \/>\naccept: *\/*<br \/>\naccept-language: *<br \/>\nsec-fetch-mode: cors<br \/>\nuser-agent: node<br \/>\naccept-encoding: gzip, deflate<br \/>\ncontent-length: 54<\/p>\n<p>{&#034;method&#034;:&#034;notifications\/initialized&#034;,&#034;jsonrpc&#034;:&#034;2.0&#034;}<br \/>\nHTTP\/1.1 202 Accepted<br \/>\ndate: Wed, 12 Mar 2025 08:08:32 GMT<br \/>\nserver: uvicorn<br \/>\ncontent-length: 8<\/p>\n<p>Accepted<\/p>\n<p>\u7b2c\u56db\u4e2a\u94fe\u63a5&#xff0c;\u8bf7\u6c42\u5982\u4e0b&#xff0c;\u8bf7\u6c42tools\/list, \u670d\u52a1\u5668\u5728\u7b2c\u4e00\u4e2aget\u7684\u94fe\u63a5&#xff0c;\u901a\u8fc7event\u7684\u65b9\u5f0f\u8fd4\u56de\u4e86\u8fd9\u4e2a\u5217\u8868\u7ed9mcp sse client<\/p>\n<p>\u7b2c\u56db\u4e2a\u94fe\u63a5,\u4ec5\u52a0\u590d 202 Accepted<\/p>\n<p>POST \/messages\/?session_id&#061;9aa12073a4494d5580a5c30ed54c4bfd HTTP\/1.1<br \/>\nhost: 10.0.105.64:8080<br \/>\nconnection: keep-alive<br \/>\ncontent-type: application\/json<br \/>\naccept: *\/*<br \/>\naccept-language: *<br \/>\nsec-fetch-mode: cors<br \/>\nuser-agent: node<br \/>\naccept-encoding: gzip, deflate<br \/>\ncontent-length: 46<\/p>\n<p>{&#034;method&#034;:&#034;tools\/list&#034;,&#034;jsonrpc&#034;:&#034;2.0&#034;,&#034;id&#034;:1}<br \/>\nHTTP\/1.1 202 Accepted<br \/>\ndate: Wed, 12 Mar 2025 08:08:32 GMT<br \/>\nserver: uvicorn<br \/>\ncontent-length: 8<\/p>\n<p>Accepted <\/p>\n<p>1-3\u5b8c\u6210\u5c31\u662f\u5c5e\u4e8e\u521d\u59cb\u5316\u5b8c\u6210&#xff0c;mcp sse\u7684client\u548cserver \u8fde\u63a5\u8d77\u6765\u4e86\u3002<\/p>\n<p>\u7136\u540e\u540e\u9762\u4f7f\u7528mcp call \u8c03\u7528\u7684&#xff0c;\u5728cursor chat\u91cc\u8f93\u5165<\/p>\n<p>call mcp tool search_coding_preferences about StdioServerTransport<\/p>\n<p>\u5c31\u662f\u65b0\u8d77\u4e00\u4e2ahttp\u77ed\u94fe\u63a5&#xff0c;post\u5230endpoint,\u5982\u4e0b<\/p>\n<p>POST \/messages\/?session_id&#061;97a44bcff590415e99cf803350ffd542 HTTP\/1.1<br \/>\nhost: 10.0.105.64:8080<br \/>\nconnection: keep-alive<br \/>\ncontent-type: application\/json<br \/>\naccept: *\/*<br \/>\naccept-language: *<br \/>\nsec-fetch-mode: cors<br \/>\nuser-agent: node<br \/>\naccept-encoding: gzip, deflate<br \/>\ncontent-length: 143<\/p>\n<p>{&#034;method&#034;:&#034;tools\/call&#034;,&#034;params&#034;:{&#034;name&#034;:&#034;search_coding_preferences&#034;,&#034;arguments&#034;:{&#034;query&#034;:&#034;about StdioServerTransport&#034;}},&#034;jsonrpc&#034;:&#034;2.0&#034;,&#034;id&#034;:3}HTTP\/1.1 202 Accepted<br \/>\ndate: Wed, 12 Mar 2025 09:10:43 GMT<br \/>\nserver: uvicorn<br \/>\ncontent-length: 8<\/p>\n<p>HTTP\/1.1 202 Accepted<br \/>\ndate: Wed, 12 Mar 2025 09:10:43 GMT<br \/>\nserver: uvicorn<br \/>\ncontent-length: 8<\/p>\n<p>Accepted <\/p>\n<p>\u7b2c\u4e00\u4e2a\u94fe\u63a5\u5c31\u662f\u4f1a\u6709\u4e00\u4e2a\u901a\u77e5\u8fd4\u56de\u5982\u4e0b&#xff1a;<\/p>\n<p>event: message<br \/>\ndata: {&#034;jsonrpc&#034;:&#034;2.0&#034;,&#034;id&#034;:3,&#034;result&#034;:{&#034;content&#034;:[{&#034;type&#034;:&#034;text&#034;,&#034;text&#034;:&#034;[]&#034;}],&#034;isError&#034;:false}}<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u6587\u7ae0\u6d4f\u89c8\u9605\u8bfb1.3k\u6b21\uff0c\u70b9\u8d5e4\u6b21\uff0c\u6536\u85cf7\u6b21\u30022. MCP SSE Client\u4f1a\u53d1\u8d77\u591a\u4e2a\u8fde\u63a5\uff0c\u4f46\u662f\u7b2c\u4e00\u4e2a\u8fde\u63a5\u662fhttp:\/\/yourhost:port\/sse,  \u8fd9\u4e2a\u8fde\u63a5\u662f\u6c9f\u901a\u7684\u7b2c\u4e00\u6b65\uff0c\u5b83\u4f1a\u4f7f\u7528chunked\u7684\u56de\u4f20\u6570\u636e\uff0c\u610f\u601d\u662f\u4e0d\u544a\u8bc9client\u8fd9\u4e2a\u6570\u636e\u6709\u591a\u5c11\uff0c\u8fd9\u6837\u5c31\u5b83\u5c31\u53ef\u4ee5\u4e00\u76f4\u8fde\u7740\u4e86\u3002\u4f46\u662fsse\u7684\u65b9\u5f0f\u53ebcursor \u5e72\u59cb\u7ec8\u4e0d\u6210\u529f\uff0c \u627e\u4e86\u4e00\u8f6e\uff0c\u53d1\u73b0youtube\u7684\u6559\u7a0b\u89c6\u9891\u91cc\u4e3b\u6301\uff0c\u4e5f\u6ca1\u6709\u641e\u5b9asse\u7684\u670d\u52a1\u5668\uff0cbalahblah\u8bf4\u4e86\u4e00\u5806\uff0c\u5c31\u8981move on &#8230;.\u4e8e\u662f\u7814\u7a76\u4e86\u4e00\u4e0b\u3002\u8ddf\u7740\u5c31\u662fping\u5305\u7684\u8fd4\u56de\uff0c\u9632\u6b62client\u6b7b\u4e86\u3002_mcp sse<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[53],"topic":[],"class_list":["post-8666","post","type-post","status-publish","format-standard","hentry","category-server","tag-ai"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v20.3 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>\u5173\u4e8eMCP SSE \u670d\u52a1\u5668\u7684\u5de5\u4f5c\u539f\u7406 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.wsisp.com\/helps\/8666.html\" \/>\n<meta property=\"og:locale\" content=\"zh_CN\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"\u5173\u4e8eMCP SSE \u670d\u52a1\u5668\u7684\u5de5\u4f5c\u539f\u7406 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\" \/>\n<meta property=\"og:description\" content=\"\u6587\u7ae0\u6d4f\u89c8\u9605\u8bfb1.3k\u6b21\uff0c\u70b9\u8d5e4\u6b21\uff0c\u6536\u85cf7\u6b21\u30022. MCP SSE Client\u4f1a\u53d1\u8d77\u591a\u4e2a\u8fde\u63a5\uff0c\u4f46\u662f\u7b2c\u4e00\u4e2a\u8fde\u63a5\u662fhttp:\/\/yourhost:port\/sse, \u8fd9\u4e2a\u8fde\u63a5\u662f\u6c9f\u901a\u7684\u7b2c\u4e00\u6b65\uff0c\u5b83\u4f1a\u4f7f\u7528chunked\u7684\u56de\u4f20\u6570\u636e\uff0c\u610f\u601d\u662f\u4e0d\u544a\u8bc9client\u8fd9\u4e2a\u6570\u636e\u6709\u591a\u5c11\uff0c\u8fd9\u6837\u5c31\u5b83\u5c31\u53ef\u4ee5\u4e00\u76f4\u8fde\u7740\u4e86\u3002\u4f46\u662fsse\u7684\u65b9\u5f0f\u53ebcursor \u5e72\u59cb\u7ec8\u4e0d\u6210\u529f\uff0c \u627e\u4e86\u4e00\u8f6e\uff0c\u53d1\u73b0youtube\u7684\u6559\u7a0b\u89c6\u9891\u91cc\u4e3b\u6301\uff0c\u4e5f\u6ca1\u6709\u641e\u5b9asse\u7684\u670d\u52a1\u5668\uff0cbalahblah\u8bf4\u4e86\u4e00\u5806\uff0c\u5c31\u8981move on ....\u4e8e\u662f\u7814\u7a76\u4e86\u4e00\u4e0b\u3002\u8ddf\u7740\u5c31\u662fping\u5305\u7684\u8fd4\u56de\uff0c\u9632\u6b62client\u6b7b\u4e86\u3002_mcp sse\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.wsisp.com\/helps\/8666.html\" \/>\n<meta property=\"og:site_name\" content=\"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\" \/>\n<meta property=\"article:published_time\" content=\"2025-04-18T08:52:47+00:00\" \/>\n<meta name=\"author\" content=\"admin\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"\u4f5c\u8005\" \/>\n\t<meta name=\"twitter:data1\" content=\"admin\" \/>\n\t<meta name=\"twitter:label2\" content=\"\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4\" \/>\n\t<meta name=\"twitter:data2\" content=\"4 \u5206\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/8666.html\",\"url\":\"https:\/\/www.wsisp.com\/helps\/8666.html\",\"name\":\"\u5173\u4e8eMCP SSE \u670d\u52a1\u5668\u7684\u5de5\u4f5c\u539f\u7406 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\",\"isPartOf\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/#website\"},\"datePublished\":\"2025-04-18T08:52:47+00:00\",\"dateModified\":\"2025-04-18T08:52:47+00:00\",\"author\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41\"},\"breadcrumb\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/8666.html#breadcrumb\"},\"inLanguage\":\"zh-Hans\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.wsisp.com\/helps\/8666.html\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/8666.html#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"\u9996\u9875\",\"item\":\"https:\/\/www.wsisp.com\/helps\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"\u5173\u4e8eMCP SSE \u670d\u52a1\u5668\u7684\u5de5\u4f5c\u539f\u7406\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#website\",\"url\":\"https:\/\/www.wsisp.com\/helps\/\",\"name\":\"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\",\"description\":\"\u9999\u6e2f\u670d\u52a1\u5668_\u9999\u6e2f\u4e91\u670d\u52a1\u5668\u8d44\u8baf_\u670d\u52a1\u5668\u5e2e\u52a9\u6587\u6863_\u670d\u52a1\u5668\u6559\u7a0b\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.wsisp.com\/helps\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"zh-Hans\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41\",\"name\":\"admin\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"zh-Hans\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery\",\"contentUrl\":\"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery\",\"caption\":\"admin\"},\"sameAs\":[\"http:\/\/wp.wsisp.com\"],\"url\":\"https:\/\/www.wsisp.com\/helps\/author\/admin\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"\u5173\u4e8eMCP SSE \u670d\u52a1\u5668\u7684\u5de5\u4f5c\u539f\u7406 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.wsisp.com\/helps\/8666.html","og_locale":"zh_CN","og_type":"article","og_title":"\u5173\u4e8eMCP SSE \u670d\u52a1\u5668\u7684\u5de5\u4f5c\u539f\u7406 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","og_description":"\u6587\u7ae0\u6d4f\u89c8\u9605\u8bfb1.3k\u6b21\uff0c\u70b9\u8d5e4\u6b21\uff0c\u6536\u85cf7\u6b21\u30022. MCP SSE Client\u4f1a\u53d1\u8d77\u591a\u4e2a\u8fde\u63a5\uff0c\u4f46\u662f\u7b2c\u4e00\u4e2a\u8fde\u63a5\u662fhttp:\/\/yourhost:port\/sse, \u8fd9\u4e2a\u8fde\u63a5\u662f\u6c9f\u901a\u7684\u7b2c\u4e00\u6b65\uff0c\u5b83\u4f1a\u4f7f\u7528chunked\u7684\u56de\u4f20\u6570\u636e\uff0c\u610f\u601d\u662f\u4e0d\u544a\u8bc9client\u8fd9\u4e2a\u6570\u636e\u6709\u591a\u5c11\uff0c\u8fd9\u6837\u5c31\u5b83\u5c31\u53ef\u4ee5\u4e00\u76f4\u8fde\u7740\u4e86\u3002\u4f46\u662fsse\u7684\u65b9\u5f0f\u53ebcursor \u5e72\u59cb\u7ec8\u4e0d\u6210\u529f\uff0c \u627e\u4e86\u4e00\u8f6e\uff0c\u53d1\u73b0youtube\u7684\u6559\u7a0b\u89c6\u9891\u91cc\u4e3b\u6301\uff0c\u4e5f\u6ca1\u6709\u641e\u5b9asse\u7684\u670d\u52a1\u5668\uff0cbalahblah\u8bf4\u4e86\u4e00\u5806\uff0c\u5c31\u8981move on ....\u4e8e\u662f\u7814\u7a76\u4e86\u4e00\u4e0b\u3002\u8ddf\u7740\u5c31\u662fping\u5305\u7684\u8fd4\u56de\uff0c\u9632\u6b62client\u6b7b\u4e86\u3002_mcp sse","og_url":"https:\/\/www.wsisp.com\/helps\/8666.html","og_site_name":"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","article_published_time":"2025-04-18T08:52:47+00:00","author":"admin","twitter_card":"summary_large_image","twitter_misc":{"\u4f5c\u8005":"admin","\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4":"4 \u5206"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.wsisp.com\/helps\/8666.html","url":"https:\/\/www.wsisp.com\/helps\/8666.html","name":"\u5173\u4e8eMCP SSE \u670d\u52a1\u5668\u7684\u5de5\u4f5c\u539f\u7406 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","isPartOf":{"@id":"https:\/\/www.wsisp.com\/helps\/#website"},"datePublished":"2025-04-18T08:52:47+00:00","dateModified":"2025-04-18T08:52:47+00:00","author":{"@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41"},"breadcrumb":{"@id":"https:\/\/www.wsisp.com\/helps\/8666.html#breadcrumb"},"inLanguage":"zh-Hans","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.wsisp.com\/helps\/8666.html"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.wsisp.com\/helps\/8666.html#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"\u9996\u9875","item":"https:\/\/www.wsisp.com\/helps"},{"@type":"ListItem","position":2,"name":"\u5173\u4e8eMCP SSE \u670d\u52a1\u5668\u7684\u5de5\u4f5c\u539f\u7406"}]},{"@type":"WebSite","@id":"https:\/\/www.wsisp.com\/helps\/#website","url":"https:\/\/www.wsisp.com\/helps\/","name":"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","description":"\u9999\u6e2f\u670d\u52a1\u5668_\u9999\u6e2f\u4e91\u670d\u52a1\u5668\u8d44\u8baf_\u670d\u52a1\u5668\u5e2e\u52a9\u6587\u6863_\u670d\u52a1\u5668\u6559\u7a0b","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.wsisp.com\/helps\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"zh-Hans"},{"@type":"Person","@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41","name":"admin","image":{"@type":"ImageObject","inLanguage":"zh-Hans","@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/image\/","url":"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery","contentUrl":"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery","caption":"admin"},"sameAs":["http:\/\/wp.wsisp.com"],"url":"https:\/\/www.wsisp.com\/helps\/author\/admin"}]}},"_links":{"self":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts\/8666","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/comments?post=8666"}],"version-history":[{"count":0,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts\/8666\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/media?parent=8666"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/categories?post=8666"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/tags?post=8666"},{"taxonomy":"topic","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/topic?post=8666"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}