Trados Business Manager allows you to use API to manipulate its data. API covers all tables existing in the TBM database, from reference data to all documents. In general, using API you can create, edit and delete any data contained in your TBM instance.
However, some functionalities may be missing in API (for example, retrieving list of recommended vendors in a new translation assignment). We'll be extending API capabilities by adding more endpoints with time. We also ask our users to post their suggestions about improving API on TBM forums.
Video tutorial
Installation and configuration
To get API working, you have to follow a procedure described below:
- API application should be installed on your server separately from main TBM application. It has separate installation file.
- Add installed application to a list of application (websites) in your IIS on a server and add binding to get URL address for the API application.
- After installing API application, edit its configuration file to add necessary database connection strings. File is named appsettings_global.json and can be found in the API application installation folder. By default, it contains some generic connection string:
You can copy and paste the whole ConnectionsStrings section from the appsettings_global.json config file found in the installation folder of the main TBM application, or just copy this file from the main TBM folder to API folder. - If everything is configured correctly, open URL linked with API application in the browser. You will see the following page:
- Start with Logon endpoint, by sending your user name and password to get access token. Take a note that default tenant name is TBM. Different tenant names are possible only in multi-tenancy environments, but if you have only one default tenant, its name will be TBM, and it cannot be changed.
General information
All requests should have Authorize header with access token (in the form of "Bearer [space]token".
All requests and responses have application/json content type.
Access tokens are valid for 30 days or until Logout request.
User will have access to the same data as allowed by security system in a regular TBM application. For example, if logged in user does not have access to translation assignments based on security system configuration, this user won't be able to access assignments via API as well.
Studying API
Current example with list of available endpoints can be checked here: https://api.ibaccs.com
On this page, you can find description of all API endpoint available in Business Manager. Additionally, you can make test calls right from this page! Of course, you can use other tools like Postman to test API, but this page does not require to install any additional software, allowing you to directly make test requests and see results.
- First of all, check Models section at the very bottom. It provides access to all data structures used in API.
- In the list, find Logon section, and expand Post request.
- Click Try it out button and enter valid values to the model:
- Click Execute to view call result. If user name and password are specified correctly you will see your access token:
Otherwise, error message: - Copy access token, scroll the page up and click Authorize button:
- Type Bearer, insert your token after space, and click Authorize.
- Try any API endpoint. For example, find Unit section, expand /Unit endpoint, click Try it out, and click Execute. You will see list of units from your database: