Documentation forAdministrator
Support

Device (Asset) API

moduleAPI Documentation Updated 17 Oct 2026

Device (Asset) API

Product: NEXTMEGABYTE (Greenitco ITAM) · Module: API Documentation · Audience: Developer, Administrator

This page lists the NEXTMEGABYTE REST API endpoints for devices. All URLs are relative to your portal, for example https://your-domain.com/api/.... Authenticate first with the Login API and send the standard headers described in the API Overview. Example values are shortened and anonymized.

Delete a device

POST /api/device/delete/device_id

Deletes a device by its ID.

Headers: standard authenticated headers (apptoken, token, Content-Type: application/x-www-form-urlencoded). See API Overview.

Example response (values shortened and anonymized)

{
  "status": "success",
  "msg": "Device has been deleted successfully!"
}

Get device information

GET /api/device-info/device_id

Returns full details of a device by its ID.

Headers: standard authenticated headers (apptoken, token, Content-Type: application/x-www-form-urlencoded). See API Overview.

Top-level response fields: status, msg, data, custom_fields, custom_fields_count, profile_imgs

Example response (values shortened and anonymized)

{
  "status": "success",
  "msg": "Device details fetch successfully",
  "data": [
    {
      "id": 1097,
      "asset_tag": "<string>",
      "mdl_id": 321,
      "mdl_name": "<string>",
      "modelno": null,
      "manu_name": "<string>",
      "cmp_name": "<string>",
      "rtd_location_id": 1,
      "loc_name": "<string>",
      "internal_place_id": null,
      "internal_place": null,
      "cat_name": "<string>",
      "name": "XXXXX",
      "serial": "<string>",
      "company_id": 1,
      "assigned_to": null,
      "assigned_for": null,
      "last_checkout_project": null,
      "ip": "<string>",
      "mac": "<string>",
      "...": "83 more fields"
    }
  ],
  "custom_fields": [
    {
      "name": "Project",
      "format": "<string>",
      "element": "<string>",
      "required": 1,
      "field_code": "<string>",
      "option_type": 1,
      "predefined_options": {
        "_itm_project": 1
      }
    },
    "..."
  ],
  "custom_fields_count": 2,
  "profile_imgs": []
}

Get device audit data

GET /api/device-audits/common-data

Returns lists needed for device audits, such as ratings and statuses.

Headers: standard authenticated headers (apptoken, token, Content-Type: application/x-www-form-urlencoded). See API Overview.

Example response (values shortened and anonymized)

{
  "status": "success",
  "msg": "",
  "ratings": [
    {
      "id": 1,
      "text": "<string>"
    },
    "..."
  ]
}

Start a device audit

POST /api/device-audits/init

Creates an audit record for a device (verifier, rating, date and images).

Headers: standard authenticated headers (apptoken, token, Content-Type: application/x-www-form-urlencoded). See API Overview.

Request Body Parameters

Parameter Type Required Description
device_id String Yes device_id

Example request

{
  "device_id": "<string>"
}

Example response (values shortened and anonymized)

{
  "status": "success",
  "msg": "New Device Audit has been initiated.",
  "id": 1286
}

Check in a device

POST /api/device-checkin

Returns a checked-out device to stock with a new status.

Headers: standard authenticated headers (apptoken, token, Content-Type: application/x-www-form-urlencoded). See API Overview.

Request Body Parameters

Parameter Type Required Description
id String Yes 1234
status_id: String Yes 1234
checkin_at String Yes
note: String Yes yes
stock_place String Yes

Example request

{ "id": "1234", "status_id": "1234" "checkin_at": "", "note": "yes", "stock_place": "" }

Example response (values shortened and anonymized)

{
  "status": "success",
  "msg": "Chosen device has been checked In successfully."
}

Check out a device

POST /api/device-checkout

Assigns a device to a user or internal place.

Headers: standard authenticated headers (apptoken, token, Content-Type: application/x-www-form-urlencoded). See API Overview.

Request Body Parameters

Parameter Type Required Description
id String Yes 1234
name: String Yes 1234
allocation_type_id String Yes
assigned_for: String Yes yes
assigned_to String Yes
last_checkout_project: String Yes 1234
checkout_at String Yes
expected_checkin: String Yes yes
note String Yes

Example request

{ "id": "348", "name": "test" "allocation_type_id:": "2", "assigned_for": "1", "assigned_to": "590", "last_checkout_project":"53", "checkout_at:":"DDMMYYYY", "expected_checkin:":"DDMMYYYY", "note:":"" }

Example response (values shortened and anonymized)

{
  "status": "success",
  "msg": "Chosen device has been checked out successfully",
  "project_id": 53
}

Get device form data

GET /api/device-common-data

Returns lists used in device forms, such as companies, models, categories, locations, statuses and suppliers.

Headers: standard authenticated headers (apptoken, token, Content-Type: application/x-www-form-urlencoded). See API Overview.

Example response (shortened)

\`\`\`json { "status": [ { "id": 6, "text": "Deployed" }, { "id": 5, "text": "Lost-Stolen" }, { "id": 4, "text": "Out for Repair" }, { "id": 2, "text": "Pending" }, { "id": 11, "text": "Ready on Stock" }, { "id": 1, "text": "Ready to Deploy" }, { "id": 3, "text": "Scrap" } ], "msg": "", "leaser": [ { "id": 10, "leaser_id": 1 }, { "id": 26, "leaser_id": 1 }, { "id": 18, "leaser_id": 1 }, { "id": 20 …

List device status labels

POST /api/ajax-status-label

Returns the device status labels.

Headers: standard authenticated headers (apptoken, token, Content-Type: application/x-www-form-urlencoded). See API Overview.

Example response (values shortened and anonymized)

{
  "status": "success",
  "msg": "",
  "data": [
    {
      "id": 6,
      "text": "<string>"
    },
    "..."
  ]
}

List devices

POST /api/ajax-device-list

Returns a paged, filterable list of devices.

Headers: standard authenticated headers (apptoken, token, Content-Type: application/x-www-form-urlencoded). See API Overview.

Request Body Parameters

Parameter Type Required Description
search_key String Yes test
order_dir: String Yes 1234
order_by String Yes 1234
index:: String Yes 1

Example request

{ "search_key": "test", "order_dir": "1234" "order_by": "1234", "index": "1" }

Top-level response fields: code, status, message, tot, filter_record, current_index, is_prev_index, is_next_index, data

Example response (values shortened and anonymized)

{
  "code": 200,
  "status": "success",
  "message": "",
  "tot": 917,
  "filter_record": 156,
  "current_index": 0,
  "is_prev_index": 0,
  "is_next_index": 1,
  "data": [
    {
      "id": 1056,
      "asset_tag": "<string>",
      "mdl_name": "<string>",
      "manu_name": "<string>",
      "cmp_name": "<string>",
      "loc_name": "<string>",
      "cat_name": "<string>",
      "name": null,
      "serial": "<string>",
      "company_id": 1,
      "assigned_to": null,
      "assigned_for": null,
      "last_checkout_project": null,
      "warranty_months": null,
      "invoice_id": 1,
      "warranty_status": 2,
      "device_rfid": null,
      "full_name": null,
      "device_transfer_status": "<string>",
      "last_checkout_on": null,
      "...": "25 more fields"
    },
    "..."
  ]
}

List asset departments

POST /api/getAssetDepartments

Returns departments that own assets.

Headers: standard authenticated headers (apptoken, token, Content-Type: application/x-www-form-urlencoded). See API Overview.

Top-level response fields: status, msg, pagination, results

Example response (values shortened and anonymized)

{
  "status": "success",
  "msg": "Department fetched successfully.",
  "pagination": {
    "more": false
  },
  "results": [
    {
      "id": 28,
      "text": "<string>"
    },
    "..."
  ]
}

List asset owners

POST /api/all-user-dropdown-list

Returns users that can be selected as asset owner or assignee.

Headers: standard authenticated headers (apptoken, token, Content-Type: application/x-www-form-urlencoded). See API Overview.

Request Body Parameters

Parameter Type Required Description
search String Yes test
page: String Yes 1

Example request

{
  "search": "<string>",
  "page": "<string>"
}

Top-level response fields: tot, filter_record, current_index, is_prev_index, is_next_index, status, msg, data

Example response (values shortened and anonymized)

{
  "tot": 41,
  "filter_record": 41,
  "current_index": 0,
  "is_prev_index": 0,
  "is_next_index": 1,
  "status": "success",
  "msg": "",
  "data": [
    {
      "id": 114,
      "text": "<string>"
    },
    "..."
  ]
}

List currencies

POST /api/api-price-dropdown-list

Returns the available purchase currencies.

Headers: standard authenticated headers (apptoken, token, Content-Type: application/x-www-form-urlencoded). See API Overview.

Example response (shortened)

{ "status": "success", "currencies": [ { "name": "US/Canadian/etc Dollar", "symbol": "\$", "symbol_html": "\$", "key": "USD" }, { "name": "GBP - British Pounds", "symbol": "£", "symbol_html": "&pound;", "key": "GBP" }, { "name": "EUR - Euros", "symbol": "€", "symbol_html": "&euro;", "key": "EUR" }, { "name": "BGN - Bulgarian lev", "symbol": "лв.", "symbol_html": "лв.", "key": "BGN" }, { "name": "B …

Get device custom fields

POST /api/device/custom-field

Returns the custom fields for a device model.

Headers: standard authenticated headers (apptoken, token, Content-Type: application/x-www-form-urlencoded). See API Overview.

Example response (values shortened and anonymized)

{
  "custom_fields": [
    {
      "name": "Project",
      "format": "<string>",
      "element": "<string>",
      "required": 1,
      "field_code": "<string>",
      "option_type": 1,
      "predefined_options": {
        "_itm_project": 1
      }
    },
    "..."
  ]
}

List stock places

POST /api/device/stock-place/1

Returns internal places that can be used as stock places.

Headers: standard authenticated headers (apptoken, token, Content-Type: application/x-www-form-urlencoded). See API Overview.

Top-level response fields: code, status, message, data

Example response (values shortened and anonymized)

{
  "code": 200,
  "status": "success",
  "message": "",
  "data": [
    {
      "id": 56,
      "company_id": 1,
      "text": "<string>"
    },
    "..."
  ]
}

List device types

POST /api/device/asset-type

Returns the device types.

Headers: standard authenticated headers (apptoken, token, Content-Type: application/x-www-form-urlencoded). See API Overview.

Top-level response fields: code, status, message, data

Example response (values shortened and anonymized)

{
  "code": 200,
  "status": "success",
  "message": "",
  "data": [
    {
      "id": 3,
      "text": "<string>"
    },
    "..."
  ]
}

Find devices by RFID

POST /api/v2/getDeviceForDropDown

Returns devices matching RFID tags or UUIDs.

Headers: standard authenticated headers (apptoken, token, Content-Type: application/x-www-form-urlencoded). See API Overview.

Request Body Parameters

Parameter Type Required Description
search String Yes test
page String Yes 1

Example request

{
  "search": "<string>",
  "page": "<string>"
}

Top-level response fields: status, msg, pagination, results

Example response (values shortened and anonymized)

{
  "status": "success",
  "msg": "Data fetch successfully",
  "pagination": {
    "more": true
  },
  "results": [
    {
      "id": 4,
      "asset_tag": "<string>",
      "asset_name": null,
      "name": "Vaio F series",
      "modelno": "<string>",
      "serial": "<string>",
      "text": "<string>"
    },
    "..."
  ]
}

List internal places

POST /api/device/internalplace

Returns the internal places of a location.

Headers: standard authenticated headers (apptoken, token, Content-Type: application/x-www-form-urlencoded). See API Overview.

Top-level response fields: code, status, message, data

Example response (values shortened and anonymized)

{
  "code": 200,
  "status": "success",
  "message": "",
  "data": [
    {
      "id": 26,
      "text": "<string>"
    },
    "..."
  ]
}

Get status board

GET /api/status-board

Returns the asset status board summary.

Headers: standard authenticated headers (apptoken, token, Content-Type: application/x-www-form-urlencoded). See API Overview.

Example response (values shortened and anonymized)

{
  "status": "success",
  "msg": "",
  "data": {
    "group": [
      {
        "title": "Web team",
        "items": [
          {
            "...": "..."
          },
          "..."
        ],
        "total_items": 2
      },
      "..."
    ],
    "incedents": [
      {
        "date": "<string>",
        "entries": []
      },
      "..."
    ],
    "IiemStatus": {
      "1": "<string>",
      "2": "<string>",
      "3": "<string>",
      "4": "<string>"
    },
    "dashboard_details": [
      {
        "tot_items": 7,
        "tot_active": "<string>",
        "tot_per_iss": "<string>",
        "tot_par_out": "<string>",
        "tot_major": "<string>"
      }
    ]
  }
}

Receive a transferred device

POST /api/v2/info-received-transfer/device_id

Confirms that a device under transfer has been received at the destination.

Headers: standard authenticated headers (apptoken, token, Content-Type: application/x-www-form-urlencoded). See API Overview.

Example response (values shortened and anonymized)

{
  "status": "success",
  "msg": "Device Received Successfully."
}

Restore a sold device

POST /api/device/restore_sold_device/device_id

Restores a device from Sold status (Super Admin only).

Headers: standard authenticated headers (apptoken, token, Content-Type: application/x-www-form-urlencoded). See API Overview.

Example response (values shortened and anonymized)

{
  "status": "success",
  "msg": "Sold Out Device restored successfully"
}