SPB Git

Repository Public

create.md 2.0 KB 96 lines markdown

1---2title: Create Skill Version3url: https://platform.claude.com/docs/en/api/skills/versions/create4---56# Create Skill Version78**POST** `/v1/skills/{skill_id}/versions`910Create Skill Version1112## Path parameters1314- `skill_id: string`1516  Unique identifier for the skill.1718  The format and length of IDs may change over time.1920## Headers2122- `"anthropic-workspace-id": optional string`2324## Body parameters (form-data)2526- `files: array of string`2728  Files to upload for the skill.2930  All files must be in the same top-level directory and must include a SKILL.md file at the root of that directory.3132## Returns3334- `SkillVersion object`3536  - `type: "skill_version"`3738    Object type.3940    For Skill Versions, this is always `"skill_version"`.4142    default: skill_version4344  - `id: string`4546    Unique identifier for this Skill Version. The id addresses the version in47    paths and pins it in references.4849  - `created_at: string`5051    ISO 8601 timestamp of when the skill was created.5253    format: date-time5455  - `description: string`5657    Description of the skill version.5859    This is extracted from the SKILL.md file in the skill upload.6061  - `name: string`6263    The Skill's immutable kebab-case slug, set at creation from the first64    upload's SKILL.md frontmatter `name` (or its enclosing directory). Every65    later upload must resolve to the same value. Also the top-level directory66    of the Skill's mounted files and the base name of a downloaded archive.6768  - `skill_id: string`6970    Unique identifier for the skill.7172    The format and length of IDs may change over time.7374## Example7576```bash77curl https://api.anthropic.com/v1/skills/$SKILL_ID/versions \78    -H 'Content-Type: multipart/form-data' \79    -H 'anthropic-version: 2023-06-01' \80    -H "X-Api-Key: $ANTHROPIC_API_KEY" \81    -F 'files[]=@/path/to/file'82```8384### Response (200)8586```json87{88  "id": "id",89  "created_at": "2024-10-30T23:58:27.427722Z",90  "description": "description",91  "name": "name",92  "skill_id": "skill_01JAbcdefghijklmnopqrstuvw",93  "type": "skill_version"94}95```96
Files main
Menu

Theme