How to use prompts from the client
PromptListChangedNotification
, it signals that the prompt list has changed. The list_prompts()
method always fetches fresh data from the server, ensuring you get up-to-date information.
Important: Always use await session.list_prompts()
instead of the deprecated session.prompts
property to ensure you get fresh data:
get_prompt
method: