API
The API documentation is provided out-of-the-box by swagger-ui and springdoc-openapi.
One can configure this in the application.yaml
file of the RDepot backend application (rdepot-app).
By default it is configured as follows:
springdoc:
pathsToMatch: /api/v2/**
api-docs:
path: /v2/api-docs
swagger-ui:
path: /docs/api.html
disable-swagger-default-url: true
url: /v2/api-docs
display-query-params: true
default-produces-media-type: application/json
The Swagger UI web application can be found on any running RDepot instance, at the following URL: http(s)://<rdepot-backend-public-url>/docs/api.html (see the springdoc.swagger-ui.path
configuration parameter above).
The OpenAPI v3 specification in JSON can be found at the following URL: http(s)://<rdepot-backend-public-url>/v2/api-docs (see the springdoc.api-docs.path
configuration parameter above).
Please note that changing the springdoc.swagger-ui.path
and springdoc.api-docs.path
configuration parameters is not supported, as they are hard-coded in the web application security filter chain to be accessible without any authentication.
One can disable the deployment of the Swagger UI web application by setting the springdoc.api-docs.enabled
configuration parameter to false
.
See here and here for additional information on the configuration.
Searching using query parameters
This section contains more information on the query parameters that can be used when using the API resources for searching. Each section describes a different type of resource within RDepot and the specific query parameters that are useful in that case.
Packages
Query parameter | Default | Multiple | Method | Notes |
---|---|---|---|---|
deleted | false | no | boolean | shows soft-deleted packages if true |
maintainer | yes | exact | matches on maintainer’s name | |
repository | yes | exact | matches on repository name | |
search | no | contains | matches on package name | |
submissionState | ACCEPTED | yes | exact | |
technology | yes | exact |
Package Maintainers
Query parameter | Default | Multiple | Method | Notes |
---|---|---|---|---|
deleted | false | no | boolean | shows soft-deleted package maintainers if true |
repository | yes | exact | matches on repository name | |
search | no | contains | matches on package name and maintainer’s name | |
technology | yes | exact |
Repositories
Query parameter | Default | Multiple | Method | Notes |
---|---|---|---|---|
deleted | false | no | boolean | shows soft-deleted repositories if true |
maintainer | yes | exact | matches on maintainer’s name | |
name | no | exact | ||
published | no | boolean | ||
search | no | contains | matches on repository name | |
technology | yes | exact |
Repository Maintainers
Query parameter | Default | Multiple | Method | Notes |
---|---|---|---|---|
deleted | false | no | boolean | shows soft-deleted repository maintainers if true |
resourceTechnology | yes | exact | ||
search | no | contains | matches on repository name and maintainer’s name |
Users
Query parameter | Default | Multiple | Method | Notes |
---|---|---|---|---|
active | no | boolean | ||
role | yes | exact | ||
search | no | contains | matches on user’s email, login and name |
Submissions
Query parameter | Default | Multiple | Method | Notes |
---|---|---|---|---|
fromDate | no | date | ISO 8601 date string | |
repository | yes | exact | matches on repository name | |
search | no | contains | matches on approver name, submitter name and package name | |
state | yes | exact | options are ACCEPTED, WAITING, CANCELLED, REJECTED | |
technology | yes | exact | ||
toDate | no | date | ISO 8601 date string |
Newsfeed Events
Query parameter | Default | Multiple | Method | Notes |
---|---|---|---|---|
eventType | yes | exact | ||
fromDate | no | date | ISO 8601 date string | |
resourceType | yes | exact | ||
technology | yes | exact | ||
toDate | no | date | ISO 8601 date string | |
userName | yes | exact |
Access Tokens
Query parameter | Default | Multiple | Method | Notes |
---|---|---|---|---|
active | no | boolean | ||
expired | no | boolean | ||
search | no | contains | matches on name | |
userLogin | yes | exact |