Skip to main content
Glama

Storyden

by Southclaws
Mozilla Public License 2.0
227
structured_test.go791 B
package ai import ( "encoding/json" "testing" "github.com/stretchr/testify/require" ) type SuggestTagsResultSchema struct { Tags []string `json:"tags" jsonschema:"title=Tags,description=List of suggested tags,items=string"` } func Test_schemaFromObjectInstance(t *testing.T) { r := require.New(t) sc, err := schemaFromObjectInstance(SuggestTagsResultSchema{}) r.NoError(err) j, _ := json.MarshalIndent(sc, "", " ") r.Equal(`{ "$schema": "https://json-schema.org/draft/2020-12/schema", "properties": { "tags": { "items": { "type": "string" }, "type": "array", "title": "Tags", "description": "List of suggested tags" } }, "additionalProperties": false, "type": "object", "required": [ "tags" ] }`, string(j)) }

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Southclaws/storyden'

If you have feedback or need assistance with the MCP directory API, please join our Discord server