ping
Test connectivity and response from the Codex MCP Server to verify the communication channel is active and working properly.
Instructions
Echo
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| prompt | No | Message to echo |
Input Schema (JSON Schema)
{
"properties": {
"prompt": {
"default": "",
"description": "Message to echo ",
"type": "string"
}
},
"required": [],
"type": "object"
}
Implementation Reference
- src/tools/simple-tools.ts:9-22 (handler)Full implementation of the 'ping' tool, including the handler (execute function) that returns an echo message.export const pingTool: UnifiedTool = { name: 'ping', description: 'Echo', zodSchema: pingArgsSchema, prompt: { description: 'Echo test message with structured response.', }, category: 'simple', execute: async (args, onProgress) => { const message = args.prompt || args.message || 'Pong!'; // Return message directly to avoid cross-platform issues with echo command return message as string; }, };
- src/tools/simple-tools.ts:5-7 (schema)Zod schema defining the input arguments for the ping tool.const pingArgsSchema = z.object({ prompt: z.string().default('').describe('Message to echo '), });
- src/tools/index.ts:11-21 (registration)Registration of the pingTool into the central tool registry.toolRegistry.push( askCodexTool, batchCodexTool, // reviewCodexTool, pingTool, helpTool, versionTool, brainstormTool, fetchChunkTool, timeoutTestTool );