> For the complete documentation index, see [llms.txt](https://bitlong.gitbook.io/api-doc/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://bitlong.gitbook.io/api-doc/tapd-api/uploadlogfile.md).

# UploadLogFile

### 1.上传日志文件

*上传已经限制15MB，最大15,728,640字节*

```go
func UploadLogFile(filePath string, deviceId string, info string, auth string) string
```

#### 参数

`filePath` <mark style="color:orange;">string</mark> 文件绝对路径

`deviceId` <mark style="color:orange;">string</mark> 设备ID

`info` <mark style="color:orange;">string</mark> 额外信息

`auth` <mark style="color:orange;">string</mark> 认证信息

> "admin:123456"

#### 响应

```json
{"success":true,"error":"","code":200,"data":null}
```

### 2.查询所有日志文件信息(按时间倒序)

<mark style="color:green;">`GET`</mark>*<http://132.232.109.84:8095/log\\_file\\_upload/get/all>*

### 3.查询所有日志文件信息(按设备号和时间倒序查看)

<mark style="color:green;">`GET`</mark>*<http://132.232.109.84:8095/log\\_file\\_upload/get/all/device\\_id>*

### 4.下载日志文件

<mark style="color:green;">`GET`</mark>*<http://132.232.109.84:8095/log\\_file\\_upload/get/download/id/:id>*

将:id替换为数字ID
