SKILL.md and optional supporting files. Upload it once, attach it to agents or to a single session, and the model loads it with the built-in skill tool when it decides it needs it.
- Lazy: only the skill’s name and description are in the model’s context until it is loaded.
- Versioned: uploading the same skill again creates a new revision under the same
skl_…id. A revision’s version id isskr_…. - Frozen per session: a session fixes every skill at a concrete
skr_…version when it is created and keeps it for its whole life. - Shared: a skill is owned by an org, project or user and granted to projects.
/v1/skills (POST /v1/skills is a multipart upload of a folder with a SKILL.md; uploading a name that exists is its next revision, and latest_version_id is the new skr_…); see the API reference.
Attach to an agent
version may be omitted or "latest", which means the newest revision at the moment a session is created, or a skr_… version, which pins that revision for every session of the agent. type: "anthropic" (Anthropic’s prebuilt skills) is rejected. The agent resource keeps showing what you wrote ("latest" stays "latest"); the resolved version is on the session.
Change skills for one session
Passagent_with_overrides when you create a session. skills replaces the agent’s list for this session only; the agent and its version are not touched, so other sessions of the same agent are unaffected.
- Whole-list replacement. To add one skill to what the agent has, read the agent, append, and send the full list.
- Creation only.
POST /v1/sessions/{id}withagent.skillsis400 unsupported; to use other skills, start a new session. - Limits. At most 500 skills per session. A
skill_idmust be owned by the session’s project or granted to it; a skill that does not exist and one you cannot see are both404.
Versions are frozen at creation
When a session is created, each skill in its effective list is resolved once:
Read it back from
session.agent.skills[].version on create, retrieve and list: it is the resolved skr_…, never "latest".
- Running sessions do not upgrade. A skill revision uploaded after the session was created is not seen by that session (instructions, supporting files and
/mnt/skillsall stay on the frozen revision). New sessions get the new revision. To move to it, start a new session. - Same for every new session, with or without an override.
- Deleted revisions. If the frozen revision is deleted while the session is alive, the skill disappears from that session’s
skilltool and/mnt/skills; the session record is not rewritten.
Errors
Errors use the standard envelope. The reason is inerror.bma_error_code; error.code carries the same value during the migration.
Creating or updating an agent that names a skill you cannot use gets the same
404 skill_not_found.
What happens at run time
When the model callsskill, BMA returns the instructions of the session’s frozen revision and installs the supporting files on the session’s computer (API resource: machine). Because skill installs files, it counts as a machine tool: the session’s computer is created if it does not exist yet. The instructions are still returned when installation fails. See Machines & pools.