Skip to content

Bridge API

The Mooch Bridge API is a local HTTP server that enables communication between the Chrome extension and the Mooch desktop app.

  • Base URL: http://localhost:62544
  • Content-Type: application/json
  • Required header: X-Mooch-Client: chrome-extension
  • Binding: 127.0.0.1 only (never 0.0.0.0)
  • CORS: Allows chrome-extension://* origins

Requests without the X-Mooch-Client header or from non-localhost origins are rejected with 403.

Check if Mooch is running and whether an interview session is active.

Response 200:

{
"status": "ok",
"version": "string",
"activeSession": "string | null"
}

List configured providers. API keys and secrets are never exposed.

Response 200:

{
"providers": [
{
"name": "string",
"type": "anthropic | openai-compatible",
"configured": true
}
]
}

Request a hint for the current code.

Request:

{
"code": "string",
"pageTitle": "string",
"language": "string | null",
"metadata": {
"difficulty": "string | null",
"tags": ["string"],
"constraints": "string | null"
},
"hintStyle": "gentle | detailed | pseudocode"
}

Response 200:

{
"hint": "string"
}

Response 503:

{
"error": "no provider configured"
}

If an interview session is active, the server automatically appends the job description and resume to the LLM context.

Request code analysis.

Request:

{
"code": "string",
"context": "string | null"
}

Response 200:

{
"analysis": "string"
}

Response 503:

{
"error": "no provider configured"
}