Geo-tracking stock movements

  1. We have a cold-chain IOT device .So, The data will be basically related to the device and many other parameters.
  2. Currently we are looking out for a system to integrate our data and also track the movement of stock and other functionality and we are currently not having any system as such to track our stock and outbound movements.
  3. So, found this very useful with the features that we require.
  4. Concern is regarding the data integration of our device.
  5. Is there a feature to track the device (Live Tracking)

Awesome. Thanks for the clarification.

Integration with IoT devices is actually on our roadmap ( so I’d be happy to help with that.

How do you want to proceed with that discussion?

To answer your last question … there isn’t yet. But implementing this would be fairly straightforward. I was actually planning to extend the Product Attribute feature to allow users to enter time-series data and then provide analytical views of the historical data.

So for example you could create a Temperature attribute in OpenBoxes, associate it with a UoM (Fahrenheit) and maybe a suitable range (35-46 degrees Fahrenheit). Then have the IoT device would send event data (including product or location) to an API. On receipt of that event, we’d save it as data point on the location or product and then propagate it to a validation rules engine that would determine whether the data is valid (e.g. falls within the range) and subsequently determine what action needs to be taken (e.g. send an alert to users subscribed to this particular topic).

    "event": { 
        "productCode": null,
        "locationCode": "FRIDGE1",
        "attributeCode": "TEMP",
        "uomCode": "FAHRENHEIT",
        "value": 30.9,

This is cool,But the live tracking I was talking was to track the device on the map .
for e.g

So.I Would Like to add a button (say TRACK,Onclick I would Like to get the map)


So,If I have to start By adding a button here ,which are the pages that I should modify and which is the page where I can write the code for this Track button.

Oh that’s even easier. We just need to get your devices to write to the Shipment Events API and integrate a map that uses the event data.

I just need to add geo coordinates to the Event and/or Location entity. Are there other attributes besides time and location that you need to keep track of? Will there be an additional JSON object that you need to store for device properties.

Edit: I’ll create some tickets for the points I made above and we can work on those together. In the meantime I’ll create a very simple endpoint for you to play around with.

Also, is (are?) there metadata related to certain locations besides latitude, longitude that you want to track for a particular event? i.e. this particular location has a name? this particular location is a customs checkpoint?

We could eventually add polygon data to Location and then create a Location Type for countries, districts, cities, buildings etc so we could represent those areas as a set of coordinates and determine when a particular event from a device has occurred within one of those locations. i.e. device has been recorded within Region A > City B > Customs Checkpoint 2. And we could instruct OB to record these particular events as In Customs rather than In Transit.


Yes,There are additional attributes,there will be a json that I will be getting from My API.
(basically this can be like tracking a trip/ride on Uber.So For plotting the Route/Track the basic info may be sufficient,But, later on for any other data that I need will be in the json that I get)

What map API do you want to use?

So, the plan is to use Mapbox API.

@Nuthana_Peta Some news to report. I had a few spare minutes tonight so I built a quick proof of concept using Traccar ( to report GPS coordinates to OpenBoxes.

Here’s a screenshot of the Traccar web interface

The Traccar client on my phone was reporting GPS coordinates to the Traccar server which was then forwarding the coordinates to the OpenBoxes API and OpenBoxes was storing the coordinates in “In Transit” events on a shipment (the shipment was identified by a custom attribute on the Traccar client).

Then I integrated with the MapBox API to display the coordinates. You can see the route as a small gray line in the middle of the map. I haven’t moved much tonight so there’s not much of a route there, but I’m going to test it out on the road tomorrow morning and will report back.

Awesome,Is there a way where I can Extend some features by my self ? Instantly Add buttons or pages,get data by calling my API`s and display the data ondemand,Instead of changing and modifying the code,

At the moment there’s no way to extend the system through plugins/modules if that’s what you mean.

Can you explain specifically what you’re trying to do because I think we might be able to do that through a webhook mechanism that could be more customizable through configuration.

Here’s a live test of the routing prototype. I just drove around Milwaukee a little, the Traccar mobile client sent location updates to the Traccar server and the server forwarded the data to OpenBoxes.

Here’s an example of a data point forwarded by the Traccar server. Right now I’m just plucking longitude and latitude from the JSON. But we could grab whatever properties we want. And actually with something like JSONPath (XPath equivalent for JSON) and some custom attributes we could make this more configurable by allowing a user to specify which data properties they want to keep track of.


Awesome, I would Like to Invoke My Api and integrate the data points with this and check.

Here’s the prototype I cooked up yesterday (in case you want to play around with it).

When I get a chance, I’ll add some comments to the associated issue ( to explain how to integrate with Traccar server if anyone is interested.

But if you just want to display your own API data in the Tracking tab, you just need to add some code to pull the data from your API and stick it in the coordinates array in the GpsApiController.route() closure.

Please note, this was meant to be a quick prototype to estimate the level of effort that would be needed to make this a viable feature. There’s quite a bit of work left to make this production-ready.

So,There are two ways i`m planning to use openboxes .

  1. As an internal system for us to track all the Inbound and Outboud etc.
  2. To give it to our clients as a sample application(an example application with the implementaions of all the client Apis, So that they can either use openboxes or can have a sample application that can be helpful in implementing the APIs into their system. )
  1. To give it to our clients as a sample application(an example application with the implementaions of all the client Apis, So that they can either use openboxes or can have a sample application that can be helpful in implementing the APIs into their system. )

Sure, we can extend the prototype to call out to your API to get data. Can you share any details of the API? Is there any documentation? We can work on a specific feature and push the branch to one of our demo servers so that your users can see a reference implementation of OpenBoxes using your API.