Vibe Coder MCP

by freshtechbro
Verified

generate-code-stub

Create code stubs for functions, classes, or methods in various languages based on detailed descriptions and optional file context.

Instructions

Generates a code stub (function, class, etc.) in a specified language based on a description. Can optionally use content from a file (relative path) as context.

Input Schema

NameRequiredDescriptionDefault
classPropertiesNoFor classes: list of properties with names, optional types, and descriptions.
contextFilePathNoOptional relative path to a file whose content should be used as additional context.
descriptionYesDetailed description of what the stub should do, including its purpose, parameters, return values, or properties.
languageYesThe programming language for the stub (e.g., 'typescript', 'python', 'javascript')
methodsNoFor classes/interfaces: list of method signatures with names and descriptions.
nameYesThe name of the function, class, interface, etc.
parametersNoFor functions/methods: list of parameters with names, optional types, and descriptions.
returnTypeNoFor functions/methods: the expected return type string.
stubTypeYesThe type of code structure to generate (function, class, etc.)

Input Schema (JSON Schema)

{ "$schema": "http://json-schema.org/draft-07/schema#", "additionalProperties": false, "properties": { "classProperties": { "description": "For classes: list of properties with names, optional types, and descriptions.", "items": { "$ref": "#/properties/parameters/items" }, "type": "array" }, "contextFilePath": { "description": "Optional relative path to a file whose content should be used as additional context.", "type": "string" }, "description": { "description": "Detailed description of what the stub should do, including its purpose, parameters, return values, or properties.", "minLength": 1, "type": "string" }, "language": { "description": "The programming language for the stub (e.g., 'typescript', 'python', 'javascript')", "minLength": 1, "type": "string" }, "methods": { "description": "For classes/interfaces: list of method signatures with names and descriptions.", "items": { "additionalProperties": false, "description": "Represents a class method signature", "properties": { "description": { "type": "string" }, "name": { "type": "string" } }, "required": [ "name" ], "type": "object" }, "type": "array" }, "name": { "description": "The name of the function, class, interface, etc.", "minLength": 1, "type": "string" }, "parameters": { "description": "For functions/methods: list of parameters with names, optional types, and descriptions.", "items": { "additionalProperties": false, "description": "Represents a function parameter or class property", "properties": { "description": { "type": "string" }, "name": { "type": "string" }, "type": { "type": "string" } }, "required": [ "name" ], "type": "object" }, "type": "array" }, "returnType": { "description": "For functions/methods: the expected return type string.", "type": "string" }, "stubType": { "description": "The type of code structure to generate (function, class, etc.)", "enum": [ "function", "class", "interface", "method", "module" ], "type": "string" } }, "required": [ "language", "stubType", "name", "description" ], "type": "object" }
ID: yvtu46xhkx