Edit photos by describing the change, on your own GPU. A free, open-source alternative to Nano Banana and ChatGPT image editing: photos stay on your computer, no daily limit. One installer for Windows, Mac and Linux sets up the best open model (Qwen-Image 2.1). MCP server for AI agents.
TypeScript ai-photo-editorcomfyui-alternativegenerative-fillimage-editingimage-generationinpaintinglinuxlocal-aimacosmcpmcp-servernano-banana-alternativeofflinephoto-editorprivacyqwen-imageqwen-image-2-1stable-diffusion-cppvulkanwindows
docs: service.json on Linux, which Origin headers the API refuses; CI runs the kokon-mcp help test
Gabriele Lozupone9e6de7c987c0
diff --git a/.github/workflows/test.yml b/.github/workflows/test.ymlindex 41ddad9..f34255e 100644--- a/.github/workflows/test.yml+++ b/.github/workflows/test.yml@@ -33,6 +33,6 @@ jobs:working-directory: mcprun: npm run typecheck# The protocol test needs a built kokon-service and MCP bundle; the others need no binaries.- - name: Test MCP paths, tools and version+ - name: Test MCP paths, tools, version and helpworking-directory: mcp- run: npm test -- test/paths.test.ts test/tools.test.ts test/version.test.ts+ run: npm test -- test/paths.test.ts test/tools.test.ts test/version.test.ts test/help.test.tsdiff --git a/README.md b/README.mdindex 1467bac..1fd882d 100644--- a/README.md+++ b/README.md@@ -427,8 +427,8 @@ claude mcp add-json --scope user kokon '{"type":"stdio","command":"C:\\Users\\<yBase URL `http://127.0.0.1:39151/api/v1`. Every call except `/ping` needs`Authorization: Bearer <token>`, with the token from `%LOCALAPPDATA%\KokonData\service.json`-(Mac: `~/Library/Application Support/KokonData/service.json`).-Requests that carry a browser `Origin` header are refused.+(Mac: `~/Library/Application Support/KokonData/service.json`, Linux: `~/.local/share/KokonData/service.json`).+Requests from web pages (a browser `Origin` header other than the app's own) are refused.```powershell$i = Get-Content "$env:LOCALAPPDATA\KokonData\service.json" | ConvertFrom-Json@@ -437,7 +437,7 @@ Invoke-RestMethod -Method Post "http://127.0.0.1:$($i.port)/api/v1/generate" -He-ContentType 'application/json' -Body '{"prompt":"a lighthouse at dusk, 16:9","quality":"fast"}'```-On macOS (or any shell with `curl`):+On macOS or Linux (`curl`; on Linux the file is in `~/.local/share/KokonData/`):```bashINFO="$HOME/Library/Application Support/KokonData/service.json"diff --git a/docs/http-api.md b/docs/http-api.mdindex ed784ca..26cf170 100644--- a/docs/http-api.md+++ b/docs/http-api.md@@ -13,10 +13,11 @@ The service writes its port and token to `service.json` when it starts:| --- | --- || Windows | `%LOCALAPPDATA%\KokonData\service.json` || Mac | `~/Library/Application Support/KokonData/service.json` |+| Linux | `~/.local/share/KokonData/service.json` (or `$XDG_DATA_HOME/KokonData`) |Base URL: `http://127.0.0.1:<port>/api/v1` (the port is usually `39151`). Every call except-`/ping` needs `Authorization: Bearer <token>`. Requests that carry a browser `Origin` header are-refused. Errors come back as `{"error": {...}}`.+`/ping` needs `Authorization: Bearer <token>`. Requests from web pages (a browser `Origin`+header other than the app's own) are refused. Errors come back as `{"error": {...}}`.**PowerShell:**@@ -27,7 +28,7 @@ Invoke-RestMethod -Method Post "http://127.0.0.1:$($i.port)/api/v1/generate" -He-ContentType 'application/json' -Body '{"prompt":"a lighthouse at dusk, 16:9","quality":"fast"}'```-**macOS (curl):**+**macOS and Linux (curl):** on Linux, set `INFO` to `$HOME/.local/share/KokonData/service.json`.```bashINFO="$HOME/Library/Application Support/KokonData/service.json"