@airtop/sdk 0.1.36-beta0 → 0.1.37-beta0
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/automations/client/Client.js +4 -4
- package/api/resources/files/client/Client.js +4 -4
- package/api/resources/files/client/requests/CreateFileRestInputV1.d.ts +0 -2
- package/api/resources/profiles/client/Client.js +1 -1
- package/api/resources/requests/client/Client.js +1 -1
- package/api/resources/sessions/client/Client.js +6 -6
- package/api/resources/sessions/types/SessionsEventsResponse.d.ts +4 -1
- package/api/resources/sessions/types/SessionsEventsResponseFileEvent.d.ts +11 -0
- package/api/resources/sessions/types/SessionsEventsResponseFileEvent.js +5 -0
- package/api/resources/sessions/types/index.d.ts +1 -0
- package/api/resources/sessions/types/index.js +1 -0
- package/api/resources/windows/client/Client.d.ts +14 -0
- package/api/resources/windows/client/Client.js +87 -30
- package/api/resources/windows/client/requests/OperatorPromptV1Body.d.ts +25 -0
- package/api/resources/windows/client/requests/OperatorPromptV1Body.js +5 -0
- package/api/resources/windows/client/requests/index.d.ts +1 -0
- package/api/types/AsyncOperatorPromptResponseEnvelope.d.ts +9 -0
- package/api/types/AsyncOperatorPromptResponseEnvelope.js +5 -0
- package/api/types/CreateFileV1.d.ts +2 -2
- package/api/types/CreateFileV1Status.d.ts +13 -0
- package/api/types/CreateFileV1Status.js +12 -0
- package/api/types/ExternalFile.d.ts +2 -0
- package/api/types/FileEventMessage.d.ts +14 -0
- package/api/types/FileEventMessage.js +5 -0
- package/api/types/FileEventMessageStatus.d.ts +13 -0
- package/api/types/FileEventMessageStatus.js +12 -0
- package/api/types/GetFileV1.d.ts +4 -2
- package/api/types/GetFileV1Status.d.ts +13 -0
- package/api/types/GetFileV1Status.js +12 -0
- package/api/types/index.d.ts +5 -0
- package/api/types/index.js +5 -0
- package/dist/api/resources/automations/client/Client.js +4 -4
- package/dist/api/resources/files/client/Client.js +4 -4
- package/dist/api/resources/files/client/requests/CreateFileRestInputV1.d.ts +0 -2
- package/dist/api/resources/profiles/client/Client.js +1 -1
- package/dist/api/resources/requests/client/Client.js +1 -1
- package/dist/api/resources/sessions/client/Client.js +6 -6
- package/dist/api/resources/sessions/types/SessionsEventsResponse.d.ts +4 -1
- package/dist/api/resources/sessions/types/SessionsEventsResponseFileEvent.d.ts +11 -0
- package/dist/api/resources/sessions/types/SessionsEventsResponseFileEvent.js +5 -0
- package/dist/api/resources/sessions/types/index.d.ts +1 -0
- package/dist/api/resources/sessions/types/index.js +1 -0
- package/dist/api/resources/windows/client/Client.d.ts +14 -0
- package/dist/api/resources/windows/client/Client.js +87 -30
- package/dist/api/resources/windows/client/requests/OperatorPromptV1Body.d.ts +25 -0
- package/dist/api/resources/windows/client/requests/OperatorPromptV1Body.js +5 -0
- package/dist/api/resources/windows/client/requests/index.d.ts +1 -0
- package/dist/api/types/AsyncOperatorPromptResponseEnvelope.d.ts +9 -0
- package/dist/api/types/AsyncOperatorPromptResponseEnvelope.js +5 -0
- package/dist/api/types/CreateFileV1.d.ts +2 -2
- package/dist/api/types/CreateFileV1Status.d.ts +13 -0
- package/dist/api/types/CreateFileV1Status.js +12 -0
- package/dist/api/types/ExternalFile.d.ts +2 -0
- package/dist/api/types/FileEventMessage.d.ts +14 -0
- package/dist/api/types/FileEventMessage.js +5 -0
- package/dist/api/types/FileEventMessageStatus.d.ts +13 -0
- package/dist/api/types/FileEventMessageStatus.js +12 -0
- package/dist/api/types/GetFileV1.d.ts +4 -2
- package/dist/api/types/GetFileV1Status.d.ts +13 -0
- package/dist/api/types/GetFileV1Status.js +12 -0
- package/dist/api/types/index.d.ts +5 -0
- package/dist/api/types/index.js +5 -0
- package/dist/serialization/resources/files/client/requests/CreateFileRestInputV1.d.ts +0 -1
- package/dist/serialization/resources/files/client/requests/CreateFileRestInputV1.js +0 -1
- package/dist/serialization/resources/sessions/types/SessionsEventsResponse.d.ts +5 -1
- package/dist/serialization/resources/sessions/types/SessionsEventsResponse.js +2 -0
- package/dist/serialization/resources/sessions/types/SessionsEventsResponseFileEvent.d.ts +15 -0
- package/dist/serialization/resources/sessions/types/SessionsEventsResponseFileEvent.js +46 -0
- package/dist/serialization/resources/sessions/types/index.d.ts +1 -0
- package/dist/serialization/resources/sessions/types/index.js +1 -0
- package/dist/serialization/resources/windows/client/requests/OperatorPromptV1Body.d.ts +17 -0
- package/dist/serialization/resources/windows/client/requests/OperatorPromptV1Body.js +48 -0
- package/dist/serialization/resources/windows/client/requests/index.d.ts +1 -0
- package/dist/serialization/resources/windows/client/requests/index.js +3 -1
- package/dist/serialization/types/AsyncOperatorPromptResponseEnvelope.d.ts +15 -0
- package/dist/serialization/types/AsyncOperatorPromptResponseEnvelope.js +46 -0
- package/dist/serialization/types/CreateFileV1.d.ts +2 -1
- package/dist/serialization/types/CreateFileV1.js +2 -1
- package/dist/serialization/types/CreateFileV1Status.d.ts +10 -0
- package/dist/serialization/types/CreateFileV1Status.js +41 -0
- package/dist/serialization/types/ExternalFile.d.ts +1 -0
- package/dist/serialization/types/ExternalFile.js +1 -0
- package/dist/serialization/types/FileEventMessage.d.ts +16 -0
- package/dist/serialization/types/FileEventMessage.js +47 -0
- package/dist/serialization/types/FileEventMessageStatus.d.ts +10 -0
- package/dist/serialization/types/FileEventMessageStatus.js +41 -0
- package/dist/serialization/types/GetFileV1.d.ts +3 -1
- package/dist/serialization/types/GetFileV1.js +3 -1
- package/dist/serialization/types/GetFileV1Status.d.ts +10 -0
- package/dist/serialization/types/GetFileV1Status.js +41 -0
- package/dist/serialization/types/index.d.ts +5 -0
- package/dist/serialization/types/index.js +5 -0
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/dist/wrapper/AirtopFiles.d.ts +12 -0
- package/dist/wrapper/AirtopFiles.js +31 -2
- package/dist/wrapper/AirtopRequests.js +1 -1
- package/dist/wrapper/AirtopSessions.d.ts +39 -0
- package/dist/wrapper/AirtopSessions.js +219 -17
- package/dist/wrapper/AirtopWindows.d.ts +26 -0
- package/dist/wrapper/AirtopWindows.js +40 -0
- package/package.json +1 -1
- package/reference.md +81 -0
- package/serialization/resources/files/client/requests/CreateFileRestInputV1.d.ts +0 -1
- package/serialization/resources/files/client/requests/CreateFileRestInputV1.js +0 -1
- package/serialization/resources/sessions/types/SessionsEventsResponse.d.ts +5 -1
- package/serialization/resources/sessions/types/SessionsEventsResponse.js +2 -0
- package/serialization/resources/sessions/types/SessionsEventsResponseFileEvent.d.ts +15 -0
- package/serialization/resources/sessions/types/SessionsEventsResponseFileEvent.js +46 -0
- package/serialization/resources/sessions/types/index.d.ts +1 -0
- package/serialization/resources/sessions/types/index.js +1 -0
- package/serialization/resources/windows/client/requests/OperatorPromptV1Body.d.ts +17 -0
- package/serialization/resources/windows/client/requests/OperatorPromptV1Body.js +48 -0
- package/serialization/resources/windows/client/requests/index.d.ts +1 -0
- package/serialization/resources/windows/client/requests/index.js +3 -1
- package/serialization/types/AsyncOperatorPromptResponseEnvelope.d.ts +15 -0
- package/serialization/types/AsyncOperatorPromptResponseEnvelope.js +46 -0
- package/serialization/types/CreateFileV1.d.ts +2 -1
- package/serialization/types/CreateFileV1.js +2 -1
- package/serialization/types/CreateFileV1Status.d.ts +10 -0
- package/serialization/types/CreateFileV1Status.js +41 -0
- package/serialization/types/ExternalFile.d.ts +1 -0
- package/serialization/types/ExternalFile.js +1 -0
- package/serialization/types/FileEventMessage.d.ts +16 -0
- package/serialization/types/FileEventMessage.js +47 -0
- package/serialization/types/FileEventMessageStatus.d.ts +10 -0
- package/serialization/types/FileEventMessageStatus.js +41 -0
- package/serialization/types/GetFileV1.d.ts +3 -1
- package/serialization/types/GetFileV1.js +3 -1
- package/serialization/types/GetFileV1Status.d.ts +10 -0
- package/serialization/types/GetFileV1Status.js +41 -0
- package/serialization/types/index.d.ts +5 -0
- package/serialization/types/index.js +5 -0
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/wrapper/AirtopFiles.d.ts +12 -0
- package/wrapper/AirtopFiles.js +31 -2
- package/wrapper/AirtopRequests.js +1 -1
- package/wrapper/AirtopSessions.d.ts +39 -0
- package/wrapper/AirtopSessions.js +219 -17
- package/wrapper/AirtopWindows.d.ts +26 -0
- package/wrapper/AirtopWindows.js +40 -0
@@ -77,7 +77,7 @@ class Windows {
|
|
77
77
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
78
78
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AirtopEnvironment.Default, `async/sessions/${encodeURIComponent(sessionId)}/windows/${encodeURIComponent(windowId)}/click`),
|
79
79
|
method: "POST",
|
80
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.
|
80
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.37-beta0", "User-Agent": "@airtop/sdk/0.1.37-beta0", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
81
81
|
contentType: "application/json",
|
82
82
|
requestType: "json",
|
83
83
|
body: serializers.AsyncClickRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
@@ -132,7 +132,7 @@ class Windows {
|
|
132
132
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
133
133
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AirtopEnvironment.Default, `async/sessions/${encodeURIComponent(sessionId)}/windows/${encodeURIComponent(windowId)}/create-automation`),
|
134
134
|
method: "POST",
|
135
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.
|
135
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.37-beta0", "User-Agent": "@airtop/sdk/0.1.37-beta0", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
136
136
|
contentType: "application/json",
|
137
137
|
requestType: "json",
|
138
138
|
body: serializers.AsyncCreateAutomationRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
@@ -187,7 +187,7 @@ class Windows {
|
|
187
187
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
188
188
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AirtopEnvironment.Default, `async/sessions/${encodeURIComponent(sessionId)}/windows/${encodeURIComponent(windowId)}/create-form-filler`),
|
189
189
|
method: "POST",
|
190
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.
|
190
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.37-beta0", "User-Agent": "@airtop/sdk/0.1.37-beta0", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
191
191
|
contentType: "application/json",
|
192
192
|
requestType: "json",
|
193
193
|
body: serializers.AsyncCreateFormFillerRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
@@ -244,7 +244,7 @@ class Windows {
|
|
244
244
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
245
245
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AirtopEnvironment.Default, `async/sessions/${encodeURIComponent(sessionId)}/windows/${encodeURIComponent(windowId)}/execute-automation`),
|
246
246
|
method: "POST",
|
247
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.
|
247
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.37-beta0", "User-Agent": "@airtop/sdk/0.1.37-beta0", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
248
248
|
contentType: "application/json",
|
249
249
|
requestType: "json",
|
250
250
|
body: serializers.AsyncExecuteAutomationRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
@@ -301,7 +301,7 @@ class Windows {
|
|
301
301
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
302
302
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AirtopEnvironment.Default, `async/sessions/${encodeURIComponent(sessionId)}/windows/${encodeURIComponent(windowId)}/fill-form`),
|
303
303
|
method: "POST",
|
304
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.
|
304
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.37-beta0", "User-Agent": "@airtop/sdk/0.1.37-beta0", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
305
305
|
contentType: "application/json",
|
306
306
|
requestType: "json",
|
307
307
|
body: serializers.AsyncFillFormRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
@@ -356,7 +356,7 @@ class Windows {
|
|
356
356
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
357
357
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AirtopEnvironment.Default, `async/sessions/${encodeURIComponent(sessionId)}/windows/${encodeURIComponent(windowId)}/hover`),
|
358
358
|
method: "POST",
|
359
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.
|
359
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.37-beta0", "User-Agent": "@airtop/sdk/0.1.37-beta0", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
360
360
|
contentType: "application/json",
|
361
361
|
requestType: "json",
|
362
362
|
body: serializers.AsyncHoverRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
@@ -411,7 +411,7 @@ class Windows {
|
|
411
411
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
412
412
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AirtopEnvironment.Default, `async/sessions/${encodeURIComponent(sessionId)}/windows/${encodeURIComponent(windowId)}/monitor`),
|
413
413
|
method: "POST",
|
414
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.
|
414
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.37-beta0", "User-Agent": "@airtop/sdk/0.1.37-beta0", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
415
415
|
contentType: "application/json",
|
416
416
|
requestType: "json",
|
417
417
|
body: serializers.AsyncMonitorRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
@@ -466,7 +466,7 @@ class Windows {
|
|
466
466
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
467
467
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AirtopEnvironment.Default, `async/sessions/${encodeURIComponent(sessionId)}/windows/${encodeURIComponent(windowId)}/page-query`),
|
468
468
|
method: "POST",
|
469
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.
|
469
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.37-beta0", "User-Agent": "@airtop/sdk/0.1.37-beta0", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
470
470
|
contentType: "application/json",
|
471
471
|
requestType: "json",
|
472
472
|
body: serializers.AsyncPageQueryRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
@@ -521,7 +521,7 @@ class Windows {
|
|
521
521
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
522
522
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AirtopEnvironment.Default, `async/sessions/${encodeURIComponent(sessionId)}/windows/${encodeURIComponent(windowId)}/paginated-extraction`),
|
523
523
|
method: "POST",
|
524
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.
|
524
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.37-beta0", "User-Agent": "@airtop/sdk/0.1.37-beta0", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
525
525
|
contentType: "application/json",
|
526
526
|
requestType: "json",
|
527
527
|
body: serializers.AsyncPaginatedExtractionRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
@@ -578,7 +578,7 @@ class Windows {
|
|
578
578
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
579
579
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AirtopEnvironment.Default, `async/sessions/${encodeURIComponent(sessionId)}/windows/${encodeURIComponent(windowId)}/prompt-content`),
|
580
580
|
method: "POST",
|
581
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.
|
581
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.37-beta0", "User-Agent": "@airtop/sdk/0.1.37-beta0", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
582
582
|
contentType: "application/json",
|
583
583
|
requestType: "json",
|
584
584
|
body: serializers.AsyncPromptContentRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
@@ -633,7 +633,7 @@ class Windows {
|
|
633
633
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
634
634
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AirtopEnvironment.Default, `async/sessions/${encodeURIComponent(sessionId)}/windows/${encodeURIComponent(windowId)}/screenshot`),
|
635
635
|
method: "POST",
|
636
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.
|
636
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.37-beta0", "User-Agent": "@airtop/sdk/0.1.37-beta0", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
637
637
|
contentType: "application/json",
|
638
638
|
requestType: "json",
|
639
639
|
body: serializers.AsyncScreenshotRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
@@ -688,7 +688,7 @@ class Windows {
|
|
688
688
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
689
689
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AirtopEnvironment.Default, `async/sessions/${encodeURIComponent(sessionId)}/windows/${encodeURIComponent(windowId)}/summarize-content`),
|
690
690
|
method: "POST",
|
691
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.
|
691
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.37-beta0", "User-Agent": "@airtop/sdk/0.1.37-beta0", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
692
692
|
contentType: "application/json",
|
693
693
|
requestType: "json",
|
694
694
|
body: serializers.AsyncSummarizeContentRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
@@ -743,7 +743,7 @@ class Windows {
|
|
743
743
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
744
744
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AirtopEnvironment.Default, `async/sessions/${encodeURIComponent(sessionId)}/windows/${encodeURIComponent(windowId)}/type`),
|
745
745
|
method: "POST",
|
746
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.
|
746
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.37-beta0", "User-Agent": "@airtop/sdk/0.1.37-beta0", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
747
747
|
contentType: "application/json",
|
748
748
|
requestType: "json",
|
749
749
|
body: serializers.AsyncTypeRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
@@ -797,7 +797,7 @@ class Windows {
|
|
797
797
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
798
798
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AirtopEnvironment.Default, `sessions/${encodeURIComponent(sessionId)}/windows`),
|
799
799
|
method: "POST",
|
800
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.
|
800
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.37-beta0", "User-Agent": "@airtop/sdk/0.1.37-beta0", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
801
801
|
contentType: "application/json",
|
802
802
|
requestType: "json",
|
803
803
|
body: serializers.CreateWindowInputV1Body.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
@@ -865,7 +865,7 @@ class Windows {
|
|
865
865
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
866
866
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AirtopEnvironment.Default, `sessions/${encodeURIComponent(sessionId)}/windows/${encodeURIComponent(windowId)}`),
|
867
867
|
method: "GET",
|
868
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.
|
868
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.37-beta0", "User-Agent": "@airtop/sdk/0.1.37-beta0", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
869
869
|
contentType: "application/json",
|
870
870
|
queryParameters: _queryParams,
|
871
871
|
requestType: "json",
|
@@ -922,7 +922,7 @@ class Windows {
|
|
922
922
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
923
923
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AirtopEnvironment.Default, `sessions/${encodeURIComponent(sessionId)}/windows/${encodeURIComponent(windowId)}`),
|
924
924
|
method: "POST",
|
925
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.
|
925
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.37-beta0", "User-Agent": "@airtop/sdk/0.1.37-beta0", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
926
926
|
contentType: "application/json",
|
927
927
|
requestType: "json",
|
928
928
|
body: serializers.WindowLoadUrlV1Body.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
@@ -976,7 +976,7 @@ class Windows {
|
|
976
976
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
977
977
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AirtopEnvironment.Default, `sessions/${encodeURIComponent(sessionId)}/windows/${encodeURIComponent(windowId)}`),
|
978
978
|
method: "DELETE",
|
979
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.
|
979
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.37-beta0", "User-Agent": "@airtop/sdk/0.1.37-beta0", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
980
980
|
contentType: "application/json",
|
981
981
|
requestType: "json",
|
982
982
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
@@ -1032,7 +1032,7 @@ class Windows {
|
|
1032
1032
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
1033
1033
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AirtopEnvironment.Default, `sessions/${encodeURIComponent(sessionId)}/windows/${encodeURIComponent(windowId)}/click`),
|
1034
1034
|
method: "POST",
|
1035
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.
|
1035
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.37-beta0", "User-Agent": "@airtop/sdk/0.1.37-beta0", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
1036
1036
|
contentType: "application/json",
|
1037
1037
|
requestType: "json",
|
1038
1038
|
body: serializers.SessionClickHandlerRequestBody.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
@@ -1087,7 +1087,7 @@ class Windows {
|
|
1087
1087
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
1088
1088
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AirtopEnvironment.Default, `sessions/${encodeURIComponent(sessionId)}/windows/${encodeURIComponent(windowId)}/create-form-filler`),
|
1089
1089
|
method: "POST",
|
1090
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.
|
1090
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.37-beta0", "User-Agent": "@airtop/sdk/0.1.37-beta0", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
1091
1091
|
contentType: "application/json",
|
1092
1092
|
requestType: "json",
|
1093
1093
|
body: serializers.CreateFormFillerRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
@@ -1144,7 +1144,7 @@ class Windows {
|
|
1144
1144
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
1145
1145
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AirtopEnvironment.Default, `sessions/${encodeURIComponent(sessionId)}/windows/${encodeURIComponent(windowId)}/fill-form`),
|
1146
1146
|
method: "POST",
|
1147
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.
|
1147
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.37-beta0", "User-Agent": "@airtop/sdk/0.1.37-beta0", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
1148
1148
|
contentType: "application/json",
|
1149
1149
|
requestType: "json",
|
1150
1150
|
body: serializers.FillFormRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
@@ -1201,7 +1201,7 @@ class Windows {
|
|
1201
1201
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
1202
1202
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AirtopEnvironment.Default, `sessions/${encodeURIComponent(sessionId)}/windows/${encodeURIComponent(windowId)}/hover`),
|
1203
1203
|
method: "POST",
|
1204
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.
|
1204
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.37-beta0", "User-Agent": "@airtop/sdk/0.1.37-beta0", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
1205
1205
|
contentType: "application/json",
|
1206
1206
|
requestType: "json",
|
1207
1207
|
body: serializers.SessionHoverHandlerRequestBody.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
@@ -1256,7 +1256,7 @@ class Windows {
|
|
1256
1256
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
1257
1257
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AirtopEnvironment.Default, `sessions/${encodeURIComponent(sessionId)}/windows/${encodeURIComponent(windowId)}/monitor`),
|
1258
1258
|
method: "POST",
|
1259
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.
|
1259
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.37-beta0", "User-Agent": "@airtop/sdk/0.1.37-beta0", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
1260
1260
|
contentType: "application/json",
|
1261
1261
|
requestType: "json",
|
1262
1262
|
body: serializers.SessionMonitorHandlerRequestBody.jsonOrThrow(request, {
|
@@ -1296,6 +1296,63 @@ class Windows {
|
|
1296
1296
|
}
|
1297
1297
|
});
|
1298
1298
|
}
|
1299
|
+
/**
|
1300
|
+
* Prompt OpenAI Operator
|
1301
|
+
*
|
1302
|
+
* @param {string} sessionId - ID of the session that owns the window.
|
1303
|
+
* @param {string} windowId - Airtop window ID of the browser window.
|
1304
|
+
* @param {Airtop.OperatorPromptV1Body} request
|
1305
|
+
* @param {Windows.RequestOptions} requestOptions - Request-specific configuration.
|
1306
|
+
*
|
1307
|
+
* @example
|
1308
|
+
* await client.windows.operatorPrompt("6aac6f73-bd89-4a76-ab32-5a6c422e8b0b", "7334da2a-91b0-42c5-6156-76a5eba87430", {
|
1309
|
+
* prompt: "What is the latest news about OpenAI?"
|
1310
|
+
* })
|
1311
|
+
*/
|
1312
|
+
operatorPrompt(sessionId, windowId, request, requestOptions) {
|
1313
|
+
return __awaiter(this, void 0, void 0, function* () {
|
1314
|
+
var _a, _b, _c;
|
1315
|
+
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
1316
|
+
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AirtopEnvironment.Default, `sessions/${encodeURIComponent(sessionId)}/windows/${encodeURIComponent(windowId)}/operator`),
|
1317
|
+
method: "POST",
|
1318
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.37-beta0", "User-Agent": "@airtop/sdk/0.1.37-beta0", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
1319
|
+
contentType: "application/json",
|
1320
|
+
requestType: "json",
|
1321
|
+
body: serializers.OperatorPromptV1Body.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
1322
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
1323
|
+
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
1324
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
1325
|
+
});
|
1326
|
+
if (_response.ok) {
|
1327
|
+
return serializers.AsyncOperatorPromptResponseEnvelope.parseOrThrow(_response.body, {
|
1328
|
+
unrecognizedObjectKeys: "passthrough",
|
1329
|
+
allowUnrecognizedUnionMembers: true,
|
1330
|
+
allowUnrecognizedEnumValues: true,
|
1331
|
+
skipValidation: true,
|
1332
|
+
breadcrumbsPrefix: ["response"],
|
1333
|
+
});
|
1334
|
+
}
|
1335
|
+
if (_response.error.reason === "status-code") {
|
1336
|
+
throw new errors.AirtopError({
|
1337
|
+
statusCode: _response.error.statusCode,
|
1338
|
+
body: _response.error.body,
|
1339
|
+
});
|
1340
|
+
}
|
1341
|
+
switch (_response.error.reason) {
|
1342
|
+
case "non-json":
|
1343
|
+
throw new errors.AirtopError({
|
1344
|
+
statusCode: _response.error.statusCode,
|
1345
|
+
body: _response.error.rawBody,
|
1346
|
+
});
|
1347
|
+
case "timeout":
|
1348
|
+
throw new errors.AirtopTimeoutError("Timeout exceeded when calling POST /sessions/{sessionId}/windows/{windowId}/operator.");
|
1349
|
+
case "unknown":
|
1350
|
+
throw new errors.AirtopError({
|
1351
|
+
message: _response.error.errorMessage,
|
1352
|
+
});
|
1353
|
+
}
|
1354
|
+
});
|
1355
|
+
}
|
1299
1356
|
/**
|
1300
1357
|
* Submit a prompt that queries the content of a specific browser window. You may extract content from the page, or ask a question about the page and allow the AI to answer it (ex. Is the user logged in?).
|
1301
1358
|
*
|
@@ -1315,7 +1372,7 @@ class Windows {
|
|
1315
1372
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
1316
1373
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AirtopEnvironment.Default, `sessions/${encodeURIComponent(sessionId)}/windows/${encodeURIComponent(windowId)}/page-query`),
|
1317
1374
|
method: "POST",
|
1318
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.
|
1375
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.37-beta0", "User-Agent": "@airtop/sdk/0.1.37-beta0", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
1319
1376
|
contentType: "application/json",
|
1320
1377
|
requestType: "json",
|
1321
1378
|
body: serializers.SessionPageQueryHandlerRequestBody.jsonOrThrow(request, {
|
@@ -1374,7 +1431,7 @@ class Windows {
|
|
1374
1431
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
1375
1432
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AirtopEnvironment.Default, `sessions/${encodeURIComponent(sessionId)}/windows/${encodeURIComponent(windowId)}/paginated-extraction`),
|
1376
1433
|
method: "POST",
|
1377
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.
|
1434
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.37-beta0", "User-Agent": "@airtop/sdk/0.1.37-beta0", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
1378
1435
|
contentType: "application/json",
|
1379
1436
|
requestType: "json",
|
1380
1437
|
body: serializers.SessionPaginatedExtractionHandlerRequestBody.jsonOrThrow(request, {
|
@@ -1433,7 +1490,7 @@ class Windows {
|
|
1433
1490
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
1434
1491
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AirtopEnvironment.Default, `sessions/${encodeURIComponent(sessionId)}/windows/${encodeURIComponent(windowId)}/prompt-content`),
|
1435
1492
|
method: "POST",
|
1436
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.
|
1493
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.37-beta0", "User-Agent": "@airtop/sdk/0.1.37-beta0", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
1437
1494
|
contentType: "application/json",
|
1438
1495
|
requestType: "json",
|
1439
1496
|
body: serializers.SessionPageQueryHandlerRequestBody.jsonOrThrow(request, {
|
@@ -1490,7 +1547,7 @@ class Windows {
|
|
1490
1547
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
1491
1548
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AirtopEnvironment.Default, `sessions/${encodeURIComponent(sessionId)}/windows/${encodeURIComponent(windowId)}/scrape-content`),
|
1492
1549
|
method: "POST",
|
1493
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.
|
1550
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.37-beta0", "User-Agent": "@airtop/sdk/0.1.37-beta0", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
1494
1551
|
contentType: "application/json",
|
1495
1552
|
requestType: "json",
|
1496
1553
|
body: serializers.ScrapeContentRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
@@ -1545,7 +1602,7 @@ class Windows {
|
|
1545
1602
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
1546
1603
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AirtopEnvironment.Default, `sessions/${encodeURIComponent(sessionId)}/windows/${encodeURIComponent(windowId)}/screenshot`),
|
1547
1604
|
method: "POST",
|
1548
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.
|
1605
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.37-beta0", "User-Agent": "@airtop/sdk/0.1.37-beta0", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
1549
1606
|
contentType: "application/json",
|
1550
1607
|
requestType: "json",
|
1551
1608
|
body: serializers.SessionScreenshotHandlerRequestBody.jsonOrThrow(request, {
|
@@ -1602,7 +1659,7 @@ class Windows {
|
|
1602
1659
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
1603
1660
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AirtopEnvironment.Default, `sessions/${encodeURIComponent(sessionId)}/windows/${encodeURIComponent(windowId)}/scroll`),
|
1604
1661
|
method: "POST",
|
1605
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.
|
1662
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.37-beta0", "User-Agent": "@airtop/sdk/0.1.37-beta0", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
1606
1663
|
contentType: "application/json",
|
1607
1664
|
requestType: "json",
|
1608
1665
|
body: serializers.SessionScrollHandlerRequestBody.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
@@ -1657,7 +1714,7 @@ class Windows {
|
|
1657
1714
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
1658
1715
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AirtopEnvironment.Default, `sessions/${encodeURIComponent(sessionId)}/windows/${encodeURIComponent(windowId)}/summarize-content`),
|
1659
1716
|
method: "POST",
|
1660
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.
|
1717
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.37-beta0", "User-Agent": "@airtop/sdk/0.1.37-beta0", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
1661
1718
|
contentType: "application/json",
|
1662
1719
|
requestType: "json",
|
1663
1720
|
body: serializers.SessionSummaryHandlerRequestBody.jsonOrThrow(request, {
|
@@ -1716,7 +1773,7 @@ class Windows {
|
|
1716
1773
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
1717
1774
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AirtopEnvironment.Default, `sessions/${encodeURIComponent(sessionId)}/windows/${encodeURIComponent(windowId)}/type`),
|
1718
1775
|
method: "POST",
|
1719
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.
|
1776
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@airtop/sdk", "X-Fern-SDK-Version": "0.1.37-beta0", "User-Agent": "@airtop/sdk/0.1.37-beta0", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
1720
1777
|
contentType: "application/json",
|
1721
1778
|
requestType: "json",
|
1722
1779
|
body: serializers.SessionTypeHandlerRequestBody.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
@@ -0,0 +1,25 @@
|
|
1
|
+
/**
|
2
|
+
* This file was auto-generated by Fern from our API Definition.
|
3
|
+
*/
|
4
|
+
import * as Airtop from "../../../../index";
|
5
|
+
/**
|
6
|
+
* @example
|
7
|
+
* {
|
8
|
+
* prompt: "What is the latest news about OpenAI?"
|
9
|
+
* }
|
10
|
+
*/
|
11
|
+
export interface OperatorPromptV1Body {
|
12
|
+
/** Async configuration options. */
|
13
|
+
async?: Airtop.AsyncConfig;
|
14
|
+
clientRequestId?: string;
|
15
|
+
/** A credit threshold that, once exceeded, will cause the operation to be cancelled. Note that this is *not* a hard limit, but a threshold that is checked periodically during the course of fulfilling the request. A default threshold is used if not specified, but you can use this option to increase or decrease as needed. Set to 0 to disable this feature entirely (not recommended). */
|
16
|
+
costThresholdCredits?: number;
|
17
|
+
/** prompt to ask operator */
|
18
|
+
prompt: string;
|
19
|
+
/**
|
20
|
+
* A time threshold in seconds that, once exceeded, will cause the operation to be cancelled. Note that this is *not* a hard limit, but a threshold that is checked periodically during the course of fulfilling the request. A default threshold is used if not specified, but you can use this option to increase or decrease as needed. Set to 0 to disable this feature entirely (not recommended).
|
21
|
+
*
|
22
|
+
* This setting does not extend the maximum session duration provided at the time of session creation.
|
23
|
+
*/
|
24
|
+
timeThresholdSeconds?: number;
|
25
|
+
}
|
@@ -19,6 +19,7 @@ export { type CreateFormFillerRequest } from "./CreateFormFillerRequest";
|
|
19
19
|
export { type FillFormRequest } from "./FillFormRequest";
|
20
20
|
export { type SessionHoverHandlerRequestBody } from "./SessionHoverHandlerRequestBody";
|
21
21
|
export { type SessionMonitorHandlerRequestBody } from "./SessionMonitorHandlerRequestBody";
|
22
|
+
export { type OperatorPromptV1Body } from "./OperatorPromptV1Body";
|
22
23
|
export { type SessionPaginatedExtractionHandlerRequestBody } from "./SessionPaginatedExtractionHandlerRequestBody";
|
23
24
|
export { type ScrapeContentRequest } from "./ScrapeContentRequest";
|
24
25
|
export { type SessionScreenshotHandlerRequestBody } from "./SessionScreenshotHandlerRequestBody";
|
@@ -13,10 +13,10 @@ export interface CreateFileV1 {
|
|
13
13
|
id: string;
|
14
14
|
/** ID of the organization */
|
15
15
|
orgId: string;
|
16
|
-
/** DEPRECATED: Use sessionIds instead */
|
17
|
-
sessionId?: string;
|
18
16
|
/** IDs of the associated sessions */
|
19
17
|
sessionIds?: string[];
|
18
|
+
/** Status of the file */
|
19
|
+
status: Airtop.CreateFileV1Status;
|
20
20
|
/** Time when the file upload was started */
|
21
21
|
uploadStartTime: Date;
|
22
22
|
/** URL to upload the file */
|
@@ -0,0 +1,13 @@
|
|
1
|
+
/**
|
2
|
+
* This file was auto-generated by Fern from our API Definition.
|
3
|
+
*/
|
4
|
+
/**
|
5
|
+
* Status of the file
|
6
|
+
*/
|
7
|
+
export type CreateFileV1Status = "available" | "uploading" | "upload_failed" | "deleted";
|
8
|
+
export declare const CreateFileV1Status: {
|
9
|
+
readonly Available: "available";
|
10
|
+
readonly Uploading: "uploading";
|
11
|
+
readonly UploadFailed: "upload_failed";
|
12
|
+
readonly Deleted: "deleted";
|
13
|
+
};
|
@@ -0,0 +1,12 @@
|
|
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.CreateFileV1Status = void 0;
|
7
|
+
exports.CreateFileV1Status = {
|
8
|
+
Available: "available",
|
9
|
+
Uploading: "uploading",
|
10
|
+
UploadFailed: "upload_failed",
|
11
|
+
Deleted: "deleted",
|
12
|
+
};
|
@@ -0,0 +1,14 @@
|
|
1
|
+
/**
|
2
|
+
* This file was auto-generated by Fern from our API Definition.
|
3
|
+
*/
|
4
|
+
import * as Airtop from "../index";
|
5
|
+
export interface FileEventMessage {
|
6
|
+
/** Download URL */
|
7
|
+
downloadUrl: string;
|
8
|
+
/** Event name */
|
9
|
+
event: string;
|
10
|
+
/** File ID */
|
11
|
+
fileId: string;
|
12
|
+
/** Status of the file */
|
13
|
+
status: Airtop.FileEventMessageStatus;
|
14
|
+
}
|
@@ -0,0 +1,13 @@
|
|
1
|
+
/**
|
2
|
+
* This file was auto-generated by Fern from our API Definition.
|
3
|
+
*/
|
4
|
+
/**
|
5
|
+
* Status of the file
|
6
|
+
*/
|
7
|
+
export type FileEventMessageStatus = "available" | "uploading" | "upload_failed" | "deleted";
|
8
|
+
export declare const FileEventMessageStatus: {
|
9
|
+
readonly Available: "available";
|
10
|
+
readonly Uploading: "uploading";
|
11
|
+
readonly UploadFailed: "upload_failed";
|
12
|
+
readonly Deleted: "deleted";
|
13
|
+
};
|
@@ -0,0 +1,12 @@
|
|
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.FileEventMessageStatus = void 0;
|
7
|
+
exports.FileEventMessageStatus = {
|
8
|
+
Available: "available",
|
9
|
+
Uploading: "uploading",
|
10
|
+
UploadFailed: "upload_failed",
|
11
|
+
Deleted: "deleted",
|
12
|
+
};
|
package/api/types/GetFileV1.d.ts
CHANGED
@@ -5,6 +5,8 @@ import * as Airtop from "../index";
|
|
5
5
|
export interface GetFileV1 {
|
6
6
|
/** URL to download the file */
|
7
7
|
downloadUrl: string;
|
8
|
+
/** Time when the file will be automatically deleted. Typically 48 hours after the file is uploaded */
|
9
|
+
expiryTime?: Date;
|
8
10
|
/** Size of the file in bytes */
|
9
11
|
fileBytes: number;
|
10
12
|
/** Name of the file */
|
@@ -15,10 +17,10 @@ export interface GetFileV1 {
|
|
15
17
|
id: string;
|
16
18
|
/** ID of the organization */
|
17
19
|
orgId: string;
|
18
|
-
/** DEPRECATED: Use sessionIds instead */
|
19
|
-
sessionId?: string;
|
20
20
|
/** IDs of the associated sessions */
|
21
21
|
sessionIds?: string[];
|
22
|
+
/** Status of the file */
|
23
|
+
status: Airtop.GetFileV1Status;
|
22
24
|
/** Time when the file upload was started */
|
23
25
|
uploadStartTime: Date;
|
24
26
|
}
|
@@ -0,0 +1,13 @@
|
|
1
|
+
/**
|
2
|
+
* This file was auto-generated by Fern from our API Definition.
|
3
|
+
*/
|
4
|
+
/**
|
5
|
+
* Status of the file
|
6
|
+
*/
|
7
|
+
export type GetFileV1Status = "available" | "uploading" | "upload_failed" | "deleted";
|
8
|
+
export declare const GetFileV1Status: {
|
9
|
+
readonly Available: "available";
|
10
|
+
readonly Uploading: "uploading";
|
11
|
+
readonly UploadFailed: "upload_failed";
|
12
|
+
readonly Deleted: "deleted";
|
13
|
+
};
|
@@ -0,0 +1,12 @@
|
|
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.GetFileV1Status = void 0;
|
7
|
+
exports.GetFileV1Status = {
|
8
|
+
Available: "available",
|
9
|
+
Uploading: "uploading",
|
10
|
+
UploadFailed: "upload_failed",
|
11
|
+
Deleted: "deleted",
|
12
|
+
};
|