preqstation
npx skills add https://github.com/sonim1/preqstation-skill --skill preqstation
Agent 安装分布
Skill 文档
Environment
PREQSTATION_API_URL: PREQSTATION API base URL (example:https://mypreqstation.vercel.app)PREQSTATION_TOKEN: PREQSTATION Bearer token (generated in PREQSTATION/api-keys)PREQSTATION_ENGINE(optional): fallback engine (claude|codex|gemini) when client auto-detection is unavailable
Agent Identity & Engine Mapping
Each agent must identify itself and use the corresponding engine value in all task operations (list, create, plan, start, complete, block):
| If you are… | Use engine= |
|---|---|
| Claude (Anthropic) | claude |
| GPT / Codex (OpenAI) | codex |
| Gemini (Google) | gemini |
Always include your engine value when listing, creating, planning, starting, completing, or blocking tasks.
MCP Plugin Mode (Recommended)
If MCP is available, prefer scripts/preqstation-mcp-server.mjs tools.
All mutation tools accept an optional engine parameter and always send an engine value using this order:
- explicit tool arg
- existing task engine (when available)
- MCP
initialize.clientInfo.nameauto-detection PREQSTATION_ENGINEcodexfallback
| Tool | engine usage |
|---|---|
preq_list_tasks |
Filter tasks by engine |
preq_get_task |
Read-only, no engine needed |
preq_plan_task |
Assign engine when planning task â todo |
preq_create_task |
Assign engine to new inbox task |
preq_start_task |
Record engine starting the work â in_progress |
preq_complete_task |
Record engine in work log result â review (fallback to task’s existing engine) |
preq_block_task |
Record engine reporting the block â blocked |
This gives deterministic task-id based execution and result upload.
Shell Helper Mode
If MCP is not available, source scripts/preqstation-api.sh and use shell functions.
All mutation helpers accept an engine parameter:
| Function | Signature |
|---|---|
preq_get_tasks |
preq_get_tasks [status] [engine] [label] |
preq_get_task |
preq_get_task <task_id> |
preq_create_task |
preq_create_task '<json_payload>' (include engine in JSON) |
preq_patch_task |
preq_patch_task <task_id> '<json_payload>' (generic PATCH) |
preq_start_task |
preq_start_task <task_id> [engine] |
preq_plan_task |
preq_plan_task <task_id> <plan_markdown> [engine] |
preq_complete_task |
preq_complete_task <task_id> <summary> [engine] [pr_url] [tests] [notes] |
preq_block_task |
preq_block_task <task_id> <reason> [engine] |
preq_delete_task |
preq_delete_task <task_id> |
Requires jq for JSON construction in plan/complete/block helpers.
List Todo Tasks
List todo tasks assigned to your engine:
# Replace ENGINE with your engine value (claude, codex, or gemini)
curl -s -H "Authorization: Bearer $PREQSTATION_TOKEN" \
"$PREQSTATION_API_URL/api/tasks?status=todo&engine=ENGINE" | jq .
Fetch Task Detail
TASK_ID="<task-id>"
curl -s -H "Authorization: Bearer $PREQSTATION_TOKEN" \
"$PREQSTATION_API_URL/api/tasks/$TASK_ID" | jq .
Recommended Execution Flow
- Fetch the task detail from PREQSTATION (verify
enginematches your identity). - Move status to
in_progresswith yourengine. - Implement code changes according to acceptance criteria.
- Run tests/verification.
- Push
status=review(In Review) andresultback to PREQSTATION with yourengineand the same ticket number. - Confirm result appears in PREQSTATION work logs.
preq_complete_task must be used only after the task is moved to in_progress.
Inbox â Todo Plan Flow
- User adds short task card to Inbox (optionally specifying
engine). - Agent loads candidate tasks with
preq_list_tasks(useprojectKey+status=todo+ ownenginefilter). - Agent reads local source code and generates implementation plan with LLM.
- Agent calls
preq_plan_taskwithprojectKey,taskId,planMarkdown,engine, and optionalacceptanceCriteria. - MCP uploads plan to task description and moves the card to
status=todo.
Create Task with Engine
curl -s -X POST \
-H "Authorization: Bearer $PREQSTATION_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"title":"Implement rate limiting",
"engine":"claude",
"projectKey":"MY_PROJECT"
}' \
"$PREQSTATION_API_URL/api/tasks" | jq .
Mark In Progress (with Engine)
curl -s -X PATCH \
-H "Authorization: Bearer $PREQSTATION_TOKEN" \
-H "Content-Type: application/json" \
-d '{"status":"in_progress","engine":"claude"}' \
"$PREQSTATION_API_URL/api/tasks/$TASK_ID" | jq .
Submit In Review Result (with Engine)
curl -s -X PATCH \
-H "Authorization: Bearer $PREQSTATION_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"status":"review",
"engine":"claude",
"result":{
"summary":"Implemented rate limiting for login endpoint",
"engine":"claude",
"pr_url":"https://github.com/org/repo/pull/123",
"tests":"npm run test",
"completed_at":"2025-02-24T12:00:00Z"
}
}' \
"$PREQSTATION_API_URL/api/tasks/$TASK_ID" | jq .
Blocked Update (with Engine)
curl -s -X PATCH \
-H "Authorization: Bearer $PREQSTATION_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"status":"blocked",
"engine":"claude",
"result":{
"reason":"Missing required Redis environment variables",
"engine":"claude",
"blocked_at":"2025-02-24T12:00:00Z"
}
}' \
"$PREQSTATION_API_URL/api/tasks/$TASK_ID" | jq .
Plan Task (with Engine)
curl -s -X PATCH \
-H "Authorization: Bearer $PREQSTATION_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"status":"todo",
"engine":"claude",
"description":"## Plan\n\n1. Add middleware...\n2. Write tests..."
}' \
"$PREQSTATION_API_URL/api/tasks/$TASK_ID" | jq .