---
name: "getEnterOptionsSync"
mode: "kit"
versionRequirements:
  - { name: "MiniKit", version: "1.0.0" }
  - { name: "@ray-js/ray", version: "0.3.23" }
platform:
  - "iOS"
  - "Android"
---

## getEnterOptionsSync

> [VERSION] MiniKit >= 1.0.0 | @ray-js/ray >= 0.3.23

> [PLATFORM] iOS, Android

### Method signature

```typescript
getEnterOptionsSync()
```

### Description

Get the parameters for this miniapp launch. If it is a cold start, the return value matches the App.onLaunch callback parameters; if it is a warm start, it matches App.onShow.

### Parameters

None


### Referenced Types

##### `interface` ReferrerInfo

| Property | Type | Description |
| --- | --- | --- |
| `appId` | `string` | appId of the source Mini App |
| `extraData` | `Record<string, any>` | Data passed from the source Mini App; supported in specific scenes |


### Valid Values

##### `return.scene`

| Value | Description | Since |
| --- | --- | --- |
| `1000` | Default value | 3.15.0 |
| `1001` | Launched via the Recently Used Mini Programs list | 3.15.0 |
| `1002` | Launched via URL mapping | 3.15.0 |


### Examples

```tsx
import { getEnterOptions } from '@ray-js/ray'

getEnterOptions({
  success: data => {
    console.log(data);
  },
  fail: error => {
    console.error(error);
  },
});
```
