smithery.yaml
file provides configuration for your Model Context Protocol (MCP) server on Smithery. This file must be placed in your repository root.
Configuration Options
runtime
Type: StringRequired: Yes Specifies the deployment runtime for your MCP server:
"typescript"
- Uses the Smithery CLI to build your TypeScript project directly"container"
- Uses Docker containers for deployment (supports any language)
TypeScript Runtime
When usingruntime: "typescript"
, Smithery uses the Smithery CLI to build your TypeScript MCP server directly. This is the recommended approach for TypeScript projects.
Properties
Property | Type | Description |
---|---|---|
runtime | string | Must be set to "typescript" |
env | object | Optional environment variables to inject when running your server |
@smithery/cli build
and deployed as a streamable HTTP server. We recommend using the Smithery CLI for the best development experience.
Container Runtime
When usingruntime: "container"
, Smithery uses Docker containers to build and deploy your server. This supports any programming language and gives you full control over the deployment environment.
startCommand
Type: Object (Required for container runtime) Defines how your MCP server should be configured and accessed.Property | Type | Description |
---|---|---|
type | string | Must be set to "http" for HTTP-based MCP servers |
configSchema | object | JSON Schema defining the configuration options for your server |
exampleConfig | object | Example configuration values for testing |
/mcp
endpoint.
Example with complex configuration:
build
Type: Object (Optional for container runtime) Contains Docker build configuration for your server.Property | Type | Description |
---|---|---|
dockerfile | string | Path to Dockerfile, relative to smithery.yaml. Defaults to “Dockerfile” |
dockerBuildPath | string | Docker build context path, relative to smithery.yaml. Defaults to ”.“ |