The NEDAP ANPR LUMO License Plate Reader offers automatic number plate reading. The camera can be configured through the web based interface. For integration purposes there is a REST API available.
This API can be used for different purposes, like integration with the available access list.
A commonly used tool to test REST API Commands next to CURL is postman https://www.postman.com/
In the attachment you can also find some POSTMAN examples link to attachment
A complete list of commands is available in the "ANPR LUMO Developerguide"
Login
This API Endpoint is used to login with own credentials on the server. The login is required in order to perform any other action taken on the server.
URL | Method | URL Parameter | Data parameter |
/login | post | None | login_string |
Parameter
login_string
string with following format : "username=your_username&password=your_password"
Examples:
# login
curl --cookie cookies.log --cookie-jar cookies.log http://192.168.3.15/login --data "username=admin&password=secret"
Digital IO
On the camera the Digital IO pins can be used with the API Endpoint for pin status fetching and for activation/deactivation of available outputs. GET method can be used to fetch status of all pins and PATCH to set the status of an output pin.
URL | Method | URL Parameter | Data parameter |
/digitalio | GET | none | none |
/digitalio | PATCH | none | :value |
Parameters
Value that specifies output pin and the status to be set on given pin. Value is JSON struct with following format:
parameter | Value Format |
:value | { "index": pin number <integer>, "set": true to activate or false to deactivate selected pin } |
examples
# login
curl --cookie cookies.log --cookie-jar cookies.log http://192.168.3.15/login --data "username=admin&password=secret"
# get status of digital IO
curl --cookie cookies.log --cookie-jar cookies.log -X GET http://192.168.3.15/digitalio
# activate status of the output pin #1
curl --cookie cookies.log --cookie-jar cookies.log -X PATCH http://192.168.3.15/digitalio --data '{"index":1, "set":true}'
Retrieve TEXT Result
This API Endpoint returns a specified amount of results that were last captured by the ANPR LUMO camera.
note: you first need to enable the text results to be stored in the Lumo front end. you can do this by changing the max historical list length, and list hours.
URL | Method | URL Parameter | Data parameter |
/text/results | GET | none | json |
/text/results | DELETE | none | json |
examples
# login
curl --cookie cookies.log --cookie-jar cookies.log http://192.168.3.15/login --data "username=admin&password=secret"
# retrieve 5 results
curl --cookie cookies.log --cookie-jar cookies.log -X GET http:// 192.168.3.15/text/results
--data '{"count":5}'
# retrieve 5 results with images
curl --cookie cookies.log --cookie-jar cookies.log -X GET http:// 192.168.3.15/text/results
--data '{"count":5,"include_images":true}'
# retrieve 10 results with a minimum confidence of 60 percent
curl --cookie cookies.log --cookie-jar cookies.log -X GET http:// 192.168.3.15/text/results
--data '{"count":10,"min-confidence":60}'
GET AND SET Access Lists
API Endpoints for retrieving and adding the access lists of the ANPR LUMO. There are four lists:
• white list listname = 'white.txt'
• black list listname = 'black.txt'
• ignore list listname = 'ignore.txt'
• wiegand matchlist listname = ‘wiegandlist.txt‘
Use the GET method to retrieve the property and the PATCH method to set it.
URL | Method | URL Parameter | Data parameter |
/access/:listname | GET | :listname | :filter (optional, can be empty) |
/access/:listname | PATCH | :listname | :entries |
/access/:listname | DELETE | :listname | :specifier |
Retrieving an access list
With a GET request a list of plates is returned. The plates can be filtered by sending a JSON document containing a pattern field that contains a regular expression (RegEx).
Add a plate to an access list
With a POST request a new entry for the access list can be added. The body of the POST request should contain a JSON document in same format as successful GET request response document.
Delete a plate from an access list
With a DELETE request, one or more entries can be deleted by either specifying one of the two fields in a JSON document inside the request body:
- index - delete a single item with the given index number
- pattern - delete every plate that matches the given pattern.
Examples
# request whitelist
curl --cookie cookies.log --cookie-jar cookies.log http://192.168.3.15/access/white.txt
# add plate HHKF1114 to whitelist
curl --cookie cookies.log --cookie-jar cookies.log -X POST http://192.168.3.15/access/white.txt
--data '[{"always":true,"plate":"HHKF1114"}]'
# add HHKF1115 to whitelist which is valid from 01-10-2019 until 31-10-2019 on Monday, Tuesday and Wednesday from 08:00
unitl 18:30
curl --cookie cookies.log --cookie-jar cookies.log -X POST
http://192.168.3.15/access/white.txt --data '[{"always":false,"plate":"HHKF1115","schedules":[{"period":{"start":"2019-10-01",
"end":"2019-10-31"},"time-span":{"from":"08:00","to":"18:30"},"weekdays": ["Mo","Tu","We"]}]}]'
# request Wiegand matchlist
curl --cookie cookies.log --cookie-jar cookies.log http://192.168.3.15/access/wiegandlist.txt
# add HHKF1116 to Wiegand matchlist and match this to Wiegand ID 213
curl --cookie cookies.log --cookie-jar cookies.log -X POST http://192.168.3.15/access/wiegandlist.txt --data
'[{"always":true,"plate":"HHKF1116", "id": 213}]'
# delete plate with index number 1 from whitelist
curl --cookie cookies.log --cookie-jar cookies.log -X DELETE http://192.168.3.15/access/white.txt
--data '{"index":1}'
# delete plates with pattern HH from whitelist
curl --cookie cookies.log --cookie-jar cookies.log -X DELETE http://192.168.3.15/access/white.txt
--data '{"pattern":"HH*"}'