Public REST API
Public REST API is a feature which is not needed by a eShare user, or even by a eShare system or project administrator. It is a feature intended for developer use, when connecting eShare with another service.
eShare is now serving a public REST API that other applications can connect to. Applications connect to the REST API as eShare users to the server by using an authentication endpoint to get an authorization key. HTTPS is recommended for a secure connection.
Note: Public REST API requires a separate eShare REST API license from Cadmatic.
A user interface with all the functionality of the REST API is provided by the server, and it can be found from <eShare address>/swagger.
The top right corner of the user interface contains a drop-down menu, which lists eShare versions that contain the REST API in a descending order. With this menu the user can check which endpoints work with which eShare versions.
The user interface contains all the endpoints of the REST API, as well as an explanation on what they do and how they work. The endpoints are divided to sections (Authentication, ModelItems, etc.), and they list the following information:
-
Request type (GET, POST, PUT, DELETE)
-
URL of the endpoint (the format is <eShare address> + <the address given by the endpoint>, for example https://cadmatic.eshare.com/api/public/v1/Projects)
-
Short summary of what the endpoint does
It is also possible to try the endpoints in the user interface by clicking on them and filling in the information the endpoint requires. The user also has to be authenticated first via the Authentication section in the interface (the first section of endpoints in the user interface). After the authentication endpoint has responded with the code 204, the user has successfully authenticated and all the other endpoints become available. Currently, the authentication endpoint supports the Basic authentication format.