REST API - setting up REST API in Command Centre
Enable the REST API and create a secured REST Client in Command Centre.
📋 Prerequisites: Create a REST operator first. You will also need a client certificate.
This page covers the two steps that stand the API up in Command Centre: turning on the web server, then creating a REST Client item.
1. Turn on the web server
In the Configuration Client, go to File → Server Properties → Web Services (about 15 rows down):
Enable the REST API and, initially, tick the checkbox to the right of the port. Watch the status. It is the first sign of a socket-binding problem.
For production, ensure "Do not require pinned client certificates" is OFF. In 8.50 this is labelled "Enable REST Clients with no client certificate". Requiring pre-shared client certificates is the server's best protection against network attackers.
The web server listens on port 8904.
2. Create the REST Client item
In the Configuration Client, go to Configure → Services and Workstations (at the bottom), right-click, then choose New → REST Client:
Set a name, then go to the API Key tab.
Drag your operator (from Manage → Cardholders) into the "REST Client Operator" box. The box looks like it holds more than one operator, but it holds exactly one.
Note the API key. Your client needs it (a sample app, Chrome, or Postman).
Set IP filtering. A space works as well as a comma. This is an extra layer that makes an attack harder.
Populate the Client Certificate Thumbprint from the certificate's Details tab (spaces are allowed). Use either a thumbprint you were provided or one you create yourself.
Verification
Browse to https://<server name or ip>:8904/api/ and ignore the key and certificate at first. If the service is listening and the port is open, the connection is refused for an invalid API key rather than timing out. See REST API - Connection for the full connection check.
🔗 Related
REST API - Create REST Operator. The operator every REST change is pinned to.
REST API - What is an API Key?. What the key contains and how to protect it.
REST API - Connection. Confirm the service is reachable.
Last updated
Was this helpful?
