Add create_api_token tool and FORGEJO_TOKEN support #3
Labels
No labels
domain:backend
domain:devops
domain:frontend
status:approved
status:in-progress
status:needs-fix
status:qa
test:label-a
test:label-b
test:set-label
type:bug
type:devops
type:feature
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
ldraney/forgejo-mcp#3
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Plan
todo-forgejo-token-auth— TODO-scoped workRepo
forgejo-mcp—~/forgejo-mcp/User Story
As an agent that needs Forgejo API access
I need an MCP tool that can create API tokens
So that I can bootstrap token-based auth and generate tokens for CI secrets and other services
Acceptance Criteria
create_api_tokenMCP tool exists wrappingPOST /api/v1/users/{username}/tokensFORGEJO_TOKENis generated and saved to~/secrets/pal-e-services/forgejo.envFORGEJO_TOKENAdditional Information
Depends on forgejo-sdk token auth being done first — the SDK needs token auth support before the MCP can switch to using it. However, the
create_api_tokentool itself can use basic auth (it's creating a token, not consuming one).Forgejo token creation API:
POST /api/v1/users/{username}/tokenswith body{"name": "...", "scopes": [...]}. Returns{"id": N, "name": "...", "sha1": "the-actual-token"}.pal-e-docs:
issue-forgejo-mcp-token-toolChecklist
Related
todo-forgejo-token-auth— parent TODOissue-forgejo-sdk-token-auth— dependency (SDK needs token auth first)repo-forgejo-mcp— repo pageproject-claude-config