httpRootProperty property

String? httpRootProperty
getter/setter pair

The root property of the JSON schema where location-data will be attached.

Note: See HTTP Guide at HttpEvent for more information.

See also:

Example

BackgroundGeolocation.ready(Config(
  httpRootProperty: "myData",
  url: "https://my.server.com"
));

{
    "myData":{
        "coords": {
            "latitude":23.232323,
            "longitude":37.373737
        }
    }
}

You may also specify the character httpRootProperty:"." to place your data in the root of the JSON:

{
    "coords": {
        "latitude":23.232323,
        "longitude":37.373737
    }
}

Implementation

String? httpRootProperty;