Codelayer API Documentation

  • Introduction

    • General
  • API Reference

    • System

      • License request
      • Register Device
      • Authentication
    • Sales

      • Add Customer
      • Check Customer
      • Device Location
      • Master Place
      • Master Routes
      • Notification Details
      • Product Summary
      • Return details
      • Route Closing
      • Route Customers
      • Route Details
      • Route Path
      • Route Products
      • Route Products Return
      • Route Report
      • Route Return
      • Route Salesmen
      • Route Save
      • Route Save With Remarks
      • Route Shops
      • Sales Closing
      • Sales Details
      • Shop Limit Override Request
      • Stock Transfer
      • Update Device Token
      • Update Notifications
    • Response Codes
Codelayer API Documentation
Register Device

Register a new device for API access. This request should be sent to https://license.codelayer.co.in/

URL

system/register_device

Method

POST

Request Media type

application/json

Response Media type

application/json

Request Parameters
Parameter Data Type Min Max M/O Sample Value Comments
imei String 14 50 M 12345678901234 IMEI or signature of the device.
appID String 3 30 M QM_V3 The ID of the application requesting registration. this ID is a constant for an application and may be shared with the developers of the front end.
clientID String 3 30 M CTPL This is the client Id and each client have their own ID(s).
deviceName String 3 50 M GM Mobile. This is humanly identifiable device name (currently unused and will be used in next revision).
mobileNumber String 10 13 M +919445295492 This is required to manually verify the device to be registered.

 

Response Values
Name Data Type Min Length Max Length M/O Sample Value Comments
status String 2 2 M OK This is the only success response. The device will be manually verified and registered/rejected.

 

Sample Request
{
    "imei": "12345678901234",
    "appID": "QM_V3",
    "clientID": "CTPL",
    "deviceName": "GM Mobile.",
    "mobileNumber": "+919445295492"
}
Sample Success Response
{
    "status": "OK",
    "e": 200,
    "msg": "Success"
}
Sample Failure Responses
{
    "e": 400,
    "msg": "Bad Request."
}
{
    "e": 401,
    "msg": "Invalid authentication credentials."
}
{
    "e": 503,
    "msg": "Service unavailable."
}