Add tags field to Server struct in MCP model
- Introduce a new Tags field in the Server struct to allow for additional metadata. - Update the listServers function to populate the Tags field from the server metadata, enhancing the server representation with more contextual information.
This commit is contained in:
parent
1b60feacab
commit
ccc25e7079
1 changed files with 8 additions and 6 deletions
|
|
@ -13,6 +13,7 @@ type Server struct {
|
|||
Value string `json:"value"`
|
||||
Name string `json:"name"`
|
||||
Description string `json:"description,omitempty"`
|
||||
Tags []string `json:"tags,omitempty"`
|
||||
Transport string `json:"transport,omitempty"` // "stdio", "sse", "http"
|
||||
Builtin bool `json:"builtin"` // true for system built-in, false for user-defined
|
||||
}
|
||||
|
|
@ -58,6 +59,7 @@ func listServers(c *gin.Context) {
|
|||
Value: id,
|
||||
Name: name,
|
||||
Description: meta.Description,
|
||||
Tags: meta.Tags,
|
||||
Transport: transport,
|
||||
Builtin: meta.Builtin,
|
||||
})
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue