setServerInfo('integration-server', '1.0.0') ->addTool( static function (RequestContext $context): string { $gateway = $context->getClientGateway(); $gateway->log(LoggingLevel::Info, 'starting work'); $gateway->progress(0.5, 1.0, 'halfway'); $gateway->progress(1.0, 1.0, 'done'); return 'finished'; }, name: 'work', description: 'Reports progress and logs while working.', ) ->build() ->run(new StdioTransport());