> For the complete documentation index, see [llms.txt](https://support.marscat.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://support.marscat.io/development-guide/frontend-development/api-interface/api-interface-details/level-0/getsafeareainsets.md).

# getSafeAreaInsets

Used to get the safe area insets at the top and bottom of mobile devices, suitable for UI adaptation on notch and full-screen models.

Request Parameters: None

Response Parameters:

| Parameter Name | Type | Description                     |
| -------------- | ---- | ------------------------------- |
| safeAreaTop    | Int  | Height of the top safe area.    |
| safeAreaBottom | Int  | Height of the bottom safe area. |

Call Example:

{% code title="example.js" %}

```javascript
const response = await relayx.getSafeAreaInsets();
if (response.code === 200) {
  console.log("Safe Area Info:", response.result);
}
```

{% endcode %}
