From b52456044ccb1689c312e408ee9338472d5af1e6 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Tue, 3 Dec 2024 15:59:03 -0500 Subject: [PATCH 1/7] Update typescript-eslint monorepo to v8.17.0 (#421) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- pnpm-lock.yaml | 104 ++++++++++++++++++++++++------------------------- 1 file changed, 52 insertions(+), 52 deletions(-) diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index f7d4169..668d483 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -13,10 +13,10 @@ importers: version: 22.10.1 '@typescript-eslint/eslint-plugin': specifier: ^8.7.0 - version: 8.16.0(@typescript-eslint/parser@8.16.0(eslint@9.16.0)(typescript@5.7.2))(eslint@9.16.0)(typescript@5.7.2) + version: 8.17.0(@typescript-eslint/parser@8.17.0(eslint@9.16.0)(typescript@5.7.2))(eslint@9.16.0)(typescript@5.7.2) '@typescript-eslint/parser': specifier: ^8.7.0 - version: 8.16.0(eslint@9.16.0)(typescript@5.7.2) + version: 8.17.0(eslint@9.16.0)(typescript@5.7.2) eslint: specifier: ^9.11.1 version: 9.16.0 @@ -52,7 +52,7 @@ importers: version: 5.7.2 typescript-eslint: specifier: ^8.7.0 - version: 8.16.0(eslint@9.16.0)(typescript@5.7.2) + version: 8.17.0(eslint@9.16.0)(typescript@5.7.2) packages: @@ -246,8 +246,8 @@ packages: '@types/unist@3.0.3': resolution: {integrity: sha512-ko/gIFJRv177XgZsZcBwnqJN5x/Gien8qNOn0D5bQU/zAzVf9Zt3BlcUiLqhV9y4ARk0GbT3tnUiPNgnTXzc/Q==} - '@typescript-eslint/eslint-plugin@8.16.0': - resolution: {integrity: sha512-5YTHKV8MYlyMI6BaEG7crQ9BhSc8RxzshOReKwZwRWN0+XvvTOm+L/UYLCYxFpfwYuAAqhxiq4yae0CMFwbL7Q==} + '@typescript-eslint/eslint-plugin@8.17.0': + resolution: {integrity: sha512-HU1KAdW3Tt8zQkdvNoIijfWDMvdSweFYm4hWh+KwhPstv+sCmWb89hCIP8msFm9N1R/ooh9honpSuvqKWlYy3w==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} peerDependencies: '@typescript-eslint/parser': ^8.0.0 || ^8.0.0-alpha.0 @@ -257,8 +257,8 @@ packages: typescript: optional: true - '@typescript-eslint/parser@8.16.0': - resolution: {integrity: sha512-D7DbgGFtsqIPIFMPJwCad9Gfi/hC0PWErRRHFnaCWoEDYi5tQUDiJCTmGUbBiLzjqAck4KcXt9Ayj0CNlIrF+w==} + '@typescript-eslint/parser@8.17.0': + resolution: {integrity: sha512-Drp39TXuUlD49F7ilHHCG7TTg8IkA+hxCuULdmzWYICxGXvDXmDmWEjJYZQYgf6l/TFfYNE167m7isnc3xlIEg==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} peerDependencies: eslint: ^8.57.0 || ^9.0.0 @@ -267,12 +267,12 @@ packages: typescript: optional: true - '@typescript-eslint/scope-manager@8.16.0': - resolution: {integrity: sha512-mwsZWubQvBki2t5565uxF0EYvG+FwdFb8bMtDuGQLdCCnGPrDEDvm1gtfynuKlnpzeBRqdFCkMf9jg1fnAK8sg==} + '@typescript-eslint/scope-manager@8.17.0': + resolution: {integrity: sha512-/ewp4XjvnxaREtqsZjF4Mfn078RD/9GmiEAtTeLQ7yFdKnqwTOgRMSvFz4et9U5RiJQ15WTGXPLj89zGusvxBg==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - '@typescript-eslint/type-utils@8.16.0': - resolution: {integrity: sha512-IqZHGG+g1XCWX9NyqnI/0CX5LL8/18awQqmkZSl2ynn8F76j579dByc0jhfVSnSnhf7zv76mKBQv9HQFKvDCgg==} + '@typescript-eslint/type-utils@8.17.0': + resolution: {integrity: sha512-q38llWJYPd63rRnJ6wY/ZQqIzPrBCkPdpIsaCfkR3Q4t3p6sb422zougfad4TFW9+ElIFLVDzWGiGAfbb/v2qw==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} peerDependencies: eslint: ^8.57.0 || ^9.0.0 @@ -281,12 +281,12 @@ packages: typescript: optional: true - '@typescript-eslint/types@8.16.0': - resolution: {integrity: sha512-NzrHj6thBAOSE4d9bsuRNMvk+BvaQvmY4dDglgkgGC0EW/tB3Kelnp3tAKH87GEwzoxgeQn9fNGRyFJM/xd+GQ==} + '@typescript-eslint/types@8.17.0': + resolution: {integrity: sha512-gY2TVzeve3z6crqh2Ic7Cr+CAv6pfb0Egee7J5UAVWCpVvDI/F71wNfolIim4FE6hT15EbpZFVUj9j5i38jYXA==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - '@typescript-eslint/typescript-estree@8.16.0': - resolution: {integrity: sha512-E2+9IzzXMc1iaBy9zmo+UYvluE3TW7bCGWSF41hVWUE01o8nzr1rvOQYSxelxr6StUvRcTMe633eY8mXASMaNw==} + '@typescript-eslint/typescript-estree@8.17.0': + resolution: {integrity: sha512-JqkOopc1nRKZpX+opvKqnM3XUlM7LpFMD0lYxTqOTKQfCWAmxw45e3qlOCsEqEB2yuacujivudOFpCnqkBDNMw==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} peerDependencies: typescript: '*' @@ -294,8 +294,8 @@ packages: typescript: optional: true - '@typescript-eslint/utils@8.16.0': - resolution: {integrity: sha512-C1zRy/mOL8Pj157GiX4kaw7iyRLKfJXBR3L82hk5kS/GyHcOFmy4YUq/zfZti72I9wnuQtA/+xzft4wCC8PJdA==} + '@typescript-eslint/utils@8.17.0': + resolution: {integrity: sha512-bQC8BnEkxqG8HBGKwG9wXlZqg37RKSMY7v/X8VEWD8JG2JuTHuNK0VFvMPMUKQcbk6B+tf05k+4AShAEtCtJ/w==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} peerDependencies: eslint: ^8.57.0 || ^9.0.0 @@ -304,8 +304,8 @@ packages: typescript: optional: true - '@typescript-eslint/visitor-keys@8.16.0': - resolution: {integrity: sha512-pq19gbaMOmFE3CbL0ZB8J8BFCo2ckfHBfaIsaOZgBIF4EoISJIdLX5xRhd0FGB0LlHReNRuzoJoMGpTjq8F2CQ==} + '@typescript-eslint/visitor-keys@8.17.0': + resolution: {integrity: sha512-1Hm7THLpO6ww5QU6H/Qp+AusUUl+z/CAm3cNZZ0jQvon9yicgO7Rwd+/WWRpMKLYV6p2UvdbR27c86rzCPpreg==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} acorn-jsx@5.3.2: @@ -1149,8 +1149,8 @@ packages: peerDependencies: typescript: 5.0.x || 5.1.x || 5.2.x || 5.3.x || 5.4.x || 5.5.x || 5.6.x || 5.7.x - typescript-eslint@8.16.0: - resolution: {integrity: sha512-wDkVmlY6O2do4V+lZd0GtRfbtXbeD0q9WygwXXSJnC1xorE8eqyC2L1tJimqpSeFrOzRlYtWnUp/uzgHQOgfBQ==} + typescript-eslint@8.17.0: + resolution: {integrity: sha512-409VXvFd/f1br1DCbuKNFqQpXICoTB+V51afcwG1pn1a3Cp92MqAUges3YjwEdQ0cMUoCIodjVDAYzyD8h3SYA==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} peerDependencies: eslint: ^8.57.0 || ^9.0.0 @@ -1448,14 +1448,14 @@ snapshots: '@types/unist@3.0.3': {} - '@typescript-eslint/eslint-plugin@8.16.0(@typescript-eslint/parser@8.16.0(eslint@9.16.0)(typescript@5.7.2))(eslint@9.16.0)(typescript@5.7.2)': + '@typescript-eslint/eslint-plugin@8.17.0(@typescript-eslint/parser@8.17.0(eslint@9.16.0)(typescript@5.7.2))(eslint@9.16.0)(typescript@5.7.2)': dependencies: '@eslint-community/regexpp': 4.12.1 - '@typescript-eslint/parser': 8.16.0(eslint@9.16.0)(typescript@5.7.2) - '@typescript-eslint/scope-manager': 8.16.0 - '@typescript-eslint/type-utils': 8.16.0(eslint@9.16.0)(typescript@5.7.2) - '@typescript-eslint/utils': 8.16.0(eslint@9.16.0)(typescript@5.7.2) - '@typescript-eslint/visitor-keys': 8.16.0 + '@typescript-eslint/parser': 8.17.0(eslint@9.16.0)(typescript@5.7.2) + '@typescript-eslint/scope-manager': 8.17.0 + '@typescript-eslint/type-utils': 8.17.0(eslint@9.16.0)(typescript@5.7.2) + '@typescript-eslint/utils': 8.17.0(eslint@9.16.0)(typescript@5.7.2) + '@typescript-eslint/visitor-keys': 8.17.0 eslint: 9.16.0 graphemer: 1.4.0 ignore: 5.3.2 @@ -1466,12 +1466,12 @@ snapshots: transitivePeerDependencies: - supports-color - '@typescript-eslint/parser@8.16.0(eslint@9.16.0)(typescript@5.7.2)': + '@typescript-eslint/parser@8.17.0(eslint@9.16.0)(typescript@5.7.2)': dependencies: - '@typescript-eslint/scope-manager': 8.16.0 - '@typescript-eslint/types': 8.16.0 - '@typescript-eslint/typescript-estree': 8.16.0(typescript@5.7.2) - '@typescript-eslint/visitor-keys': 8.16.0 + '@typescript-eslint/scope-manager': 8.17.0 + '@typescript-eslint/types': 8.17.0 + '@typescript-eslint/typescript-estree': 8.17.0(typescript@5.7.2) + '@typescript-eslint/visitor-keys': 8.17.0 debug: 4.3.7 eslint: 9.16.0 optionalDependencies: @@ -1479,15 +1479,15 @@ snapshots: transitivePeerDependencies: - supports-color - '@typescript-eslint/scope-manager@8.16.0': + '@typescript-eslint/scope-manager@8.17.0': dependencies: - '@typescript-eslint/types': 8.16.0 - '@typescript-eslint/visitor-keys': 8.16.0 + '@typescript-eslint/types': 8.17.0 + '@typescript-eslint/visitor-keys': 8.17.0 - '@typescript-eslint/type-utils@8.16.0(eslint@9.16.0)(typescript@5.7.2)': + '@typescript-eslint/type-utils@8.17.0(eslint@9.16.0)(typescript@5.7.2)': dependencies: - '@typescript-eslint/typescript-estree': 8.16.0(typescript@5.7.2) - '@typescript-eslint/utils': 8.16.0(eslint@9.16.0)(typescript@5.7.2) + '@typescript-eslint/typescript-estree': 8.17.0(typescript@5.7.2) + '@typescript-eslint/utils': 8.17.0(eslint@9.16.0)(typescript@5.7.2) debug: 4.3.7 eslint: 9.16.0 ts-api-utils: 1.4.3(typescript@5.7.2) @@ -1496,12 +1496,12 @@ snapshots: transitivePeerDependencies: - supports-color - '@typescript-eslint/types@8.16.0': {} + '@typescript-eslint/types@8.17.0': {} - '@typescript-eslint/typescript-estree@8.16.0(typescript@5.7.2)': + '@typescript-eslint/typescript-estree@8.17.0(typescript@5.7.2)': dependencies: - '@typescript-eslint/types': 8.16.0 - '@typescript-eslint/visitor-keys': 8.16.0 + '@typescript-eslint/types': 8.17.0 + '@typescript-eslint/visitor-keys': 8.17.0 debug: 4.3.7 fast-glob: 3.3.2 is-glob: 4.0.3 @@ -1513,21 +1513,21 @@ snapshots: transitivePeerDependencies: - supports-color - '@typescript-eslint/utils@8.16.0(eslint@9.16.0)(typescript@5.7.2)': + '@typescript-eslint/utils@8.17.0(eslint@9.16.0)(typescript@5.7.2)': dependencies: '@eslint-community/eslint-utils': 4.4.1(eslint@9.16.0) - '@typescript-eslint/scope-manager': 8.16.0 - '@typescript-eslint/types': 8.16.0 - '@typescript-eslint/typescript-estree': 8.16.0(typescript@5.7.2) + '@typescript-eslint/scope-manager': 8.17.0 + '@typescript-eslint/types': 8.17.0 + '@typescript-eslint/typescript-estree': 8.17.0(typescript@5.7.2) eslint: 9.16.0 optionalDependencies: typescript: 5.7.2 transitivePeerDependencies: - supports-color - '@typescript-eslint/visitor-keys@8.16.0': + '@typescript-eslint/visitor-keys@8.17.0': dependencies: - '@typescript-eslint/types': 8.16.0 + '@typescript-eslint/types': 8.17.0 eslint-visitor-keys: 4.2.0 acorn-jsx@5.3.2(acorn@8.14.0): @@ -2301,11 +2301,11 @@ snapshots: typescript: 5.7.2 yaml: 2.6.1 - typescript-eslint@8.16.0(eslint@9.16.0)(typescript@5.7.2): + typescript-eslint@8.17.0(eslint@9.16.0)(typescript@5.7.2): dependencies: - '@typescript-eslint/eslint-plugin': 8.16.0(@typescript-eslint/parser@8.16.0(eslint@9.16.0)(typescript@5.7.2))(eslint@9.16.0)(typescript@5.7.2) - '@typescript-eslint/parser': 8.16.0(eslint@9.16.0)(typescript@5.7.2) - '@typescript-eslint/utils': 8.16.0(eslint@9.16.0)(typescript@5.7.2) + '@typescript-eslint/eslint-plugin': 8.17.0(@typescript-eslint/parser@8.17.0(eslint@9.16.0)(typescript@5.7.2))(eslint@9.16.0)(typescript@5.7.2) + '@typescript-eslint/parser': 8.17.0(eslint@9.16.0)(typescript@5.7.2) + '@typescript-eslint/utils': 8.17.0(eslint@9.16.0)(typescript@5.7.2) eslint: 9.16.0 optionalDependencies: typescript: 5.7.2 From 210264e474b014187ececa5c88ac693fe81de394 Mon Sep 17 00:00:00 2001 From: Dessalines Date: Tue, 3 Dec 2024 18:13:16 -0500 Subject: [PATCH 2/7] Fixing woodpecker secrets warning. (#420) --- .woodpecker.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.woodpecker.yml b/.woodpecker.yml index 07258c9..63aeaf5 100644 --- a/.woodpecker.yml +++ b/.woodpecker.yml @@ -20,12 +20,14 @@ steps: npm_publish: image: node:alpine + environment: + NPM_TOKEN: + from_secret: npm_token commands: - *install_pnpm - pnpm i - echo "//registry.npmjs.org/:_authToken=$NPM_TOKEN" >> .npmrc - echo "email = tyhou13@gmx.com" >> ~/.npmrc - npm publish - secrets: [npm_token] when: - event: tag From 1454ecb8aad44342e6cf4d363bc0850b8e0ea236 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Fri, 6 Dec 2024 19:44:35 -0500 Subject: [PATCH 3/7] Update dependency prettier to v3.4.2 (#422) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- pnpm-lock.yaml | 32 ++++++++++++++++---------------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 668d483..f56b822 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -22,7 +22,7 @@ importers: version: 9.16.0 eslint-plugin-prettier: specifier: ^5.2.1 - version: 5.2.1(eslint-config-prettier@9.1.0(eslint@9.16.0))(eslint@9.16.0)(prettier@3.4.1) + version: 5.2.1(eslint-config-prettier@9.1.0(eslint@9.16.0))(eslint@9.16.0)(prettier@3.4.2) husky: specifier: ^9.1.4 version: 9.1.7 @@ -31,16 +31,16 @@ importers: version: 15.2.10 prettier: specifier: ^3.3.3 - version: 3.4.1 + version: 3.4.2 prettier-plugin-import-sort: specifier: ^0.0.7 - version: 0.0.7(prettier@3.4.1) + version: 0.0.7(prettier@3.4.2) prettier-plugin-organize-imports: specifier: ^4.0.0 - version: 4.1.0(prettier@3.4.1)(typescript@5.7.2) + version: 4.1.0(prettier@3.4.2)(typescript@5.7.2) prettier-plugin-packagejson: specifier: ^2.5.1 - version: 2.5.6(prettier@3.4.1) + version: 2.5.6(prettier@3.4.2) sortpack: specifier: ^2.4.0 version: 2.4.0 @@ -988,8 +988,8 @@ packages: prettier: optional: true - prettier@3.4.1: - resolution: {integrity: sha512-G+YdqtITVZmOJje6QkXQWzl3fSfMxFwm1tjTyo9exhkmWSqC4Yhd1+lug++IlR2mvRVAxEDDWYkQdeSztajqgg==} + prettier@3.4.2: + resolution: {integrity: sha512-e9MewbtFo+Fevyuxn/4rrcDAaq0IYxPGLvObpQjiZBMAzB9IGmzlnG9RZy3FFas+eBMu2vA0CszMeduow5dIuQ==} engines: {node: '>=14'} hasBin: true @@ -1703,10 +1703,10 @@ snapshots: eslint: 9.16.0 optional: true - eslint-plugin-prettier@5.2.1(eslint-config-prettier@9.1.0(eslint@9.16.0))(eslint@9.16.0)(prettier@3.4.1): + eslint-plugin-prettier@5.2.1(eslint-config-prettier@9.1.0(eslint@9.16.0))(eslint@9.16.0)(prettier@3.4.2): dependencies: eslint: 9.16.0 - prettier: 3.4.1 + prettier: 3.4.2 prettier-linter-helpers: 1.0.0 synckit: 0.9.1 optionalDependencies: @@ -2141,29 +2141,29 @@ snapshots: dependencies: fast-diff: 1.3.0 - prettier-plugin-import-sort@0.0.7(prettier@3.4.1): + prettier-plugin-import-sort@0.0.7(prettier@3.4.2): dependencies: import-sort: 6.0.0 import-sort-config: 6.0.0 import-sort-parser-babylon: 6.0.0 import-sort-parser-typescript: 6.0.0 - prettier: 3.4.1 + prettier: 3.4.2 transitivePeerDependencies: - supports-color - prettier-plugin-organize-imports@4.1.0(prettier@3.4.1)(typescript@5.7.2): + prettier-plugin-organize-imports@4.1.0(prettier@3.4.2)(typescript@5.7.2): dependencies: - prettier: 3.4.1 + prettier: 3.4.2 typescript: 5.7.2 - prettier-plugin-packagejson@2.5.6(prettier@3.4.1): + prettier-plugin-packagejson@2.5.6(prettier@3.4.2): dependencies: sort-package-json: 2.12.0 synckit: 0.9.2 optionalDependencies: - prettier: 3.4.1 + prettier: 3.4.2 - prettier@3.4.1: {} + prettier@3.4.2: {} punycode.js@2.3.1: {} From 23f64d1e18cd614b197a106ae79610e6af1559c2 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Fri, 6 Dec 2024 19:45:06 -0500 Subject: [PATCH 4/7] Update dependency typedoc to v0.27.3 (#423) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- pnpm-lock.yaml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index f56b822..92665cd 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -46,7 +46,7 @@ importers: version: 2.4.0 typedoc: specifier: ^0.27.0 - version: 0.27.2(typescript@5.7.2) + version: 0.27.3(typescript@5.7.2) typescript: specifier: ^5.5.4 version: 5.7.2 @@ -1142,8 +1142,8 @@ packages: resolution: {integrity: sha512-XleUoc9uwGXqjWwXaUTZAmzMcFZ5858QA2vvx1Ur5xIcixXIP+8LnFDgRplU30us6teqdlskFfu+ae4K79Ooew==} engines: {node: '>= 0.8.0'} - typedoc@0.27.2: - resolution: {integrity: sha512-C2ima5TZJHU3ecnRIz50lKd1BsYck5LhYQIy7MRPmjuSEJreUEAt+uAVcZgY7wZsSORzEI7xW8miZIdxv/cbmw==} + typedoc@0.27.3: + resolution: {integrity: sha512-oWT7zDS5oIaxYL5yOikBX4cL99CpNAZn6mI24JZQxsYuIHbtguSSwJ7zThuzNNwSE0wqhlfTSd99HgqKu2aQXQ==} engines: {node: '>= 18'} hasBin: true peerDependencies: @@ -2292,7 +2292,7 @@ snapshots: dependencies: prelude-ls: 1.2.1 - typedoc@0.27.2(typescript@5.7.2): + typedoc@0.27.3(typescript@5.7.2): dependencies: '@gerrit0/mini-shiki': 1.24.1 lunr: 2.3.9 From 5e47bf67f133bdcf4d8bc934e0ab0c57b8849bcd Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Fri, 6 Dec 2024 22:22:35 -0500 Subject: [PATCH 5/7] Update pnpm to v9.15.0 (#424) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index b4ad899..1b38f81 100644 --- a/package.json +++ b/package.json @@ -35,7 +35,7 @@ "typescript": "^5.5.4", "typescript-eslint": "^8.7.0" }, - "packageManager": "pnpm@9.14.4", + "packageManager": "pnpm@9.15.0", "types": "./dist/index.d.ts", "lint-staged": { "*.{ts,tsx,js}": [ From 792bed9a01630ffe689afc32610b7aad64e239db Mon Sep 17 00:00:00 2001 From: Nutomic Date: Sat, 7 Dec 2024 22:53:44 +0000 Subject: [PATCH 6/7] Changes for api v4 (#410) * Instance blocks with mod log entry and expiration * 0.20.0-instance-blocks.0 * fix methods * 0.20.0-instance-blocks.1 * remove params * 0.20.0-instance-blocks.2 * pass domain * 0.20.0-instance-blocks.3 * add file * 0.20.0-instance-blocks.4 * pass instance domain * 0.20.0-instance-blocks.5 * Changes for api v4 * 0.20.0-api-v4.0 * 0.20.0-api-v4.1 * remove param * 0.20.0-api-v4.2 * remove GetSiteResponse.my_user * 0.20.0-api-v4.3 * 0.20.0-api-v4.4 * fix path * 0.20.0-api-v4.5 * fix path * 0.20.0-api-v4.6 * 0.20.0-api-v4.7 * 0.20.0-api-v4.8 * move block endpoints * 0.20.0-api-v4.9 * fix path * 0.20.0-api-v4.10 * fix * 0.20.0-api-v4.11 * change /admin/block_instance to /admin/instance/block (and same for allow) * 0.20.0-api-v4.12 * fix mark all read * 0.20.0-api-v4.13 * fix user endpoints * 0.20.0-api-v4.14 * add MarkManyPostsAsRead * change account route * 0.20.0-api-v4.15 * rename mention mark as read * 0.20.0-api-v4.16 --------- Co-authored-by: Dessalines --- src/http.ts | 172 ++++++++++++++++++++++------------- src/other_types.ts | 2 +- src/types/GetSiteResponse.ts | 2 - 3 files changed, 109 insertions(+), 67 deletions(-) diff --git a/src/http.ts b/src/http.ts index daa129a..31ac0ca 100644 --- a/src/http.ts +++ b/src/http.ts @@ -5,6 +5,7 @@ import { AddModToCommunityResponse } from "./types/AddModToCommunityResponse"; import { ApproveRegistrationApplication } from "./types/ApproveRegistrationApplication"; import { BanFromCommunity } from "./types/BanFromCommunity"; import { BanFromCommunityResponse } from "./types/BanFromCommunityResponse"; +import { MarkManyPostsAsRead } from "./types/MarkManyPostsAsRead"; import { BanPerson } from "./types/BanPerson"; import { BanPersonResponse } from "./types/BanPersonResponse"; import { BannedPersonsResponse } from "./types/BannedPersonsResponse"; @@ -158,6 +159,7 @@ import { GetCommunityPendingFollowsCountResponse } from "./types/GetCommunityPen import { ListCommunityPendingFollowsResponse } from "./types/ListCommunityPendingFollowsResponse"; import { ListCommunityPendingFollows } from "./types/ListCommunityPendingFollows"; import { CommunityId } from "./types/CommunityId"; +import { MyUserInfo } from "./types/MyUserInfo"; import { UserBlockInstanceParams } from "./types/UserBlockInstanceParams"; import { AdminAllowInstanceParams } from "./types/AdminAllowInstanceParams"; import { AdminBlockInstanceParams } from "./types/AdminBlockInstanceParams"; @@ -247,12 +249,12 @@ export class LemmyHttp { /** * Leave the Site admins. * - * `HTTP.POST /user/leave_admin` + * `HTTP.POST /admin/leave` */ leaveAdmin(options?: RequestOptions) { return this.#wrapper( HttpType.Post, - "/user/leave_admin", + "/admin/leave", {}, options, ); @@ -261,14 +263,28 @@ export class LemmyHttp { /** * Generate a TOTP / two-factor secret. * - * Afterwards you need to call `/user/totp/update` with a valid token to enable it. + * Afterwards you need to call `/account/auth/totp/update` with a valid token to enable it. * - * `HTTP.POST /user/totp/generate` + * `HTTP.POST /account/auth/totp/generate` */ generateTotpSecret(options?: RequestOptions) { return this.#wrapper( HttpType.Post, - "/user/totp/generate", + "/account/auth/totp/generate", + {}, + options, + ); + } + + /** + * Get data of current user. + * + * `HTTP.GET /account` + */ + getMyUser(options?: RequestOptions) { + return this.#wrapper( + HttpType.Get, + "/account", {}, options, ); @@ -278,12 +294,12 @@ export class LemmyHttp { * Export a backup of your user settings, including your saved content, * followed communities, and blocks. * - * `HTTP.GET /user/export_settings` + * `HTTP.GET /account/settings/export` */ exportSettings(options?: RequestOptions) { return this.#wrapper( HttpType.Get, - "/user/export_settings", + "/account/settings/export", {}, options, ); @@ -292,12 +308,12 @@ export class LemmyHttp { /** * Import a backup of your user settings. * - * `HTTP.POST /user/import_settings` + * `HTTP.POST /account/settings/import` */ importSettings(form: any, options?: RequestOptions) { return this.#wrapper( HttpType.Post, - "/user/import_settings", + "/account/settings/import", form, options, ); @@ -306,12 +322,12 @@ export class LemmyHttp { /** * List login tokens for your user * - * `HTTP.GET /user/list_logins` + * `HTTP.GET /account/list_logins` */ listLogins(options?: RequestOptions) { return this.#wrapper( HttpType.Get, - "/user/list_logins", + "/account/list_logins", {}, options, ); @@ -320,12 +336,12 @@ export class LemmyHttp { /** * Returns an error message if your auth token is invalid * - * `HTTP.GET /user/validate_auth` + * `HTTP.GET /account/validate_auth` */ validateAuth(options?: RequestOptions) { return this.#wrapper( HttpType.Get, - "/user/validate_auth", + "/account/validate_auth", {}, options, ); @@ -362,16 +378,16 @@ export class LemmyHttp { /** * Enable / Disable TOTP / two-factor authentication. * - * To enable, you need to first call `/user/totp/generate` and then pass a valid token to this. + * To enable, you need to first call `/account/auth/totp/generate` and then pass a valid token to this. * * Disabling is only possible if 2FA was previously enabled. Again it is necessary to pass a valid token. * - * `HTTP.POST /user/totp/update` + * `HTTP.POST /account/auth/totp/update` */ updateTotp(form: UpdateTotp, options?: RequestOptions) { return this.#wrapper( HttpType.Post, - "/user/totp/update", + "/account/auth/totp/update", form, options, ); @@ -525,12 +541,12 @@ export class LemmyHttp { /** * Block a community. * - * `HTTP.POST /community/block` + * `HTTP.POST /account/block/community` */ blockCommunity(form: BlockCommunity, options?: RequestOptions) { return this.#wrapper( HttpType.Post, - "/community/block", + "/account/block/community", form, options, ); @@ -718,6 +734,20 @@ export class LemmyHttp { ); } + /** + * Mark multiple posts as read. + * + * `HTTP.POST /post/mark_as_read/many` + */ + markManyPostAsRead(form: MarkManyPostsAsRead, options?: RequestOptions) { + return this.#wrapper( + HttpType.Post, + "/post/mark_as_read/many", + form, + options, + ); + } + /** * Hide a post from list views. * @@ -1192,12 +1222,12 @@ export class LemmyHttp { /** * Register a new user. * - * `HTTP.POST /user/register` + * `HTTP.POST /account/auth/register` */ register(form: Register, options?: RequestOptions) { return this.#wrapper( HttpType.Post, - "/user/register", + "/account/auth/register", form, options, ); @@ -1206,12 +1236,12 @@ export class LemmyHttp { /** * Log into lemmy. * - * `HTTP.POST /user/login` + * `HTTP.POST /account/auth/login` */ login(form: Login, options?: RequestOptions) { return this.#wrapper( HttpType.Post, - "/user/login", + "/account/auth/login", form, options, ); @@ -1220,12 +1250,12 @@ export class LemmyHttp { /** * Invalidate the currently used auth token. * - * `HTTP.POST /user/logout` + * `HTTP.POST /account/auth/logout` */ logout(options?: RequestOptions) { return this.#wrapper( HttpType.Post, - "/user/logout", + "/account/auth/logout", {}, options, ); @@ -1234,12 +1264,12 @@ export class LemmyHttp { /** * Get the details for a person. * - * `HTTP.GET /user` + * `HTTP.GET /person` */ getPersonDetails(form: GetPersonDetails = {}, options?: RequestOptions) { return this.#wrapper( HttpType.Get, - "/user", + "/person", form, options, ); @@ -1248,12 +1278,12 @@ export class LemmyHttp { /** * Get mentions for your user. * - * `HTTP.GET /user/mention` + * `HTTP.GET /account/mention` */ getPersonMentions(form: GetPersonMentions, options?: RequestOptions) { return this.#wrapper( HttpType.Get, - "/user/mention", + "/account/mention", form, options, ); @@ -1262,7 +1292,7 @@ export class LemmyHttp { /** * Mark a person mention as read. * - * `HTTP.POST /user/mention/mark_as_read` + * `HTTP.POST /account/mention/mark_as_read` */ markPersonMentionAsRead( form: MarkPersonMentionAsRead, @@ -1270,21 +1300,35 @@ export class LemmyHttp { ) { return this.#wrapper( HttpType.Post, - "/user/mention/mark_as_read", + "/account/mention/mark_as_read", form, options, ); } + /** + * Mark a person mention as read. + * + * `HTTP.POST /account/mention/mark_as_read` + */ + markPersonAllMentionAsRead(options?: RequestOptions) { + return this.#wrapper( + HttpType.Post, + "/account/mention/mark_as_read", + {}, + options, + ); + } + /** * Get comment replies. * - * `HTTP.GET /user/replies` + * `HTTP.GET /account/replies` */ getReplies(form: GetReplies, options?: RequestOptions) { return this.#wrapper( HttpType.Get, - "/user/replies", + "/account/replies", form, options, ); @@ -1293,12 +1337,12 @@ export class LemmyHttp { /** * Ban a person from your site. * - * `HTTP.POST /user/ban` + * `HTTP.POST /admin/ban` */ banPerson(form: BanPerson, options?: RequestOptions) { return this.#wrapper( HttpType.Post, - "/user/ban", + "/admin/ban", form, options, ); @@ -1307,12 +1351,12 @@ export class LemmyHttp { /** * Get a list of banned users * - * `HTTP.GET /user/banned` + * `HTTP.GET /admin/banned` */ getBannedPersons(options?: RequestOptions) { return this.#wrapper( HttpType.Get, - "/user/banned", + "/admin/banned", {}, options, ); @@ -1321,12 +1365,12 @@ export class LemmyHttp { /** * Block a person. * - * `HTTP.POST /user/block` + * `HTTP.POST /account/block/person` */ blockPerson(form: BlockPerson, options?: RequestOptions) { return this.#wrapper( HttpType.Post, - "/user/block", + "/account/block/person", form, options, ); @@ -1335,12 +1379,12 @@ export class LemmyHttp { /** * Fetch a Captcha. * - * `HTTP.GET /user/get_captcha` + * `HTTP.GET /account/auth/get_captcha` */ getCaptcha(options?: RequestOptions) { return this.#wrapper( HttpType.Get, - "/user/get_captcha", + "/account/auth/get_captcha", {}, options, ); @@ -1349,12 +1393,12 @@ export class LemmyHttp { /** * Delete your account. * - * `HTTP.POST /user/delete_account` + * `HTTP.POST /account/delete` */ deleteAccount(form: DeleteAccount, options?: RequestOptions) { return this.#wrapper( HttpType.Post, - "/user/delete_account", + "/account/delete", form, options, ); @@ -1363,12 +1407,12 @@ export class LemmyHttp { /** * Reset your password. * - * `HTTP.POST /user/password_reset` + * `HTTP.POST /account/auth/password_reset` */ passwordReset(form: PasswordReset, options?: RequestOptions) { return this.#wrapper( HttpType.Post, - "/user/password_reset", + "/account/auth/password_reset", form, options, ); @@ -1377,7 +1421,7 @@ export class LemmyHttp { /** * Change your password from an email / token based reset. * - * `HTTP.POST /user/password_change` + * `HTTP.POST /account/auth/password_change` */ passwordChangeAfterReset( form: PasswordChangeAfterReset, @@ -1385,7 +1429,7 @@ export class LemmyHttp { ) { return this.#wrapper( HttpType.Post, - "/user/password_change", + "/account/auth/password_change", form, options, ); @@ -1394,12 +1438,12 @@ export class LemmyHttp { /** * Mark all replies as read. * - * `HTTP.POST /user/mark_all_as_read` + * `HTTP.POST /account/mention/mark_as_read/all` */ markAllAsRead(options?: RequestOptions) { return this.#wrapper( HttpType.Post, - "/user/mark_all_as_read", + "/account/mention/mark_as_read/all", {}, options, ); @@ -1408,12 +1452,12 @@ export class LemmyHttp { /** * Save your user settings. * - * `HTTP.PUT /user/save_user_settings` + * `HTTP.PUT /account/settings/save` */ saveUserSettings(form: SaveUserSettings, options?: RequestOptions) { return this.#wrapper( HttpType.Put, - "/user/save_user_settings", + "/account/settings/save", form, options, ); @@ -1422,12 +1466,12 @@ export class LemmyHttp { /** * Change your user password. * - * `HTTP.PUT /user/change_password` + * `HTTP.PUT /account/auth/change_password` */ changePassword(form: ChangePassword, options?: RequestOptions) { return this.#wrapper( HttpType.Put, - "/user/change_password", + "/account/auth/change_password", form, options, ); @@ -1436,12 +1480,12 @@ export class LemmyHttp { /** * Get counts for your reports * - * `HTTP.GET /user/report_count` + * `HTTP.GET /account/report_count` */ getReportCount(form: GetReportCount, options?: RequestOptions) { return this.#wrapper( HttpType.Get, - "/user/report_count", + "/account/report_count", form, options, ); @@ -1450,12 +1494,12 @@ export class LemmyHttp { /** * Get your unread counts * - * `HTTP.GET /user/unread_count` + * `HTTP.GET /account/unread_count` */ getUnreadCount(options?: RequestOptions) { return this.#wrapper( HttpType.Get, - "/user/unread_count", + "/account/unread_count", {}, options, ); @@ -1464,12 +1508,12 @@ export class LemmyHttp { /** * Verify your email * - * `HTTP.POST /user/verify_email` + * `HTTP.POST /account/auth/verify_email` */ verifyEmail(form: VerifyEmail, options?: RequestOptions) { return this.#wrapper( HttpType.Post, - "/user/verify_email", + "/account/auth/verify_email", form, options, ); @@ -1789,12 +1833,12 @@ export class LemmyHttp { /** * Block an instance as user. * - * `HTTP.Post /site/block` + * `HTTP.Post /account/block/instance` */ userBlockInstance(form: UserBlockInstanceParams, options?: RequestOptions) { return this.#wrapper( HttpType.Post, - "/site/block", + "/account/block/instance", form, options, ); @@ -1803,12 +1847,12 @@ export class LemmyHttp { /** * Globally block an instance as admin. * - * `HTTP.Post /admin/block_instance` + * `HTTP.Post /admin/instance/block` */ adminBlockInstance(form: AdminBlockInstanceParams, options?: RequestOptions) { return this.#wrapper( HttpType.Post, - "/admin/block_instance", + "/admin/instance/block", form, options, ); @@ -1817,12 +1861,12 @@ export class LemmyHttp { /** * Globally allow an instance as admin. * - * `HTTP.Post /admin/allow_instance` + * `HTTP.Post /admin/instance/allow` */ adminAllowInstance(form: AdminAllowInstanceParams, options?: RequestOptions) { return this.#wrapper( HttpType.Post, - "/admin/allow_instance", + "/admin/instance/allow", form, options, ); diff --git a/src/other_types.ts b/src/other_types.ts index 9db74ea..27e2e33 100644 --- a/src/other_types.ts +++ b/src/other_types.ts @@ -1,4 +1,4 @@ -export const VERSION = "v3"; +export const VERSION = "v4"; export interface UploadImage { image: File | Buffer; diff --git a/src/types/GetSiteResponse.ts b/src/types/GetSiteResponse.ts index 366cbfc..0119254 100644 --- a/src/types/GetSiteResponse.ts +++ b/src/types/GetSiteResponse.ts @@ -2,7 +2,6 @@ import type { Language } from "./Language"; import type { LanguageId } from "./LanguageId"; import type { LocalSiteUrlBlocklist } from "./LocalSiteUrlBlocklist"; -import type { MyUserInfo } from "./MyUserInfo"; import type { OAuthProvider } from "./OAuthProvider"; import type { PersonView } from "./PersonView"; import type { PublicOAuthProvider } from "./PublicOAuthProvider"; @@ -16,7 +15,6 @@ export type GetSiteResponse = { site_view: SiteView; admins: Array; version: string; - my_user?: MyUserInfo; all_languages: Array; discussion_languages: Array; /** From 5efb9f774fd7edf7f540589d336cd131fd11bc33 Mon Sep 17 00:00:00 2001 From: Dessalines Date: Sat, 7 Dec 2024 17:54:49 -0500 Subject: [PATCH 7/7] 0.20.0-api-v4.17 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 1b38f81..a1eda16 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "lemmy-js-client", "description": "A javascript / typescript client for Lemmy", - "version": "0.20.0-pkce.1", + "version": "0.20.0-api-v4.17", "author": "Dessalines ", "license": "AGPL-3.0", "main": "./dist/index.js",