Difference between revisions of "NPS-API Webservice"
Line 2: | Line 2: | ||
Webservice is a computer communications protocol, providing full-duplex communication channels over a single TCP connection.<br> | Webservice is a computer communications protocol, providing full-duplex communication channels over a single TCP connection.<br> | ||
The Webservice protocol enables interaction between a client-side application and a web server with lower overheads, facilitating real-time data transfer from and to the server. This is made possible by providing a standardized way for the server to send content to the client without being first requested by the client, and allowing messages to be passed back and forth while keeping the connection open. In this way, a two-way ongoing conversation can take place between the client and the server. The communications are done over TCP port number <strong>40</strong>.<br> | The Webservice protocol enables interaction between a client-side application and a web server with lower overheads, facilitating real-time data transfer from and to the server. This is made possible by providing a standardized way for the server to send content to the client without being first requested by the client, and allowing messages to be passed back and forth while keeping the connection open. In this way, a two-way ongoing conversation can take place between the client and the server. The communications are done over TCP port number <strong>40</strong>.<br> | ||
+ | === Commands === | ||
+ | ==== ping ==== | ||
+ | ==== test ==== | ||
+ | ==== nps ==== | ||
+ | |||
=== Example (telnet) === | === Example (telnet) === | ||
* Open a connection to the server (serv.nptracker.co.za) port 40 | * Open a connection to the server (serv.nptracker.co.za) port 40 | ||
Line 12: | Line 17: | ||
* If you found a plate to get a report on just do. | * If you found a plate to get a report on just do. | ||
$><strong>nps abc123gp</strong> | $><strong>nps abc123gp</strong> | ||
+ | === Example (php) === | ||
+ | see [http://api.nptracker.co.za/phpexample.html api example] |
Revision as of 07:39, 18 April 2019
Contents
Webservice
Webservice is a computer communications protocol, providing full-duplex communication channels over a single TCP connection.
The Webservice protocol enables interaction between a client-side application and a web server with lower overheads, facilitating real-time data transfer from and to the server. This is made possible by providing a standardized way for the server to send content to the client without being first requested by the client, and allowing messages to be passed back and forth while keeping the connection open. In this way, a two-way ongoing conversation can take place between the client and the server. The communications are done over TCP port number 40.
Commands
ping
test
nps
Example (telnet)
- Open a connection to the server (serv.nptracker.co.za) port 40
telnet serv.nptracker.co.za 40
- You will then be welcomed please authenticate it with your token
$> AUTH {API-Key}
- You can now start testing plates.
$>test abc123gp
- It will return with the plate followed by a true or false true being there is a report for the plate and false not
- If you found a plate to get a report on just do.
$>nps abc123gp
Example (php)
see api example