MCPcopy Create free account
hub / github.com/github/gh-aw / generateArrayExample

Function generateArrayExample

pkg/parser/schema_suggestions.go:399–409  ·  view source on GitHub ↗
(schema map[string]any)

Source from the content-addressed store, hash-verified

397}
398
399func generateArrayExample(schema map[string]any) any {
400 items, ok := schema["items"].(map[string]any)
401 if !ok {
402 return []any{}
403 }
404 itemExample := generateExampleFromSchema(items)
405 if itemExample == nil {
406 return []any{}
407 }
408 return []any{itemExample}
409}
410
411func generateObjectExample(schema map[string]any) any {
412 result := make(map[string]any)

Callers 1

Calls 1

Tested by

no test coverage detected