POST api/DEVICES?foreigns={foreigns}
Insert a single record into DEVICES
Request Information
URI Parameters
| Name | Description | Type | Additional information |
|---|---|---|---|
| foreigns |
Optional. Default value is false. True=> Include nested foreign objects within reply. False=> Do NOT Include nested foreign objects within reply |
boolean |
Default value is False |
Body Parameters
Obligatory. The new DEVICES object that need to be added
DEVICES| Name | Description | Type | Additional information |
|---|---|---|---|
| DEVICE_ID | integer |
None. |
|
| TOKEN | string |
Required String length: inclusive between 0 and 300 |
|
| FK_CUSTOMER | integer |
None. |
|
| DEVICE_TYPE |
0= iOS, 1= Android |
byte |
None. |
| UDID | string |
String length: inclusive between 0 and 50 |
|
| LANG | byte |
None. |
|
| CUSTOMERS | CUSTOMERS |
None. |
Request Formats
application/json, text/json
Sample:
{
"DEVICE_ID": 1,
"TOKEN": "sample string 2",
"FK_CUSTOMER": 1,
"DEVICE_TYPE": 64,
"UDID": "sample string 4",
"LANG": 64,
"CUSTOMERS": {
"CUSTOMER_ID": 1,
"CUSTOMER_ID_IMAGE": "d0dd8265-b88e-4425-81e0-8777db33b303",
"CUSTOMER_NAME_AR": "sample string 2",
"CUSTOMER_NAME_EN": "sample string 3",
"FK_EMIRATE": 1,
"EMAIL": "sample string 4",
"MOBILE_NO": "sample string 5",
"LOGIN_PASSWORD": "sample string 6",
"FK_MOBILE_COUNTRY": 7,
"ACTIVE": true,
"NOTES": "sample string 9",
"LAST_NOTIFY_DELETE": "2025-12-08T00:32:18.631Z",
"FK_USER": 1,
"FK_GROUP": 1,
"COUNTRIES": {
"COUNTRY_ID": 1,
"COUNTRY_NO": 2,
"CALLING_CODE": "sample string 3",
"COUNTRY_NAME_AR": "sample string 4",
"COUNTRY_NAME_EN": "sample string 5",
"COUNTRY_CODE2": "sample string 6",
"COUNTRY_CODE3": "sample string 7"
},
"EMIRATES": {
"EMIRATE_ID": 1,
"EMIRATE_NAME_AR": "sample string 2",
"EMIRATE_NAME_EN": "sample string 3"
}
}
}
application/x-www-form-urlencoded
Sample:
Sample not available.
Response Information
Resource Description
DEVICES_CMD_RESPONSE| Name | Description | Type | Additional information |
|---|---|---|---|
| Status | Status |
None. |
|
| DATA | Collection of DEVICES |
None. |
Response Formats
application/json, text/json
Sample:
{
"Status": {
"Success": true,
"MessageEn": "sample string 2",
"MessageAr": "sample string 3",
"DetailedMessage": "sample string 4",
"Code": 0,
"CartErrors": [
{
"ResultStatusCode": 0,
"CartId": 1,
"CorrectValue": {},
"MessageEn": "sample string 2",
"MessageAr": "sample string 3",
"CartCorrectAction": 0
},
{
"ResultStatusCode": 0,
"CartId": 1,
"CorrectValue": {},
"MessageEn": "sample string 2",
"MessageAr": "sample string 3",
"CartCorrectAction": 0
}
]
},
"DATA": [
{
"DEVICE_ID": 1,
"TOKEN": "sample string 2",
"FK_CUSTOMER": 1,
"DEVICE_TYPE": 64,
"UDID": "sample string 4",
"LANG": 64,
"CUSTOMERS": {
"CUSTOMER_ID": 1,
"CUSTOMER_ID_IMAGE": "f4f9fde5-449b-4dc5-9246-5e816a3d1279",
"CUSTOMER_NAME_AR": "sample string 2",
"CUSTOMER_NAME_EN": "sample string 3",
"FK_EMIRATE": 1,
"EMAIL": "sample string 4",
"MOBILE_NO": "sample string 5",
"LOGIN_PASSWORD": "sample string 6",
"FK_MOBILE_COUNTRY": 7,
"ACTIVE": true,
"NOTES": "sample string 9",
"LAST_NOTIFY_DELETE": "2025-12-08T00:32:18.633Z",
"FK_USER": 1,
"FK_GROUP": 1,
"COUNTRIES": {
"COUNTRY_ID": 1,
"COUNTRY_NO": 2,
"CALLING_CODE": "sample string 3",
"COUNTRY_NAME_AR": "sample string 4",
"COUNTRY_NAME_EN": "sample string 5",
"COUNTRY_CODE2": "sample string 6",
"COUNTRY_CODE3": "sample string 7"
},
"EMIRATES": {
"EMIRATE_ID": 1,
"EMIRATE_NAME_AR": "sample string 2",
"EMIRATE_NAME_EN": "sample string 3"
}
}
},
{
"DEVICE_ID": 1,
"TOKEN": "sample string 2",
"FK_CUSTOMER": 1,
"DEVICE_TYPE": 64,
"UDID": "sample string 4",
"LANG": 64,
"CUSTOMERS": {
"CUSTOMER_ID": 1,
"CUSTOMER_ID_IMAGE": "f4f9fde5-449b-4dc5-9246-5e816a3d1279",
"CUSTOMER_NAME_AR": "sample string 2",
"CUSTOMER_NAME_EN": "sample string 3",
"FK_EMIRATE": 1,
"EMAIL": "sample string 4",
"MOBILE_NO": "sample string 5",
"LOGIN_PASSWORD": "sample string 6",
"FK_MOBILE_COUNTRY": 7,
"ACTIVE": true,
"NOTES": "sample string 9",
"LAST_NOTIFY_DELETE": "2025-12-08T00:32:18.633Z",
"FK_USER": 1,
"FK_GROUP": 1,
"COUNTRIES": {
"COUNTRY_ID": 1,
"COUNTRY_NO": 2,
"CALLING_CODE": "sample string 3",
"COUNTRY_NAME_AR": "sample string 4",
"COUNTRY_NAME_EN": "sample string 5",
"COUNTRY_CODE2": "sample string 6",
"COUNTRY_CODE3": "sample string 7"
},
"EMIRATES": {
"EMIRATE_ID": 1,
"EMIRATE_NAME_AR": "sample string 2",
"EMIRATE_NAME_EN": "sample string 3"
}
}
}
]
}
