Commit Graph
8 Commits
Author SHA1 Message Date
teahubxyzandClaude Fable 5.1 b5376e9dee MCP 2.3.0: tea_file_edit, exact-text replacements in one file (#12) (#13)
MCP 2.3.0: tea_file_edit, exact-text replacements in one file (#13)

Closes #12. A commit through the MCP needs the whole file in one call, and one model answer carries about 100 KB at most; tea_file_edit reads a file at the branch, applies exact-text replacements in order (each old text exactly once in the file as it stands), commits one update with the file's sha, and answers with the new size and sha256 to check against the caller's copy. 40 tests pass from a clean checkout on hb-5. Merged on the owner's say-so in the chat.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01SKUMBXauq7XVN4BhTXjCSM
2026-10-16 23:21:50 +00:00
teahubxyzandClaude Opus 5.5 25e72f64b8 mcp 2.2: domain search in chat (tea_domains) and on the dashboard, without a second sign-in
Being signed in to teahub.xyz, or connected to Tea MCP in chat, is the gate,
as the operator put it. This takes out 9fece6d's browser sign-in: GET /domains
is open and bounded again (only teahub.xyz may read it, 8 searches a minute
per client and 20 in all, answers kept ten minutes), and the same search is
the tea_domains tool, behind the connector's sign-in.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01CYHXFvWMCs1GUmRmpySqQ6
2026-10-15 00:01:28 -07:00
teahubxyzandClaude Opus 5.5 9fece6d818 mcp 2.2: domain search needs the MCP's sign-in; the Domains tab sends people through it once
/domains/sign-in and /domains/callback do Tea MCP's own Gitea OAuth (the
Green Tea MCP app) in the browser, keep only the name from Gitea, and leave a
signed, HttpOnly cookie on mcp.teahub.xyz for 30 days. GET /domains wants it
(401 with a sign-in link otherwise) and rate-limits per person. The Domains
tab sends that cookie, offers the sign-in on a 401, and runs the waiting
search on the way back. Tested end to end against a Gitea 28 and Cloudflare.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01CYHXFvWMCs1GUmRmpySqQ6
2026-10-14 22:07:03 -07:00
teahubxyzandClaude Opus 5.5 9551a8658a Teahub's look back on prod, and Tea MCP 2.2 for the dashboard's Domains tab
gitea/custom: the old factory's home page and dashboard, ported to Gitea 28.
The signed-out home is Teahub = Git + Tea + Time beside the cup; the
dashboard keeps the feed and puts Domains | Repository | Organization above
the contribution heatmap. Green tea colours for Gitea's light, dark and auto
themes, and the 🍵 mark. gitea/sync-custom.sh puts it on green-tea's volume;
gitea/fly.toml names the site Teahub and sets the meta tags.

mcp 2.2: GET /domains, the old factory's Cloudflare Registrar search (a live
check of the exact names, suggestions, prices). Only GITEA_URL may read it
from a browser; 8 searches a minute per client and 20 in all; answers kept
ten minutes.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01CYHXFvWMCs1GUmRmpySqQ6
2026-10-14 20:47:34 -07:00
teahubxyzandClaude Opus 5.5 40706b8af4 mcp 2.1: Actions runs and job logs, now that prod runs Gitea 28
tea_actions lists runs from /actions/runs (ids, numbers, workflows, conclusions) and tea_action_logs reads one run's jobs, their steps and the last lines of each job's log. Gitea 1.24 had neither endpoint; 28 has both. Tried against a copy of prod's data on 28 before this commit.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01CYHXFvWMCs1GUmRmpySqQ6
2026-10-14 19:46:49 -07:00
teahubxyzandClaude Opus 5.5 fb8acb0af9 mcp: Teahub MCP 2.0, typed and with the tools agents kept asking for
One file, 29 tools, every one acting with the caller's own Gitea token.
Parameters are typed (patterns, ranges, enums), so FastMCP refuses a bad
argument before Gitea is asked anything and publishes the limits in each
tool's schema.

New: tea_pull_get/create/review/merge, tea_labels and tea_label,
tea_commit (up to 50 files, text or base64), tea_branch_create,
tea_repo_edit (including archived), tea_hook_create (one per URL),
tea_secret_set and tea_variable_set.

Fixed:
- unknown labels are refused instead of silently dropped
- a file update is chosen from a 404 on the path, not from matching "404"
  in an error message; paths with spaces are percent-encoded
- tea_org_add_member names its team; there is no default
- org repositories are private by default, like user repositories
- "more" and "truncated" come from X-Total-Count, so they are true
- tea_issue_comments pages client-side: Gitea's endpoint is unpaged
- tea_actions reads /actions/tasks: 1.24 has no /actions/runs, so the
  old tool always got a 404
- a Gitea that does not answer is named as such instead of a masked error

Tests run against a fake Gitea (27). The same code was run against
teahub.xyz with a temporary token in scratch repositories that were then
deleted.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01CYHXFvWMCs1GUmRmpySqQ6
2026-10-14 18:04:07 -07:00
teahubxyz 630de02cf6 mcp: org tools (create, add member, org repo) 2026-10-14 06:05:49 +00:00
teahubxyz 52e0c0cf54 mcp: README 2026-10-14 05:28:57 +00:00