---
title: "Upload Object"
method: PUT
path: "/api/storage/buckets/{bucketName}/objects/{objectKey}"
tags: ["Client"]
---

# Upload Object

`PUT /api/storage/buckets/{bucketName}/objects/{objectKey}`

Creates or replaces the object at the exact key, matching S3 PutObject semantics. End-user creates and replacements are gated by the `storage.objects` row-level-security policies; replacing an object never reassigns its ownership.

## Path parameters

- `bucketName` string, required
- `objectKey` string, required

## Response `200`

Object created or replaced

- StoredFile
  - `bucket` string, required — Name of the bucket containing the object
  - `key` string, required — Unique key identifying the object within the bucket
  - `size` integer, required — Size of the file in bytes
  - `mimeType` string — MIME type of the file
  - `uploadedAt` string, date-time, required — ISO timestamp when the file was uploaded
  - `url` string, required — URL to download the file

## Other responses

- `400` — Invalid bucket name, key, or file
- `403` — The caller is not permitted to create or replace this object
- `404` — Bucket not found

---

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