Skip to content
Back to skills

Server Desktop Web Api

ASecurity

"Run, inspect, and extend Kiln's REST server, MCP server, desktop

  • 247 stars
  • 0 votes
  • 0 copies
  • 6 views
  • Added September 8, 2026
developmenttypescriptpythonbashfastapitestinggitapi

Works with

  • cli
  • api
  • mcp

Security analysis

A100/100

Pro scans all 8 files and shows the line behind each finding

Scanned September 8, 2026

npx -y skills add VectorSpaceLab/AREX-Skill --skill server-desktop-web-api --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Server Desktop Web Api?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Server Desktop Web Api
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/vectorspacelab-server-desktop-web-api/badge)](https://www.skillsdirectory.com/skills/vectorspacelab-server-desktop-web-api)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: server-desktop-web-api
description: "Run, inspect, and extend Kiln's REST server, MCP server, desktop
  studio server, Git sync, jobs, chat, OpenAPI schema bridge, and Svelte web
  UI."
disable-model-invocation: true
metadata:
  disco-role: operating
license: NOASSERTION
---

# Server, desktop, web API

Use this sub-skill when the task is about Kiln's FastAPI REST server, MCP server entrypoint, desktop studio server extensions, API route registration, Git sync middleware, background jobs and SSE streams, chat/agent endpoints, OpenAPI schema generation, or the Svelte web UI that consumes the generated API client.

Route core `.kiln` datamodel creation, persistence, CLI project packaging, and object signatures to `project-datamodel`. Route provider/model semantics, `adapter_for_task`, run-config execution behavior, tool IDs, and MCP task execution internals to `task-execution-providers-tools`. Route documents, extraction, vector stores, LanceDB, RAG indexing, and search semantics to `rag-documents-data`. Route evals, synthetic data generation, prompt optimization, fine-tuning, and repair workflows to `evals-optimization-finetuning`. Route repo-wide check policy, UI visual design standards, and general Svelte testing style to `repo-development`.

## Load these references

1. Read [rest-and-mcp-server.md](references/rest-and-mcp-server.md) for `kiln_server.make_app`, the `kiln_server` CLI, the `kiln_mcp` CLI, `connect_*_api` extension patterns, agent-policy metadata, core REST route surfaces, and MCP startup constraints.
2. Read [desktop-studio-server.md](references/desktop-studio-server.md) for `app.desktop.desktop_server.make_app`, desktop lifespan behavior, studio-only API registration, webhost catch-all ordering, CORS, and extension checklists.
3. Read [git-sync-jobs-chat.md](references/git-sync-jobs-chat.md) before changing Git sync, job registry/SSE behavior, chat streaming, Copilot proxying, agent overview, or endpoint lock annotations.
4. Read [openapi-and-web-ui.md](references/openapi-and-web-ui.md) before adding/changing routes used by the Svelte UI, regenerating `api_schema.d.ts`, editing stores/components/routes, or writing web tests.
5. Read [troubleshooting.md](references/troubleshooting.md) when imports, route registration, schema drift, CORS, Starlette/FastAPI versions, MCP imports, RAG optional imports, jobs/SSE, chat/Copilot, Git sync, or optional paid/provider services fail.

## Safe bundled helpers

Use [inspect_kiln_server.py](scripts/inspect_kiln_server.py) to import a Kiln FastAPI app and report route/tag coverage without starting uvicorn:

```bash
python scripts/inspect_kiln_server.py --app desktop --repo-root "$KILN_REPO_ROOT" --summary
python scripts/inspect_kiln_server.py --app server --list-routes
```

Use [check_openapi_schema.sh](scripts/check_openapi_schema.sh) from a Kiln checkout to run the OpenAPI schema freshness check through the bundled wrapper:

```bash
bash scripts/check_openapi_schema.sh --check
bash scripts/check_openapi_schema.sh --generate
```

The helpers are read-only by default. `--generate` intentionally updates the checkout's generated TypeScript schema.

## Operating rules

- Treat `kiln_server.make_app()` as the core REST surface and `app.desktop.desktop_server.make_app()` as the studio app that layers desktop APIs, Git sync middleware, jobs, chat, and the webhost on top.
- Keep `connect_webhost(app)` last in the desktop app; it mounts a root catch-all for the built web UI.
- Preserve CORS as the outermost middleware. Add caller middleware through `kiln_server.make_app(extra_middleware=[...])` when it must remain inner to CORS.
- Give every `/api/...` route a tag from `tags_metadata`, path/query parameter descriptions, and explicit `openapi_extra` agent policy metadata where relevant.
- Mark streaming or long-running endpoints that must bypass Git sync write-lock buffering with `@no_write_lock`; mark mutating `GET` endpoints with `@write_lock`.
- Use `CancellableStreamingResponse` for SSE routes that must tear down observers cleanly without cancelling background work.
- Regenerate/check the web OpenAPI client after changing Pydantic models, route paths, response models, path/query params, or tags used by the UI.
- Do not call optional paid providers, Ollama, cloud APIs, Copilot, remote MCP servers, or Git remotes while performing safe inspection unless the user explicitly asks and credentials/services are available.

## Evidence notes

This sub-skill is distilled from repo-relative evidence in `libs/server/README.md`, `libs/server/kiln_server/server.py`, `libs/server/kiln_server/mcp/README.md`, `libs/server/kiln_server/mcp/mcp.py`, `app/desktop/desktop_server.py`, `app/desktop/studio_server/`, `app/desktop/git_sync/`, `app/web_ui/package.json`, `app/web_ui/src/lib/api_client.ts`, `app/web_ui/src/lib/openapi_schema.sh`, web routes/stores/components/tests, and server/webhost/Git sync/jobs/chat tests. Verified package evidence covered `kiln-ai`, `kiln-server`, and `kiln-studio-desktop` 1.0.4, the CLI commands `kiln_ai`, `kiln_server`, and `kiln_mcp`, and a desktop `make_app` route table with 83 registered routes.

Files in this skill

  • SKILL.md5 KB
  • references/desktop-studio-server.md7.8 KB
  • references/git-sync-jobs-chat.md10 KB
  • references/openapi-and-web-ui.md7.3 KB
  • references/rest-and-mcp-server.md7.8 KB
  • references/troubleshooting.md9.8 KB
  • scripts/check_openapi_schema.sh1.8 KB
  • scripts/inspect_kiln_server.py6 KB

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.