scrapebadger 0.40.1 → 0.41.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.cts +21 -0
- package/dist/index.d.ts +21 -0
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +1 -1
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -99,6 +99,27 @@ interface ScrapeResult {
|
|
|
99
99
|
ai_extraction: Record<string, unknown> | string | unknown[] | null;
|
|
100
100
|
ai_model: string | null;
|
|
101
101
|
ai_error: string | null;
|
|
102
|
+
/**
|
|
103
|
+
* Whether the `wait_for` selector appeared within `wait_timeout`. Null when
|
|
104
|
+
* no `wait_for` was requested. A miss never arrives as a success — the API
|
|
105
|
+
* answers `422 wait_for_timeout` and nothing is charged.
|
|
106
|
+
*/
|
|
107
|
+
wait_for_found?: boolean | null;
|
|
108
|
+
/**
|
|
109
|
+
* One entry per executed `js_scenario` step, in order: `step`, `action`,
|
|
110
|
+
* `selector`, `ok`, `error`, `url` (the page URL right after the step).
|
|
111
|
+
* Execution stops at the first failed step; a failed step is a free
|
|
112
|
+
* `422 js_scenario_failed`. Null when no scenario ran.
|
|
113
|
+
*/
|
|
114
|
+
js_scenario_report?: JsScenarioStepReport[] | null;
|
|
115
|
+
}
|
|
116
|
+
interface JsScenarioStepReport {
|
|
117
|
+
step: number;
|
|
118
|
+
action: string;
|
|
119
|
+
selector: string | null;
|
|
120
|
+
ok: boolean;
|
|
121
|
+
error: string | null;
|
|
122
|
+
url: string | null;
|
|
102
123
|
}
|
|
103
124
|
interface DetectOptions {
|
|
104
125
|
/** Request timeout in ms (1000-60000) */
|
package/dist/index.d.ts
CHANGED
|
@@ -99,6 +99,27 @@ interface ScrapeResult {
|
|
|
99
99
|
ai_extraction: Record<string, unknown> | string | unknown[] | null;
|
|
100
100
|
ai_model: string | null;
|
|
101
101
|
ai_error: string | null;
|
|
102
|
+
/**
|
|
103
|
+
* Whether the `wait_for` selector appeared within `wait_timeout`. Null when
|
|
104
|
+
* no `wait_for` was requested. A miss never arrives as a success — the API
|
|
105
|
+
* answers `422 wait_for_timeout` and nothing is charged.
|
|
106
|
+
*/
|
|
107
|
+
wait_for_found?: boolean | null;
|
|
108
|
+
/**
|
|
109
|
+
* One entry per executed `js_scenario` step, in order: `step`, `action`,
|
|
110
|
+
* `selector`, `ok`, `error`, `url` (the page URL right after the step).
|
|
111
|
+
* Execution stops at the first failed step; a failed step is a free
|
|
112
|
+
* `422 js_scenario_failed`. Null when no scenario ran.
|
|
113
|
+
*/
|
|
114
|
+
js_scenario_report?: JsScenarioStepReport[] | null;
|
|
115
|
+
}
|
|
116
|
+
interface JsScenarioStepReport {
|
|
117
|
+
step: number;
|
|
118
|
+
action: string;
|
|
119
|
+
selector: string | null;
|
|
120
|
+
ok: boolean;
|
|
121
|
+
error: string | null;
|
|
122
|
+
url: string | null;
|
|
102
123
|
}
|
|
103
124
|
interface DetectOptions {
|
|
104
125
|
/** Request timeout in ms (1000-60000) */
|
package/dist/index.js
CHANGED
|
@@ -9,7 +9,7 @@ function _interopDefault (e) { return e && e.__esModule ? e : { default: e }; }
|
|
|
9
9
|
var WebSocket__default = /*#__PURE__*/_interopDefault(WebSocket);
|
|
10
10
|
|
|
11
11
|
// src/internal/version.ts
|
|
12
|
-
var SDK_VERSION = "0.
|
|
12
|
+
var SDK_VERSION = "0.41.0";
|
|
13
13
|
|
|
14
14
|
// src/internal/exceptions.ts
|
|
15
15
|
var ScrapeBadgerError = class _ScrapeBadgerError extends Error {
|