Skip to content

Commit b9a9838

Browse files
committed
Add meta
1 parent fc56716 commit b9a9838

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

src/mcp/client/client.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -195,6 +195,7 @@ async def read_resource(self, uri: str, *, meta: RequestParamsMeta | None = None
195195
196196
Args:
197197
uri: The URI of the resource to read.
198+
meta: Additional metadata for the request
198199
199200
Returns:
200201
The resource content.
@@ -247,17 +248,20 @@ async def list_prompts(
247248
"""List available prompts from the server."""
248249
return await self.session.list_prompts(params=types.PaginatedRequestParams(cursor=cursor, _meta=meta))
249250

250-
async def get_prompt(self, name: str, arguments: dict[str, str] | None = None) -> types.GetPromptResult:
251+
async def get_prompt(
252+
self, name: str, arguments: dict[str, str] | None = None, *, meta: RequestParamsMeta | None = None
253+
) -> types.GetPromptResult:
251254
"""Get a prompt from the server.
252255
253256
Args:
254257
name: The name of the prompt
255258
arguments: Arguments to pass to the prompt
259+
meta: Additional metadata for the request
256260
257261
Returns:
258262
The prompt content.
259263
"""
260-
return await self.session.get_prompt(name=name, arguments=arguments)
264+
return await self.session.get_prompt(name=name, arguments=arguments, meta=meta)
261265

262266
async def complete(
263267
self,

0 commit comments

Comments
 (0)