{"_id":"loki-logs-downloader","_rev":"38-381d58440f6c40b43a24b43bf885f0be","name":"loki-logs-downloader","dist-tags":{"latest":"4.0.0","beta":"4.0.0-beta.2"},"versions":{"3.1.0":{"name":"loki-logs-downloader","version":"3.1.0","keywords":["loki"],"license":"MIT","_id":"loki-logs-downloader@3.1.0","maintainers":[{"name":"vosmol","email":"vo.smolar@gmail.com"}],"homepage":"https://github.com/vosmol/loki-logs-downloader/","bugs":{"url":"https://github.com/vosmol/loki-logs-downloader/issues"},"bin":{"loki-logs-downloader":"dist/cli.js"},"dist":{"shasum":"4f714dfe18adaaeefdb14597b783694b2bd40992","tarball":"https://registry.npmjs.org/loki-logs-downloader/-/loki-logs-downloader-3.1.0.tgz","fileCount":13,"integrity":"sha512-vgL0xp6txjW2jgLNWaoNJQ3SnZhRZwQ3r8zLGXBwpxRyOZr5iAggJp+7s7I4UaUBm0YJXHI0wzoVpjS88WaZqw==","signatures":[{"sig":"MEYCIQCfaZ80IPpISXexfT0k9lv0B6mZ2FzZM+EyC4Qxs8iQ4QIhAPmL5Zi1AkLd4CK9Mo+iIQaTVtGiKbML0O2lBIDe65Ux","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":749615},"main":"./dist/sdk.js","types":"./dist/sdk.d.ts","module":"./dist/sdk.mjs","engines":{"node":">=20"},"gitHead":"f928818b7d877dd931b22ec1620d9aa4b49f21c8","scripts":{"exec":"npm run build && node ./dist/cli.js -c ./config.json","lint":"eslint","test":"vitest run --passWithNoTests --exclude=src/integration.spec.ts","build":"tsup --entry.cli ./src/cli.ts --entry.sdk ./src/sdk.ts --no-splitting --format cjs,esm --dts --clean --target=node20","prepack":"npmignore --auto","prepare":"husky","release":"release-it","exec:dev":"tsx ./src/cli.ts -c ./config.json","lint:fix":"eslint --fix --cache","test:all":"vitest run","test:dev":"vitest --passWithNoTests --exclude=src/integration.spec.ts","format:fix":"prettier --write --cache --ignore-unknown","exec:dev-cli":"tsx ./src/cli.ts","lint:fix-all":"npm run lint:fix .","format:fix-all":"npm run format:fix .","prepublishOnly":"npm run build","test:integration":"vitest src/integration.spec.ts","generate-config-schema":"tsx ./dev/config-schema.ts"},"_npmUser":{"name":"vosmol","email":"vo.smolar@gmail.com"},"release-it":{"github":{"release":true},"$schema":"https://unpkg.com/release-it/schema/release-it.json","plugins":{"@release-it/conventional-changelog":{"infile":"CHANGELOG.md","preset":{"name":"conventionalcommits","types":[{"type":"feat","section":"Features 🚀"},{"type":"fix","section":"Bug Fixes 🦗"}]}}}},"repository":{"url":"git+https://github.com/vosmol/loki-logs-downloader.git","type":"git"},"_npmVersion":"10.8.1","description":"Tool for downloading logs from Loki API","directories":{},"lint-staged":{"*":["npm run lint:fix","npm run format:fix"]},"_nodeVersion":"22.4.0","dependencies":{"md5":"^2.3.0","zod":"^3.23.8","glob":"^11.0.0","prompts":"^2.4.2","fs-extra":"^11.2.0","commander":"^12.1.0","zod-validation-error":"^3.4.0"},"publishConfig":{"access":"public","ignore":[".github/",".husky/","dev/","src/",".editorconfig",".nvmrc",".prettierignore","CHANGELOG.md","config.example.json","docker-compose.yaml","eslint.config.mjs","prettier.config.cjs","tsconfig.json","vitest.config.ts"]},"_hasShrinkwrap":false,"devDependencies":{"tsx":"^4.19.1","tsup":"^8.3.0","husky":"^9.1.6","eslint":"^9.11.1","vitest":"^2.1.1","globals":"^15.9.0","prettier":"^3.3.3","npmignore":"^0.3.1","@eslint/js":"^9.11.1","@types/md5":"^2.3.5","release-it":"^17.6.0","@types/node":"^22.7.4","lint-staged":"^15.2.10","@types/prompts":"^2.4.9","@types/fs-extra":"^11.0.4","typescript-eslint":"^8.7.0","zod-to-json-schema":"^3.23.3","eslint-config-prettier":"^9.1.0","@release-it/conventional-changelog":"^8.0.2"},"_npmOperationalInternal":{"tmp":"tmp/loki-logs-downloader_3.1.0_1728251869974_0.509092574253021","host":"s3://npm-registry-packages"}},"3.2.0":{"name":"loki-logs-downloader","version":"3.2.0","keywords":["loki"],"license":"MIT","_id":"loki-logs-downloader@3.2.0","maintainers":[{"name":"vosmol","email":"vo.smolar@gmail.com"}],"homepage":"https://github.com/smowli/loki-logs-downloader/","bugs":{"url":"https://github.com/smowli/loki-logs-downloader/issues"},"bin":{"loki-logs-downloader":"dist/cli.js"},"dist":{"shasum":"3e2a6868e8e28964c654dafa3db987f63ff7657d","tarball":"https://registry.npmjs.org/loki-logs-downloader/-/loki-logs-downloader-3.2.0.tgz","fileCount":12,"integrity":"sha512-3q2DsARmmp19vAsfQuwct0lsFRQeadbn0zCEwpv4ZgLcKoO3gTI7fpImObVzduNgoud1ck66cL8n0llx+S87fA==","signatures":[{"sig":"MEUCICH4s5w5jY9hplN+gOuCB7Y5oUHCzSV6W4xA2qxqLRO1AiEAmzFZ7BST5TP137xsIVPAwHVmSjvHyl66AdlYajv1b5I=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":119115},"main":"./dist/sdk.js","types":"./dist/sdk.d.ts","module":"./dist/sdk.mjs","engines":{"node":">=20"},"gitHead":"3b535bf0c14a8db8f464f8ed0b1f5abe816a6939","scripts":{"exec":"npm run build && node ./dist/cli.js -c ./config.json","lint":"eslint","test":"vitest run --passWithNoTests --exclude=src/test/integration.spec.ts","build":"tsup --entry.cli ./src/cli.ts --entry.sdk ./src/sdk.ts --no-splitting --format cjs,esm --dts --clean --target=node20","prepack":"npmignore --auto","prepare":"husky","release":"release-it","exec:dev":"tsx ./src/cli.ts -c ./config.json","lint:fix":"eslint --fix --cache","test:all":"vitest run","test:dev":"vitest --passWithNoTests --exclude=src/test/integration.spec.ts","format:fix":"prettier --write --cache --ignore-unknown","exec:dev-cli":"tsx ./src/cli.ts","lint:fix-all":"npm run lint:fix .","format:fix-all":"npm run format:fix .","prepublishOnly":"npm run build","test:integration":"vitest src/test/integration.spec.ts","generate-config-schema":"tsx ./dev/config-schema.ts"},"_npmUser":{"name":"vosmol","email":"vo.smolar@gmail.com"},"release-it":{"github":{"release":true},"$schema":"https://unpkg.com/release-it/schema/release-it.json","plugins":{"@release-it/conventional-changelog":{"infile":"CHANGELOG.md","preset":{"name":"conventionalcommits","types":[{"type":"feat","section":"Features 🚀"},{"type":"fix","section":"Bug Fixes 🦗"}]}}}},"repository":{"url":"git+https://github.com/smowli/loki-logs-downloader.git","type":"git"},"_npmVersion":"10.7.0","description":"Tool for downloading logs from Loki API","directories":{},"lint-staged":{"*":["npm run lint:fix","npm run format:fix"]},"_nodeVersion":"18.20.3","dependencies":{"md5":"^2.3.0","zod":"^3.23.8","glob":"^11.0.0","prompts":"^2.4.2","fs-extra":"^11.2.0","commander":"^12.1.0","zod-validation-error":"^3.4.0"},"publishConfig":{"access":"public","ignore":[".github/",".husky/","dev/","docs/","src/",".editorconfig",".nvmrc",".prettierignore","CHANGELOG.md","config.example.json","docker-compose.yaml","eslint.config.mjs","prettier.config.cjs","tsconfig.json","vitest.config.ts"]},"_hasShrinkwrap":false,"devDependencies":{"tsx":"^4.19.1","tsup":"^8.3.0","husky":"^9.1.6","eslint":"^9.11.1","vitest":"^2.1.1","globals":"^15.9.0","prettier":"^3.3.3","npmignore":"^0.3.1","@eslint/js":"^9.11.1","@types/md5":"^2.3.5","release-it":"^17.6.0","@types/node":"^22.7.4","lint-staged":"^15.2.10","@types/prompts":"^2.4.9","@types/fs-extra":"^11.0.4","typescript-eslint":"^8.7.0","zod-to-json-schema":"^3.23.3","eslint-config-prettier":"^9.1.0","@release-it/conventional-changelog":"^8.0.2"},"_npmOperationalInternal":{"tmp":"tmp/loki-logs-downloader_3.2.0_1728567088561_0.19547515152686845","host":"s3://npm-registry-packages"}},"4.0.0-beta.0":{"name":"loki-logs-downloader","version":"4.0.0-beta.0","keywords":["loki"],"license":"MIT","_id":"loki-logs-downloader@4.0.0-beta.0","maintainers":[{"name":"vosmol","email":"vo.smolar@gmail.com"},{"name":"smowli","email":"vosmol@pm.me"}],"homepage":"https://github.com/smowli/loki-logs-downloader/","bugs":{"url":"https://github.com/smowli/loki-logs-downloader/issues"},"bin":{"loki-logs-downloader":"dist/cli.js"},"dist":{"shasum":"c911f676b820c61fb764acee3b8b039ec560769b","tarball":"https://registry.npmjs.org/loki-logs-downloader/-/loki-logs-downloader-4.0.0-beta.0.tgz","fileCount":12,"integrity":"sha512-gn0BvhZFnHNbnUETMP7sklS2H3xBgeS+GdkXwYtDR72wkjXPqM8Wp93Dp88wvG50OV8F1VILF6gInlDdJt3N+A==","signatures":[{"sig":"MEQCIAhMJB5PngLymmSM8vwRB+s8y81UvGurQHLsid3g4fBzAiBwi35jTeP/9upIhxsXP6Cdzfz8laAPOJ+0XpTqOkpERg==","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":133772},"main":"./dist/sdk.js","types":"./dist/sdk.d.ts","module":"./dist/sdk.mjs","engines":{"node":">=20"},"gitHead":"fb58890e9897ceea10e9a17bf49f4ede778286ef","scripts":{"exec":"npm run build && node ./dist/cli.js -c ./config.json","lint":"eslint","test":"vitest run --passWithNoTests --exclude=src/test/integration.spec.ts","build":"tsup --entry.cli ./src/cli.ts --entry.sdk ./src/sdk.ts --no-splitting --format cjs,esm --dts --clean --target=node20","prepack":"npmignore --auto","prepare":"husky","release":"release-it","exec:dev":"tsx ./src/cli.ts -c ./config.json","lint:fix":"eslint --fix --cache","test:all":"vitest run","test:dev":"vitest --passWithNoTests --exclude=src/test/integration.spec.ts","format:fix":"prettier --write --cache --ignore-unknown","exec:dev-cli":"tsx ./src/cli.ts","lint:fix-all":"npm run lint:fix .","format:fix-all":"npm run format:fix .","prepublishOnly":"npm run build","test:integration":"vitest src/test/integration.spec.ts","generate-config-schema":"tsx ./dev/config-schema.ts"},"_npmUser":{"name":"smowli","email":"vosmol@pm.me"},"release-it":{"github":{"release":true},"$schema":"https://unpkg.com/release-it/schema/release-it.json","plugins":{"@release-it/conventional-changelog":{"infile":"CHANGELOG.md","preset":{"name":"conventionalcommits","types":[{"type":"feat","section":"Features 🚀"},{"type":"fix","section":"Bug Fixes 🦗"}]}}}},"repository":{"url":"git+https://github.com/smowli/loki-logs-downloader.git","type":"git"},"_npmVersion":"10.7.0","description":"Tool for downloading logs from Loki API","directories":{},"lint-staged":{"*":["npm run lint:fix","npm run format:fix"]},"_nodeVersion":"18.20.3","dependencies":{"md5":"^2.3.0","zod":"^3.23.8","glob":"^11.0.0","prompts":"^2.4.2","fs-extra":"^11.2.0","commander":"^12.1.0","zod-validation-error":"^3.4.0"},"publishConfig":{"access":"public","ignore":[".github/",".husky/","dev/","docs/","src/",".editorconfig",".nvmrc",".prettierignore","CHANGELOG.md","config.example.json","docker-compose.yaml","eslint.config.mjs","prettier.config.cjs","tsconfig.json","vitest.config.ts"]},"_hasShrinkwrap":false,"readmeFilename":"README.md","devDependencies":{"tsx":"^4.19.1","tsup":"^8.3.0","husky":"^9.1.6","eslint":"^9.11.1","vitest":"^2.1.1","globals":"^15.9.0","prettier":"^3.3.3","npmignore":"^0.3.1","@eslint/js":"^9.11.1","@types/md5":"^2.3.5","release-it":"^17.6.0","@types/node":"^22.7.4","lint-staged":"^15.2.10","@types/prompts":"^2.4.9","@types/fs-extra":"^11.0.4","typescript-eslint":"^8.7.0","zod-to-json-schema":"^3.23.3","eslint-config-prettier":"^9.1.0","@release-it/conventional-changelog":"^8.0.2"},"_npmOperationalInternal":{"tmp":"tmp/loki-logs-downloader_4.0.0-beta.0_1728606265876_0.509302529724049","host":"s3://npm-registry-packages"}},"4.0.0-beta.1":{"name":"loki-logs-downloader","version":"4.0.0-beta.1","keywords":["loki"],"license":"MIT","_id":"loki-logs-downloader@4.0.0-beta.1","maintainers":[{"name":"vosmol","email":"vo.smolar@gmail.com"},{"name":"smowli","email":"vosmol@pm.me"}],"homepage":"https://github.com/smowli/loki-logs-downloader/","bugs":{"url":"https://github.com/smowli/loki-logs-downloader/issues"},"bin":{"loki-logs-downloader":"dist/cli.js"},"dist":{"shasum":"a437f2a7325fd0affffc90d44d0808c2b49c8fd7","tarball":"https://registry.npmjs.org/loki-logs-downloader/-/loki-logs-downloader-4.0.0-beta.1.tgz","fileCount":12,"integrity":"sha512-51XIrecLCp3FK53p7QdDSOvNcv9yt08ic5QgmwJKPP6njtvWExq79L4x+tk5TM56g0pECAXJvldKYzJuVfru6w==","signatures":[{"sig":"MEUCIQC0dP4sjSNVIeF4IhsoiAdjHqg/y50GeOCkvbLywkHJmAIgLqDa+TN2IOyiX3fSTfprXxXMDvcknfTPbz/PvHPEYnY=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":132959},"main":"./dist/sdk.js","types":"./dist/sdk.d.ts","module":"./dist/sdk.mjs","engines":{"node":">=20"},"gitHead":"e3397f70af3bac6ea4234fc01d15242a425e2e75","scripts":{"exec":"npm run build && node ./dist/cli.js -c ./config.json","lint":"eslint","test":"vitest run --passWithNoTests --exclude=src/test/integration.spec.ts","build":"tsup --entry.cli ./src/cli.ts --entry.sdk ./src/sdk.ts --no-splitting --format cjs,esm --dts --clean --target=node20","prepack":"npmignore --auto","prepare":"husky","release":"release-it","exec:dev":"tsx ./src/cli.ts -c ./config.json","lint:fix":"eslint --fix --cache","test:all":"vitest run","test:dev":"vitest --passWithNoTests --exclude=src/test/integration.spec.ts","format:fix":"prettier --write --cache --ignore-unknown","exec:dev-cli":"tsx ./src/cli.ts","lint:fix-all":"npm run lint:fix .","format:fix-all":"npm run format:fix .","prepublishOnly":"npm run build","test:integration":"vitest src/test/integration.spec.ts","generate-config-schema":"tsx ./dev/config-schema.ts"},"_npmUser":{"name":"smowli","email":"vosmol@pm.me"},"release-it":{"github":{"release":true},"$schema":"https://unpkg.com/release-it/schema/release-it.json","plugins":{"@release-it/conventional-changelog":{"infile":"CHANGELOG.md","preset":{"name":"conventionalcommits","types":[{"type":"feat","section":"Features 🚀"},{"type":"fix","section":"Bug Fixes 🦗"}]}}}},"repository":{"url":"git+https://github.com/smowli/loki-logs-downloader.git","type":"git"},"_npmVersion":"10.8.1","description":"Tool for downloading logs from Loki API","directories":{},"lint-staged":{"*":["npm run lint:fix","npm run format:fix"]},"_nodeVersion":"22.4.0","dependencies":{"md5":"^2.3.0","zod":"^3.23.8","glob":"^11.0.0","prompts":"^2.4.2","fs-extra":"^11.2.0","commander":"^12.1.0","zod-validation-error":"^3.4.0"},"publishConfig":{"access":"public","ignore":[".github/",".husky/","dev/","docs/","src/",".editorconfig",".nvmrc",".prettierignore","CHANGELOG.md","config.example.json","docker-compose.yaml","eslint.config.mjs","prettier.config.cjs","tsconfig.json","vitest.config.ts"]},"_hasShrinkwrap":false,"readmeFilename":"README.md","devDependencies":{"tsx":"^4.19.1","tsup":"^8.3.0","husky":"^9.1.6","eslint":"^9.11.1","vitest":"^2.1.1","globals":"^15.9.0","prettier":"^3.3.3","npmignore":"^0.3.1","@eslint/js":"^9.11.1","@types/md5":"^2.3.5","release-it":"^17.6.0","@types/node":"^22.7.4","lint-staged":"^15.2.10","@types/prompts":"^2.4.9","@types/fs-extra":"^11.0.4","typescript-eslint":"^8.7.0","zod-to-json-schema":"^3.23.3","eslint-config-prettier":"^9.1.0","@release-it/conventional-changelog":"^8.0.2"},"_npmOperationalInternal":{"tmp":"tmp/loki-logs-downloader_4.0.0-beta.1_1728607687489_0.11112154750465675","host":"s3://npm-registry-packages"}},"4.0.0-beta.2":{"name":"loki-logs-downloader","version":"4.0.0-beta.2","keywords":["loki"],"license":"MIT","_id":"loki-logs-downloader@4.0.0-beta.2","maintainers":[{"name":"vosmol","email":"vo.smolar@gmail.com"},{"name":"smowli","email":"vosmol@pm.me"}],"homepage":"https://github.com/smowli/loki-logs-downloader/","bugs":{"url":"https://github.com/smowli/loki-logs-downloader/issues"},"bin":{"loki-logs-downloader":"dist/cli.js"},"dist":{"shasum":"e44e18086760a008fb07b868dde1177bbd96e9af","tarball":"https://registry.npmjs.org/loki-logs-downloader/-/loki-logs-downloader-4.0.0-beta.2.tgz","fileCount":12,"integrity":"sha512-AwMvhEj+TDraFSLGzEr2uM/JEnH2HLSSIKZNrc40DXwHsYwkl8ocyrcsF23DpnRWIghRBRgQ4g/zHeuWiZ/GXg==","signatures":[{"sig":"MEYCIQCm6GoR3Gld0EkXQOpBiP5qofSs+01es34bfmYSpJQN2wIhAIEiq1CWYIrJ6PvDPazj+kYFug4oWEy7xTpj3hyVAYsw","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":127410},"main":"./dist/sdk.js","types":"./dist/sdk.d.ts","module":"./dist/sdk.mjs","engines":{"node":">=20"},"gitHead":"14684a93b23dc7c69b156dfcd46c8f93f0aec801","scripts":{"exec":"npm run build && node ./dist/cli.js -c ./config.json","lint":"eslint","test":"vitest run --passWithNoTests --exclude=src/test/integration.spec.ts","build":"tsup --entry.cli ./src/cli.ts --entry.sdk ./src/sdk.ts --no-splitting --format cjs,esm --dts --clean --target=node20","prepack":"npmignore --auto","prepare":"husky","release":"release-it","exec:dev":"tsx ./src/cli.ts -c ./config.json","lint:fix":"eslint --fix --cache","test:all":"vitest run","test:dev":"vitest --passWithNoTests --exclude=src/test/integration.spec.ts","format:fix":"prettier --write --cache --ignore-unknown","exec:dev-cli":"tsx ./src/cli.ts","lint:fix-all":"npm run lint:fix .","format:fix-all":"npm run format:fix .","prepublishOnly":"npm run build","test:integration":"vitest src/test/integration.spec.ts","generate-config-schema":"tsx ./dev/config-schema.ts"},"_npmUser":{"name":"smowli","email":"vosmol@pm.me"},"release-it":{"github":{"release":true},"$schema":"https://unpkg.com/release-it/schema/release-it.json","plugins":{"@release-it/conventional-changelog":{"infile":"CHANGELOG.md","preset":{"name":"conventionalcommits","types":[{"type":"feat","section":"Features 🚀"},{"type":"fix","section":"Bug Fixes 🦗"}]}}}},"repository":{"url":"git+https://github.com/smowli/loki-logs-downloader.git","type":"git"},"_npmVersion":"10.8.1","description":"Tool for downloading logs from Loki API","directories":{},"lint-staged":{"*":["npm run lint:fix","npm run format:fix"]},"_nodeVersion":"22.4.0","dependencies":{"md5":"^2.3.0","zod":"^3.23.8","glob":"^11.0.0","prompts":"^2.4.2","fs-extra":"^11.2.0","commander":"^12.1.0","zod-validation-error":"^3.4.0"},"publishConfig":{"access":"public","ignore":[".github/",".husky/","dev/","docs/","src/",".editorconfig",".nvmrc",".prettierignore","CHANGELOG.md","config.example.json","docker-compose.yaml","eslint.config.mjs","prettier.config.cjs","tsconfig.json","vitest.config.ts"]},"_hasShrinkwrap":false,"readmeFilename":"README.md","devDependencies":{"tsx":"^4.19.1","tsup":"^8.3.0","husky":"^9.1.6","eslint":"^9.11.1","vitest":"^2.1.1","globals":"^15.9.0","prettier":"^3.3.3","npmignore":"^0.3.1","@eslint/js":"^9.11.1","@types/md5":"^2.3.5","release-it":"^17.6.0","@types/node":"^22.7.4","lint-staged":"^15.2.10","@types/prompts":"^2.4.9","@types/fs-extra":"^11.0.4","typescript-eslint":"^8.7.0","zod-to-json-schema":"^3.23.3","eslint-config-prettier":"^9.1.0","@release-it/conventional-changelog":"^8.0.2"},"_npmOperationalInternal":{"tmp":"tmp/loki-logs-downloader_4.0.0-beta.2_1728608767623_0.8400686614217414","host":"s3://npm-registry-packages"}},"4.0.0":{"name":"loki-logs-downloader","description":"Tool for downloading logs from Loki API","version":"4.0.0","license":"MIT","keywords":["loki"],"engines":{"node":">=20"},"main":"./dist/sdk.js","module":"./dist/sdk.mjs","types":"./dist/sdk.d.ts","bin":{"loki-logs-downloader":"dist/cli.js"},"homepage":"https://github.com/smowli/loki-logs-downloader/","repository":{"type":"git","url":"git+https://github.com/smowli/loki-logs-downloader.git"},"bugs":{"url":"https://github.com/smowli/loki-logs-downloader/issues"},"release-it":{"$schema":"https://unpkg.com/release-it/schema/release-it.json","github":{"release":true},"plugins":{"@release-it/conventional-changelog":{"preset":{"name":"conventionalcommits","types":[{"type":"feat","section":"Features 🚀"},{"type":"fix","section":"Bug Fixes 🦗"}]},"infile":"CHANGELOG.md"}}},"publishConfig":{"access":"public","ignore":[".github/",".husky/","dev/","docs/","src/",".editorconfig",".nvmrc",".prettierignore","CHANGELOG.md","config.example.json","docker-compose.yaml","eslint.config.mjs","prettier.config.cjs","tsconfig.json","vitest.config.ts"]},"scripts":{"build":"tsup --entry.cli ./src/cli.ts --entry.sdk ./src/sdk.ts --no-splitting --format cjs,esm --dts --clean --target=node20","exec":"npm run build && node ./dist/cli.js -c ./config.json","exec:dev":"tsx ./src/cli.ts -c ./config.json","exec:dev-cli":"tsx ./src/cli.ts","test":"vitest run --passWithNoTests --exclude=src/test/integration.spec.ts","test:all":"vitest run","test:dev":"vitest --passWithNoTests --exclude=src/test/integration.spec.ts","test:integration":"vitest src/test/integration.spec.ts","format:fix":"prettier --write --cache --ignore-unknown","format:fix-all":"npm run format:fix .","lint":"eslint","lint:fix":"eslint --fix --cache","lint:fix-all":"npm run lint:fix .","prepack":"npmignore --auto","prepare":"husky","prepublishOnly":"npm run build","release":"release-it","generate-config-schema":"tsx ./dev/config-schema.ts"},"lint-staged":{"*":["npm run lint:fix","npm run format:fix"]},"devDependencies":{"@eslint/js":"^9.11.1","@release-it/conventional-changelog":"^8.0.2","@types/fs-extra":"^11.0.4","@types/md5":"^2.3.5","@types/node":"^22.7.4","@types/prompts":"^2.4.9","eslint":"^9.11.1","eslint-config-prettier":"^9.1.0","globals":"^15.9.0","husky":"^9.1.6","lint-staged":"^15.2.10","npmignore":"^0.3.1","prettier":"^3.3.3","release-it":"^17.6.0","tsup":"^8.3.0","tsx":"^4.19.1","typescript-eslint":"^8.7.0","vitest":"^2.1.1","zod-to-json-schema":"^3.23.3"},"dependencies":{"commander":"^12.1.0","fs-extra":"^11.2.0","glob":"^11.0.0","md5":"^2.3.0","prompts":"^2.4.2","zod":"^3.23.8","zod-validation-error":"^3.4.0"},"_id":"loki-logs-downloader@4.0.0","gitHead":"14684a93b23dc7c69b156dfcd46c8f93f0aec801","_nodeVersion":"22.4.0","_npmVersion":"10.8.1","dist":{"integrity":"sha512-giNDodqsAb3X20mOb8iDhukOAC0dv5/UM6L+yZIq6RD3LGXZ6LBmobClorTymxYl7/aCWRP/x0Un67i6QGlLuA==","shasum":"d072c89943f12cff65c027f3479802d35427815f","tarball":"https://registry.npmjs.org/loki-logs-downloader/-/loki-logs-downloader-4.0.0.tgz","fileCount":12,"unpackedSize":127375,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIArWu0CNImEQ6z4mf46Tqz9v2I0lRa2WJngLs0GrlUZFAiALzGJQnUsRgvC4IdcvTITV65akDE4Z6X4M96gKE7c2YA=="}]},"_npmUser":{"name":"smowli","email":"vosmol@pm.me"},"directories":{},"maintainers":[{"name":"vosmol","email":"vo.smolar@gmail.com"},{"name":"smowli","email":"vosmol@pm.me"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/loki-logs-downloader_4.0.0_1728609051917_0.20437927733492667"},"_hasShrinkwrap":false}},"time":{"created":"2024-10-02T20:30:18.043Z","modified":"2024-10-11T01:10:52.312Z","2.1.0":"2024-10-02T20:30:18.390Z","2.1.1":"2024-10-02T20:47:56.579Z","2.1.2":"2024-10-02T21:26:03.197Z","2.2.0":"2024-10-03T20:12:55.782Z","2.2.1":"2024-10-03T20:26:22.519Z","2.2.2":"2024-10-03T20:33:49.337Z","2.2.3":"2024-10-04T07:02:32.297Z","2.2.4":"2024-10-04T07:07:48.698Z","3.0.0":"2024-10-06T16:38:44.727Z","3.0.1":"2024-10-06T16:40:00.351Z","3.0.2":"2024-10-06T16:41:28.586Z","3.0.3":"2024-10-06T16:45:30.205Z","3.0.4":"2024-10-06T16:48:40.589Z","3.0.5":"2024-10-06T17:01:28.006Z","3.0.6":"2024-10-06T17:13:50.251Z","3.0.7":"2024-10-06T17:17:07.274Z","3.1.0":"2024-10-06T21:57:50.244Z","3.2.0":"2024-10-10T13:31:28.721Z","4.0.0-beta.0":"2024-10-11T00:24:26.060Z","4.0.0-beta.1":"2024-10-11T00:48:07.771Z","4.0.0-beta.2":"2024-10-11T01:06:07.816Z","4.0.0":"2024-10-11T01:10:52.137Z"},"bugs":{"url":"https://github.com/smowli/loki-logs-downloader/issues"},"license":"MIT","homepage":"https://github.com/smowli/loki-logs-downloader/","keywords":["loki"],"repository":{"type":"git","url":"git+https://github.com/smowli/loki-logs-downloader.git"},"description":"Tool for downloading logs from Loki API","maintainers":[{"name":"vosmol","email":"vo.smolar@gmail.com"},{"name":"smowli","email":"vosmol@pm.me"}],"readme":"# 🗃️ Loki Logs Downloader\n\nUnofficial tool for downloading large amounts of logs from the Grafana Loki API 📖\n\n![Thumbnail](./docs/thumbnail.jpg)\n\n> ⚠️ This tool is still under active development. It is quite capable, but some features might still be missing. There also may be changes to the API and the behavior in the future. ⚠️\n\n## Table of contents\n\n- [✨ Introduction](#-introduction)\n- [🏃 Getting started](#-getting-started)\n  - [Installation](#installation)\n    - [CLI](#cli)\n    - [SDK](#sdk)\n  - [Configuration](#configuration)\n- [⌨️ Contributing](#️-contributing)\n\n## ✨ Introduction\n\nSo... you want to download or migrate all the logs of a certain query from Loki, huh? 🙈\n\nYou can somewhat use logCLI - the official CLI for Loki. It is a good general CLI, but when it comes to downloading logs, it can be cumbersome and inefficient:\n\n- https://community.grafana.com/t/how-to-gather-all-logs-for-annual-reports/99854/3\n- https://community.grafana.com/t/how-can-i-download-loki-logs/70304\n- https://stackoverflow.com/questions/64693913/download-logs-from-loki\n- https://github.com/grafana/loki/issues/2122\n\nWell, look no further! This is the tool you are most likely searching for because it can download these logs like there’s no tomorrow! 😎\n\n...\n<br>\n\nOn a more serious note, though 🗿, this tool is optimized to download all or part of queried logs with the least possible load on the Loki server, so you don't bomb 💥 the production. This is achieved in a few ways:\n\n- It stores the download state. If the download is not finished and you run the tool again with the same params it continues from where it previously left off = no repeated queries. Watch out for `from` & `to` options! If not set, default time [now - 1h] range will be different per run.\n- It queries the server in smaller batches that are easier to process.\n- It allows you to tweak key options affecting server load. For example:\n  - `batchRecords` - the number of records returned in a single API call (the `limit` parameter of the standard Loki API)\n  - `coolDown` - the time to wait before fetching the next batch of records\n  - `totalRecordsLimit` - the total limit of records that will be fetched from the API\n\nIt also comes in both **CLI and SDK flavors**. You can run it as-is, but advanced use cases are also possible. For example, you can plug in your custom file system interface and implement things like:\n\n- Backing up logs to a different storage system, like S3\n- Migrating logs to another log management system\n\n## 🏃 Getting Started\n\n### Installation & Usage\n\nThe package is published at [npm](https://www.npmjs.com/package/loki-logs-downloader)\n\n#### CLI:\n\nExecute it through npx\n\n```bash\nnpx loki-logs-downloader <...cli_params[]>\n```\n\n##### Examples\n\nFor list of all params use -h, --help flag:\n\n```bash\nnpx loki-logs-downloader -h\n```\n\nDownload logs for a whole day:\n\n```bash\nnpx loki-logs-downloader \\\n  --lokiUrl http://localhost:3100 \\\n  --query '{app=\"test\"}' \\\n  --from 2024-10-03T00:00:00.000Z \\\n  --to 2024-10-03T24:00:00.000Z \\\n  --fileRecordsLimit 1000 \\\n  --coolDown 1000\n```\n\nYou can also provide same params with a json config file:\n\n```bash\necho '{\n\"lokiUrl\": \"http://localhost:3100\",\n\"query\": \"{app=\\\"test\\\"}\",\n\"from\": \"2024-10-03T00:00:00.000Z\",\n\"to\": \"2024-10-03T24:00:00.000Z\",\n\"fileRecordsLimit\": 1000,\n\"coolDown\": 1000\n}' > ./config.json\n\nnpx loki-logs-downloader --configFile ./config.json\n```\n\n#### SDK:\n\n```bash\nnpm install loki-logs-downloader\n```\n\nAnd check [./dev/npm-check/sdk.ts](./dev/npm-check/sdk.ts) to see simple usage. There are also **cjs** and **mjs** versions right next to it.\n\n### Configuration\n\nBoth CLI and SDK have same options. You can run the CLI with -h flag to see more information and flag aliases.\n\nTo see all available config options refer to [./config-schema.json](./config-schema.json)\n\n## ⌨️ Contributing\n\nIf something is missing or not working as expected, feel free to open an issue—PRs with tests included are welcomed. 🫶\n\n### Local Development & Testing\n\n1. Use Node version `20>=` - you can run `nvm use` if you use nvm.\n2. Run `npm install`\n3. If you want to do test-driven development, run `npm run test:dev` to start tests in watch mode or `npm run test` for a single test run. The majority of tests run against a mocked version of the Loki API.\n4. If you want to develop against the real Loki API, you will need to provide your own `lokiUrl` or start Loki locally on `port 3100` with this [docker compose file](./docker-compose.yaml) by running `docker compose up -d`\n5. If you want to test against the real Loki API, there is an [integration test for that](./src/test/integration.spec.ts) which you can run with `npm run test:integration`\n   - **⚠️ Watch out: the integration test will try to push plenty of logs to the Loki API on localhost:3100 (DEFAULT_LOKI_URL) ⚠️**\n6. To start the dev environment:\n\n   1. Run `cp ./config.example.json ./config.json`, which has the `promptToStart` option (it will prompt you for keyboard confirmation before anything happens).\n   2. Here in the `config.json` set `lokiUrl` to the running server.\n   3. Run `npm run exec:dev` which consumes the config.json or `npm run exec:dev-cli` which consumes the cli params\n","readmeFilename":"README.md"}