---
name: "getAiVisualReportList"
mode: "kit"
versionRequirements:
  - { name: "@tuya-miniapp/cloud-api", version: "1.0.5" }
---

## getAiVisualReportList

> [VERSION] @tuya-miniapp/cloud-api >= 1.0.5

### Method signature

```typescript
getAiVisualReportList(params: QueryGetAiVisualReportList)
```

### Description

Query Vision Box report list

### Parameters

`Params`

| Parameter | Type | Required | Default | Description |
| --- | --- | --- | --- | --- |
| `params` | `QueryGetAiVisualReportList` | Yes | - | Request body |

### Return Value

Type: `Promise<VisionBoxReport[]>`

Array of VisionBoxReport (for report type, title, status, etc., see minituya response tables and type fields)

### Referenced Types

##### `type` QueryGetAiVisualReportList

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `gid` | `string` | Yes | Home gid |
| `visionBoxId` | `string` | Yes | Vision Cube ID |
| `offset` | `number` | Yes | Page offset |
| `limit` | `number` | Yes | Page size |

##### `interface` VisionBoxReport

| Property | Type | Description |
| --- | --- | --- |
| `visionBoxId` | `string` | Vision Cube ID |
| `modelName` | `string` | Model name |
| `reportId` | `string` | Report ID |
| `reportType` | `"ReportType.DAILY" \\| "ReportType.WEEKLY"` | Report type (daily, weekly, etc.) |
| `reportTitleName` | `string` | Report title |
| `reportContent` | `Object` | Report body (event statistics, etc.) |
| `summaryAndSuggestion` | `string` | Summary and recommendations |
| `detailTitle` | `string` | Details title |
| `totalNumTitle` | `string` | Total count title |
| `reportState` | `number` | Report status |
| `reportStateName` | `string` | Report status name |
| `relatedFileList` | `RelatedFileList[]` | Associated file list |
| `reportKey` | `string` | Report business key |

##### `enum` ReportType

| Enum Value | Actual Value | Description |
| --- | --- | --- |
| `ReportType.DAILY` | `1` | Daily report |
| `ReportType.WEEKLY` | `2` | Weekly report |

##### `type` VisionBoxReport.reportContent

| Property | Type | Description |
| --- | --- | --- |
| `totalEventNum` | `number` | Total number of events |
| `eventInfoList` | `EventInfo[]` | Event information list |

##### `type` RelatedFileList

| Property | Type | Description |
| --- | --- | --- |
| `bucket` | `string` | Storage bucket |
| `filePath` | `string` | File path |
| `signUrl` | `string` | Signed access URL |
| `uuid` | `string` | File UUID |


### Valid Values

##### `ReportType`

| Value | Description | Since |
| --- | --- | --- |
| `1` | Daily report | - |
| `2` | Weekly report | - |


### Examples

#### Request example

```typescript
import { getAiVisualReportList } from '@tuya-miniapp/cloud-api';

getAiVisualReportList({
  gid: '194137',
  visionBoxId: 'vb-1',
  offset: 0,
  limit: 10,
})
  .then((list) => console.log(list))
  .catch(console.error);
```

#### Response example

```json
[
  {
    "visionBoxId": "vb-1",
    "modelName": "model-a",
    "reportId": "r1",
    "reportType": 1,
    "reportTitleName": "Daily Report",
    "summaryAndSuggestion": "",
    "detailTitle": "Details",
    "totalNumTitle": "Total Events",
    "reportState": 1,
    "reportStateName": "Completed"
  }
]
```
