# 3.4.2-Query Status for Offline Uploaded File in Chatflow

## 1. Overview

* **Interface Name**: Query status for the offline uploaded file
* **Version number**: v1.0.0

## 2. Information

* **Request method**: GET
* **Request URL**: https\://*DOMAIN*/openapi/v1/chatflow/get\_offline\_file\_status/
* **Domain**: *Refer to "Service address description"*

## 3. Request parameters

Request header http header field:

| Parameter name        | Type   | Required | Description             |
| --------------------- | ------ | -------- | ----------------------- |
| Content-Type          | string | Yes      | Fixed`application/json` |
| cybertron-robot-key   | string | Yes      | Robot key               |
| cybertron-robot-token | string | Yes      | Robot token             |

Request body field:

| Parameter name | Type   | Required | Description                   |
| -------------- | ------ | -------- | ----------------------------- |
| username       | string | Yes      | User account                  |
| file\_id       | string | Yes      | file id returned by above API |

## 4. Response field description

HTTP status code: 200 OK

Response field description:

| Field Name     | Type   | Description                                                                                                                    |
| -------------- | ------ | ------------------------------------------------------------------------------------------------------------------------------ |
| code           | string | "000000" is normal, other exceptions                                                                                           |
| message        | string | Status description                                                                                                             |
| data           | object | message body                                                                                                                   |
| file\_id       | int    | file id                                                                                                                        |
| status         | int    | file status; 1:uploading 2:upload finish 3:upload failed 4:parsing 5: parse finish 6:parse failed 7:flow success 8:flow failed |
| error\_msg     | string | error message                                                                                                                  |
| file\_name     | string | file name                                                                                                                      |
| parse\_content | string | file parsed content                                                                                                            |
| llm\_content   | string | content returned by llm node in flow                                                                                           |

## 5. Example

Request Example:

```bash
curl --location 'https://_DOMAIN_/openapi/v1/chatflow/get_offline_file_status/?file_id=6' \
--header 'cybertron-robot-key: qN7xiUNHTVZ2******M3Edg%3D' \
--header 'cybertron-robot-token: MTczMjc4MDQ3OTMyNwp*******mFVaWJZbVZIWHA2S3gzRy9wT1U9' \
--header 'username: aaa@brgroup.com'
```

Response example:

```json
{
    "code": "000000",
    "message": "susses",
    "data": {
        "file_id": 6,
        "status": 5,
        "error_msg": "",
        "file_name": "820033.wav",
        "parse_content": "['[{\"text\": \"\\\\message1\", \"speaker_id\": 0}, {\"text\": \"\\\\message2\", \"speaker_id\": 1}, {\"text\": \"\\\\message3\", \"speaker_id\": 1}]']",
        "llm_content": null
    }
}
```
