MCPcopy
hub / github.com/npmx-dev/npmx.dev / start

Method start

cli/src/mock-app.ts:433–448  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

431 }
432
433 async start(): Promise<void> {
434 if (this.server) {
435 throw new Error('Mock connector server is already running')
436 }
437
438 const app = createMockConnectorApp(this.stateManager)
439
440 this.server = serve({
441 port: this.stateManager.port,
442 hostname: '127.0.0.1',
443 fetch: app.fetch,
444 })
445
446 await this.server.ready()
447 console.log(`[Mock Connector] Started on http://127.0.0.1:${this.stateManager.port}`)
448 }
449
450 async stop(): Promise<void> {
451 if (!this.server) return

Callers 1

runFunction · 0.95

Calls 1

createMockConnectorAppFunction · 0.85

Tested by

no test coverage detected