@gymspace/sdk 1.4.5 → 1.5.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/.tsbuildinfo +1 -0
- package/dist/index.d.mts +27 -1
- package/dist/index.d.ts +27 -1
- package/dist/index.js +20 -2
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +20 -2
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
- package/src/models/index.ts +5 -0
- package/src/models/organizations.ts +28 -1
- package/src/resources/auth.ts +5 -2
- package/src/resources/organizations.ts +38 -7
package/dist/index.mjs
CHANGED
|
@@ -302,7 +302,11 @@ var AuthResource = class extends BaseResource {
|
|
|
302
302
|
return this.client.post(`${this.basePath}/login`, data, options);
|
|
303
303
|
}
|
|
304
304
|
async refreshToken(refreshToken, options) {
|
|
305
|
-
return this.client.post(
|
|
305
|
+
return this.client.post(
|
|
306
|
+
`${this.basePath}/refresh`,
|
|
307
|
+
{ refresh_token: refreshToken },
|
|
308
|
+
options
|
|
309
|
+
);
|
|
306
310
|
}
|
|
307
311
|
async verifyEmail(data, options) {
|
|
308
312
|
return this.client.post(`${this.basePath}/verify-email`, data, options);
|
|
@@ -383,7 +387,21 @@ var OrganizationsResource = class extends BaseResource {
|
|
|
383
387
|
return this.client.get(`${this.basePath}/list`, void 0, options);
|
|
384
388
|
}
|
|
385
389
|
async getOrganizationForAdmin(id, options) {
|
|
386
|
-
return this.client.get(
|
|
390
|
+
return this.client.get(
|
|
391
|
+
`${this.basePath}/admin/${id}`,
|
|
392
|
+
void 0,
|
|
393
|
+
options
|
|
394
|
+
);
|
|
395
|
+
}
|
|
396
|
+
async getMyOrganizations(options) {
|
|
397
|
+
return this.client.get(
|
|
398
|
+
`${this.basePath}/my-organizations`,
|
|
399
|
+
void 0,
|
|
400
|
+
options
|
|
401
|
+
);
|
|
402
|
+
}
|
|
403
|
+
async switchOrganization(data, options) {
|
|
404
|
+
return this.client.post(`${this.basePath}/switch`, data, options);
|
|
387
405
|
}
|
|
388
406
|
};
|
|
389
407
|
|