Can you get the cluster names through AWS Private Link?

It is possible from an AWS account connected to MongoDB atlas via PrivateLink to get the list of names of the clusters available over the PrivateLink?

Hi @Kristian_Whittick - Welcome to the community :wave:

I’m not entirely sure I understand this question - Do you mean you want a list of all clusters (for e.g. “Prod-cluster” (M20), “Dev-Cluster” (M10), etc) that are associated with a privatelink connection?

Or are you after the hostnames of the nodes within the cluster? If the latter, then one way you can obtain the hostnames in the metrics page.

Regards,
Jason

After more checking, what I need is the sub-domain not the cluster name.
E.g. I need “crt7mqe” from the URL.
mongodb+srv://cluster0.crt7mqe.mongodb.net/myFirstDatabase

I need to get this information via API from the external AWS account that is connected via the PrivateLink.
So, I think I need to use the Atlas API key, which according to the documentation does not go via the PrivateLink, but only via the internet.

Therefore, I think I have answered my own question, “It is not possible!”, unless there is a way to get DNS information from the PrivateLink endpoint.

Hi Kristian,

Yes - you are correct as you can access the Atlas Administration API servers through the public internet only. The Atlas Administration API is not available over connections that use network peering or private endpoints.

Regards,
Jason