MCPcopy Create free account
hub / github.com/modelcontextprotocol/go-sdk / RemovePrompts

Method RemovePrompts

mcp/server.go:212–214  ·  view source on GitHub ↗

RemovePrompts removes the prompts with the given names. It is not an error to remove a nonexistent prompt.

(names ...string)

Source from the content-addressed store, hash-verified

210// RemovePrompts removes the prompts with the given names.
211// It is not an error to remove a nonexistent prompt.
212func (s *Server) RemovePrompts(names ...string) {
213 s.changeAndNotify(notificationPromptListChanged, func() bool { return s.prompts.remove(names...) })
214}
215
216// AddTool adds a [Tool] to the server, or replaces one with the same name.
217// The Tool argument must not be modified after this call.

Callers 1

TestEndToEndFunction · 0.95

Calls 2

changeAndNotifyMethod · 0.95
removeMethod · 0.80

Tested by 1

TestEndToEndFunction · 0.76