diff --git a/pkg/account/account.go b/pkg/account/account.go index e038a49..bac9c80 100644 --- a/pkg/account/account.go +++ b/pkg/account/account.go @@ -102,7 +102,12 @@ func (p *oauthPayload) domain() string { } if inet.ValidTeslaDomainSuffix(d) && strings.HasPrefix(d, "fleet-api.") { + // PATCHED by jbanyer. Only return the EU endpoint. This means the proxy will not work with NA accounts. + if strings.HasSuffix(d, "eu.vn.cloud.tesla.com") { + return d + } domain = d + // Prefer domains that contain the ou_code (region) if strings.Contains(domain, ouCodeMatch) { return domain