Configure manual metrics collection

While PDS includes built-in dashboards for monitoring common usage scenarios for your data services, you may wish to see additional metrics or combine metrics from multiple data services or your cluster. To do this, you can query the full list of metrics from a native Prometheus endpoint using a REST API.


  • PDS account admin privileges


  1. Create a new service account using the API:

    curl -X POST<ID>/service-accounts -d `{"name": <service-account-name>"}`
  2. Use the API to assign a “metrics-reader” role binding to this service account, actor-type: service-account:

    • actor_id with the ID of the service account you just created

    • actor_type set to service-account

    • role_name set to metrics-reader

      curl -X PUT<ID>/role-bindings -d `{"actor_id": "<ID>","actor_type": "service-account","role_name": "metrics-reader"}`
  3. Retrieve the service account token by issuing the following GET request:

    curl -X GET<ID>/token

    Save the account token for future reference.

  4. Retrieve the metrics by querying the endpoint and authenticating with the service account token.

Last edited: Tuesday, Mar 28, 2023