Skip to main content
Skip table of contents

Retrieving Anchor Coordinates Using Postman

Use Postman to obtain Anchor coordinates from a calibrated system.

Getting Started

To begin, ensure that Postman is installed and that you have connected to the ZeroKey API.

Obtaining the Bearer Token

Once connected to the ZeroKey API, you can proceed to the following steps to obtain the bearer token.

  1. Navigate to the Core System folder and open the Authentication subfolder, as shown below.

image-20240823-224134.png
  1. Under the Authentication subfolder, click Get OAuth2 Token.

  2. Click the Send button on the top right-hand side. This will send a request to get "access_token". After the request is sent, you should see the following:

image-20240823-224241.png
  1. Copy the access token. In the example above, the following value should be copied:
    8NUA4hvKp0Mpn+eDPHUcRzlrVKy6HMG6UMIfEYIMULs=

Receiving the API’s Output

To get Anchor coordinates, navigate to the Hardware Abstraction Layer folder. Under the Device Information subfolder, click Get Devices, as shown below.

image-20240823-224342.png

In the main window, click the Authorization tab. Click the dropdown menu under Auth Type, select Bearer Token, and paste the code that you copied in the entry field beside Token. For example:

image-20240823-224447.png

Lastly, click the Send button on the right-hand side. You will now be able to see the output of the system obtained from the API. The following is an example of what this may look like:

 {
        "DeviceID": "D4:3A:C1:87:14:02",
        "Position": [
            1.116614,
            -1.877612,
            2.5513
        ],
        "Orientation": [
            1.0,
            0.0,
            0.0,
            0.0
        ],
        "DeviceFlags": 0,
        "AlertState": "Off",
        "FirmwareHash": null,
        "FirmwareVersion": null,
        "DeviceType": "anchor",
        "LastUpdateTime": "2024-05-17T19:55:32.4876",
        "UpdateRate": 0,
        "BatteryLevel": null,
        "LastGatewaySource": "ZK://0::379ec3df-ed1c-4860-ade0-ac28c168f7d3::USB::/dev/ttyACM0",
        "Provisioning": null,
        "IsDeleted": false,
        "HardwareVersion": 0,
        "HardwareType": 0,
        "Velocity": [
            0.0,
            0.0,
            0.0
        ],
        "InsState": 0,
        "UsState": 0
    },

Navigating to the Anchor Coordinate Values

The Anchor coordinates in the example above are located under the line "Position": [ and are displayed as the following:

1.116614,
-1.877612,
2.5513

For reference, the values in the first, second, and third lines indicate the X, Y, and Z positions of the Anchors, respectively.

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.