Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions google/api_core/universe_domain.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@

GOOGLE_DEFAULT_UNIVERSE = "googleapis.com"

def _validate_universe_domain(client_universe, credentials_universe):
"""Validates the universe domain used by the client instance against
the universe domain in the credentials.
"""
if client_universe != credentials_universe:
raise ValueError(f"The configured universe domain ({client_universe}) does not match the universe domain found in the credentials ({credentials_universe}). If you haven't configured the universe domain explicitly, `googleapis.com` is the default.")