Accessing the API for Endpoint Documentation and Testing |
BarTender provides complete documentation for the API endpoints together with examples of actions in YAML, JSON, and BTXML formats. You can view this documentation after you install BarTender by using ReDoc, which is included in the BarTender installation file.
To view the API by using ReDoc
Before you design your own applications to work with the API, you might want to use a tool to test how the API can be used. You can use one of several popular tools, such as Insomnia and Postman, to access the API endpoints.
To access the API endpoints by using Insomnia
If you are running BarTender on a computer that is using a remote connection, consider the following guidelines when you access the REST API, both to run the API and to retrieve the API documentation:
You must configure Microsoft Internet Information Services (IIS) and install Print Portal on the server that is running the BarTender REST API.
To access the API endpoints, use "http://<hostname or IP address>/BarTender/api/actions".
To access the ReDoc documentation, use "http://<hostname or IP address>/BarTender/api/actions/reference/index.html".
The browser might prompt you to enter your credentials for authentication.
If you are a domain user and the remote computer that you are running is in the same Windows domain, you can use your domain account to sign in. Otherwise, a local account of that remote computer is required.
When you run the REST API, the following errors might occur:
401: Indicates that the HTTP client failed to sign in to the computer that is specified in the URL.
403: Indicates that the sign-in request is from a user who does not have permission to administer integrations. To run actions or BTXML scripts by using the API, a user must have Allow specified for the Administer Integrations permission in Administration Console.