hcloud-sdk 17.0.0 → 18.0.0
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/changelog.md +176 -76
- package/lib/Base.d.ts +2 -1
- package/lib/Hcloud.d.ts +6 -3
- package/lib/Hcloud.js +16 -5
- package/lib/helper/ValidationHelper.d.ts +10 -2
- package/lib/helper/ValidationHelper.js +55 -7
- package/lib/interfaces/auditor/index.d.ts +13 -2
- package/lib/interfaces/auditor/index.js +9 -1
- package/lib/interfaces/cosmo/asset/index.d.ts +185 -0
- package/lib/interfaces/cosmo/asset/index.js +82 -0
- package/lib/interfaces/cosmo/comment/index.d.ts +38 -0
- package/lib/interfaces/cosmo/comment/index.js +8 -0
- package/lib/interfaces/cosmo/event/index.d.ts +31 -0
- package/lib/interfaces/cosmo/event/index.js +17 -0
- package/lib/interfaces/cosmo/location/index.d.ts +4 -0
- package/lib/interfaces/cosmo/namespace/index.d.ts +9 -0
- package/lib/interfaces/cosmo/namespace/index.js +9 -0
- package/lib/interfaces/cosmo/permissions.d.ts +96 -0
- package/lib/interfaces/cosmo/permissions.js +58 -0
- package/lib/interfaces/cosmo/share/index.d.ts +28 -0
- package/lib/interfaces/cosmo/share/index.js +2 -0
- package/lib/interfaces/cosmo/space/index.d.ts +25 -0
- package/lib/interfaces/cosmo/space/index.js +2 -0
- package/lib/interfaces/cosmo/tag/tag.d.ts +12 -0
- package/lib/interfaces/cosmo/tag/tag.js +2 -0
- package/lib/interfaces/global/Products.d.ts +2 -2
- package/lib/interfaces/global/Products.js +1 -1
- package/lib/interfaces/high5/index.d.ts +7 -7
- package/lib/interfaces/high5/index.js +7 -7
- package/lib/interfaces/{friday → high5}/space/database/document/index.d.ts +1 -1
- package/lib/interfaces/{friday → high5}/space/database/document/index.js +2 -1
- package/lib/interfaces/high5/space/database/index.js +2 -0
- package/lib/interfaces/high5/space/event/stream/design/StreamDesign.d.ts +9 -2
- package/lib/interfaces/high5/space/execution/index.d.ts +2 -1
- package/lib/interfaces/high5/space/job/JobLog.d.ts +16 -0
- package/lib/interfaces/high5/space/job/JobLog.js +2 -0
- package/lib/interfaces/high5/space/job/index.d.ts +38 -0
- package/lib/interfaces/high5/space/job/index.js +8 -0
- package/lib/interfaces/high5/stats.d.ts +21 -0
- package/lib/interfaces/high5/stats.js +2 -0
- package/lib/interfaces/idp/oauth/index.d.ts +4 -3
- package/lib/interfaces/idp/organization/index.d.ts +1 -0
- package/lib/interfaces/idp/organization/index.js +1 -0
- package/lib/interfaces/idp/organization/license/index.d.ts +13 -11
- package/lib/interfaces/idp/organization/member/index.d.ts +1 -0
- package/lib/interfaces/idp/organization/stats.d.ts +7 -0
- package/lib/interfaces/idp/organization/stats.js +2 -0
- package/lib/interfaces/idp/organization/team/index.d.ts +0 -1
- package/lib/interfaces/idp/user/Message.d.ts +21 -0
- package/lib/interfaces/idp/user/Message.js +14 -0
- package/lib/interfaces/idp/user/NotificationSettings.d.ts +1 -0
- package/lib/interfaces/idp/user/Scopes.d.ts +1 -7
- package/lib/interfaces/idp/user/Scopes.js +0 -9
- package/lib/interfaces/idp/user/index.d.ts +2 -1
- package/lib/interfaces/mailer/index.d.ts +30 -1
- package/lib/interfaces/mailer/index.js +87 -1
- package/lib/interfaces/mothership/index.d.ts +3 -1
- package/lib/interfaces/mothership/index.js +15 -0
- package/lib/interfaces/mothership/stats.d.ts +4 -0
- package/lib/interfaces/mothership/stats.js +2 -0
- package/lib/interfaces/nats/index.d.ts +54 -24
- package/lib/interfaces/nats/index.js +87 -58
- package/lib/interfaces/shorts/index.d.ts +10 -0
- package/lib/interfaces/shorts/index.js +2 -0
- package/lib/service/agent/bundle/dev/index.d.ts +16 -6
- package/lib/service/agent/bundle/dev/index.js +12 -10
- package/lib/service/agent/bundle/index.d.ts +10 -4
- package/lib/service/agent/bundle/index.js +6 -6
- package/lib/service/agent/context/index.d.ts +22 -8
- package/lib/service/agent/context/index.js +15 -14
- package/lib/service/auditor/index.d.ts +8 -4
- package/lib/service/auditor/index.js +5 -5
- package/lib/service/auditor/internal/index.d.ts +27 -3
- package/lib/service/auditor/internal/index.js +34 -5
- package/lib/service/bouncer/features/index.d.ts +4 -2
- package/lib/service/bouncer/features/index.js +2 -2
- package/lib/service/cosmo/asset/index.d.ts +219 -0
- package/lib/service/cosmo/asset/index.js +314 -0
- package/lib/service/cosmo/comment/index.d.ts +122 -0
- package/lib/service/cosmo/comment/index.js +161 -0
- package/lib/service/cosmo/event/index.d.ts +23 -0
- package/lib/service/cosmo/event/index.js +40 -0
- package/lib/service/cosmo/folder/index.d.ts +27 -0
- package/lib/service/cosmo/folder/index.js +47 -0
- package/lib/service/cosmo/index.d.ts +49 -0
- package/lib/service/cosmo/index.js +119 -0
- package/lib/service/cosmo/internal/index.d.ts +7 -0
- package/lib/service/cosmo/internal/index.js +17 -0
- package/lib/service/cosmo/internal/space/index.d.ts +15 -0
- package/lib/service/cosmo/internal/space/index.js +34 -0
- package/lib/service/cosmo/location/index.d.ts +40 -0
- package/lib/service/cosmo/location/index.js +63 -0
- package/lib/service/cosmo/namespace/index.d.ts +42 -0
- package/lib/service/cosmo/namespace/index.js +65 -0
- package/lib/service/cosmo/organization/index.d.ts +47 -0
- package/lib/service/cosmo/organization/index.js +64 -0
- package/lib/service/cosmo/permissions/index.d.ts +131 -0
- package/lib/service/cosmo/permissions/index.js +181 -0
- package/lib/service/cosmo/production/index.d.ts +26 -0
- package/lib/service/cosmo/production/index.js +45 -0
- package/lib/service/cosmo/share/index.d.ts +161 -0
- package/lib/service/cosmo/share/index.js +215 -0
- package/lib/service/cosmo/space/index.d.ts +104 -0
- package/lib/service/cosmo/space/index.js +146 -0
- package/lib/service/cosmo/tag/index.d.ts +67 -0
- package/lib/service/cosmo/tag/index.js +93 -0
- package/lib/service/dali/avatar/DaliCosmoSpace.d.ts +10 -4
- package/lib/service/dali/avatar/DaliCosmoSpace.js +8 -7
- package/lib/service/dali/avatar/DaliFuseSpace.d.ts +10 -4
- package/lib/service/dali/avatar/DaliFuseSpace.js +7 -6
- package/lib/service/dali/avatar/DaliHigh5Pool.d.ts +10 -4
- package/lib/service/dali/avatar/DaliHigh5Pool.js +7 -6
- package/lib/service/dali/avatar/DaliHigh5Space.d.ts +10 -4
- package/lib/service/dali/avatar/DaliHigh5Space.js +7 -6
- package/lib/service/dali/avatar/DaliOAuthApp.d.ts +10 -4
- package/lib/service/dali/avatar/DaliOAuthApp.js +7 -6
- package/lib/service/dali/avatar/DaliOrganization.d.ts +10 -4
- package/lib/service/dali/avatar/DaliOrganization.js +7 -6
- package/lib/service/dali/avatar/DaliServiceAccount.d.ts +10 -4
- package/lib/service/dali/avatar/DaliServiceAccount.js +7 -6
- package/lib/service/dali/avatar/DaliTeam.d.ts +10 -4
- package/lib/service/dali/avatar/DaliTeam.js +7 -6
- package/lib/service/dali/avatar/DaliUser.d.ts +10 -4
- package/lib/service/dali/avatar/DaliUser.js +7 -6
- package/lib/service/dali/index.d.ts +4 -5
- package/lib/service/dali/index.js +2 -5
- package/lib/service/fuse/index.d.ts +4 -2
- package/lib/service/fuse/index.js +2 -2
- package/lib/service/fuse/internal/index.d.ts +4 -2
- package/lib/service/fuse/internal/index.js +3 -2
- package/lib/service/fuse/internal/space/cronjob/log/index.d.ts +4 -2
- package/lib/service/fuse/internal/space/cronjob/log/index.js +2 -2
- package/lib/service/fuse/internal/space/index.d.ts +7 -3
- package/lib/service/fuse/internal/space/index.js +6 -4
- package/lib/service/fuse/space/cronjob/index.d.ts +35 -13
- package/lib/service/fuse/space/cronjob/index.js +48 -50
- package/lib/service/fuse/space/cronjob/log/index.d.ts +8 -4
- package/lib/service/fuse/space/cronjob/log/index.js +5 -5
- package/lib/service/fuse/space/index.d.ts +27 -11
- package/lib/service/fuse/space/index.js +19 -18
- package/lib/service/high5/execution/index.d.ts +4 -2
- package/lib/service/high5/execution/index.js +3 -2
- package/lib/service/high5/execution/status/index.d.ts +5 -3
- package/lib/service/high5/execution/status/index.js +3 -3
- package/lib/service/high5/index.d.ts +7 -2
- package/lib/service/high5/index.js +9 -2
- package/lib/service/high5/internal/index.d.ts +4 -2
- package/lib/service/high5/internal/index.js +3 -2
- package/lib/service/high5/internal/space/index.d.ts +10 -3
- package/lib/service/high5/internal/space/index.js +13 -4
- package/lib/service/high5/internal/space/job/index.d.ts +7 -0
- package/lib/service/high5/internal/space/job/index.js +17 -0
- package/lib/service/high5/internal/space/job/log/index.d.ts +17 -0
- package/lib/service/high5/internal/space/job/log/index.js +34 -0
- package/lib/service/high5/joinToken/index.d.ts +14 -6
- package/lib/service/high5/joinToken/index.js +10 -9
- package/lib/service/high5/space/database/document/array/index.d.ts +73 -0
- package/lib/service/high5/space/database/document/array/index.js +102 -0
- package/lib/service/{friday → high5}/space/database/document/index.d.ts +26 -10
- package/lib/service/{friday → high5}/space/database/document/index.js +31 -16
- package/lib/service/high5/space/database/document/number/index.d.ts +51 -0
- package/lib/service/high5/space/database/document/number/index.js +77 -0
- package/lib/service/{friday → high5}/space/database/index.d.ts +22 -12
- package/lib/service/{friday → high5}/space/database/index.js +18 -17
- package/lib/service/high5/space/event/index.d.ts +17 -7
- package/lib/service/high5/space/event/index.js +12 -11
- package/lib/service/high5/space/event/stream/design/DesignOperations.d.ts +4 -2
- package/lib/service/high5/space/event/stream/design/DesignOperations.js +2 -2
- package/lib/service/high5/space/event/stream/design/index.d.ts +10 -4
- package/lib/service/high5/space/event/stream/design/index.js +7 -6
- package/lib/service/high5/space/event/stream/design/snapshot/index.d.ts +16 -6
- package/lib/service/high5/space/event/stream/design/snapshot/index.js +12 -10
- package/lib/service/high5/space/event/stream/index.d.ts +32 -12
- package/lib/service/high5/space/event/stream/index.js +22 -21
- package/lib/service/high5/space/execution/index.d.ts +19 -7
- package/lib/service/high5/space/execution/index.js +17 -12
- package/lib/service/high5/space/execution/log/index.d.ts +8 -4
- package/lib/service/high5/space/execution/log/index.js +5 -5
- package/lib/service/high5/space/execution/status/index.d.ts +7 -3
- package/lib/service/high5/space/execution/status/index.js +4 -4
- package/lib/service/high5/space/index.d.ts +43 -14
- package/lib/service/high5/space/index.js +45 -23
- package/lib/service/high5/space/job/index.d.ts +145 -0
- package/lib/service/high5/space/job/index.js +201 -0
- package/lib/service/high5/space/job/log/index.d.ts +35 -0
- package/lib/service/high5/space/job/log/index.js +58 -0
- package/lib/service/high5/space/node/index.d.ts +20 -8
- package/lib/service/high5/space/node/index.js +14 -13
- package/lib/service/high5/space/pool/index.d.ts +27 -11
- package/lib/service/high5/space/pool/index.js +19 -18
- package/lib/service/high5/space/secret/index.d.ts +17 -7
- package/lib/service/high5/space/secret/index.js +12 -11
- package/lib/service/high5/space/stat/index.d.ts +12 -0
- package/lib/service/high5/space/stat/index.js +31 -0
- package/lib/service/high5/space/wave/index.d.ts +16 -6
- package/lib/service/high5/space/wave/index.js +11 -10
- package/lib/service/high5/space/webhook/index.d.ts +32 -12
- package/lib/service/high5/space/webhook/index.js +25 -21
- package/lib/service/high5/space/webhook/log/index.d.ts +4 -2
- package/lib/service/high5/space/webhook/log/index.js +2 -2
- package/lib/service/high5/stat/index.d.ts +11 -0
- package/lib/service/high5/stat/index.js +30 -0
- package/lib/service/high5/wave/s3/index.d.ts +31 -8
- package/lib/service/high5/wave/s3/index.js +42 -21
- package/lib/service/idp/guest/index.d.ts +42 -0
- package/lib/service/idp/guest/index.js +66 -0
- package/lib/service/idp/index.d.ts +25 -7
- package/lib/service/idp/index.js +23 -12
- package/lib/service/idp/internal/index.d.ts +5 -3
- package/lib/service/idp/internal/index.js +5 -3
- package/lib/service/idp/oauth/index.d.ts +16 -6
- package/lib/service/idp/oauth/index.js +15 -15
- package/lib/service/idp/organization/index.d.ts +19 -5
- package/lib/service/idp/organization/index.js +19 -8
- package/lib/service/idp/organization/license/index.d.ts +7 -3
- package/lib/service/idp/organization/license/index.js +4 -4
- package/lib/service/idp/organization/member/index.d.ts +20 -8
- package/lib/service/idp/organization/member/index.js +15 -13
- package/lib/service/idp/organization/member/invitations/index.d.ts +23 -9
- package/lib/service/idp/organization/member/invitations/index.js +72 -59
- package/lib/service/idp/organization/service-accounts/index.d.ts +20 -8
- package/lib/service/idp/organization/service-accounts/index.js +13 -12
- package/lib/service/idp/organization/settings/domain/index.d.ts +13 -5
- package/lib/service/idp/organization/settings/domain/index.js +9 -8
- package/lib/service/idp/organization/settings/domain/saml/index.d.ts +16 -6
- package/lib/service/idp/organization/settings/domain/saml/index.js +19 -18
- package/lib/service/idp/organization/settings/oauth/index.d.ts +23 -9
- package/lib/service/idp/organization/settings/oauth/index.js +16 -15
- package/lib/service/idp/organization/stat/index.d.ts +11 -0
- package/lib/service/idp/organization/stat/index.js +30 -0
- package/lib/service/idp/organization/team/index.d.ts +22 -10
- package/lib/service/idp/organization/team/index.js +14 -13
- package/lib/service/idp/registration/index.d.ts +10 -4
- package/lib/service/idp/registration/index.js +15 -9
- package/lib/service/idp/user/index.d.ts +33 -11
- package/lib/service/idp/user/index.js +29 -16
- package/lib/service/idp/user/license/index.d.ts +7 -3
- package/lib/service/idp/user/license/index.js +4 -4
- package/lib/service/idp/user/message/index.d.ts +61 -0
- package/lib/service/idp/user/message/index.js +92 -0
- package/lib/service/idp/user/password/index.d.ts +4 -2
- package/lib/service/idp/user/password/index.js +2 -2
- package/lib/service/idp/user/settings/connections/index.d.ts +4 -2
- package/lib/service/idp/user/settings/connections/index.js +2 -2
- package/lib/service/idp/user/settings/general/index.d.ts +10 -4
- package/lib/service/idp/user/settings/general/index.js +6 -6
- package/lib/service/idp/user/settings/notifications/index.d.ts +7 -3
- package/lib/service/idp/user/settings/notifications/index.js +4 -4
- package/lib/service/idp/user/settings/oauthApps/index.d.ts +7 -3
- package/lib/service/idp/user/settings/oauthApps/index.js +6 -5
- package/lib/service/idp/user/settings/pats/index.d.ts +22 -8
- package/lib/service/idp/user/settings/pats/index.js +17 -15
- package/lib/service/idp/user/settings/twoFactor/totp/index.d.ts +16 -6
- package/lib/service/idp/user/settings/twoFactor/totp/index.js +13 -10
- package/lib/service/mailer/index.d.ts +4 -2
- package/lib/service/mailer/index.js +2 -2
- package/lib/service/mailer/internal/index.d.ts +13 -5
- package/lib/service/mailer/internal/index.js +8 -8
- package/lib/service/mothership/index.d.ts +35 -13
- package/lib/service/mothership/index.js +32 -17
- package/lib/service/nats/index.js +58 -43
- package/lib/service/shorts/index.d.ts +18 -0
- package/lib/service/{friday → shorts}/index.js +13 -10
- package/lib/service/shorts/internal/index.d.ts +72 -0
- package/lib/service/shorts/internal/index.js +104 -0
- package/package.json +1 -1
- package/lib/interfaces/friday/index.d.ts +0 -3
- package/lib/interfaces/friday/index.js +0 -19
- package/lib/interfaces/friday/space/index.d.ts +0 -21
- package/lib/interfaces/friday/space/index.js +0 -11
- package/lib/service/friday/index.d.ts +0 -13
- package/lib/service/friday/space/index.d.ts +0 -81
- package/lib/service/friday/space/index.js +0 -150
- /package/lib/interfaces/{friday/space/database → cosmo/location}/index.js +0 -0
- /package/lib/interfaces/{friday → high5}/space/database/index.d.ts +0 -0
|
@@ -18,10 +18,10 @@ class DaliCosmoSpace extends Base_1.default {
|
|
|
18
18
|
* @param spaceName Name of the space
|
|
19
19
|
* @returns Public URL of the created avatar
|
|
20
20
|
*/
|
|
21
|
-
createAvatar(orgName, spaceName) {
|
|
21
|
+
createAvatar(orgName, spaceName, raw) {
|
|
22
22
|
return __awaiter(this, void 0, void 0, function* () {
|
|
23
23
|
const resp = yield this.axios.post(this.getEndpoint(`/v1/avatar/org/${orgName}/spaces/cosmo/${spaceName}`), {});
|
|
24
|
-
return resp.data;
|
|
24
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : resp.data);
|
|
25
25
|
});
|
|
26
26
|
}
|
|
27
27
|
/**
|
|
@@ -29,9 +29,10 @@ class DaliCosmoSpace extends Base_1.default {
|
|
|
29
29
|
* @param orgName Name of the organization
|
|
30
30
|
* @param spaceName Name of the space
|
|
31
31
|
*/
|
|
32
|
-
deleteAvatar(orgName, spaceName) {
|
|
32
|
+
deleteAvatar(orgName, spaceName, raw) {
|
|
33
33
|
return __awaiter(this, void 0, void 0, function* () {
|
|
34
|
-
yield this.axios.delete(this.getEndpoint(`/v1/avatar/org/${orgName}/spaces/cosmo/${spaceName}`));
|
|
34
|
+
const resp = yield this.axios.delete(this.getEndpoint(`/v1/avatar/org/${orgName}/spaces/cosmo/${spaceName}`));
|
|
35
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : resp.data);
|
|
35
36
|
});
|
|
36
37
|
}
|
|
37
38
|
/**
|
|
@@ -41,14 +42,14 @@ class DaliCosmoSpace extends Base_1.default {
|
|
|
41
42
|
* @param file Image as Javascript File
|
|
42
43
|
* @returns Public URL of the new avatar
|
|
43
44
|
*/
|
|
44
|
-
updateAvatar(orgName, spaceName, file) {
|
|
45
|
+
updateAvatar(orgName, spaceName, file, raw) {
|
|
45
46
|
return __awaiter(this, void 0, void 0, function* () {
|
|
46
47
|
const data = new FormData();
|
|
47
48
|
data.append("avatar", file);
|
|
48
|
-
const resp = yield this.axios.
|
|
49
|
+
const resp = yield this.axios.patch(`${this.options.server}/api/cosmo/v1/org/${orgName}/spaces/${spaceName}/avatar`, data, {
|
|
49
50
|
headers: { "Content-Type": "multipart/form-data" },
|
|
50
51
|
});
|
|
51
|
-
return resp.data;
|
|
52
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : { url: resp.data.avatarUrl });
|
|
52
53
|
});
|
|
53
54
|
}
|
|
54
55
|
getEndpoint(endpoint) {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import Base from "../../../Base";
|
|
1
|
+
import Base, { MaybeRaw } from "../../../Base";
|
|
2
2
|
import { AvatarCreated } from "../../../interfaces/dali";
|
|
3
3
|
export declare class DaliFuseSpace extends Base {
|
|
4
4
|
/**
|
|
@@ -7,13 +7,17 @@ export declare class DaliFuseSpace extends Base {
|
|
|
7
7
|
* @param spaceName Name of the space
|
|
8
8
|
* @returns Public URL of the created avatar
|
|
9
9
|
*/
|
|
10
|
-
createAvatar(orgName: string, spaceName: string
|
|
10
|
+
createAvatar<R extends boolean = false>(orgName: string, spaceName: string, raw?: {
|
|
11
|
+
raw: R;
|
|
12
|
+
}): Promise<MaybeRaw<R, AvatarCreated>>;
|
|
11
13
|
/**
|
|
12
14
|
* Deletes the avatar of the Fuse space from cloud storage. If you want to update it instead, use updateAvatar().
|
|
13
15
|
* @param orgName Name of the organization
|
|
14
16
|
* @param spaceName Name of the space
|
|
15
17
|
*/
|
|
16
|
-
deleteAvatar(orgName: string, spaceName: string
|
|
18
|
+
deleteAvatar<R extends boolean = false>(orgName: string, spaceName: string, raw?: {
|
|
19
|
+
raw: R;
|
|
20
|
+
}): Promise<MaybeRaw<R, string>>;
|
|
17
21
|
/**
|
|
18
22
|
* Updates the avatar of the specified Fuse space
|
|
19
23
|
* @param orgName Name of the organization
|
|
@@ -21,6 +25,8 @@ export declare class DaliFuseSpace extends Base {
|
|
|
21
25
|
* @param file Image as Javascript File
|
|
22
26
|
* @returns Public URL of the new avatar
|
|
23
27
|
*/
|
|
24
|
-
updateAvatar(orgName: string, spaceName: string, file: File
|
|
28
|
+
updateAvatar<R extends boolean = false>(orgName: string, spaceName: string, file: File, raw?: {
|
|
29
|
+
raw: R;
|
|
30
|
+
}): Promise<MaybeRaw<R, AvatarCreated>>;
|
|
25
31
|
protected getEndpoint(endpoint: string): string;
|
|
26
32
|
}
|
|
@@ -18,10 +18,10 @@ class DaliFuseSpace extends Base_1.default {
|
|
|
18
18
|
* @param spaceName Name of the space
|
|
19
19
|
* @returns Public URL of the created avatar
|
|
20
20
|
*/
|
|
21
|
-
createAvatar(orgName, spaceName) {
|
|
21
|
+
createAvatar(orgName, spaceName, raw) {
|
|
22
22
|
return __awaiter(this, void 0, void 0, function* () {
|
|
23
23
|
const resp = yield this.axios.post(this.getEndpoint(`/v1/avatar/org/${orgName}/spaces/fuse/${spaceName}`), {});
|
|
24
|
-
return resp.data;
|
|
24
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : resp.data);
|
|
25
25
|
});
|
|
26
26
|
}
|
|
27
27
|
/**
|
|
@@ -29,9 +29,10 @@ class DaliFuseSpace extends Base_1.default {
|
|
|
29
29
|
* @param orgName Name of the organization
|
|
30
30
|
* @param spaceName Name of the space
|
|
31
31
|
*/
|
|
32
|
-
deleteAvatar(orgName, spaceName) {
|
|
32
|
+
deleteAvatar(orgName, spaceName, raw) {
|
|
33
33
|
return __awaiter(this, void 0, void 0, function* () {
|
|
34
|
-
yield this.axios.delete(this.getEndpoint(`/v1/avatar/org/${orgName}/spaces/fuse/${spaceName}`));
|
|
34
|
+
const resp = yield this.axios.delete(this.getEndpoint(`/v1/avatar/org/${orgName}/spaces/fuse/${spaceName}`));
|
|
35
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : resp.data);
|
|
35
36
|
});
|
|
36
37
|
}
|
|
37
38
|
/**
|
|
@@ -41,14 +42,14 @@ class DaliFuseSpace extends Base_1.default {
|
|
|
41
42
|
* @param file Image as Javascript File
|
|
42
43
|
* @returns Public URL of the new avatar
|
|
43
44
|
*/
|
|
44
|
-
updateAvatar(orgName, spaceName, file) {
|
|
45
|
+
updateAvatar(orgName, spaceName, file, raw) {
|
|
45
46
|
return __awaiter(this, void 0, void 0, function* () {
|
|
46
47
|
const data = new FormData();
|
|
47
48
|
data.append("avatar", file);
|
|
48
49
|
const resp = yield this.axios.put(this.getEndpoint(`/v1/avatar/org/${orgName}/spaces/fuse/${spaceName}`), data, {
|
|
49
50
|
headers: { "Content-Type": "multipart/form-data" },
|
|
50
51
|
});
|
|
51
|
-
return resp.data;
|
|
52
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : resp.data);
|
|
52
53
|
});
|
|
53
54
|
}
|
|
54
55
|
getEndpoint(endpoint) {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import Base from "../../../Base";
|
|
1
|
+
import Base, { MaybeRaw } from "../../../Base";
|
|
2
2
|
import { AvatarCreated } from "../../../interfaces/dali";
|
|
3
3
|
export declare class DaliHigh5Pool extends Base {
|
|
4
4
|
/**
|
|
@@ -8,14 +8,18 @@ export declare class DaliHigh5Pool extends Base {
|
|
|
8
8
|
* @param poolName Name of the pool
|
|
9
9
|
* @returns Public URL of the created avatar
|
|
10
10
|
*/
|
|
11
|
-
createAvatar(orgName: string, spaceName: string, poolName: string
|
|
11
|
+
createAvatar<R extends boolean = false>(orgName: string, spaceName: string, poolName: string, raw?: {
|
|
12
|
+
raw: R;
|
|
13
|
+
}): Promise<MaybeRaw<R, AvatarCreated>>;
|
|
12
14
|
/**
|
|
13
15
|
* Deletes the avatar of the High5 pool from cloud storage. If you want to update it instead, use updateAvatar().
|
|
14
16
|
* @param orgName Name of the organization
|
|
15
17
|
* @param spaceName Name of the space
|
|
16
18
|
* @param poolName Name of the pool
|
|
17
19
|
*/
|
|
18
|
-
deleteAvatar(orgName: string, spaceName: string, poolName: string
|
|
20
|
+
deleteAvatar<R extends boolean = false>(orgName: string, spaceName: string, poolName: string, raw?: {
|
|
21
|
+
raw: R;
|
|
22
|
+
}): Promise<MaybeRaw<R, string>>;
|
|
19
23
|
/**
|
|
20
24
|
* Updates the avatar of the specified High5 pool
|
|
21
25
|
* @param orgName Name of the organization
|
|
@@ -24,6 +28,8 @@ export declare class DaliHigh5Pool extends Base {
|
|
|
24
28
|
* @param file Image as Javascript File
|
|
25
29
|
* @returns Public URL of the new avatar
|
|
26
30
|
*/
|
|
27
|
-
updateAvatar(orgName: string, spaceName: string, poolName: string, file: File
|
|
31
|
+
updateAvatar<R extends boolean = false>(orgName: string, spaceName: string, poolName: string, file: File, raw?: {
|
|
32
|
+
raw: R;
|
|
33
|
+
}): Promise<MaybeRaw<R, AvatarCreated>>;
|
|
28
34
|
protected getEndpoint(endpoint: string): string;
|
|
29
35
|
}
|
|
@@ -19,10 +19,10 @@ class DaliHigh5Pool extends Base_1.default {
|
|
|
19
19
|
* @param poolName Name of the pool
|
|
20
20
|
* @returns Public URL of the created avatar
|
|
21
21
|
*/
|
|
22
|
-
createAvatar(orgName, spaceName, poolName) {
|
|
22
|
+
createAvatar(orgName, spaceName, poolName, raw) {
|
|
23
23
|
return __awaiter(this, void 0, void 0, function* () {
|
|
24
24
|
const resp = yield this.axios.post(this.getEndpoint(`/v1/avatar/org/${orgName}/spaces/high5/${spaceName}/pools/${poolName}`), {});
|
|
25
|
-
return resp.data;
|
|
25
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : resp.data);
|
|
26
26
|
});
|
|
27
27
|
}
|
|
28
28
|
/**
|
|
@@ -31,9 +31,10 @@ class DaliHigh5Pool extends Base_1.default {
|
|
|
31
31
|
* @param spaceName Name of the space
|
|
32
32
|
* @param poolName Name of the pool
|
|
33
33
|
*/
|
|
34
|
-
deleteAvatar(orgName, spaceName, poolName) {
|
|
34
|
+
deleteAvatar(orgName, spaceName, poolName, raw) {
|
|
35
35
|
return __awaiter(this, void 0, void 0, function* () {
|
|
36
|
-
yield this.axios.delete(this.getEndpoint(`/v1/avatar/org/${orgName}/spaces/high5/${spaceName}/pools/${poolName}`));
|
|
36
|
+
const resp = yield this.axios.delete(this.getEndpoint(`/v1/avatar/org/${orgName}/spaces/high5/${spaceName}/pools/${poolName}`));
|
|
37
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : resp.data);
|
|
37
38
|
});
|
|
38
39
|
}
|
|
39
40
|
/**
|
|
@@ -44,14 +45,14 @@ class DaliHigh5Pool extends Base_1.default {
|
|
|
44
45
|
* @param file Image as Javascript File
|
|
45
46
|
* @returns Public URL of the new avatar
|
|
46
47
|
*/
|
|
47
|
-
updateAvatar(orgName, spaceName, poolName, file) {
|
|
48
|
+
updateAvatar(orgName, spaceName, poolName, file, raw) {
|
|
48
49
|
return __awaiter(this, void 0, void 0, function* () {
|
|
49
50
|
const data = new FormData();
|
|
50
51
|
data.append("avatar", file);
|
|
51
52
|
const resp = yield this.axios.put(this.getEndpoint(`/v1/avatar/org/${orgName}/spaces/high5/${spaceName}/pools/${poolName}`), data, {
|
|
52
53
|
headers: { "Content-Type": "multipart/form-data" },
|
|
53
54
|
});
|
|
54
|
-
return resp.data;
|
|
55
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : resp.data);
|
|
55
56
|
});
|
|
56
57
|
}
|
|
57
58
|
getEndpoint(endpoint) {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import Base from "../../../Base";
|
|
1
|
+
import Base, { MaybeRaw } from "../../../Base";
|
|
2
2
|
import { AvatarCreated } from "../../../interfaces/dali";
|
|
3
3
|
export declare class DaliHigh5Space extends Base {
|
|
4
4
|
/**
|
|
@@ -7,13 +7,17 @@ export declare class DaliHigh5Space extends Base {
|
|
|
7
7
|
* @param spaceName Name of the space
|
|
8
8
|
* @returns Public URL of the created avatar
|
|
9
9
|
*/
|
|
10
|
-
createAvatar(orgName: string, spaceName: string
|
|
10
|
+
createAvatar<R extends boolean = false>(orgName: string, spaceName: string, raw?: {
|
|
11
|
+
raw: R;
|
|
12
|
+
}): Promise<MaybeRaw<R, AvatarCreated>>;
|
|
11
13
|
/**
|
|
12
14
|
* Deletes the avatar of the High5 space from cloud storage. If you want to update it instead, use updateAvatar().
|
|
13
15
|
* @param orgName Name of the organization
|
|
14
16
|
* @param spaceName Name of the space
|
|
15
17
|
*/
|
|
16
|
-
deleteAvatar(orgName: string, spaceName: string
|
|
18
|
+
deleteAvatar<R extends boolean = false>(orgName: string, spaceName: string, raw?: {
|
|
19
|
+
raw: R;
|
|
20
|
+
}): Promise<MaybeRaw<R, string>>;
|
|
17
21
|
/**
|
|
18
22
|
* Updates the avatar of the specified High5 space
|
|
19
23
|
* @param orgName Name of the organization
|
|
@@ -21,6 +25,8 @@ export declare class DaliHigh5Space extends Base {
|
|
|
21
25
|
* @param file Image as Javascript File
|
|
22
26
|
* @returns Public URL of the new avatar
|
|
23
27
|
*/
|
|
24
|
-
updateAvatar(orgName: string, spaceName: string, file: File
|
|
28
|
+
updateAvatar<R extends boolean = false>(orgName: string, spaceName: string, file: File, raw?: {
|
|
29
|
+
raw: R;
|
|
30
|
+
}): Promise<MaybeRaw<R, AvatarCreated>>;
|
|
25
31
|
protected getEndpoint(endpoint: string): string;
|
|
26
32
|
}
|
|
@@ -18,10 +18,10 @@ class DaliHigh5Space extends Base_1.default {
|
|
|
18
18
|
* @param spaceName Name of the space
|
|
19
19
|
* @returns Public URL of the created avatar
|
|
20
20
|
*/
|
|
21
|
-
createAvatar(orgName, spaceName) {
|
|
21
|
+
createAvatar(orgName, spaceName, raw) {
|
|
22
22
|
return __awaiter(this, void 0, void 0, function* () {
|
|
23
23
|
const resp = yield this.axios.post(this.getEndpoint(`/v1/avatar/org/${orgName}/spaces/high5/${spaceName}`), {});
|
|
24
|
-
return resp.data;
|
|
24
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : resp.data);
|
|
25
25
|
});
|
|
26
26
|
}
|
|
27
27
|
/**
|
|
@@ -29,9 +29,10 @@ class DaliHigh5Space extends Base_1.default {
|
|
|
29
29
|
* @param orgName Name of the organization
|
|
30
30
|
* @param spaceName Name of the space
|
|
31
31
|
*/
|
|
32
|
-
deleteAvatar(orgName, spaceName) {
|
|
32
|
+
deleteAvatar(orgName, spaceName, raw) {
|
|
33
33
|
return __awaiter(this, void 0, void 0, function* () {
|
|
34
|
-
yield this.axios.delete(this.getEndpoint(`/v1/avatar/org/${orgName}/spaces/high5/${spaceName}`));
|
|
34
|
+
const resp = yield this.axios.delete(this.getEndpoint(`/v1/avatar/org/${orgName}/spaces/high5/${spaceName}`));
|
|
35
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : resp.data);
|
|
35
36
|
});
|
|
36
37
|
}
|
|
37
38
|
/**
|
|
@@ -41,14 +42,14 @@ class DaliHigh5Space extends Base_1.default {
|
|
|
41
42
|
* @param file Image as Javascript File
|
|
42
43
|
* @returns Public URL of the new avatar
|
|
43
44
|
*/
|
|
44
|
-
updateAvatar(orgName, spaceName, file) {
|
|
45
|
+
updateAvatar(orgName, spaceName, file, raw) {
|
|
45
46
|
return __awaiter(this, void 0, void 0, function* () {
|
|
46
47
|
const data = new FormData();
|
|
47
48
|
data.append("avatar", file);
|
|
48
49
|
const resp = yield this.axios.put(this.getEndpoint(`/v1/avatar/org/${orgName}/spaces/high5/${spaceName}`), data, {
|
|
49
50
|
headers: { "Content-Type": "multipart/form-data" },
|
|
50
51
|
});
|
|
51
|
-
return resp.data;
|
|
52
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : resp.data);
|
|
52
53
|
});
|
|
53
54
|
}
|
|
54
55
|
getEndpoint(endpoint) {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import Base from "../../../Base";
|
|
1
|
+
import Base, { MaybeRaw } from "../../../Base";
|
|
2
2
|
import { AvatarCreated } from "../../../interfaces/dali";
|
|
3
3
|
export declare class DaliOAuthApp extends Base {
|
|
4
4
|
/**
|
|
@@ -7,13 +7,17 @@ export declare class DaliOAuthApp extends Base {
|
|
|
7
7
|
* @param appId ID of the OAuth app
|
|
8
8
|
* @returns Public URL of the created avatar
|
|
9
9
|
*/
|
|
10
|
-
createAvatar(orgName: string, appId: string
|
|
10
|
+
createAvatar<R extends boolean = false>(orgName: string, appId: string, raw?: {
|
|
11
|
+
raw: R;
|
|
12
|
+
}): Promise<MaybeRaw<R, AvatarCreated>>;
|
|
11
13
|
/**
|
|
12
14
|
* Deletes the avatar of the OAuth app from cloud storage. If you want to update it instead, use updateAvatar().
|
|
13
15
|
* @param orgName Name of the organization
|
|
14
16
|
* @param appId ID of the OAuth app
|
|
15
17
|
*/
|
|
16
|
-
deleteAvatar(orgName: string, appId: string
|
|
18
|
+
deleteAvatar<R extends boolean = false>(orgName: string, appId: string, raw?: {
|
|
19
|
+
raw: R;
|
|
20
|
+
}): Promise<MaybeRaw<R, string>>;
|
|
17
21
|
/**
|
|
18
22
|
* Updates the avatar of the specified OAuth app.
|
|
19
23
|
* @param orgName Name of the organization
|
|
@@ -21,6 +25,8 @@ export declare class DaliOAuthApp extends Base {
|
|
|
21
25
|
* @param file Image as Javascript File
|
|
22
26
|
* @returns Public URL of the new avatar
|
|
23
27
|
*/
|
|
24
|
-
updateAvatar(orgName: string, appId: string, file: File
|
|
28
|
+
updateAvatar<R extends boolean = false>(orgName: string, appId: string, file: File, raw?: {
|
|
29
|
+
raw: R;
|
|
30
|
+
}): Promise<MaybeRaw<R, AvatarCreated>>;
|
|
25
31
|
protected getEndpoint(endpoint: string): string;
|
|
26
32
|
}
|
|
@@ -18,10 +18,10 @@ class DaliOAuthApp extends Base_1.default {
|
|
|
18
18
|
* @param appId ID of the OAuth app
|
|
19
19
|
* @returns Public URL of the created avatar
|
|
20
20
|
*/
|
|
21
|
-
createAvatar(orgName, appId) {
|
|
21
|
+
createAvatar(orgName, appId, raw) {
|
|
22
22
|
return __awaiter(this, void 0, void 0, function* () {
|
|
23
23
|
const resp = yield this.axios.post(this.getEndpoint(`/v1/avatar/org/${orgName}/applications/oauth/${appId}`), {});
|
|
24
|
-
return resp.data;
|
|
24
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : resp.data);
|
|
25
25
|
});
|
|
26
26
|
}
|
|
27
27
|
/**
|
|
@@ -29,9 +29,10 @@ class DaliOAuthApp extends Base_1.default {
|
|
|
29
29
|
* @param orgName Name of the organization
|
|
30
30
|
* @param appId ID of the OAuth app
|
|
31
31
|
*/
|
|
32
|
-
deleteAvatar(orgName, appId) {
|
|
32
|
+
deleteAvatar(orgName, appId, raw) {
|
|
33
33
|
return __awaiter(this, void 0, void 0, function* () {
|
|
34
|
-
yield this.axios.delete(this.getEndpoint(`/v1/avatar/org/${orgName}/applications/oauth/${appId}`));
|
|
34
|
+
const resp = yield this.axios.delete(this.getEndpoint(`/v1/avatar/org/${orgName}/applications/oauth/${appId}`));
|
|
35
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : resp.data);
|
|
35
36
|
});
|
|
36
37
|
}
|
|
37
38
|
/**
|
|
@@ -41,14 +42,14 @@ class DaliOAuthApp extends Base_1.default {
|
|
|
41
42
|
* @param file Image as Javascript File
|
|
42
43
|
* @returns Public URL of the new avatar
|
|
43
44
|
*/
|
|
44
|
-
updateAvatar(orgName, appId, file) {
|
|
45
|
+
updateAvatar(orgName, appId, file, raw) {
|
|
45
46
|
return __awaiter(this, void 0, void 0, function* () {
|
|
46
47
|
const data = new FormData();
|
|
47
48
|
data.append("avatar", file);
|
|
48
49
|
const resp = yield this.axios.put(this.getEndpoint(`/v1/avatar/org/${orgName}/applications/oauth/${appId}`), data, {
|
|
49
50
|
headers: { "Content-Type": "multipart/form-data" },
|
|
50
51
|
});
|
|
51
|
-
return resp.data;
|
|
52
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : resp.data);
|
|
52
53
|
});
|
|
53
54
|
}
|
|
54
55
|
getEndpoint(endpoint) {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import Base from "../../../Base";
|
|
1
|
+
import Base, { MaybeRaw } from "../../../Base";
|
|
2
2
|
import { AvatarCreated } from "../../../interfaces/dali";
|
|
3
3
|
export declare class DaliOrganization extends Base {
|
|
4
4
|
/**
|
|
@@ -6,18 +6,24 @@ export declare class DaliOrganization extends Base {
|
|
|
6
6
|
* @param orgName Name of the organization
|
|
7
7
|
* @returns Public URL of the created avatar
|
|
8
8
|
*/
|
|
9
|
-
createAvatar(orgName: string
|
|
9
|
+
createAvatar<R extends boolean = false>(orgName: string, raw?: {
|
|
10
|
+
raw: R;
|
|
11
|
+
}): Promise<MaybeRaw<R, AvatarCreated>>;
|
|
10
12
|
/**
|
|
11
13
|
* Deletes the avatar of the organization from cloud storage. If you want to update it, use updateAvatar() instead.
|
|
12
14
|
* @param orgName Name of the organization
|
|
13
15
|
*/
|
|
14
|
-
deleteAvatar(orgName: string
|
|
16
|
+
deleteAvatar<R extends boolean = false>(orgName: string, raw?: {
|
|
17
|
+
raw: R;
|
|
18
|
+
}): Promise<MaybeRaw<R, string>>;
|
|
15
19
|
/**
|
|
16
20
|
* Updates the avatar of the specified organization.
|
|
17
21
|
* @param orgName Name of the organization
|
|
18
22
|
* @param file Image as Javascript File
|
|
19
23
|
* @returns Public URL of the new avatar
|
|
20
24
|
*/
|
|
21
|
-
updateAvatar(orgName: string, file: File
|
|
25
|
+
updateAvatar<R extends boolean = false>(orgName: string, file: File, raw?: {
|
|
26
|
+
raw: R;
|
|
27
|
+
}): Promise<MaybeRaw<R, AvatarCreated>>;
|
|
22
28
|
protected getEndpoint(endpoint: string): string;
|
|
23
29
|
}
|
|
@@ -17,19 +17,20 @@ class DaliOrganization extends Base_1.default {
|
|
|
17
17
|
* @param orgName Name of the organization
|
|
18
18
|
* @returns Public URL of the created avatar
|
|
19
19
|
*/
|
|
20
|
-
createAvatar(orgName) {
|
|
20
|
+
createAvatar(orgName, raw) {
|
|
21
21
|
return __awaiter(this, void 0, void 0, function* () {
|
|
22
22
|
const resp = yield this.axios.post(this.getEndpoint(`/v1/avatar/org/${orgName}`), {});
|
|
23
|
-
return resp.data;
|
|
23
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : resp.data);
|
|
24
24
|
});
|
|
25
25
|
}
|
|
26
26
|
/**
|
|
27
27
|
* Deletes the avatar of the organization from cloud storage. If you want to update it, use updateAvatar() instead.
|
|
28
28
|
* @param orgName Name of the organization
|
|
29
29
|
*/
|
|
30
|
-
deleteAvatar(orgName) {
|
|
30
|
+
deleteAvatar(orgName, raw) {
|
|
31
31
|
return __awaiter(this, void 0, void 0, function* () {
|
|
32
|
-
yield this.axios.delete(this.getEndpoint(`/v1/avatar/org/${orgName}`));
|
|
32
|
+
const resp = yield this.axios.delete(this.getEndpoint(`/v1/avatar/org/${orgName}`));
|
|
33
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : resp.data);
|
|
33
34
|
});
|
|
34
35
|
}
|
|
35
36
|
/**
|
|
@@ -38,14 +39,14 @@ class DaliOrganization extends Base_1.default {
|
|
|
38
39
|
* @param file Image as Javascript File
|
|
39
40
|
* @returns Public URL of the new avatar
|
|
40
41
|
*/
|
|
41
|
-
updateAvatar(orgName, file) {
|
|
42
|
+
updateAvatar(orgName, file, raw) {
|
|
42
43
|
return __awaiter(this, void 0, void 0, function* () {
|
|
43
44
|
const data = new FormData();
|
|
44
45
|
data.append("avatar", file);
|
|
45
46
|
const resp = yield this.axios.put(this.getEndpoint(`/v1/avatar/org/${orgName}`), data, {
|
|
46
47
|
headers: { "Content-Type": "multipart/form-data" },
|
|
47
48
|
});
|
|
48
|
-
return resp.data;
|
|
49
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : resp.data);
|
|
49
50
|
});
|
|
50
51
|
}
|
|
51
52
|
getEndpoint(endpoint) {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import Base from "../../../Base";
|
|
1
|
+
import Base, { MaybeRaw } from "../../../Base";
|
|
2
2
|
import { AvatarCreated } from "../../../interfaces/dali";
|
|
3
3
|
export declare class DaliServiceAccount extends Base {
|
|
4
4
|
/**
|
|
@@ -7,13 +7,17 @@ export declare class DaliServiceAccount extends Base {
|
|
|
7
7
|
* @param serviceAccountId ID of the service account
|
|
8
8
|
* @returns Public URL of the created avatar
|
|
9
9
|
*/
|
|
10
|
-
createAvatar(orgName: string, serviceAccountId: string
|
|
10
|
+
createAvatar<R extends boolean = false>(orgName: string, serviceAccountId: string, raw?: {
|
|
11
|
+
raw: R;
|
|
12
|
+
}): Promise<MaybeRaw<R, AvatarCreated>>;
|
|
11
13
|
/**
|
|
12
14
|
* Deletes the avatar of the service account from cloud storage. If you want to update it instead, use updateAvatar().
|
|
13
15
|
* @param orgName Name of the organization
|
|
14
16
|
* @param serviceAccountId ID of the service account
|
|
15
17
|
*/
|
|
16
|
-
deleteAvatar(orgName: string, serviceAccountId: string
|
|
18
|
+
deleteAvatar<R extends boolean = false>(orgName: string, serviceAccountId: string, raw?: {
|
|
19
|
+
raw: R;
|
|
20
|
+
}): Promise<MaybeRaw<R, string>>;
|
|
17
21
|
/**
|
|
18
22
|
* Updates the avatar of the specified service account.
|
|
19
23
|
* @param orgName Name of the organization
|
|
@@ -21,6 +25,8 @@ export declare class DaliServiceAccount extends Base {
|
|
|
21
25
|
* @param file Image as Javascript File
|
|
22
26
|
* @returns Public URL of the new avatar
|
|
23
27
|
*/
|
|
24
|
-
updateAvatar(orgName: string, serviceAccountId: string, file: File
|
|
28
|
+
updateAvatar<R extends boolean = false>(orgName: string, serviceAccountId: string, file: File, raw?: {
|
|
29
|
+
raw: R;
|
|
30
|
+
}): Promise<MaybeRaw<R, AvatarCreated>>;
|
|
25
31
|
protected getEndpoint(endpoint: string): string;
|
|
26
32
|
}
|
|
@@ -18,10 +18,10 @@ class DaliServiceAccount extends Base_1.default {
|
|
|
18
18
|
* @param serviceAccountId ID of the service account
|
|
19
19
|
* @returns Public URL of the created avatar
|
|
20
20
|
*/
|
|
21
|
-
createAvatar(orgName, serviceAccountId) {
|
|
21
|
+
createAvatar(orgName, serviceAccountId, raw) {
|
|
22
22
|
return __awaiter(this, void 0, void 0, function* () {
|
|
23
23
|
const resp = yield this.axios.post(this.getEndpoint(`/v1/avatar/org/${orgName}/service-accounts/${serviceAccountId}`), {});
|
|
24
|
-
return resp.data;
|
|
24
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : resp.data);
|
|
25
25
|
});
|
|
26
26
|
}
|
|
27
27
|
/**
|
|
@@ -29,9 +29,10 @@ class DaliServiceAccount extends Base_1.default {
|
|
|
29
29
|
* @param orgName Name of the organization
|
|
30
30
|
* @param serviceAccountId ID of the service account
|
|
31
31
|
*/
|
|
32
|
-
deleteAvatar(orgName, serviceAccountId) {
|
|
32
|
+
deleteAvatar(orgName, serviceAccountId, raw) {
|
|
33
33
|
return __awaiter(this, void 0, void 0, function* () {
|
|
34
|
-
yield this.axios.delete(this.getEndpoint(`/v1/avatar/org/${orgName}/service-accounts/${serviceAccountId}`));
|
|
34
|
+
const resp = yield this.axios.delete(this.getEndpoint(`/v1/avatar/org/${orgName}/service-accounts/${serviceAccountId}`));
|
|
35
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : resp.data);
|
|
35
36
|
});
|
|
36
37
|
}
|
|
37
38
|
/**
|
|
@@ -41,14 +42,14 @@ class DaliServiceAccount extends Base_1.default {
|
|
|
41
42
|
* @param file Image as Javascript File
|
|
42
43
|
* @returns Public URL of the new avatar
|
|
43
44
|
*/
|
|
44
|
-
updateAvatar(orgName, serviceAccountId, file) {
|
|
45
|
+
updateAvatar(orgName, serviceAccountId, file, raw) {
|
|
45
46
|
return __awaiter(this, void 0, void 0, function* () {
|
|
46
47
|
const data = new FormData();
|
|
47
48
|
data.append("avatar", file);
|
|
48
49
|
const resp = yield this.axios.put(this.getEndpoint(`/v1/avatar/org/${orgName}/service-accounts/${serviceAccountId}`), data, {
|
|
49
50
|
headers: { "Content-Type": "multipart/form-data" },
|
|
50
51
|
});
|
|
51
|
-
return resp.data;
|
|
52
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : resp.data);
|
|
52
53
|
});
|
|
53
54
|
}
|
|
54
55
|
getEndpoint(endpoint) {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import Base from "../../../Base";
|
|
1
|
+
import Base, { MaybeRaw } from "../../../Base";
|
|
2
2
|
import { AvatarCreated } from "../../../interfaces/dali";
|
|
3
3
|
export declare class DaliTeam extends Base {
|
|
4
4
|
/**
|
|
@@ -7,13 +7,17 @@ export declare class DaliTeam extends Base {
|
|
|
7
7
|
* @param teamName Name of the team
|
|
8
8
|
* @returns Public URL of the created avatar
|
|
9
9
|
*/
|
|
10
|
-
createAvatar(orgName: string, teamName: string
|
|
10
|
+
createAvatar<R extends boolean = false>(orgName: string, teamName: string, raw?: {
|
|
11
|
+
raw: R;
|
|
12
|
+
}): Promise<MaybeRaw<R, AvatarCreated>>;
|
|
11
13
|
/**
|
|
12
14
|
* Deletes the avatar of the team from cloud storage. If you want to update it instead, use updateAvatar().
|
|
13
15
|
* @param orgName Name of the organization
|
|
14
16
|
* @param teamName Name of the team
|
|
15
17
|
*/
|
|
16
|
-
deleteAvatar(orgName: string, teamName: string
|
|
18
|
+
deleteAvatar<R extends boolean = false>(orgName: string, teamName: string, raw?: {
|
|
19
|
+
raw: R;
|
|
20
|
+
}): Promise<MaybeRaw<R, string>>;
|
|
17
21
|
/**
|
|
18
22
|
* Updates the avatar of the specified team.
|
|
19
23
|
* @param orgName Name of the organization
|
|
@@ -21,6 +25,8 @@ export declare class DaliTeam extends Base {
|
|
|
21
25
|
* @param file Image as Javascript File
|
|
22
26
|
* @returns Public URL of the new avatar
|
|
23
27
|
*/
|
|
24
|
-
updateAvatar(orgName: string, teamName: string, file: File
|
|
28
|
+
updateAvatar<R extends boolean = false>(orgName: string, teamName: string, file: File, raw?: {
|
|
29
|
+
raw: R;
|
|
30
|
+
}): Promise<MaybeRaw<R, AvatarCreated>>;
|
|
25
31
|
protected getEndpoint(endpoint: string): string;
|
|
26
32
|
}
|
|
@@ -18,10 +18,10 @@ class DaliTeam extends Base_1.default {
|
|
|
18
18
|
* @param teamName Name of the team
|
|
19
19
|
* @returns Public URL of the created avatar
|
|
20
20
|
*/
|
|
21
|
-
createAvatar(orgName, teamName) {
|
|
21
|
+
createAvatar(orgName, teamName, raw) {
|
|
22
22
|
return __awaiter(this, void 0, void 0, function* () {
|
|
23
23
|
const resp = yield this.axios.post(this.getEndpoint(`/v1/avatar/org/${orgName}/teams/${teamName}`), {});
|
|
24
|
-
return resp.data;
|
|
24
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : resp.data);
|
|
25
25
|
});
|
|
26
26
|
}
|
|
27
27
|
/**
|
|
@@ -29,9 +29,10 @@ class DaliTeam extends Base_1.default {
|
|
|
29
29
|
* @param orgName Name of the organization
|
|
30
30
|
* @param teamName Name of the team
|
|
31
31
|
*/
|
|
32
|
-
deleteAvatar(orgName, teamName) {
|
|
32
|
+
deleteAvatar(orgName, teamName, raw) {
|
|
33
33
|
return __awaiter(this, void 0, void 0, function* () {
|
|
34
|
-
yield this.axios.delete(this.getEndpoint(`/v1/avatar/org/${orgName}/teams/${teamName}`));
|
|
34
|
+
const resp = yield this.axios.delete(this.getEndpoint(`/v1/avatar/org/${orgName}/teams/${teamName}`));
|
|
35
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : resp.data);
|
|
35
36
|
});
|
|
36
37
|
}
|
|
37
38
|
/**
|
|
@@ -41,14 +42,14 @@ class DaliTeam extends Base_1.default {
|
|
|
41
42
|
* @param file Image as Javascript File
|
|
42
43
|
* @returns Public URL of the new avatar
|
|
43
44
|
*/
|
|
44
|
-
updateAvatar(orgName, teamName, file) {
|
|
45
|
+
updateAvatar(orgName, teamName, file, raw) {
|
|
45
46
|
return __awaiter(this, void 0, void 0, function* () {
|
|
46
47
|
const data = new FormData();
|
|
47
48
|
data.append("avatar", file);
|
|
48
49
|
const resp = yield this.axios.put(this.getEndpoint(`/v1/avatar/org/${orgName}/teams/${teamName}`), data, {
|
|
49
50
|
headers: { "Content-Type": "multipart/form-data" },
|
|
50
51
|
});
|
|
51
|
-
return resp.data;
|
|
52
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : resp.data);
|
|
52
53
|
});
|
|
53
54
|
}
|
|
54
55
|
getEndpoint(endpoint) {
|
|
@@ -1,20 +1,26 @@
|
|
|
1
|
-
import Base from "../../../Base";
|
|
1
|
+
import Base, { MaybeRaw } from "../../../Base";
|
|
2
2
|
import { AvatarCreated } from "../../../interfaces/dali";
|
|
3
3
|
export declare class DaliUser extends Base {
|
|
4
4
|
/**
|
|
5
5
|
* Creates a default avatar for the requesting user.
|
|
6
6
|
* @returns Public URL of the created avatar
|
|
7
7
|
*/
|
|
8
|
-
createAvatar(
|
|
8
|
+
createAvatar<R extends boolean = false>(raw?: {
|
|
9
|
+
raw: R;
|
|
10
|
+
}): Promise<MaybeRaw<R, AvatarCreated>>;
|
|
9
11
|
/**
|
|
10
12
|
* Deletes the avatar of the requesting user from cloud storage. If you want to update it instead, use updateAvatar().
|
|
11
13
|
*/
|
|
12
|
-
deleteAvatar(
|
|
14
|
+
deleteAvatar<R extends boolean = false>(raw?: {
|
|
15
|
+
raw: R;
|
|
16
|
+
}): Promise<MaybeRaw<R, string>>;
|
|
13
17
|
/**
|
|
14
18
|
* Updates the avatar of the requesting user.
|
|
15
19
|
* @param file Image as Javascript File
|
|
16
20
|
* @returns Public URL of the new avatar
|
|
17
21
|
*/
|
|
18
|
-
updateAvatar(file: File
|
|
22
|
+
updateAvatar<R extends boolean = false>(file: File, raw?: {
|
|
23
|
+
raw: R;
|
|
24
|
+
}): Promise<MaybeRaw<R, AvatarCreated>>;
|
|
19
25
|
protected getEndpoint(endpoint: string): string;
|
|
20
26
|
}
|