diff options
| author | Fabian Mastenbroek <mail.fabianm@gmail.com> | 2021-05-16 11:43:03 +0200 |
|---|---|---|
| committer | Fabian Mastenbroek <mail.fabianm@gmail.com> | 2021-05-18 15:46:42 +0200 |
| commit | 5c710d329b16efb947a6d25793f6a0f7865f3df1 (patch) | |
| tree | 91d5c26407ffac8134490367e512a9e33b36528d /opendc-api-spec.yml | |
| parent | 2281d3265423d01e60f8cc088de5a5730bb8a910 (diff) | |
api: Add Swagger UI for API documentation
This change adds Swagger UI to the REST API endpoint in order to
experiment with the API endpoints interactively. It also serves as the
documentation for the API endpoints.
Diffstat (limited to 'opendc-api-spec.yml')
| -rw-r--r-- | opendc-api-spec.yml | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/opendc-api-spec.yml b/opendc-api-spec.yml index 1f7c5697..c23b2f3d 100644 --- a/opendc-api-spec.yml +++ b/opendc-api-spec.yml @@ -3,11 +3,25 @@ info: version: 2.0.0 title: OpenDC API description: 'OpenDC is an open-source datacenter simulator for education, featuring real-time online collaboration, diverse simulation models, and detailed performance feedback statistics.' -host: opendc.org +host: api.opendc.org basePath: /v2 schemes: - https +security: + - auth0: + - openid + +securityDefinitions: + auth0: + type: oauth2 + scopes: + openid: Grants access to user_id + flow: accessCode + authorizationUrl: https://opendc.eu.auth0.com/authorize + tokenUrl: https://opendc.eu.auth0.com/oauth/token + x-token-validation-url: https://opendc.eu.auth0.com/userinfo + paths: '/projects': get: |
