Overview
Swagger is an interactive documentation system that also allows you to conveniently try out & make REST API calls from the documentation page itself.
To interact with it, open a web browser to port 9000 of the root of your Syndeia Cloud instance, ex: http://myhost.mydomain.com:9000 and click on the API ("REST API Swagger Documentation") button:
The Swagger REST API Documentation page should open as shown below. The REST endpoints are organized based on a system of repositories, containers, artifacts, and relations (see Conceptual Model for an overview).
To login
The sign-in request authenticates the user and returns a token if succesful. The token is then used for every REST API request to the Syndeia Cloud server. Follow the steps below to sign-in and register the token so that you do not have to specify it for each request.
1. Click on POST /signIn button under the Auth category.
5. Click the blue Execute button.
8. Click the Authorize button at the top of the page (RHS), a popup screen should show.
To create a new user
12. Click the Edit button. The field should now become editable.
13. Fill out the requested fields, ie: first name, last name, email, password.
14. Click the blue Execute button.
15. If successful, you should receive an HTTP 200 response back with JSON data. If there was a form error, you should receive an HTTP 4XX response back with an appropriate error message.
To reset a password
18. Click the Edit button. The field should now become editable.
19. Fill out the requested fields, ie: email, newPassword.
20. Click the blue Execute button.
21. If successful, you should receive an HTTP 200 response back with JSON data. If there was a form error, you should receive an HTTP 4XX response back with an appropriate error message.
Note, Reset Password is considered an admin-level operation that requires the USER_MODIFY
permission. This is distinct from the Change Password operation which does not require any permission and only applies to one's own password.
To Update User Permissions
23. Click the Edit button. The field should now become editable.
24. Fill out the requested fields, ie: firstName, lastName, permissions.
| Create user permission |
| User read permission |
| User modification permission |
| User remove permission |
| Create repository permission |
| Repository modification permission |
| Repository deletion permission |
| Create container permission |
| Container modification permission |
| Artifact relation write permission |
| Container deletion permission |
| General read permission |
26. If successful, you should receive an HTTP 200 response back with JSON data. If there was a form error, you should receive an HTTP 4XX response back with an appropriate error message.