@ampsec/platform-client 63.0.0 → 63.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/src/dto/actionExecution.dto.d.ts +82 -0
- package/build/src/dto/actionExecution.dto.js +21 -0
- package/build/src/dto/actionExecution.dto.js.map +1 -0
- package/build/src/dto/coverage.dto.d.ts +16 -16
- package/build/src/dto/customScores.dto.d.ts +120 -12
- package/build/src/dto/customScores.dto.js +1 -1
- package/build/src/dto/customScores.dto.js.map +1 -1
- package/build/src/dto/enums/actionExecution.status.d.ts +6 -0
- package/build/src/dto/enums/actionExecution.status.js +11 -0
- package/build/src/dto/enums/actionExecution.status.js.map +1 -0
- package/build/src/dto/enums/index.d.ts +1 -0
- package/build/src/dto/enums/index.js +1 -0
- package/build/src/dto/enums/index.js.map +1 -1
- package/build/src/dto/flows.dto.d.ts +6 -6
- package/build/src/dto/index.d.ts +1 -0
- package/build/src/dto/index.js +1 -0
- package/build/src/dto/index.js.map +1 -1
- package/build/src/dto/platform/index.d.ts +1 -0
- package/build/src/dto/platform/index.js +1 -0
- package/build/src/dto/platform/index.js.map +1 -1
- package/build/src/dto/platform/platform.actionExecution.dto.d.ts +77 -0
- package/build/src/dto/platform/platform.actionExecution.dto.js +8 -0
- package/build/src/dto/platform/platform.actionExecution.dto.js.map +1 -0
- package/build/src/dto/platform/platform.customScores.dto.d.ts +120 -12
- package/build/src/dto/platform/platform.flows.dto.d.ts +4 -4
- package/build/src/dto/platform/platform.saasUsers.dto.d.ts +9 -9
- package/build/src/dto/saasUsers.dto.d.ts +28 -28
- package/build/src/dto/saasUsers.dto.js +1 -1
- package/build/src/services/AmpApi.d.ts +2 -1
- package/build/src/services/AmpApi.js +1 -0
- package/build/src/services/AmpApi.js.map +1 -1
- package/build/src/services/AmpSdk.d.ts +2 -1
- package/build/src/services/AmpSdk.js +1 -0
- package/build/src/services/AmpSdk.js.map +1 -1
- package/build/src/services/constants.d.ts +1 -0
- package/build/src/services/constants.js +1 -0
- package/build/src/services/constants.js.map +1 -1
- package/package.json +1 -1
- package/src/dto/actionExecution.dto.ts +24 -0
- package/src/dto/customScores.dto.ts +1 -1
- package/src/dto/enums/actionExecution.status.ts +6 -0
- package/src/dto/enums/index.ts +1 -0
- package/src/dto/index.ts +1 -0
- package/src/dto/platform/index.ts +1 -0
- package/src/dto/platform/platform.actionExecution.dto.ts +9 -0
- package/src/dto/saasUsers.dto.ts +1 -1
- package/src/services/AmpApi.ts +3 -0
- package/src/services/AmpSdk.ts +4 -0
- package/src/services/constants.ts +1 -0
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { AgentDto, AgentUpsertDto, AssetDto, CustomActionDto, CustomActionUpsertDto, CustomScoreCohortDto, CustomScoreCohortUpsertDto, CustomScoreValueDto, CustomScoreValueUpsertDto, FindingSpecDto, FindingSpecUpsertDto, ProviderDto, ReportResultDto, SaasAssetDto, SaasComponentDto, SaasUserDto, TenantDto, TenantUpsertDto, TokenDto, UserDto } from '../dto';
|
|
1
|
+
import { ActionExecutionDto, AgentDto, AgentUpsertDto, AssetDto, CustomActionDto, CustomActionUpsertDto, CustomScoreCohortDto, CustomScoreCohortUpsertDto, CustomScoreValueDto, CustomScoreValueUpsertDto, FindingSpecDto, FindingSpecUpsertDto, ProviderDto, ReportResultDto, SaasAssetDto, SaasComponentDto, SaasUserDto, TenantDto, TenantUpsertDto, TokenDto, UserDto } from '../dto';
|
|
2
2
|
import { AmpEntityService, AmpDataService, AmpReportService, AmpSettingsService, ConnectorsService, FindingsInsightsService, FindingsService, NotificationService, PredictionService } from '.';
|
|
3
3
|
import { AmpRestClientOptions, AgentIdentityService, ConnectorInstallService, EnumService, RestClient } from './rest';
|
|
4
4
|
import { UsersInsightsService } from './usersInsights.service';
|
|
@@ -18,6 +18,7 @@ export type AmpApiOptions = AmpRestClientOptions;
|
|
|
18
18
|
* - Tenants: {@link AmpApi.tenants}
|
|
19
19
|
*/
|
|
20
20
|
export declare class AmpApi {
|
|
21
|
+
readonly actionExecutions: AmpDataService<ActionExecutionDto>;
|
|
21
22
|
readonly agents: AmpEntityService<AgentUpsertDto, AgentDto>;
|
|
22
23
|
readonly asset: AmpDataService<AssetDto>;
|
|
23
24
|
readonly cohorts: CohortService;
|
|
@@ -21,6 +21,7 @@ const CohortService_1 = require("./rest/CohortService");
|
|
|
21
21
|
*/
|
|
22
22
|
class AmpApi {
|
|
23
23
|
constructor(rest) {
|
|
24
|
+
this.actionExecutions = new _1.AmpDataServiceImpl(rest, constants_1.KIND.ACTION_EXECUTION);
|
|
24
25
|
this.agents = new _1.AmpEntityServiceImpl(rest, constants_1.KIND.AGENTS);
|
|
25
26
|
this.asset = new _1.AmpDataServiceImpl(rest, constants_1.KIND.ASSETS);
|
|
26
27
|
this.cohorts = new CohortService_1.CohortService(rest);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AmpApi.js","sourceRoot":"","sources":["../../../src/services/AmpApi.ts"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"AmpApi.js","sourceRoot":"","sources":["../../../src/services/AmpApi.ts"],"names":[],"mappings":";;;AAuBA,wBAaW;AACX,2CAAmD;AACnD,iCAA0J;AAC1J,mEAA6D;AAC7D,2DAAqD;AACrD,wDAAmD;AAInD;;;;;;;;;;;GAWG;AACH,MAAa,MAAM;IA8BjB,YAAY,IAAgB;QAC1B,IAAI,CAAC,gBAAgB,GAAG,IAAI,qBAAkB,CAAqB,IAAI,EAAE,gBAAI,CAAC,gBAAgB,CAAC,CAAC;QAChG,IAAI,CAAC,MAAM,GAAG,IAAI,uBAAoB,CAA2B,IAAI,EAAE,gBAAI,CAAC,MAAM,CAAC,CAAC;QACpF,IAAI,CAAC,KAAK,GAAG,IAAI,qBAAkB,CAAW,IAAI,EAAE,gBAAI,CAAC,MAAM,CAAC,CAAC;QACjE,IAAI,CAAC,OAAO,GAAG,IAAI,6BAAa,CAAC,IAAI,CAAC,CAAC;QACvC,IAAI,CAAC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;QAC9C,IAAI,CAAC,UAAU,GAAG,IAAI,qBAAkB,CAAe,IAAI,EAAE,gBAAI,CAAC,WAAW,CAAC,CAAC;QAC/E,IAAI,CAAC,cAAc,GAAG,IAAI,qBAAkB,CAAmB,IAAI,EAAE,gBAAI,CAAC,eAAe,CAAC,CAAC;QAC3F,IAAI,CAAC,SAAS,GAAG,IAAI,qBAAkB,CAAc,IAAI,EAAE,gBAAI,CAAC,UAAU,CAAC,CAAC;QAC5E,IAAI,CAAC,QAAQ,GAAG,IAAI,qBAAkB,CAAC,IAAI,CAAC,CAAC;QAC7C,IAAI,CAAC,OAAO,GAAG,IAAI,uBAAoB,CAA6B,IAAI,EAAE,gBAAI,CAAC,OAAO,CAAC,CAAC;QACxF,IAAI,CAAC,MAAM,GAAG,IAAI,qBAAkB,CAAW,IAAI,EAAE,gBAAI,CAAC,MAAM,CAAC,CAAC;QAClE,IAAI,CAAC,KAAK,GAAG,IAAI,qBAAkB,CAAU,IAAI,EAAE,gBAAI,CAAC,KAAK,CAAC,CAAC;QAC/D,IAAI,CAAC,aAAa,GAAG,IAAI,4CAAoB,CAAC,IAAI,CAAC,CAAC;QACpD,IAAI,CAAC,UAAU,GAAG,IAAI,oBAAiB,CAAC,IAAI,EAAE,gBAAI,CAAC,QAAQ,CAAC,CAAC;IAC/D,CAAC;IAED,MAAM,CAAC,QAAQ,CAAC,OAAsB;QACpC,MAAM,IAAI,GAAG,IAAA,uBAAgB,EAAC,OAAO,CAAC,CAAC;QACvC,OAAO,IAAI,MAAM,CAAC,IAAI,CAAC,CAAC;IAC1B,CAAC;CACF;AAjED,wBAiEC"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { PlatformAgentDto, PlatformAgentUpsertDto, PlatformConnectorDto, PlatformConnectorUpsertDto, PlatformCustomActionDto, PlatformCustomActionUpsertDto, PlatformCustomScoreCohortDto, PlatformCustomScoreCohortUpsertDto, PlatformCustomScoreValueDto, PlatformCustomScoreValueUpsertDto, PlatformFindingDto, PlatformFindingSpecDto, PlatformFindingSpecUpsertDto, PlatformFindingUpsertDto, PlatformFlowSpecDto, PlatformFlowSpecUpsertDto, PlatformFlowStateDto, PlatformFlowStateUpsertDto, PlatformJobExecutionStateDto, PlatformJobExecutionStateUpsertDto, PlatformJobSpecDto, PlatformJobSpecUpsertDto, PlatformNotificationDto, PlatformNotificationUpsertDto, PlatformProviderUpsertDto, PlatformReportResultDto, PlatformReportResultUpsertDto, PlatformRiskContributorDto, PlatformRiskContributorUpsertDto, PlatformSaasComponentDto, PlatformSaasComponentUpsertDto, PlatformStagedSaasAssetDto, PlatformStagedSaasAssetUpsertDto, PlatformStagedSaasUserDto, PlatformStagedSaasUserUpsertDto, PlatformTokenDto, PlatformTokenUpsertDto, ProviderDto, TenantDto, TenantUpsertDto } from '../dto';
|
|
1
|
+
import { PlatformActionExecutionDto, PlatformActionExecutionUpsertDto, PlatformAgentDto, PlatformAgentUpsertDto, PlatformConnectorDto, PlatformConnectorUpsertDto, PlatformCustomActionDto, PlatformCustomActionUpsertDto, PlatformCustomScoreCohortDto, PlatformCustomScoreCohortUpsertDto, PlatformCustomScoreValueDto, PlatformCustomScoreValueUpsertDto, PlatformFindingDto, PlatformFindingSpecDto, PlatformFindingSpecUpsertDto, PlatformFindingUpsertDto, PlatformFlowSpecDto, PlatformFlowSpecUpsertDto, PlatformFlowStateDto, PlatformFlowStateUpsertDto, PlatformJobExecutionStateDto, PlatformJobExecutionStateUpsertDto, PlatformJobSpecDto, PlatformJobSpecUpsertDto, PlatformNotificationDto, PlatformNotificationUpsertDto, PlatformProviderUpsertDto, PlatformReportResultDto, PlatformReportResultUpsertDto, PlatformRiskContributorDto, PlatformRiskContributorUpsertDto, PlatformSaasComponentDto, PlatformSaasComponentUpsertDto, PlatformStagedSaasAssetDto, PlatformStagedSaasAssetUpsertDto, PlatformStagedSaasUserDto, PlatformStagedSaasUserUpsertDto, PlatformTokenDto, PlatformTokenUpsertDto, ProviderDto, TenantDto, TenantUpsertDto } from '../dto';
|
|
2
2
|
import { AmpEntityService, AmpSdkAssetService, AmpSdkTenantService, AmpSdkUserService, TruncatableAmpEntityService } from './entity.service';
|
|
3
3
|
import { AmpRestClientOptions, RestClient } from './rest';
|
|
4
4
|
import { EnumService } from './rest/EnumService';
|
|
@@ -17,6 +17,7 @@ export type AmpSdkOptions = AmpRestClientOptions;
|
|
|
17
17
|
* This client provides CRUD access to all of the AMP API.
|
|
18
18
|
*/
|
|
19
19
|
export declare class AmpSdkServices {
|
|
20
|
+
readonly actionExecutions: AmpEntityService<PlatformActionExecutionUpsertDto, PlatformActionExecutionDto>;
|
|
20
21
|
readonly agents: AmpEntityService<PlatformAgentUpsertDto, PlatformAgentDto>;
|
|
21
22
|
readonly asset: AmpSdkAssetService;
|
|
22
23
|
readonly connectors: AmpEntityService<PlatformConnectorUpsertDto, PlatformConnectorDto>;
|
|
@@ -20,6 +20,7 @@ const findingsInsights_service_1 = require("./findingsInsights.service");
|
|
|
20
20
|
*/
|
|
21
21
|
class AmpSdkServices {
|
|
22
22
|
constructor(rest) {
|
|
23
|
+
this.actionExecutions = new entity_service_1.AmpEntityServiceImpl(rest, constants_1.KIND.ACTION_EXECUTION, constants_1.TARGET_API_PLATFORM);
|
|
23
24
|
this.agents = new entity_service_1.AmpEntityServiceImpl(rest, constants_1.KIND.AGENTS, constants_1.TARGET_API_PLATFORM);
|
|
24
25
|
this.asset = new entity_service_1.AmpSdkAssetService(rest, constants_1.TARGET_API_PLATFORM);
|
|
25
26
|
this.connectors = new entity_service_1.AmpEntityServiceImpl(rest, constants_1.KIND.CONNECTORS, constants_1.TARGET_API_PLATFORM);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AmpSdk.js","sourceRoot":"","sources":["../../../src/services/AmpSdk.ts"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"AmpSdk.js","sourceRoot":"","sources":["../../../src/services/AmpSdk.ts"],"names":[],"mappings":";;;AA8CA,qDAQ0B;AAC1B,i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.dto';
|
|
3
|
+
import {ActionExecutionStatus} from './enums/actionExecution.status';
|
|
4
|
+
|
|
5
|
+
// TODO use more specific types if we are going to process this data. At the moment, we are only storing/displaying it as a string
|
|
6
|
+
export const _ActionExecutionInput = z.unknown();
|
|
7
|
+
export type ActionExecutionInput = z.infer<typeof _ActionExecutionInput>;
|
|
8
|
+
// TODO use more specific types if we are going to process this data. At the moment, we are only storing/displaying it as a string
|
|
9
|
+
export const _ActionExecutionOutput = z.unknown();
|
|
10
|
+
export type ActionExecutionOutput = z.infer<typeof _ActionExecutionOutput>;
|
|
11
|
+
|
|
12
|
+
export const _ActionExecutionDto = _BaseDto.extend({
|
|
13
|
+
tid: z.string(),
|
|
14
|
+
specId: z.string(),
|
|
15
|
+
status: z.nativeEnum(ActionExecutionStatus),
|
|
16
|
+
input: _ActionExecutionInput,
|
|
17
|
+
output: _ActionExecutionOutput,
|
|
18
|
+
executionTime: z.nullable(z.string()),
|
|
19
|
+
executionDuration: z.nullable(z.number()),
|
|
20
|
+
});
|
|
21
|
+
export type ActionExecutionDto = z.infer<typeof _ActionExecutionDto>;
|
|
22
|
+
|
|
23
|
+
export const _ActionExecutionUpsertDto = _ActionExecutionDto.partial(UPSERT_DTO_MASK);
|
|
24
|
+
export type ActionExecutionUpsertDto = z.infer<typeof _ActionExecutionUpsertDto>;
|
|
@@ -12,7 +12,7 @@ export const _CustomScoreValueUpsertDto = _CustomScoreValueDto.partial(UPSERT_DT
|
|
|
12
12
|
export type CustomScoreValueUpsertDto = z.infer<typeof _CustomScoreValueUpsertDto>;
|
|
13
13
|
|
|
14
14
|
export const _CustomScoreCohortDto = _BaseDto.extend({
|
|
15
|
-
cohort: _AmplifierCohortDto
|
|
15
|
+
cohort: z.union([_AmplifierCohortDto, z.array(_AmplifierCohortDto)]),
|
|
16
16
|
multiplier: z.number(),
|
|
17
17
|
});
|
|
18
18
|
export type CustomScoreCohortDto = z.infer<typeof _CustomScoreCohortDto>;
|
package/src/dto/enums/index.ts
CHANGED
package/src/dto/index.ts
CHANGED
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import {z} from 'zod';
|
|
2
|
+
import {_ActionExecutionDto, _ActionExecutionUpsertDto} from '../actionExecution.dto';
|
|
3
|
+
import {_TenantBased, _UpsertTenantBased} from './tenant.based.dto';
|
|
4
|
+
|
|
5
|
+
export const _PlatformActionExecutionDto = _ActionExecutionDto.merge(_TenantBased);
|
|
6
|
+
export type PlatformActionExecutionDto = z.infer<typeof _PlatformActionExecutionDto>;
|
|
7
|
+
|
|
8
|
+
export const _PlatformActionExecutionUpsertDto = _ActionExecutionUpsertDto.merge(_UpsertTenantBased);
|
|
9
|
+
export type PlatformActionExecutionUpsertDto = z.infer<typeof _PlatformActionExecutionUpsertDto>;
|
package/src/dto/saasUsers.dto.ts
CHANGED
|
@@ -11,7 +11,7 @@ export const _MfaFactorDto = z
|
|
|
11
11
|
status: z.union([z.literal('ACTIVE'), z.string()]).optional(),
|
|
12
12
|
vendorName: z.string().optional(),
|
|
13
13
|
factorType: z.string().optional(),
|
|
14
|
-
|
|
14
|
+
secure: _MfaRating.optional(),
|
|
15
15
|
})
|
|
16
16
|
.catchall(z.string());
|
|
17
17
|
|
package/src/services/AmpApi.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import {
|
|
2
|
+
ActionExecutionDto,
|
|
2
3
|
AgentDto,
|
|
3
4
|
AgentUpsertDto,
|
|
4
5
|
AssetDto,
|
|
@@ -55,6 +56,7 @@ export type AmpApiOptions = AmpRestClientOptions;
|
|
|
55
56
|
* - Tenants: {@link AmpApi.tenants}
|
|
56
57
|
*/
|
|
57
58
|
export class AmpApi {
|
|
59
|
+
readonly actionExecutions: AmpDataService<ActionExecutionDto>;
|
|
58
60
|
readonly agents: AmpEntityService<AgentUpsertDto, AgentDto>;
|
|
59
61
|
readonly asset: AmpDataService<AssetDto>;
|
|
60
62
|
readonly cohorts: CohortService;
|
|
@@ -84,6 +86,7 @@ export class AmpApi {
|
|
|
84
86
|
readonly prediction: PredictionService;
|
|
85
87
|
|
|
86
88
|
constructor(rest: RestClient) {
|
|
89
|
+
this.actionExecutions = new AmpDataServiceImpl<ActionExecutionDto>(rest, KIND.ACTION_EXECUTION);
|
|
87
90
|
this.agents = new AmpEntityServiceImpl<AgentUpsertDto, AgentDto>(rest, KIND.AGENTS);
|
|
88
91
|
this.asset = new AmpDataServiceImpl<AssetDto>(rest, KIND.ASSETS);
|
|
89
92
|
this.cohorts = new CohortService(rest);
|
package/src/services/AmpSdk.ts
CHANGED
|
@@ -1,4 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
|
+
PlatformActionExecutionDto,
|
|
3
|
+
PlatformActionExecutionUpsertDto,
|
|
2
4
|
PlatformAgentDto,
|
|
3
5
|
PlatformAgentUpsertDto,
|
|
4
6
|
PlatformConnectorDto,
|
|
@@ -71,6 +73,7 @@ export type AmpSdkOptions = AmpRestClientOptions;
|
|
|
71
73
|
* This client provides CRUD access to all of the AMP API.
|
|
72
74
|
*/
|
|
73
75
|
export class AmpSdkServices {
|
|
76
|
+
readonly actionExecutions: AmpEntityService<PlatformActionExecutionUpsertDto, PlatformActionExecutionDto>;
|
|
74
77
|
readonly agents: AmpEntityService<PlatformAgentUpsertDto, PlatformAgentDto>;
|
|
75
78
|
readonly asset: AmpSdkAssetService;
|
|
76
79
|
readonly connectors: AmpEntityService<PlatformConnectorUpsertDto, PlatformConnectorDto>;
|
|
@@ -102,6 +105,7 @@ export class AmpSdkServices {
|
|
|
102
105
|
readonly users: AmpSdkUserService;
|
|
103
106
|
|
|
104
107
|
constructor(rest: RestClient) {
|
|
108
|
+
this.actionExecutions = new AmpEntityServiceImpl<PlatformActionExecutionUpsertDto, PlatformActionExecutionDto>(rest, KIND.ACTION_EXECUTION, TARGET_API_PLATFORM);
|
|
105
109
|
this.agents = new AmpEntityServiceImpl<PlatformAgentUpsertDto, PlatformAgentDto>(rest, KIND.AGENTS, TARGET_API_PLATFORM);
|
|
106
110
|
this.asset = new AmpSdkAssetService(rest, TARGET_API_PLATFORM);
|
|
107
111
|
this.connectors = new AmpEntityServiceImpl<PlatformConnectorUpsertDto, PlatformConnectorDto>(rest, KIND.CONNECTORS, TARGET_API_PLATFORM);
|