internal/mcp: generate method names
Augment the generator to create constants for all method names. Change-Id: I858e516b1afec0aa3cf3b9852cbdfc16aec4c553 Reviewed-on: https://go-review.googlesource.com/c/tools/+/673177 LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com> Reviewed-by: Robert Findley <rfindley@google.com> Reviewed-by: Sam Thanawalla <samthanawalla@google.com>
This commit is contained in:
parent
9bcc6c758f
commit
74340f088d
1 changed files with 66 additions and 21 deletions
|
|
@ -494,3 +494,30 @@ type toolCapabilities struct {
|
|||
// Whether this server supports notifications for changes to the tool list.
|
||||
ListChanged bool `json:"listChanged,omitempty"`
|
||||
}
|
||||
|
||||
const (
|
||||
notificationCancelled = "notifications/cancelled"
|
||||
methodInitialize = "initialize"
|
||||
notificationProgress = "notifications/progress"
|
||||
methodSetLevel = "logging/setLevel"
|
||||
methodCreateMessage = "sampling/createMessage"
|
||||
notificationResourceListChanged = "notifications/resources/list_changed"
|
||||
notificationInitialized = "notifications/initialized"
|
||||
methodUnsubscribe = "resources/unsubscribe"
|
||||
notificationLoggingMessage = "notifications/message"
|
||||
methodSubscribe = "resources/subscribe"
|
||||
methodComplete = "completion/complete"
|
||||
methodCallTool = "tools/call"
|
||||
notificationPromptListChanged = "notifications/prompts/list_changed"
|
||||
methodReadResource = "resources/read"
|
||||
methodListResourceTemplates = "resources/templates/list"
|
||||
methodListRoots = "roots/list"
|
||||
notificationToolListChanged = "notifications/tools/list_changed"
|
||||
methodGetPrompt = "prompts/get"
|
||||
methodListPrompts = "prompts/list"
|
||||
methodPing = "ping"
|
||||
notificationRootsListChanged = "notifications/roots/list_changed"
|
||||
methodListTools = "tools/list"
|
||||
methodListResources = "resources/list"
|
||||
notificationResourceUpdated = "notifications/resources/updated"
|
||||
)
|
||||
|
|
|
|||
Loading…
Reference in a new issue