# API Levels

Defines functions for working with Android API levels.

## Summary

| ### Functions ||
|---|---|
| `https://developer.android.com/ndk/reference/group/apilevels#group__apilevels_1ga79b134cadc2dfed84268e67fd9e2dfd6()` | `int` Returns the API level of the device we're actually running on, or -1 on failure. |

## Functions

### android_get_device_api_level

Declared in `android/api-level.h`

```
int android_get_device_api_level()
```
Returns the API level of the device we're actually running on, or -1 on failure.

The returned value is the same as the Java `Build.VERSION.SDK_INT`. This is mostly useful for an app to work out what version of the OS it's running on. See also android_get_application_target_sdk_version().

Available since API level 29.