---
name: "analyzePetFeature"
mode: "api"
versionRequirements:
  - { name: "@ray-js/ray", version: "1.6.27" }
title: "analyzePetFeature - Pet feature analysis."
---

## analyzePetFeature

> [VERSION] @ray-js/ray >= 1.6.27

### Description

Submit pet feature analysis task

### Parameters

`Params`

| Parameter | Type | Required | Description |
| --- | --- | --- | --- |
| `data` | `PetFeatureAnalyze` | Yes | Request parameters: miniAppId, agentId, ownerId, and images to analyze (list of objectKey values) |

### Return Value

Type: `Promise<string>`

Promise that resolves to the async task ID (string), used to poll getAnalyzePetFeatureResult

### Referenced Types

##### `type` PetFeatureAnalyze

| Property | Type | Description |
| --- | --- | --- |
| `miniAppId` | `string` | Tuya Mini Program ID |
| `agentId` | `string` | Agent ID |
| `ownerId` | `string` | Home ID |
| `images` | `Object[]` | Image information |

##### `type` PetFeatureAnalyze.images

| Property | Type | Description |
| --- | --- | --- |
| `objectKey` | `string` | Image objectKey |


### Examples

#### Request example

```typescript
import { analyzePetFeature } from '@ray-js/ray';

analyzePetFeature({
  miniAppId: 'xxxx',
  agentId: 'xxxx',
  ownerId: 'xxxx',
  images: [
    {
      objectKey: 'xxxx',
    },
  ],
});
```

#### Response example

```json
"xxxxxxx"
```
