@airtop/sdk 0.1.15 → 0.1.16
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/api/resources/profiles/client/Client.js +2 -2
- package/api/resources/sessions/client/Client.d.ts +9 -0
- package/api/resources/sessions/client/Client.js +65 -12
- package/api/resources/sessions/types/SessionsEventsResponse.d.ts +4 -4
- package/api/resources/sessions/types/index.d.ts +1 -1
- package/api/resources/sessions/types/index.js +1 -1
- package/api/resources/windows/client/Client.js +26 -26
- package/api/types/PaginatedExtractionConfig.d.ts +1 -1
- package/api/types/SessionConfigV1.d.ts +2 -0
- package/api/types/VisualAnalysisConfig.d.ts +2 -0
- package/api/types/VisualAnalysisConfigResultSelectionStrategy.d.ts +11 -0
- package/api/types/VisualAnalysisConfigResultSelectionStrategy.js +10 -0
- package/api/types/index.d.ts +1 -0
- package/api/types/index.js +1 -0
- package/dist/api/resources/profiles/client/Client.js +2 -2
- package/dist/api/resources/sessions/client/Client.d.ts +9 -0
- package/dist/api/resources/sessions/client/Client.js +65 -12
- package/dist/api/resources/sessions/types/SessionsEventsResponse.d.ts +4 -4
- package/dist/api/resources/sessions/types/index.d.ts +1 -1
- package/dist/api/resources/sessions/types/index.js +1 -1
- package/dist/api/resources/windows/client/Client.js +26 -26
- package/dist/api/types/PaginatedExtractionConfig.d.ts +1 -1
- package/dist/api/types/SessionConfigV1.d.ts +2 -0
- package/dist/api/types/VisualAnalysisConfig.d.ts +2 -0
- package/dist/api/types/VisualAnalysisConfigResultSelectionStrategy.d.ts +11 -0
- package/dist/api/types/VisualAnalysisConfigResultSelectionStrategy.js +10 -0
- package/dist/api/types/index.d.ts +1 -0
- package/dist/api/types/index.js +1 -0
- package/dist/serialization/resources/sessions/types/SessionsEventsResponse.d.ts +5 -5
- package/dist/serialization/resources/sessions/types/SessionsEventsResponse.js +2 -2
- package/dist/serialization/resources/sessions/types/index.d.ts +1 -1
- package/dist/serialization/resources/sessions/types/index.js +1 -1
- package/dist/serialization/types/SessionConfigV1.d.ts +1 -0
- package/dist/serialization/types/SessionConfigV1.js +1 -0
- package/dist/serialization/types/VisualAnalysisConfig.d.ts +2 -0
- package/dist/serialization/types/VisualAnalysisConfig.js +2 -0
- package/dist/serialization/types/VisualAnalysisConfigResultSelectionStrategy.d.ts +10 -0
- package/dist/serialization/types/VisualAnalysisConfigResultSelectionStrategy.js +31 -0
- package/dist/serialization/types/index.d.ts +1 -0
- package/dist/serialization/types/index.js +1 -0
- package/package.json +1 -1
- package/reference.md +59 -0
- package/serialization/resources/sessions/types/SessionsEventsResponse.d.ts +5 -5
- package/serialization/resources/sessions/types/SessionsEventsResponse.js +2 -2
- package/serialization/resources/sessions/types/index.d.ts +1 -1
- package/serialization/resources/sessions/types/index.js +1 -1
- package/serialization/types/SessionConfigV1.d.ts +1 -0
- package/serialization/types/SessionConfigV1.js +1 -0
- package/serialization/types/VisualAnalysisConfig.d.ts +2 -0
- package/serialization/types/VisualAnalysisConfig.js +2 -0
- package/serialization/types/VisualAnalysisConfigResultSelectionStrategy.d.ts +10 -0
- package/serialization/types/VisualAnalysisConfigResultSelectionStrategy.js +31 -0
- package/serialization/types/index.d.ts +1 -0
- package/serialization/types/index.js +1 -0
@@ -84,8 +84,8 @@ class Profiles {
|
|
84
84
|
Authorization: yield this._getAuthorizationHeader(),
|
85
85
|
"X-Fern-Language": "JavaScript",
|
86
86
|
"X-Fern-SDK-Name": "@airtop/sdk",
|
87
|
-
"X-Fern-SDK-Version": "0.1.
|
88
|
-
"User-Agent": "@airtop/sdk/0.1.
|
87
|
+
"X-Fern-SDK-Version": "0.1.16",
|
88
|
+
"User-Agent": "@airtop/sdk/0.1.16",
|
89
89
|
"X-Fern-Runtime": core.RUNTIME.type,
|
90
90
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
91
91
|
},
|
@@ -75,6 +75,15 @@ export declare class Sessions {
|
|
75
75
|
* Get a session event stream for a given session ID
|
76
76
|
*/
|
77
77
|
events(id: string, request?: Airtop.SessionsEventsRequest, requestOptions?: Sessions.RequestOptions): Promise<core.Stream<Airtop.SessionsEventsResponse>>;
|
78
|
+
/**
|
79
|
+
* @param {string} sessionId - ID of the session.
|
80
|
+
* @param {string} extensionConfigurationName - Name under which to save the extension configuration.
|
81
|
+
* @param {Sessions.RequestOptions} requestOptions - Request-specific configuration.
|
82
|
+
*
|
83
|
+
* @example
|
84
|
+
* await client.sessions.saveExtentionConfigurationOnTermination("6aac6f73-bd89-4a76-ab32-5a6c422e8b0b", "myExtensionConfiguration")
|
85
|
+
*/
|
86
|
+
saveExtentionConfigurationOnTermination(sessionId: string, extensionConfigurationName: string, requestOptions?: Sessions.RequestOptions): Promise<void>;
|
78
87
|
/**
|
79
88
|
* @param {string} sessionId - ID of the session.
|
80
89
|
* @param {string} profileName - Name under which to save the profile.
|
@@ -94,8 +94,8 @@ class Sessions {
|
|
94
94
|
Authorization: yield this._getAuthorizationHeader(),
|
95
95
|
"X-Fern-Language": "JavaScript",
|
96
96
|
"X-Fern-SDK-Name": "@airtop/sdk",
|
97
|
-
"X-Fern-SDK-Version": "0.1.
|
98
|
-
"User-Agent": "@airtop/sdk/0.1.
|
97
|
+
"X-Fern-SDK-Version": "0.1.16",
|
98
|
+
"User-Agent": "@airtop/sdk/0.1.16",
|
99
99
|
"X-Fern-Runtime": core.RUNTIME.type,
|
100
100
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
101
101
|
},
|
@@ -180,8 +180,8 @@ class Sessions {
|
|
180
180
|
Authorization: yield this._getAuthorizationHeader(),
|
181
181
|
"X-Fern-Language": "JavaScript",
|
182
182
|
"X-Fern-SDK-Name": "@airtop/sdk",
|
183
|
-
"X-Fern-SDK-Version": "0.1.
|
184
|
-
"User-Agent": "@airtop/sdk/0.1.
|
183
|
+
"X-Fern-SDK-Version": "0.1.16",
|
184
|
+
"User-Agent": "@airtop/sdk/0.1.16",
|
185
185
|
"X-Fern-Runtime": core.RUNTIME.type,
|
186
186
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
187
187
|
},
|
@@ -245,8 +245,8 @@ class Sessions {
|
|
245
245
|
Authorization: yield this._getAuthorizationHeader(),
|
246
246
|
"X-Fern-Language": "JavaScript",
|
247
247
|
"X-Fern-SDK-Name": "@airtop/sdk",
|
248
|
-
"X-Fern-SDK-Version": "0.1.
|
249
|
-
"User-Agent": "@airtop/sdk/0.1.
|
248
|
+
"X-Fern-SDK-Version": "0.1.16",
|
249
|
+
"User-Agent": "@airtop/sdk/0.1.16",
|
250
250
|
"X-Fern-Runtime": core.RUNTIME.type,
|
251
251
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
252
252
|
},
|
@@ -332,8 +332,8 @@ class Sessions {
|
|
332
332
|
Authorization: yield this._getAuthorizationHeader(),
|
333
333
|
"X-Fern-Language": "JavaScript",
|
334
334
|
"X-Fern-SDK-Name": "@airtop/sdk",
|
335
|
-
"X-Fern-SDK-Version": "0.1.
|
336
|
-
"User-Agent": "@airtop/sdk/0.1.
|
335
|
+
"X-Fern-SDK-Version": "0.1.16",
|
336
|
+
"User-Agent": "@airtop/sdk/0.1.16",
|
337
337
|
"X-Fern-Runtime": core.RUNTIME.type,
|
338
338
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
339
339
|
},
|
@@ -388,8 +388,8 @@ class Sessions {
|
|
388
388
|
Authorization: yield this._getAuthorizationHeader(),
|
389
389
|
"X-Fern-Language": "JavaScript",
|
390
390
|
"X-Fern-SDK-Name": "@airtop/sdk",
|
391
|
-
"X-Fern-SDK-Version": "0.1.
|
392
|
-
"User-Agent": "@airtop/sdk/0.1.
|
391
|
+
"X-Fern-SDK-Version": "0.1.16",
|
392
|
+
"User-Agent": "@airtop/sdk/0.1.16",
|
393
393
|
"X-Fern-Runtime": core.RUNTIME.type,
|
394
394
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
395
395
|
},
|
@@ -468,6 +468,59 @@ class Sessions {
|
|
468
468
|
}
|
469
469
|
});
|
470
470
|
}
|
471
|
+
/**
|
472
|
+
* @param {string} sessionId - ID of the session.
|
473
|
+
* @param {string} extensionConfigurationName - Name under which to save the extension configuration.
|
474
|
+
* @param {Sessions.RequestOptions} requestOptions - Request-specific configuration.
|
475
|
+
*
|
476
|
+
* @example
|
477
|
+
* await client.sessions.saveExtentionConfigurationOnTermination("6aac6f73-bd89-4a76-ab32-5a6c422e8b0b", "myExtensionConfiguration")
|
478
|
+
*/
|
479
|
+
saveExtentionConfigurationOnTermination(sessionId, extensionConfigurationName, requestOptions) {
|
480
|
+
var _a, _b;
|
481
|
+
return __awaiter(this, void 0, void 0, function* () {
|
482
|
+
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
483
|
+
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.AirtopEnvironment.Default, `sessions/${encodeURIComponent(sessionId)}/save-extention-configuration-on-termination/${encodeURIComponent(extensionConfigurationName)}`),
|
484
|
+
method: "PUT",
|
485
|
+
headers: {
|
486
|
+
Authorization: yield this._getAuthorizationHeader(),
|
487
|
+
"X-Fern-Language": "JavaScript",
|
488
|
+
"X-Fern-SDK-Name": "@airtop/sdk",
|
489
|
+
"X-Fern-SDK-Version": "0.1.16",
|
490
|
+
"User-Agent": "@airtop/sdk/0.1.16",
|
491
|
+
"X-Fern-Runtime": core.RUNTIME.type,
|
492
|
+
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
493
|
+
},
|
494
|
+
contentType: "application/json",
|
495
|
+
requestType: "json",
|
496
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
497
|
+
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
498
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
499
|
+
});
|
500
|
+
if (_response.ok) {
|
501
|
+
return;
|
502
|
+
}
|
503
|
+
if (_response.error.reason === "status-code") {
|
504
|
+
throw new errors.AirtopError({
|
505
|
+
statusCode: _response.error.statusCode,
|
506
|
+
body: _response.error.body,
|
507
|
+
});
|
508
|
+
}
|
509
|
+
switch (_response.error.reason) {
|
510
|
+
case "non-json":
|
511
|
+
throw new errors.AirtopError({
|
512
|
+
statusCode: _response.error.statusCode,
|
513
|
+
body: _response.error.rawBody,
|
514
|
+
});
|
515
|
+
case "timeout":
|
516
|
+
throw new errors.AirtopTimeoutError();
|
517
|
+
case "unknown":
|
518
|
+
throw new errors.AirtopError({
|
519
|
+
message: _response.error.errorMessage,
|
520
|
+
});
|
521
|
+
}
|
522
|
+
});
|
523
|
+
}
|
471
524
|
/**
|
472
525
|
* @param {string} sessionId - ID of the session.
|
473
526
|
* @param {string} profileName - Name under which to save the profile.
|
@@ -486,8 +539,8 @@ class Sessions {
|
|
486
539
|
Authorization: yield this._getAuthorizationHeader(),
|
487
540
|
"X-Fern-Language": "JavaScript",
|
488
541
|
"X-Fern-SDK-Name": "@airtop/sdk",
|
489
|
-
"X-Fern-SDK-Version": "0.1.
|
490
|
-
"User-Agent": "@airtop/sdk/0.1.
|
542
|
+
"X-Fern-SDK-Version": "0.1.16",
|
543
|
+
"User-Agent": "@airtop/sdk/0.1.16",
|
491
544
|
"X-Fern-Runtime": core.RUNTIME.type,
|
492
545
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
493
546
|
},
|
@@ -5,8 +5,11 @@ import * as Airtop from "../../../index";
|
|
5
5
|
/**
|
6
6
|
* Each oneOf object in the array represents one possible Server Sent Events (SSE) message, serialized as UTF-8 text according to the SSE specification.
|
7
7
|
*/
|
8
|
-
export declare type SessionsEventsResponse = Airtop.SessionsEventsResponse.
|
8
|
+
export declare type SessionsEventsResponse = Airtop.SessionsEventsResponse.SessionEvent | Airtop.SessionsEventsResponse.Status | Airtop.SessionsEventsResponse.Error_ | Airtop.SessionsEventsResponse.WindowEvent;
|
9
9
|
export declare namespace SessionsEventsResponse {
|
10
|
+
interface SessionEvent extends Airtop.SessionsEventsResponseSessionEvent {
|
11
|
+
event: "sessionEvent";
|
12
|
+
}
|
10
13
|
interface Status extends Airtop.SessionsEventsResponseStatus {
|
11
14
|
event: "status";
|
12
15
|
}
|
@@ -16,7 +19,4 @@ export declare namespace SessionsEventsResponse {
|
|
16
19
|
interface WindowEvent extends Airtop.SessionsEventsResponseWindowEvent {
|
17
20
|
event: "windowEvent";
|
18
21
|
}
|
19
|
-
interface SessionEvent extends Airtop.SessionsEventsResponseSessionEvent {
|
20
|
-
event: "sessionEvent";
|
21
|
-
}
|
22
22
|
}
|
@@ -1,6 +1,6 @@
|
|
1
1
|
export * from "./SessionsListRequestStatus";
|
2
|
+
export * from "./SessionsEventsResponseSessionEvent";
|
2
3
|
export * from "./SessionsEventsResponseStatus";
|
3
4
|
export * from "./SessionsEventsResponseError";
|
4
5
|
export * from "./SessionsEventsResponseWindowEvent";
|
5
|
-
export * from "./SessionsEventsResponseSessionEvent";
|
6
6
|
export * from "./SessionsEventsResponse";
|
@@ -15,8 +15,8 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
15
15
|
};
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
17
17
|
__exportStar(require("./SessionsListRequestStatus"), exports);
|
18
|
+
__exportStar(require("./SessionsEventsResponseSessionEvent"), exports);
|
18
19
|
__exportStar(require("./SessionsEventsResponseStatus"), exports);
|
19
20
|
__exportStar(require("./SessionsEventsResponseError"), exports);
|
20
21
|
__exportStar(require("./SessionsEventsResponseWindowEvent"), exports);
|
21
|
-
__exportStar(require("./SessionsEventsResponseSessionEvent"), exports);
|
22
22
|
__exportStar(require("./SessionsEventsResponse"), exports);
|
@@ -68,8 +68,8 @@ class Windows {
|
|
68
68
|
Authorization: yield this._getAuthorizationHeader(),
|
69
69
|
"X-Fern-Language": "JavaScript",
|
70
70
|
"X-Fern-SDK-Name": "@airtop/sdk",
|
71
|
-
"X-Fern-SDK-Version": "0.1.
|
72
|
-
"User-Agent": "@airtop/sdk/0.1.
|
71
|
+
"X-Fern-SDK-Version": "0.1.16",
|
72
|
+
"User-Agent": "@airtop/sdk/0.1.16",
|
73
73
|
"X-Fern-Runtime": core.RUNTIME.type,
|
74
74
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
75
75
|
},
|
@@ -144,8 +144,8 @@ class Windows {
|
|
144
144
|
Authorization: yield this._getAuthorizationHeader(),
|
145
145
|
"X-Fern-Language": "JavaScript",
|
146
146
|
"X-Fern-SDK-Name": "@airtop/sdk",
|
147
|
-
"X-Fern-SDK-Version": "0.1.
|
148
|
-
"User-Agent": "@airtop/sdk/0.1.
|
147
|
+
"X-Fern-SDK-Version": "0.1.16",
|
148
|
+
"User-Agent": "@airtop/sdk/0.1.16",
|
149
149
|
"X-Fern-Runtime": core.RUNTIME.type,
|
150
150
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
151
151
|
},
|
@@ -209,8 +209,8 @@ class Windows {
|
|
209
209
|
Authorization: yield this._getAuthorizationHeader(),
|
210
210
|
"X-Fern-Language": "JavaScript",
|
211
211
|
"X-Fern-SDK-Name": "@airtop/sdk",
|
212
|
-
"X-Fern-SDK-Version": "0.1.
|
213
|
-
"User-Agent": "@airtop/sdk/0.1.
|
212
|
+
"X-Fern-SDK-Version": "0.1.16",
|
213
|
+
"User-Agent": "@airtop/sdk/0.1.16",
|
214
214
|
"X-Fern-Runtime": core.RUNTIME.type,
|
215
215
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
216
216
|
},
|
@@ -271,8 +271,8 @@ class Windows {
|
|
271
271
|
Authorization: yield this._getAuthorizationHeader(),
|
272
272
|
"X-Fern-Language": "JavaScript",
|
273
273
|
"X-Fern-SDK-Name": "@airtop/sdk",
|
274
|
-
"X-Fern-SDK-Version": "0.1.
|
275
|
-
"User-Agent": "@airtop/sdk/0.1.
|
274
|
+
"X-Fern-SDK-Version": "0.1.16",
|
275
|
+
"User-Agent": "@airtop/sdk/0.1.16",
|
276
276
|
"X-Fern-Runtime": core.RUNTIME.type,
|
277
277
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
278
278
|
},
|
@@ -335,8 +335,8 @@ class Windows {
|
|
335
335
|
Authorization: yield this._getAuthorizationHeader(),
|
336
336
|
"X-Fern-Language": "JavaScript",
|
337
337
|
"X-Fern-SDK-Name": "@airtop/sdk",
|
338
|
-
"X-Fern-SDK-Version": "0.1.
|
339
|
-
"User-Agent": "@airtop/sdk/0.1.
|
338
|
+
"X-Fern-SDK-Version": "0.1.16",
|
339
|
+
"User-Agent": "@airtop/sdk/0.1.16",
|
340
340
|
"X-Fern-Runtime": core.RUNTIME.type,
|
341
341
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
342
342
|
},
|
@@ -398,8 +398,8 @@ class Windows {
|
|
398
398
|
Authorization: yield this._getAuthorizationHeader(),
|
399
399
|
"X-Fern-Language": "JavaScript",
|
400
400
|
"X-Fern-SDK-Name": "@airtop/sdk",
|
401
|
-
"X-Fern-SDK-Version": "0.1.
|
402
|
-
"User-Agent": "@airtop/sdk/0.1.
|
401
|
+
"X-Fern-SDK-Version": "0.1.16",
|
402
|
+
"User-Agent": "@airtop/sdk/0.1.16",
|
403
403
|
"X-Fern-Runtime": core.RUNTIME.type,
|
404
404
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
405
405
|
},
|
@@ -463,8 +463,8 @@ class Windows {
|
|
463
463
|
Authorization: yield this._getAuthorizationHeader(),
|
464
464
|
"X-Fern-Language": "JavaScript",
|
465
465
|
"X-Fern-SDK-Name": "@airtop/sdk",
|
466
|
-
"X-Fern-SDK-Version": "0.1.
|
467
|
-
"User-Agent": "@airtop/sdk/0.1.
|
466
|
+
"X-Fern-SDK-Version": "0.1.16",
|
467
|
+
"User-Agent": "@airtop/sdk/0.1.16",
|
468
468
|
"X-Fern-Runtime": core.RUNTIME.type,
|
469
469
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
470
470
|
},
|
@@ -528,8 +528,8 @@ class Windows {
|
|
528
528
|
Authorization: yield this._getAuthorizationHeader(),
|
529
529
|
"X-Fern-Language": "JavaScript",
|
530
530
|
"X-Fern-SDK-Name": "@airtop/sdk",
|
531
|
-
"X-Fern-SDK-Version": "0.1.
|
532
|
-
"User-Agent": "@airtop/sdk/0.1.
|
531
|
+
"X-Fern-SDK-Version": "0.1.16",
|
532
|
+
"User-Agent": "@airtop/sdk/0.1.16",
|
533
533
|
"X-Fern-Runtime": core.RUNTIME.type,
|
534
534
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
535
535
|
},
|
@@ -595,8 +595,8 @@ class Windows {
|
|
595
595
|
Authorization: yield this._getAuthorizationHeader(),
|
596
596
|
"X-Fern-Language": "JavaScript",
|
597
597
|
"X-Fern-SDK-Name": "@airtop/sdk",
|
598
|
-
"X-Fern-SDK-Version": "0.1.
|
599
|
-
"User-Agent": "@airtop/sdk/0.1.
|
598
|
+
"X-Fern-SDK-Version": "0.1.16",
|
599
|
+
"User-Agent": "@airtop/sdk/0.1.16",
|
600
600
|
"X-Fern-Runtime": core.RUNTIME.type,
|
601
601
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
602
602
|
},
|
@@ -660,8 +660,8 @@ class Windows {
|
|
660
660
|
Authorization: yield this._getAuthorizationHeader(),
|
661
661
|
"X-Fern-Language": "JavaScript",
|
662
662
|
"X-Fern-SDK-Name": "@airtop/sdk",
|
663
|
-
"X-Fern-SDK-Version": "0.1.
|
664
|
-
"User-Agent": "@airtop/sdk/0.1.
|
663
|
+
"X-Fern-SDK-Version": "0.1.16",
|
664
|
+
"User-Agent": "@airtop/sdk/0.1.16",
|
665
665
|
"X-Fern-Runtime": core.RUNTIME.type,
|
666
666
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
667
667
|
},
|
@@ -723,8 +723,8 @@ class Windows {
|
|
723
723
|
Authorization: yield this._getAuthorizationHeader(),
|
724
724
|
"X-Fern-Language": "JavaScript",
|
725
725
|
"X-Fern-SDK-Name": "@airtop/sdk",
|
726
|
-
"X-Fern-SDK-Version": "0.1.
|
727
|
-
"User-Agent": "@airtop/sdk/0.1.
|
726
|
+
"X-Fern-SDK-Version": "0.1.16",
|
727
|
+
"User-Agent": "@airtop/sdk/0.1.16",
|
728
728
|
"X-Fern-Runtime": core.RUNTIME.type,
|
729
729
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
730
730
|
},
|
@@ -788,8 +788,8 @@ class Windows {
|
|
788
788
|
Authorization: yield this._getAuthorizationHeader(),
|
789
789
|
"X-Fern-Language": "JavaScript",
|
790
790
|
"X-Fern-SDK-Name": "@airtop/sdk",
|
791
|
-
"X-Fern-SDK-Version": "0.1.
|
792
|
-
"User-Agent": "@airtop/sdk/0.1.
|
791
|
+
"X-Fern-SDK-Version": "0.1.16",
|
792
|
+
"User-Agent": "@airtop/sdk/0.1.16",
|
793
793
|
"X-Fern-Runtime": core.RUNTIME.type,
|
794
794
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
795
795
|
},
|
@@ -855,8 +855,8 @@ class Windows {
|
|
855
855
|
Authorization: yield this._getAuthorizationHeader(),
|
856
856
|
"X-Fern-Language": "JavaScript",
|
857
857
|
"X-Fern-SDK-Name": "@airtop/sdk",
|
858
|
-
"X-Fern-SDK-Version": "0.1.
|
859
|
-
"User-Agent": "@airtop/sdk/0.1.
|
858
|
+
"X-Fern-SDK-Version": "0.1.16",
|
859
|
+
"User-Agent": "@airtop/sdk/0.1.16",
|
860
860
|
"X-Fern-Runtime": core.RUNTIME.type,
|
861
861
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
862
862
|
},
|
@@ -2,7 +2,7 @@
|
|
2
2
|
* This file was auto-generated by Fern from our API Definition.
|
3
3
|
*/
|
4
4
|
export interface PaginatedExtractionConfig {
|
5
|
-
/** The mode to use for interaction. If set to 'auto', Airtop AI will automatically choose the most cost-effective interaction mode. If set to 'accurate',
|
5
|
+
/** The mode to use for interaction. If set to 'auto', Airtop AI will automatically choose the most cost-effective interaction mode. If set to 'accurate', the request might be slower, but more likely to be accurate. Whereas, 'cost-efficient' will be cheaper and speed things up, but may reduce accuracy. */
|
6
6
|
interactionMode?: string;
|
7
7
|
/** JSON schema defining the structure of the output. If not provided, the format of the output might vary. */
|
8
8
|
outputSchema?: string;
|
@@ -6,6 +6,8 @@ export interface SessionConfigV1 {
|
|
6
6
|
/** Deprecated: Use profileName instead. */
|
7
7
|
baseProfileId?: string;
|
8
8
|
/** - */
|
9
|
+
extensionConfigurationName?: string;
|
10
|
+
/** - */
|
9
11
|
extensionIds?: string[];
|
10
12
|
/** Deprecated: use Save Profile On Termination API instead. */
|
11
13
|
persistProfile?: boolean;
|
@@ -9,6 +9,8 @@ export interface VisualAnalysisConfig {
|
|
9
9
|
overlapPercentage?: number;
|
10
10
|
/** The direction to partition the screenshot into chunks: 'vertical', 'horizontal', or 'bidirectional'. Defaults to 'vertical', which is recommended for most web pages. For optimal results when partitioning in a single direction, ensure the perpendicular dimension does not exceed 1920 pixels. */
|
11
11
|
partitionDirection?: Airtop.VisualAnalysisConfigPartitionDirection;
|
12
|
+
/** [Experimental] The strategy to use for selecting the match using visual analysis. Can be 'first' or bestMatch'. Defaults to 'first'. Use 'first' to select the first visual element that matches the element description. This will favor results that appear higher on the page in the event of multiple matches. Use 'bestMatch' to perform a second round of analysis to select the result that best matches the element description. */
|
13
|
+
resultSelectionStrategy?: Airtop.VisualAnalysisConfigResultSelectionStrategy;
|
12
14
|
/** Scan mode only: The delay between scrolls in milliseconds. Defaults to 1000 (milliseconds). */
|
13
15
|
scanScrollDelay?: number;
|
14
16
|
/** Whether to analyze the current viewport or the whole page. Can be 'viewport', 'page', 'scan' or 'auto'. Defaults to 'auto', which provides the simplest out-of-the-box experience for most web pages. Use 'viewport' for analysis of the current browser view only. Use 'page' for a full page analysis. Use 'scan' for a full page analysis on sites that have compatibility or accuracy issues with 'page' mode. */
|
@@ -0,0 +1,11 @@
|
|
1
|
+
/**
|
2
|
+
* This file was auto-generated by Fern from our API Definition.
|
3
|
+
*/
|
4
|
+
/**
|
5
|
+
* [Experimental] The strategy to use for selecting the match using visual analysis. Can be 'first' or bestMatch'. Defaults to 'first'. Use 'first' to select the first visual element that matches the element description. This will favor results that appear higher on the page in the event of multiple matches. Use 'bestMatch' to perform a second round of analysis to select the result that best matches the element description.
|
6
|
+
*/
|
7
|
+
export declare type VisualAnalysisConfigResultSelectionStrategy = "first" | "bestMatch";
|
8
|
+
export declare const VisualAnalysisConfigResultSelectionStrategy: {
|
9
|
+
readonly First: "first";
|
10
|
+
readonly BestMatch: "bestMatch";
|
11
|
+
};
|
@@ -0,0 +1,10 @@
|
|
1
|
+
"use strict";
|
2
|
+
/**
|
3
|
+
* This file was auto-generated by Fern from our API Definition.
|
4
|
+
*/
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
6
|
+
exports.VisualAnalysisConfigResultSelectionStrategy = void 0;
|
7
|
+
exports.VisualAnalysisConfigResultSelectionStrategy = {
|
8
|
+
First: "first",
|
9
|
+
BestMatch: "bestMatch",
|
10
|
+
};
|
package/api/types/index.d.ts
CHANGED
@@ -45,6 +45,7 @@ export * from "./StatusMessage";
|
|
45
45
|
export * from "./SummaryConfig";
|
46
46
|
export * from "./SummaryExperimentalConfig";
|
47
47
|
export * from "./VisualAnalysisConfigPartitionDirection";
|
48
|
+
export * from "./VisualAnalysisConfigResultSelectionStrategy";
|
48
49
|
export * from "./VisualAnalysisConfigScope";
|
49
50
|
export * from "./VisualAnalysisConfig";
|
50
51
|
export * from "./Window";
|
package/api/types/index.js
CHANGED
@@ -61,6 +61,7 @@ __exportStar(require("./StatusMessage"), exports);
|
|
61
61
|
__exportStar(require("./SummaryConfig"), exports);
|
62
62
|
__exportStar(require("./SummaryExperimentalConfig"), exports);
|
63
63
|
__exportStar(require("./VisualAnalysisConfigPartitionDirection"), exports);
|
64
|
+
__exportStar(require("./VisualAnalysisConfigResultSelectionStrategy"), exports);
|
64
65
|
__exportStar(require("./VisualAnalysisConfigScope"), exports);
|
65
66
|
__exportStar(require("./VisualAnalysisConfig"), exports);
|
66
67
|
__exportStar(require("./Window"), exports);
|
@@ -84,8 +84,8 @@ class Profiles {
|
|
84
84
|
Authorization: yield this._getAuthorizationHeader(),
|
85
85
|
"X-Fern-Language": "JavaScript",
|
86
86
|
"X-Fern-SDK-Name": "@airtop/sdk",
|
87
|
-
"X-Fern-SDK-Version": "0.1.
|
88
|
-
"User-Agent": "@airtop/sdk/0.1.
|
87
|
+
"X-Fern-SDK-Version": "0.1.16",
|
88
|
+
"User-Agent": "@airtop/sdk/0.1.16",
|
89
89
|
"X-Fern-Runtime": core.RUNTIME.type,
|
90
90
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
91
91
|
},
|
@@ -75,6 +75,15 @@ export declare class Sessions {
|
|
75
75
|
* Get a session event stream for a given session ID
|
76
76
|
*/
|
77
77
|
events(id: string, request?: Airtop.SessionsEventsRequest, requestOptions?: Sessions.RequestOptions): Promise<core.Stream<Airtop.SessionsEventsResponse>>;
|
78
|
+
/**
|
79
|
+
* @param {string} sessionId - ID of the session.
|
80
|
+
* @param {string} extensionConfigurationName - Name under which to save the extension configuration.
|
81
|
+
* @param {Sessions.RequestOptions} requestOptions - Request-specific configuration.
|
82
|
+
*
|
83
|
+
* @example
|
84
|
+
* await client.sessions.saveExtentionConfigurationOnTermination("6aac6f73-bd89-4a76-ab32-5a6c422e8b0b", "myExtensionConfiguration")
|
85
|
+
*/
|
86
|
+
saveExtentionConfigurationOnTermination(sessionId: string, extensionConfigurationName: string, requestOptions?: Sessions.RequestOptions): Promise<void>;
|
78
87
|
/**
|
79
88
|
* @param {string} sessionId - ID of the session.
|
80
89
|
* @param {string} profileName - Name under which to save the profile.
|
@@ -94,8 +94,8 @@ class Sessions {
|
|
94
94
|
Authorization: yield this._getAuthorizationHeader(),
|
95
95
|
"X-Fern-Language": "JavaScript",
|
96
96
|
"X-Fern-SDK-Name": "@airtop/sdk",
|
97
|
-
"X-Fern-SDK-Version": "0.1.
|
98
|
-
"User-Agent": "@airtop/sdk/0.1.
|
97
|
+
"X-Fern-SDK-Version": "0.1.16",
|
98
|
+
"User-Agent": "@airtop/sdk/0.1.16",
|
99
99
|
"X-Fern-Runtime": core.RUNTIME.type,
|
100
100
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
101
101
|
},
|
@@ -180,8 +180,8 @@ class Sessions {
|
|
180
180
|
Authorization: yield this._getAuthorizationHeader(),
|
181
181
|
"X-Fern-Language": "JavaScript",
|
182
182
|
"X-Fern-SDK-Name": "@airtop/sdk",
|
183
|
-
"X-Fern-SDK-Version": "0.1.
|
184
|
-
"User-Agent": "@airtop/sdk/0.1.
|
183
|
+
"X-Fern-SDK-Version": "0.1.16",
|
184
|
+
"User-Agent": "@airtop/sdk/0.1.16",
|
185
185
|
"X-Fern-Runtime": core.RUNTIME.type,
|
186
186
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
187
187
|
},
|
@@ -245,8 +245,8 @@ class Sessions {
|
|
245
245
|
Authorization: yield this._getAuthorizationHeader(),
|
246
246
|
"X-Fern-Language": "JavaScript",
|
247
247
|
"X-Fern-SDK-Name": "@airtop/sdk",
|
248
|
-
"X-Fern-SDK-Version": "0.1.
|
249
|
-
"User-Agent": "@airtop/sdk/0.1.
|
248
|
+
"X-Fern-SDK-Version": "0.1.16",
|
249
|
+
"User-Agent": "@airtop/sdk/0.1.16",
|
250
250
|
"X-Fern-Runtime": core.RUNTIME.type,
|
251
251
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
252
252
|
},
|
@@ -332,8 +332,8 @@ class Sessions {
|
|
332
332
|
Authorization: yield this._getAuthorizationHeader(),
|
333
333
|
"X-Fern-Language": "JavaScript",
|
334
334
|
"X-Fern-SDK-Name": "@airtop/sdk",
|
335
|
-
"X-Fern-SDK-Version": "0.1.
|
336
|
-
"User-Agent": "@airtop/sdk/0.1.
|
335
|
+
"X-Fern-SDK-Version": "0.1.16",
|
336
|
+
"User-Agent": "@airtop/sdk/0.1.16",
|
337
337
|
"X-Fern-Runtime": core.RUNTIME.type,
|
338
338
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
339
339
|
},
|
@@ -388,8 +388,8 @@ class Sessions {
|
|
388
388
|
Authorization: yield this._getAuthorizationHeader(),
|
389
389
|
"X-Fern-Language": "JavaScript",
|
390
390
|
"X-Fern-SDK-Name": "@airtop/sdk",
|
391
|
-
"X-Fern-SDK-Version": "0.1.
|
392
|
-
"User-Agent": "@airtop/sdk/0.1.
|
391
|
+
"X-Fern-SDK-Version": "0.1.16",
|
392
|
+
"User-Agent": "@airtop/sdk/0.1.16",
|
393
393
|
"X-Fern-Runtime": core.RUNTIME.type,
|
394
394
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
395
395
|
},
|
@@ -468,6 +468,59 @@ class Sessions {
|
|
468
468
|
}
|
469
469
|
});
|
470
470
|
}
|
471
|
+
/**
|
472
|
+
* @param {string} sessionId - ID of the session.
|
473
|
+
* @param {string} extensionConfigurationName - Name under which to save the extension configuration.
|
474
|
+
* @param {Sessions.RequestOptions} requestOptions - Request-specific configuration.
|
475
|
+
*
|
476
|
+
* @example
|
477
|
+
* await client.sessions.saveExtentionConfigurationOnTermination("6aac6f73-bd89-4a76-ab32-5a6c422e8b0b", "myExtensionConfiguration")
|
478
|
+
*/
|
479
|
+
saveExtentionConfigurationOnTermination(sessionId, extensionConfigurationName, requestOptions) {
|
480
|
+
var _a, _b;
|
481
|
+
return __awaiter(this, void 0, void 0, function* () {
|
482
|
+
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
483
|
+
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.AirtopEnvironment.Default, `sessions/${encodeURIComponent(sessionId)}/save-extention-configuration-on-termination/${encodeURIComponent(extensionConfigurationName)}`),
|
484
|
+
method: "PUT",
|
485
|
+
headers: {
|
486
|
+
Authorization: yield this._getAuthorizationHeader(),
|
487
|
+
"X-Fern-Language": "JavaScript",
|
488
|
+
"X-Fern-SDK-Name": "@airtop/sdk",
|
489
|
+
"X-Fern-SDK-Version": "0.1.16",
|
490
|
+
"User-Agent": "@airtop/sdk/0.1.16",
|
491
|
+
"X-Fern-Runtime": core.RUNTIME.type,
|
492
|
+
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
493
|
+
},
|
494
|
+
contentType: "application/json",
|
495
|
+
requestType: "json",
|
496
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
497
|
+
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
498
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
499
|
+
});
|
500
|
+
if (_response.ok) {
|
501
|
+
return;
|
502
|
+
}
|
503
|
+
if (_response.error.reason === "status-code") {
|
504
|
+
throw new errors.AirtopError({
|
505
|
+
statusCode: _response.error.statusCode,
|
506
|
+
body: _response.error.body,
|
507
|
+
});
|
508
|
+
}
|
509
|
+
switch (_response.error.reason) {
|
510
|
+
case "non-json":
|
511
|
+
throw new errors.AirtopError({
|
512
|
+
statusCode: _response.error.statusCode,
|
513
|
+
body: _response.error.rawBody,
|
514
|
+
});
|
515
|
+
case "timeout":
|
516
|
+
throw new errors.AirtopTimeoutError();
|
517
|
+
case "unknown":
|
518
|
+
throw new errors.AirtopError({
|
519
|
+
message: _response.error.errorMessage,
|
520
|
+
});
|
521
|
+
}
|
522
|
+
});
|
523
|
+
}
|
471
524
|
/**
|
472
525
|
* @param {string} sessionId - ID of the session.
|
473
526
|
* @param {string} profileName - Name under which to save the profile.
|
@@ -486,8 +539,8 @@ class Sessions {
|
|
486
539
|
Authorization: yield this._getAuthorizationHeader(),
|
487
540
|
"X-Fern-Language": "JavaScript",
|
488
541
|
"X-Fern-SDK-Name": "@airtop/sdk",
|
489
|
-
"X-Fern-SDK-Version": "0.1.
|
490
|
-
"User-Agent": "@airtop/sdk/0.1.
|
542
|
+
"X-Fern-SDK-Version": "0.1.16",
|
543
|
+
"User-Agent": "@airtop/sdk/0.1.16",
|
491
544
|
"X-Fern-Runtime": core.RUNTIME.type,
|
492
545
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
493
546
|
},
|
@@ -5,8 +5,11 @@ import * as Airtop from "../../../index";
|
|
5
5
|
/**
|
6
6
|
* Each oneOf object in the array represents one possible Server Sent Events (SSE) message, serialized as UTF-8 text according to the SSE specification.
|
7
7
|
*/
|
8
|
-
export declare type SessionsEventsResponse = Airtop.SessionsEventsResponse.
|
8
|
+
export declare type SessionsEventsResponse = Airtop.SessionsEventsResponse.SessionEvent | Airtop.SessionsEventsResponse.Status | Airtop.SessionsEventsResponse.Error_ | Airtop.SessionsEventsResponse.WindowEvent;
|
9
9
|
export declare namespace SessionsEventsResponse {
|
10
|
+
interface SessionEvent extends Airtop.SessionsEventsResponseSessionEvent {
|
11
|
+
event: "sessionEvent";
|
12
|
+
}
|
10
13
|
interface Status extends Airtop.SessionsEventsResponseStatus {
|
11
14
|
event: "status";
|
12
15
|
}
|
@@ -16,7 +19,4 @@ export declare namespace SessionsEventsResponse {
|
|
16
19
|
interface WindowEvent extends Airtop.SessionsEventsResponseWindowEvent {
|
17
20
|
event: "windowEvent";
|
18
21
|
}
|
19
|
-
interface SessionEvent extends Airtop.SessionsEventsResponseSessionEvent {
|
20
|
-
event: "sessionEvent";
|
21
|
-
}
|
22
22
|
}
|
@@ -1,6 +1,6 @@
|
|
1
1
|
export * from "./SessionsListRequestStatus";
|
2
|
+
export * from "./SessionsEventsResponseSessionEvent";
|
2
3
|
export * from "./SessionsEventsResponseStatus";
|
3
4
|
export * from "./SessionsEventsResponseError";
|
4
5
|
export * from "./SessionsEventsResponseWindowEvent";
|
5
|
-
export * from "./SessionsEventsResponseSessionEvent";
|
6
6
|
export * from "./SessionsEventsResponse";
|
@@ -15,8 +15,8 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
15
15
|
};
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
17
17
|
__exportStar(require("./SessionsListRequestStatus"), exports);
|
18
|
+
__exportStar(require("./SessionsEventsResponseSessionEvent"), exports);
|
18
19
|
__exportStar(require("./SessionsEventsResponseStatus"), exports);
|
19
20
|
__exportStar(require("./SessionsEventsResponseError"), exports);
|
20
21
|
__exportStar(require("./SessionsEventsResponseWindowEvent"), exports);
|
21
|
-
__exportStar(require("./SessionsEventsResponseSessionEvent"), exports);
|
22
22
|
__exportStar(require("./SessionsEventsResponse"), exports);
|