---
title: "Create a file (Deprecated)"
description: "Registers a new temporary file and returns a URL for uploading the content."
canonical: "https://signatureapi.com/docs/api/resources/files/create"
source: "https://signatureapi.com/docs/api/resources/files/create.md"
last_verified_api_version: "1.18.0"
last_modified: "2026-11-18T17:22:42Z"
---

# Create a file (Deprecated)

Registers a new temporary file and returns a URL for uploading the content.

_Last verified against API version 1.18.0._

> **Deprecated:** The `/v1/files` endpoint is replaced by the [Upload resource](https://signatureapi.com/docs/api/resources/uploads/object). New integrations use [Create an upload](https://signatureapi.com/docs/api/resources/uploads/create).

Registers a new temporary file. The response includes a `put_url` you use to upload the file content in a second request.

> **Note:** Files are temporary and expire 24 hours after creation. To store files for reuse across multiple envelopes, use the [Library](https://dashboard.signatureapi.com/library) in your dashboard.

## How to upload a file

Creating a usable file requires two steps.

1. **Create a file record**

   Send a POST request to `/v1/files`. No request body is needed.

   The response includes:

   - An `id` for the new file.
   - A `put_url` to upload the file content.
   - An `expires_at` timestamp indicating when the file will be deleted.

   The response also includes a `Location` header with the file's reference URL: `https://api.signatureapi.com/v1/files/{id}`.

2. **Upload the file content**

   Send a PUT request to the `put_url` from the previous response. Set the request body to the raw binary content of your file.

   ```bash
   curl -X PUT "{put_url}" \
     --data-binary "@/path/to/document.pdf" \
     -H "Content-Type: application/pdf"
   ```

   > **Note:** Upload the file as a binary stream. Multipart form uploads are not supported and will produce an invalid file.

3. **Use the file URL in your envelope**

   After uploading, reference the file by its URL in other API calls. Use the `Location` header value from step 1, or construct the URL using the pattern `https://api.signatureapi.com/v1/files/{id}`.

   For example, to use the file as the source of a document:

   ```json Document in the create envelope request
   {
     "url": "https://api.signatureapi.com/v1/files/fil_0nZXZ8pYPByQ4XksJbDl4r",
     "format": "pdf"
   }
   ```

## Returns

Returns a `201 Created` status code on success. The response body includes the following properties:

#### `id` (string)

The unique identifier of the file.

#### `put_url` (string)

A presigned URL. Send a PUT request to this URL with the raw file content to complete the upload. This URL is temporary and should be used immediately.

#### `expires_at` (string)

The date and time when the file will expire, in ISO 8601 format.

### Example: Standard

Registers a temporary file and returns the URL to upload its content to.

```http
POST /v1/files HTTP/1.1
Host: api.signatureapi.com
X-API-Key: YOUR_API_KEY
```

Response 201 Created:

```json
{
  "id": "fil_0nZXZ8pYPByQ4XksJbDl4r",
  "put_url": "https://signatureapi-vault.s3.us-east-2.amazonaws.com/temp/fil_0nZXZ8pYPByQ4XksJbDl4r?X-Amz-Expires=3600&X-Amz-Signature=6e1b0c9d7a",
  "expires_at": "2026-11-02T15:03:11.000Z"
}
```

Errors that any request can return (authentication, rate limits, server errors) are on the [Errors](https://signatureapi.com/docs/api/errors) and [Authentication](https://signatureapi.com/docs/api/authentication) pages.
