POST api/devicemodel/RetrieveDeviceModelList?ApplicationKey={ApplicationKey}&APIKey={APIKey}&DeviceID={DeviceID}

This method provides model information of existing devices on the Traxia 6 system.

Request Information

URI Parameters

NameDescriptionTypeAdditional Information
ApplicationKey

The application identity issued by an authorized publisher of Traxia services. This identity is unique and generated one-time during registration.

string

Required

APIKey

Secret key issued to be challenged as identity verification.

string

Required

DeviceID

Unique code to identify a device that connects to the Traxia system, such as IMEI.

string

None

Body Parameters

In the Traxia 6, parameter body consists of parameters and values, the parameters used in this case are includediscard, subcriberid, and orderby.

APIParameters
NameDescriptionTypeAdditional Information
Parameters

New technique from Traxia to simplify filling data in body parameter by just input key value and the system will retrieve the available information.

Collection of Pair of string [key] and string [value]

Required

Request Formats

application/json, text/json

Sample:
// DeviceModel parameter query offers optional filters using key-value pair such as following
{
    "Parameters": [ 
        { 
            "Key": "includediscard", 
            "Value": "false" // mandatory, show your discard data, boolean 
        }, 
        { 
            "Key": "subscriberid", 
            "Value": "1" // mandatory, your subcriber ID, integer 
        }, 
        { 
            "Key": "orderby", 
            "Value": "DeviceModelID" // mandatory, for sorting the data, can change by any param on the output 
        },
        {
            "Key": "gmt",
            "Value": "4" // mandatory, setting time compare to UTC i.e Jakarta:7
        },
        {
            "Key": "fetchrowcount",
            "Value": "1000" // mandatory, the amount of data you want to display
        },
        {
            "Key": "offset",
            "Value": "1" // mandatory, the lower limit of the data you want to display
        },      
        {
            "Key": "roworder",
            "Value": "ASC" // mandatory, ordering of data, option: ASC or DESC
        }
    ] 
}

application/xml, text/xml

Sample:
<APIParameters xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Traxia.Common">
  <Parameters xmlns:d2p1="http://schemas.datacontract.org/2004/07/System.Collections.Generic">
    <d2p1:KeyValuePairOfstringstring>
      <d2p1:key>sample string 1</d2p1:key>
      <d2p1:value>sample string 2</d2p1:value>
    </d2p1:KeyValuePairOfstringstring>
    <d2p1:KeyValuePairOfstringstring>
      <d2p1:key>sample string 1</d2p1:key>
      <d2p1:value>sample string 2</d2p1:value>
    </d2p1:KeyValuePairOfstringstring>
  </Parameters>
</APIParameters>

multipart/form-data

Sample:
<APIParameters xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Traxia.Common"><Parameters xmlns:d2p1="http://schemas.datacontract.org/2004/07/System.Collections.Generic"><d2p1:KeyValuePairOfstringstring><d2p1:key>sample string 1</d2p1:key><d2p1:value>sample string 2</d2p1:value></d2p1:KeyValuePairOfstringstring><d2p1:KeyValuePairOfstringstring><d2p1:key>sample string 1</d2p1:key><d2p1:value>sample string 2</d2p1:value></d2p1:KeyValuePairOfstringstring></Parameters></APIParameters>

application/x-www-form-urlencoded

Sample:

Sample not available.

Response Information

Resource Description

BaseResponse
NameDescriptionTypeAdditional Information
Acknowledge

Acknowledgement of API request format, whether you are submitting the requested parameter in a proper format.

Acknowledge

None

ResponseCode

Indicates the result of your API service process. Negative results may have different code indicators depending on their failure type.

ResponseCode

None

ResponseMessage

Negative API process results may have additional information in text to explain the failure reasons.

string

None

Data

Data provide a universal object response model transformed into JSON compatible format. You will need to recognize the type of returned object model of each of your request. For more information about object class model, please consult our object class library documentation.

Object

None

Latency

integer

None

Response Formats

application/json, text/json

Sample:
// Succesful result of DeviceModel retrieval list may resulted in large json array consisted of activity data in defined request interval
{
    "Acknowledge": 1, 
    "ResponseCode": 200, 
    "ResponseMessage": "Request was succesfully performed.", 
    "Data": [ 
        {
            "DeviceModelID": 3,
            "DeviceModelName": "Smart Tracker",
            "QueueContainer": "SMT-01",
            "CreatedBy": "aulia@dit.co.id",
            "CreatedTimeStamp": "2021-02-23T08:53:06.513",
            "LastUpdateBy": "ambar@dit.co.id",
            "LastUpdateTimeStamp": "2021-02-25T06:50:34",
            "Discard": false,
            "DiscardBy": "aulia@dit.co.id",
            "DiscardTimeStamp": "2021-02-25T06:50:13"
        },
        {
            "DeviceModelID": 2,
            "DeviceModelName": "Fayara2",
            "QueueContainer": "queue-fayara-21",
            "CreatedBy": "aulia@dit.co.id",
            "CreatedTimeStamp": "2021-02-17T10:06:20.03",
            "LastUpdateBy": "ambar@dit.co.id",
            "LastUpdateTimeStamp": "2021-02-25T06:51:18",
            "Discard": false,
            "DiscardBy": "aulia@dit.co.id",
            "DiscardTimeStamp": "2021-02-24T05:07:52"
        } 
    ]      
}