apify-client 2.22.4-beta.3 → 2.23.1-beta.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/bundle.js +289 -117
- package/dist/bundle.js.map +1 -1
- package/dist/http_client.d.ts.map +1 -1
- package/dist/http_client.js +1 -6
- package/dist/http_client.js.map +1 -1
- package/dist/interceptors.js.map +1 -1
- package/dist/resource_clients/actor.d.ts +30 -3
- package/dist/resource_clients/actor.d.ts.map +1 -1
- package/dist/resource_clients/actor.js +20 -3
- package/dist/resource_clients/actor.js.map +1 -1
- package/dist/resource_clients/key_value_store.js.map +1 -1
- package/dist/resource_clients/store_collection.d.ts +5 -0
- package/dist/resource_clients/store_collection.d.ts.map +1 -1
- package/dist/resource_clients/store_collection.js +1 -0
- package/dist/resource_clients/store_collection.js.map +1 -1
- package/dist/utils.d.ts +0 -5
- package/dist/utils.d.ts.map +1 -1
- package/dist/utils.js +4 -12
- package/dist/utils.js.map +1 -1
- package/package.json +1 -1
package/dist/bundle.js
CHANGED
|
@@ -11881,23 +11881,6 @@ module.exports = function (str) {
|
|
|
11881
11881
|
};
|
|
11882
11882
|
|
|
11883
11883
|
|
|
11884
|
-
},
|
|
11885
|
-
433(module) {
|
|
11886
|
-
function webpackEmptyAsyncContext(req) {
|
|
11887
|
-
// Here Promise.resolve().then() is used instead of new Promise() to prevent
|
|
11888
|
-
// uncaught exception popping up in devtools
|
|
11889
|
-
return Promise.resolve().then(function() {
|
|
11890
|
-
var e = new Error("Cannot find module '" + req + "'");
|
|
11891
|
-
e.code = 'MODULE_NOT_FOUND';
|
|
11892
|
-
throw e;
|
|
11893
|
-
});
|
|
11894
|
-
}
|
|
11895
|
-
webpackEmptyAsyncContext.keys = () => ([]);
|
|
11896
|
-
webpackEmptyAsyncContext.resolve = webpackEmptyAsyncContext;
|
|
11897
|
-
webpackEmptyAsyncContext.id = 433;
|
|
11898
|
-
module.exports = webpackEmptyAsyncContext;
|
|
11899
|
-
|
|
11900
|
-
|
|
11901
11884
|
},
|
|
11902
11885
|
1089(__unused_rspack_module, __webpack_exports__, __webpack_require__) {
|
|
11903
11886
|
"use strict";
|
|
@@ -12921,10 +12904,8 @@ class HttpClient {
|
|
|
12921
12904
|
async initNode() {
|
|
12922
12905
|
if (!(0,_utils__rspack_import_4.isNode)()) return;
|
|
12923
12906
|
const [{ ProxyAgent }, os] = await Promise.all([
|
|
12924
|
-
|
|
12925
|
-
(
|
|
12926
|
-
// eslint-disable-next-line @typescript-eslint/consistent-type-imports
|
|
12927
|
-
(0,_utils__rspack_import_4.dynamicNodeImport)('node:os')
|
|
12907
|
+
Promise.resolve().then(function __rspack_missing_module() { var e = new Error("Cannot find module 'proxy-agent'"); e.code = 'MODULE_NOT_FOUND'; throw e; }),
|
|
12908
|
+
Promise.resolve(/* import() */).then(__webpack_require__.t.bind(__webpack_require__, 3031, 23))
|
|
12928
12909
|
]);
|
|
12929
12910
|
// We want to keep sockets alive for better performance.
|
|
12930
12911
|
// Enhanced agent configuration based on agentkeepalive best practices:
|
|
@@ -13557,11 +13538,28 @@ __webpack_require__.d(__webpack_exports__, {
|
|
|
13557
13538
|
return (0,_utils__rspack_import_3.cast)((0,_utils__rspack_import_3.parseDateFields)((0,_utils__rspack_import_3.pluckData)(response.data)));
|
|
13558
13539
|
}
|
|
13559
13540
|
/**
|
|
13560
|
-
*
|
|
13541
|
+
* Returns a client for the default build of this Actor.
|
|
13542
|
+
*
|
|
13543
|
+
* Makes an API call to resolve the Actor's default build, then returns a {@link BuildClient}
|
|
13544
|
+
* for that build. Use the returned client to get build details, wait for the build to finish,
|
|
13545
|
+
* or access its logs.
|
|
13561
13546
|
*
|
|
13562
|
-
* @param options - Options for getting the build
|
|
13563
|
-
* @
|
|
13547
|
+
* @param options - Options for getting the default build
|
|
13548
|
+
* @param options.waitForFinish - Maximum time to wait (in seconds, max 60s) for the build to finish on the API side before returning. Default is 0 (returns immediately).
|
|
13549
|
+
* @returns A client for the default build
|
|
13564
13550
|
* @see https://docs.apify.com/api/v2/act-build-default-get
|
|
13551
|
+
*
|
|
13552
|
+
* @example
|
|
13553
|
+
* ```javascript
|
|
13554
|
+
* // Get the default build client, then fetch build details
|
|
13555
|
+
* const buildClient = await client.actor('my-actor').defaultBuild();
|
|
13556
|
+
* const build = await buildClient.get();
|
|
13557
|
+
* console.log(`Default build status: ${build.status}`);
|
|
13558
|
+
*
|
|
13559
|
+
* // Wait up to 60 seconds for the default build to finish
|
|
13560
|
+
* const buildClient = await client.actor('my-actor').defaultBuild({ waitForFinish: 60 });
|
|
13561
|
+
* const build = await buildClient.get();
|
|
13562
|
+
* ```
|
|
13565
13563
|
*/ async defaultBuild() {
|
|
13566
13564
|
let options = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
|
|
13567
13565
|
const response = await this.httpClient.call({
|
|
@@ -17023,7 +17021,8 @@ __webpack_require__.d(__webpack_exports__, {
|
|
|
17023
17021
|
sortBy: (ow__rspack_import_1_default().optional.string),
|
|
17024
17022
|
category: (ow__rspack_import_1_default().optional.string),
|
|
17025
17023
|
username: (ow__rspack_import_1_default().optional.string),
|
|
17026
|
-
pricingModel: (ow__rspack_import_1_default().optional.string)
|
|
17024
|
+
pricingModel: (ow__rspack_import_1_default().optional.string),
|
|
17025
|
+
includeUnrunnableActors: (ow__rspack_import_1_default().optional.boolean)
|
|
17027
17026
|
}));
|
|
17028
17027
|
return this._listPaginated(options);
|
|
17029
17028
|
}
|
|
@@ -17860,7 +17859,6 @@ __webpack_require__.d(__webpack_exports__, {
|
|
|
17860
17859
|
asArray: () => (asArray),
|
|
17861
17860
|
cast: () => (cast),
|
|
17862
17861
|
catchNotFoundOrThrow: () => (catchNotFoundOrThrow),
|
|
17863
|
-
dynamicNodeImport: () => (dynamicNodeImport),
|
|
17864
17862
|
getVersionData: () => (getVersionData),
|
|
17865
17863
|
isBuffer: () => (isBuffer),
|
|
17866
17864
|
isNode: () => (isNode),
|
|
@@ -17961,10 +17959,8 @@ let gzipPromisified;
|
|
|
17961
17959
|
const areDataLargeEnough = Buffer.byteLength(value) >= MIN_GZIP_BYTES;
|
|
17962
17960
|
if (areDataLargeEnough) {
|
|
17963
17961
|
if (!gzipPromisified) {
|
|
17964
|
-
|
|
17965
|
-
const {
|
|
17966
|
-
// eslint-disable-next-line @typescript-eslint/consistent-type-imports
|
|
17967
|
-
const { gzip } = await dynamicNodeImport('node:zlib');
|
|
17962
|
+
const { promisify } = await Promise.resolve(/* import() */).then(__webpack_require__.t.bind(__webpack_require__, 6029, 23));
|
|
17963
|
+
const { gzip } = await Promise.resolve(/* import() */).then(__webpack_require__.t.bind(__webpack_require__, 1134, 23));
|
|
17968
17964
|
gzipPromisified = promisify(gzip);
|
|
17969
17965
|
}
|
|
17970
17966
|
return gzipPromisified(value);
|
|
@@ -17994,14 +17990,9 @@ let gzipPromisified;
|
|
|
17994
17990
|
return slicedArray;
|
|
17995
17991
|
}
|
|
17996
17992
|
function isNode() {
|
|
17993
|
+
if (true) return false;
|
|
17997
17994
|
return !!(typeof process !== 'undefined' && process.versions && process.versions.node);
|
|
17998
17995
|
}
|
|
17999
|
-
/**
|
|
18000
|
-
* Dynamic import wrapper that prevents bundlers from statically analyzing the import specifier.
|
|
18001
|
-
* Use this for Node.js-only modules that should not be included in browser bundles.
|
|
18002
|
-
*/ async function dynamicNodeImport(specifier) {
|
|
18003
|
-
return await __webpack_require__(433)(specifier);
|
|
18004
|
-
}
|
|
18005
17996
|
function isBuffer(value) {
|
|
18006
17997
|
return ow__rspack_import_0_default().isValid(value, ow__rspack_import_0_default().any((ow__rspack_import_0_default().buffer), (ow__rspack_import_0_default().arrayBuffer), (ow__rspack_import_0_default().typedArray)));
|
|
18007
17998
|
}
|
|
@@ -18011,7 +18002,7 @@ function isStream(value) {
|
|
|
18011
18002
|
function getVersionData() {
|
|
18012
18003
|
if (true) {
|
|
18013
18004
|
return {
|
|
18014
|
-
version: "2.
|
|
18005
|
+
version: "2.23.1-beta.0"
|
|
18015
18006
|
};
|
|
18016
18007
|
}
|
|
18017
18008
|
// eslint-disable-next-line
|
|
@@ -18095,6 +18086,21 @@ function asArray(value) {
|
|
|
18095
18086
|
"use strict";
|
|
18096
18087
|
/* (ignored) */
|
|
18097
18088
|
|
|
18089
|
+
},
|
|
18090
|
+
3031() {
|
|
18091
|
+
"use strict";
|
|
18092
|
+
/* (ignored) */
|
|
18093
|
+
|
|
18094
|
+
},
|
|
18095
|
+
6029() {
|
|
18096
|
+
"use strict";
|
|
18097
|
+
/* (ignored) */
|
|
18098
|
+
|
|
18099
|
+
},
|
|
18100
|
+
1134() {
|
|
18101
|
+
"use strict";
|
|
18102
|
+
/* (ignored) */
|
|
18103
|
+
|
|
18098
18104
|
},
|
|
18099
18105
|
6125(__unused_rspack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
18100
18106
|
"use strict";
|
|
@@ -18414,6 +18420,7 @@ var APIFY_ENV_VARS = {
|
|
|
18414
18420
|
PROXY_PASSWORD: "APIFY_PROXY_PASSWORD",
|
|
18415
18421
|
PROXY_PORT: "APIFY_PROXY_PORT",
|
|
18416
18422
|
PROXY_STATUS_URL: "APIFY_PROXY_STATUS_URL",
|
|
18423
|
+
MCP_PROXY_URL: "APIFY_MCP_PROXY_URL",
|
|
18417
18424
|
PURGE_ON_START: "APIFY_PURGE_ON_START",
|
|
18418
18425
|
SDK_LATEST_VERSION: "APIFY_SDK_LATEST_VERSION",
|
|
18419
18426
|
SYSTEM_INFO_INTERVAL_MILLIS: "APIFY_SYSTEM_INFO_INTERVAL_MILLIS",
|
|
@@ -19741,8 +19748,10 @@ var FORBIDDEN_USERNAMES_REGEXPS = [
|
|
|
19741
19748
|
"reel",
|
|
19742
19749
|
"video-reel",
|
|
19743
19750
|
"mcp",
|
|
19751
|
+
"mcpc",
|
|
19744
19752
|
"model-context-protocol",
|
|
19745
19753
|
"modelcontextprotocol",
|
|
19754
|
+
// 'apify.com' intentionally unescaped so "." matches any character, also blocking variants like "apify_com" or "apifyxcom"
|
|
19746
19755
|
"apify.com",
|
|
19747
19756
|
"design-kit",
|
|
19748
19757
|
"press-kit",
|
|
@@ -19752,6 +19761,76 @@ var FORBIDDEN_USERNAMES_REGEXPS = [
|
|
|
19752
19761
|
"challange",
|
|
19753
19762
|
"1m-challenge",
|
|
19754
19763
|
"1m-usd-challenge",
|
|
19764
|
+
// Apify platform resources
|
|
19765
|
+
"key-value-store",
|
|
19766
|
+
"request-queue",
|
|
19767
|
+
"request-queues",
|
|
19768
|
+
"builds",
|
|
19769
|
+
"schedule",
|
|
19770
|
+
// AI / LLM related
|
|
19771
|
+
"llms",
|
|
19772
|
+
"openai",
|
|
19773
|
+
"anthropic",
|
|
19774
|
+
"claude",
|
|
19775
|
+
"copilot",
|
|
19776
|
+
"mistral",
|
|
19777
|
+
"prompt",
|
|
19778
|
+
"prompts",
|
|
19779
|
+
"embeddings",
|
|
19780
|
+
"vectors",
|
|
19781
|
+
// Organizations / workspaces / permissions
|
|
19782
|
+
"orgs",
|
|
19783
|
+
"workspaces",
|
|
19784
|
+
"tenant",
|
|
19785
|
+
"tenants",
|
|
19786
|
+
"permission",
|
|
19787
|
+
"permissions",
|
|
19788
|
+
// Auth / security
|
|
19789
|
+
"saml",
|
|
19790
|
+
"scim",
|
|
19791
|
+
"token",
|
|
19792
|
+
"tokens",
|
|
19793
|
+
"api-key",
|
|
19794
|
+
"api-keys",
|
|
19795
|
+
// Billing / commerce
|
|
19796
|
+
"coupon",
|
|
19797
|
+
"coupons",
|
|
19798
|
+
"discount",
|
|
19799
|
+
"discounts",
|
|
19800
|
+
"promos",
|
|
19801
|
+
"refund",
|
|
19802
|
+
"refunds",
|
|
19803
|
+
"credit",
|
|
19804
|
+
"credits",
|
|
19805
|
+
"billing-portal",
|
|
19806
|
+
// Infrastructure / environments
|
|
19807
|
+
"production",
|
|
19808
|
+
"canary",
|
|
19809
|
+
"restricted",
|
|
19810
|
+
// Communication
|
|
19811
|
+
"conversations",
|
|
19812
|
+
"reactions",
|
|
19813
|
+
"mentions",
|
|
19814
|
+
// Legal / trust / web standards
|
|
19815
|
+
"accessibility",
|
|
19816
|
+
"imprint",
|
|
19817
|
+
"impressum",
|
|
19818
|
+
"trust",
|
|
19819
|
+
"trust-center",
|
|
19820
|
+
"security-center",
|
|
19821
|
+
// Brand protection / impersonation prevention
|
|
19822
|
+
"brand",
|
|
19823
|
+
"branding",
|
|
19824
|
+
"verified",
|
|
19825
|
+
"apify-support",
|
|
19826
|
+
"apify-team",
|
|
19827
|
+
"support-team",
|
|
19828
|
+
"abuse",
|
|
19829
|
+
// Incidents / updates
|
|
19830
|
+
"outage",
|
|
19831
|
+
"incident",
|
|
19832
|
+
"incidents",
|
|
19833
|
+
"what-is-new",
|
|
19755
19834
|
// Special files
|
|
19756
19835
|
"index",
|
|
19757
19836
|
"index\\.html",
|
|
@@ -19763,6 +19842,7 @@ var FORBIDDEN_USERNAMES_REGEXPS = [
|
|
|
19763
19842
|
"(apple-touch-icon.*)",
|
|
19764
19843
|
"security-whitepaper\\.pdf",
|
|
19765
19844
|
"security\\.txt",
|
|
19845
|
+
"llms\\.txt",
|
|
19766
19846
|
// All hidden files
|
|
19767
19847
|
"(\\..*)",
|
|
19768
19848
|
// Username starting with xxx-
|
|
@@ -19920,6 +20000,7 @@ var FORBIDDEN_USERNAMES_REGEXPS = [
|
|
|
19920
20000
|
"errors",
|
|
19921
20001
|
"eval",
|
|
19922
20002
|
"event",
|
|
20003
|
+
"events",
|
|
19923
20004
|
"exit",
|
|
19924
20005
|
"explore",
|
|
19925
20006
|
"facebook",
|
|
@@ -21698,14 +21779,20 @@ const factory = (env) => {
|
|
|
21698
21779
|
test(() => {
|
|
21699
21780
|
let duplexAccessed = false;
|
|
21700
21781
|
|
|
21701
|
-
const
|
|
21782
|
+
const request = new Request(_platform_index_js__rspack_import_1["default"].origin, {
|
|
21702
21783
|
body: new ReadableStream(),
|
|
21703
21784
|
method: 'POST',
|
|
21704
21785
|
get duplex() {
|
|
21705
21786
|
duplexAccessed = true;
|
|
21706
21787
|
return 'half';
|
|
21707
21788
|
},
|
|
21708
|
-
})
|
|
21789
|
+
});
|
|
21790
|
+
|
|
21791
|
+
const hasContentType = request.headers.has('Content-Type');
|
|
21792
|
+
|
|
21793
|
+
if (request.body != null) {
|
|
21794
|
+
request.body.cancel();
|
|
21795
|
+
}
|
|
21709
21796
|
|
|
21710
21797
|
return duplexAccessed && !hasContentType;
|
|
21711
21798
|
});
|
|
@@ -21849,6 +21936,19 @@ const factory = (env) => {
|
|
|
21849
21936
|
// see https://github.com/cloudflare/workerd/issues/902
|
|
21850
21937
|
const isCredentialsSupported = isRequestSupported && 'credentials' in Request.prototype;
|
|
21851
21938
|
|
|
21939
|
+
// If data is FormData and Content-Type is multipart/form-data without boundary,
|
|
21940
|
+
// delete it so fetch can set it correctly with the boundary
|
|
21941
|
+
if (_utils_js__rspack_import_0["default"].isFormData(data)) {
|
|
21942
|
+
const contentType = headers.getContentType();
|
|
21943
|
+
if (
|
|
21944
|
+
contentType &&
|
|
21945
|
+
/^multipart\/form-data/i.test(contentType) &&
|
|
21946
|
+
!/boundary=/i.test(contentType)
|
|
21947
|
+
) {
|
|
21948
|
+
headers.delete('content-type');
|
|
21949
|
+
}
|
|
21950
|
+
}
|
|
21951
|
+
|
|
21852
21952
|
const resolvedOptions = {
|
|
21853
21953
|
...fetchOptions,
|
|
21854
21954
|
signal: composedSignal,
|
|
@@ -22577,13 +22677,29 @@ class Axios {
|
|
|
22577
22677
|
Error.captureStackTrace ? Error.captureStackTrace(dummy) : (dummy = new Error());
|
|
22578
22678
|
|
|
22579
22679
|
// slice off the Error: ... line
|
|
22580
|
-
const stack =
|
|
22680
|
+
const stack = (() => {
|
|
22681
|
+
if (!dummy.stack) {
|
|
22682
|
+
return '';
|
|
22683
|
+
}
|
|
22684
|
+
|
|
22685
|
+
const firstNewlineIndex = dummy.stack.indexOf('\n');
|
|
22686
|
+
|
|
22687
|
+
return firstNewlineIndex === -1 ? '' : dummy.stack.slice(firstNewlineIndex + 1);
|
|
22688
|
+
})();
|
|
22581
22689
|
try {
|
|
22582
22690
|
if (!err.stack) {
|
|
22583
22691
|
err.stack = stack;
|
|
22584
22692
|
// match without the 2 top stack lines
|
|
22585
|
-
} else if (stack
|
|
22586
|
-
|
|
22693
|
+
} else if (stack) {
|
|
22694
|
+
const firstNewlineIndex = stack.indexOf('\n');
|
|
22695
|
+
const secondNewlineIndex =
|
|
22696
|
+
firstNewlineIndex === -1 ? -1 : stack.indexOf('\n', firstNewlineIndex + 1);
|
|
22697
|
+
const stackWithoutTwoTopLines =
|
|
22698
|
+
secondNewlineIndex === -1 ? '' : stack.slice(secondNewlineIndex + 1);
|
|
22699
|
+
|
|
22700
|
+
if (!String(err.stack).endsWith(stackWithoutTwoTopLines)) {
|
|
22701
|
+
err.stack += '\n' + stack;
|
|
22702
|
+
}
|
|
22587
22703
|
}
|
|
22588
22704
|
} catch (e) {
|
|
22589
22705
|
// ignore the case where "stack" is an un-writable property
|
|
@@ -22767,8 +22883,6 @@ _utils_js__rspack_import_3["default"].forEach(['delete', 'get', 'head', 'options
|
|
|
22767
22883
|
});
|
|
22768
22884
|
|
|
22769
22885
|
_utils_js__rspack_import_3["default"].forEach(['post', 'put', 'patch'], function forEachMethodWithData(method) {
|
|
22770
|
-
/*eslint func-names:0*/
|
|
22771
|
-
|
|
22772
22886
|
function generateHTTPMethod(isForm) {
|
|
22773
22887
|
return function httpMethod(url, data, config) {
|
|
22774
22888
|
return this.request(
|
|
@@ -22821,40 +22935,40 @@ class AxiosError extends Error {
|
|
|
22821
22935
|
return axiosError;
|
|
22822
22936
|
}
|
|
22823
22937
|
|
|
22824
|
-
|
|
22825
|
-
|
|
22826
|
-
|
|
22827
|
-
|
|
22828
|
-
|
|
22829
|
-
|
|
22830
|
-
|
|
22831
|
-
|
|
22832
|
-
|
|
22833
|
-
|
|
22834
|
-
|
|
22835
|
-
|
|
22836
|
-
|
|
22837
|
-
|
|
22838
|
-
|
|
22839
|
-
|
|
22840
|
-
|
|
22841
|
-
|
|
22842
|
-
|
|
22843
|
-
|
|
22844
|
-
|
|
22845
|
-
|
|
22846
|
-
|
|
22847
|
-
|
|
22848
|
-
|
|
22849
|
-
|
|
22850
|
-
|
|
22851
|
-
|
|
22852
|
-
|
|
22853
|
-
|
|
22854
|
-
|
|
22855
|
-
|
|
22856
|
-
}
|
|
22938
|
+
/**
|
|
22939
|
+
* Create an Error with the specified message, config, error code, request and response.
|
|
22940
|
+
*
|
|
22941
|
+
* @param {string} message The error message.
|
|
22942
|
+
* @param {string} [code] The error code (for example, 'ECONNABORTED').
|
|
22943
|
+
* @param {Object} [config] The config.
|
|
22944
|
+
* @param {Object} [request] The request.
|
|
22945
|
+
* @param {Object} [response] The response.
|
|
22946
|
+
*
|
|
22947
|
+
* @returns {Error} The created error.
|
|
22948
|
+
*/
|
|
22949
|
+
constructor(message, code, config, request, response) {
|
|
22950
|
+
super(message);
|
|
22951
|
+
|
|
22952
|
+
// Make message enumerable to maintain backward compatibility
|
|
22953
|
+
// The native Error constructor sets message as non-enumerable,
|
|
22954
|
+
// but axios < v1.13.3 had it as enumerable
|
|
22955
|
+
Object.defineProperty(this, 'message', {
|
|
22956
|
+
value: message,
|
|
22957
|
+
enumerable: true,
|
|
22958
|
+
writable: true,
|
|
22959
|
+
configurable: true,
|
|
22960
|
+
});
|
|
22961
|
+
|
|
22962
|
+
this.name = 'AxiosError';
|
|
22963
|
+
this.isAxiosError = true;
|
|
22964
|
+
code && (this.code = code);
|
|
22965
|
+
config && (this.config = config);
|
|
22966
|
+
request && (this.request = request);
|
|
22967
|
+
if (response) {
|
|
22968
|
+
this.response = response;
|
|
22969
|
+
this.status = response.status;
|
|
22857
22970
|
}
|
|
22971
|
+
}
|
|
22858
22972
|
|
|
22859
22973
|
toJSON() {
|
|
22860
22974
|
return {
|
|
@@ -22890,6 +23004,7 @@ AxiosError.ERR_BAD_REQUEST = 'ERR_BAD_REQUEST';
|
|
|
22890
23004
|
AxiosError.ERR_CANCELED = 'ERR_CANCELED';
|
|
22891
23005
|
AxiosError.ERR_NOT_SUPPORT = 'ERR_NOT_SUPPORT';
|
|
22892
23006
|
AxiosError.ERR_INVALID_URL = 'ERR_INVALID_URL';
|
|
23007
|
+
AxiosError.ERR_FORM_DATA_DEPTH_EXCEEDED = 'ERR_FORM_DATA_DEPTH_EXCEEDED';
|
|
22893
23008
|
|
|
22894
23009
|
/* export default */ const __rspack_default_export = (AxiosError);
|
|
22895
23010
|
|
|
@@ -22910,16 +23025,49 @@ __webpack_require__.d(__webpack_exports__, {
|
|
|
22910
23025
|
|
|
22911
23026
|
const $internals = Symbol('internals');
|
|
22912
23027
|
|
|
23028
|
+
const INVALID_HEADER_VALUE_CHARS_RE = /[^\x09\x20-\x7E\x80-\xFF]/g;
|
|
23029
|
+
|
|
23030
|
+
function trimSPorHTAB(str) {
|
|
23031
|
+
let start = 0;
|
|
23032
|
+
let end = str.length;
|
|
23033
|
+
|
|
23034
|
+
while (start < end) {
|
|
23035
|
+
const code = str.charCodeAt(start);
|
|
23036
|
+
|
|
23037
|
+
if (code !== 0x09 && code !== 0x20) {
|
|
23038
|
+
break;
|
|
23039
|
+
}
|
|
23040
|
+
|
|
23041
|
+
start += 1;
|
|
23042
|
+
}
|
|
23043
|
+
|
|
23044
|
+
while (end > start) {
|
|
23045
|
+
const code = str.charCodeAt(end - 1);
|
|
23046
|
+
|
|
23047
|
+
if (code !== 0x09 && code !== 0x20) {
|
|
23048
|
+
break;
|
|
23049
|
+
}
|
|
23050
|
+
|
|
23051
|
+
end -= 1;
|
|
23052
|
+
}
|
|
23053
|
+
|
|
23054
|
+
return start === 0 && end === str.length ? str : str.slice(start, end);
|
|
23055
|
+
}
|
|
23056
|
+
|
|
22913
23057
|
function normalizeHeader(header) {
|
|
22914
23058
|
return header && String(header).trim().toLowerCase();
|
|
22915
23059
|
}
|
|
22916
23060
|
|
|
23061
|
+
function sanitizeHeaderValue(str) {
|
|
23062
|
+
return trimSPorHTAB(str.replace(INVALID_HEADER_VALUE_CHARS_RE, ''));
|
|
23063
|
+
}
|
|
23064
|
+
|
|
22917
23065
|
function normalizeValue(value) {
|
|
22918
23066
|
if (value === false || value == null) {
|
|
22919
23067
|
return value;
|
|
22920
23068
|
}
|
|
22921
23069
|
|
|
22922
|
-
return _utils_js__rspack_import_0["default"].isArray(value) ? value.map(normalizeValue) : String(value);
|
|
23070
|
+
return _utils_js__rspack_import_0["default"].isArray(value) ? value.map(normalizeValue) : sanitizeHeaderValue(String(value));
|
|
22923
23071
|
}
|
|
22924
23072
|
|
|
22925
23073
|
function parseTokens(str) {
|
|
@@ -23357,7 +23505,7 @@ __webpack_require__.d(__webpack_exports__, {
|
|
|
23357
23505
|
*/
|
|
23358
23506
|
function buildFullPath(baseURL, requestedURL, allowAbsoluteUrls) {
|
|
23359
23507
|
let isRelativeUrl = !(0,_helpers_isAbsoluteURL_js__rspack_import_0["default"])(requestedURL);
|
|
23360
|
-
if (baseURL && (isRelativeUrl || allowAbsoluteUrls
|
|
23508
|
+
if (baseURL && (isRelativeUrl || allowAbsoluteUrls === false)) {
|
|
23361
23509
|
return (0,_helpers_combineURLs_js__rspack_import_1["default"])(baseURL, requestedURL);
|
|
23362
23510
|
}
|
|
23363
23511
|
return requestedURL;
|
|
@@ -23523,9 +23671,9 @@ function mergeConfig(config1, config2) {
|
|
|
23523
23671
|
|
|
23524
23672
|
// eslint-disable-next-line consistent-return
|
|
23525
23673
|
function mergeDirectKeys(a, b, prop) {
|
|
23526
|
-
if (prop
|
|
23674
|
+
if (_utils_js__rspack_import_1["default"].hasOwnProp(config2, prop)) {
|
|
23527
23675
|
return getMergedValue(a, b);
|
|
23528
|
-
} else if (prop
|
|
23676
|
+
} else if (_utils_js__rspack_import_1["default"].hasOwnProp(config1, prop)) {
|
|
23529
23677
|
return getMergedValue(undefined, a);
|
|
23530
23678
|
}
|
|
23531
23679
|
}
|
|
@@ -23566,7 +23714,9 @@ function mergeConfig(config1, config2) {
|
|
|
23566
23714
|
_utils_js__rspack_import_1["default"].forEach(Object.keys({ ...config1, ...config2 }), function computeConfigValue(prop) {
|
|
23567
23715
|
if (prop === '__proto__' || prop === 'constructor' || prop === 'prototype') return;
|
|
23568
23716
|
const merge = _utils_js__rspack_import_1["default"].hasOwnProp(mergeMap, prop) ? mergeMap[prop] : mergeDeepProperties;
|
|
23569
|
-
const
|
|
23717
|
+
const a = _utils_js__rspack_import_1["default"].hasOwnProp(config1, prop) ? config1[prop] : undefined;
|
|
23718
|
+
const b = _utils_js__rspack_import_1["default"].hasOwnProp(config2, prop) ? config2[prop] : undefined;
|
|
23719
|
+
const configValue = merge(a, b, prop);
|
|
23570
23720
|
(_utils_js__rspack_import_1["default"].isUndefined(configValue) && merge !== mergeDirectKeys) || (config[prop] = configValue);
|
|
23571
23721
|
});
|
|
23572
23722
|
|
|
@@ -23679,6 +23829,8 @@ __webpack_require__.d(__webpack_exports__, {
|
|
|
23679
23829
|
|
|
23680
23830
|
|
|
23681
23831
|
|
|
23832
|
+
const own = (obj, key) => (obj != null && _utils_js__rspack_import_0["default"].hasOwnProp(obj, key) ? obj[key] : undefined);
|
|
23833
|
+
|
|
23682
23834
|
/**
|
|
23683
23835
|
* It takes a string, tries to parse it, and if it fails, it returns the stringified version
|
|
23684
23836
|
* of the input
|
|
@@ -23746,20 +23898,22 @@ const defaults = {
|
|
|
23746
23898
|
let isFileList;
|
|
23747
23899
|
|
|
23748
23900
|
if (isObjectPayload) {
|
|
23901
|
+
const formSerializer = own(this, 'formSerializer');
|
|
23749
23902
|
if (contentType.indexOf('application/x-www-form-urlencoded') > -1) {
|
|
23750
|
-
return (0,_helpers_toURLEncodedForm_js__rspack_import_3["default"])(data,
|
|
23903
|
+
return (0,_helpers_toURLEncodedForm_js__rspack_import_3["default"])(data, formSerializer).toString();
|
|
23751
23904
|
}
|
|
23752
23905
|
|
|
23753
23906
|
if (
|
|
23754
23907
|
(isFileList = _utils_js__rspack_import_0["default"].isFileList(data)) ||
|
|
23755
23908
|
contentType.indexOf('multipart/form-data') > -1
|
|
23756
23909
|
) {
|
|
23757
|
-
const
|
|
23910
|
+
const env = own(this, 'env');
|
|
23911
|
+
const _FormData = env && env.FormData;
|
|
23758
23912
|
|
|
23759
23913
|
return (0,_helpers_toFormData_js__rspack_import_4["default"])(
|
|
23760
23914
|
isFileList ? { 'files[]': data } : data,
|
|
23761
23915
|
_FormData && new _FormData(),
|
|
23762
|
-
|
|
23916
|
+
formSerializer
|
|
23763
23917
|
);
|
|
23764
23918
|
}
|
|
23765
23919
|
}
|
|
@@ -23775,9 +23929,10 @@ const defaults = {
|
|
|
23775
23929
|
|
|
23776
23930
|
transformResponse: [
|
|
23777
23931
|
function transformResponse(data) {
|
|
23778
|
-
const transitional = this
|
|
23932
|
+
const transitional = own(this, 'transitional') || defaults.transitional;
|
|
23779
23933
|
const forcedJSONParsing = transitional && transitional.forcedJSONParsing;
|
|
23780
|
-
const
|
|
23934
|
+
const responseType = own(this, 'responseType');
|
|
23935
|
+
const JSONRequested = responseType === 'json';
|
|
23781
23936
|
|
|
23782
23937
|
if (_utils_js__rspack_import_0["default"].isResponse(data) || _utils_js__rspack_import_0["default"].isReadableStream(data)) {
|
|
23783
23938
|
return data;
|
|
@@ -23786,17 +23941,17 @@ const defaults = {
|
|
|
23786
23941
|
if (
|
|
23787
23942
|
data &&
|
|
23788
23943
|
_utils_js__rspack_import_0["default"].isString(data) &&
|
|
23789
|
-
((forcedJSONParsing && !
|
|
23944
|
+
((forcedJSONParsing && !responseType) || JSONRequested)
|
|
23790
23945
|
) {
|
|
23791
23946
|
const silentJSONParsing = transitional && transitional.silentJSONParsing;
|
|
23792
23947
|
const strictJSONParsing = !silentJSONParsing && JSONRequested;
|
|
23793
23948
|
|
|
23794
23949
|
try {
|
|
23795
|
-
return JSON.parse(data, this
|
|
23950
|
+
return JSON.parse(data, own(this, 'parseReviver'));
|
|
23796
23951
|
} catch (e) {
|
|
23797
23952
|
if (strictJSONParsing) {
|
|
23798
23953
|
if (e.name === 'SyntaxError') {
|
|
23799
|
-
throw _core_AxiosError_js__rspack_import_5["default"].from(e, _core_AxiosError_js__rspack_import_5["default"].ERR_BAD_RESPONSE, this, null, this
|
|
23954
|
+
throw _core_AxiosError_js__rspack_import_5["default"].from(e, _core_AxiosError_js__rspack_import_5["default"].ERR_BAD_RESPONSE, this, null, own(this, 'response'));
|
|
23800
23955
|
}
|
|
23801
23956
|
throw e;
|
|
23802
23957
|
}
|
|
@@ -23867,7 +24022,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
23867
24022
|
__webpack_require__.d(__webpack_exports__, {
|
|
23868
24023
|
VERSION: () => (VERSION)
|
|
23869
24024
|
});
|
|
23870
|
-
const VERSION = "1.
|
|
24025
|
+
const VERSION = "1.15.1";
|
|
23871
24026
|
|
|
23872
24027
|
},
|
|
23873
24028
|
5267(__unused_rspack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
@@ -23897,9 +24052,8 @@ function encode(str) {
|
|
|
23897
24052
|
')': '%29',
|
|
23898
24053
|
'~': '%7E',
|
|
23899
24054
|
'%20': '+',
|
|
23900
|
-
'%00': '\x00',
|
|
23901
24055
|
};
|
|
23902
|
-
return encodeURIComponent(str).replace(/[!'()~]|%20
|
|
24056
|
+
return encodeURIComponent(str).replace(/[!'()~]|%20/g, function replacer(match) {
|
|
23903
24057
|
return charMap[match];
|
|
23904
24058
|
});
|
|
23905
24059
|
}
|
|
@@ -24065,8 +24219,8 @@ __webpack_require__.d(__webpack_exports__, {
|
|
|
24065
24219
|
|
|
24066
24220
|
|
|
24067
24221
|
/**
|
|
24068
|
-
* It replaces
|
|
24069
|
-
*
|
|
24222
|
+
* It replaces URL-encoded forms of `:`, `$`, `,`, and spaces with
|
|
24223
|
+
* their plain counterparts (`:`, `$`, `,`, `+`).
|
|
24070
24224
|
*
|
|
24071
24225
|
* @param {string} val The value to be encoded.
|
|
24072
24226
|
*
|
|
@@ -24346,7 +24500,9 @@ function formDataToJSON(formData) {
|
|
|
24346
24500
|
|
|
24347
24501
|
if (isLast) {
|
|
24348
24502
|
if (_utils_js__rspack_import_0["default"].hasOwnProp(target, name)) {
|
|
24349
|
-
target[name] = [target[name]
|
|
24503
|
+
target[name] = _utils_js__rspack_import_0["default"].isArray(target[name])
|
|
24504
|
+
? target[name].concat(value)
|
|
24505
|
+
: [target[name], value];
|
|
24350
24506
|
} else {
|
|
24351
24507
|
target[name] = value;
|
|
24352
24508
|
}
|
|
@@ -24587,13 +24743,13 @@ const progressEventReducer = (listener, isDownloadStream, freq = 3) => {
|
|
|
24587
24743
|
const _speedometer = (0,_speedometer_js__rspack_import_0["default"])(50, 250);
|
|
24588
24744
|
|
|
24589
24745
|
return (0,_throttle_js__rspack_import_1["default"])((e) => {
|
|
24590
|
-
const
|
|
24746
|
+
const rawLoaded = e.loaded;
|
|
24591
24747
|
const total = e.lengthComputable ? e.total : undefined;
|
|
24592
|
-
const
|
|
24748
|
+
const loaded = total != null ? Math.min(rawLoaded, total) : rawLoaded;
|
|
24749
|
+
const progressBytes = Math.max(0, loaded - bytesNotified);
|
|
24593
24750
|
const rate = _speedometer(progressBytes);
|
|
24594
|
-
const inRange = loaded <= total;
|
|
24595
24751
|
|
|
24596
|
-
bytesNotified = loaded;
|
|
24752
|
+
bytesNotified = Math.max(bytesNotified, loaded);
|
|
24597
24753
|
|
|
24598
24754
|
const data = {
|
|
24599
24755
|
loaded,
|
|
@@ -24601,7 +24757,7 @@ const progressEventReducer = (listener, isDownloadStream, freq = 3) => {
|
|
|
24601
24757
|
progress: total ? loaded / total : undefined,
|
|
24602
24758
|
bytes: progressBytes,
|
|
24603
24759
|
rate: rate ? rate : undefined,
|
|
24604
|
-
estimated: rate && total
|
|
24760
|
+
estimated: rate && total ? (total - loaded) / rate : undefined,
|
|
24605
24761
|
event: e,
|
|
24606
24762
|
lengthComputable: total != null,
|
|
24607
24763
|
[isDownloadStream ? 'download' : 'upload']: true,
|
|
@@ -24702,10 +24858,18 @@ __webpack_require__.d(__webpack_exports__, {
|
|
|
24702
24858
|
// Specifically not if we're in a web worker, or react-native.
|
|
24703
24859
|
|
|
24704
24860
|
if (_platform_index_js__rspack_import_5["default"].hasStandardBrowserEnv) {
|
|
24705
|
-
|
|
24861
|
+
if (_utils_js__rspack_import_4["default"].isFunction(withXSRFToken)) {
|
|
24862
|
+
withXSRFToken = withXSRFToken(newConfig);
|
|
24863
|
+
}
|
|
24706
24864
|
|
|
24707
|
-
|
|
24708
|
-
|
|
24865
|
+
// Strict boolean check — prevents proto-pollution gadgets (e.g. Object.prototype.withXSRFToken = 1)
|
|
24866
|
+
// and misconfigurations (e.g. "false") from short-circuiting the same-origin check and leaking
|
|
24867
|
+
// the XSRF token cross-origin. See GHSA-xx6v-rp6x-q39c.
|
|
24868
|
+
const shouldSendXSRF =
|
|
24869
|
+
withXSRFToken === true ||
|
|
24870
|
+
(withXSRFToken == null && (0,_isURLSameOrigin_js__rspack_import_6["default"])(newConfig.url));
|
|
24871
|
+
|
|
24872
|
+
if (shouldSendXSRF) {
|
|
24709
24873
|
const xsrfValue = xsrfHeaderName && xsrfCookieName && _cookies_js__rspack_import_7["default"].read(xsrfCookieName);
|
|
24710
24874
|
|
|
24711
24875
|
if (xsrfValue) {
|
|
@@ -25000,6 +25164,7 @@ function toFormData(obj, formData, options) {
|
|
|
25000
25164
|
const dots = options.dots;
|
|
25001
25165
|
const indexes = options.indexes;
|
|
25002
25166
|
const _Blob = options.Blob || (typeof Blob !== 'undefined' && Blob);
|
|
25167
|
+
const maxDepth = options.maxDepth === undefined ? 100 : options.maxDepth;
|
|
25003
25168
|
const useBlob = _Blob && _utils_js__rspack_import_0["default"].isSpecCompliantForm(formData);
|
|
25004
25169
|
|
|
25005
25170
|
if (!_utils_js__rspack_import_0["default"].isFunction(visitor)) {
|
|
@@ -25092,9 +25257,16 @@ function toFormData(obj, formData, options) {
|
|
|
25092
25257
|
isVisitable,
|
|
25093
25258
|
});
|
|
25094
25259
|
|
|
25095
|
-
function build(value, path) {
|
|
25260
|
+
function build(value, path, depth = 0) {
|
|
25096
25261
|
if (_utils_js__rspack_import_0["default"].isUndefined(value)) return;
|
|
25097
25262
|
|
|
25263
|
+
if (depth > maxDepth) {
|
|
25264
|
+
throw new _core_AxiosError_js__rspack_import_2["default"](
|
|
25265
|
+
'Object is too deeply nested (' + depth + ' levels). Max depth: ' + maxDepth,
|
|
25266
|
+
_core_AxiosError_js__rspack_import_2["default"].ERR_FORM_DATA_DEPTH_EXCEEDED
|
|
25267
|
+
);
|
|
25268
|
+
}
|
|
25269
|
+
|
|
25098
25270
|
if (stack.indexOf(value) !== -1) {
|
|
25099
25271
|
throw Error('Circular reference detected in ' + path.join('.'));
|
|
25100
25272
|
}
|
|
@@ -25107,7 +25279,7 @@ function toFormData(obj, formData, options) {
|
|
|
25107
25279
|
visitor.call(formData, el, _utils_js__rspack_import_0["default"].isString(key) ? key.trim() : key, path, exposedHelpers);
|
|
25108
25280
|
|
|
25109
25281
|
if (result === true) {
|
|
25110
|
-
build(el, path ? path.concat(key) : [key]);
|
|
25282
|
+
build(el, path ? path.concat(key) : [key], depth + 1);
|
|
25111
25283
|
}
|
|
25112
25284
|
});
|
|
25113
25285
|
|
|
@@ -25786,16 +25958,16 @@ const G = getGlobal();
|
|
|
25786
25958
|
const FormDataCtor = typeof G.FormData !== 'undefined' ? G.FormData : undefined;
|
|
25787
25959
|
|
|
25788
25960
|
const isFormData = (thing) => {
|
|
25789
|
-
|
|
25790
|
-
|
|
25791
|
-
|
|
25792
|
-
|
|
25793
|
-
|
|
25794
|
-
|
|
25795
|
-
|
|
25796
|
-
|
|
25797
|
-
|
|
25798
|
-
|
|
25961
|
+
if (!thing) return false;
|
|
25962
|
+
if (FormDataCtor && thing instanceof FormDataCtor) return true;
|
|
25963
|
+
// Reject plain objects inheriting directly from Object.prototype so prototype-pollution gadgets can't spoof FormData (GHSA-6chq-wfr3-2hj9).
|
|
25964
|
+
const proto = getPrototypeOf(thing);
|
|
25965
|
+
if (!proto || proto === Object.prototype) return false;
|
|
25966
|
+
if (!isFunction(thing.append)) return false;
|
|
25967
|
+
const kind = kindOf(thing);
|
|
25968
|
+
return kind === 'formdata' ||
|
|
25969
|
+
// detect form-data instance
|
|
25970
|
+
(kind === 'object' && isFunction(thing.toString) && thing.toString() === '[object FormData]');
|
|
25799
25971
|
};
|
|
25800
25972
|
|
|
25801
25973
|
/**
|
|
@@ -26451,7 +26623,7 @@ const isIterable = (thing) => thing != null && isFunction(thing[iterator]);
|
|
|
26451
26623
|
},
|
|
26452
26624
|
8330(module) {
|
|
26453
26625
|
"use strict";
|
|
26454
|
-
module.exports = JSON.parse('{"name":"apify-client","version":"2.
|
|
26626
|
+
module.exports = JSON.parse('{"name":"apify-client","version":"2.23.1-beta.0","description":"Apify API client for JavaScript","main":"dist/index.js","module":"dist/index.mjs","types":"dist/index.d.ts","browser":"dist/bundle.js","unpkg":"dist/bundle.js","exports":{"./package.json":"./package.json","./browser":"./dist/bundle.js",".":{"import":"./dist/index.mjs","require":"./dist/index.js","types":"./dist/index.d.ts","browser":"./dist/bundle.js"}},"keywords":["apify","api","apifier","crawler","scraper"],"author":{"name":"Apify","email":"support@apify.com","url":"https://apify.com"},"contributors":["Jan Curn <jan@apify.com>","Marek Trunkát <marek@apify.com>","Ondra Urban <ondra@apify.com>","Jakub Drobník <jakub.drobnik@apify.com>"],"license":"Apache-2.0","repository":{"type":"git","url":"git+https://github.com/apify/apify-client-js"},"bugs":{"url":"https://github.com/apify/apify-client-js/issues"},"homepage":"https://docs.apify.com/api/client/js/","files":["dist","!dist/*.tsbuildinfo"],"scripts":{"build":"npm run clean && npm run build:node && npm run build:browser","postbuild":"gen-esm-wrapper dist/index.js dist/index.mjs","prepublishOnly":"(test $CI || (echo \\"Publishing is reserved to CI!\\"; exit 1))","clean":"rimraf dist","test":"npm run build && vitest run","test:bundling":"npm run build && npm --prefix=./test/bundling run bundle:all","lint":"eslint","lint:fix":"eslint --fix","tsc-check-tests":"tsc --noEmit --project test/tsconfig.json","format":"prettier --write .","format:check":"prettier --check .","build:node":"tsc","build:browser":"rsbuild build"},"dependencies":{"@apify/consts":"^2.50.0","@apify/log":"^2.2.6","@apify/utilities":"^2.23.2","@crawlee/types":"^3.3.0","ansi-colors":"^4.1.1","async-retry":"^1.3.3","axios":"^1.6.7","content-type":"^1.0.5","ow":"^0.28.2","proxy-agent":"^6.5.0","tslib":"^2.5.0","type-fest":"^4.0.0"},"devDependencies":{"@apify/eslint-config":"^1.0.0","@apify/tsconfig":"^0.1.1","@crawlee/puppeteer":"^3.2.2","@rsbuild/core":"^1.3.6","@rsbuild/plugin-node-polyfill":"^1.3.0","@rspack/cli":"^1.7.6","@rspack/core":"^1.7.6","@stylistic/eslint-plugin-ts":"^4.2.0","@types/async-retry":"^1.4.5","@types/compression":"^1.8.1","@types/content-type":"^1.1.5","@types/express":"^5.0.0","@types/node":"^24.0.0","ajv":"^8.17.1","body-parser":"^2.0.0","compression":"^1.7.4","esbuild":"0.27.4","eslint":"^9.24.0","eslint-config-prettier":"^10.1.2","express":"^5.0.0","gen-esm-wrapper":"^1.1.2","globals":"^17.0.0","prettier":"^3.5.3","puppeteer":"^24.0.0","rimraf":"^6.0.0","rolldown":"^1.0.0-rc.4","typescript":"^5.8.3","typescript-eslint":"^8.29.1","vitest":"^4.0.16","webpack":"^5.105.2","webpack-cli":"^7.0.0"},"packageManager":"npm@10.9.2"}')
|
|
26455
26627
|
|
|
26456
26628
|
},
|
|
26457
26629
|
|