SPB Git

Repository Public

artifacts.md 3.3 KB 158 lines markdown

1---2title: Artifacts3url: https://platform.claude.com/docs/en/api/compliance/apps/artifacts4---56# Artifacts78## Get artifact metadata910**GET** `/v1/compliance/apps/artifacts/{artifact_version_id}`1112Returns metadata for an artifact version, without the content body.1314Use the sibling `/content` endpoint to fetch the artifact text. The15`md5` and `size_bytes` fields here are computed over the UTF-816encoding of that text, so a DLP consumer can dedupe or match hashes17without downloading every artifact.1819### Path parameters2021- `artifact_version_id: string`2223  The artifact version ID (tagged ID, e.g., claude_artifact_version_abc123)2425### Headers2627- `"x-api-key": optional string`2829### Returns3031- `id: string`3233  Artifact ID e.g. 'claude_artifact_abc123'3435- `artifact_type: string or null`3637  MIME-like artifact type e.g. 'application/vnd.ant.code'3839- `claude_chat_id: string`4041  The chat this artifact belongs to4243- `created_at: string`4445  Artifact version creation timestamp4647  format: date-time4849- `md5: string`5051  Lowercase hex MD5 of the artifact content (UTF-8 encoded). Matches the `content` field returned by the sibling `/content` endpoint.5253- `size_bytes: number`5455  Size in bytes of the artifact content (UTF-8 encoded)5657- `title: string or null`5859  Artifact title6061- `version_id: string`6263  Artifact version ID e.g. 'claude_artifact_version_abc123'6465### Example6667```bash68curl https://api.anthropic.com/v1/compliance/apps/artifacts/$ARTIFACT_VERSION_ID \69    -H 'anthropic-version: 2023-06-01' \70    -H "Authorization: Bearer $ANTHROPIC_COMPLIANCE_API_KEY"71```7273#### Response (200)7475```json76{77  "id": "id",78  "artifact_type": "artifact_type",79  "claude_chat_id": "claude_chat_id",80  "created_at": "2019-12-27T18:11:19.117Z",81  "md5": "md5",82  "size_bytes": 0,83  "title": "title",84  "version_id": "version_id"85}86```8788## Download artifact content8990**GET** `/v1/compliance/apps/artifacts/{artifact_version_id}/content`9192Download the content of an artifact version for compliance purposes.9394Returns the full text content of the artifact version.9596### Path parameters9798- `artifact_version_id: string`99100  The artifact version ID (tagged ID, e.g., claude_artifact_version_abc123)101102### Headers103104- `"x-api-key": optional string`105106### Example107108```bash109curl https://api.anthropic.com/v1/compliance/apps/artifacts/$ARTIFACT_VERSION_ID/content \110    -H 'anthropic-version: 2023-06-01' \111    -H "Authorization: Bearer $ANTHROPIC_COMPLIANCE_API_KEY"112```113114## Domain types115116### Artifact Retrieve Response117118- `ArtifactRetrieveResponse object`119120  Artifact version metadata for GET /v1/compliance/apps/artifacts/{artifact_version_id}.121122  Returns metadata only. Use the sibling `/content` endpoint to fetch the123  artifact body.124125  - `id: string`126127    Artifact ID e.g. 'claude_artifact_abc123'128129  - `artifact_type: string or null`130131    MIME-like artifact type e.g. 'application/vnd.ant.code'132133  - `claude_chat_id: string`134135    The chat this artifact belongs to136137  - `created_at: string`138139    Artifact version creation timestamp140141    format: date-time142143  - `md5: string`144145    Lowercase hex MD5 of the artifact content (UTF-8 encoded). Matches the `content` field returned by the sibling `/content` endpoint.146147  - `size_bytes: number`148149    Size in bytes of the artifact content (UTF-8 encoded)150151  - `title: string or null`152153    Artifact title154155  - `version_id: string`156157    Artifact version ID e.g. 'claude_artifact_version_abc123'158
Files main
Menu

Theme