---
title: "Upsert artifact"
method: POST
path: "/disk/{disk_id}/artifact"
tags: ["artifact"]
---

# Upsert artifact

`POST /disk/{disk_id}/artifact`

Upload a file and create or update an artifact record under a disk. File size must not exceed the configured maximum upload size limit (default: 16MB).

## Path parameters

- `disk_id` string, uuid, required

## Response `201`

Created

- object
  - `code` integer
  - `error` string
  - `msg` string
  - `data` ModelArtifact
    - `created_at` string
    - `disk_id` string
    - `filename` string
    - `meta` object
    - `path` string
    - `updated_at` string

## Other responses

- `413` — File size exceeds maximum allowed size

---

[API](https://skmtc.dev/memodb-io/apis/acontext-api.md) · [All operations](https://skmtc.dev/memodb-io/apis/acontext-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/memodb-io/acontext-api/revisions/c8775333b1ed/schema)
