Skip to main content
GET
/
devices
/
{deviceId}
/
location
JavaScript
import Mobilerun from '@mobilerun/sdk';

const client = new Mobilerun({
  apiKey: process.env['MOBILERUN_CLOUD_API_KEY'], // This is the default and can be omitted
});

const location = await client.devices.location.get('deviceId');

console.log(location.latitude);
{
  "latitude": 123,
  "longitude": 123,
  "$schema": "<string>"
}

Authorizations

Authorization
string
header
required

Bearer token via Authorization header

Headers

X-Device-Display-ID
integer<int64>
default:0
Required range: x >= 0

Path Parameters

deviceId
string
required

Response

OK

latitude
number<double>
required
longitude
number<double>
required
$schema
string<uri>
read-only

A URL to the JSON Schema for this object.

Example:

"https://example.com/schemas/Location.json"