diff --git a/pkg/api/client_runtime.go b/pkg/api/client_runtime.go index 66b31332..81f18166 100644 --- a/pkg/api/client_runtime.go +++ b/pkg/api/client_runtime.go @@ -63,6 +63,7 @@ var globalPath = map[string]bool{ "users": true, "billing": true, "organizations": true, + "saas": true, } type newRuntimeFunc func(region string) *runtimeclient.Runtime diff --git a/pkg/api/client_runtime_test.go b/pkg/api/client_runtime_test.go index bfcd446f..57033718 100644 --- a/pkg/api/client_runtime_test.go +++ b/pkg/api/client_runtime_test.go @@ -246,6 +246,17 @@ func TestCloudClientRuntime_getRuntime(t *testing.T) { }}, want: &runtimeclient.Runtime{BasePath: "/api/v1"}, }, + { + name: "/saas operation uses the regionless path", + fields: fields{ + newRegionRuntime: mocknewRuntimeFunc, + runtime: regionless, + }, + args: args{op: &runtime.ClientOperation{ + PathPattern: "/saas/billing/prices", + }}, + want: &runtimeclient.Runtime{BasePath: "/api/v1"}, + }, } for _, tt := range tests { t.Run(tt.name, func(t *testing.T) {