Both the ways of having a registered domain for the tenant and the tenant ID which is seen in the GUID format. Even though the tenant ID is more stable. both will yield the same results.
You will have to figure out which of the domains is associated with your tenant. It should be seen in the UX when you're providing the authentication.
You can check this Azure Administrator certification out for more insights on Microsoft Azure!