Skip to content

geoKatcher monitors geofences between two layers of geospatial data. It exposes a monitor service to create, read, update and delete monitors, and a healthcheck endpoint. Layers and features are retrieved from a Kano instance discovered over feathers-distributed.


Health

Service status


Service health check

GET
/healthcheck

Returns the service name and its version. The version can be overridden at build time with the VERSION environment variable, and a buildNumber is added when BUILD_NUMBER is set.

Authorizations

bearerAuth

Paste a Kalisio JWT access token to authorize requests sent through the API gateway.

Type
HTTP (bearer)

Responses

Service is up

application/json
JSON
{
  
"name": "geokatcher",
  
"version": "1.0.0",
  
"buildNumber": "42"
}

Playground

Server
Authorization

Samples


Monitors


List monitors

GET
/monitor

Returns the stored monitors. Feathers query parameters are supported through the query string (e.g. ?monitor.name=my-monitor). Pagination is disabled, so the response is a plain array.

Authorizations

bearerAuth

Paste a Kalisio JWT access token to authorize requests sent through the API gateway.

Type
HTTP (bearer)

Responses

The matching monitors

application/json
JSON
[
  
{
  
  
"target": {
  
  
  
"name": "layer1",
  
  
  
"filter": {
  
  
  
},
  
  
  
"layerInfo": {
  
  
  
  
"kanoService": "features",
  
  
  
  
"layerId": "663e3593fb7a85c83f5084fe"
  
  
  
}
  
  
},
  
  
"zone": {
  
  
  
"name": "layer1",
  
  
  
"filter": {
  
  
  
},
  
  
  
"layerInfo": {
  
  
  
  
"kanoService": "features",
  
  
  
  
"layerId": "663e3593fb7a85c83f5084fe"
  
  
  
}
  
  
},
  
  
"monitor": {
  
  
  
"name": "string",
  
  
  
"description": "",
  
  
  
"enabled": true,
  
  
  
"type": "string",
  
  
  
"trigger": [
  
  
  
  
[
  
  
  
  
  
"patched"
  
  
  
  
]
  
  
  
],
  
  
  
"evaluation": {
  
  
  
  
"alertOn": "data",
  
  
  
  
"type": "geoIntersects",
  
  
  
  
"maxDistance": 0,
  
  
  
  
"minDistance": 0
  
  
  
},
  
  
  
"action": {
  
  
  
  
"type": "no-webhook",
  
  
  
  
"cooldown": 60,
  
  
  
  
"url": "string",
  
  
  
  
"additionalProperties": {
  
  
  
  
  
"organisation": "string",
  
  
  
  
  
"token": "string",
  
  
  
  
  
"data": {
  
  
  
  
  
  
"template": "string",
  
  
  
  
  
  
"name": "string",
  
  
  
  
  
  
"description": "string"
  
  
  
  
  
}
  
  
  
  
}
  
  
  
},
  
  
  
"lastRun": {
  
  
  
  
"date": "string",
  
  
  
  
"lastActionRun": 0,
  
  
  
  
"alert": "string",
  
  
  
  
"status": {
  
  
  
  
  
"success": true,
  
  
  
  
  
"error": {
  
  
  
  
  
  
"message": "Layer not found",
  
  
  
  
  
  
"data": {
  
  
  
  
  
  
}
  
  
  
  
  
}
  
  
  
  
}
  
  
  
}
  
  
}
  
}
]

Playground

Server
Authorization

Samples


Create a monitor

POST
/monitor

Validates the monitor structure, then runs the evaluation once before saving. If either fails, nothing is persisted and the error is returned.

Set monitor.type to dryRun to test a monitor without persisting it, running its action or emitting events: name and trigger are then optional and the response is a DryRunResult instead of a stored monitor.

Authorizations

bearerAuth

Paste a Kalisio JWT access token to authorize requests sent through the API gateway.

Type
HTTP (bearer)

Request Body

application/json
JSON
{
  
"target": {
  
  
"name": "layer1",
  
  
"filter": {
  
  
},
  
  
"layerInfo": {
  
  
  
"kanoService": "features",
  
  
  
"layerId": "663e3593fb7a85c83f5084fe"
  
  
}
  
},
  
"zone": {
  
  
"name": "layer1",
  
  
"filter": {
  
  
},
  
  
"layerInfo": {
  
  
  
"kanoService": "features",
  
  
  
"layerId": "663e3593fb7a85c83f5084fe"
  
  
}
  
},
  
"monitor": {
  
  
"name": "string",
  
  
"description": "",
  
  
"enabled": true,
  
  
"type": "string",
  
  
"trigger": [
  
  
  
[
  
  
  
  
"patched"
  
  
  
]
  
  
],
  
  
"evaluation": {
  
  
  
"alertOn": "data",
  
  
  
"type": "geoIntersects",
  
  
  
"maxDistance": 0,
  
  
  
"minDistance": 0
  
  
},
  
  
"action": {
  
  
  
"type": "no-webhook",
  
  
  
"cooldown": 60,
  
  
  
"url": "string",
  
  
  
"additionalProperties": {
  
  
  
  
"organisation": "string",
  
  
  
  
"token": "string",
  
  
  
  
"data": {
  
  
  
  
  
"template": "string",
  
  
  
  
  
"name": "string",
  
  
  
  
  
"description": "string"
  
  
  
  
}
  
  
  
}
  
  
},
  
  
"lastRun": {
  
  
  
"date": "string",
  
  
  
"lastActionRun": 0,
  
  
  
"alert": "string",
  
  
  
"status": {
  
  
  
  
"success": true,
  
  
  
  
"error": {
  
  
  
  
  
"message": "Layer not found",
  
  
  
  
  
"data": {
  
  
  
  
  
}
  
  
  
  
}
  
  
  
}
  
  
}
  
}
}

Responses

The created monitor, or a dry-run result when monitor.type is dryRun

application/json
JSON
{
  
"target": {
  
  
"name": "layer1",
  
  
"filter": {
  
  
},
  
  
"layerInfo": {
  
  
  
"kanoService": "features",
  
  
  
"layerId": "663e3593fb7a85c83f5084fe"
  
  
}
  
},
  
"zone": {
  
  
"name": "layer1",
  
  
"filter": {
  
  
},
  
  
"layerInfo": {
  
  
  
"kanoService": "features",
  
  
  
"layerId": "663e3593fb7a85c83f5084fe"
  
  
}
  
},
  
"monitor": {
  
  
"name": "string",
  
  
"description": "",
  
  
"enabled": true,
  
  
"type": "string",
  
  
"trigger": [
  
  
  
[
  
  
  
  
"patched"
  
  
  
]
  
  
],
  
  
"evaluation": {
  
  
  
"alertOn": "data",
  
  
  
"type": "geoIntersects",
  
  
  
"maxDistance": 0,
  
  
  
"minDistance": 0
  
  
},
  
  
"action": {
  
  
  
"type": "no-webhook",
  
  
  
"cooldown": 60,
  
  
  
"url": "string",
  
  
  
"additionalProperties": {
  
  
  
  
"organisation": "string",
  
  
  
  
"token": "string",
  
  
  
  
"data": {
  
  
  
  
  
"template": "string",
  
  
  
  
  
"name": "string",
  
  
  
  
  
"description": "string"
  
  
  
  
}
  
  
  
}
  
  
},
  
  
"lastRun": {
  
  
  
"date": "string",
  
  
  
"lastActionRun": 0,
  
  
  
"alert": "string",
  
  
  
"status": {
  
  
  
  
"success": true,
  
  
  
  
"error": {
  
  
  
  
  
"message": "Layer not found",
  
  
  
  
  
"data": {
  
  
  
  
  
}
  
  
  
  
}
  
  
  
}
  
  
}
  
}
}

Playground

Server
Authorization
Body

Samples


Get a monitor by id

GET
/monitor/{id}

Authorizations

bearerAuth

Paste a Kalisio JWT access token to authorize requests sent through the API gateway.

Type
HTTP (bearer)

Responses

The monitor

application/json
JSON
{
  
"target": {
  
  
"name": "layer1",
  
  
"filter": {
  
  
},
  
  
"layerInfo": {
  
  
  
"kanoService": "features",
  
  
  
"layerId": "663e3593fb7a85c83f5084fe"
  
  
}
  
},
  
"zone": {
  
  
"name": "layer1",
  
  
"filter": {
  
  
},
  
  
"layerInfo": {
  
  
  
"kanoService": "features",
  
  
  
"layerId": "663e3593fb7a85c83f5084fe"
  
  
}
  
},
  
"monitor": {
  
  
"name": "string",
  
  
"description": "",
  
  
"enabled": true,
  
  
"type": "string",
  
  
"trigger": [
  
  
  
[
  
  
  
  
"patched"
  
  
  
]
  
  
],
  
  
"evaluation": {
  
  
  
"alertOn": "data",
  
  
  
"type": "geoIntersects",
  
  
  
"maxDistance": 0,
  
  
  
"minDistance": 0
  
  
},
  
  
"action": {
  
  
  
"type": "no-webhook",
  
  
  
"cooldown": 60,
  
  
  
"url": "string",
  
  
  
"additionalProperties": {
  
  
  
  
"organisation": "string",
  
  
  
  
"token": "string",
  
  
  
  
"data": {
  
  
  
  
  
"template": "string",
  
  
  
  
  
"name": "string",
  
  
  
  
  
"description": "string"
  
  
  
  
}
  
  
  
}
  
  
},
  
  
"lastRun": {
  
  
  
"date": "string",
  
  
  
"lastActionRun": 0,
  
  
  
"alert": "string",
  
  
  
"status": {
  
  
  
  
"success": true,
  
  
  
  
"error": {
  
  
  
  
  
"message": "Layer not found",
  
  
  
  
  
"data": {
  
  
  
  
  
}
  
  
  
  
}
  
  
  
}
  
  
}
  
}
}

Playground

Server
Authorization

Samples


Replace a monitor

PUT
/monitor/{id}

Full update: the whole monitor is replaced, so nothing is inherited. monitor.name and monitor.enabled must be provided explicitly, and monitor.type may only be cron or event (not dryRun). The structure is validated and re-evaluated before saving.

Authorizations

bearerAuth

Paste a Kalisio JWT access token to authorize requests sent through the API gateway.

Type
HTTP (bearer)

Request Body

application/json
JSON
{
  
"target": {
  
  
"name": "layer1",
  
  
"filter": {
  
  
},
  
  
"layerInfo": {
  
  
  
"kanoService": "features",
  
  
  
"layerId": "663e3593fb7a85c83f5084fe"
  
  
}
  
},
  
"zone": {
  
  
"name": "layer1",
  
  
"filter": {
  
  
},
  
  
"layerInfo": {
  
  
  
"kanoService": "features",
  
  
  
"layerId": "663e3593fb7a85c83f5084fe"
  
  
}
  
},
  
"monitor": {
  
  
"name": "string",
  
  
"description": "",
  
  
"enabled": true,
  
  
"type": "string",
  
  
"trigger": [
  
  
  
[
  
  
  
  
"patched"
  
  
  
]
  
  
],
  
  
"evaluation": {
  
  
  
"alertOn": "data",
  
  
  
"type": "geoIntersects",
  
  
  
"maxDistance": 0,
  
  
  
"minDistance": 0
  
  
},
  
  
"action": {
  
  
  
"type": "no-webhook",
  
  
  
"cooldown": 60,
  
  
  
"url": "string",
  
  
  
"additionalProperties": {
  
  
  
  
"organisation": "string",
  
  
  
  
"token": "string",
  
  
  
  
"data": {
  
  
  
  
  
"template": "string",
  
  
  
  
  
"name": "string",
  
  
  
  
  
"description": "string"
  
  
  
  
}
  
  
  
}
  
  
},
  
  
"lastRun": {
  
  
  
"date": "string",
  
  
  
"lastActionRun": 0,
  
  
  
"alert": "string",
  
  
  
"status": {
  
  
  
  
"success": true,
  
  
  
  
"error": {
  
  
  
  
  
"message": "Layer not found",
  
  
  
  
  
"data": {
  
  
  
  
  
}
  
  
  
  
}
  
  
  
}
  
  
}
  
}
}

Responses

The updated monitor

application/json
JSON
{
  
"target": {
  
  
"name": "layer1",
  
  
"filter": {
  
  
},
  
  
"layerInfo": {
  
  
  
"kanoService": "features",
  
  
  
"layerId": "663e3593fb7a85c83f5084fe"
  
  
}
  
},
  
"zone": {
  
  
"name": "layer1",
  
  
"filter": {
  
  
},
  
  
"layerInfo": {
  
  
  
"kanoService": "features",
  
  
  
"layerId": "663e3593fb7a85c83f5084fe"
  
  
}
  
},
  
"monitor": {
  
  
"name": "string",
  
  
"description": "",
  
  
"enabled": true,
  
  
"type": "string",
  
  
"trigger": [
  
  
  
[
  
  
  
  
"patched"
  
  
  
]
  
  
],
  
  
"evaluation": {
  
  
  
"alertOn": "data",
  
  
  
"type": "geoIntersects",
  
  
  
"maxDistance": 0,
  
  
  
"minDistance": 0
  
  
},
  
  
"action": {
  
  
  
"type": "no-webhook",
  
  
  
"cooldown": 60,
  
  
  
"url": "string",
  
  
  
"additionalProperties": {
  
  
  
  
"organisation": "string",
  
  
  
  
"token": "string",
  
  
  
  
"data": {
  
  
  
  
  
"template": "string",
  
  
  
  
  
"name": "string",
  
  
  
  
  
"description": "string"
  
  
  
  
}
  
  
  
}
  
  
},
  
  
"lastRun": {
  
  
  
"date": "string",
  
  
  
"lastActionRun": 0,
  
  
  
"alert": "string",
  
  
  
"status": {
  
  
  
  
"success": true,
  
  
  
  
"error": {
  
  
  
  
  
"message": "Layer not found",
  
  
  
  
  
"data": {
  
  
  
  
  
}
  
  
  
  
}
  
  
  
}
  
  
}
  
}
}

Playground

Server
Authorization
Body

Samples


Delete a monitor

DELETE
/monitor/{id}

Stops the monitor's schedule/listeners and removes it from the database.

Authorizations

bearerAuth

Paste a Kalisio JWT access token to authorize requests sent through the API gateway.

Type
HTTP (bearer)

Responses

The deleted monitor

application/json
JSON
{
  
"target": {
  
  
"name": "layer1",
  
  
"filter": {
  
  
},
  
  
"layerInfo": {
  
  
  
"kanoService": "features",
  
  
  
"layerId": "663e3593fb7a85c83f5084fe"
  
  
}
  
},
  
"zone": {
  
  
"name": "layer1",
  
  
"filter": {
  
  
},
  
  
"layerInfo": {
  
  
  
"kanoService": "features",
  
  
  
"layerId": "663e3593fb7a85c83f5084fe"
  
  
}
  
},
  
"monitor": {
  
  
"name": "string",
  
  
"description": "",
  
  
"enabled": true,
  
  
"type": "string",
  
  
"trigger": [
  
  
  
[
  
  
  
  
"patched"
  
  
  
]
  
  
],
  
  
"evaluation": {
  
  
  
"alertOn": "data",
  
  
  
"type": "geoIntersects",
  
  
  
"maxDistance": 0,
  
  
  
"minDistance": 0
  
  
},
  
  
"action": {
  
  
  
"type": "no-webhook",
  
  
  
"cooldown": 60,
  
  
  
"url": "string",
  
  
  
"additionalProperties": {
  
  
  
  
"organisation": "string",
  
  
  
  
"token": "string",
  
  
  
  
"data": {
  
  
  
  
  
"template": "string",
  
  
  
  
  
"name": "string",
  
  
  
  
  
"description": "string"
  
  
  
  
}
  
  
  
}
  
  
},
  
  
"lastRun": {
  
  
  
"date": "string",
  
  
  
"lastActionRun": 0,
  
  
  
"alert": "string",
  
  
  
"status": {
  
  
  
  
"success": true,
  
  
  
  
"error": {
  
  
  
  
  
"message": "Layer not found",
  
  
  
  
  
"data": {
  
  
  
  
  
}
  
  
  
  
}
  
  
  
}
  
  
}
  
}
}

Playground

Server
Authorization

Samples


Partially update a monitor

PATCH
/monitor/{id}

Partial update: only the supplied fields change, the rest are inherited from the stored monitor. Two exceptions, because a section that is supplied only inherits its name:

  • when updating a layer element (target or zone), its filter must be provided again to be kept, otherwise it is dropped;
  • when updating monitor.action, its additionalProperties must be provided again to be kept, otherwise it is dropped.

These constraints only apply to the part actually being updated.

Authorizations

bearerAuth

Paste a Kalisio JWT access token to authorize requests sent through the API gateway.

Type
HTTP (bearer)

Request Body

application/json
JSON
{
  
"target": {
  
  
"name": "layer1",
  
  
"filter": {
  
  
},
  
  
"layerInfo": {
  
  
  
"kanoService": "features",
  
  
  
"layerId": "663e3593fb7a85c83f5084fe"
  
  
}
  
},
  
"zone": {
  
  
"name": "layer1",
  
  
"filter": {
  
  
},
  
  
"layerInfo": {
  
  
  
"kanoService": "features",
  
  
  
"layerId": "663e3593fb7a85c83f5084fe"
  
  
}
  
},
  
"monitor": {
  
  
"name": "string",
  
  
"description": "",
  
  
"enabled": true,
  
  
"type": "string",
  
  
"trigger": [
  
  
  
[
  
  
  
  
"patched"
  
  
  
]
  
  
],
  
  
"evaluation": {
  
  
  
"alertOn": "data",
  
  
  
"type": "geoIntersects",
  
  
  
"maxDistance": 0,
  
  
  
"minDistance": 0
  
  
},
  
  
"action": {
  
  
  
"type": "no-webhook",
  
  
  
"cooldown": 60,
  
  
  
"url": "string",
  
  
  
"additionalProperties": {
  
  
  
  
"organisation": "string",
  
  
  
  
"token": "string",
  
  
  
  
"data": {
  
  
  
  
  
"template": "string",
  
  
  
  
  
"name": "string",
  
  
  
  
  
"description": "string"
  
  
  
  
}
  
  
  
}
  
  
},
  
  
"lastRun": {
  
  
  
"date": "string",
  
  
  
"lastActionRun": 0,
  
  
  
"alert": "string",
  
  
  
"status": {
  
  
  
  
"success": true,
  
  
  
  
"error": {
  
  
  
  
  
"message": "Layer not found",
  
  
  
  
  
"data": {
  
  
  
  
  
}
  
  
  
  
}
  
  
  
}
  
  
}
  
}
}

Responses

The patched monitor

application/json
JSON
{
  
"target": {
  
  
"name": "layer1",
  
  
"filter": {
  
  
},
  
  
"layerInfo": {
  
  
  
"kanoService": "features",
  
  
  
"layerId": "663e3593fb7a85c83f5084fe"
  
  
}
  
},
  
"zone": {
  
  
"name": "layer1",
  
  
"filter": {
  
  
},
  
  
"layerInfo": {
  
  
  
"kanoService": "features",
  
  
  
"layerId": "663e3593fb7a85c83f5084fe"
  
  
}
  
},
  
"monitor": {
  
  
"name": "string",
  
  
"description": "",
  
  
"enabled": true,
  
  
"type": "string",
  
  
"trigger": [
  
  
  
[
  
  
  
  
"patched"
  
  
  
]
  
  
],
  
  
"evaluation": {
  
  
  
"alertOn": "data",
  
  
  
"type": "geoIntersects",
  
  
  
"maxDistance": 0,
  
  
  
"minDistance": 0
  
  
},
  
  
"action": {
  
  
  
"type": "no-webhook",
  
  
  
"cooldown": 60,
  
  
  
"url": "string",
  
  
  
"additionalProperties": {
  
  
  
  
"organisation": "string",
  
  
  
  
"token": "string",
  
  
  
  
"data": {
  
  
  
  
  
"template": "string",
  
  
  
  
  
"name": "string",
  
  
  
  
  
"description": "string"
  
  
  
  
}
  
  
  
}
  
  
},
  
  
"lastRun": {
  
  
  
"date": "string",
  
  
  
"lastActionRun": 0,
  
  
  
"alert": "string",
  
  
  
"status": {
  
  
  
  
"success": true,
  
  
  
  
"error": {
  
  
  
  
  
"message": "Layer not found",
  
  
  
  
  
"data": {
  
  
  
  
  
}
  
  
  
  
}
  
  
  
}
  
  
}
  
}
}

Playground

Server
Authorization
Body

Samples