🐛 Disabel required fields in mcp

This commit is contained in:
OpenWaygate committed 2025-12-07 00:34:14 +08:00
1 parent faefd73622
commit c4d0ae41c7
2 files changed
+5 -6

No files matched your search

+4 -4
View File
@@ -39,10 +39,10 @@ type listIn struct {
var listInSchema = &jsonschema.Schema{
Type: "object",
Required: []string{
"channelId", "home", "maxResults", "mine", "publishedAfter",
"publishedBefore", "regionCode", "parts", "output", "jsonpath",
},
// Required: []string{
// "channelId", "home", "maxResults", "mine", "publishedAfter",
// "publishedBefore", "regionCode", "parts", "output", "jsonpath",
// },
Properties: map[string]*jsonschema.Schema{
"channelId": {
Type: "string", Description: ciUsage, Default: json.RawMessage(`""`),
+1 -2
View File
@@ -4,7 +4,6 @@
package cmd
import (
"context"
"fmt"
"log/slog"
"net/http"
@@ -43,7 +42,7 @@ var mcpCmd = &cobra.Command{
Long: mcpLong,
Run: func(cmd *cobra.Command, args []string) {
var err error
ctx := context.Background()
ctx := cmd.Context()
addr := fmt.Sprintf(":%d", port)
slog.InfoContext(
ctx, "starting MCP server",