Skip to content

Skills

Skills

A skill is a folder of instructions and files your agents can use. Its entry point is a SKILL.md file.

Create a skill #

POST /v1/skills

Uploads a skill as separate files or as one ZIP. Each upload creates a new skill. The files are stored, never run.

Body

files[] file
One field per file. Set each filename to its path inside the skill folder, such as basic-math/SKILL.md.
files file
Or one ZIP that contains the skill folder.
  • The folder must contain one SKILL.md that starts with frontmatter: a name (lowercase letters, digits and hyphens, up to 64 characters) and a description (up to 1,024 characters).
  • Up to 4 MB per upload and 500 files.
  • Send it as a multipart form; curl's -F does this for you.
curl
curl -X POST "$MAILA_API_URL/v1/skills" \
  -H "Authorization: Bearer $MAILA_API_KEY" \
  -F 'files[]=@basic-math/SKILL.md;filename=basic-math/SKILL.md' \
  -F 'files[]=@basic-math/calculate.py;filename=basic-math/calculate.py'
Response
{
  "object": "skill",
  "id": "skill_3f9a1c7e5b2d4f6a8c0e1b3d5f7a9c2e",
  "name": "basic-math",
  "description": "Add or multiply numbers.",
  "created_at": 1792335167,
  "default_version": "1",
  "latest_version": "1"
}