# TrackMeApi.PositionsApi

All URIs are relative to *https://trackme.lk/api/v1*

Method | HTTP request | Description
------------- | ------------- | -------------
[**devicePositionsGet**](PositionsApi.md#devicePositionsGet) | **GET** /positions/{deviceId} | 
[**positionsGet**](PositionsApi.md#positionsGet) | **GET** /positions | 


<a name="devicePositionsGet"></a>
# **devicePositionsGet**
> Position devicePositionsGet(deviceId)



Get latest positions of device with specified identifier

### Example
```javascript
var TrackMeApi = require('track_me_api');
var defaultClient = TrackMeApi.ApiClient.default;

// Configure API key authorization: TrackMe-Api-Key
var TrackMe-Api-Key = defaultClient.authentications['TrackMe-Api-Key'];
TrackMe-Api-Key.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//TrackMe-Api-Key.apiKeyPrefix = 'Token';

var apiInstance = new TrackMeApi.PositionsApi();

var deviceId = 789; // Number | 


var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
apiInstance.devicePositionsGet(deviceId, callback);
```

### Parameters

Name | Type | Description  | Notes
------------- | ------------- | ------------- | -------------
 **deviceId** | **Number**|  | 

### Return type

[**Position**](Position.md)

### Authorization

[TrackMe-Api-Key](../README.md#TrackMe-Api-Key)

### HTTP request headers

 - **Content-Type**: application/json
 - **Accept**: application/json

<a name="positionsGet"></a>
# **positionsGet**
> positionsGet()



List latest positions of all available devices for user

### Example
```javascript
var TrackMeApi = require('track_me_api');
var defaultClient = TrackMeApi.ApiClient.default;

// Configure API key authorization: TrackMe-Api-Key
var TrackMe-Api-Key = defaultClient.authentications['TrackMe-Api-Key'];
TrackMe-Api-Key.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//TrackMe-Api-Key.apiKeyPrefix = 'Token';

var apiInstance = new TrackMeApi.PositionsApi();

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully.');
  }
};
apiInstance.positionsGet(callback);
```

### Parameters
This endpoint does not need any parameter.

### Return type

null (empty response body)

### Authorization

[TrackMe-Api-Key](../README.md#TrackMe-Api-Key)

### HTTP request headers

 - **Content-Type**: application/json
 - **Accept**: application/json

