Skip to content

Commit d791b06

Browse files
authored
fix: base url
1 parent 4d27105 commit d791b06

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

.github/workflows/ci.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,7 @@ jobs:
5959
6060
const version = semver.parse('$version');
6161
version.major += 1;
62+
version.minor += 1;
6263
6364
version.format();
6465
")

src/client.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@ export class VRChat extends VRChatInternal {
5252
headers.set("user-agent", getUserAgent(application));
5353

5454
const client = createClient(createConfig({
55+
baseUrl: "https://api.vrchat.cloud/api/1",
5556
...clientOptions,
5657
headers
5758
}));
@@ -122,7 +123,7 @@ export class VRChat extends VRChatInternal {
122123
}
123124

124125
interceptors.request.use(async (request, options) => {
125-
const { meta = {} } = options as Options as { meta: Record<PropertyKey, unknown> };
126+
const { meta = {} } = options as Options as { meta?: Record<PropertyKey, unknown> };
126127

127128
// If the session is being refreshed, wait for the authentication to complete.
128129
if (this.authenticatePromise && !meta[authenticateSymbol]) {
@@ -141,7 +142,7 @@ export class VRChat extends VRChatInternal {
141142
});
142143

143144
interceptors.response.use(async (response, request, options) => {
144-
const { meta } = options as Options as { meta: Record<PropertyKey, unknown> };
145+
const { meta = {} } = options as Options as { meta?: Record<PropertyKey, unknown> };
145146

146147
await this.saveCookies(response.headers);
147148

0 commit comments

Comments
 (0)