---
title: "Create a new attachment"
method: POST
path: "/api/v3/projects/{project_id}/attachments"
tags: ["attachments"]
---

# Create a new attachment

`POST /api/v3/projects/{project_id}/attachments`

## Request

- Base URL: `https://client-api.us.fieldwire.com`
- URL: `https://client-api.us.fieldwire.com/api/v3/projects/{project_id}/attachments`
- Auth: HTTP bearer

## Path parameters

- `project_id` string, uuid, required

## Headers

- `Fieldwire-Version` string, date, required

## Request body

- AttachmentCreateInput: Schema for creating new attachments
  - `id` string, uuid: ID of the attachment
  - `creator_user_id` integer, required: ID of the user who created this attachment
  - `last_editor_user_id` integer, required: ID of the user who most recently edited this attachment
  - `folder_id` string, uuid, nullable: ID of the folder, if this attachment belongs to one
  - `is_dynamic` boolean: Whether the content of this attachment can change without the URL changing
  - `file_url` string, required: URL of the potential processed file
  - `name` string, required: Name of the attachment
  - `original_url` string, nullable: URL of the file originally uploaded by the user
  - `thumb_url` string, nullable: URL of the thumb version of image attachment
  - `file_size` integer, nullable: Attachment file size
  - `kind` 'file' | 'photo' | 'video' | 'photo_sphere' | 'sign': Kind of the attachment
  - `latitude` number, double, nullable: Latitude of where this photo attachment was created
  - `longitude` number, double, nullable: Longitude of where this photo attachment was created
  - `device_created_at` string, date-time, nullable: Time when the device created the attachment
  - `device_updated_at` string, date-time, nullable: Time when the device last updated the attachment
  - `flattened_file_url` string, nullable: URL of the file that has the markups flattened too
  - `deleted_by_two_way_sync` boolean, nullable: Indicates if a file was deleted by two way sync
  - `origin` 'photo_gallery' | 'plan_attachment' | 'form_attachment' | 'bubble_attachment' | 'null', nullable: Indicates the original location an attachment is uploaded from
  - `crop` boolean: Flag to notify whether thumb_url should be populated by cropping this attachment (only applicable for photo & photo_sphere)
  - `floorplan_crop` object: Include if you'd like to crop a floorplan
    - `floorplan_id` string, uuid, required: ID of the floorplan
    - `x1` integer, required: Coordinate x1
    - `x2` integer, required: Coordinate x2
    - `y1` integer, required: Coordinate y1
    - `y2` integer, required: Coordinate y2

## Response `201`

Successful response

- Attachment: Entity that usually show up in the "files" tab
  - `id` string, uuid, required: ID of the attachment
  - `creator_user_id` integer, required: ID of the user who created this attachment
  - `last_editor_user_id` integer, required: ID of the user who most recently edited this attachment
  - `cascade_deleted_by_id` string, uuid, nullable: ID of the item that cascaded its delete to this attachment
  - `folder_id` string, uuid, nullable: ID of the folder, if this attachment belongs to one
  - `project_id` string, uuid, required: ID of the project this attachment belongs to
  - `is_dynamic` boolean, required: Whether the content of this attachment can change without the URL changing
  - `file_url` string, required: URL of the potential processed file
  - `name` string, required: Name of the attachment
  - `original_url` string, nullable: URL of the file originally uploaded by the user
  - `thumb_url` string, nullable: URL of the thumb version of image attachment
  - `file_size` integer, nullable: Attachment file size
  - `floorplans_count` integer, required: Count of active plans this attachment links to
  - `kind` 'file' | 'photo' | 'video' | 'photo_sphere' | 'sign', required: Kind of the attachment
  - `process_state` 'deleting' | 'restoring' | 'null', nullable: Whether this attachment is being restored or deleted
  - `latitude` number, double, nullable: Latitude of where this photo attachment was created
  - `longitude` number, double, nullable: Longitude of where this photo attachment was created
  - `captured_at` string, date-time, nullable: Time when a photo attachment was taken extracted from photo data
  - `created_at` string, date-time, required: Time when the server created the attachment
  - `deleted_at` string, date-time, nullable: Time the server deleted the attachment
  - `resolved_conflict` boolean, nullable, required: Specifies if PUT/PATCH request was rejected - do not store this field!
  - `device_created_at` string, date-time, nullable, required: Time when the device created the attachment
  - `device_updated_at` string, date-time, nullable, required: Time when the device last updated the attachment
  - `updated_at` string, date-time, required: Time when the server last updated the attachment
  - `flattened_file_url` string, nullable: URL of the file that has the markups flattened too
  - `deleted_by_two_way_sync` boolean, nullable, required: Indicates if a file was deleted by two way sync
  - `origin` 'photo_gallery' | 'plan_attachment' | 'form_attachment' | 'bubble_attachment' | 'null', nullable, required: Indicates the original location an attachment is uploaded from

---

[API](https://skmtc.dev/fieldwire/apis/fieldwire-regional-api.md) - [All operations](https://skmtc.dev/fieldwire/apis/fieldwire-regional-api/llms.txt) - [OpenAPI document](https://skmtc.dev/fieldwire/apis/fieldwire-regional-api/revisions/34b820438c0b?raw)
