---
title: "Create File"
method: POST
path: "/files"
tags: ["files"]
---

# Create File

`POST /files`

## Request body

- CreateFileRequest — Payload for creating a file
  - `name` string, required
  - `description` string
  - `mime_type` string, nullable
  - `content` string, required
  - `project` string, nullable

## Response `201`

Successful Response

- File
  - `id` string, uuid, required
  - `created_at` string, date-time, required
  - `name` string, required
  - `description` string
  - `mime_type` string, nullable
  - `content` string, required
  - `project` string, nullable
  - `size` integer, required
  - `hash` string, required

## Other responses

- `422` — Validation Error

## Changes

- **2025-05-12** `3b58badc86fa` — 2 info
  - added the new optional request property `project`
  - added the optional property `project` to the response with the `201` status
- **2025-01-27** `f87931a479bd` — 1 warning, 7 info
  - removed the optional property `jobs` from the response with the `201` status
  - added the optional property `description` to the response with the `201` status
  - added the optional property `mime_type` to the response with the `201` status
  - added the required property `content` to the response with the `201` status
  - …4 more

[Change history](https://skmtc.dev/julep-ai/apis/julep-agents-api/changes/files/post.md)

---

[API](https://skmtc.dev/julep-ai/apis/julep-agents-api.md) · [All operations](https://skmtc.dev/julep-ai/apis/julep-agents-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/julep-ai/julep-agents-api/revisions/21c8182519ef/schema)
