The Prometheus-X Catalog API is a catalog management API that allows ecosystem administrators to manage their ecosystems, data/service providers to register their data & services, and enables users to browse the catalog. This API provides a platform for organizing and discovering various offerings within the Prometheus-X ecosystem.
The Catalog API is one of the components allowing management of the catalog. Even though it is independant and serves its own purpose, users of a catalog will need interaction with more than one service. Thus, if you want to run a full catalog, consider looking into deploying the Catalog Registry and the Ecosystem Matcher, two components expanding on the catalog API to offer a more complete set of features.
In addition, the Prometheus-X Full specifications can be found on the Prometheus-X docs repo/wiki
git clone https://github.com/Prometheus-X-association/catalog-api.git
cd prometheus-x-catalog-api
npm install
cp .env.sample .env
# Setup your variables in .env
git clone https://github.com/Prometheus-X-association/catalog-api.git
cd catalog-api
and copy the .env.sample to .env cp .env.sample .env
docker network create ptx
docker-compose up -d
docker-compose build
and restart with: docker-compose up -d
docker run -d -p your-port:your-port --name catalog-api catalog-api
after running docker-compose build
cd terraform
terraform init
terraform apply
terraform output catalog_api_service_ip
- Replace placeholder values in the
kubernetes_secret
resource with actual values from your.env
.- Ensure the
server_port
value matches the port used in your application.- Adjust the
host_path
in thekubernetes_persistent_volume
resource to an appropriate path on your Kubernetes nodes.
Install Helm: Ensure Helm is installed on your machine. You can install it following the instructions here.
helm package ./path/to/catalog-api
helm install catalog-api ./path/to/catalog-api
kubectl get all -n catalog-api
kubectl get svc -n catalog-api
- Replace placeholder values in the
values.yaml
file with actual values from your.env
.- Ensure the
port
value matches the port used in your application.- Configure your MongoDB connection details in the values.yaml file to point to your managed MongoDB instance.
Start the development server:
npm run dev
By default, the API will be accessible at http://localhost:3000
.
The Prometheus-X Catalog API currently uses JWT (JSON Web Tokens) for authentication. To access certain endpoints, you need to include a valid JWT bearer token in the request header.
Authentication via a decentralized wallet is planned.
For a complete list of all available endpoints, along with their request and response schemas, refer to the JSON Swagger Specification provided or visit the github-pages of this repository which displays the swagger specification with the Swagger UI.
We welcome contributions to the Prometheus-X Catalog API. If you find a bug or want to suggest a new feature, please open an issue in the GitHub repository. If you want to contribute code, please fork the repository, create a new branch, make your changes, and submit a pull request.
The Prometheus-X Catalog API is open-source software licensed under the MIT License.