@autifyhq/autify-sdk 0.1.1 → 0.4.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.
@@ -122,6 +122,94 @@ export interface CapabilityOption {
122
122
  */
123
123
  unsupported?: boolean;
124
124
  }
125
+ /**
126
+ *
127
+ * @export
128
+ * @interface CreateAccessPoint400Response
129
+ */
130
+ export interface CreateAccessPoint400Response {
131
+ /**
132
+ *
133
+ * @type {Array<CreateAccessPoint400ResponseErrorsInner>}
134
+ * @memberof CreateAccessPoint400Response
135
+ */
136
+ errors?: Array<CreateAccessPoint400ResponseErrorsInner>;
137
+ }
138
+ /**
139
+ *
140
+ * @export
141
+ * @interface CreateAccessPoint400ResponseErrorsInner
142
+ */
143
+ export interface CreateAccessPoint400ResponseErrorsInner {
144
+ /**
145
+ *
146
+ * @type {number}
147
+ * @memberof CreateAccessPoint400ResponseErrorsInner
148
+ */
149
+ code?: number;
150
+ /**
151
+ *
152
+ * @type {string}
153
+ * @memberof CreateAccessPoint400ResponseErrorsInner
154
+ */
155
+ message?: string;
156
+ }
157
+ /**
158
+ *
159
+ * @export
160
+ * @interface CreateAccessPointRequest
161
+ */
162
+ export interface CreateAccessPointRequest {
163
+ /**
164
+ * Name of the access point to be created
165
+ * @type {string}
166
+ * @memberof CreateAccessPointRequest
167
+ */
168
+ name: string;
169
+ }
170
+ /**
171
+ *
172
+ * @export
173
+ * @interface CreateAccessPointResult
174
+ */
175
+ export interface CreateAccessPointResult {
176
+ /**
177
+ *
178
+ * @type {string}
179
+ * @memberof CreateAccessPointResult
180
+ */
181
+ name: string;
182
+ /**
183
+ *
184
+ * @type {string}
185
+ * @memberof CreateAccessPointResult
186
+ */
187
+ key: string;
188
+ /**
189
+ *
190
+ * @type {string}
191
+ * @memberof CreateAccessPointResult
192
+ */
193
+ creator: string;
194
+ /**
195
+ *
196
+ * @type {string}
197
+ * @memberof CreateAccessPointResult
198
+ */
199
+ last_use?: string;
200
+ /**
201
+ *
202
+ * @type {string}
203
+ * @memberof CreateAccessPointResult
204
+ */
205
+ created_at?: string;
206
+ /**
207
+ *
208
+ * @type {string}
209
+ * @memberof CreateAccessPointResult
210
+ */
211
+ updated_at?: string;
212
+ }
125
213
  /**
126
214
  *
127
215
  * @export
@@ -141,6 +229,51 @@ export interface CreateUrlReplacementRequest {
141
229
  */
142
230
  replacement_url: string;
143
231
  }
232
+ /**
233
+ *
234
+ * @export
235
+ * @interface DeleteAccessPoint404Response
236
+ */
237
+ export interface DeleteAccessPoint404Response {
238
+ /**
239
+ *
240
+ * @type {Array<DeleteAccessPoint404ResponseErrorsInner>}
241
+ * @memberof DeleteAccessPoint404Response
242
+ */
243
+ errors?: Array<DeleteAccessPoint404ResponseErrorsInner>;
244
+ }
245
+ /**
246
+ *
247
+ * @export
248
+ * @interface DeleteAccessPoint404ResponseErrorsInner
249
+ */
250
+ export interface DeleteAccessPoint404ResponseErrorsInner {
251
+ /**
252
+ *
253
+ * @type {number}
254
+ * @memberof DeleteAccessPoint404ResponseErrorsInner
255
+ */
256
+ code?: number;
257
+ /**
258
+ *
259
+ * @type {string}
260
+ * @memberof DeleteAccessPoint404ResponseErrorsInner
261
+ */
262
+ message?: string;
263
+ }
264
+ /**
265
+ *
266
+ * @export
267
+ * @interface DeleteAccessPointRequest
268
+ */
269
+ export interface DeleteAccessPointRequest {
270
+ /**
271
+ * Name of the access point to be deleted
272
+ * @type {string}
273
+ * @memberof DeleteAccessPointRequest
274
+ */
275
+ name: string;
276
+ }
144
277
  /**
145
278
  *
146
279
  * @export
@@ -209,6 +342,7 @@ export declare const DescribeResult200ResponseStatusEnum: {
209
342
  readonly Passed: "passed";
210
343
  readonly Failed: "failed";
211
344
  readonly Skipped: "skipped";
345
+ readonly InternalError: "internal_error";
212
346
  };
213
347
  export declare type DescribeResult200ResponseStatusEnum = typeof DescribeResult200ResponseStatusEnum[keyof typeof DescribeResult200ResponseStatusEnum];
214
348
  /**
@@ -367,12 +501,31 @@ export interface ExecuteScenariosRequest {
367
501
  * @memberof ExecuteScenariosRequest
368
502
  */
369
503
  scenarios: Array<ExecuteScenariosRequestScenariosInner>;
504
+ /**
505
+ *
506
+ * @type {ExecuteScenariosRequestAutifyConnect}
507
+ * @memberof ExecuteScenariosRequest
508
+ */
509
+ autify_connect?: ExecuteScenariosRequestAutifyConnect;
370
510
  }
371
511
  export declare const ExecuteScenariosRequestExecutionTypeEnum: {
372
512
  readonly Parallel: "parallel";
373
513
  readonly Sequential: "sequential";
374
514
  };
375
515
  export declare type ExecuteScenariosRequestExecutionTypeEnum = typeof ExecuteScenariosRequestExecutionTypeEnum[keyof typeof ExecuteScenariosRequestExecutionTypeEnum];
516
+ /**
517
+ *
518
+ * @export
519
+ * @interface ExecuteScenariosRequestAutifyConnect
520
+ */
521
+ export interface ExecuteScenariosRequestAutifyConnect {
522
+ /**
523
+ *
524
+ * @type {string}
525
+ * @memberof ExecuteScenariosRequestAutifyConnect
526
+ */
527
+ name: string;
528
+ }
376
529
  /**
377
530
  *
378
531
  * @export
@@ -585,37 +738,37 @@ export interface Label {
585
738
  /**
586
739
  *
587
740
  * @export
588
- * @interface Story
741
+ * @interface Scenario
589
742
  */
590
- export interface Story {
743
+ export interface Scenario {
591
744
  /**
592
745
  *
593
746
  * @type {number}
594
- * @memberof Story
747
+ * @memberof Scenario
595
748
  */
596
749
  id?: number;
597
750
  /**
598
751
  *
599
752
  * @type {string}
600
- * @memberof Story
753
+ * @memberof Scenario
601
754
  */
602
755
  name?: string;
603
756
  /**
604
757
  *
605
758
  * @type {string}
606
- * @memberof Story
759
+ * @memberof Scenario
607
760
  */
608
761
  created_at?: string;
609
762
  /**
610
763
  *
611
764
  * @type {string}
612
- * @memberof Story
765
+ * @memberof Scenario
613
766
  */
614
767
  updated_at?: string;
615
768
  /**
616
769
  *
617
770
  * @type {Array<Label>}
618
- * @memberof Story
771
+ * @memberof Scenario
619
772
  */
620
773
  labels?: Array<Label>;
621
774
  }
@@ -692,6 +845,7 @@ export declare const TestCaseResultStatusEnum: {
692
845
  readonly Passed: "passed";
693
846
  readonly Failed: "failed";
694
847
  readonly Skipped: "skipped";
848
+ readonly InternalError: "internal_error";
695
849
  };
696
850
  export declare type TestCaseResultStatusEnum = typeof TestCaseResultStatusEnum[keyof typeof TestCaseResultStatusEnum];
697
851
  /**
@@ -768,6 +922,7 @@ export declare const TestPlanCapabilityResultStatusEnum: {
768
922
  readonly Passed: "passed";
769
923
  readonly Failed: "failed";
770
924
  readonly Skipped: "skipped";
925
+ readonly InternalError: "internal_error";
771
926
  };
772
927
  export declare type TestPlanCapabilityResultStatusEnum = typeof TestPlanCapabilityResultStatusEnum[keyof typeof TestPlanCapabilityResultStatusEnum];
773
928
  /**
@@ -831,6 +986,7 @@ export declare const TestPlanResultStatusEnum: {
831
986
  readonly Passed: "passed";
832
987
  readonly Failed: "failed";
833
988
  readonly Skipped: "skipped";
989
+ readonly InternalError: "internal_error";
834
990
  };
835
991
  export declare type TestPlanResultStatusEnum = typeof TestPlanResultStatusEnum[keyof typeof TestPlanResultStatusEnum];
836
992
  /**
@@ -895,6 +1051,98 @@ export interface UrlReplacement {
895
1051
  */
896
1052
  updated_at: string;
897
1053
  }
1054
+ /**
1055
+ * AutifyConnectApi - axios parameter creator
1056
+ * @export
1057
+ */
1058
+ export declare const AutifyConnectApiAxiosParamCreator: (configuration?: Configuration) => {
1059
+ /**
1060
+ * You can generate a new access point by passing in its name.
1061
+ * @param {number} projectId For example, 1 for the following URL: https://app.autify.com/projects/1/scenarios
1062
+ * @param {CreateAccessPointRequest} createAccessPointRequest The name of the access point to be created
1063
+ * @param {*} [options] Override http request option.
1064
+ * @throws {RequiredError}
1065
+ */
1066
+ createAccessPoint: (projectId: number, createAccessPointRequest: CreateAccessPointRequest, options?: AxiosRequestConfig) => Promise<RequestArgs>;
1067
+ /**
1068
+ * You can delete an access point by passing in its name.
1069
+ * @param {number} projectId For example, 1 for the following URL: https://app.autify.com/projects/1/scenarios
1070
+ * @param {DeleteAccessPointRequest} deleteAccessPointRequest The name of the access point to be deleted
1071
+ * @param {*} [options] Override http request option.
1072
+ * @throws {RequiredError}
1073
+ */
1074
+ deleteAccessPoint: (projectId: number, deleteAccessPointRequest: DeleteAccessPointRequest, options?: AxiosRequestConfig) => Promise<RequestArgs>;
1075
+ };
1076
+ /**
1077
+ * AutifyConnectApi - functional programming interface
1078
+ * @export
1079
+ */
1080
+ export declare const AutifyConnectApiFp: (configuration?: Configuration) => {
1081
+ /**
1082
+ * You can generate a new access point by passing in its name.
1083
+ * @param {number} projectId For example, 1 for the following URL: https://app.autify.com/projects/1/scenarios
1084
+ * @param {CreateAccessPointRequest} createAccessPointRequest The name of the access point to be created
1085
+ * @param {*} [options] Override http request option.
1086
+ * @throws {RequiredError}
1087
+ */
1088
+ createAccessPoint(projectId: number, createAccessPointRequest: CreateAccessPointRequest, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<CreateAccessPointResult>>;
1089
+ /**
1090
+ * You can delete an access point by passing in its name.
1091
+ * @param {number} projectId For example, 1 for the following URL: https://app.autify.com/projects/1/scenarios
1092
+ * @param {DeleteAccessPointRequest} deleteAccessPointRequest The name of the access point to be deleted
1093
+ * @param {*} [options] Override http request option.
1094
+ * @throws {RequiredError}
1095
+ */
1096
+ deleteAccessPoint(projectId: number, deleteAccessPointRequest: DeleteAccessPointRequest, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<object>>;
1097
+ };
1098
+ /**
1099
+ * AutifyConnectApi - factory interface
1100
+ * @export
1101
+ */
1102
+ export declare const AutifyConnectApiFactory: (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) => {
1103
+ /**
1104
+ * You can generate a new access point by passing in its name.
1105
+ * @param {number} projectId For example, 1 for the following URL: https://app.autify.com/projects/1/scenarios
1106
+ * @param {CreateAccessPointRequest} createAccessPointRequest The name of the access point to be created
1107
+ * @param {*} [options] Override http request option.
1108
+ * @throws {RequiredError}
1109
+ */
1110
+ createAccessPoint(projectId: number, createAccessPointRequest: CreateAccessPointRequest, options?: any): AxiosPromise<CreateAccessPointResult>;
1111
+ /**
1112
+ * You can delete an access point by passing in its name.
1113
+ * @param {number} projectId For example, 1 for the following URL: https://app.autify.com/projects/1/scenarios
1114
+ * @param {DeleteAccessPointRequest} deleteAccessPointRequest The name of the access point to be deleted
1115
+ * @param {*} [options] Override http request option.
1116
+ * @throws {RequiredError}
1117
+ */
1118
+ deleteAccessPoint(projectId: number, deleteAccessPointRequest: DeleteAccessPointRequest, options?: any): AxiosPromise<object>;
1119
+ };
1120
+ /**
1121
+ * AutifyConnectApi - object-oriented interface
1122
+ * @export
1123
+ * @class AutifyConnectApi
1124
+ * @extends {BaseAPI}
1125
+ */
1126
+ export declare class AutifyConnectApi extends BaseAPI {
1127
+ /**
1128
+ * You can generate a new access point by passing in its name.
1129
+ * @param {number} projectId For example, 1 for the following URL: https://app.autify.com/projects/1/scenarios
1130
+ * @param {CreateAccessPointRequest} createAccessPointRequest The name of the access point to be created
1131
+ * @param {*} [options] Override http request option.
1132
+ * @throws {RequiredError}
1133
+ * @memberof AutifyConnectApi
1134
+ */
1135
+ createAccessPoint(projectId: number, createAccessPointRequest: CreateAccessPointRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<CreateAccessPointResult, any>>;
1136
+ /**
1137
+ * You can delete an access point by passing in its name.
1138
+ * @param {number} projectId For example, 1 for the following URL: https://app.autify.com/projects/1/scenarios
1139
+ * @param {DeleteAccessPointRequest} deleteAccessPointRequest The name of the access point to be deleted
1140
+ * @param {*} [options] Override http request option.
1141
+ * @throws {RequiredError}
1142
+ * @memberof AutifyConnectApi
1143
+ */
1144
+ deleteAccessPoint(projectId: number, deleteAccessPointRequest: DeleteAccessPointRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<object, any>>;
1145
+ }
898
1146
  /**
899
1147
  * CapabilityApi - axios parameter creator
900
1148
  * @export
@@ -1104,7 +1352,7 @@ export declare const ScenarioApiFp: (configuration?: Configuration) => {
1104
1352
  * @param {*} [options] Override http request option.
1105
1353
  * @throws {RequiredError}
1106
1354
  */
1107
- describeScenario(projectId: number, scenarioId: number, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<Story>>;
1355
+ describeScenario(projectId: number, scenarioId: number, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<Scenario>>;
1108
1356
  /**
1109
1357
  * You can execute any scenarios in your workspace using any execution environments (which is called \"capabilities\" here).
1110
1358
  * @param {number} projectId For example, 1 for the following URL: https://app.autify.com/projects/1/scenarios
@@ -1120,7 +1368,7 @@ export declare const ScenarioApiFp: (configuration?: Configuration) => {
1120
1368
  * @param {*} [options] Override http request option.
1121
1369
  * @throws {RequiredError}
1122
1370
  */
1123
- listScenarios(projectId: number, page?: number, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<Array<Story>>>;
1371
+ listScenarios(projectId: number, page?: number, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<Array<Scenario>>>;
1124
1372
  };
1125
1373
  /**
1126
1374
  * ScenarioApi - factory interface
@@ -1134,7 +1382,7 @@ export declare const ScenarioApiFactory: (configuration?: Configuration, basePat
1134
1382
  * @param {*} [options] Override http request option.
1135
1383
  * @throws {RequiredError}
1136
1384
  */
1137
- describeScenario(projectId: number, scenarioId: number, options?: any): AxiosPromise<Story>;
1385
+ describeScenario(projectId: number, scenarioId: number, options?: any): AxiosPromise<Scenario>;
1138
1386
  /**
1139
1387
  * You can execute any scenarios in your workspace using any execution environments (which is called \"capabilities\" here).
1140
1388
  * @param {number} projectId For example, 1 for the following URL: https://app.autify.com/projects/1/scenarios
@@ -1150,7 +1398,7 @@ export declare const ScenarioApiFactory: (configuration?: Configuration, basePat
1150
1398
  * @param {*} [options] Override http request option.
1151
1399
  * @throws {RequiredError}
1152
1400
  */
1153
- listScenarios(projectId: number, page?: number, options?: any): AxiosPromise<Array<Story>>;
1401
+ listScenarios(projectId: number, page?: number, options?: any): AxiosPromise<Array<Scenario>>;
1154
1402
  };
1155
1403
  /**
1156
1404
  * ScenarioApi - object-oriented interface
@@ -1167,7 +1415,7 @@ export declare class ScenarioApi extends BaseAPI {
1167
1415
  * @throws {RequiredError}
1168
1416
  * @memberof ScenarioApi
1169
1417
  */
1170
- describeScenario(projectId: number, scenarioId: number, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<Story, any>>;
1418
+ describeScenario(projectId: number, scenarioId: number, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<Scenario, any>>;
1171
1419
  /**
1172
1420
  * You can execute any scenarios in your workspace using any execution environments (which is called \"capabilities\" here).
1173
1421
  * @param {number} projectId For example, 1 for the following URL: https://app.autify.com/projects/1/scenarios
@@ -1185,7 +1433,7 @@ export declare class ScenarioApi extends BaseAPI {
1185
1433
  * @throws {RequiredError}
1186
1434
  * @memberof ScenarioApi
1187
1435
  */
1188
- listScenarios(projectId: number, page?: number, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<Story[], any>>;
1436
+ listScenarios(projectId: number, page?: number, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<Scenario[], any>>;
1189
1437
  }
1190
1438
  /**
1191
1439
  * ScheduleApi - axios parameter creator
@@ -13,7 +13,7 @@
13
13
  * Do not edit the class manually.
14
14
  */
15
15
  Object.defineProperty(exports, "__esModule", { value: true });
16
- exports.UrlReplacementApi = exports.UrlReplacementApiFactory = exports.UrlReplacementApiFp = exports.UrlReplacementApiAxiosParamCreator = exports.ScheduleApi = exports.ScheduleApiFactory = exports.ScheduleApiFp = exports.ScheduleApiAxiosParamCreator = exports.ScenarioApi = exports.ScenarioApiFactory = exports.ScenarioApiFp = exports.ScenarioApiAxiosParamCreator = exports.ResultApi = exports.ResultApiFactory = exports.ResultApiFp = exports.ResultApiAxiosParamCreator = exports.CapabilityApi = exports.CapabilityApiFactory = exports.CapabilityApiFp = exports.CapabilityApiAxiosParamCreator = exports.TestPlanResultStatusEnum = exports.TestPlanCapabilityResultStatusEnum = exports.TestCaseResultStatusEnum = exports.ExecuteScenariosRequestExecutionTypeEnum = exports.DescribeResult200ResponseStatusEnum = void 0;
16
+ exports.UrlReplacementApi = exports.UrlReplacementApiFactory = exports.UrlReplacementApiFp = exports.UrlReplacementApiAxiosParamCreator = exports.ScheduleApi = exports.ScheduleApiFactory = exports.ScheduleApiFp = exports.ScheduleApiAxiosParamCreator = exports.ScenarioApi = exports.ScenarioApiFactory = exports.ScenarioApiFp = exports.ScenarioApiAxiosParamCreator = exports.ResultApi = exports.ResultApiFactory = exports.ResultApiFp = exports.ResultApiAxiosParamCreator = exports.CapabilityApi = exports.CapabilityApiFactory = exports.CapabilityApiFp = exports.CapabilityApiAxiosParamCreator = exports.AutifyConnectApi = exports.AutifyConnectApiFactory = exports.AutifyConnectApiFp = exports.AutifyConnectApiAxiosParamCreator = exports.TestPlanResultStatusEnum = exports.TestPlanCapabilityResultStatusEnum = exports.TestCaseResultStatusEnum = exports.ExecuteScenariosRequestExecutionTypeEnum = exports.DescribeResult200ResponseStatusEnum = void 0;
17
17
  const tslib_1 = require("tslib");
18
18
  const axios_1 = tslib_1.__importDefault(require("axios"));
19
19
  // URLSearchParams not necessarily used
@@ -31,6 +31,7 @@ exports.DescribeResult200ResponseStatusEnum = {
31
31
  Passed: "passed",
32
32
  Failed: "failed",
33
33
  Skipped: "skipped",
34
+ InternalError: "internal_error",
34
35
  };
35
36
  exports.ExecuteScenariosRequestExecutionTypeEnum = {
36
37
  Parallel: "parallel",
@@ -42,6 +43,7 @@ exports.TestCaseResultStatusEnum = {
42
43
  Passed: "passed",
43
44
  Failed: "failed",
44
45
  Skipped: "skipped",
46
+ InternalError: "internal_error",
45
47
  };
46
48
  exports.TestPlanCapabilityResultStatusEnum = {
47
49
  Waiting: "waiting",
@@ -49,6 +51,7 @@ exports.TestPlanCapabilityResultStatusEnum = {
49
51
  Passed: "passed",
50
52
  Failed: "failed",
51
53
  Skipped: "skipped",
54
+ InternalError: "internal_error",
52
55
  };
53
56
  exports.TestPlanResultStatusEnum = {
54
57
  Waiting: "waiting",
@@ -56,7 +59,204 @@ exports.TestPlanResultStatusEnum = {
56
59
  Passed: "passed",
57
60
  Failed: "failed",
58
61
  Skipped: "skipped",
62
+ InternalError: "internal_error",
59
63
  };
64
+ /**
65
+ * AutifyConnectApi - axios parameter creator
66
+ * @export
67
+ */
68
+ const AutifyConnectApiAxiosParamCreator = function (configuration) {
69
+ return {
70
+ /**
71
+ * You can generate a new access point by passing in its name.
72
+ * @param {number} projectId For example, 1 for the following URL: https://app.autify.com/projects/1/scenarios
73
+ * @param {CreateAccessPointRequest} createAccessPointRequest The name of the access point to be created
74
+ * @param {*} [options] Override http request option.
75
+ * @throws {RequiredError}
76
+ */
77
+ createAccessPoint: async (projectId, createAccessPointRequest, options = {}) => {
78
+ // verify required parameter 'projectId' is not null or undefined
79
+ (0, common_1.assertParamExists)("createAccessPoint", "projectId", projectId);
80
+ // verify required parameter 'createAccessPointRequest' is not null or undefined
81
+ (0, common_1.assertParamExists)("createAccessPoint", "createAccessPointRequest", createAccessPointRequest);
82
+ const localVarPath = `/projects/{project_id}/autify_connect/access_points`.replace(`{${"project_id"}}`, encodeURIComponent(String(projectId)));
83
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
84
+ const localVarUrlObj = new url_1.URL(localVarPath, common_1.DUMMY_BASE_URL);
85
+ let baseOptions;
86
+ if (configuration) {
87
+ baseOptions = configuration.baseOptions;
88
+ }
89
+ const localVarRequestOptions = {
90
+ method: "POST",
91
+ ...baseOptions,
92
+ ...options,
93
+ };
94
+ const localVarHeaderParameter = {};
95
+ const localVarQueryParameter = {};
96
+ // authentication bearerAuth required
97
+ // http bearer authentication required
98
+ await (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration);
99
+ localVarHeaderParameter["Content-Type"] = "application/json";
100
+ (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
101
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
102
+ localVarRequestOptions.headers = {
103
+ ...localVarHeaderParameter,
104
+ ...headersFromBaseOptions,
105
+ ...options.headers,
106
+ };
107
+ localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(createAccessPointRequest, localVarRequestOptions, configuration);
108
+ return {
109
+ url: (0, common_1.toPathString)(localVarUrlObj),
110
+ options: localVarRequestOptions,
111
+ };
112
+ },
113
+ /**
114
+ * You can delete an access point by passing in its name.
115
+ * @param {number} projectId For example, 1 for the following URL: https://app.autify.com/projects/1/scenarios
116
+ * @param {DeleteAccessPointRequest} deleteAccessPointRequest The name of the access point to be deleted
117
+ * @param {*} [options] Override http request option.
118
+ * @throws {RequiredError}
119
+ */
120
+ deleteAccessPoint: async (projectId, deleteAccessPointRequest, options = {}) => {
121
+ // verify required parameter 'projectId' is not null or undefined
122
+ (0, common_1.assertParamExists)("deleteAccessPoint", "projectId", projectId);
123
+ // verify required parameter 'deleteAccessPointRequest' is not null or undefined
124
+ (0, common_1.assertParamExists)("deleteAccessPoint", "deleteAccessPointRequest", deleteAccessPointRequest);
125
+ const localVarPath = `/projects/{project_id}/autify_connect/access_points`.replace(`{${"project_id"}}`, encodeURIComponent(String(projectId)));
126
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
127
+ const localVarUrlObj = new url_1.URL(localVarPath, common_1.DUMMY_BASE_URL);
128
+ let baseOptions;
129
+ if (configuration) {
130
+ baseOptions = configuration.baseOptions;
131
+ }
132
+ const localVarRequestOptions = {
133
+ method: "DELETE",
134
+ ...baseOptions,
135
+ ...options,
136
+ };
137
+ const localVarHeaderParameter = {};
138
+ const localVarQueryParameter = {};
139
+ // authentication bearerAuth required
140
+ // http bearer authentication required
141
+ await (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration);
142
+ localVarHeaderParameter["Content-Type"] = "application/json";
143
+ (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
144
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
145
+ localVarRequestOptions.headers = {
146
+ ...localVarHeaderParameter,
147
+ ...headersFromBaseOptions,
148
+ ...options.headers,
149
+ };
150
+ localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(deleteAccessPointRequest, localVarRequestOptions, configuration);
151
+ return {
152
+ url: (0, common_1.toPathString)(localVarUrlObj),
153
+ options: localVarRequestOptions,
154
+ };
155
+ },
156
+ };
157
+ };
158
+ exports.AutifyConnectApiAxiosParamCreator = AutifyConnectApiAxiosParamCreator;
159
+ /**
160
+ * AutifyConnectApi - functional programming interface
161
+ * @export
162
+ */
163
+ const AutifyConnectApiFp = function (configuration) {
164
+ const localVarAxiosParamCreator = (0, exports.AutifyConnectApiAxiosParamCreator)(configuration);
165
+ return {
166
+ /**
167
+ * You can generate a new access point by passing in its name.
168
+ * @param {number} projectId For example, 1 for the following URL: https://app.autify.com/projects/1/scenarios
169
+ * @param {CreateAccessPointRequest} createAccessPointRequest The name of the access point to be created
170
+ * @param {*} [options] Override http request option.
171
+ * @throws {RequiredError}
172
+ */
173
+ async createAccessPoint(projectId, createAccessPointRequest, options) {
174
+ const localVarAxiosArgs = await localVarAxiosParamCreator.createAccessPoint(projectId, createAccessPointRequest, options);
175
+ return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
176
+ },
177
+ /**
178
+ * You can delete an access point by passing in its name.
179
+ * @param {number} projectId For example, 1 for the following URL: https://app.autify.com/projects/1/scenarios
180
+ * @param {DeleteAccessPointRequest} deleteAccessPointRequest The name of the access point to be deleted
181
+ * @param {*} [options] Override http request option.
182
+ * @throws {RequiredError}
183
+ */
184
+ async deleteAccessPoint(projectId, deleteAccessPointRequest, options) {
185
+ const localVarAxiosArgs = await localVarAxiosParamCreator.deleteAccessPoint(projectId, deleteAccessPointRequest, options);
186
+ return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
187
+ },
188
+ };
189
+ };
190
+ exports.AutifyConnectApiFp = AutifyConnectApiFp;
191
+ /**
192
+ * AutifyConnectApi - factory interface
193
+ * @export
194
+ */
195
+ const AutifyConnectApiFactory = function (configuration, basePath, axios) {
196
+ const localVarFp = (0, exports.AutifyConnectApiFp)(configuration);
197
+ return {
198
+ /**
199
+ * You can generate a new access point by passing in its name.
200
+ * @param {number} projectId For example, 1 for the following URL: https://app.autify.com/projects/1/scenarios
201
+ * @param {CreateAccessPointRequest} createAccessPointRequest The name of the access point to be created
202
+ * @param {*} [options] Override http request option.
203
+ * @throws {RequiredError}
204
+ */
205
+ createAccessPoint(projectId, createAccessPointRequest, options) {
206
+ return localVarFp
207
+ .createAccessPoint(projectId, createAccessPointRequest, options)
208
+ .then((request) => request(axios, basePath));
209
+ },
210
+ /**
211
+ * You can delete an access point by passing in its name.
212
+ * @param {number} projectId For example, 1 for the following URL: https://app.autify.com/projects/1/scenarios
213
+ * @param {DeleteAccessPointRequest} deleteAccessPointRequest The name of the access point to be deleted
214
+ * @param {*} [options] Override http request option.
215
+ * @throws {RequiredError}
216
+ */
217
+ deleteAccessPoint(projectId, deleteAccessPointRequest, options) {
218
+ return localVarFp
219
+ .deleteAccessPoint(projectId, deleteAccessPointRequest, options)
220
+ .then((request) => request(axios, basePath));
221
+ },
222
+ };
223
+ };
224
+ exports.AutifyConnectApiFactory = AutifyConnectApiFactory;
225
+ /**
226
+ * AutifyConnectApi - object-oriented interface
227
+ * @export
228
+ * @class AutifyConnectApi
229
+ * @extends {BaseAPI}
230
+ */
231
+ class AutifyConnectApi extends base_1.BaseAPI {
232
+ /**
233
+ * You can generate a new access point by passing in its name.
234
+ * @param {number} projectId For example, 1 for the following URL: https://app.autify.com/projects/1/scenarios
235
+ * @param {CreateAccessPointRequest} createAccessPointRequest The name of the access point to be created
236
+ * @param {*} [options] Override http request option.
237
+ * @throws {RequiredError}
238
+ * @memberof AutifyConnectApi
239
+ */
240
+ createAccessPoint(projectId, createAccessPointRequest, options) {
241
+ return (0, exports.AutifyConnectApiFp)(this.configuration)
242
+ .createAccessPoint(projectId, createAccessPointRequest, options)
243
+ .then((request) => request(this.axios, this.basePath));
244
+ }
245
+ /**
246
+ * You can delete an access point by passing in its name.
247
+ * @param {number} projectId For example, 1 for the following URL: https://app.autify.com/projects/1/scenarios
248
+ * @param {DeleteAccessPointRequest} deleteAccessPointRequest The name of the access point to be deleted
249
+ * @param {*} [options] Override http request option.
250
+ * @throws {RequiredError}
251
+ * @memberof AutifyConnectApi
252
+ */
253
+ deleteAccessPoint(projectId, deleteAccessPointRequest, options) {
254
+ return (0, exports.AutifyConnectApiFp)(this.configuration)
255
+ .deleteAccessPoint(projectId, deleteAccessPointRequest, options)
256
+ .then((request) => request(this.axios, this.basePath));
257
+ }
258
+ }
259
+ exports.AutifyConnectApi = AutifyConnectApi;
60
260
  /**
61
261
  * CapabilityApi - axios parameter creator
62
262
  * @export
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@autifyhq/autify-sdk",
3
- "version": "0.1.1",
3
+ "version": "0.4.0",
4
4
  "description": "Autify SDK for JavaScript",
5
5
  "author": "Autify",
6
6
  "homepage": "https://github.com/autifyhq/autify-sdk-js",
@@ -39,7 +39,7 @@
39
39
  "prettier": "^2.6.2",
40
40
  "shx": "^0.3.4",
41
41
  "ts-jest": "^28.0.5",
42
- "ts-morph": "^15.1.0",
42
+ "ts-morph": "^16.0.0",
43
43
  "ts-node": "^10.8.1",
44
44
  "typescript": "^4.7.3"
45
45
  },