Skip to content

Commit 065df19

Browse files
authored
feat: scaffold MCP server with robot tools (#299)
* feat: scaffold MCP server with robot tools * feat: add MCP create assembly tool * feat: add MCP assembly status tools * feat: add MCP golden templates * feat: add streamable http transport * docs: tighten MCP server spec * feat: add robot catalog helpers * feat: add upload behavior controls * feat: add input file prep helper * docs: update MCP todo status * chore: apply lint fixes * test: add resume assembly e2e * test: cover lint issue formatting * test: cover base64 limit error * test: cover url import injection * feat: download URL inputs by default * feat: allow multiple URLs per import step * test: cover robot helpers * chore: add mcp-server to knip config * chore: update transloadit parity baseline * feat(mcp-server): support bearer tokens * docs(mcp): note signature auth with bearer * docs: refresh README and MCP todo * w * refactor(mcp-server): share http handler logic * fix: harden input handling * feat: allow private URL downloads by default * docs(node): document prepareInputFiles options * fix: trust assembly url for cancel * feat(mcp-server): add sev-logger with redaction * chore: format transloadit baseline
1 parent 541711c commit 065df19

47 files changed

Lines changed: 4591 additions & 145 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
---
2+
name: council-refactor-ideas
3+
description:
4+
Run `~/code/dotfiles/bin/council.ts refactor` to get a multi-agent refactoring ideas, evaluate
5+
proposals, and bring them to the human.
6+
---
7+
8+
# Council Refactoring Ideas
9+
10+
## Overview
11+
12+
Run the local `council.ts refactor` script to get multi-agent refactoring brainstorms, then triage
13+
and address valid issues before final validation and PR creation.
14+
15+
## Workflow
16+
17+
Run `~/code/dotfiles/bin/council.ts refactor` to get some more refactoring ideas and see which ones
18+
make sense.

.ai/skills/council-review/SKILL.md

Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
---
2+
name: council-review
3+
description:
4+
Run `~/code/dotfiles/bin/council.ts review` to perform a multi-model review, evaluate findings,
5+
fix valid issues (with tests when possible), add clarifying comments for invalid findings, then
6+
run required checks. Use before PR creation or when the user asks for a deep review.
7+
---
8+
9+
# Council Review
10+
11+
## Overview
12+
13+
Run the local `council.ts review` script to get multi-model review findings, then triage and address
14+
valid issues before final validation and PR creation.
15+
16+
## Workflow
17+
18+
### 1) Preflight
19+
20+
- Confirm the script exists and is executable: `~/code/dotfiles/bin/council.ts`.
21+
- Do not use `--post` unless explicitly asked.
22+
- Expect a long runtime (30+ minutes); so set any command timeout on your side to >= 45 minutes.
23+
24+
### 2) Run the review
25+
26+
- Run: `~/code/dotfiles/bin/council.ts review` from inside the repository we were working on.
27+
- Capture the consolidated output (P0-P3 items or "No issues found.").
28+
29+
### 3) Triage findings
30+
31+
For each item:
32+
33+
- **Valid + worth fixing**
34+
- If tests exist for the area, add or extend coverage for the issue.
35+
- Run the test and confirm it fails.
36+
- Apply the fix and re-run the test to confirm it passes.
37+
- **Invalid or not worth fixing**
38+
- Add a brief code comment explaining why it is safe or intentional.
39+
40+
### 4) Re-run review if needed
41+
42+
- Re-run `council.ts review` only if you made substantive changes that affect earlier findings.
43+
44+
### 5) Final validation
45+
46+
- Run repo-required checks (for this repo: `yarn check`).
47+
- Note any warnings but avoid unrelated changes unless required.
48+
49+
## Notes
50+
51+
- Avoid modifications while running; only edit after it finishes.
52+
- If `council.ts review` fails, consider the errors, source code, and propose a fix for the review
53+
script, but do not change it, just propose it to the human

.changeset/mcp-logger-redaction.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
---
2+
"@transloadit/mcp-server": patch
3+
"@transloadit/node": patch
4+
---
5+
6+
Add sev-logger based logging with redaction for MCP server, and improve input handling with trusted assembly URLs and configurable URL download restrictions.

README.md

Lines changed: 36 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,18 +11,51 @@
1111

1212
# Transloadit JavaScript/TypeScript SDKs
1313

14-
Monorepo for Transloadit SDKs and shared packages.
14+
Monorepo for Transloadit SDKs, shared packages, and the MCP server.
1515

16-
For SDK usage docs, see `packages/node/README.md`.
16+
For full SDK usage docs, see `packages/node/README.md`.
1717

1818
## Packages
1919

20-
- `@transloadit/node` — Node.js SDK + CLI (experimental). See `packages/node/README.md`.
20+
- `@transloadit/node` — Node.js SDK + CLI. See `packages/node/README.md`.
2121
- `transloadit` — Stable unscoped package (built from `@transloadit/node`).
22+
- `@transloadit/mcp-server` — MCP server (Streamable HTTP + stdio).
2223
- `@transloadit/types` — Shared TypeScript types.
2324
- `@transloadit/utils` — Shared utilities.
2425
- `@transloadit/zod` — Zod schemas for Transloadit APIs.
2526

27+
## Quick start
28+
29+
### Node SDK
30+
31+
```ts
32+
import { Transloadit } from '@transloadit/node'
33+
34+
const client = new Transloadit({
35+
authKey: process.env.TRANSLOADIT_KEY as string,
36+
authSecret: process.env.TRANSLOADIT_SECRET as string,
37+
})
38+
39+
const result = await client.createAssembly({
40+
params: {
41+
steps: {
42+
':original': { robot: '/upload/handle' },
43+
},
44+
},
45+
files: { file: '/path/to/file.jpg' },
46+
waitForCompletion: true,
47+
})
48+
```
49+
50+
### MCP server (local)
51+
52+
```bash
53+
corepack yarn workspace @transloadit/mcp-server build
54+
node packages/mcp-server/dist/cli.js http --host 127.0.0.1 --port 5723
55+
```
56+
57+
See `docs/mcp-spec.md` for the MCP design and `docs/mcp-todo.md` for the remaining work.
58+
2659
## Development
2760

2861
- Install: `corepack yarn`
@@ -35,4 +68,3 @@ See `CONTRIBUTING.md` for full guidelines.
3568

3669
- Docs live under `docs/`.
3770
- The `transloadit` package is prepared via `scripts/prepare-transloadit.ts`.
38-

0 commit comments

Comments
 (0)