> ## Documentation Index
> Fetch the complete documentation index at: https://moengage-sdk-docs.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Location Triggered

# Installation

To add MoEngage Geofence SDK to your application run the below command from a terminal

<CodeGroup>
  ```NPM npm theme={"theme":{"light":"github-light","dark":"github-dark"}}
  npm install react-native-moengage-geofence
  ```
</CodeGroup>

Note: This plugin is dependent on `react-native-moengage` plugin. Make sure you have installed the `react-native-moengage` plugin as well.

## Android Installation

<Info>
  For location triggered push to work, ensure your Application has:

  * Location permission
  * Play Services Location Library
  * Device's location should be enabled
</Info>

## iOS Installation

To run the application in the new react architecture, follow these steps:

1. Navigate to the iOS folder.
2. Run the command ***RCT\_NEW\_ARCH\_ENABLED=1 bundle exec pod install*** to install the necessary dependencies.

 To run the application in the old react architecture, follow these steps

1. Navigate to the iOS folder.
2. Run the command ***pod install*** to install the necessary dependencies.

# Configure Geofence

By default, the geofence feature is not enabled. To enable the feature call the below API.

<CodeGroup>
  ```TypeScript TypeScript theme={"theme":{"light":"github-light","dark":"github-dark"}}
  import ReactMoEGeofence from 'react-native-moengage-geofence';
  ReactMoEGeofence.startGeofenceMonitoring(YOUR Workspace ID);
  ```
</CodeGroup>

At any time if you want to stop the geofence monitoring or feature use the below API. This API will remove the existing geofences.

<CodeGroup>
  ```TypeScript TypeScript theme={"theme":{"light":"github-light","dark":"github-dark"}}
  import ReactMoEGeofence from 'react-native-moengage-geofence';
  ReactMoEGeofence.stopGeofenceMonitoring(YOUR Workspace ID);
  ```
</CodeGroup>
