Skip to content

Should output also have a schema? #9

@bokand

Description

@bokand

The explainer includes an example returning some structured output:

return {
        content: [
            {
                type: "text",
                text: `Stamp "${name}" added successfully! The collection now contains ${stamps.length} stamps.`, 
            },
        ]
    };

Should we include an outputSchema as MCP recently added?

I'm not sure the schema itself helps (the return is already a JavaScript object...) but descriptions might help the agent understand what the output means?

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions