server/

directory
v0.36.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 3, 2026 License: MIT

README ΒΆ

πŸš€ inGitDB server

inGitDB can be started to serve as an API and/or MCP serve.

πŸ€– MCP server

To start an MCP server, run:

ingitdb serve --mcp [--mcp-port=8080] [--mcp-domains=mcp.ingitdb.com,localhost]

🌐 HTTP(s) server

To start an HTTP server, run:

ingitdb serve --http [--api-port=8080] [--api-domains=api.ingitdb.com,localhost]
  • --api-port – optional parameter for a port to use for an HTTP connection, if not set defaults to 8080.
  • --api-domain – optional paramer for domain names to be used for hosting API, if not defaults to "localhost,api.ingitdb.com"

🌐 Enabling HTTPS

TODO: Needs instructions on how to enable HTTPS connections (and probably implementation).

πŸš€ Public inGitDB servers

  • api.ingitdb.com – query and modify inGitDBs in public and private GitHub repositories using REST API.
  • mcp.ingitdb.com – grant AI agents access to inGitDBs in public and private GitHub repositories.

πŸ”’ GitHub OAuth authentication

HTTP API and MCP HTTP endpoints now require a valid GitHub token (from Authorization: Bearer ... or shared auth cookie).

Required environment variables for ingitdb serve --http:

  • INGITDB_GITHUB_OAUTH_CLIENT_ID
  • INGITDB_GITHUB_OAUTH_CLIENT_SECRET
  • INGITDB_GITHUB_OAUTH_CALLBACK_URL
  • INGITDB_AUTH_COOKIE_DOMAIN
  • INGITDB_AUTH_API_BASE_URL

These are required only when --api-domains is set to a non-localhost value. Localhost mode (--api-domains=localhost or omitted --api-domains) allows unauthenticated API/MCP requests.

Optional environment variables:

  • INGITDB_AUTH_COOKIE_NAME (default: ingitdb_github_token)
  • INGITDB_AUTH_COOKIE_SECURE (default: true)
  • INGITDB_GITHUB_OAUTH_SCOPES (default: repo,read:org,read:user; accepts comma and/or space separated scopes)

For organization repositories, the OAuth app may still require organization approval (if org third-party app restrictions are enabled).

API-hosted auth endpoints:

  • GET /auth/github/login β€” redirects to GitHub OAuth authorize page.
  • GET /auth/github/logout β€” clears auth cookies and unauthenticates current browser session.
  • GET /auth/github/callback β€” exchanges code for token, stores shared-domain cookie, renders success page.
  • GET /auth/github/status β€” validates current token and returns auth status.

MCP-hosted helper endpoint:

  • GET /auth/github/login β€” redirects to API-hosted /auth/github/login.

Directories ΒΆ

Path Synopsis
Package api implements the REST API server for api.ingitdb.com.
Package api implements the REST API server for api.ingitdb.com.
Package mcp implements the MCP (Model Context Protocol) HTTP server for mcp.ingitdb.com.
Package mcp implements the MCP (Model Context Protocol) HTTP server for mcp.ingitdb.com.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL