> For AI agents: the complete documentation index is available at /next/llms.txt, the full documentation bundle is available at /next/llms-full.txt.

# sendGlobalEvent

APISummary
Send global events to the front end through the client, and the front end can listen to the event through `GlobalEventEmitter`.

## Syntax

### Android

```java
public void sendGlobalEvent(String name, JavaOnlyArray params);
```

#### Parameters

- `name`: Global event name.
- `params`: Parameters carried by global events.

### iOS

```objc
- (void)sendGlobalEvent:(nonnull NSString *)name withParams:(nullable NSArray *)params;
```

#### Parameters

- `name`: Global event name.
- `params`: Parameters carried by global events.

### Web

```ts
sendGlobalEvent(eventName: string, params: Cloneable[]): void;
```

#### Parameters

- `eventName`: Global event name.
- `params`: Parameters carried by global events.

### Desktop (C++)

```cpp
void SendGlobalEvent(const std::string& name, const std::string& json);
```

#### Parameters

- `name`: Global event name.
- `json`: The event payload serialized as a JSON string.

## Compatibility

**Compatibility Table**

**Query:** `lynx-native-api.lynx-view.send-global-event`

[Source](https://github.com/lynx-family/lynx-website/tree/main/packages/lynx-compat-data/lynx-native-api/lynx-view/send-global-event.json)

| Feature | Android | HarmonyOS | iOS | macOS | Windows | Web |
| --- | --- | --- | --- | --- | --- | --- |
| send-global-event | Yes (1.0) | No | Yes (1.0) | Yes (3.7) | Yes (3.7) | Yes |

**`send-global-event`**

send global event to js environment

**Specifications:**

