There is no way how to get list of existing domains from the Credentials Plugin via API. When accessing the API URL (http://localhost:8080/credential-store/api/json?pretty=true&depth=10), only empty domain elements are shown:
The number of empty elements correspond with the number of existing credential domains. I would expect to see here at least names of the domains. Could this be added?