iam icon indicating copy to clipboard operation
iam copied to clipboard

Add statistical endpoint

Open rmiccoli opened this issue 2 years ago • 7 comments

e.g. for the number of VO users; it should be public

rmiccoli avatar Oct 17 '22 13:10 rmiccoli

Related GGUS:155077

vokac avatar Dec 05 '22 17:12 vokac

The output of the following query shows only the total number of VO users:

$ curl --silent -H "Authorization: Bearer $AT" https://iam-dev.cloud.cnaf.infn.it/scim/Users?count=0 | jq 
{
  "totalResults": 22,
  "schemas": [
    "urn:ietf:params:scim:api:messages:2.0:ListResponse"
  ],
  "Resources": []
}

and we can extract it like this:

$ curl --silent -H "Authorization: Bearer $AT" https://iam-dev.cloud.cnaf.infn.it/scim/Users?count=0 | jq .totalResults
22

The only constraint is that access to the endpoint requires the scim:read scope in the access token.

rmiccoli avatar Apr 26 '24 07:04 rmiccoli

Ciao Roberta, we need something like that to work without an AT...

maarten-litmaath avatar Apr 26 '24 08:04 maarten-litmaath

We probably need to have an anonymous /stats endpoint (name to be decided) that we populate with some basic information. Based on your experience, can you give some indication on what this information can be, at least as a first solution? As a format, is JSON ok?

giacomini avatar Apr 26 '24 08:04 giacomini

Why we are talking just about "stats" while original GGUS ticket asks for "list of users of each IAM VOMs"?

vokac avatar Apr 26 '24 08:04 vokac

Hi all, while the Operations Portal may get the list of users from VOMS-Admin to count them, we can no longer do that in these GDPR times. The number of users is sufficient, to be made available anonymously, so that we avoid hassles with client registration and operations: "My client no longer works: help!"

maarten-litmaath avatar Apr 26 '24 09:04 maarten-litmaath

Hi again, JSON format sounds fine.

maarten-litmaath avatar Apr 26 '24 11:04 maarten-litmaath

PR https://github.com/indigo-iam/iam/pull/790.

federicaagostini avatar Jul 22 '24 15:07 federicaagostini