Rigs API

VPN based endpoints for managing rigs and rig actions

Update a rigs location

PUT /api/v1/rigs/:id

This endpoint allows a rig to phone home with it's current location, ip address, etc. Rigs are expected to 'phone home' regularly with an update of their location whenever they are connected to the internet. This endpoint updates the device_locations table to provide a history of rig activity. Users can view current locations through the devices list.

Parameters

Name Description
rig_serial serial number of the riq
gpsd_latitude latitude of rig
gpsd_longitude longitude of the rig
local_ip local ip address of the rig
software_version current software version for the rig
git_branch which software branch

Request

Headers

Host: vpn.manager.geocam.xyz
Content-Type: application/x-www-form-urlencoded
Cookie: 

Route

PUT /api/v1/rigs/9999

Body

rig_serial=9999&gpsd_latitude=-45.87416&gpsd_longitude=170.50361&local_ip=127.0.0.1&software_version=0.0.1&git_branch=master

Response

Headers

X-Frame-Options: SAMEORIGIN
X-XSS-Protection: 0
X-Content-Type-Options: nosniff
X-Download-Options: noopen
X-Permitted-Cross-Domain-Policies: none
Referrer-Policy: strict-origin-when-cross-origin
Content-Type: text/plain; charset=utf-8
ETag: W/"843ac01149cced785dfebd0028d3b03b"
Cache-Control: max-age=0, private, must-revalidate
X-Request-Id: cf4c9137-e79c-4f00-a6e3-257307c3d11e
X-Runtime: 0.075168
Vary: Origin
Content-Length: 2

Status

200 OK

Body

Ok