Local Web API

MAXST Developer site RESTful API for local sdk

Authorization

Add the following value to the Request Header

Authorization: Token {User-generated token}

tokenauth.PNG

  • Token Structure : JSON Web Token (JWT)

The JWT payload contains iat (valid for 30 minutes), secId and isLocal.

  • JWT Algorithm : HS256

  • iat : current unix timestamp

  • isLocal : true

  • sec Id(SEC ID), secret(SEC KEY) can be checked by clicking the "Access Keys" button in the group of "Target Manager - Local". localwebapi.png

  • Reference :

  • Sample :

    • secId : "abcde"
    • secret : "secret"
    • iat : 1513732932 (2017-12-20T01:22:12+00:00)
    • isLocal : true
    • Authorization: Token eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpYXQiOjE1MTM3MzI5MzIsInNlY0lkIjoiYWJjZGUiLCJpc0xvY2FsIjp0cnVlfQ.H7V2um1MHkMKZQfv0M9g1KxNoqdkRFCEZPwgVc7-Nmo localwebapijwt.png

Content Type

Content-Type: application/json; charset=utf-8

Create Target

Create a target within an authenticated group

Protocol Method Additional URLs
https POST /api/UN/Trackables

Request Body Param :
Name Type Required Description
Name string true Up to 20 characters consisting only of alphanumeric characters shall be allowed. No duplication is allowed in the group.
UploadFile string true This is the image you are uploading; base64 format byte array (3MB or less) JPG, PNG (32-bit PNG is not supported).
RealWidth float true This is represented in meters (30 cm = 0.3).
OriginalFileName string true The original file name of the image shall be uploaded

Response Body :
Name Type Description
Id string ID
CreateDT Datetime Created Date
UpdateDT Datetime Updated Date
Name string
RealWidth float
OriginalFileName string
WorkStatus string Learning status(standby, ing, complete, fail)
LearnQuality float Learning quality for recognition (0 ~ 5)

Update Target

Edit target for id. Anything that is null or undefined is unmodified.

Protocol Method Additional URLs
https PUT /api/UN/Trackables/{Id}

Request Body Param :
Name Type Required Description
Name string true Up to 20 characters consisting only of alphanumeric characters shall be allowed. No duplication is allowed in the group.

Response Body :
Name Type Description
Id string ID
CreateDT Datetime Created Date
UpdateDT Datetime Updated Date
Name string
RealWidth float
OriginalFileName string
WorkStatus string Learning status(standby, ing, complete, fail)
LearnQuality float Learning quality for recognition (0 ~ 5)

Delete Target

Delete target for id.

Protocol Method Additional URLs
https DELETE /api/UN/Trackables/{Id}

Request Body Param :
Name Type Required Description

Response Body :
Name Type Description
Id string ID

Get Target

Get target for ID.

Protocol Method Additional URLs
https GET /api/UN/Trackables/{Id}

Request Body Param :

Name Type Required Description

Response Body :
Name Type Description
Id string ID
CreateDT Datetime Created Date
UpdateDT Datetime Updated Date
Name string
RealWidth float
OriginalFileName string
WorkStatus string Learning status(standby, ing, complete, fail)
LearnQuality float Learning quality for recognition (0 ~ 5)

Get Target List

Get a list of targets within an authenticated group

Protocol Method Additional URLs
https GET /api/UN/Trackables

Request Body Param :
Name Type Required Description

Response Body :
Name Type Description
array targets

Get Target Group

Get a information about authenticated groups

Protocol Method Additional URLs
https GET /api/UN/TrackableGroupInfo

Request Body Param :
Name Type Required Description

Response Body :
Name Type Description
Id string ID
CreateDT Datetime Created Date
UpdateDT Datetime Updated Date
Name string Group Name
TrackableCnt int Targets Count
TrackableQuota int Targets Quota