resources
Uploads a custom skill from a local directory and keeps it current. The directory must contain a SKILL.md with name and description frontmatter; its basename becomes the skill's top-level directory. The provider hashes the files on every plan: when the content changes it uploads a new skill version and latest_version_id moves. Skills have no update endpoint and the API returns no content hash, so changes made outside Terraform are not detected. terraform destroy deletes the skill and every version. Set delete_on_destroy = false to leave it in place. Deleting a version that an agent or deployment pins breaks them at run time. ~> The Managed Agents API is in beta. This resource needs api_key (a regular workspace API key, not an Admin key) and workspace_id when the key can reach more than one workspace.
- License 许可
- MPL-2.0
- 最近更新
- 2026-11-09
- Stars
- ★ 0
- Forks
- 0
01 前言 Front Matter
- page_title
- anthropic_skill Resource - Anthropic Enterprise
- description
- Uploads a custom skill from a local directory and keeps it current. The directory must contain a SKILL.md with name and description frontmatter; its basename becomes the skill's top-level directory. The provider hashes the files on every plan: when the content changes it uploads a new skill version and latest_version_id moves. Skills have no update endpoint and the API returns no content hash, so changes made outside Terraform are not detected. terraform destroy deletes the skill and every version. Set delete_on_destroy = false to leave it in place. Deleting a version that an agent or deployment pins breaks them at run time. ~> The Managed Agents API is in beta. This resource needs api_key (a regular workspace API key, not an Admin key) and workspace_id when the key can reach more than one workspace.
- subcategory
- Skills
02 资源文件 22
- 参考文档agent.md5.3 KB
- 参考文档api_key.md2.6 KB
- 参考文档compliance_settings.md1.4 KB
- 参考文档deployment.md6.6 KB
- 参考文档environment.md4.2 KB
- 参考文档external_key.md3.1 KB
- 参考文档federation_issuer.md4.1 KB
- 参考文档federation_rule_workspace.md1.8 KB
- 参考文档federation_rule.md5.3 KB
- 参考文档invite.md2.3 KB
- 参考文档memory_store.md2.6 KB
- 参考文档memory.md4.0 KB
- 参考文档rbac_group_member.md1.6 KB
- 参考文档rbac_group.md1.9 KB
- 参考文档service_account.md2.9 KB
- 参考文档spend_limit.md2.2 KB
- 参考文档user.md2.4 KB
- 参考文档vault_credential.md7.5 KB
- 参考文档vault.md2.2 KB
- 参考文档workspace_member.md2.8 KB
- 参考文档workspace_service_account.md2.9 KB
- 参考文档workspace.md3.3 KB
03 SKILL.md 正文
anthropic_skill (Resource)
Uploads a custom skill from a local directory and keeps it current. The directory must contain a SKILL.md with name and description frontmatter; its basename becomes the skill's top-level directory. The provider hashes the files on every plan: when the content changes it uploads a new skill version and latest_version_id moves. Skills have no update endpoint and the API returns no content hash, so changes made outside Terraform are not detected.
terraform destroy deletes the skill and every version. Set delete_on_destroy = false to leave it in place. Deleting a version that an agent or deployment pins breaks them at run time.
~> The Managed Agents API is in beta. This resource needs api_key (a regular workspace API key, not an Admin key) and workspace_id when the key can reach more than one workspace.
Example Usage
# The directory must contain SKILL.md; its basename becomes the skill folder.
resource "anthropic_skill" "release_notes" {
source_dir = "${path.module}/skills/example-skill"
}
resource "anthropic_agent" "writer" {
name = "release-writer"
model = "claude-sonnet-5"
skills = [
{ type = "custom", skill_id = anthropic_skill.release_notes.id, version = anthropic_skill.release_notes.latest_version_id },
]
}
<!-- schema generated by tfplugindocs -->
Schema
Required
source_dir(String) Local directory holdingSKILL.mdand up to 20 files (30 MB total). Changing the path forces a new skill.
Optional
delete_on_destroy(Boolean) Delete the skill (all versions) on destroy. Defaults totrue. Imported resources start withfalse, so removing one from configuration cannot destroy it until you opt in.display_name(String) Display label, up to 255 characters. Defaults to theSKILL.mdname. Cannot be changed after creation.
Read-Only
content_hash(String) SHA-256 over the sorted file paths and contents ofsource_dir, computed locally on every plan.created_at(String) Creation timestamp (RFC 3339).id(String) Skill id (skill_...).latest_version_id(String) Id of the newest version; pin agents to it withskills[].version.name(String) Slug from theSKILL.mdfrontmatter; every version must keep it.source_type(String) Alwayscustomfor uploaded skills.updated_at(String) Last update timestamp (RFC 3339).
Import
Import is supported using the following syntax:
The terraform import command can be used, for example:
terraform import anthropic_skill.release_notes skill_01ExampleSkillId000000000
04 同仓库更多 Skills
example-skill
Turns a changelog into release notes with a consistent structure.
data-sources
Reads one skill and its latest version. ~> The Managed Agents API is in beta. This resource needs api_key (a regular workspace API key, not an Admin key) and workspace_id when the key can reach more than one workspace.