Per-project admin key auth, drop ProjectID; MIT license; go 1.21
This commit is contained in:
+1
-2
@@ -14,12 +14,11 @@ import (
|
||||
type transport struct {
|
||||
baseURL string
|
||||
apiKey string
|
||||
projectID string
|
||||
httpClient *http.Client
|
||||
}
|
||||
|
||||
func (t *transport) do(ctx context.Context, method, path string, query url.Values, body any, out any) error {
|
||||
endpoint := strings.TrimSuffix(t.baseURL, "/") + "/game/v1/projects/" + t.projectID + path
|
||||
endpoint := strings.TrimSuffix(t.baseURL, "/") + "/game/v1" + path
|
||||
if len(query) > 0 {
|
||||
endpoint += "?" + query.Encode()
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user