Plan a source pack
What a profile of share/archive.yaml would pack: the files carried and their bytes and o200k_base tokens, every file left out by reason (worktree, link, artifact, binary, derived, excluded; derived counted, the rest listed), the shards it is cut into within the profile's token budget and file count, and every finding that refuses the build — a file over the budget, too many shards, a machine path or credential in a selected file, an empty selection, a profile without limits. Reads git's index and blobs only; writes nothing.
- query
- behaviorally_verified
- benchmark required
- cache disabled
- MCP tool majordomus_pack_plan
- $ pack plan
Query parameters
| name | type | required | description | examples |
|---|---|---|---|---|
| profile | string | no | A profile of `share/archive.yaml`; its `default` when absent. | chatgpt: "chatgpt" |
Try it
The port is whatever the server logged; 8741 is the one it asks for first. The values are the operation's first example.
curl -s "http://127.0.0.1:8741/api/v1/pack/plan?profile=chatgpt"
Tested by apps/majordomus-cli/tests/http_serve.rs, which replays the route with these values against a server on a real socket.
Responses
| status | body | meaning |
|---|---|---|
| 200 | PackPlan | Plan a source pack: the result. |
| 400 | ErrorBody | invalid_input: The input does not fit the schema: a parameter of the wrong type, an unknown one, or a value the capability rejects. |
| 404 | ErrorBody | not_found: The input names something the repository does not hold. |
| 500 | ErrorBody | internal: The capability failed for a reason of its own; the message names it. |
| default | ErrorBody | Any other failure the transport reports: 405 method_not_allowed for another method on this path, 400 invalid_input for a body that is not a JSON object. |