---
url: /api/@ufo-soft/caelus-mcp/functions/stdio.md
---
# Function: stdio()

> **stdio**(`registry`, `info`, `stdin?`, `stdout?`): `Promise`<`void`>

Defined in: [packages/mcp/src/mcp.ts:35](https://github.com/ufo-soft/caelus/blob/31cc32fc3d2008e3b0d484d65d10bba2a91a5897/packages/mcp/src/mcp.ts#L35)

The registry as an MCP server on this process's stdin and stdout, the way a host launches one.
Resolves when the host disconnects, once every request already received has been answered; a
handler that never settles keeps the process alive. Handlers must not write to stdout: that is
the protocol's channel.

## Parameters

### registry

[`Registry`](../../caelus/core/classes/Registry.md)

### info

#### description?

`string`

#### icons?

`object`\[]

#### name

`string`

#### title?

`string`

#### version

`string`

#### websiteUrl?

`string`

### stdin?

`Readable` = `process.stdin`

### stdout?

`Writable` = `process.stdout`

## Returns

`Promise`<`void`>
