Tracking Navigine API (JSONAPI)

Authorization

POST SERVER_URL/v1/auth-check?_username={_username}&_password={_password}

Request returns JTW-token.

Parameter Value
_username Username
_password User password

Tracked Objects

Get All Tracked Objects

GET SERVER_URL/v1/api-key/tracked-objects?filter[title][]={filter[title][]}&filter[id][]={filter[id][]}&page[limit]={page[limit]}

Request returns all tracked objects. You can also sort objects by title and id, using parameters below.

Parameters

Header

Parameter Value
Api-key Application key, you can get it from JTW-token

Query

Parameter Value
actv Time is seconds when object is active (date >= now - actv)
sort Sort by keys, ex. -id, -title
{filter[id][]} Filtering data by ID
{filter[title][]} Filtering data by title
{like[title][]} Searching by name
{page[limit]} Number of requested objects
{page[offset]} Offset on query parameters
{like[relationships.tracked-group.title][]} | Filtering data by group name
{filter[relationships.tracked-group.id][]} | Filtering data by group ID

JSON Response Example

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
{
  "data": [
        {
          "type": "string",
          "id": 0,
          "attributes": {
            "title": "string",
            "url": "string",
            "created_at": 0,
            "updated_at": 0,
            "deleted_at": 0
          },
          "relationships": {
              "group": {
                "type": "string",
                "id": 0
              },
              "tracked-beacon": {
                "type": "string",
                "id": 0
              }
          }
        }
  ],
  "included": [{}]
}

Post All Tracked Objects

POST SERVER_URL/v1/api-key/tracked-objects

Request enables to store the client data on web server.

Parameters

Header

Parameter Value
Api-key Application key, you can get it from JTW-token

Query

Body Data, which should store on web server

JSON Body Example

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
  {
    "data": {
      "type": "string",
      "id": 0,
      "attributes": {
        "title": "string",
        "url": "string",
        "created_at": 0,
        "updated_at": 0,
        "deleted_at": 0
      },
      "relationships": {
        "group": {
          "type": "string",
          "id": 0
        },
        "tracked-beacon": {
          "type": "string",
          "id": 0
        }
      }
    }
  }

JSON Response Example

Code 201

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
{
  "data": {
    "type": "string",
    "id": 0,
    "attributes": {
      "title": "string",
      "url": "string",
      "created_at": 0,
      "updated_at": 0,
      "deleted_at": 0
    },
    "relationships": {
      "group": {
        "type": "string",
        "id": 0
      },
      "tracked-beacon": {
        "type": "string",
        "id": 0
      }
    }
  },
  "included": [
    {}
  ]
}

Get Tracked Object by ID

GET SERVER_URL/v1/tracked-objects/{id}

Request returns tracked object by ID.

Parameters

Header

Parameter Value
Api-key Application key, you can get it from JTW-token

Path

id Tracking object ID

JSON Response Example

Code 200

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
{
  "data": {
    "type": "string",
    "id": 0,
    "attributes": {
      "title": "string",
      "url": "string",
      "created_at": 0,
      "updated_at": 0,
      "deleted_at": 0
    },
    "relationships": {
      "group": {
        "type": "string",
        "id": 0
      },
      "tracked-beacon": {
        "type": "string",
        "id": 0
      }
    }
  },
  "included": [
    {}
  ]
}

Patch Tracked Object by ID

PATCH SERVER_URL/v1/tracked-objects/{id}

Request enables change tracked object by ID.

Parameters

Header

Parameter Value
Api-key Application key, you can get it from JTW-token

Path

id Tracking object ID

JSON Body Example

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
{
  "data": {
    "type": "string",
    "id": 0,
    "attributes": {
      "title": "string",
      "url": "string",
      "created_at": 0,
      "updated_at": 0,
      "deleted_at": 0
    },
    "relationships": {
      "group": {
        "type": "string",
        "id": 0
      },
      "tracked-beacon": {
        "type": "string",
        "id": 0
      }
    }
  }
}

JSON Response Example

Code 200

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
{
  "data": {
    "type": "string",
    "id": 0,
    "attributes": {
      "title": "string",
      "url": "string",
      "created_at": 0,
      "updated_at": 0,
      "deleted_at": 0
    },
    "relationships": {
      "group": {
        "type": "string",
        "id": 0
      },
      "tracked-beacon": {
        "type": "string",
        "id": 0
      }
    }
  },
  "included": [
    {}
  ]
}

Delete Tracked Object by ID

DELETE SERVER_URL/v1/tracked-objects/{id}

Request enables delete tracked object by ID.

Parameters

Header

Parameter Value
Api-key Application key, you can get it from JTW-token

Path

id Tracking object ID

JSON Response Example

Code 204

1
Object successfully delete.

Restore Tracked Object by ID

POST SERVER_URL/v1/tracked-objects/{id}/restore

Request enables restore tracked object by ID.

Parameters

Header

Parameter Value
Api-key Application key, you can get it from JTW-token

Path

id Tracking object ID

JSON Response Example

Code 204

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
{
  "data": {
    "type": "string",
    "id": 0,
    "attributes": {
      "title": "string",
      "url": "string",
      "created_at": 0,
      "updated_at": 0,
      "deleted_at": 0
    },
    "relationships": {
      "group": {
        "type": "string",
        "id": 0
      },
      "tracked-beacon": {
        "type": "string",
        "id": 0
      }
    }
  },
  "included": [
    {}
  ]
}