Collect and use countable namespaces via api

Change-Id: Ia0dafcf239c5c6b9754ba14727394f9cac3dbb49