# EXCT 配置：Agent 接口

## 配置服务连接信息

MCP URL: `https://fit.exct.online/mcp`

Transport: **Streamable HTTP**. Public, anonymous, read-only. This service uses stateless JSON responses, without a standalone SSE notification stream.

连接步骤、客户端配置示例、导出格式选择和常见问题统一收录在军团文档的 [Agent 与 MCP 接入](https://wiki.exct.online/agents/)。本页说明配置服务的工具参数和数据格式。

## Tools

- `search_fits({query?, ship?, purpose?, collection?, limit?, offset?})`: Chinese/English substring search. Space-separated query terms must all match. Ship accepts a typeID or localized name. Limit defaults to 10, maximum 50. Search covers names/descriptions, branch names/notes/alerts and collection/series metadata. Results contain concise summaries and stable configuration IDs.
- `get_fit({id, branch?, version?})`: default returns all branches and versions. Selecting a branch without a version selects its latest listed version. Selecting a version without a branch uses the first branch. Unknown IDs are errors, never silently replaced.
- `export_fit({id, branch?, version?, alternatives?, format?})`: defaults to EFT for the first branch's latest version. `format` is `eft`, `text`, or `xml`. Explicitly select a budget branch when needed.
- `get_fit_screenshot({id, branch?, version?, language?, includeImage?})`: returns a published default-equipment PNG and its public URL. Defaults to first branch/latest version, Chinese (`zh`), and `includeImage: true`. Use `en` for English or `includeImage: false` for the link and metadata only. Custom alternatives are unsupported and rejected.
- `get_data_version({})`: data hash, generated timestamp, counts and official SDE provenance.

MCP resource: `vexor://manifest` returns the data manifest.

## Example

1. `search_fits({"ship":"魔像","purpose":"四级","query":"廉价"})`.
2. `get_fit({"id":"lv4/marauder/golem"})`; inspect the branch whose Chinese name is 廉价超大回.
3. Call `export_fit` with `id: "lv4/marauder/golem"`, `branch` set to the actual budget branch ID returned in step 2, and `format: "eft"`.

Never guess branch IDs. Branch IDs are explicit XML `<branch id="...">` values when present, otherwise derived from their English name. Keep names stable or assign an explicit ID before renaming. Version IDs are the XML `version` attribute values and are strings. Existing numeric website `b`/`v` parameters remain presentation indices, distinct from these API IDs.

## Equipment and alternatives

Each version includes `ship` with CCP `typeID` and `{en,zh}` names; `equipment` includes low, med, high, rig, sub, service, drone, cargo and imp. Each displayed row has `selectionKey`, `copies`, `quantity`, `offline`, optional `charge`, and structured `alternatives` containing their index and original text. Effective total quantity is `copies * quantity`. Charge quantity is `null` when the source does not specify it.

Example: `alternatives: {"rig-0": 0}` selects the first replacement for that row. Omit a key to use its original equipment. Selections use the exact keys and indices returned by `get_fit` and are checked against the selected branch/version. Returned website links restore the same selection.

`sourceFit` retains the parsed original data, including every source item and alternative string. Exported source XML is untouched. Descriptions, bilingual names, branch notes/alerts and versions are retained.

EFT has no implant section. Game imports ignore offline state. Use `text` to retain implants/offline state for a selected configuration. Use `xml` to retain the entire original configuration with all branches/versions/alternatives; omit branch/version/alternatives for XML export. Static `.eft` and `.txt` files select the first branch's latest version with original equipment.

## Plain HTTP and bulk data

- `GET /api/v1/fits?ship=28710&purpose=四级&query=廉价`
- `GET /api/v1/fit?id=lv4/marauder/golem`
- `GET /api/v1/export?id=lv4/marauder/golem&format=eft`
- `GET /api/v1/screenshot?id=lv4/marauder/golem&branch=xlarge&language=zh` (PNG metadata and static URL)
- `GET /api/v1/version`
- `GET /data/v1/index.json`, `/data/v1/catalog.json`, `/data/v1/manifest.json`
- `GET /data/v1/fits/lv4/marauder/golem.json` and `.xml`, `.eft`, `.txt`

HTTP export returns JSON containing `text`, selected IDs, source URL, dataVersion and warnings. `alternatives` is a URL-encoded JSON object in query parameters. Bad parameters return 400; unknown IDs return 404. Runtime API/MCP is limited to 120 requests/minute per client IP; 429 includes Retry-After. Static files support normal HTTP caching and bulk downloads.

`dataVersion` is a SHA-256 of published configuration content, source XML, SDE provenance and generated screenshots. `generatedAt` is build time, not a claimed author edit time. Every detail carries the catalog version and SDE build; retain these and the source link in citations. Live data switches together with website releases.

## Default screenshots

Every version contains `screenshots.zh` and `screenshots.en`. The root `screenshots` field shows the first branch/latest version when reading the entire configuration, or the exact selected version when using branch/version parameters. Each image includes its branch, version, language, dimensions, hash, static URL and `scope: "default-equipment"`. Images use original equipment, with `alternatives: {}`; they do not represent a user's custom replacements. Use the screenshot from the exact branch/version discussed in your answer. Keep notes and warnings alongside the image.

PNGs are rendered with the website's existing screenshot component during the static build and uploaded with the data. MCP reads the existing file and returns image content; it never runs a browser on the production server. Image URLs contain a content hash. `get_fit_screenshot` is useful when the client can display MCP image results; ordinary HTTP clients can fetch the returned URL directly.

These configurations are community guidance. The service does not calculate DPS, tank, capacitor stability, prices, character skills or live game state. Include published alerts and notes when recommending a configuration.
