> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://uploadcare.com/docs/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://uploadcare.com/docs/_mcp/server.

# Search files

POST https://api.uploadcare.com/files/search/
Content-Type: application/json

Search files by filename, metadata, MIME type, UUID, or tags using full-text or exact matching, with optional filtering by size, upload date, and file type.

Use `query` for a quick search across all full-text fields at once. Use `phrase` to search specific fields. Use `exact`, `datetime_uploaded`, `size`, `is_image`, or `tags` for structured filtering. At least one condition is required.

**How conditions combine:** all top-level conditions are combined with AND — a file must satisfy every condition you pass. There is no top-level OR and no general NOT. OR is available only within a single `exact` field (multiple values), within `query` (across fields), and in `tags.any`; NOT is available only via `tags.none` and `is_image: false`.

A field cannot appear in both `phrase` and `exact` in the same request.

Full-text matching (`query`, `phrase`) is substring-aware: a term matches anywhere inside a word. Each value must be at least 4 characters; for short or precise values use `exact`.

Set `fuzziness: true` to enable typo-tolerant search. Disabled by default. **Note:** Enabling fuzziness significantly increases query latency.

**Note:** Newly uploaded files are indexed asynchronously and may not appear in search results immediately.

See the [file search guide](https://uploadcare.com/docs/file-search/) for worked examples.

Reference: https://uploadcare.com/docs/api/rest/file/search-files

## Authentication

- `Authorization` header (required) — Every request made to `https://api.uploadcare.com/` MUST be signed. HTTPS SHOULD be used with any authorization scheme. Requests MUST contain the `Authorization` header defining `auth-scheme` and `auth-param`: `Authorization: auth-scheme auth-param`. Every request MUST contain the `Accept` header identifying the REST API version: `Accept: application/vnd.uploadcare-v0.7+json`. There are two available authorization schemes: * For production: `Uploadcare`, a scheme where a `signature`, not your Secret API Key MUST be specified. Signatures SHOULD be generated on backend. * For quick tests: `Uploadcare.Simple`, a simple scheme where your [Secret API Key](https://app.uploadcare.com/projects/-/api-keys/) MUST be specified in every request's `auth-param`.

## Request

### Query parameters

- `limit` (integer, optional, default: 20) — Number of results per page. Range: 1–100. Default: `20`.
- `offset` (integer, optional, default: 0) — Pagination offset. Default: `0`. The sum of `offset` and `limit` must not exceed `1000`.
- `include` (enum, optional) — Include additional fields in each result object. The only supported value is `appdata`, which embeds application data (e.g. moderation or virus-scan results).
  - Allowed values: `appdata`

### Headers

- `Accept` (string, required) — Version header.

### Body (application/json)

This endpoint expects an object.

- `query` (string, optional) — Quick full-text search across all searchable fields (`original_filename`, `metadata`, `detected_mime_type`); fields are OR-ed. Substring-aware (matches anywhere inside a word). The value is also matched against the file UUID with a relevance boost, so pasting a UUID returns that file at the top. Minimum 4 characters.
- `phrase` (FilesSearchPostRequestBodyContentApplicationJsonSchemaPhrase, optional) — Full-text search scoped to specific fields; multiple fields are combined with AND. Substring-aware (matches anywhere inside a word). Each value must be ≥ 4 characters. Cannot reference the same field as `exact`. `metadata` searches across all metadata keys and values at once — to match a specific key, use `exact` with `metadata[key]`.
- `exact` (FilesSearchPostRequestBodyContentApplicationJsonSchemaExact, optional) — Exact value matching. Each key takes a non-empty array of values. Cannot reference the same field as `phrase`. Use `metadata[key]` syntax to match metadata fields, e.g. `"metadata[camera]": ["Canon"]`.
- `datetime_uploaded` (FilesSearchPostRequestBodyContentApplicationJsonSchemaDatetimeUploaded, optional) — Filter by upload date (ISO 8601). Supported operators: `gt`, `gte`, `lt`, `lte`. At least one operator is required; combine two to form a range.
- `size` (FilesSearchPostRequestBodyContentApplicationJsonSchemaSize, optional) — Filter by file size in bytes. Supported operators: `gt`, `gte`, `lt`, `lte`. At least one operator is required; combine two to form a range.
- `is_image` (boolean, optional) — `true` to return images only; `false` to exclude images.
- `fuzziness` (boolean, optional, default: false) — Enable typo-tolerant matching for `query` and `phrase` searches (does not affect `exact`). When `true`, searches tolerate small spelling differences; the allowed edit distance scales with term length (roughly 1 edit for 3–5 characters, 2 for longer). Disabled by default. **Note:** Enabling fuzziness significantly increases query latency.
- `tags` (FilesSearchPostRequestBodyContentApplicationJsonSchemaTags, optional) — Filter files by tags. All specified keys are combined with AND logic. Tag values are normalized (lowercased, whitespace-stripped) before matching.
- `sort` (list of enum, optional) — Sort order. Array of 1–4 unique sort keys. Prefix with `-` for descending order. If omitted, results are ordered by relevance. For filter-only requests (no `query` or `phrase`) there is no relevance to rank by, so pass an explicit sort to get a deterministic order.
  - Allowed values: `score`, `-score`, `datetime_uploaded`, `-datetime_uploaded`, `size`, `-size`, `original_filename`, `-original_filename`

## Response

### 200

Search results.

- `next` (string, optional, nullable) — Next page URL.
- `previous` (string, optional, nullable) — Previous page URL.
- `total` (integer, optional) — Total number of matching files.
- `per_page` (integer, optional) — Number of results per page.
- `results` (list of fileSearchMatch, optional)

## Errors

### 400 Bad Request Error

Validation error. Returned when query parameters or request body fail validation. The response body is a JSON object where keys are field names and values are arrays of error strings. Cross-field errors appear under `non_field_errors`.

- `non_field_errors` (list of string, optional) — Top-level validation errors not tied to a specific field.

### 401 Unauthorized Error

Authorization errors.

- `detail` (enum, optional)
  - Allowed values: `Incorrect authentication credentials.`, `Public key {public_key} not found.`, `Secret key not found.`, `Invalid signature. Please check your Secret key.`

### 403 Forbidden Error

Forbidden. The authenticated project does not have access to the requested resource (for example, revoked API key or blocked account).

- `any`

### 406 Not Acceptable Error

Invalid version header `Accept` for this endpoint.

- `detail` (string, optional, default: Incorrect Accept header provided. Make sure to specify API version. Refer to REST API docs for details.)

### 429 Too Many Requests Error

Request was throttled.

- `detail` (string, optional)

## Types

### FilesSearchPostRequestBodyContentApplicationJsonSchemaPhrase

Full-text search scoped to specific fields; multiple fields are combined with AND. Substring-aware (matches anywhere inside a word). Each value must be ≥ 4 characters. Cannot reference the same field as `exact`. `metadata` searches across all metadata keys and values at once — to match a specific key, use `exact` with `metadata[key]`.

- `original_filename` (string, optional)
- `metadata` (string, optional)
- `detected_mime_type` (string, optional) — Matches against the `mime_type` field in file objects.

### FilesSearchPostRequestBodyContentApplicationJsonSchemaExact

Exact value matching. Each key takes a non-empty array of values. Cannot reference the same field as `phrase`. Use `metadata[key]` syntax to match metadata fields, e.g. `"metadata[camera]": ["Canon"]`.

- `uuid` (list of string, optional)
- `detected_mime_type` (list of string, optional) — Matches against the `mime_type` field in file objects.
- `original_filename` (list of string, optional)

### FilesSearchPostRequestBodyContentApplicationJsonSchemaDatetimeUploaded

Filter by upload date (ISO 8601). Supported operators: `gt`, `gte`, `lt`, `lte`. At least one operator is required; combine two to form a range.

### FilesSearchPostRequestBodyContentApplicationJsonSchemaSize

Filter by file size in bytes. Supported operators: `gt`, `gte`, `lt`, `lte`. At least one operator is required; combine two to form a range.

### FilesSearchPostRequestBodyContentApplicationJsonSchemaTags

Filter files by tags. All specified keys are combined with AND logic. Tag values are normalized (lowercased, whitespace-stripped) before matching.

- `any` (list of string, optional) — File must have **at least one** of these tags.
- `all` (list of string, optional) — File must have **all** of these tags.
- `none` (list of string, optional) — File must have **none** of these tags.

### fileSearchMatch

A single search hit. Same shape as file info (API v0.7 `file` schema — `FileSerializer_v0.7` on the platform) plus an optional `highlight` field. `appdata` appears only when `include=appdata` is passed; `tags` appears when the file tags feature is enabled for the project.

- `datetime_removed` (datetime, required, nullable) — Date and time when a file was removed, if any.
- `datetime_stored` (datetime, required, nullable) — Date and time of the last store request, if any.
- `datetime_uploaded` (datetime, required) — Date and time when a file was uploaded.
- `is_image` (boolean, required) — Is file is image.
- `is_ready` (boolean, required) — Is file is ready to be used after upload.
- `mime_type` (string, required) — File MIME-type.
- `original_file_url` (string, required, nullable) — Publicly available file CDN URL. Available if a file is not deleted.
- `original_filename` (string, required) — Original file name taken from uploaded file.
- `size` (integer, required) — File size in bytes.
- `url` (string, required) — API resource URL for a particular file.
- `uuid` (string, required) — File UUID.
- `variations` (map from string to string, required, nullable) — Dictionary of other files that were created using this file as a source. It's used for video processing and document conversion jobs. E.g., `<conversion_path>: <uuid>`.
- `content_info` (contentInfo, required) — Information about file content.
- `metadata` (metadata, required) — Arbitrary metadata associated with a file.
- `appdata` (applicationDataObject, optional) — Dictionary of application names and data associated with these applications.
- `tags` (list of string, optional) — Ordered list of string tags associated with the file. Empty array if no tags are set.
- `highlight` (fileSearchHighlight, optional) — Matched tokens wrapped in `<em>` tags, present only for fields that matched a full-text condition (`query` / `phrase`). Absent for filter-only matches. `original_filename` and `detected_mime_type` are arrays of highlighted strings. `metadata` is an object keyed by metadata field name.

### contentInfo

Information about file content.

- `mime` (ContentInfoMime, optional) — MIME type.
- `image` (imageInfo, optional) — Image metadata.
- `video` (videoInfo, optional) — Video metadata.

### metadata

Arbitrary metadata associated with a file.

### applicationDataObject

Dictionary of application names and data associated with these applications.

- `aws_rekognition_detect_labels` (awsRekognitionDetectLabels_v2016_06_27, optional)
- `aws_rekognition_detect_moderation_labels` (awsRekognitionDetectModerationLabels_v2016_06_27, optional)
- `remove_bg` (removeBg_v1_0, optional)
- `uc_clamav_virus_scan` (ucClamavVirusScan, optional)

### fileSearchHighlight

Matched tokens wrapped in `<em>` tags, present only for fields that matched a full-text condition (`query` / `phrase`). Absent for filter-only matches. `original_filename` and `detected_mime_type` are arrays of highlighted strings. `metadata` is an object keyed by metadata field name.

- `original_filename` (list of string, optional)
- `detected_mime_type` (list of string, optional)
- `metadata` (map from string to string, optional)

### ContentInfoMime

MIME type.

- `mime` (string, required) — Full MIME type.
- `type` (string, required) — Type of MIME type.
- `subtype` (string, required) — Subtype of MIME type.

### imageInfo

Image metadata.

- `color_mode` (enum, required) — Image color mode.
  - Allowed values: `RGB`, `RGBA`, `RGBa`, `RGBX`, `L`, `LA`, `La`, `P`, `PA`, `CMYK`, `YCbCr`, `HSV`, `LAB`
- `orientation` (integer, required, nullable) — Image orientation from EXIF.
- `format` (string, required) — Image format.
- `sequence` (boolean, required) — Set to true if a file contains a sequence of images (GIF for example).
- `height` (integer, required) — Image height in pixels.
- `width` (integer, required) — Image width in pixels.
- `geo_location` (ImageInfoGeoLocation, required, nullable) — Geo-location of image from EXIF.
- `datetime_original` (datetime, required, nullable) — Image date and time from EXIF. Please be aware that this data is not always formatted and displayed exactly as it appears in the EXIF.
- `dpi` (list of double, required, nullable) — Image DPI for two dimensions.

### videoInfo

Video metadata.

- `duration` (integer, required, nullable) — Video file's duration in milliseconds.
- `format` (string, required) — Video file's format.
- `bitrate` (integer, required, nullable) — Video file's bitrate.
- `audio` (list of VideoInfoAudioItems, required)
- `video` (list of VideoInfoVideoItems, required)

### awsRekognitionDetectLabels_v2016_06_27

- `version` (enum, required) — An application version.
  - Allowed values: `2016-06-27`
- `datetime_created` (datetime, required) — Date and time when an application data was created.
- `datetime_updated` (datetime, required) — Date and time when an application data was updated.
- `data` (AwsRekognitionDetectLabelsV20160627Data, required) — Dictionary with a result of an aws rekognition detect labels execution result.

### awsRekognitionDetectModerationLabels_v2016_06_27

- `version` (enum, required) — An application version.
  - Allowed values: `2016-06-27`
- `datetime_created` (datetime, required) — Date and time when an application data was created.
- `datetime_updated` (datetime, required) — Date and time when an application data was updated.
- `data` (AwsRekognitionDetectModerationLabelsV20160627Data, required) — Dictionary with a result of an aws rekognition detect moderation labels execution result.

### removeBg_v1_0

- `version` (enum, required) — An application version.
  - Allowed values: `1.0`
- `datetime_created` (datetime, required) — Date and time when an application data was created.
- `datetime_updated` (datetime, required) — Date and time when an application data was updated.
- `data` (RemoveBgV10Data, required) — Dictionary with a result of an remove.bg information about an image.

### ucClamavVirusScan

- `version` (enum, required) — An application version.
  - Allowed values: `0.104.2`, `0.104.3`, `0.105.0`, `0.105.1`
- `datetime_created` (datetime, required) — Date and time when an application data was created.
- `datetime_updated` (datetime, required) — Date and time when an application data was updated.
- `data` (UcClamavVirusScanData, required) — Dictionary with a result of ClamAV execution result.

### ImageInfoGeoLocation

Geo-location of image from EXIF.

- `latitude` (double, required) — Location latitude.
- `longitude` (double, required) — Location longitude.

### VideoInfoAudioItems

Audio stream's metadata.

- `bitrate` (integer, required, nullable) — Audio stream's bitrate.
- `codec` (string, required, nullable) — Audio stream's codec.
- `sample_rate` (integer, required, nullable) — Audio stream's sample rate.
- `channels` (integer, required, nullable) — Audio stream's number of channels.

### VideoInfoVideoItems

Video stream's metadata.

- `height` (integer, required) — Video stream's image height.
- `width` (integer, required) — Video stream's image width.
- `frame_rate` (double, required) — Video stream's frame rate.
- `bitrate` (integer, required, nullable) — Video stream's bitrate.
- `codec` (string, required, nullable) — Video stream's codec.

### AwsRekognitionDetectLabelsV20160627Data

Dictionary with a result of an aws rekognition detect labels execution result.

- `LabelModelVersion` (string, required)
- `Labels` (list of AwsRekognitionDetectLabelsV20160627DataLabelsItems, required)

### AwsRekognitionDetectModerationLabelsV20160627Data

Dictionary with a result of an aws rekognition detect moderation labels execution result.

- `ModerationModelVersion` (string, required)
- `ModerationLabels` (list of AwsRekognitionDetectModerationLabelsV20160627DataModerationLabelsItems, required)

### RemoveBgV10Data

Dictionary with a result of an remove.bg information about an image.

- `foreground_type` (string, optional) — foreground classification type (present if type_level was set)

### UcClamavVirusScanData

Dictionary with a result of ClamAV execution result.

- `infected` (boolean, required)
- `infected_with` (string, optional)

### AwsRekognitionDetectLabelsV20160627DataLabelsItems

- `Confidence` (double, required)
- `Instances` (list of AwsRekognitionDetectLabelsV20160627DataLabelsItemsInstancesItems, required)
- `Name` (string, required)
- `Parents` (list of AwsRekognitionDetectLabelsV20160627DataLabelsItemsParentsItems, required)

### AwsRekognitionDetectModerationLabelsV20160627DataModerationLabelsItems

- `Confidence` (double, required)
- `Name` (string, required)
- `ParentName` (string, required)

### AwsRekognitionDetectLabelsV20160627DataLabelsItemsInstancesItems

- `BoundingBox` (AwsRekognitionDetectLabelsV20160627DataLabelsItemsInstancesItemsBoundingBox, optional)
- `Confidence` (double, optional)

### AwsRekognitionDetectLabelsV20160627DataLabelsItemsParentsItems

- `Name` (string, optional)

### AwsRekognitionDetectLabelsV20160627DataLabelsItemsInstancesItemsBoundingBox

- `Height` (double, optional)
- `Left` (double, optional)
- `Top` (double, optional)
- `Width` (double, optional)

## Examples

### Success

**Response**

```json
{
  "next": "https://api.uploadcare.com/files/search/?limit=20&offset=20",
  "previous": null,
  "total": 42,
  "per_page": 20,
  "results": [
    {
      "datetime_removed": null,
      "datetime_stored": "2024-03-15T10:00:01.000000Z",
      "datetime_uploaded": "2024-03-15T10:00:00.000000Z",
      "is_image": true,
      "is_ready": true,
      "mime_type": "image/jpeg",
      "original_file_url": "https://ucarecdn.com/575ed4e8-f4e8-4c14-a58b-1527b6d9ee46/photo.jpg",
      "original_filename": "photo.jpg",
      "size": 145212,
      "url": "https://api.uploadcare.com/files/575ed4e8-f4e8-4c14-a58b-1527b6d9ee46/",
      "uuid": "575ed4e8-f4e8-4c14-a58b-1527b6d9ee46",
      "variations": null,
      "content_info": {
        "mime": {
          "mime": "image/jpeg",
          "type": "image",
          "subtype": "jpeg"
        },
        "image": {
          "color_mode": "RGB",
          "orientation": null,
          "format": "JPEG",
          "sequence": false,
          "height": 600,
          "width": 800,
          "geo_location": null,
          "datetime_original": null,
          "dpi": null
        }
      },
      "metadata": {
        "camera": "Canon"
      },
      "highlight": {
        "original_filename": [
          "<em>photo</em>.jpg"
        ]
      }
    }
  ]
}
```

**SDK Code**

```shell cURL
curl -X POST "https://api.uploadcare.com/files/search/" \
     -H "Accept: application/vnd.uploadcare-v0.7+json" \
     -H "Authorization: Uploadcare.Simple YOUR_PUBLIC_KEY:YOUR_SECRET_KEY" \
     -H "Content-Type: application/json" \
     -d '{
       "phrase": {
         "original_filename": "photo"
       },
       "datetime_uploaded": {
         "gte": "2024-01-01T00:00:00Z"
       },
       "is_image": true
     }'

```

```python Success
import requests

url = "https://api.uploadcare.com/files/search/"

querystring = {"include":"appdata","limit":"20","offset":"0"}

headers = {
    "Accept": "application/vnd.uploadcare-v0.7+json",
    "Authorization": "<apiKey>"
}

response = requests.post(url, headers=headers, params=querystring)

print(response.json())
```

```javascript Success
const url = 'https://api.uploadcare.com/files/search/?include=appdata&limit=20&offset=0';
const options = {
  method: 'POST',
  headers: {Accept: 'application/vnd.uploadcare-v0.7+json', Authorization: '<apiKey>'}
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go Success
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "https://api.uploadcare.com/files/search/?include=appdata&limit=20&offset=0"

	req, _ := http.NewRequest("POST", url, nil)

	req.Header.Add("Accept", "application/vnd.uploadcare-v0.7+json")
	req.Header.Add("Authorization", "<apiKey>")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby Success
require 'uri'
require 'net/http'

url = URI("https://api.uploadcare.com/files/search/?include=appdata&limit=20&offset=0")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["Accept"] = 'application/vnd.uploadcare-v0.7+json'
request["Authorization"] = '<apiKey>'

response = http.request(request)
puts response.read_body
```

```java Success
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.post("https://api.uploadcare.com/files/search/?include=appdata&limit=20&offset=0")
  .header("Accept", "application/vnd.uploadcare-v0.7+json")
  .header("Authorization", "<apiKey>")
  .asString();
```

```php Success
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('POST', 'https://api.uploadcare.com/files/search/?include=appdata&limit=20&offset=0', [
  'headers' => [
    'Accept' => 'application/vnd.uploadcare-v0.7+json',
    'Authorization' => '<apiKey>',
  ],
]);

echo $response->getBody();
```

```csharp Success
using RestSharp;

var client = new RestClient("https://api.uploadcare.com/files/search/?include=appdata&limit=20&offset=0");
var request = new RestRequest(Method.POST);
request.AddHeader("Accept", "application/vnd.uploadcare-v0.7+json");
request.AddHeader("Authorization", "<apiKey>");
IRestResponse response = client.Execute(request);
```

```swift Success
import Foundation

let headers = [
  "Accept": "application/vnd.uploadcare-v0.7+json",
  "Authorization": "<apiKey>"
]

let request = NSMutableURLRequest(url: NSURL(string: "https://api.uploadcare.com/files/search/?include=appdata&limit=20&offset=0")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```

### With appdata

**Response**

```json
{
  "next": "https://api.uploadcare.com/files/search/?limit=20&offset=20&include=appdata",
  "previous": null,
  "total": 42,
  "per_page": 20,
  "results": [
    {
      "datetime_removed": null,
      "datetime_stored": "2024-03-15T10:00:01.000000Z",
      "datetime_uploaded": "2024-03-15T10:00:00.000000Z",
      "is_image": true,
      "is_ready": true,
      "mime_type": "image/jpeg",
      "original_file_url": "https://ucarecdn.com/575ed4e8-f4e8-4c14-a58b-1527b6d9ee46/photo.jpg",
      "original_filename": "photo.jpg",
      "size": 145212,
      "url": "https://api.uploadcare.com/files/575ed4e8-f4e8-4c14-a58b-1527b6d9ee46/",
      "uuid": "575ed4e8-f4e8-4c14-a58b-1527b6d9ee46",
      "variations": null,
      "content_info": {
        "mime": {
          "mime": "image/jpeg",
          "type": "image",
          "subtype": "jpeg"
        },
        "image": {
          "color_mode": "RGB",
          "orientation": null,
          "format": "JPEG",
          "sequence": false,
          "height": 600,
          "width": 800,
          "geo_location": null,
          "datetime_original": null,
          "dpi": null
        }
      },
      "metadata": {
        "camera": "Canon"
      },
      "appdata": {
        "uc_clamav_virus_scan": {
          "version": "0.104.2",
          "datetime_created": "2024-03-15T10:00:00.000000Z",
          "datetime_updated": "2024-03-15T10:00:00.000000Z",
          "data": {
            "infected": false
          }
        }
      },
      "highlight": {
        "original_filename": [
          "<em>photo</em>.jpg"
        ]
      }
    }
  ]
}
```

**SDK Code**

```shell cURL
curl -X POST "https://api.uploadcare.com/files/search/" \
     -H "Accept: application/vnd.uploadcare-v0.7+json" \
     -H "Authorization: Uploadcare.Simple YOUR_PUBLIC_KEY:YOUR_SECRET_KEY" \
     -H "Content-Type: application/json" \
     -d '{
       "phrase": {
         "original_filename": "photo"
       },
       "datetime_uploaded": {
         "gte": "2024-01-01T00:00:00Z"
       },
       "is_image": true
     }'

```

```python With appdata
import requests

url = "https://api.uploadcare.com/files/search/"

querystring = {"include":"appdata","limit":"20","offset":"0"}

headers = {
    "Accept": "application/vnd.uploadcare-v0.7+json",
    "Authorization": "<apiKey>"
}

response = requests.post(url, headers=headers, params=querystring)

print(response.json())
```

```javascript With appdata
const url = 'https://api.uploadcare.com/files/search/?include=appdata&limit=20&offset=0';
const options = {
  method: 'POST',
  headers: {Accept: 'application/vnd.uploadcare-v0.7+json', Authorization: '<apiKey>'}
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go With appdata
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "https://api.uploadcare.com/files/search/?include=appdata&limit=20&offset=0"

	req, _ := http.NewRequest("POST", url, nil)

	req.Header.Add("Accept", "application/vnd.uploadcare-v0.7+json")
	req.Header.Add("Authorization", "<apiKey>")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby With appdata
require 'uri'
require 'net/http'

url = URI("https://api.uploadcare.com/files/search/?include=appdata&limit=20&offset=0")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["Accept"] = 'application/vnd.uploadcare-v0.7+json'
request["Authorization"] = '<apiKey>'

response = http.request(request)
puts response.read_body
```

```java With appdata
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.post("https://api.uploadcare.com/files/search/?include=appdata&limit=20&offset=0")
  .header("Accept", "application/vnd.uploadcare-v0.7+json")
  .header("Authorization", "<apiKey>")
  .asString();
```

```php With appdata
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('POST', 'https://api.uploadcare.com/files/search/?include=appdata&limit=20&offset=0', [
  'headers' => [
    'Accept' => 'application/vnd.uploadcare-v0.7+json',
    'Authorization' => '<apiKey>',
  ],
]);

echo $response->getBody();
```

```csharp With appdata
using RestSharp;

var client = new RestClient("https://api.uploadcare.com/files/search/?include=appdata&limit=20&offset=0");
var request = new RestRequest(Method.POST);
request.AddHeader("Accept", "application/vnd.uploadcare-v0.7+json");
request.AddHeader("Authorization", "<apiKey>");
IRestResponse response = client.Execute(request);
```

```swift With appdata
import Foundation

let headers = [
  "Accept": "application/vnd.uploadcare-v0.7+json",
  "Authorization": "<apiKey>"
]

let request = NSMutableURLRequest(url: NSURL(string: "https://api.uploadcare.com/files/search/?include=appdata&limit=20&offset=0")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```

### Search by Filename and Date

**Request**

```json
{
  "phrase": {
    "original_filename": "photo"
  },
  "datetime_uploaded": null,
  "is_image": true
}
```

**Response**

```json
{
  "next": "https://api.uploadcare.com/files/search/?limit=20&offset=20",
  "previous": null,
  "total": 42,
  "per_page": 20,
  "results": [
    {
      "datetime_removed": null,
      "datetime_stored": "2024-03-15T10:00:01.000000Z",
      "datetime_uploaded": "2024-03-15T10:00:00.000000Z",
      "is_image": true,
      "is_ready": true,
      "mime_type": "image/jpeg",
      "original_file_url": "https://ucarecdn.com/575ed4e8-f4e8-4c14-a58b-1527b6d9ee46/photo.jpg",
      "original_filename": "photo.jpg",
      "size": 145212,
      "url": "https://api.uploadcare.com/files/575ed4e8-f4e8-4c14-a58b-1527b6d9ee46/",
      "uuid": "575ed4e8-f4e8-4c14-a58b-1527b6d9ee46",
      "variations": null,
      "content_info": {
        "mime": {
          "mime": "image/jpeg",
          "type": "image",
          "subtype": "jpeg"
        },
        "image": {
          "color_mode": "RGB",
          "orientation": null,
          "format": "JPEG",
          "sequence": false,
          "height": 600,
          "width": 800,
          "geo_location": null,
          "datetime_original": null,
          "dpi": null
        }
      },
      "metadata": {
        "camera": "Canon"
      },
      "highlight": {
        "original_filename": [
          "<em>photo</em>.jpg"
        ]
      }
    }
  ]
}
```

**SDK Code**

```shell cURL
curl -X POST "https://api.uploadcare.com/files/search/" \
     -H "Accept: application/vnd.uploadcare-v0.7+json" \
     -H "Authorization: Uploadcare.Simple YOUR_PUBLIC_KEY:YOUR_SECRET_KEY" \
     -H "Content-Type: application/json" \
     -d '{
       "phrase": {
         "original_filename": "photo"
       },
       "datetime_uploaded": {
         "gte": "2024-01-01T00:00:00Z"
       },
       "is_image": true
     }'

```

```python Search by Filename and Date
import requests

url = "https://api.uploadcare.com/files/search/"

querystring = {"include":"appdata","limit":"20","offset":"0"}

payload = {
    "phrase": { "original_filename": "photo" },
    "datetime_uploaded": None,
    "is_image": True
}
headers = {
    "Accept": "application/vnd.uploadcare-v0.7+json",
    "Authorization": "<apiKey>",
    "Content-Type": "application/json"
}

response = requests.post(url, json=payload, headers=headers, params=querystring)

print(response.json())
```

```javascript Search by Filename and Date
const url = 'https://api.uploadcare.com/files/search/?include=appdata&limit=20&offset=0';
const options = {
  method: 'POST',
  headers: {
    Accept: 'application/vnd.uploadcare-v0.7+json',
    Authorization: '<apiKey>',
    'Content-Type': 'application/json'
  },
  body: '{"phrase":{"original_filename":"photo"},"datetime_uploaded":null,"is_image":true}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go Search by Filename and Date
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "https://api.uploadcare.com/files/search/?include=appdata&limit=20&offset=0"

	payload := strings.NewReader("{\n  \"phrase\": {\n    \"original_filename\": \"photo\"\n  },\n  \"datetime_uploaded\": null,\n  \"is_image\": true\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("Accept", "application/vnd.uploadcare-v0.7+json")
	req.Header.Add("Authorization", "<apiKey>")
	req.Header.Add("Content-Type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby Search by Filename and Date
require 'uri'
require 'net/http'

url = URI("https://api.uploadcare.com/files/search/?include=appdata&limit=20&offset=0")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["Accept"] = 'application/vnd.uploadcare-v0.7+json'
request["Authorization"] = '<apiKey>'
request["Content-Type"] = 'application/json'
request.body = "{\n  \"phrase\": {\n    \"original_filename\": \"photo\"\n  },\n  \"datetime_uploaded\": null,\n  \"is_image\": true\n}"

response = http.request(request)
puts response.read_body
```

```java Search by Filename and Date
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.post("https://api.uploadcare.com/files/search/?include=appdata&limit=20&offset=0")
  .header("Accept", "application/vnd.uploadcare-v0.7+json")
  .header("Authorization", "<apiKey>")
  .header("Content-Type", "application/json")
  .body("{\n  \"phrase\": {\n    \"original_filename\": \"photo\"\n  },\n  \"datetime_uploaded\": null,\n  \"is_image\": true\n}")
  .asString();
```

```php Search by Filename and Date
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('POST', 'https://api.uploadcare.com/files/search/?include=appdata&limit=20&offset=0', [
  'body' => '{
  "phrase": {
    "original_filename": "photo"
  },
  "datetime_uploaded": null,
  "is_image": true
}',
  'headers' => [
    'Accept' => 'application/vnd.uploadcare-v0.7+json',
    'Authorization' => '<apiKey>',
    'Content-Type' => 'application/json',
  ],
]);

echo $response->getBody();
```

```csharp Search by Filename and Date
using RestSharp;

var client = new RestClient("https://api.uploadcare.com/files/search/?include=appdata&limit=20&offset=0");
var request = new RestRequest(Method.POST);
request.AddHeader("Accept", "application/vnd.uploadcare-v0.7+json");
request.AddHeader("Authorization", "<apiKey>");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{\n  \"phrase\": {\n    \"original_filename\": \"photo\"\n  },\n  \"datetime_uploaded\": null,\n  \"is_image\": true\n}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
```

```swift Search by Filename and Date
import Foundation

let headers = [
  "Accept": "application/vnd.uploadcare-v0.7+json",
  "Authorization": "<apiKey>",
  "Content-Type": "application/json"
]
let parameters = [
  "phrase": ["original_filename": "photo"],
  "datetime_uploaded": ,
  "is_image": true
] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "https://api.uploadcare.com/files/search/?include=appdata&limit=20&offset=0")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```