koonjs 0.5.2 → 0.5.5
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/index.d.ts +19 -19
- package/koon.linux-x64-gnu.node +0 -0
- package/koon.win32-x64-msvc.node +0 -0
- package/package.json +1 -1
package/index.d.ts
CHANGED
|
@@ -1,26 +1,23 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Browser profile name for impersonation.
|
|
3
|
+
*
|
|
4
|
+
* Format: `{browser}{version?}{-os?}`
|
|
5
|
+
* - browser: chrome, firefox, safari, edge, opera, chrome-mobile, firefox-mobile, safari-mobile, okhttp
|
|
6
|
+
* - version: optional number (e.g. 145, 148)
|
|
7
|
+
* - os: optional suffix with dash (e.g. -windows, -macos, -linux, -android, -ios)
|
|
8
|
+
*
|
|
9
|
+
* Examples: "chrome", "chrome145", "chrome145-macos", "firefox148-linux",
|
|
10
|
+
* "chrome-mobile145", "firefox-mobile148", "safari-mobile183", "okhttp5"
|
|
11
|
+
*/
|
|
1
12
|
export type Browser =
|
|
2
|
-
// Desktop browsers
|
|
3
|
-
| 'chrome' | '
|
|
4
|
-
| 'chrome136' | 'chrome137' | 'chrome138' | 'chrome139' | 'chrome140'
|
|
5
|
-
| 'chrome141' | 'chrome142' | 'chrome143' | 'chrome144' | 'chrome145'
|
|
6
|
-
| 'firefox' | 'firefox135' | 'firefox136' | 'firefox137' | 'firefox138'
|
|
7
|
-
| 'firefox139' | 'firefox140' | 'firefox141' | 'firefox142' | 'firefox143'
|
|
8
|
-
| 'firefox144' | 'firefox145' | 'firefox146' | 'firefox147' | 'firefox148'
|
|
9
|
-
| 'safari' | 'safari156' | 'safari160' | 'safari161' | 'safari170' | 'safari171'
|
|
10
|
-
| 'safari172' | 'safari173' | 'safari180' | 'safari181' | 'safari182' | 'safari183'
|
|
11
|
-
| 'edge' | 'edge131' | 'edge132' | 'edge133' | 'edge134' | 'edge135'
|
|
12
|
-
| 'edge136' | 'edge137' | 'edge138' | 'edge139' | 'edge140'
|
|
13
|
-
| 'edge141' | 'edge142' | 'edge143' | 'edge144' | 'edge145'
|
|
14
|
-
| 'opera' | 'opera124' | 'opera125' | 'opera126' | 'opera127'
|
|
13
|
+
// Desktop browsers (common values for autocomplete)
|
|
14
|
+
| 'chrome' | 'firefox' | 'safari' | 'edge' | 'opera'
|
|
15
15
|
// Mobile browsers
|
|
16
|
-
| 'chrome-mobile' |
|
|
17
|
-
| 'safari-mobile' | `safari-mobile${string}`
|
|
18
|
-
| 'firefox-mobile' | `firefox-mobile${number}`
|
|
16
|
+
| 'chrome-mobile' | 'firefox-mobile' | 'safari-mobile'
|
|
19
17
|
// OkHttp (Android apps)
|
|
20
18
|
| 'okhttp' | 'okhttp4' | 'okhttp5'
|
|
21
|
-
// OS
|
|
22
|
-
|
|
|
23
|
-
| `${string}-android` | `${string}-ios`;
|
|
19
|
+
// Any other valid profile string (version, OS suffix, etc.)
|
|
20
|
+
| (string & {});
|
|
24
21
|
|
|
25
22
|
export interface KoonOptions {
|
|
26
23
|
/** Browser profile to impersonate. */
|
|
@@ -154,6 +151,9 @@ export class Koon {
|
|
|
154
151
|
/** Clear all cookies from the cookie jar. Keeps TLS sessions and connection pool. */
|
|
155
152
|
clearCookies(): void;
|
|
156
153
|
|
|
154
|
+
/** Close all pooled connections and release resources. The client can still be used after — new connections open on demand. */
|
|
155
|
+
close(): void;
|
|
156
|
+
|
|
157
157
|
exportProfile(): string;
|
|
158
158
|
saveSession(): string;
|
|
159
159
|
loadSession(json: string): void;
|
|
Binary file
|
package/koon.win32-x64-msvc.node
CHANGED
|
Binary file
|