Skills API
Skill lists, details, versions, upload, update, comments, and sub-Skills.
Most read endpoints are dual; most write endpoints are user_only, but the upload endpoint is dual, and tk_ can upload only to the repository bound to the token.
Endpoints
Queries
| Method | Path | Purpose |
|---|---|---|
GET |
/api/skills |
List Skills |
GET |
/api/skills/categories |
Categories |
GET |
/api/skills/tag-suggest |
Tag suggestions |
GET |
/api/skills/agent-stats |
Statistics by Agent |
GET |
/api/skills/featured |
Featured Skills |
GET |
/api/skills/stats |
Skill statistics |
GET |
/api/skills/search |
Search |
GET |
/api/skills/by-id/{skill_id} |
Details |
GET |
/api/skills/{skill_id}/sub |
Sub-Skill list |
GET |
/api/skills/{skill_id}/sub/{sub_name} |
Sub-Skill details |
GET |
/api/skills/by-id/{skill_id}/download |
Download ZIP |
GET |
/api/skills/by-id/{skill_id}/versions |
Version history |
GET |
/api/skills/by-id/{skill_id}/files |
Files in the package |
POST |
/api/skills/by-id/{skill_id}/convert |
Convert skill scope in place (user ↔ repository) |
PUT |
/api/skills/by-id/{skill_id}/content |
Save a personal skill's SKILL.md without bumping the version |
POST |
/api/skills/by-id/{skill_id}/ai-fill |
Suggest skill metadata from SKILL.md |
GET |
/api/skills/by-id/{skill_id}/related |
Related Skills |
GET |
/api/skills/template |
Skill template |
Writes and maintenance
| Method | Path | Purpose |
|---|---|---|
POST |
/api/skills/upload |
Upload Skill |
POST |
/api/skills/by-id/{skill_id}/update |
Overwrite with a new ZIP |
PATCH |
/api/skills/{skill_id} |
Update metadata |
DELETE |
/api/skills/by-id/{skill_id} |
Delete Skill |
POST |
/api/skills/{skill_id}/like |
Like |
POST |
/api/skills/convert |
Convert Skill mode |
POST |
/api/skills/by-id/{skill_id}/comments |
Post comment |
GET |
/api/skills/by-id/{skill_id}/comments |
List comments |
Sub-Skills
| Method | Path | Purpose |
|---|---|---|
GET |
/api/skills/{skill_id}/sub |
List sub-Skills |
GET |
/api/skills/{skill_id}/sub/{sub_name} |
Read sub-Skill |
GET |
/api/skills/package-sub/{pkg_id}/{sub_name} |
Read sub-Skill in a package |
Uploading a Skill
A Skill package is a ZIP file. Upload uses multipart/form-data.
curl -fsS -X POST "$GRAPE_BASE_URL/api/skills/upload" \
-H @~/.grape.auth \
-F 'file=@my-skill.zip' \
-F 'scope=repo' \
-F 'repo=<owner>/<repo>' \
-F 'agent_type=sre'
file and agent_type are required; a repository Skill also requires scope=repo and repo. The server derives the owner from the token identity; the client cannot specify it. By default a single ZIP is ≤10MB and the unpacked total is ≤100MB.
For project Skills, prefer the Scene Center → Grape Skill development workflow path; do not hand-write a ZIP and upload it first. Call the upload endpoint directly only when an existing Skill package needs to be migrated.
Skill details and versions
GET /api/skills/by-id/{skill_id}
GET /api/skills/by-id/{skill_id}/versions
GET /api/skills/by-id/{skill_id}/files
Use versions to confirm which version corresponds to a release; use files to inspect the file list in the ZIP without downloading the whole package.
Common errors
| Status | Cause |
|---|---|
| 400 | Invalid ZIP structure or missing Skill name |
| 403 | tk_ used to call a write endpoint, or no repository permission |
| 404 | Skill does not exist |
| 409 | Conflicting Skill with the same name |
Related
Skill management | Agents in detail | Authentication and credentials