hcloud-sdk 17.0.0 → 19.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 +87 -76
- package/lib/Base.d.ts +2 -1
- package/lib/Hcloud.d.ts +24 -6
- package/lib/Hcloud.js +127 -24
- package/lib/helper/ErrorHelper.js +5 -2
- package/lib/helper/ValidationHelper.d.ts +14 -4
- package/lib/helper/ValidationHelper.js +71 -11
- package/lib/interfaces/agent/logging/cloudwatch.d.ts +23 -0
- package/lib/interfaces/agent/logging/index.d.ts +2 -0
- package/lib/interfaces/{friday → agent/logging}/index.js +2 -3
- package/lib/interfaces/agent/logging/log-collector.d.ts +35 -0
- package/lib/interfaces/agent/module/index.d.ts +7 -0
- package/lib/interfaces/agent/module/index.js +2 -0
- package/lib/interfaces/auditor/index.d.ts +13 -3
- package/lib/interfaces/auditor/index.js +9 -2
- package/lib/interfaces/axios/index.d.ts +5 -0
- package/lib/interfaces/cosmo/asset/index.d.ts +216 -0
- package/lib/interfaces/cosmo/asset/index.js +90 -0
- package/lib/interfaces/cosmo/comment/index.d.ts +41 -0
- package/lib/interfaces/cosmo/comment/index.js +8 -0
- package/lib/interfaces/cosmo/event/index.d.ts +60 -0
- package/lib/interfaces/cosmo/event/index.js +31 -0
- package/lib/interfaces/cosmo/location/index.d.ts +4 -0
- package/lib/interfaces/cosmo/location/index.js +2 -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 +110 -0
- package/lib/interfaces/cosmo/share/index.js +23 -0
- package/lib/interfaces/cosmo/space/index.d.ts +31 -0
- package/lib/interfaces/cosmo/space/index.js +2 -0
- package/lib/interfaces/cosmo/stats/index.d.ts +11 -0
- package/lib/interfaces/cosmo/stats/index.js +2 -0
- package/lib/interfaces/cosmo/tag/tag.d.ts +13 -0
- package/lib/interfaces/cosmo/tag/tag.js +2 -0
- package/lib/interfaces/global/Products.d.ts +2 -3
- package/lib/interfaces/global/Products.js +1 -2
- package/lib/interfaces/global/Views.d.ts +0 -1
- package/lib/interfaces/global/Views.js +0 -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 +10 -2
- package/lib/interfaces/high5/space/event/stream/node/index.d.ts +1 -0
- package/lib/interfaces/high5/space/execution/index.d.ts +3 -1
- package/lib/interfaces/{fuse/space/cronjob/CronjobLog.d.ts → high5/space/job/JobLog.d.ts} +3 -3
- package/lib/interfaces/high5/space/job/JobLog.js +2 -0
- package/lib/interfaces/high5/space/job/index.d.ts +83 -0
- package/lib/interfaces/high5/space/job/index.js +11 -0
- package/lib/interfaces/high5/stats.d.ts +21 -0
- package/lib/interfaces/high5/stats.js +2 -0
- package/lib/interfaces/high5/wave/dependentInputs.d.ts +42 -0
- package/lib/interfaces/high5/wave/dependentInputs.js +144 -0
- package/lib/interfaces/high5/wave/dependentInputsValidation.d.ts +22 -0
- package/lib/interfaces/high5/wave/dependentInputsValidation.js +220 -0
- package/lib/interfaces/idp/index.d.ts +3 -3
- package/lib/interfaces/idp/index.js +3 -3
- package/lib/interfaces/idp/oauth/device.d.ts +18 -0
- package/lib/interfaces/idp/oauth/device.js +2 -0
- package/lib/interfaces/idp/oauth/index.d.ts +19 -5
- package/lib/interfaces/idp/organization/index.d.ts +2 -0
- package/lib/interfaces/idp/organization/index.js +2 -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/settings/oauthApp/index.d.ts +4 -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 +22 -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 -15
- package/lib/interfaces/idp/user/Scopes.js +0 -21
- package/lib/interfaces/idp/user/index.d.ts +5 -1
- package/lib/interfaces/mailer/index.d.ts +50 -2
- package/lib/interfaces/mailer/index.js +100 -2
- 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 +79 -51
- package/lib/interfaces/nats/index.js +140 -125
- package/lib/interfaces/shorts/index.d.ts +17 -0
- package/lib/interfaces/shorts/index.js +8 -0
- package/lib/service/agent/bundle/dev/index.d.ts +16 -6
- package/lib/service/agent/bundle/dev/index.js +16 -11
- package/lib/service/agent/bundle/index.d.ts +10 -4
- package/lib/service/agent/bundle/index.js +10 -7
- package/lib/service/agent/context/index.d.ts +22 -8
- package/lib/service/agent/context/index.js +19 -15
- package/lib/service/agent/index.d.ts +6 -0
- package/lib/service/agent/index.js +18 -1
- package/lib/service/agent/installer/index.js +4 -1
- package/lib/service/agent/logging/index.d.ts +69 -0
- package/lib/service/agent/logging/index.js +117 -0
- package/lib/service/agent/module/index.d.ts +36 -0
- package/lib/service/agent/module/index.js +65 -0
- package/lib/service/auditor/index.d.ts +8 -4
- package/lib/service/auditor/index.js +9 -6
- package/lib/service/auditor/internal/index.d.ts +27 -3
- package/lib/service/auditor/internal/index.js +38 -6
- package/lib/service/bouncer/features/index.d.ts +4 -2
- package/lib/service/bouncer/features/index.js +6 -3
- package/lib/service/bouncer/index.js +5 -2
- package/lib/service/cosmo/asset/index.d.ts +265 -0
- package/lib/service/cosmo/asset/index.js +420 -0
- package/lib/service/cosmo/comment/index.d.ts +93 -0
- package/lib/service/cosmo/comment/index.js +136 -0
- package/lib/service/cosmo/event/index.d.ts +23 -0
- package/lib/service/cosmo/event/index.js +43 -0
- package/lib/service/cosmo/folder/index.d.ts +27 -0
- package/lib/service/cosmo/folder/index.js +50 -0
- package/lib/service/cosmo/index.d.ts +52 -0
- package/lib/service/cosmo/index.js +129 -0
- package/lib/service/cosmo/internal/index.d.ts +7 -0
- package/lib/service/cosmo/internal/index.js +20 -0
- package/lib/service/cosmo/internal/space/index.d.ts +15 -0
- package/lib/service/cosmo/internal/space/index.js +37 -0
- package/lib/service/cosmo/location/index.d.ts +40 -0
- package/lib/service/cosmo/location/index.js +66 -0
- package/lib/service/cosmo/namespace/index.d.ts +56 -0
- package/lib/service/cosmo/namespace/index.js +85 -0
- package/lib/service/cosmo/organization/index.d.ts +47 -0
- package/lib/service/cosmo/organization/index.js +67 -0
- package/lib/service/cosmo/permissions/index.d.ts +131 -0
- package/lib/service/cosmo/permissions/index.js +184 -0
- package/lib/service/cosmo/production/index.d.ts +26 -0
- package/lib/service/cosmo/production/index.js +48 -0
- package/lib/service/cosmo/share/index.d.ts +169 -0
- package/lib/service/cosmo/share/index.js +227 -0
- package/lib/service/cosmo/space/index.d.ts +131 -0
- package/lib/service/cosmo/space/index.js +190 -0
- package/lib/service/cosmo/stats/index.d.ts +35 -0
- package/lib/service/cosmo/stats/index.js +58 -0
- package/lib/service/cosmo/tag/index.d.ts +67 -0
- package/lib/service/cosmo/tag/index.js +96 -0
- package/lib/service/dali/DaliAvatar.d.ts +0 -6
- package/lib/service/dali/DaliAvatar.js +4 -11
- package/lib/service/dali/avatar/DaliCosmoSpace.d.ts +10 -4
- package/lib/service/dali/avatar/DaliCosmoSpace.js +12 -8
- package/lib/service/dali/avatar/DaliHigh5Pool.d.ts +11 -4
- package/lib/service/dali/avatar/DaliHigh5Pool.js +12 -8
- package/lib/service/dali/avatar/DaliHigh5Space.d.ts +11 -4
- package/lib/service/dali/avatar/DaliHigh5Space.js +12 -8
- package/lib/service/dali/avatar/DaliOAuthApp.d.ts +11 -4
- package/lib/service/dali/avatar/DaliOAuthApp.js +12 -8
- package/lib/service/dali/avatar/DaliOrganization.d.ts +11 -4
- package/lib/service/dali/avatar/DaliOrganization.js +12 -8
- package/lib/service/dali/avatar/DaliServiceAccount.d.ts +10 -4
- package/lib/service/dali/avatar/DaliServiceAccount.js +12 -8
- package/lib/service/dali/avatar/DaliTeam.d.ts +11 -4
- package/lib/service/dali/avatar/DaliTeam.js +12 -8
- package/lib/service/dali/avatar/DaliUser.d.ts +11 -4
- package/lib/service/dali/avatar/DaliUser.js +12 -8
- package/lib/service/dali/index.d.ts +4 -5
- package/lib/service/dali/index.js +6 -6
- package/lib/service/high5/execution/index.d.ts +4 -2
- package/lib/service/high5/execution/index.js +7 -3
- package/lib/service/high5/execution/log/index.js +4 -1
- package/lib/service/high5/execution/status/index.d.ts +5 -3
- package/lib/service/high5/execution/status/index.js +7 -4
- package/lib/service/high5/index.d.ts +7 -2
- package/lib/service/high5/index.js +13 -3
- package/lib/service/high5/internal/index.d.ts +4 -2
- package/lib/service/high5/internal/index.js +7 -3
- package/lib/service/high5/internal/space/index.d.ts +10 -3
- package/lib/service/high5/internal/space/index.js +17 -5
- package/lib/service/high5/internal/space/job/index.d.ts +7 -0
- package/lib/service/high5/internal/space/job/index.js +20 -0
- package/lib/service/high5/internal/space/job/log/index.d.ts +17 -0
- package/lib/service/{fuse/internal/space/cronjob → high5/internal/space/job}/log/index.js +13 -10
- package/lib/service/high5/joinToken/index.d.ts +14 -6
- package/lib/service/high5/joinToken/index.js +14 -10
- package/lib/service/high5/space/database/document/array/index.d.ts +73 -0
- package/lib/service/high5/space/database/document/array/index.js +105 -0
- package/lib/service/{friday → high5}/space/database/document/index.d.ts +26 -10
- package/lib/service/{friday → high5}/space/database/document/index.js +35 -17
- package/lib/service/high5/space/database/document/number/index.d.ts +51 -0
- package/lib/service/high5/space/database/document/number/index.js +80 -0
- package/lib/service/{friday → high5}/space/database/index.d.ts +22 -12
- package/lib/service/{friday → high5}/space/database/index.js +22 -18
- package/lib/service/high5/space/event/index.d.ts +17 -7
- package/lib/service/high5/space/event/index.js +16 -12
- package/lib/service/high5/space/event/stream/design/DesignOperations.d.ts +4 -2
- package/lib/service/high5/space/event/stream/design/DesignOperations.js +6 -3
- package/lib/service/high5/space/event/stream/design/index.d.ts +10 -4
- package/lib/service/high5/space/event/stream/design/index.js +13 -9
- 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 +16 -11
- package/lib/service/high5/space/event/stream/index.d.ts +32 -12
- package/lib/service/high5/space/event/stream/index.js +26 -22
- package/lib/service/high5/space/execution/index.d.ts +19 -7
- package/lib/service/high5/space/execution/index.js +21 -13
- package/lib/service/high5/space/execution/log/index.d.ts +8 -4
- package/lib/service/high5/space/execution/log/index.js +9 -6
- package/lib/service/high5/space/execution/status/index.d.ts +7 -3
- package/lib/service/high5/space/execution/status/index.js +8 -5
- package/lib/service/high5/space/index.d.ts +53 -14
- package/lib/service/high5/space/index.js +70 -28
- package/lib/service/{fuse/space/cronjob → high5/space/job}/index.d.ts +57 -35
- package/lib/service/{fuse/space/cronjob → high5/space/job}/index.js +88 -87
- package/lib/service/{fuse/space/cronjob → high5/space/job}/log/index.d.ts +15 -11
- package/lib/service/{fuse/space/cronjob → high5/space/job}/log/index.js +19 -16
- package/lib/service/high5/space/node/index.d.ts +20 -8
- package/lib/service/high5/space/node/index.js +18 -14
- package/lib/service/high5/space/pool/index.d.ts +38 -11
- package/lib/service/high5/space/pool/index.js +41 -19
- package/lib/service/high5/space/secret/index.d.ts +17 -7
- package/lib/service/high5/space/secret/index.js +16 -12
- package/lib/service/high5/space/stat/index.d.ts +12 -0
- package/lib/service/high5/space/stat/index.js +34 -0
- package/lib/service/high5/space/wave/index.d.ts +16 -6
- package/lib/service/high5/space/wave/index.js +15 -11
- package/lib/service/high5/space/webhook/index.d.ts +32 -12
- package/lib/service/high5/space/webhook/index.js +29 -22
- package/lib/service/high5/space/webhook/log/index.d.ts +4 -2
- package/lib/service/high5/space/webhook/log/index.js +6 -3
- package/lib/service/high5/stat/index.d.ts +11 -0
- package/lib/service/{fuse/internal → high5/stat}/index.js +16 -14
- package/lib/service/high5/wave/index.js +4 -1
- package/lib/service/high5/wave/s3/index.d.ts +31 -8
- package/lib/service/high5/wave/s3/index.js +47 -23
- package/lib/service/idp/guest/index.d.ts +42 -0
- package/lib/service/idp/guest/index.js +69 -0
- package/lib/service/idp/index.d.ts +25 -7
- package/lib/service/idp/index.js +27 -13
- package/lib/service/idp/internal/index.d.ts +5 -3
- package/lib/service/idp/internal/index.js +9 -4
- package/lib/service/idp/oauth/device.d.ts +131 -0
- package/lib/service/idp/oauth/device.js +177 -0
- package/lib/service/idp/oauth/index.d.ts +19 -6
- package/lib/service/idp/oauth/index.js +26 -16
- package/lib/service/idp/organization/index.d.ts +28 -5
- package/lib/service/idp/organization/index.js +41 -11
- package/lib/service/idp/organization/license/index.d.ts +7 -3
- package/lib/service/idp/organization/license/index.js +8 -5
- package/lib/service/idp/organization/member/index.d.ts +20 -8
- package/lib/service/idp/organization/member/index.js +20 -15
- package/lib/service/idp/organization/member/invitations/index.d.ts +42 -9
- package/lib/service/idp/organization/member/invitations/index.js +94 -59
- package/lib/service/idp/organization/service-accounts/index.d.ts +31 -9
- package/lib/service/idp/organization/service-accounts/index.js +35 -14
- package/lib/service/idp/organization/settings/domain/index.d.ts +13 -5
- package/lib/service/idp/organization/settings/domain/index.js +13 -9
- package/lib/service/idp/organization/settings/domain/saml/index.d.ts +16 -6
- package/lib/service/idp/organization/settings/domain/saml/index.js +23 -19
- package/lib/service/idp/organization/settings/index.js +4 -1
- package/lib/service/idp/organization/settings/oauth/index.d.ts +33 -9
- package/lib/service/idp/organization/settings/oauth/index.js +37 -16
- package/lib/service/idp/organization/stat/index.d.ts +11 -0
- package/lib/service/idp/organization/stat/index.js +33 -0
- package/lib/service/idp/organization/team/index.d.ts +32 -10
- package/lib/service/idp/organization/team/index.js +35 -14
- package/lib/service/idp/registration/index.d.ts +10 -4
- package/lib/service/idp/registration/index.js +19 -10
- package/lib/service/idp/user/index.d.ts +41 -11
- package/lib/service/idp/user/index.js +49 -19
- package/lib/service/idp/user/license/index.d.ts +7 -3
- package/lib/service/idp/user/license/index.js +8 -5
- package/lib/service/idp/user/message/index.d.ts +62 -0
- package/lib/service/idp/user/message/index.js +95 -0
- package/lib/service/idp/user/password/index.d.ts +4 -2
- package/lib/service/idp/user/password/index.js +6 -3
- package/lib/service/idp/user/settings/connections/index.d.ts +4 -2
- package/lib/service/idp/user/settings/connections/index.js +6 -3
- package/lib/service/idp/user/settings/general/index.d.ts +10 -4
- package/lib/service/idp/user/settings/general/index.js +10 -7
- package/lib/service/idp/user/settings/index.js +4 -1
- package/lib/service/idp/user/settings/notifications/index.d.ts +7 -3
- package/lib/service/idp/user/settings/notifications/index.js +8 -5
- package/lib/service/idp/user/settings/oauthApps/index.d.ts +7 -3
- package/lib/service/idp/user/settings/oauthApps/index.js +10 -6
- package/lib/service/idp/user/settings/pats/index.d.ts +22 -8
- package/lib/service/idp/user/settings/pats/index.js +21 -16
- package/lib/service/idp/user/settings/twoFactor/index.js +4 -1
- package/lib/service/idp/user/settings/twoFactor/totp/index.d.ts +16 -6
- package/lib/service/idp/user/settings/twoFactor/totp/index.js +17 -11
- package/lib/service/mailer/index.d.ts +4 -2
- package/lib/service/mailer/index.js +7 -4
- package/lib/service/mailer/internal/index.d.ts +14 -6
- package/lib/service/mailer/internal/index.js +12 -9
- package/lib/service/mothership/index.d.ts +35 -13
- package/lib/service/mothership/index.js +36 -18
- package/lib/service/nats/index.d.ts +7 -0
- package/lib/service/nats/index.js +77 -44
- package/lib/service/shorts/index.d.ts +18 -0
- package/lib/service/{friday → shorts}/index.js +17 -11
- package/lib/service/shorts/internal/index.d.ts +75 -0
- package/lib/service/shorts/internal/index.js +118 -0
- package/lib/utils/bouncer/features/Provider.js +0 -1
- package/package.json +2 -2
- package/lib/interfaces/friday/index.d.ts +0 -3
- package/lib/interfaces/friday/space/index.d.ts +0 -21
- package/lib/interfaces/friday/space/index.js +0 -11
- package/lib/interfaces/fuse/index.d.ts +0 -3
- package/lib/interfaces/fuse/index.js +0 -19
- package/lib/interfaces/fuse/space/cronjob/Cronjob.d.ts +0 -38
- package/lib/interfaces/fuse/space/cronjob/Cronjob.js +0 -8
- package/lib/interfaces/fuse/space/index.d.ts +0 -22
- package/lib/interfaces/fuse/space/index.js +0 -11
- package/lib/service/dali/avatar/DaliFuseSpace.d.ts +0 -26
- package/lib/service/dali/avatar/DaliFuseSpace.js +0 -58
- 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/service/fuse/index.d.ts +0 -18
- package/lib/service/fuse/index.js +0 -48
- package/lib/service/fuse/internal/index.d.ts +0 -8
- package/lib/service/fuse/internal/space/cronjob/index.d.ts +0 -7
- package/lib/service/fuse/internal/space/cronjob/index.js +0 -17
- package/lib/service/fuse/internal/space/cronjob/log/index.d.ts +0 -15
- package/lib/service/fuse/internal/space/index.d.ts +0 -22
- package/lib/service/fuse/internal/space/index.js +0 -49
- package/lib/service/fuse/space/index.d.ts +0 -81
- package/lib/service/fuse/space/index.js +0 -152
- /package/lib/interfaces/{friday/space/database/index.js → agent/logging/cloudwatch.js} +0 -0
- /package/lib/interfaces/{fuse/space/cronjob/CronjobLog.js → agent/logging/log-collector.js} +0 -0
- /package/lib/interfaces/{friday → high5}/space/database/index.d.ts +0 -0
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import Base from "../../../../../../../Base";
|
|
1
|
+
import Base, { MaybeRaw } from "../../../../../../../Base";
|
|
2
2
|
import { PaginatedResponse, SearchParams } from "../../../../../../../interfaces/global";
|
|
3
3
|
import DesignSnapshot from "../../../../../../../interfaces/high5/space/event/stream/design/snapshot";
|
|
4
4
|
export default class High5DesignSnapshots extends Base {
|
|
@@ -15,7 +15,9 @@ export default class High5DesignSnapshots extends Base {
|
|
|
15
15
|
* @param page (optional) Page number: Skip the first (page * limit) results (defaults to 0)
|
|
16
16
|
* @returns Object containing an array of snapshots of the stream design and the total number of results found in the database (independent of limit and page)
|
|
17
17
|
*/
|
|
18
|
-
search(orgName: string, spaceName: string, eventName: string, streamId: string, content: boolean | undefined, { filters, sorting, limit, page }: SearchParams
|
|
18
|
+
search<R extends boolean = false>(orgName: string, spaceName: string, eventName: string, streamId: string, content: boolean | undefined, { filters, sorting, limit, page }: SearchParams, raw?: {
|
|
19
|
+
raw: R;
|
|
20
|
+
}): Promise<MaybeRaw<R, PaginatedResponse<DesignSnapshot>>>;
|
|
19
21
|
/**
|
|
20
22
|
* Create a snapshot of stream's design.
|
|
21
23
|
* @param orgName Name of the organization
|
|
@@ -25,7 +27,9 @@ export default class High5DesignSnapshots extends Base {
|
|
|
25
27
|
* @param name Name of the snapshot
|
|
26
28
|
* @returns The snapshot
|
|
27
29
|
*/
|
|
28
|
-
create(orgName: string, spaceName: string, eventName: string, streamId: string, name: string
|
|
30
|
+
create<R extends boolean = false>(orgName: string, spaceName: string, eventName: string, streamId: string, name: string, raw?: {
|
|
31
|
+
raw: R;
|
|
32
|
+
}): Promise<MaybeRaw<R, DesignSnapshot>>;
|
|
29
33
|
/**
|
|
30
34
|
* Update a snapshot's name.
|
|
31
35
|
* @param orgName Name of the organization
|
|
@@ -36,7 +40,9 @@ export default class High5DesignSnapshots extends Base {
|
|
|
36
40
|
* @param name Name of the snapshot
|
|
37
41
|
* @returns The snapshot
|
|
38
42
|
*/
|
|
39
|
-
update(orgName: string, spaceName: string, eventName: string, streamId: string, snapshotId: string, name: string
|
|
43
|
+
update<R extends boolean = false>(orgName: string, spaceName: string, eventName: string, streamId: string, snapshotId: string, name: string, raw?: {
|
|
44
|
+
raw: R;
|
|
45
|
+
}): Promise<MaybeRaw<R, DesignSnapshot>>;
|
|
40
46
|
/**
|
|
41
47
|
* Delete a stream design's snapshot.
|
|
42
48
|
* @param orgName Name of the organization
|
|
@@ -45,7 +51,9 @@ export default class High5DesignSnapshots extends Base {
|
|
|
45
51
|
* @param streamId ID of the stream
|
|
46
52
|
* @param snapshotId ID of the snapshot
|
|
47
53
|
*/
|
|
48
|
-
delete(orgName: string, spaceName: string, eventName: string, streamId: string, snapshotId: string
|
|
54
|
+
delete<R extends boolean = false>(orgName: string, spaceName: string, eventName: string, streamId: string, snapshotId: string, raw?: {
|
|
55
|
+
raw: R;
|
|
56
|
+
}): Promise<MaybeRaw<R, void>>;
|
|
49
57
|
/**
|
|
50
58
|
* Restore a stream's design to a certain snapshot.
|
|
51
59
|
*
|
|
@@ -57,6 +65,8 @@ export default class High5DesignSnapshots extends Base {
|
|
|
57
65
|
* @param streamId ID of the stream
|
|
58
66
|
* @param snapshotId ID of the snapshot
|
|
59
67
|
*/
|
|
60
|
-
restore(orgName: string, spaceName: string, eventName: string, streamId: string, snapshotId: string
|
|
68
|
+
restore<R extends boolean = false>(orgName: string, spaceName: string, eventName: string, streamId: string, snapshotId: string, raw?: {
|
|
69
|
+
raw: R;
|
|
70
|
+
}): Promise<MaybeRaw<R, void>>;
|
|
61
71
|
protected getEndpoint(endpoint: string): string;
|
|
62
72
|
}
|
|
@@ -8,8 +8,11 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
8
8
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
9
|
});
|
|
10
10
|
};
|
|
11
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
12
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
13
|
+
};
|
|
11
14
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
const Base_1 = require("../../../../../../../Base");
|
|
15
|
+
const Base_1 = __importDefault(require("../../../../../../../Base"));
|
|
13
16
|
const paginatedResponseHelper_1 = require("../../../../../../../helper/paginatedResponseHelper");
|
|
14
17
|
const searchFilter_1 = require("../../../../../../../helper/searchFilter");
|
|
15
18
|
class High5DesignSnapshots extends Base_1.default {
|
|
@@ -27,7 +30,7 @@ class High5DesignSnapshots extends Base_1.default {
|
|
|
27
30
|
* @returns Object containing an array of snapshots of the stream design and the total number of results found in the database (independent of limit and page)
|
|
28
31
|
*/
|
|
29
32
|
search(orgName_1, spaceName_1, eventName_1, streamId_1) {
|
|
30
|
-
return __awaiter(this, arguments, void 0, function* (orgName, spaceName, eventName, streamId, content = false, { filters, sorting, limit = 25, page = 0 }) {
|
|
33
|
+
return __awaiter(this, arguments, void 0, function* (orgName, spaceName, eventName, streamId, content = false, { filters, sorting, limit = 25, page = 0 }, raw) {
|
|
31
34
|
const filtersDTO = filters === null || filters === void 0 ? void 0 : filters.map((f) => {
|
|
32
35
|
return new searchFilter_1.SearchFilterDTO(f);
|
|
33
36
|
});
|
|
@@ -37,7 +40,7 @@ class High5DesignSnapshots extends Base_1.default {
|
|
|
37
40
|
}, {
|
|
38
41
|
params: { content, limit, page },
|
|
39
42
|
});
|
|
40
|
-
return (0, paginatedResponseHelper_1.createPaginatedResponse)(resp);
|
|
43
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? Object.assign(Object.assign({}, resp), { data: (0, paginatedResponseHelper_1.createPaginatedResponse)(resp) }) : (0, paginatedResponseHelper_1.createPaginatedResponse)(resp));
|
|
41
44
|
});
|
|
42
45
|
}
|
|
43
46
|
/**
|
|
@@ -49,10 +52,10 @@ class High5DesignSnapshots extends Base_1.default {
|
|
|
49
52
|
* @param name Name of the snapshot
|
|
50
53
|
* @returns The snapshot
|
|
51
54
|
*/
|
|
52
|
-
create(orgName, spaceName, eventName, streamId, name) {
|
|
55
|
+
create(orgName, spaceName, eventName, streamId, name, raw) {
|
|
53
56
|
return __awaiter(this, void 0, void 0, function* () {
|
|
54
57
|
const resp = yield this.axios.post(this.getEndpoint(`/v1/org/${orgName}/spaces/${spaceName}/events/${eventName}/streams/${streamId}/design/snapshots`), { name });
|
|
55
|
-
return resp.data;
|
|
58
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : resp.data);
|
|
56
59
|
});
|
|
57
60
|
}
|
|
58
61
|
/**
|
|
@@ -65,10 +68,10 @@ class High5DesignSnapshots extends Base_1.default {
|
|
|
65
68
|
* @param name Name of the snapshot
|
|
66
69
|
* @returns The snapshot
|
|
67
70
|
*/
|
|
68
|
-
update(orgName, spaceName, eventName, streamId, snapshotId, name) {
|
|
71
|
+
update(orgName, spaceName, eventName, streamId, snapshotId, name, raw) {
|
|
69
72
|
return __awaiter(this, void 0, void 0, function* () {
|
|
70
73
|
const resp = yield this.axios.patch(this.getEndpoint(`/v1/org/${orgName}/spaces/${spaceName}/events/${eventName}/streams/${streamId}/design/snapshots/${snapshotId}`), { name });
|
|
71
|
-
return resp.data;
|
|
74
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : resp.data);
|
|
72
75
|
});
|
|
73
76
|
}
|
|
74
77
|
/**
|
|
@@ -79,9 +82,10 @@ class High5DesignSnapshots extends Base_1.default {
|
|
|
79
82
|
* @param streamId ID of the stream
|
|
80
83
|
* @param snapshotId ID of the snapshot
|
|
81
84
|
*/
|
|
82
|
-
delete(orgName, spaceName, eventName, streamId, snapshotId) {
|
|
85
|
+
delete(orgName, spaceName, eventName, streamId, snapshotId, raw) {
|
|
83
86
|
return __awaiter(this, void 0, void 0, function* () {
|
|
84
|
-
yield this.axios.delete(this.getEndpoint(`/v1/org/${orgName}/spaces/${spaceName}/events/${eventName}/streams/${streamId}/design/snapshots/${snapshotId}`));
|
|
87
|
+
const resp = yield this.axios.delete(this.getEndpoint(`/v1/org/${orgName}/spaces/${spaceName}/events/${eventName}/streams/${streamId}/design/snapshots/${snapshotId}`));
|
|
88
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : undefined);
|
|
85
89
|
});
|
|
86
90
|
}
|
|
87
91
|
/**
|
|
@@ -95,9 +99,10 @@ class High5DesignSnapshots extends Base_1.default {
|
|
|
95
99
|
* @param streamId ID of the stream
|
|
96
100
|
* @param snapshotId ID of the snapshot
|
|
97
101
|
*/
|
|
98
|
-
restore(orgName, spaceName, eventName, streamId, snapshotId) {
|
|
102
|
+
restore(orgName, spaceName, eventName, streamId, snapshotId, raw) {
|
|
99
103
|
return __awaiter(this, void 0, void 0, function* () {
|
|
100
|
-
yield this.axios.put(this.getEndpoint(`/v1/org/${orgName}/spaces/${spaceName}/events/${eventName}/streams/${streamId}/design/snapshots/${snapshotId}/restore`));
|
|
104
|
+
const resp = yield this.axios.put(this.getEndpoint(`/v1/org/${orgName}/spaces/${spaceName}/events/${eventName}/streams/${streamId}/design/snapshots/${snapshotId}/restore`));
|
|
105
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : undefined);
|
|
101
106
|
});
|
|
102
107
|
}
|
|
103
108
|
getEndpoint(endpoint) {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import Base from "../../../../../Base";
|
|
1
|
+
import Base, { MaybeRaw } from "../../../../../Base";
|
|
2
2
|
import { PaginatedResponse, SearchParams } from "../../../../../interfaces/global";
|
|
3
3
|
import { SingleStreamPatchOrder, Stream, StreamPatchActive, StreamPatchOrder } from "../../../../../interfaces/high5/space/event/stream";
|
|
4
4
|
import { High5Design } from "./design";
|
|
@@ -16,11 +16,13 @@ export declare class High5Stream extends Base {
|
|
|
16
16
|
* @param page (optional) Page number: Skip the first (page * limit) results (defaults to 0)
|
|
17
17
|
* @returns Object containing an array of streams as well as the total number of results found in the database (independent of limit and page)
|
|
18
18
|
*/
|
|
19
|
-
searchStreams({ orgName, spaceName, eventName, filters, sorting, limit, page, }: SearchParams & {
|
|
19
|
+
searchStreams<R extends boolean = false>({ orgName, spaceName, eventName, filters, sorting, limit, page, }: SearchParams & {
|
|
20
20
|
orgName: string;
|
|
21
21
|
spaceName: string;
|
|
22
22
|
eventName: string;
|
|
23
|
-
}
|
|
23
|
+
}, raw?: {
|
|
24
|
+
raw: R;
|
|
25
|
+
}): Promise<MaybeRaw<R, PaginatedResponse<Stream>>>;
|
|
24
26
|
/**
|
|
25
27
|
* Retrieves a Stream by its ID.
|
|
26
28
|
* @param orgName Name of the organization
|
|
@@ -29,7 +31,9 @@ export declare class High5Stream extends Base {
|
|
|
29
31
|
* @param streamId ID of the stream
|
|
30
32
|
* @returns The requested stream
|
|
31
33
|
*/
|
|
32
|
-
getStream(orgName: string, spaceName: string, eventName: string, streamId: string
|
|
34
|
+
getStream<R extends boolean = false>(orgName: string, spaceName: string, eventName: string, streamId: string, raw?: {
|
|
35
|
+
raw: R;
|
|
36
|
+
}): Promise<MaybeRaw<R, Stream>>;
|
|
33
37
|
/**
|
|
34
38
|
* Creates a new Stream for the specified Event.
|
|
35
39
|
* @param orgName Name of the organization
|
|
@@ -38,7 +42,9 @@ export declare class High5Stream extends Base {
|
|
|
38
42
|
* @param name Name for the new stream
|
|
39
43
|
* @returns The created stream
|
|
40
44
|
*/
|
|
41
|
-
createStream(orgName: string, spaceName: string, eventName: string, name: string
|
|
45
|
+
createStream<R extends boolean = false>(orgName: string, spaceName: string, eventName: string, name: string, raw?: {
|
|
46
|
+
raw: R;
|
|
47
|
+
}): Promise<MaybeRaw<R, Stream>>;
|
|
42
48
|
/**
|
|
43
49
|
* Duplicate a Stream for the specified Event.
|
|
44
50
|
* @param orgName Name of the organization
|
|
@@ -48,7 +54,9 @@ export declare class High5Stream extends Base {
|
|
|
48
54
|
* @param sourceStreamId ID for the stream to duplicate
|
|
49
55
|
* @returns The created stream
|
|
50
56
|
*/
|
|
51
|
-
duplicateStream(orgName: string, spaceName: string, eventName: string, name: string, sourceStreamId: string
|
|
57
|
+
duplicateStream<R extends boolean = false>(orgName: string, spaceName: string, eventName: string, name: string, sourceStreamId: string, raw?: {
|
|
58
|
+
raw: R;
|
|
59
|
+
}): Promise<MaybeRaw<R, Stream>>;
|
|
52
60
|
/**
|
|
53
61
|
* Patches the order of Streams for an Event.
|
|
54
62
|
* @param orgName Name of the organization
|
|
@@ -57,7 +65,9 @@ export declare class High5Stream extends Base {
|
|
|
57
65
|
* @param StreamPatchOrder List of all event streams with their new order
|
|
58
66
|
* @returns Array of updated Streams
|
|
59
67
|
*/
|
|
60
|
-
patchStreamOrderMulti(orgName: string, spaceName: string, eventName: string, streamList: StreamPatchOrder[]
|
|
68
|
+
patchStreamOrderMulti<R extends boolean = false>(orgName: string, spaceName: string, eventName: string, streamList: StreamPatchOrder[], raw?: {
|
|
69
|
+
raw: R;
|
|
70
|
+
}): Promise<MaybeRaw<R, Stream[]>>;
|
|
61
71
|
/**
|
|
62
72
|
* Activate or deactivate a stream
|
|
63
73
|
* @param orgName Name of the organization
|
|
@@ -67,7 +77,9 @@ export declare class High5Stream extends Base {
|
|
|
67
77
|
* @param StreamPatchActive Object defining if stream should be active or inactive
|
|
68
78
|
* @returns Details of the updated stream
|
|
69
79
|
*/
|
|
70
|
-
patchStreamState(orgName: string, spaceName: string, eventName: string, streamId: string, streamPatchActive: StreamPatchActive
|
|
80
|
+
patchStreamState<R extends boolean = false>(orgName: string, spaceName: string, eventName: string, streamId: string, streamPatchActive: StreamPatchActive, raw?: {
|
|
81
|
+
raw: R;
|
|
82
|
+
}): Promise<MaybeRaw<R, Stream>>;
|
|
71
83
|
/**
|
|
72
84
|
* Moves a Stream up or down in the existing Streams order.
|
|
73
85
|
* @param orgName Name of the organization
|
|
@@ -77,7 +89,9 @@ export declare class High5Stream extends Base {
|
|
|
77
89
|
* @param SingleStreamPatchOrder Object defining if stream should move up or down
|
|
78
90
|
* @returns Array of updated Streams
|
|
79
91
|
*/
|
|
80
|
-
patchStreamOrder(orgName: string, spaceName: string, eventName: string, streamId: string, singleStreamPatchOrder: SingleStreamPatchOrder
|
|
92
|
+
patchStreamOrder<R extends boolean = false>(orgName: string, spaceName: string, eventName: string, streamId: string, singleStreamPatchOrder: SingleStreamPatchOrder, raw?: {
|
|
93
|
+
raw: R;
|
|
94
|
+
}): Promise<MaybeRaw<R, Stream[]>>;
|
|
81
95
|
/**
|
|
82
96
|
* Rename a stream
|
|
83
97
|
* @param orgName Name of the organization
|
|
@@ -87,7 +101,9 @@ export declare class High5Stream extends Base {
|
|
|
87
101
|
* @param name New name of the stream
|
|
88
102
|
* @returns Updated stream
|
|
89
103
|
*/
|
|
90
|
-
renameStream(orgName: string, spaceName: string, eventName: string, streamId: string, name: string
|
|
104
|
+
renameStream<R extends boolean = false>(orgName: string, spaceName: string, eventName: string, streamId: string, name: string, raw?: {
|
|
105
|
+
raw: R;
|
|
106
|
+
}): Promise<MaybeRaw<R, Stream>>;
|
|
91
107
|
/**
|
|
92
108
|
* Moves a Stream to another event.
|
|
93
109
|
*
|
|
@@ -100,7 +116,9 @@ export declare class High5Stream extends Base {
|
|
|
100
116
|
* @param [order] (optional) Order the stream should have in the new event
|
|
101
117
|
* @returns Updated Stream
|
|
102
118
|
*/
|
|
103
|
-
moveStream(orgName: string, spaceName: string, eventName: string, streamId: string, newEventName: string, name?: string, order?: number
|
|
119
|
+
moveStream<R extends boolean = false>(orgName: string, spaceName: string, eventName: string, streamId: string, newEventName: string, name?: string, order?: number, raw?: {
|
|
120
|
+
raw: R;
|
|
121
|
+
}): Promise<MaybeRaw<R, Stream>>;
|
|
104
122
|
/**
|
|
105
123
|
* Deletes a Stream by its ID.
|
|
106
124
|
* @param orgName Name of the organization
|
|
@@ -108,6 +126,8 @@ export declare class High5Stream extends Base {
|
|
|
108
126
|
* @param eventName Name of the event
|
|
109
127
|
* @param streamId ID of the stream
|
|
110
128
|
*/
|
|
111
|
-
deleteStream(orgName: string, spaceName: string, eventName: string, streamId: string
|
|
129
|
+
deleteStream<R extends boolean = false>(orgName: string, spaceName: string, eventName: string, streamId: string, raw?: {
|
|
130
|
+
raw: R;
|
|
131
|
+
}): Promise<MaybeRaw<R, void>>;
|
|
112
132
|
protected getEndpoint(endpoint: string): string;
|
|
113
133
|
}
|
|
@@ -8,9 +8,12 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
8
8
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
9
|
});
|
|
10
10
|
};
|
|
11
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
12
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
13
|
+
};
|
|
11
14
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
15
|
exports.High5Stream = void 0;
|
|
13
|
-
const Base_1 = require("../../../../../Base");
|
|
16
|
+
const Base_1 = __importDefault(require("../../../../../Base"));
|
|
14
17
|
const paginatedResponseHelper_1 = require("../../../../../helper/paginatedResponseHelper");
|
|
15
18
|
const searchFilter_1 = require("../../../../../helper/searchFilter");
|
|
16
19
|
const design_1 = require("./design");
|
|
@@ -32,14 +35,14 @@ class High5Stream extends Base_1.default {
|
|
|
32
35
|
* @param page (optional) Page number: Skip the first (page * limit) results (defaults to 0)
|
|
33
36
|
* @returns Object containing an array of streams as well as the total number of results found in the database (independent of limit and page)
|
|
34
37
|
*/
|
|
35
|
-
searchStreams(_a) {
|
|
36
|
-
return __awaiter(this, arguments, void 0, function* ({ orgName, spaceName, eventName, filters, sorting, limit = 25, page = 0, }) {
|
|
38
|
+
searchStreams(_a, raw_1) {
|
|
39
|
+
return __awaiter(this, arguments, void 0, function* ({ orgName, spaceName, eventName, filters, sorting, limit = 25, page = 0, }, raw) {
|
|
37
40
|
const filtersDTO = filters === null || filters === void 0 ? void 0 : filters.map((f) => new searchFilter_1.SearchFilterDTO(f));
|
|
38
41
|
const resp = yield this.axios.post(this.getEndpoint(`/v1/org/${orgName}/spaces/${spaceName}/events/${eventName}/streams/search?page=${page}&limit=${limit}`), {
|
|
39
42
|
filters: filtersDTO,
|
|
40
43
|
sorting: sorting,
|
|
41
44
|
});
|
|
42
|
-
return (0, paginatedResponseHelper_1.createPaginatedResponse)(resp);
|
|
45
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? Object.assign(Object.assign({}, resp), { data: (0, paginatedResponseHelper_1.createPaginatedResponse)(resp) }) : (0, paginatedResponseHelper_1.createPaginatedResponse)(resp));
|
|
43
46
|
});
|
|
44
47
|
}
|
|
45
48
|
/**
|
|
@@ -50,10 +53,10 @@ class High5Stream extends Base_1.default {
|
|
|
50
53
|
* @param streamId ID of the stream
|
|
51
54
|
* @returns The requested stream
|
|
52
55
|
*/
|
|
53
|
-
getStream(orgName, spaceName, eventName, streamId) {
|
|
56
|
+
getStream(orgName, spaceName, eventName, streamId, raw) {
|
|
54
57
|
return __awaiter(this, void 0, void 0, function* () {
|
|
55
58
|
const resp = yield this.axios.get(this.getEndpoint(`/v1/org/${orgName}/spaces/${spaceName}/events/${eventName}/streams/${streamId}`));
|
|
56
|
-
return resp.data;
|
|
59
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : resp.data);
|
|
57
60
|
});
|
|
58
61
|
}
|
|
59
62
|
/**
|
|
@@ -64,12 +67,12 @@ class High5Stream extends Base_1.default {
|
|
|
64
67
|
* @param name Name for the new stream
|
|
65
68
|
* @returns The created stream
|
|
66
69
|
*/
|
|
67
|
-
createStream(orgName, spaceName, eventName, name) {
|
|
70
|
+
createStream(orgName, spaceName, eventName, name, raw) {
|
|
68
71
|
return __awaiter(this, void 0, void 0, function* () {
|
|
69
72
|
const resp = yield this.axios.post(this.getEndpoint(`/v1/org/${orgName}/spaces/${spaceName}/events/${eventName}/streams`), {
|
|
70
73
|
name: name,
|
|
71
74
|
});
|
|
72
|
-
return resp.data;
|
|
75
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : resp.data);
|
|
73
76
|
});
|
|
74
77
|
}
|
|
75
78
|
/**
|
|
@@ -81,13 +84,13 @@ class High5Stream extends Base_1.default {
|
|
|
81
84
|
* @param sourceStreamId ID for the stream to duplicate
|
|
82
85
|
* @returns The created stream
|
|
83
86
|
*/
|
|
84
|
-
duplicateStream(orgName, spaceName, eventName, name, sourceStreamId) {
|
|
87
|
+
duplicateStream(orgName, spaceName, eventName, name, sourceStreamId, raw) {
|
|
85
88
|
return __awaiter(this, void 0, void 0, function* () {
|
|
86
89
|
const resp = yield this.axios.post(this.getEndpoint(`/v1/org/${orgName}/spaces/${spaceName}/events/${eventName}/streams`), {
|
|
87
90
|
name: name,
|
|
88
91
|
streamId: sourceStreamId,
|
|
89
92
|
});
|
|
90
|
-
return resp.data;
|
|
93
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : resp.data);
|
|
91
94
|
});
|
|
92
95
|
}
|
|
93
96
|
/**
|
|
@@ -98,10 +101,10 @@ class High5Stream extends Base_1.default {
|
|
|
98
101
|
* @param StreamPatchOrder List of all event streams with their new order
|
|
99
102
|
* @returns Array of updated Streams
|
|
100
103
|
*/
|
|
101
|
-
patchStreamOrderMulti(orgName, spaceName, eventName, streamList) {
|
|
104
|
+
patchStreamOrderMulti(orgName, spaceName, eventName, streamList, raw) {
|
|
102
105
|
return __awaiter(this, void 0, void 0, function* () {
|
|
103
106
|
const resp = yield this.axios.patch(this.getEndpoint(`/v1/org/${orgName}/spaces/${spaceName}/events/${eventName}/streams/order`), streamList);
|
|
104
|
-
return resp.data;
|
|
107
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : resp.data);
|
|
105
108
|
});
|
|
106
109
|
}
|
|
107
110
|
/**
|
|
@@ -113,10 +116,10 @@ class High5Stream extends Base_1.default {
|
|
|
113
116
|
* @param StreamPatchActive Object defining if stream should be active or inactive
|
|
114
117
|
* @returns Details of the updated stream
|
|
115
118
|
*/
|
|
116
|
-
patchStreamState(orgName, spaceName, eventName, streamId, streamPatchActive) {
|
|
119
|
+
patchStreamState(orgName, spaceName, eventName, streamId, streamPatchActive, raw) {
|
|
117
120
|
return __awaiter(this, void 0, void 0, function* () {
|
|
118
121
|
const resp = yield this.axios.patch(this.getEndpoint(`/v1/org/${orgName}/spaces/${spaceName}/events/${eventName}/streams/${streamId}/active`), streamPatchActive);
|
|
119
|
-
return resp.data;
|
|
122
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : resp.data);
|
|
120
123
|
});
|
|
121
124
|
}
|
|
122
125
|
/**
|
|
@@ -128,10 +131,10 @@ class High5Stream extends Base_1.default {
|
|
|
128
131
|
* @param SingleStreamPatchOrder Object defining if stream should move up or down
|
|
129
132
|
* @returns Array of updated Streams
|
|
130
133
|
*/
|
|
131
|
-
patchStreamOrder(orgName, spaceName, eventName, streamId, singleStreamPatchOrder) {
|
|
134
|
+
patchStreamOrder(orgName, spaceName, eventName, streamId, singleStreamPatchOrder, raw) {
|
|
132
135
|
return __awaiter(this, void 0, void 0, function* () {
|
|
133
136
|
const resp = yield this.axios.patch(this.getEndpoint(`/v1/org/${orgName}/spaces/${spaceName}/events/${eventName}/streams/${streamId}/order`), singleStreamPatchOrder);
|
|
134
|
-
return resp.data;
|
|
137
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : resp.data);
|
|
135
138
|
});
|
|
136
139
|
}
|
|
137
140
|
/**
|
|
@@ -143,10 +146,10 @@ class High5Stream extends Base_1.default {
|
|
|
143
146
|
* @param name New name of the stream
|
|
144
147
|
* @returns Updated stream
|
|
145
148
|
*/
|
|
146
|
-
renameStream(orgName, spaceName, eventName, streamId, name) {
|
|
149
|
+
renameStream(orgName, spaceName, eventName, streamId, name, raw) {
|
|
147
150
|
return __awaiter(this, void 0, void 0, function* () {
|
|
148
151
|
const resp = yield this.axios.patch(this.getEndpoint(`/v1/org/${orgName}/spaces/${spaceName}/events/${eventName}/streams/${streamId}/name`), { name });
|
|
149
|
-
return resp.data;
|
|
152
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : resp.data);
|
|
150
153
|
});
|
|
151
154
|
}
|
|
152
155
|
/**
|
|
@@ -161,10 +164,10 @@ class High5Stream extends Base_1.default {
|
|
|
161
164
|
* @param [order] (optional) Order the stream should have in the new event
|
|
162
165
|
* @returns Updated Stream
|
|
163
166
|
*/
|
|
164
|
-
moveStream(orgName, spaceName, eventName, streamId, newEventName, name, order) {
|
|
167
|
+
moveStream(orgName, spaceName, eventName, streamId, newEventName, name, order, raw) {
|
|
165
168
|
return __awaiter(this, void 0, void 0, function* () {
|
|
166
169
|
const resp = yield this.axios.patch(this.getEndpoint(`/v1/org/${orgName}/spaces/${spaceName}/events/${eventName}/streams/${streamId}/event`), { eventName: newEventName, name, order });
|
|
167
|
-
return resp.data;
|
|
170
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : resp.data);
|
|
168
171
|
});
|
|
169
172
|
}
|
|
170
173
|
/**
|
|
@@ -174,9 +177,10 @@ class High5Stream extends Base_1.default {
|
|
|
174
177
|
* @param eventName Name of the event
|
|
175
178
|
* @param streamId ID of the stream
|
|
176
179
|
*/
|
|
177
|
-
deleteStream(orgName, spaceName, eventName, streamId) {
|
|
180
|
+
deleteStream(orgName, spaceName, eventName, streamId, raw) {
|
|
178
181
|
return __awaiter(this, void 0, void 0, function* () {
|
|
179
|
-
yield this.axios.delete(this.getEndpoint(`/v1/org/${orgName}/spaces/${spaceName}/events/${eventName}/streams/${streamId}`));
|
|
182
|
+
const resp = yield this.axios.delete(this.getEndpoint(`/v1/org/${orgName}/spaces/${spaceName}/events/${eventName}/streams/${streamId}`));
|
|
183
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : undefined);
|
|
180
184
|
});
|
|
181
185
|
}
|
|
182
186
|
getEndpoint(endpoint) {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import Base from "../../../../Base";
|
|
1
|
+
import Base, { MaybeRaw } from "../../../../Base";
|
|
2
2
|
import { DebugCommand } from "../../../../interfaces/high5";
|
|
3
3
|
import { High5ExecutionPackage, High5ExecutionPatch, High5ExecutionRequest, High5ExecutionResponse } from "../../../../interfaces/high5/space/execution";
|
|
4
4
|
import { High5SpaceExecutionLogs } from "./log/index";
|
|
@@ -19,7 +19,9 @@ export declare class High5SpaceExecute extends Base {
|
|
|
19
19
|
* @param overrideUserAgent if true the User-Agent header will be overwritten with "hcloud-stream" to identify this execution got triggered from within a stream with the TriggerStreamAction node
|
|
20
20
|
* @returns the stream result
|
|
21
21
|
*/
|
|
22
|
-
executeHigh5Stream(orgName: string, spaceName: string, streamId: string, high5ExecutionRequest: High5ExecutionRequest, design?: boolean, debug?: boolean, overrideUserAgent?: boolean
|
|
22
|
+
executeHigh5Stream<R extends boolean = false>(orgName: string, spaceName: string, streamId: string, high5ExecutionRequest: High5ExecutionRequest, design?: boolean, debug?: boolean, overrideUserAgent?: boolean, raw?: {
|
|
23
|
+
raw: R;
|
|
24
|
+
}): Promise<MaybeRaw<R, High5ExecutionResponse>>;
|
|
23
25
|
/**
|
|
24
26
|
* Executes all streams within an event.
|
|
25
27
|
* @param orgName Name of the Organization
|
|
@@ -28,7 +30,9 @@ export declare class High5SpaceExecute extends Base {
|
|
|
28
30
|
* @param eventExecutionRequest Event execution request containing payload, target and a boolean specifying if it should be a dry run
|
|
29
31
|
* @returns Array of stream results
|
|
30
32
|
*/
|
|
31
|
-
executeHigh5Event(orgName: string, spaceName: string, eventName: string, high5EventExecutionRequest: High5ExecutionRequest
|
|
33
|
+
executeHigh5Event<R extends boolean = false>(orgName: string, spaceName: string, eventName: string, high5EventExecutionRequest: High5ExecutionRequest, raw?: {
|
|
34
|
+
raw: R;
|
|
35
|
+
}): Promise<MaybeRaw<R, High5ExecutionResponse[]>>;
|
|
32
36
|
/**
|
|
33
37
|
* Requests the StreamExecutionPackage for the provided Stream, which will hold all informations required to execute the Stream.
|
|
34
38
|
* @param orgName Name of the Organization
|
|
@@ -37,7 +41,9 @@ export declare class High5SpaceExecute extends Base {
|
|
|
37
41
|
* @param secret Secret of the Stream execution object
|
|
38
42
|
* @returns StreamExecutionPackage
|
|
39
43
|
*/
|
|
40
|
-
getStreamExecutionPackage(orgName: string, spaceName: string, streamId: string, secret: string
|
|
44
|
+
getStreamExecutionPackage<R extends boolean = false>(orgName: string, spaceName: string, streamId: string, secret: string, raw?: {
|
|
45
|
+
raw: R;
|
|
46
|
+
}): Promise<MaybeRaw<R, High5ExecutionPackage>>;
|
|
41
47
|
/**
|
|
42
48
|
* Publishes the stream status and logs to high5
|
|
43
49
|
* @param orgName the organizations's name
|
|
@@ -47,7 +53,9 @@ export declare class High5SpaceExecute extends Base {
|
|
|
47
53
|
* @param streamResult the result of the stream
|
|
48
54
|
* @returns StreamLog
|
|
49
55
|
*/
|
|
50
|
-
high5ExecutionStatusAndLogResponse(orgName: string, spaceName: string, secret: string, high5ExecutionResponse: High5ExecutionPatch
|
|
56
|
+
high5ExecutionStatusAndLogResponse<R extends boolean = false>(orgName: string, spaceName: string, secret: string, high5ExecutionResponse: High5ExecutionPatch, raw?: {
|
|
57
|
+
raw: R;
|
|
58
|
+
}): Promise<MaybeRaw<R, void>>;
|
|
51
59
|
/**
|
|
52
60
|
* Issue debug command to a stopped execution running in debug mode.
|
|
53
61
|
* If the agent that is handling this execution does not acknowledge
|
|
@@ -61,7 +69,9 @@ export declare class High5SpaceExecute extends Base {
|
|
|
61
69
|
* @param executionId ID of the execution. Obtained from High5ExecutionResponse
|
|
62
70
|
* @param command DebugCommand to send
|
|
63
71
|
*/
|
|
64
|
-
issueDebugCommand(orgName: string, spaceName: string, executionId: string, command: DebugCommand
|
|
72
|
+
issueDebugCommand<R extends boolean = false>(orgName: string, spaceName: string, executionId: string, command: DebugCommand, raw?: {
|
|
73
|
+
raw: R;
|
|
74
|
+
}): Promise<MaybeRaw<R, void>>;
|
|
65
75
|
/**
|
|
66
76
|
* Log an execution crash to High5
|
|
67
77
|
*
|
|
@@ -73,6 +83,8 @@ export declare class High5SpaceExecute extends Base {
|
|
|
73
83
|
* @param secret the secret of the stream execution object
|
|
74
84
|
* @param message crash log
|
|
75
85
|
*/
|
|
76
|
-
logExecutionCrash(orgName: string, spaceName: string, secret: string, message?: string
|
|
86
|
+
logExecutionCrash<R extends boolean = false>(orgName: string, spaceName: string, secret: string, message?: string, raw?: {
|
|
87
|
+
raw: R;
|
|
88
|
+
}): Promise<MaybeRaw<R, void>>;
|
|
77
89
|
protected getEndpoint(endpoint: string): string;
|
|
78
90
|
}
|
|
@@ -8,9 +8,12 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
8
8
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
9
|
});
|
|
10
10
|
};
|
|
11
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
12
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
13
|
+
};
|
|
11
14
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
15
|
exports.High5SpaceExecute = void 0;
|
|
13
|
-
const Base_1 = require("../../../../Base");
|
|
16
|
+
const Base_1 = __importDefault(require("../../../../Base"));
|
|
14
17
|
const index_1 = require("./log/index");
|
|
15
18
|
const index_2 = require("./status/index");
|
|
16
19
|
class High5SpaceExecute extends Base_1.default {
|
|
@@ -38,7 +41,7 @@ class High5SpaceExecute extends Base_1.default {
|
|
|
38
41
|
* @returns the stream result
|
|
39
42
|
*/
|
|
40
43
|
executeHigh5Stream(orgName_1, spaceName_1, streamId_1, high5ExecutionRequest_1) {
|
|
41
|
-
return __awaiter(this, arguments, void 0, function* (orgName, spaceName, streamId, high5ExecutionRequest, design = false, debug = false, overrideUserAgent = false) {
|
|
44
|
+
return __awaiter(this, arguments, void 0, function* (orgName, spaceName, streamId, high5ExecutionRequest, design = false, debug = false, overrideUserAgent = false, raw) {
|
|
42
45
|
if (overrideUserAgent) {
|
|
43
46
|
this.axios.defaults.headers.common["User-Agent"] = "hcloud-stream";
|
|
44
47
|
}
|
|
@@ -48,7 +51,7 @@ class High5SpaceExecute extends Base_1.default {
|
|
|
48
51
|
debug,
|
|
49
52
|
},
|
|
50
53
|
});
|
|
51
|
-
return resp.data;
|
|
54
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : resp.data);
|
|
52
55
|
});
|
|
53
56
|
}
|
|
54
57
|
/**
|
|
@@ -59,10 +62,10 @@ class High5SpaceExecute extends Base_1.default {
|
|
|
59
62
|
* @param eventExecutionRequest Event execution request containing payload, target and a boolean specifying if it should be a dry run
|
|
60
63
|
* @returns Array of stream results
|
|
61
64
|
*/
|
|
62
|
-
executeHigh5Event(orgName, spaceName, eventName, high5EventExecutionRequest) {
|
|
65
|
+
executeHigh5Event(orgName, spaceName, eventName, high5EventExecutionRequest, raw) {
|
|
63
66
|
return __awaiter(this, void 0, void 0, function* () {
|
|
64
67
|
const resp = yield this.axios.post(this.getEndpoint(`/v1/org/${orgName}/spaces/${spaceName}/execute/event/name/${eventName}`), high5EventExecutionRequest);
|
|
65
|
-
return resp.data;
|
|
68
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : resp.data);
|
|
66
69
|
});
|
|
67
70
|
}
|
|
68
71
|
/**
|
|
@@ -73,10 +76,10 @@ class High5SpaceExecute extends Base_1.default {
|
|
|
73
76
|
* @param secret Secret of the Stream execution object
|
|
74
77
|
* @returns StreamExecutionPackage
|
|
75
78
|
*/
|
|
76
|
-
getStreamExecutionPackage(orgName, spaceName, streamId, secret) {
|
|
79
|
+
getStreamExecutionPackage(orgName, spaceName, streamId, secret, raw) {
|
|
77
80
|
return __awaiter(this, void 0, void 0, function* () {
|
|
78
81
|
const resp = yield this.axios.get(this.getEndpoint(`/v1/org/${orgName}/spaces/${spaceName}/execute/stream/id/${streamId}/package/${secret}`));
|
|
79
|
-
return resp.data;
|
|
82
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : resp.data);
|
|
80
83
|
});
|
|
81
84
|
}
|
|
82
85
|
/**
|
|
@@ -88,9 +91,10 @@ class High5SpaceExecute extends Base_1.default {
|
|
|
88
91
|
* @param streamResult the result of the stream
|
|
89
92
|
* @returns StreamLog
|
|
90
93
|
*/
|
|
91
|
-
high5ExecutionStatusAndLogResponse(orgName, spaceName, secret, high5ExecutionResponse) {
|
|
94
|
+
high5ExecutionStatusAndLogResponse(orgName, spaceName, secret, high5ExecutionResponse, raw) {
|
|
92
95
|
return __awaiter(this, void 0, void 0, function* () {
|
|
93
|
-
yield this.axios.patch(this.getEndpoint(`/v1/org/${orgName}/spaces/${spaceName}/execution/streams/${secret}`), high5ExecutionResponse);
|
|
96
|
+
const resp = yield this.axios.patch(this.getEndpoint(`/v1/org/${orgName}/spaces/${spaceName}/execution/streams/${secret}`), high5ExecutionResponse);
|
|
97
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : undefined);
|
|
94
98
|
});
|
|
95
99
|
}
|
|
96
100
|
/**
|
|
@@ -106,9 +110,10 @@ class High5SpaceExecute extends Base_1.default {
|
|
|
106
110
|
* @param executionId ID of the execution. Obtained from High5ExecutionResponse
|
|
107
111
|
* @param command DebugCommand to send
|
|
108
112
|
*/
|
|
109
|
-
issueDebugCommand(orgName, spaceName, executionId, command) {
|
|
113
|
+
issueDebugCommand(orgName, spaceName, executionId, command, raw) {
|
|
110
114
|
return __awaiter(this, void 0, void 0, function* () {
|
|
111
|
-
yield this.axios.post(this.getEndpoint(`/v1/org/${orgName}/spaces/${spaceName}/execute/${executionId}/debug`), command);
|
|
115
|
+
const resp = yield this.axios.post(this.getEndpoint(`/v1/org/${orgName}/spaces/${spaceName}/execute/${executionId}/debug`), command);
|
|
116
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : undefined);
|
|
112
117
|
});
|
|
113
118
|
}
|
|
114
119
|
/**
|
|
@@ -122,9 +127,12 @@ class High5SpaceExecute extends Base_1.default {
|
|
|
122
127
|
* @param secret the secret of the stream execution object
|
|
123
128
|
* @param message crash log
|
|
124
129
|
*/
|
|
125
|
-
logExecutionCrash(orgName, spaceName, secret, message) {
|
|
130
|
+
logExecutionCrash(orgName, spaceName, secret, message, raw) {
|
|
126
131
|
return __awaiter(this, void 0, void 0, function* () {
|
|
127
|
-
yield this.axios.patch(this.getEndpoint(`/v1/org/${orgName}/spaces/${spaceName}/execution/streams/${secret}/crash`), {
|
|
132
|
+
const resp = yield this.axios.patch(this.getEndpoint(`/v1/org/${orgName}/spaces/${spaceName}/execution/streams/${secret}/crash`), {
|
|
133
|
+
message,
|
|
134
|
+
});
|
|
135
|
+
return ((raw === null || raw === void 0 ? void 0 : raw.raw) ? resp : undefined);
|
|
128
136
|
});
|
|
129
137
|
}
|
|
130
138
|
getEndpoint(endpoint) {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import Base from "../../../../../Base";
|
|
1
|
+
import Base, { MaybeRaw } from "../../../../../Base";
|
|
2
2
|
import { PaginatedResponse, SearchParams } from "../../../../../interfaces/global";
|
|
3
3
|
import { High5ExecutionLog } from "../../../../../interfaces/high5/space/execution";
|
|
4
4
|
export declare class High5SpaceExecutionLogs extends Base {
|
|
@@ -12,11 +12,13 @@ export declare class High5SpaceExecutionLogs extends Base {
|
|
|
12
12
|
* @param page (optional) Page number: Skip the first (page * limit) results (defaults to 0)
|
|
13
13
|
* @returns Object containing an array of Stream execution logs as well as the total number of results
|
|
14
14
|
*/
|
|
15
|
-
searchExecutionLogs({ orgName, spaceName, payload, filters, sorting, limit, page, }: SearchParams & {
|
|
15
|
+
searchExecutionLogs<R extends boolean = false>({ orgName, spaceName, payload, filters, sorting, limit, page, }: SearchParams & {
|
|
16
16
|
orgName: string;
|
|
17
17
|
spaceName: string;
|
|
18
18
|
payload?: boolean;
|
|
19
|
-
}
|
|
19
|
+
}, raw?: {
|
|
20
|
+
raw: R;
|
|
21
|
+
}): Promise<MaybeRaw<R, PaginatedResponse<High5ExecutionLog>>>;
|
|
20
22
|
/**
|
|
21
23
|
* Retrieves the execution log of a stream.
|
|
22
24
|
* @param orgName Name of the Organization
|
|
@@ -24,6 +26,8 @@ export declare class High5SpaceExecutionLogs extends Base {
|
|
|
24
26
|
* @param streamLogId ID of the stream log
|
|
25
27
|
* @returns Stream execution log
|
|
26
28
|
*/
|
|
27
|
-
getStreamExecutionLog(orgName: string, spaceName: string, streamLogId: string, payload?: boolean
|
|
29
|
+
getStreamExecutionLog<R extends boolean = false>(orgName: string, spaceName: string, streamLogId: string, payload?: boolean, raw?: {
|
|
30
|
+
raw: R;
|
|
31
|
+
}): Promise<MaybeRaw<R, High5ExecutionLog>>;
|
|
28
32
|
protected getEndpoint(endpoint: string): string;
|
|
29
33
|
}
|