> ## Documentation Index
> Fetch the complete documentation index at: https://docs.realitydefender.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Media Detail

<ParamField path="requestId" type="string">
  Returns deepfake detection result for specified requestId.
</ParamField>

This endpoint returns the results for a specific upload. When you upload the file, the response of a successful upload will contain the requestId. You can also find your requestId in the URL path when you access the upload in the web application.

### Authorization

To request a pre-signed URL, you must include the `x-api-key` in your request headers. This key is essential for authenticating your request and ensuring secure access to the API.

### Sample Code Snippet

Here's an example of how you can request a pre-signed URL and upload a file.

<CodeGroup>
  ```bash curl theme={null}
  REQUEST_ID="your-requestId"
  API_KEY="your-api-key"

  curl -X GET \
    "https://api.prd.realitydefender.xyz/api/media/users/${REQUEST_ID}" \
    -H "X-API-KEY: ${API_KEY}" \
    -H "Content-Type: application/json"
  ```

  ```python python theme={null}
  import requests 

  requestId = "your-request-id"
  url = f"https://api.prd.realitydefender.xyz/api/media/users/{requestId}"
  headers = {
      "X-API-KEY": "your-api-key",
      "Content-Type": "application/json"
  }

  response = requests.get(url, headers=headers).json()
  print(response.get('filename','N/A'))
  print(response.get('overallStatus','N/A'))


  ```
</CodeGroup>

### Sample Response

```
{
    "filename": "rd-file-name",
    "originalFileName": "original-file-name", 
    "requestId": "request-id",
    "uploadedDate": "uploaded-date",
    "mediaType": "media-type", // AUDIO, VIDEO, TEXT, IMAGE
    "showAudioResult": "show-audio-result", // True, False
    "audioRequestId": "audio-request-id", // populated if showAudioResult is True
    "userId": "user-id",
    "institutionId": "institution-id", 
    "releaseVersion": "2.3.1",
    "resultsSummary": {
        "status": "status", // AUTHENTIC, FAKE, SUSPICIOUS, NOT_APPLICABLE, UNABLE_TO_EVALUATE
        "metadata": {
            "languages": ["language"], // detected languages include english, spanish, and portuguese
            "finalScore": score // ensemble score goes from 0-100
        }
    },
    "models": [
        // individual model results
    ]
}
```

## Response Details

#### NOT\_APPLICABLE

Reality Defender will return NOT\_APPLICABLE as a status if the file contains certain characteristics that are known to impact accuracy.
The reason behind the NOT\_APPLICABLE response will be returned as a list in the `metadata` feel.

For example, see below for a `resultsSummary` returned for an image that was not applicable.

```
"resultsSummary": {
    "status": "NOT_APPLICABLE",
    "metadata": {
      "reasons": [
        {
          "code": "relevance",
          "message": "no faces detected/faces too small"
        }
      ]
    }
}
```

**Image Reasons** <br />
Possible reasons returned for `NOT_APPLICABLE` are:

* code: relevance
  * message: no faces detected/faces too small

**Video Reasons** <br />
Currently, our video files do not output reasons.

**Audio Reasons** <br />
Possible reasons returned for `NOT_APPLICABLE` are:

* code: duration
  * message: audio too short (\<1.5s)
* code: detected
  * message: dialtone and/or music
* code: cross-talk
  * message: more than one speaker detected
* code: quality
  * audio too noisy
* code: language
  * audio is more likely in {language} language

#### UNABLE\_TO\_EVALUATE Response

Reality Defender will return UNABLE\_TO\_EVALUATE if an error occurred while processing the file. This is typically caused by timeouts. You can try again, or upload a smaller file.

Here is an example of the `resultsSummary` returned for an image that is unable to be evaluated.

```
"resultsSummary": {
    "status": "UNABLE_TO_EVALUATE",
    "metadata": {},
    "error": {
      "code": "model-error",
      "message": "An error occurred while processing the file. Please try uploading the file again."
    }
}
```
