diff --git a/.github/workflows/check.yaml b/.github/workflows/check.yaml index a12a6c98..d7217b11 100644 --- a/.github/workflows/check.yaml +++ b/.github/workflows/check.yaml @@ -30,10 +30,13 @@ jobs: run: npm ci - name: Lint - run: npm run lint + run: npm run lint:fix - name: Build run: npm run build - name: Test run: npm run test + + - name: Type checks + run: npm run type-check diff --git a/.nvmrc b/.nvmrc new file mode 100644 index 00000000..d5b283a3 --- /dev/null +++ b/.nvmrc @@ -0,0 +1 @@ +22.13.1 diff --git a/eslint.config.mjs b/eslint.config.mjs index ffe1b904..fb9cd123 100644 --- a/eslint.config.mjs +++ b/eslint.config.mjs @@ -1,9 +1,9 @@ -import apify from '@apify/eslint-config'; +import apifyTypeScriptConfig from '@apify/eslint-config/ts.js'; // eslint-disable-next-line import/no-default-export export default [ - { ignores: ['**/dist', '**/.venv'] }, // Ignores need to happen first - ...apify, + { ignores: ['**/dist'] }, // Ignores need to happen first + ...apifyTypeScriptConfig, { languageOptions: { sourceType: 'module', diff --git a/package-lock.json b/package-lock.json index af1da43b..8369b555 100644 --- a/package-lock.json +++ b/package-lock.json @@ -10,7 +10,7 @@ "license": "MIT", "dependencies": { "@apify/log": "^2.5.16", - "@modelcontextprotocol/sdk": "^1.9.0", + "@modelcontextprotocol/sdk": "github:jirispilka/mcp-typescript-sdk#fix/add-src-dir", "ajv": "^8.17.1", "apify": "^3.4.0", "apify-client": "^2.12.1", @@ -69,9 +69,9 @@ } }, "node_modules/@apify/consts": { - "version": "2.39.0", - "resolved": "https://registry.npmjs.org/@apify/consts/-/consts-2.39.0.tgz", - "integrity": "sha512-rO9+uzv7kP5XNiz8K+cYcgDmLPK9WZQ9Xlg2VEa2YB5MXDVcBnStdZm4loX/vPPpAGK5ztQnpBnYlA8PURBcXQ==", + "version": "2.40.0", + "resolved": "https://registry.npmjs.org/@apify/consts/-/consts-2.40.0.tgz", + "integrity": "sha512-2coaQ97ddsQ4+QRybqGbPE4irqfmkSaUPlbUPQvIcmT+PLdFT1t1iSU61Yy2T1UW5wN3K6UDAqFWNIqxxb0apg==", "license": "Apache-2.0" }, "node_modules/@apify/datastructures": { @@ -109,23 +109,23 @@ } }, "node_modules/@apify/input_secrets": { - "version": "1.1.70", - "resolved": "https://registry.npmjs.org/@apify/input_secrets/-/input_secrets-1.1.70.tgz", - "integrity": "sha512-fKuNdeYCMIwz5GxBydI+uu/cOnSye1l39SJcZ5FA38knpQHURZxSpYbtLcb98/MOUuzKOSCQvIbPyx1OwO1Pxg==", + "version": "1.1.71", + "resolved": "https://registry.npmjs.org/@apify/input_secrets/-/input_secrets-1.1.71.tgz", + "integrity": "sha512-vLdbRNZkVAOpgqHtho+AGIgWLgaeB4fV2B43oPm9pDbdX+Iv5X+04OM8Gh/X/Gcxs4ssdVXgb/hRy0uDxVa/Uw==", "license": "Apache-2.0", "dependencies": { - "@apify/log": "^2.5.16", - "@apify/utilities": "^2.15.3", + "@apify/log": "^2.5.17", + "@apify/utilities": "^2.15.4", "ow": "^0.28.2" } }, "node_modules/@apify/log": { - "version": "2.5.16", - "resolved": "https://registry.npmjs.org/@apify/log/-/log-2.5.16.tgz", - "integrity": "sha512-/kZJN/vs80yRpihcLxG2kLj45f6stky4RUIC1ea5Vmkb0i6Zv1l/sUqDLBimZMaQkSDCxM1j+Yhc5QaPlgJZrg==", + "version": "2.5.17", + "resolved": "https://registry.npmjs.org/@apify/log/-/log-2.5.17.tgz", + "integrity": "sha512-1L/iiHRxyc8e0EuFfZ1raZLWC4mQYrTPy9JzF1hwwhsRSlyHNFQrfNzF0vbF3/8XpLwEBSasAA3fclQhDbUn/Q==", "license": "Apache-2.0", "dependencies": { - "@apify/consts": "^2.39.0", + "@apify/consts": "^2.40.0", "ansi-colors": "^4.1.1" } }, @@ -145,12 +145,12 @@ } }, "node_modules/@apify/pseudo_url": { - "version": "2.0.57", - "resolved": "https://registry.npmjs.org/@apify/pseudo_url/-/pseudo_url-2.0.57.tgz", - "integrity": "sha512-5LJBocbpBYE9vfb6UDqcqAq3azC0b2PHxRXRz8JFGU4qt7o3Gzi4p16lImZ2qy9/x3plWYWxbYsewX5aH/aamA==", + "version": "2.0.58", + "resolved": "https://registry.npmjs.org/@apify/pseudo_url/-/pseudo_url-2.0.58.tgz", + "integrity": "sha512-a0F94mEhwZJe6UUO3JGVbvufNqSQkP3uc0nLAAJA7Bydwe5PMRrWGLQ8+/EW8pEnrYCFVTuI9+uXtJideQpinA==", "license": "Apache-2.0", "dependencies": { - "@apify/log": "^2.5.16" + "@apify/log": "^2.5.17" } }, "node_modules/@apify/timeout": { @@ -160,20 +160,20 @@ "license": "Apache-2.0" }, "node_modules/@apify/tsconfig": { - "version": "0.1.0", - "resolved": "https://registry.npmjs.org/@apify/tsconfig/-/tsconfig-0.1.0.tgz", - "integrity": "sha512-ba9Y6AMocRucO3AVTb6GM2V+oy1wByNlCDzamK+IC+aqU3pCgJwSN87uNu6iEgu+uetsqYvVbXJYakwiQO1LGA==", + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/@apify/tsconfig/-/tsconfig-0.1.1.tgz", + "integrity": "sha512-cS7mwN2UW1UXcluGXRDHH0Vr2VsSLkw2DwLTwoSBkcJSe8fvCr3MPryTSq0uod4MashpMURxJ7CsLKxs82VmOQ==", "dev": true, "license": "Apache-2.0" }, "node_modules/@apify/utilities": { - "version": "2.15.3", - "resolved": "https://registry.npmjs.org/@apify/utilities/-/utilities-2.15.3.tgz", - "integrity": "sha512-jCyZ3ZhosjHSnaPND6l9/gPp0y+bH3G+Gz+/eIFRMXE418T9me0X828Ua2sCROcj/TrNg+1DZbdE3GWqOMdyuw==", + "version": "2.15.4", + "resolved": "https://registry.npmjs.org/@apify/utilities/-/utilities-2.15.4.tgz", + "integrity": "sha512-uM1kLJAE3bnDApGPqdD0xWeo/2HCE9KyAxeBdtRNaHVOu8DvRf8ioOlif75AZbMCXCo3g0zNmkznjtR6hrglJw==", "license": "Apache-2.0", "dependencies": { - "@apify/consts": "^2.39.0", - "@apify/log": "^2.5.16" + "@apify/consts": "^2.40.0", + "@apify/log": "^2.5.17" } }, "node_modules/@crawlee/core": { @@ -715,9 +715,9 @@ } }, "node_modules/@eslint-community/eslint-utils": { - "version": "4.5.1", - "resolved": "https://registry.npmjs.org/@eslint-community/eslint-utils/-/eslint-utils-4.5.1.tgz", - "integrity": "sha512-soEIOALTfTK6EjmKMMoLugwaP0rzkad90iIWd1hMO9ARkSAyjfMfkRRhLvD5qH7vvM0Cg72pieUfR6yh6XxC4w==", + "version": "4.6.0", + "resolved": "https://registry.npmjs.org/@eslint-community/eslint-utils/-/eslint-utils-4.6.0.tgz", + "integrity": "sha512-WhCn7Z7TauhBtmzhvKpoQs0Wwb/kBcy4CwpuI0/eEIr2Lx2auxmulAzLr91wVZJaz47iUZdkXOK7WlAfxGKCnA==", "dev": true, "license": "MIT", "dependencies": { @@ -1064,9 +1064,8 @@ "license": "MIT" }, "node_modules/@modelcontextprotocol/sdk": { - "version": "1.9.0", - "resolved": "https://registry.npmjs.org/@modelcontextprotocol/sdk/-/sdk-1.9.0.tgz", - "integrity": "sha512-Jq2EUCQpe0iyO5FGpzVYDNFR6oR53AIrwph9yWl7uSc7IWUMsrmpmSaTGra5hQNunXpM+9oit85p924jWuHzUA==", + "version": "1.10.0", + "resolved": "git+ssh://git@github.com/jirispilka/mcp-typescript-sdk.git#4ae4b33f263ec0ab157eb5f541c69ba01cbf2822", "license": "MIT", "dependencies": { "content-type": "^1.0.5", @@ -1391,9 +1390,9 @@ } }, "node_modules/@rollup/rollup-android-arm-eabi": { - "version": "4.39.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm-eabi/-/rollup-android-arm-eabi-4.39.0.tgz", - "integrity": "sha512-lGVys55Qb00Wvh8DMAocp5kIcaNzEFTmGhfFd88LfaogYTRKrdxgtlO5H6S49v2Nd8R2C6wLOal0qv6/kCkOwA==", + "version": "4.40.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm-eabi/-/rollup-android-arm-eabi-4.40.0.tgz", + "integrity": "sha512-+Fbls/diZ0RDerhE8kyC6hjADCXA1K4yVNlH0EYfd2XjyH0UGgzaQ8MlT0pCXAThfxv3QUAczHaL+qSv1E4/Cg==", "cpu": [ "arm" ], @@ -1405,9 +1404,9 @@ ] }, "node_modules/@rollup/rollup-android-arm64": { - "version": "4.39.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm64/-/rollup-android-arm64-4.39.0.tgz", - "integrity": "sha512-It9+M1zE31KWfqh/0cJLrrsCPiF72PoJjIChLX+rEcujVRCb4NLQ5QzFkzIZW8Kn8FTbvGQBY5TkKBau3S8cCQ==", + "version": "4.40.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm64/-/rollup-android-arm64-4.40.0.tgz", + "integrity": "sha512-PPA6aEEsTPRz+/4xxAmaoWDqh67N7wFbgFUJGMnanCFs0TV99M0M8QhhaSCks+n6EbQoFvLQgYOGXxlMGQe/6w==", "cpu": [ "arm64" ], @@ -1419,9 +1418,9 @@ ] }, "node_modules/@rollup/rollup-darwin-arm64": { - "version": "4.39.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-arm64/-/rollup-darwin-arm64-4.39.0.tgz", - "integrity": "sha512-lXQnhpFDOKDXiGxsU9/l8UEGGM65comrQuZ+lDcGUx+9YQ9dKpF3rSEGepyeR5AHZ0b5RgiligsBhWZfSSQh8Q==", + "version": "4.40.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-arm64/-/rollup-darwin-arm64-4.40.0.tgz", + "integrity": "sha512-GwYOcOakYHdfnjjKwqpTGgn5a6cUX7+Ra2HeNj/GdXvO2VJOOXCiYYlRFU4CubFM67EhbmzLOmACKEfvp3J1kQ==", "cpu": [ "arm64" ], @@ -1433,9 +1432,9 @@ ] }, "node_modules/@rollup/rollup-darwin-x64": { - "version": "4.39.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-x64/-/rollup-darwin-x64-4.39.0.tgz", - "integrity": "sha512-mKXpNZLvtEbgu6WCkNij7CGycdw9cJi2k9v0noMb++Vab12GZjFgUXD69ilAbBh034Zwn95c2PNSz9xM7KYEAQ==", + "version": "4.40.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-x64/-/rollup-darwin-x64-4.40.0.tgz", + "integrity": "sha512-CoLEGJ+2eheqD9KBSxmma6ld01czS52Iw0e2qMZNpPDlf7Z9mj8xmMemxEucinev4LgHalDPczMyxzbq+Q+EtA==", "cpu": [ "x64" ], @@ -1447,9 +1446,9 @@ ] }, "node_modules/@rollup/rollup-freebsd-arm64": { - "version": "4.39.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-arm64/-/rollup-freebsd-arm64-4.39.0.tgz", - "integrity": "sha512-jivRRlh2Lod/KvDZx2zUR+I4iBfHcu2V/BA2vasUtdtTN2Uk3jfcZczLa81ESHZHPHy4ih3T/W5rPFZ/hX7RtQ==", + "version": "4.40.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-arm64/-/rollup-freebsd-arm64-4.40.0.tgz", + "integrity": "sha512-r7yGiS4HN/kibvESzmrOB/PxKMhPTlz+FcGvoUIKYoTyGd5toHp48g1uZy1o1xQvybwwpqpe010JrcGG2s5nkg==", "cpu": [ "arm64" ], @@ -1461,9 +1460,9 @@ ] }, "node_modules/@rollup/rollup-freebsd-x64": { - "version": "4.39.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-x64/-/rollup-freebsd-x64-4.39.0.tgz", - "integrity": "sha512-8RXIWvYIRK9nO+bhVz8DwLBepcptw633gv/QT4015CpJ0Ht8punmoHU/DuEd3iw9Hr8UwUV+t+VNNuZIWYeY7Q==", + "version": "4.40.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-x64/-/rollup-freebsd-x64-4.40.0.tgz", + "integrity": "sha512-mVDxzlf0oLzV3oZOr0SMJ0lSDd3xC4CmnWJ8Val8isp9jRGl5Dq//LLDSPFrasS7pSm6m5xAcKaw3sHXhBjoRw==", "cpu": [ "x64" ], @@ -1475,9 +1474,9 @@ ] }, "node_modules/@rollup/rollup-linux-arm-gnueabihf": { - "version": "4.39.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-gnueabihf/-/rollup-linux-arm-gnueabihf-4.39.0.tgz", - "integrity": "sha512-mz5POx5Zu58f2xAG5RaRRhp3IZDK7zXGk5sdEDj4o96HeaXhlUwmLFzNlc4hCQi5sGdR12VDgEUqVSHer0lI9g==", + "version": "4.40.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-gnueabihf/-/rollup-linux-arm-gnueabihf-4.40.0.tgz", + "integrity": "sha512-y/qUMOpJxBMy8xCXD++jeu8t7kzjlOCkoxxajL58G62PJGBZVl/Gwpm7JK9+YvlB701rcQTzjUZ1JgUoPTnoQA==", "cpu": [ "arm" ], @@ -1489,9 +1488,9 @@ ] }, "node_modules/@rollup/rollup-linux-arm-musleabihf": { - "version": "4.39.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-musleabihf/-/rollup-linux-arm-musleabihf-4.39.0.tgz", - "integrity": "sha512-+YDwhM6gUAyakl0CD+bMFpdmwIoRDzZYaTWV3SDRBGkMU/VpIBYXXEvkEcTagw/7VVkL2vA29zU4UVy1mP0/Yw==", + "version": "4.40.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-musleabihf/-/rollup-linux-arm-musleabihf-4.40.0.tgz", + "integrity": "sha512-GoCsPibtVdJFPv/BOIvBKO/XmwZLwaNWdyD8TKlXuqp0veo2sHE+A/vpMQ5iSArRUz/uaoj4h5S6Pn0+PdhRjg==", "cpu": [ "arm" ], @@ -1503,9 +1502,9 @@ ] }, "node_modules/@rollup/rollup-linux-arm64-gnu": { - "version": "4.39.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-gnu/-/rollup-linux-arm64-gnu-4.39.0.tgz", - "integrity": "sha512-EKf7iF7aK36eEChvlgxGnk7pdJfzfQbNvGV/+l98iiMwU23MwvmV0Ty3pJ0p5WQfm3JRHOytSIqD9LB7Bq7xdQ==", + "version": "4.40.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-gnu/-/rollup-linux-arm64-gnu-4.40.0.tgz", + "integrity": "sha512-L5ZLphTjjAD9leJzSLI7rr8fNqJMlGDKlazW2tX4IUF9P7R5TMQPElpH82Q7eNIDQnQlAyiNVfRPfP2vM5Avvg==", "cpu": [ "arm64" ], @@ -1517,9 +1516,9 @@ ] }, "node_modules/@rollup/rollup-linux-arm64-musl": { - "version": "4.39.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-musl/-/rollup-linux-arm64-musl-4.39.0.tgz", - "integrity": "sha512-vYanR6MtqC7Z2SNr8gzVnzUul09Wi1kZqJaek3KcIlI/wq5Xtq4ZPIZ0Mr/st/sv/NnaPwy/D4yXg5x0B3aUUA==", + "version": "4.40.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-musl/-/rollup-linux-arm64-musl-4.40.0.tgz", + "integrity": "sha512-ATZvCRGCDtv1Y4gpDIXsS+wfFeFuLwVxyUBSLawjgXK2tRE6fnsQEkE4csQQYWlBlsFztRzCnBvWVfcae/1qxQ==", "cpu": [ "arm64" ], @@ -1531,9 +1530,9 @@ ] }, "node_modules/@rollup/rollup-linux-loongarch64-gnu": { - "version": "4.39.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-loongarch64-gnu/-/rollup-linux-loongarch64-gnu-4.39.0.tgz", - "integrity": "sha512-NMRUT40+h0FBa5fb+cpxtZoGAggRem16ocVKIv5gDB5uLDgBIwrIsXlGqYbLwW8YyO3WVTk1FkFDjMETYlDqiw==", + "version": "4.40.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-loongarch64-gnu/-/rollup-linux-loongarch64-gnu-4.40.0.tgz", + "integrity": "sha512-wG9e2XtIhd++QugU5MD9i7OnpaVb08ji3P1y/hNbxrQ3sYEelKJOq1UJ5dXczeo6Hj2rfDEL5GdtkMSVLa/AOg==", "cpu": [ "loong64" ], @@ -1545,9 +1544,9 @@ ] }, "node_modules/@rollup/rollup-linux-powerpc64le-gnu": { - "version": "4.39.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-powerpc64le-gnu/-/rollup-linux-powerpc64le-gnu-4.39.0.tgz", - "integrity": "sha512-0pCNnmxgduJ3YRt+D+kJ6Ai/r+TaePu9ZLENl+ZDV/CdVczXl95CbIiwwswu4L+K7uOIGf6tMo2vm8uadRaICQ==", + "version": "4.40.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-powerpc64le-gnu/-/rollup-linux-powerpc64le-gnu-4.40.0.tgz", + "integrity": "sha512-vgXfWmj0f3jAUvC7TZSU/m/cOE558ILWDzS7jBhiCAFpY2WEBn5jqgbqvmzlMjtp8KlLcBlXVD2mkTSEQE6Ixw==", "cpu": [ "ppc64" ], @@ -1559,9 +1558,9 @@ ] }, "node_modules/@rollup/rollup-linux-riscv64-gnu": { - "version": "4.39.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-gnu/-/rollup-linux-riscv64-gnu-4.39.0.tgz", - "integrity": "sha512-t7j5Zhr7S4bBtksT73bO6c3Qa2AV/HqiGlj9+KB3gNF5upcVkx+HLgxTm8DK4OkzsOYqbdqbLKwvGMhylJCPhQ==", + "version": "4.40.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-gnu/-/rollup-linux-riscv64-gnu-4.40.0.tgz", + "integrity": "sha512-uJkYTugqtPZBS3Z136arevt/FsKTF/J9dEMTX/cwR7lsAW4bShzI2R0pJVw+hcBTWF4dxVckYh72Hk3/hWNKvA==", "cpu": [ "riscv64" ], @@ -1573,9 +1572,9 @@ ] }, "node_modules/@rollup/rollup-linux-riscv64-musl": { - "version": "4.39.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-musl/-/rollup-linux-riscv64-musl-4.39.0.tgz", - "integrity": "sha512-m6cwI86IvQ7M93MQ2RF5SP8tUjD39Y7rjb1qjHgYh28uAPVU8+k/xYWvxRO3/tBN2pZkSMa5RjnPuUIbrwVxeA==", + "version": "4.40.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-musl/-/rollup-linux-riscv64-musl-4.40.0.tgz", + "integrity": "sha512-rKmSj6EXQRnhSkE22+WvrqOqRtk733x3p5sWpZilhmjnkHkpeCgWsFFo0dGnUGeA+OZjRl3+VYq+HyCOEuwcxQ==", "cpu": [ "riscv64" ], @@ -1587,9 +1586,9 @@ ] }, "node_modules/@rollup/rollup-linux-s390x-gnu": { - "version": "4.39.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-s390x-gnu/-/rollup-linux-s390x-gnu-4.39.0.tgz", - "integrity": "sha512-iRDJd2ebMunnk2rsSBYlsptCyuINvxUfGwOUldjv5M4tpa93K8tFMeYGpNk2+Nxl+OBJnBzy2/JCscGeO507kA==", + "version": "4.40.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-s390x-gnu/-/rollup-linux-s390x-gnu-4.40.0.tgz", + "integrity": "sha512-SpnYlAfKPOoVsQqmTFJ0usx0z84bzGOS9anAC0AZ3rdSo3snecihbhFTlJZ8XMwzqAcodjFU4+/SM311dqE5Sw==", "cpu": [ "s390x" ], @@ -1601,9 +1600,9 @@ ] }, "node_modules/@rollup/rollup-linux-x64-gnu": { - "version": "4.39.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-gnu/-/rollup-linux-x64-gnu-4.39.0.tgz", - "integrity": "sha512-t9jqYw27R6Lx0XKfEFe5vUeEJ5pF3SGIM6gTfONSMb7DuG6z6wfj2yjcoZxHg129veTqU7+wOhY6GX8wmf90dA==", + "version": "4.40.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-gnu/-/rollup-linux-x64-gnu-4.40.0.tgz", + "integrity": "sha512-RcDGMtqF9EFN8i2RYN2W+64CdHruJ5rPqrlYw+cgM3uOVPSsnAQps7cpjXe9be/yDp8UC7VLoCoKC8J3Kn2FkQ==", "cpu": [ "x64" ], @@ -1615,9 +1614,9 @@ ] }, "node_modules/@rollup/rollup-linux-x64-musl": { - "version": "4.39.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-musl/-/rollup-linux-x64-musl-4.39.0.tgz", - "integrity": "sha512-ThFdkrFDP55AIsIZDKSBWEt/JcWlCzydbZHinZ0F/r1h83qbGeenCt/G/wG2O0reuENDD2tawfAj2s8VK7Bugg==", + "version": "4.40.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-musl/-/rollup-linux-x64-musl-4.40.0.tgz", + "integrity": "sha512-HZvjpiUmSNx5zFgwtQAV1GaGazT2RWvqeDi0hV+AtC8unqqDSsaFjPxfsO6qPtKRRg25SisACWnJ37Yio8ttaw==", "cpu": [ "x64" ], @@ -1629,9 +1628,9 @@ ] }, "node_modules/@rollup/rollup-win32-arm64-msvc": { - "version": "4.39.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-arm64-msvc/-/rollup-win32-arm64-msvc-4.39.0.tgz", - "integrity": "sha512-jDrLm6yUtbOg2TYB3sBF3acUnAwsIksEYjLeHL+TJv9jg+TmTwdyjnDex27jqEMakNKf3RwwPahDIt7QXCSqRQ==", + "version": "4.40.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-arm64-msvc/-/rollup-win32-arm64-msvc-4.40.0.tgz", + "integrity": "sha512-UtZQQI5k/b8d7d3i9AZmA/t+Q4tk3hOC0tMOMSq2GlMYOfxbesxG4mJSeDp0EHs30N9bsfwUvs3zF4v/RzOeTQ==", "cpu": [ "arm64" ], @@ -1643,9 +1642,9 @@ ] }, "node_modules/@rollup/rollup-win32-ia32-msvc": { - "version": "4.39.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-ia32-msvc/-/rollup-win32-ia32-msvc-4.39.0.tgz", - "integrity": "sha512-6w9uMuza+LbLCVoNKL5FSLE7yvYkq9laSd09bwS0tMjkwXrmib/4KmoJcrKhLWHvw19mwU+33ndC69T7weNNjQ==", + "version": "4.40.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-ia32-msvc/-/rollup-win32-ia32-msvc-4.40.0.tgz", + "integrity": "sha512-+m03kvI2f5syIqHXCZLPVYplP8pQch9JHyXKZ3AGMKlg8dCyr2PKHjwRLiW53LTrN/Nc3EqHOKxUxzoSPdKddA==", "cpu": [ "ia32" ], @@ -1657,9 +1656,9 @@ ] }, "node_modules/@rollup/rollup-win32-x64-msvc": { - "version": "4.39.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-msvc/-/rollup-win32-x64-msvc-4.39.0.tgz", - "integrity": "sha512-yAkUOkIKZlK5dl7u6dg897doBgLXmUHhIINM2c+sND3DZwnrdQkkSiDh7N75Ll4mM4dxSkYfXqU9fW3lLkMFug==", + "version": "4.40.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-msvc/-/rollup-win32-x64-msvc-4.40.0.tgz", + "integrity": "sha512-lpPE1cLfP5oPzVjKMx10pgBmKELQnFJXHgvtHCtuJWOv8MxqdEIMNtgHgBFf7Ea2/7EuVwa9fodWUfXAlXZLZQ==", "cpu": [ "x64" ], @@ -1933,17 +1932,17 @@ } }, "node_modules/@typescript-eslint/eslint-plugin": { - "version": "8.29.1", - "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-8.29.1.tgz", - "integrity": "sha512-ba0rr4Wfvg23vERs3eB+P3lfj2E+2g3lhWcCVukUuhtcdUx5lSIFZlGFEBHKr+3zizDa/TvZTptdNHVZWAkSBg==", + "version": "8.30.1", + "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-8.30.1.tgz", + "integrity": "sha512-v+VWphxMjn+1t48/jO4t950D6KR8JaJuNXzi33Ve6P8sEmPr5k6CEXjdGwT6+LodVnEa91EQCtwjWNUCPweo+Q==", "dev": true, "license": "MIT", "dependencies": { "@eslint-community/regexpp": "^4.10.0", - "@typescript-eslint/scope-manager": "8.29.1", - "@typescript-eslint/type-utils": "8.29.1", - "@typescript-eslint/utils": "8.29.1", - "@typescript-eslint/visitor-keys": "8.29.1", + "@typescript-eslint/scope-manager": "8.30.1", + "@typescript-eslint/type-utils": "8.30.1", + "@typescript-eslint/utils": "8.30.1", + "@typescript-eslint/visitor-keys": "8.30.1", "graphemer": "^1.4.0", "ignore": "^5.3.1", "natural-compare": "^1.4.0", @@ -1963,16 +1962,16 @@ } }, "node_modules/@typescript-eslint/parser": { - "version": "8.29.1", - "resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-8.29.1.tgz", - "integrity": "sha512-zczrHVEqEaTwh12gWBIJWj8nx+ayDcCJs06yoNMY0kwjMWDM6+kppljY+BxWI06d2Ja+h4+WdufDcwMnnMEWmg==", + "version": "8.30.1", + "resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-8.30.1.tgz", + "integrity": "sha512-H+vqmWwT5xoNrXqWs/fesmssOW70gxFlgcMlYcBaWNPIEWDgLa4W9nkSPmhuOgLnXq9QYgkZ31fhDyLhleCsAg==", "dev": true, "license": "MIT", "dependencies": { - "@typescript-eslint/scope-manager": "8.29.1", - "@typescript-eslint/types": "8.29.1", - "@typescript-eslint/typescript-estree": "8.29.1", - "@typescript-eslint/visitor-keys": "8.29.1", + "@typescript-eslint/scope-manager": "8.30.1", + "@typescript-eslint/types": "8.30.1", + "@typescript-eslint/typescript-estree": "8.30.1", + "@typescript-eslint/visitor-keys": "8.30.1", "debug": "^4.3.4" }, "engines": { @@ -2006,14 +2005,14 @@ } }, "node_modules/@typescript-eslint/scope-manager": { - "version": "8.29.1", - "resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-8.29.1.tgz", - "integrity": "sha512-2nggXGX5F3YrsGN08pw4XpMLO1Rgtnn4AzTegC2MDesv6q3QaTU5yU7IbS1tf1IwCR0Hv/1EFygLn9ms6LIpDA==", + "version": "8.30.1", + "resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-8.30.1.tgz", + "integrity": "sha512-+C0B6ChFXZkuaNDl73FJxRYT0G7ufVPOSQkqkpM/U198wUwUFOtgo1k/QzFh1KjpBitaK7R1tgjVz6o9HmsRPg==", "dev": true, "license": "MIT", "dependencies": { - "@typescript-eslint/types": "8.29.1", - "@typescript-eslint/visitor-keys": "8.29.1" + "@typescript-eslint/types": "8.30.1", + "@typescript-eslint/visitor-keys": "8.30.1" }, "engines": { "node": "^18.18.0 || ^20.9.0 || >=21.1.0" @@ -2024,14 +2023,14 @@ } }, "node_modules/@typescript-eslint/type-utils": { - "version": "8.29.1", - "resolved": "https://registry.npmjs.org/@typescript-eslint/type-utils/-/type-utils-8.29.1.tgz", - "integrity": "sha512-DkDUSDwZVCYN71xA4wzySqqcZsHKic53A4BLqmrWFFpOpNSoxX233lwGu/2135ymTCR04PoKiEEEvN1gFYg4Tw==", + "version": "8.30.1", + "resolved": "https://registry.npmjs.org/@typescript-eslint/type-utils/-/type-utils-8.30.1.tgz", + "integrity": "sha512-64uBF76bfQiJyHgZISC7vcNz3adqQKIccVoKubyQcOnNcdJBvYOILV1v22Qhsw3tw3VQu5ll8ND6hycgAR5fEA==", "dev": true, "license": "MIT", "dependencies": { - "@typescript-eslint/typescript-estree": "8.29.1", - "@typescript-eslint/utils": "8.29.1", + "@typescript-eslint/typescript-estree": "8.30.1", + "@typescript-eslint/utils": "8.30.1", "debug": "^4.3.4", "ts-api-utils": "^2.0.1" }, @@ -2066,9 +2065,9 @@ } }, "node_modules/@typescript-eslint/types": { - "version": "8.29.1", - "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-8.29.1.tgz", - "integrity": "sha512-VT7T1PuJF1hpYC3AGm2rCgJBjHL3nc+A/bhOp9sGMKfi5v0WufsX/sHCFBfNTx2F+zA6qBc/PD0/kLRLjdt8mQ==", + "version": "8.30.1", + "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-8.30.1.tgz", + "integrity": "sha512-81KawPfkuulyWo5QdyG/LOKbspyyiW+p4vpn4bYO7DM/hZImlVnFwrpCTnmNMOt8CvLRr5ojI9nU1Ekpw4RcEw==", "dev": true, "license": "MIT", "engines": { @@ -2080,14 +2079,14 @@ } }, "node_modules/@typescript-eslint/typescript-estree": { - "version": "8.29.1", - "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-8.29.1.tgz", - "integrity": "sha512-l1enRoSaUkQxOQnbi0KPUtqeZkSiFlqrx9/3ns2rEDhGKfTa+88RmXqedC1zmVTOWrLc2e6DEJrTA51C9iLH5g==", + "version": "8.30.1", + "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-8.30.1.tgz", + "integrity": "sha512-kQQnxymiUy9tTb1F2uep9W6aBiYODgq5EMSk6Nxh4Z+BDUoYUSa029ISs5zTzKBFnexQEh71KqwjKnRz58lusQ==", "dev": true, "license": "MIT", "dependencies": { - "@typescript-eslint/types": "8.29.1", - "@typescript-eslint/visitor-keys": "8.29.1", + "@typescript-eslint/types": "8.30.1", + "@typescript-eslint/visitor-keys": "8.30.1", "debug": "^4.3.4", "fast-glob": "^3.3.2", "is-glob": "^4.0.3", @@ -2164,16 +2163,16 @@ } }, "node_modules/@typescript-eslint/utils": { - "version": "8.29.1", - "resolved": "https://registry.npmjs.org/@typescript-eslint/utils/-/utils-8.29.1.tgz", - "integrity": "sha512-QAkFEbytSaB8wnmB+DflhUPz6CLbFWE2SnSCrRMEa+KnXIzDYbpsn++1HGvnfAsUY44doDXmvRkO5shlM/3UfA==", + "version": "8.30.1", + "resolved": "https://registry.npmjs.org/@typescript-eslint/utils/-/utils-8.30.1.tgz", + "integrity": "sha512-T/8q4R9En2tcEsWPQgB5BQ0XJVOtfARcUvOa8yJP3fh9M/mXraLxZrkCfGb6ChrO/V3W+Xbd04RacUEqk1CFEQ==", "dev": true, "license": "MIT", "dependencies": { "@eslint-community/eslint-utils": "^4.4.0", - "@typescript-eslint/scope-manager": "8.29.1", - "@typescript-eslint/types": "8.29.1", - "@typescript-eslint/typescript-estree": "8.29.1" + "@typescript-eslint/scope-manager": "8.30.1", + "@typescript-eslint/types": "8.30.1", + "@typescript-eslint/typescript-estree": "8.30.1" }, "engines": { "node": "^18.18.0 || ^20.9.0 || >=21.1.0" @@ -2188,13 +2187,13 @@ } }, "node_modules/@typescript-eslint/visitor-keys": { - "version": "8.29.1", - "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-8.29.1.tgz", - "integrity": "sha512-RGLh5CRaUEf02viP5c1Vh1cMGffQscyHe7HPAzGpfmfflFg1wUz2rYxd+OZqwpeypYvZ8UxSxuIpF++fmOzEcg==", + "version": "8.30.1", + "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-8.30.1.tgz", + "integrity": "sha512-aEhgas7aJ6vZnNFC7K4/vMGDGyOiqWcYZPpIWrTKuTAlsvDNKy2GFDqh9smL+iq069ZvR0YzEeq0B8NJlLzjFA==", "dev": true, "license": "MIT", "dependencies": { - "@typescript-eslint/types": "8.29.1", + "@typescript-eslint/types": "8.30.1", "eslint-visitor-keys": "^4.2.0" }, "engines": { @@ -2465,12 +2464,12 @@ } }, "node_modules/apify-client": { - "version": "2.12.1", - "resolved": "https://registry.npmjs.org/apify-client/-/apify-client-2.12.1.tgz", - "integrity": "sha512-5K9VfSwjb2veD0ts1mScI5mVVuw/eTqF3tjyQj/jGyi7o3WIP5NI+3cXWz/aZGIQtPMLSjJ1VAVGu/of+wcmpw==", + "version": "2.12.2", + "resolved": "https://registry.npmjs.org/apify-client/-/apify-client-2.12.2.tgz", + "integrity": "sha512-+eSexDukVso58MQ8pOJj67mnaDkexH80VJs0/stfM8yNSUKMa/BIIdbG3rX8axjpTtT3UzpPgMIz6qh8inxFCQ==", "license": "Apache-2.0", "dependencies": { - "@apify/consts": "^2.25.0", + "@apify/consts": "^2.40.0", "@apify/log": "^2.2.6", "@crawlee/types": "^3.3.0", "agentkeepalive": "^4.2.1", @@ -2915,9 +2914,9 @@ } }, "node_modules/caniuse-lite": { - "version": "1.0.30001712", - "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001712.tgz", - "integrity": "sha512-MBqPpGYYdQ7/hfKiet9SCI+nmN5/hp4ZzveOJubl5DTAMa5oggjAuoi0Z4onBpKPFI2ePGnQuQIzF3VxDjDJig==", + "version": "1.0.30001713", + "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001713.tgz", + "integrity": "sha512-wCIWIg+A4Xr7NfhTuHdX+/FKh3+Op3LBbSp2N5Pfx6T/LhdQy3GTyoTg48BReaW/MyMNZAkTadsBtai3ldWK0Q==", "funding": [ { "type": "opencollective", @@ -3424,9 +3423,9 @@ } }, "node_modules/dotenv": { - "version": "16.4.7", - "resolved": "https://registry.npmjs.org/dotenv/-/dotenv-16.4.7.tgz", - "integrity": "sha512-47qPchRCykZC03FhkYAhrvwU4xDBFIj1QPqaarj6mdM/hgUzfPHcpkHJOn3mJAufFeeAxAzeGsr5X0M4k6fLZQ==", + "version": "16.5.0", + "resolved": "https://registry.npmjs.org/dotenv/-/dotenv-16.5.0.tgz", + "integrity": "sha512-m/C+AwOAr9/W1UOIZUo232ejMNnJAJtYQjUbHoNTBNTJSvqzzDh7vnrei3o3r3m9blf6ZoDkvcw0VmozNRFJxg==", "dev": true, "license": "BSD-2-Clause", "engines": { @@ -3463,9 +3462,9 @@ "license": "MIT" }, "node_modules/electron-to-chromium": { - "version": "1.5.134", - "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.5.134.tgz", - "integrity": "sha512-zSwzrLg3jNP3bwsLqWHmS5z2nIOQ5ngMnfMZOWWtXnqqQkPVyOipxK98w+1beLw1TB+EImPNcG8wVP/cLVs2Og==", + "version": "1.5.137", + "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.5.137.tgz", + "integrity": "sha512-/QSJaU2JyIuTbbABAo/crOs+SuAZLS+fVVS10PVrIT9hrRkmZl8Hb0xPSkKRUUWHQtYzXHpQUW3Dy5hwMzGZkA==", "license": "ISC" }, "node_modules/encodeurl": { @@ -6607,9 +6606,9 @@ } }, "node_modules/rollup": { - "version": "4.39.0", - "resolved": "https://registry.npmjs.org/rollup/-/rollup-4.39.0.tgz", - "integrity": "sha512-thI8kNc02yNvnmJp8dr3fNWJ9tCONDhp6TV35X6HkKGGs9E6q7YWCHbe5vKiTa7TAiNcFEmXKj3X/pG2b3ci0g==", + "version": "4.40.0", + "resolved": "https://registry.npmjs.org/rollup/-/rollup-4.40.0.tgz", + "integrity": "sha512-Noe455xmA96nnqH5piFtLobsGbCij7Tu+tb3c1vYjNbTkfzGqXqQXG3wJaYXkRZuQ0vEYN4bhwg7QnIrqB5B+w==", "dev": true, "license": "MIT", "dependencies": { @@ -6623,26 +6622,26 @@ "npm": ">=8.0.0" }, "optionalDependencies": { - "@rollup/rollup-android-arm-eabi": "4.39.0", - "@rollup/rollup-android-arm64": "4.39.0", - "@rollup/rollup-darwin-arm64": "4.39.0", - "@rollup/rollup-darwin-x64": "4.39.0", - "@rollup/rollup-freebsd-arm64": "4.39.0", - "@rollup/rollup-freebsd-x64": "4.39.0", - "@rollup/rollup-linux-arm-gnueabihf": "4.39.0", - "@rollup/rollup-linux-arm-musleabihf": "4.39.0", - "@rollup/rollup-linux-arm64-gnu": "4.39.0", - "@rollup/rollup-linux-arm64-musl": "4.39.0", - "@rollup/rollup-linux-loongarch64-gnu": "4.39.0", - "@rollup/rollup-linux-powerpc64le-gnu": "4.39.0", - "@rollup/rollup-linux-riscv64-gnu": "4.39.0", - "@rollup/rollup-linux-riscv64-musl": "4.39.0", - "@rollup/rollup-linux-s390x-gnu": "4.39.0", - "@rollup/rollup-linux-x64-gnu": "4.39.0", - "@rollup/rollup-linux-x64-musl": "4.39.0", - "@rollup/rollup-win32-arm64-msvc": "4.39.0", - "@rollup/rollup-win32-ia32-msvc": "4.39.0", - "@rollup/rollup-win32-x64-msvc": "4.39.0", + "@rollup/rollup-android-arm-eabi": "4.40.0", + "@rollup/rollup-android-arm64": "4.40.0", + "@rollup/rollup-darwin-arm64": "4.40.0", + "@rollup/rollup-darwin-x64": "4.40.0", + "@rollup/rollup-freebsd-arm64": "4.40.0", + "@rollup/rollup-freebsd-x64": "4.40.0", + "@rollup/rollup-linux-arm-gnueabihf": "4.40.0", + "@rollup/rollup-linux-arm-musleabihf": "4.40.0", + "@rollup/rollup-linux-arm64-gnu": "4.40.0", + "@rollup/rollup-linux-arm64-musl": "4.40.0", + "@rollup/rollup-linux-loongarch64-gnu": "4.40.0", + "@rollup/rollup-linux-powerpc64le-gnu": "4.40.0", + "@rollup/rollup-linux-riscv64-gnu": "4.40.0", + "@rollup/rollup-linux-riscv64-musl": "4.40.0", + "@rollup/rollup-linux-s390x-gnu": "4.40.0", + "@rollup/rollup-linux-x64-gnu": "4.40.0", + "@rollup/rollup-linux-x64-musl": "4.40.0", + "@rollup/rollup-win32-arm64-msvc": "4.40.0", + "@rollup/rollup-win32-ia32-msvc": "4.40.0", + "@rollup/rollup-win32-x64-msvc": "4.40.0", "fsevents": "~2.3.2" } }, @@ -7285,21 +7284,21 @@ } }, "node_modules/tldts": { - "version": "6.1.85", - "resolved": "https://registry.npmjs.org/tldts/-/tldts-6.1.85.tgz", - "integrity": "sha512-gBdZ1RjCSevRPFix/hpaUWeak2/RNUZB4/8frF1r5uYMHjFptkiT0JXIebWvgI/0ZHXvxaUDDJshiA0j6GdL3w==", + "version": "6.1.86", + "resolved": "https://registry.npmjs.org/tldts/-/tldts-6.1.86.tgz", + "integrity": "sha512-WMi/OQ2axVTf/ykqCQgXiIct+mSQDFdH2fkwhPwgEwvJ1kSzZRiinb0zF2Xb8u4+OqPChmyI6MEu4EezNJz+FQ==", "license": "MIT", "dependencies": { - "tldts-core": "^6.1.85" + "tldts-core": "^6.1.86" }, "bin": { "tldts": "bin/cli.js" } }, "node_modules/tldts-core": { - "version": "6.1.85", - "resolved": "https://registry.npmjs.org/tldts-core/-/tldts-core-6.1.85.tgz", - "integrity": "sha512-DTjUVvxckL1fIoPSb3KE7ISNtkWSawZdpfxGxwiIrZoO6EbHVDXXUIlIuWympPaeS+BLGyggozX/HTMsRAdsoA==", + "version": "6.1.86", + "resolved": "https://registry.npmjs.org/tldts-core/-/tldts-core-6.1.86.tgz", + "integrity": "sha512-Je6p7pkk+KMzMv2XXKmAE3McmolOQFdxkKw0R8EYNr7sELW46JqnNeTX8ybPiQgvg1ymCoF8LXs5fzFaZvJPTA==", "license": "MIT" }, "node_modules/to-regex-range": { @@ -7439,9 +7438,9 @@ } }, "node_modules/type-fest": { - "version": "4.39.1", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-4.39.1.tgz", - "integrity": "sha512-uW9qzd66uyHYxwyVBYiwS4Oi0qZyUqwjU+Oevr6ZogYiXt99EOYtwvzMSLw1c3lYo2HzJsep/NB23iEVEgjG/w==", + "version": "4.40.0", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-4.40.0.tgz", + "integrity": "sha512-ABHZ2/tS2JkvH1PEjxFDTUWC8dB5OsIGZP4IFLhR293GqT5Y5qB1WwL2kMPYhQW9DVgVD8Hd7I8gjwPIf5GFkw==", "license": "(MIT OR CC0-1.0)", "engines": { "node": ">=16" @@ -7556,15 +7555,15 @@ } }, "node_modules/typescript-eslint": { - "version": "8.29.1", - "resolved": "https://registry.npmjs.org/typescript-eslint/-/typescript-eslint-8.29.1.tgz", - "integrity": "sha512-f8cDkvndhbQMPcysk6CUSGBWV+g1utqdn71P5YKwMumVMOG/5k7cHq0KyG4O52nB0oKS4aN2Tp5+wB4APJGC+w==", + "version": "8.30.1", + "resolved": "https://registry.npmjs.org/typescript-eslint/-/typescript-eslint-8.30.1.tgz", + "integrity": "sha512-D7lC0kcehVH7Mb26MRQi64LMyRJsj3dToJxM1+JVTl53DQSV5/7oUGWQLcKl1C1KnoVHxMMU2FNQMffr7F3Row==", "dev": true, "license": "MIT", "dependencies": { - "@typescript-eslint/eslint-plugin": "8.29.1", - "@typescript-eslint/parser": "8.29.1", - "@typescript-eslint/utils": "8.29.1" + "@typescript-eslint/eslint-plugin": "8.30.1", + "@typescript-eslint/parser": "8.30.1", + "@typescript-eslint/utils": "8.30.1" }, "engines": { "node": "^18.18.0 || ^20.9.0 || >=21.1.0" @@ -7701,9 +7700,9 @@ } }, "node_modules/vite": { - "version": "6.2.5", - "resolved": "https://registry.npmjs.org/vite/-/vite-6.2.5.tgz", - "integrity": "sha512-j023J/hCAa4pRIUH6J9HemwYfjB5llR2Ps0CWeikOtdR8+pAURAk0DoJC5/mm9kd+UgdnIy7d6HE4EAvlYhPhA==", + "version": "6.2.6", + "resolved": "https://registry.npmjs.org/vite/-/vite-6.2.6.tgz", + "integrity": "sha512-9xpjNl3kR4rVDZgPNdTL0/c6ao4km69a/2ihNQbcANz8RuCOK3hQBmLSJf3bRKVQjVMda+YvizNE8AwvogcPbw==", "dev": true, "license": "MIT", "dependencies": { diff --git a/package.json b/package.json index d85fc9f2..988d9350 100644 --- a/package.json +++ b/package.json @@ -31,7 +31,7 @@ ], "dependencies": { "@apify/log": "^2.5.16", - "@modelcontextprotocol/sdk": "^1.9.0", + "@modelcontextprotocol/sdk": "github:jirispilka/mcp-typescript-sdk#fix/add-src-dir", "ajv": "^8.17.1", "apify": "^3.4.0", "apify-client": "^2.12.1", @@ -59,13 +59,13 @@ "start": "npm run start:dev", "start:prod": "node dist/main.js", "start:dev": "tsx src/main.ts", - "lint": "./node_modules/.bin/eslint .", - "lint:fix": "./node_modules/.bin/eslint . --fix", - "build": "tsc", - "build:watch": "tsc -w", + "lint": "eslint .", + "lint:fix": "eslint . --fix", + "build": "tsc -b src", + "build:watch": "tsc -b src -w", + "type-check": "tsc --noEmit", "inspector": "npx @modelcontextprotocol/inspector dist/stdio.js", "test": "vitest run", - "type-check": "tsc --noEmit", "clean": "tsc -b src --clean" }, "author": "Apify", diff --git a/src/actor/const.ts b/src/actor/const.ts index 538e7784..bc9aa114 100644 --- a/src/actor/const.ts +++ b/src/actor/const.ts @@ -5,6 +5,14 @@ export const HEADER_READINESS_PROBE = 'x-apify-container-server-readiness-probe' export enum Routes { ROOT = '/', + MCP = '/mcp', SSE = '/sse', MESSAGE = '/message', } + +export const getHelpMessage = (host: string) => `To interact with the server you can either: +- send request to ${host}${Routes.MCP}?token=YOUR-APIFY-TOKEN and receive a response +or +- connect for Server-Sent Events (SSE) via GET request to: ${host}${Routes.SSE}?token=YOUR-APIFY-TOKEN +- send messages via POST request to: ${host}${Routes.MESSAGE}?token=YOUR-APIFY-TOKEN + (Include your message content in the request body.)`; diff --git a/src/actor/server.ts b/src/actor/server.ts index 85563ff5..29b82ad7 100644 --- a/src/actor/server.ts +++ b/src/actor/server.ts @@ -2,91 +2,170 @@ * Express server implementation used for standby Actor mode. */ +import { randomUUID } from 'node:crypto'; + import { SSEServerTransport } from '@modelcontextprotocol/sdk/server/sse.js'; +import { StreamableHTTPServerTransport } from '@modelcontextprotocol/sdk/server/streamableHttp.js'; import type { Request, Response } from 'express'; import express from 'express'; import log from '@apify/log'; -import { HEADER_READINESS_PROBE, Routes } from './const.js'; import { type ActorsMcpServer } from '../mcp-server.js'; +import { getHelpMessage, HEADER_READINESS_PROBE, Routes } from './const.js'; import { getActorRunData, processParamsGetTools } from './utils.js'; export function createExpressApp( host: string, mcpServer: ActorsMcpServer, ): express.Express { - const HELP_MESSAGE = `Connect to the server with GET request to ${host}/sse?token=YOUR-APIFY-TOKEN` - + ` and then send POST requests to ${host}/message?token=YOUR-APIFY-TOKEN`; - const app = express(); + app.use(express.json()); + let transportSSE: SSEServerTransport; + const transports: { [sessionId: string]: StreamableHTTPServerTransport } = {}; - let transport: SSEServerTransport; + function respondWithError(res: Response, error: unknown, logMessage: string, statusCode = 500) { + log.error(`${logMessage}: ${error}`); + if (!res.headersSent) { + res.status(statusCode).json({ + jsonrpc: '2.0', + error: { + code: statusCode === 500 ? -32603 : -32000, + message: statusCode === 500 ? 'Internal server error' : 'Bad Request', + }, + id: null, + }); + } + } - app.route(Routes.ROOT) - .get(async (req: Request, res: Response) => { - if (req.headers && req.get(HEADER_READINESS_PROBE) !== undefined) { - log.debug('Received readiness probe'); - res.status(200).json({ message: 'Server is ready' }).end(); - return; + app.get(Routes.ROOT, async (req: Request, res: Response) => { + if (req.headers && req.get(HEADER_READINESS_PROBE) !== undefined) { + log.debug('Received readiness probe'); + res.status(200).json({ message: 'Server is ready' }).end(); + return; + } + try { + log.info(`Received GET message at: ${Routes.ROOT}`); + const tools = await processParamsGetTools(req.url); + if (tools) { + mcpServer.updateTools(tools); } - try { - log.info(`Received GET message at: ${Routes.ROOT}`); - const tools = await processParamsGetTools(req.url); - if (tools) { - mcpServer.updateTools(tools); - } - res.setHeader('Content-Type', 'text/event-stream'); - res.setHeader('Cache-Control', 'no-cache'); - res.setHeader('Connection', 'keep-alive'); - res.status(200).json({ message: `Actor is using Model Context Protocol. ${HELP_MESSAGE}`, data: getActorRunData() }).end(); - } catch (error) { - log.error(`Error in GET ${Routes.ROOT} ${error}`); - res.status(500).json({ message: 'Internal Server Error' }).end(); + res.setHeader('Content-Type', 'text/event-stream'); + res.setHeader('Cache-Control', 'no-cache'); + res.setHeader('Connection', 'keep-alive'); + res.status(200).json({ message: `Actor is using Model Context Protocol. ${getHelpMessage(host)}`, data: getActorRunData() }).end(); + } catch (error) { + respondWithError(res, error, `Error in GET ${Routes.ROOT}`); + } + }); + + app.head(Routes.ROOT, (_req: Request, res: Response) => { + res.status(200).end(); + }); + + app.get(Routes.SSE, async (req: Request, res: Response) => { + try { + log.info(`Received GET message at: ${Routes.SSE}`); + const tools = await processParamsGetTools(req.url); + if (tools) { + mcpServer.updateTools(tools); } - }) - .head((_req: Request, res: Response) => { - res.status(200).end(); - }); - - app.route(Routes.SSE) - .get(async (req: Request, res: Response) => { - try { - log.info(`Received GET message at: ${Routes.SSE}`); - const tools = await processParamsGetTools(req.url); - if (tools) { - mcpServer.updateTools(tools); - } - transport = new SSEServerTransport(Routes.MESSAGE, res); - await mcpServer.connect(transport); - } catch (error) { - log.error(`Error in GET ${Routes.SSE}: ${error}`); - res.status(500).json({ message: 'Internal Server Error' }).end(); + transportSSE = new SSEServerTransport(Routes.MESSAGE, res); + await mcpServer.connect(transportSSE); + } catch (error) { + respondWithError(res, error, `Error in GET ${Routes.SSE}`); + } + }); + + app.post(Routes.MESSAGE, async (req: Request, res: Response) => { + try { + log.info(`Received POST message at: ${Routes.MESSAGE}`); + if (transportSSE) { + await transportSSE.handlePostMessage(req, res); + } else { + log.error('Server is not connected to the client.'); + res.status(400).json({ + jsonrpc: '2.0', + error: { + code: -32000, + message: 'Bad Request: Server is not connected to the client. ' + + 'Connect to the server with GET request to /sse endpoint', + }, + id: null, + }); } - }); - - app.route(Routes.MESSAGE) - .post(async (req: Request, res: Response) => { - try { - log.info(`Received POST message at: ${Routes.MESSAGE}`); - if (transport) { - await transport.handlePostMessage(req, res); - } else { - res.status(400).json({ - message: 'Server is not connected to the client. ' - + 'Connect to the server with GET request to /sse endpoint', - }); + } catch (error) { + respondWithError(res, error, `Error in POST ${Routes.MESSAGE}`); + } + }); + + app.post(Routes.MCP, async (req: Request, res: Response) => { + log.info('Received MCP request:', req.body); + try { + // Check for existing session ID + const sessionId = req.headers['mcp-session-id'] as string | undefined; + let transport: StreamableHTTPServerTransport; + + if (sessionId && transports[sessionId]) { + // Reuse existing transport + transport = transports[sessionId]; + } else if (!sessionId && isInitializeRequest(req.body)) { + // New initialization request - use JSON response mode + transport = new StreamableHTTPServerTransport({ + sessionIdGenerator: () => randomUUID(), + enableJsonResponse: true, // Enable JSON response mode + }); + + // Connect the transport to the MCP server BEFORE handling the request + await mcpServer.connect(transport); + + // After handling the request, if we get a session ID back, store the transport + await transport.handleRequest(req, res, req.body); + + // Store the transport by session ID for future requests + if (transport.sessionId) { + transports[transport.sessionId] = transport; } - } catch (error) { - log.error(`Error in POST ${Routes.MESSAGE}: ${error}`); - res.status(500).json({ message: 'Internal Server Error' }).end(); + return; // Already handled + } else { + // Invalid request - no session ID or not initialization request + res.status(400).json({ + jsonrpc: '2.0', + error: { + code: -32000, + message: 'Bad Request: No valid session ID provided or not initialization request', + }, + id: null, + }); + return; } - }); + + // Handle the request with existing transport - no need to reconnect + await transport.handleRequest(req, res, req.body); + } catch (error) { + respondWithError(res, error, 'Error handling MCP request'); + } + }); + + // Handle GET requests for SSE streams according to spec + app.get(Routes.MCP, async (_req: Request, res: Response) => { + // We don't support GET requests for this server + // The spec requires returning 405 Method Not Allowed in this case + res.status(405).set('Allow', 'POST').send('Method Not Allowed'); + }); // Catch-all for undefined routes app.use((req: Request, res: Response) => { - res.status(404).json({ message: `There is nothing at route ${req.method} ${req.originalUrl}. ${HELP_MESSAGE}` }).end(); + res.status(404).json({ message: `There is nothing at route ${req.method} ${req.originalUrl}. ${getHelpMessage(host)}` }).end(); }); return app; } + +// Helper function to detect initialize requests +function isInitializeRequest(body: unknown): boolean { + if (Array.isArray(body)) { + return body.some((msg) => typeof msg === 'object' && msg !== null && 'method' in msg && msg.method === 'initialize'); + } + return typeof body === 'object' && body !== null && 'method' in body && body.method === 'initialize'; +} diff --git a/src/actor/utils.ts b/src/actor/utils.ts index 2a826e9e..f31088e6 100644 --- a/src/actor/utils.ts +++ b/src/actor/utils.ts @@ -2,10 +2,10 @@ import { parse } from 'node:querystring'; import { Actor } from 'apify'; -import { processInput } from './input.js'; -import type { ActorRunData, Input } from './types.js'; import { addTool, getActorsAsTools, removeTool } from '../tools/index.js'; import type { ToolWrap } from '../types.js'; +import { processInput } from './input.js'; +import type { ActorRunData, Input } from './types.js'; export function parseInputParamsFromUrl(url: string): Input { const query = url.split('?')[1] || ''; diff --git a/src/const.ts b/src/const.ts index 7758896c..e23c3805 100644 --- a/src/const.ts +++ b/src/const.ts @@ -16,7 +16,7 @@ export const ACTOR_MAX_MEMORY_MBYTES = 4_096; // If the Actor requires 8GB of me // MCP Server export const SERVER_NAME = 'apify-mcp-server'; -export const SERVER_VERSION = '0.1.0'; +export const SERVER_VERSION = '1.0.0'; // User agent headers export const USER_AGENT_ORIGIN = 'Origin/mcp-server'; diff --git a/src/examples/clientSse.ts b/src/examples/clientSse.ts index c77d1fa6..f5f7d930 100644 --- a/src/examples/clientSse.ts +++ b/src/examples/clientSse.ts @@ -6,14 +6,15 @@ * It requires the `APIFY_TOKEN` in the `.env` file. */ -import path from 'path'; -import { fileURLToPath } from 'url'; +import path from 'node:path'; +import { fileURLToPath } from 'node:url'; import { Client } from '@modelcontextprotocol/sdk/client/index.js'; import { SSEClientTransport } from '@modelcontextprotocol/sdk/client/sse.js'; import { CallToolResultSchema } from '@modelcontextprotocol/sdk/types.js'; -import dotenv from 'dotenv'; -import { EventSource, EventSourceInit } from 'eventsource'; +import dotenv from 'dotenv'; // eslint-disable-line import/no-extraneous-dependencies +import type { EventSourceInit } from 'eventsource'; +import { EventSource } from 'eventsource'; // eslint-disable-line import/no-extraneous-dependencies import { actorNameToToolName } from '../tools/utils.js'; @@ -36,13 +37,15 @@ if (!process.env.APIFY_TOKEN) { // Declare EventSource on globalThis if not available (needed for Node.js environment) declare global { + + // eslint-disable-next-line no-var, vars-on-top var EventSource: { new(url: string, eventSourceInitDict?: EventSourceInit): EventSource; prototype: EventSource; CONNECTING: 0; OPEN: 1; CLOSED: 2; - }; // eslint-disable-line no-var + }; } if (typeof globalThis.EventSource === 'undefined') { diff --git a/src/examples/clientStdio.ts b/src/examples/clientStdio.ts index 8e5627d4..343e380e 100644 --- a/src/examples/clientStdio.ts +++ b/src/examples/clientStdio.ts @@ -6,14 +6,14 @@ * You can choose actors to run in the server, for example: `apify/rag-web-browser`. */ -import { execSync } from 'child_process'; -import path from 'path'; -import { fileURLToPath } from 'url'; +import { execSync } from 'node:child_process'; +import path from 'node:path'; +import { fileURLToPath } from 'node:url'; import { Client } from '@modelcontextprotocol/sdk/client/index.js'; import { StdioClientTransport } from '@modelcontextprotocol/sdk/client/stdio.js'; import { CallToolResultSchema } from '@modelcontextprotocol/sdk/types.js'; -import dotenv from 'dotenv'; +import dotenv from 'dotenv'; // eslint-disable-line import/no-extraneous-dependencies import { actorNameToToolName } from '../tools/utils.js'; diff --git a/src/examples/clientStdioChat.ts b/src/examples/clientStdioChat.ts index d7c122e2..bd1118c9 100644 --- a/src/examples/clientStdioChat.ts +++ b/src/examples/clientStdioChat.ts @@ -17,17 +17,17 @@ * Let me summarize the key points: */ -import { execSync } from 'child_process'; -import path from 'path'; -import * as readline from 'readline'; -import { fileURLToPath } from 'url'; +import { execSync } from 'node:child_process'; +import path from 'node:path'; +import * as readline from 'node:readline'; +import { fileURLToPath } from 'node:url'; -import { Anthropic } from '@anthropic-ai/sdk'; -import type { Message, ToolUseBlock, MessageParam } from '@anthropic-ai/sdk/resources/messages'; +import { Anthropic } from '@anthropic-ai/sdk'; // eslint-disable-line import/no-extraneous-dependencies +import type { Message, MessageParam, ToolUseBlock } from '@anthropic-ai/sdk/resources/messages'; import { Client } from '@modelcontextprotocol/sdk/client/index.js'; import { StdioClientTransport } from '@modelcontextprotocol/sdk/client/stdio.js'; import { CallToolResultSchema } from '@modelcontextprotocol/sdk/types.js'; -import dotenv from 'dotenv'; +import dotenv from 'dotenv'; // eslint-disable-line import/no-extraneous-dependencies const filename = fileURLToPath(import.meta.url); const dirname = path.dirname(filename); diff --git a/src/examples/clientStreamableHttp.ts b/src/examples/clientStreamableHttp.ts new file mode 100644 index 00000000..2322dc78 --- /dev/null +++ b/src/examples/clientStreamableHttp.ts @@ -0,0 +1,109 @@ +import { Client } from '@modelcontextprotocol/sdk/client/index.js'; +import { StreamableHTTPClientTransport } from '@modelcontextprotocol/sdk/client/streamableHttp.js'; +import type { CallToolRequest, ListToolsRequest } from '@modelcontextprotocol/sdk/types.js'; +import { + CallToolResultSchema, + ListToolsResultSchema, + LoggingMessageNotificationSchema, +} from '@modelcontextprotocol/sdk/types.js'; + +import log from '@apify/log'; + +log.setLevel(log.LEVELS.DEBUG); + +async function main(): Promise { + // Create a new client with streamable HTTP transport + const client = new Client({ + name: 'example-client', + version: '1.0.0', + }); + + const transport = new StreamableHTTPClientTransport( + new URL('http://localhost:3000/mcp'), + ); + + // Connect the client using the transport and initialize the server + await client.connect(transport); + log.debug('Connected to MCP server'); + + // Set up notification handlers for server-initiated messages + client.setNotificationHandler(LoggingMessageNotificationSchema, (notification) => { + log.debug(`Notification received: ${notification.params.level} - ${notification.params.data}`); + }); + + // List and call tools + await listTools(client); + + await callSearchTool(client); + await callActor(client); + + // Keep the connection open to receive notifications + log.debug('\nKeeping connection open to receive notifications. Press Ctrl+C to exit.'); +} + +async function listTools(client: Client): Promise { + try { + const toolsRequest: ListToolsRequest = { + method: 'tools/list', + params: {}, + }; + const toolsResult = await client.request(toolsRequest, ListToolsResultSchema); + log.debug(`Tools available, count: ${toolsResult.tools.length}`); + for (const tool of toolsResult.tools) { + log.debug(`Tool: ${tool.name}, Description: ${tool.description}`); + } + if (toolsResult.tools.length === 0) { + log.debug('No tools available from the server'); + } + } catch (error) { + log.error(`Tools not supported by this server (${error})`); + } +} + +async function callSearchTool(client: Client): Promise { + try { + const searchRequest: CallToolRequest = { + method: 'tools/call', + params: { + name: 'search', + arguments: { search: 'rag web browser', limit: 1 }, + }, + }; + const searchResult = await client.request(searchRequest, CallToolResultSchema); + log.debug('Search result:'); + searchResult.content.forEach((item) => { + if (item.type === 'text') { + log.debug(`\t${item.text}`); + } + }); + } catch (error) { + log.error(`Error calling greet tool: ${error}`); + } +} + +async function callActor(client: Client): Promise { + try { + log.debug('\nCalling Actor...'); + const actorRequest: CallToolRequest = { + method: 'tools/call', + params: { + name: 'apify/rag-web-browser', + arguments: { query: 'apify mcp server' }, + }, + }; + const actorResult = await client.request(actorRequest, CallToolResultSchema); + log.debug('Actor results:'); + actorResult.content.forEach((item) => { + if (item.type === 'text') { + log.debug(`- ${item.text}`); + } + }); + } catch (error) { + log.error(`Error calling Actor: ${error}`); + } +} + +main().catch((error: unknown) => { + log.error('Error running MCP client:', error as Error); + process.exit(1); +}); diff --git a/src/index.ts b/src/index.ts index e20c084d..4fb67976 100644 --- a/src/index.ts +++ b/src/index.ts @@ -4,4 +4,5 @@ */ import { ActorsMcpServer } from './mcp-server.js'; -export default ActorsMcpServer; + +export { ActorsMcpServer }; diff --git a/src/main.ts b/src/main.ts index 8f70bc3f..d88023fe 100644 --- a/src/main.ts +++ b/src/main.ts @@ -12,14 +12,20 @@ import { processInput } from './actor/input.js'; import { createExpressApp } from './actor/server.js'; import type { Input } from './actor/types'; import { ActorsMcpServer } from './mcp-server.js'; -import { actorDefinitionTool, addTool, removeTool, searchTool, callActorGetDataset } from './tools/index.js'; +import { + actorDefinitionTool, + addTool, + callActorGetDataset, + removeTool, + searchTool, +} from './tools/index.js'; const STANDBY_MODE = Actor.getEnv().metaOrigin === 'STANDBY'; await Actor.init(); const HOST = Actor.isAtHome() ? process.env.ACTOR_STANDBY_URL as string : 'http://localhost'; -const PORT = Actor.isAtHome() ? Number(process.env.ACTOR_STANDBY_PORT) : 3001; +const PORT = Actor.isAtHome() ? Number(process.env.ACTOR_STANDBY_PORT) : 3000; if (!process.env.APIFY_TOKEN) { log.error('APIFY_TOKEN is required but not set in the environment variables.'); diff --git a/src/mcp-server.ts b/src/mcp-server.ts index bb54b37a..cdc03c37 100644 --- a/src/mcp-server.ts +++ b/src/mcp-server.ts @@ -9,24 +9,21 @@ import type { ActorCallOptions } from 'apify-client'; import log from '@apify/log'; -import { - ACTOR_OUTPUT_MAX_CHARS_PER_ITEM, +import { processParamsGetTools } from './actor/utils.js'; +import { ACTOR_OUTPUT_MAX_CHARS_PER_ITEM, ACTOR_OUTPUT_TRUNCATED_MESSAGE, - SERVER_NAME, - SERVER_VERSION, -} from './const.js'; + defaults, SERVER_NAME, + SERVER_VERSION } from './const.js'; import { actorDefinitionTool, callActorGetDataset, getActorsAsTools, searchTool } from './tools/index.js'; -import type { ActorTool, HelperTool, ToolWrap } from './types.js'; -import { defaults } from './const.js'; import { actorNameToToolName } from './tools/utils.js'; -import { processParamsGetTools } from './actor/utils.js'; +import type { ActorTool, HelperTool, ToolWrap } from './types.js'; /** * Create Apify MCP server */ export class ActorsMcpServer { - public server: Server; - public tools: Map; + public readonly server: Server; + public readonly tools: Map; constructor() { this.server = new Server( @@ -37,6 +34,7 @@ export class ActorsMcpServer { { capabilities: { tools: { listChanged: true }, + logging: {}, }, }, ); @@ -52,7 +50,7 @@ export class ActorsMcpServer { * Loads missing default tools. */ public async loadDefaultTools() { - const missingDefaultTools = defaults.actors.filter(name => !this.tools.has(actorNameToToolName(name))); + const missingDefaultTools = defaults.actors.filter((name) => !this.tools.has(actorNameToToolName(name))); const tools = await getActorsAsTools(missingDefaultTools); if (tools.length > 0) this.updateTools(tools); } diff --git a/src/stdio.ts b/src/stdio.ts index d04525a7..f5bc2236 100644 --- a/src/stdio.ts +++ b/src/stdio.ts @@ -19,7 +19,7 @@ import log from '@apify/log'; import { defaults } from './const.js'; import { ActorsMcpServer } from './mcp-server.js'; -import { addTool, removeTool, getActorsAsTools } from './tools/index.js'; +import { addTool, getActorsAsTools, removeTool } from './tools/index.js'; // Configure logging, set to ERROR log.setLevel(log.LEVELS.ERROR); diff --git a/src/tools/actor.ts b/src/tools/actor.ts index 45af401f..d8ef7632 100644 --- a/src/tools/actor.ts +++ b/src/tools/actor.ts @@ -3,9 +3,9 @@ import type { ActorCallOptions } from 'apify-client'; import log from '@apify/log'; +import { ACTOR_ADDITIONAL_INSTRUCTIONS, ACTOR_MAX_MEMORY_MBYTES } from '../const.js'; import type { ToolWrap } from '../types.js'; import { getActorDefinition } from './build.js'; -import { ACTOR_ADDITIONAL_INSTRUCTIONS, ACTOR_MAX_MEMORY_MBYTES } from '../const.js'; import { ApifyClient } from './mcp-apify-client.js'; import { actorNameToToolName, diff --git a/src/tools/helpers.ts b/src/tools/helpers.ts index fbe18af4..3fa344f2 100644 --- a/src/tools/helpers.ts +++ b/src/tools/helpers.ts @@ -3,9 +3,9 @@ import { z } from 'zod'; import zodToJsonSchema from 'zod-to-json-schema'; import { HelperTools } from '../const.js'; -import { actorNameToToolName } from './utils.js'; import type { ActorTool, InternalTool, ToolWrap } from '../types'; import { getActorsAsTools } from './actor.js'; +import { actorNameToToolName } from './utils.js'; const ajv = new Ajv({ coerceTypes: 'array', strict: false }); export const AddToolArgsSchema = z.object({ diff --git a/src/tsconfig.json b/src/tsconfig.json new file mode 100644 index 00000000..4a8b9089 --- /dev/null +++ b/src/tsconfig.json @@ -0,0 +1,7 @@ +{ + "extends": "../tsconfig.json", + "compilerOptions": { + "rootDir": "./", + "outDir": "../dist", + } +} diff --git a/tests/actor-server-test.ts b/tests/actor-server-test.ts index 2a1d16ee..4785bd41 100644 --- a/tests/actor-server-test.ts +++ b/tests/actor-server-test.ts @@ -1,4 +1,4 @@ -import type { Server as HttpServer } from 'http'; +import type { Server as HttpServer } from 'node:http'; import type { Express } from 'express'; import { afterEach, beforeEach, describe, expect, it } from 'vitest'; diff --git a/tests/actor-test.ts b/tests/actor-test.ts index ba7137ba..2fd26f35 100644 --- a/tests/actor-test.ts +++ b/tests/actor-test.ts @@ -1,4 +1,4 @@ -import { describe, it, expect } from 'vitest'; +import { describe, expect, it } from 'vitest'; import { ACTOR_ENUM_MAX_LENGTH } from '../src/const.js'; import { actorNameToToolName, inferArrayItemType, shortenEnum } from '../src/tools/utils.js'; diff --git a/tests/actor-utils-test.ts b/tests/actor-utils-test.ts index fa77b62f..566c5484 100644 --- a/tests/actor-utils-test.ts +++ b/tests/actor-utils-test.ts @@ -1,4 +1,4 @@ -import { describe, it, expect } from 'vitest'; +import { describe, expect, it } from 'vitest'; import { parseInputParamsFromUrl } from '../src/actor/utils.js'; diff --git a/tsconfig.eslint.json b/tsconfig.eslint.json index c5811e85..16c0e4e8 100644 --- a/tsconfig.eslint.json +++ b/tsconfig.eslint.json @@ -1,14 +1,9 @@ { - "extends": "./tsconfig.json", - "include": [ - "src/**/*.ts", - "tests/**/*.ts", - "*.ts", - "*.js", - ".eslintrc.js" - ], - "exclude": [ - "node_modules", - "dist" - ] + "extends": "./tsconfig.json", + "include": [ + "src", + "test", + "tests", + "vitest.config.ts" + ], } diff --git a/tsconfig.json b/tsconfig.json index fb02aa71..8288461e 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -1,16 +1,7 @@ { - "extends": "@apify/tsconfig", - "compilerOptions": { - "module": "ESNext", - "target": "ESNext", - "outDir": "dist", - "moduleResolution": "node", - "noUnusedLocals": false, - "lib": ["ES2022"], - "skipLibCheck": true, - "typeRoots": ["./types", "./node_modules/@types"], - "strict": true - }, - "include": ["./src/**/*"], - "exclude": ["node_modules"] + "extends": "@apify/tsconfig", + "compilerOptions": { + "module": "ES2022", + "skipLibCheck": true, + }, }