https://github.com/inab/observatory-api
Software Observatory API
https://github.com/inab/observatory-api
fair-software fairsoft fastapi software-metadata
Last synced: 3 months ago
JSON representation
Software Observatory API
- Host: GitHub
- URL: https://github.com/inab/observatory-api
- Owner: inab
- License: mit
- Created: 2024-08-06T18:03:37.000Z (10 months ago)
- Default Branch: main
- Last Pushed: 2024-12-04T14:02:42.000Z (6 months ago)
- Last Synced: 2025-01-06T07:25:13.480Z (5 months ago)
- Topics: fair-software, fairsoft, fastapi, software-metadata
- Language: Python
- Homepage: https://observatory.openebench.bsc.es/api/docs
- Size: 6.44 MB
- Stars: 1
- Watchers: 7
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: readme.md
- License: LICENSE
- Citation: CITATION.cff
Awesome Lists containing this project
README
# Software Observatory API
This repository contains the source code of the Software Observatory API. This API is a [FastAPI](https://fastapi.tiangolo.com/) application that uses a remote mongodb database.
## Development
To start the development environment, first create a virtual environment and install the dependencies:
```
python3 -m venv venv
source venv/bin/activate
pip install -r requirements.txt
```Then, start the development server:
```
export CONFIG_PATH=./api-variables/config_db.ini
python3 main.py
```The API will be available at `http://localhost:3500`.
### Versioning
When a push is done to the `main` branch, the version of the API should be updated. This is done by adding the new version to `VERSION`. A GitHub action will create a tag with the version to the version in `VERSION` file, build and publish the docker image.
### Collections
Most endpoints use the `observatory.tools` collection. The endpoint `GET "/tools/names_type_labels"` uses the collection `observatory.tools_discoverer_w_index`. This is due to this collection being processed to contain information of types and labels in a more convenient way.### Mappings
| bioschema | UI |
| --------- | ------ |
| `@type` | `type` |
| `schema:applicationSubcategory` | `topics` |
| `schema:additionalType` | `type` |
| `schema:name` | `name` |
| `schema:url` | `webpages` |
| `schema:description` | `description` |
| `schema:applicationCategory` | `type` |
| `schema:operatingSystem` | `os` |
| `schema:license` | `license` |
| `schema:author` | `authors` |
| `schema:maintainer` | `authors` |
| `schema:softwareVersion` | `version` |
| `schema:codeRepository` | `repository`
| `schema:featureList` | `operations` |
| `schema:input` | `input` |
| `schema:output` | `output` |
| `schema:downloadURL` | `download` |
| `schema:softwareHelp` | `documentation` |
| `schema:citation` | `publication` |
| `schema:requirements` | `dependencies` |
| `schema:isAccessibleForFree` | `registration_not_manadatory` |
| `schema:dateModified` | - |
| `@context` | - |## API Documentation
The API documentation is available at [https://observatory.openebench.bsc.es/api/docs](https://observatory.openebench.bsc.es/api/docs).
This documentation is automatically generated by FastAPI and is based on the OpenAPI standard.
## Production
The API is deployed in the BSC's infrastructure. The deployment is done using docker and docker-compose.
The docker image is built as part of the CI/CD pipeline. It is triggered by pushing a tag to the repository.
Notice that the API is accessible at a subdomain of the OpenEBench platform. The API is available at [https://observatory.openebench.bsc.es/api](https://observatory.openebench.bsc.es/api). In development, the API is available directly at `http://localhost:3500`.
## License
This software is licensed under the MIT License. For more information, read the [LICENSE](LICENSE) file.