diff --git a/.github/workflows/platform-frontend-ci.yml b/.github/workflows/platform-frontend-ci.yml index 13ea52eedc..d0b591b6b3 100644 --- a/.github/workflows/platform-frontend-ci.yml +++ b/.github/workflows/platform-frontend-ci.yml @@ -18,11 +18,14 @@ defaults: working-directory: autogpt_platform/frontend jobs: - lint: + setup: runs-on: ubuntu-latest - + outputs: + cache-key: ${{ steps.cache-key.outputs.key }} + steps: - - uses: actions/checkout@v4 + - name: Checkout repository + uses: actions/checkout@v4 - name: Set up Node.js uses: actions/setup-node@v4 @@ -32,6 +35,45 @@ jobs: - name: Enable corepack run: corepack enable + - name: Generate cache key + id: cache-key + run: echo "key=${{ runner.os }}-pnpm-${{ hashFiles('**/pnpm-lock.yaml') }}" >> $GITHUB_OUTPUT + + - name: Cache dependencies + uses: actions/cache@v4 + with: + path: ~/.pnpm-store + key: ${{ steps.cache-key.outputs.key }} + restore-keys: | + ${{ runner.os }}-pnpm- + + - name: Install dependencies + run: pnpm install --frozen-lockfile + + lint: + runs-on: ubuntu-latest + needs: setup + + steps: + - name: Checkout repository + uses: actions/checkout@v4 + + - name: Set up Node.js + uses: actions/setup-node@v4 + with: + node-version: "21" + + - name: Enable corepack + run: corepack enable + + - name: Restore dependencies cache + uses: actions/cache@v4 + with: + path: ~/.pnpm-store + key: ${{ needs.setup.outputs.cache-key }} + restore-keys: | + ${{ runner.os }}-pnpm- + - name: Install dependencies run: pnpm install --frozen-lockfile @@ -40,9 +82,11 @@ jobs: type-check: runs-on: ubuntu-latest + needs: setup steps: - - uses: actions/checkout@v4 + - name: Checkout repository + uses: actions/checkout@v4 - name: Set up Node.js uses: actions/setup-node@v4 @@ -52,21 +96,29 @@ jobs: - name: Enable corepack run: corepack enable + - name: Restore dependencies cache + uses: actions/cache@v4 + with: + path: ~/.pnpm-store + key: ${{ needs.setup.outputs.cache-key }} + restore-keys: | + ${{ runner.os }}-pnpm- + - name: Install dependencies run: pnpm install --frozen-lockfile - - name: Generate API client - run: pnpm generate:api-client - - name: Run tsc check run: pnpm type-check chromatic: runs-on: ubuntu-latest + needs: setup # Only run on dev branch pushes or PRs targeting dev if: github.ref == 'refs/heads/dev' || github.base_ref == 'dev' + steps: - - uses: actions/checkout@v4 + - name: Checkout repository + uses: actions/checkout@v4 with: fetch-depth: 0 @@ -78,6 +130,14 @@ jobs: - name: Enable corepack run: corepack enable + - name: Restore dependencies cache + uses: actions/cache@v4 + with: + path: ~/.pnpm-store + key: ${{ needs.setup.outputs.cache-key }} + restore-keys: | + ${{ runner.os }}-pnpm- + - name: Install dependencies run: pnpm install --frozen-lockfile @@ -91,6 +151,7 @@ jobs: test: runs-on: ubuntu-latest + needs: setup strategy: fail-fast: false matrix: @@ -128,6 +189,14 @@ jobs: run: | docker compose -f ../docker-compose.yml up -d + - name: Restore dependencies cache + uses: actions/cache@v4 + with: + path: ~/.pnpm-store + key: ${{ needs.setup.outputs.cache-key }} + restore-keys: | + ${{ runner.os }}-pnpm- + - name: Install dependencies run: pnpm install --frozen-lockfile diff --git a/.gitignore b/.gitignore index f381981b96..1067dd921c 100644 --- a/.gitignore +++ b/.gitignore @@ -177,6 +177,3 @@ autogpt_platform/backend/settings.py *.ign.* .test-contents .claude/settings.local.json - -# Auto generated client -autogpt_platform/frontend/src/app/api/__generated__ diff --git a/autogpt_platform/backend/backend/util/request.py b/autogpt_platform/backend/backend/util/request.py index 08ac08ec50..7c7c684c48 100644 --- a/autogpt_platform/backend/backend/util/request.py +++ b/autogpt_platform/backend/backend/util/request.py @@ -353,6 +353,10 @@ class Requests: max_redirects: int = 10, **kwargs, ) -> Response: + # Convert auth tuple to aiohttp.BasicAuth if necessary + if "auth" in kwargs and isinstance(kwargs["auth"], tuple): + kwargs["auth"] = aiohttp.BasicAuth(*kwargs["auth"]) + if files is not None: if json is not None: raise ValueError( diff --git a/autogpt_platform/frontend/README.md b/autogpt_platform/frontend/README.md index 601187c968..94c65a6e3b 100644 --- a/autogpt_platform/frontend/README.md +++ b/autogpt_platform/frontend/README.md @@ -71,6 +71,9 @@ This project uses [`next/font`](https://nextjs.org/docs/basic-features/font-opti ## 🔄 Data Fetching Strategy +> [!NOTE] +> You don't need to run the OpenAPI commands below to run the Front-end. You will only need to run them when adding or modifying endpoints on the Backend API and wanting to use those on the Frontend. + This project uses an auto-generated API client powered by [**Orval**](https://orval.dev/), which creates type-safe API clients from OpenAPI specifications. ### How It Works diff --git a/autogpt_platform/frontend/orval.config.ts b/autogpt_platform/frontend/orval.config.ts index 136b437ff4..0047ecb720 100644 --- a/autogpt_platform/frontend/orval.config.ts +++ b/autogpt_platform/frontend/orval.config.ts @@ -16,11 +16,6 @@ export default defineConfig({ client: "react-query", httpClient: "fetch", indexFiles: false, - mock: { - type: "msw", - delay: 1000, // artifical latency - generateEachHttpStatus: true, // helps us test error-handling scenarios and generate mocks for all HTTP statuses - }, override: { mutator: { path: "./mutators/custom-mutator.ts", @@ -45,23 +40,23 @@ export default defineConfig({ afterAllFilesWrite: "prettier --write", }, }, - autogpt_zod_schema: { - input: { - target: `./src/app/api/openapi.json`, - override: { - transformer: "./src/app/api/transformers/fix-tags.mjs", - }, - }, - output: { - workspace: "./src/app/api", - target: `./__generated__/zod-schema`, - schemas: "./__generated__/models", - mode: "tags-split", - client: "zod", - indexFiles: false, - }, - hooks: { - afterAllFilesWrite: "prettier --write", - }, - }, + // autogpt_zod_schema: { + // input: { + // target: `./src/app/api/openapi.json`, + // override: { + // transformer: "./src/app/api/transformers/fix-tags.mjs", + // }, + // }, + // output: { + // workspace: "./src/app/api", + // target: `./__generated__/zod-schema`, + // schemas: "./__generated__/models", + // mode: "tags-split", + // client: "zod", + // indexFiles: false, + // }, + // hooks: { + // afterAllFilesWrite: "prettier --write", + // }, + // }, }); diff --git a/autogpt_platform/frontend/package.json b/autogpt_platform/frontend/package.json index de44ec141e..c51fa60c41 100644 --- a/autogpt_platform/frontend/package.json +++ b/autogpt_platform/frontend/package.json @@ -4,7 +4,7 @@ "private": true, "scripts": { "dev": "next dev --turbo", - "build": "pnpm run generate:api-client && SKIP_STORYBOOK_TESTS=true next build", + "build": "cross-env pnpm run generate:api-client && SKIP_STORYBOOK_TESTS=true next build", "start": "next start", "start:standalone": "cd .next/standalone && node server.js", "lint": "next lint && prettier --check .", @@ -96,13 +96,13 @@ "devDependencies": { "@chromatic-com/storybook": "4.0.1", "@playwright/test": "1.53.1", - "@storybook/addon-a11y": "9.0.13", - "@storybook/addon-docs": "9.0.13", - "@storybook/addon-links": "9.0.13", - "@storybook/addon-onboarding": "9.0.13", - "@storybook/nextjs": "9.0.13", + "@storybook/addon-a11y": "9.0.14", + "@storybook/addon-docs": "9.0.14", + "@storybook/addon-links": "9.0.14", + "@storybook/addon-onboarding": "9.0.14", + "@storybook/nextjs": "9.0.14", "@tanstack/eslint-plugin-query": "5.81.2", - "@tanstack/react-query-devtools": "5.81.2", + "@tanstack/react-query-devtools": "5.81.5", "@types/canvas-confetti": "1.9.0", "@types/lodash": "4.17.19", "@types/negotiator": "0.6.4", @@ -113,18 +113,19 @@ "axe-playwright": "2.1.0", "chromatic": "11.25.2", "concurrently": "9.2.0", + "cross-env": "7.0.3", "eslint": "8.57.1", "eslint-config-next": "15.3.4", - "eslint-plugin-storybook": "9.0.13", + "eslint-plugin-storybook": "9.0.14", "import-in-the-middle": "1.14.2", "msw": "2.10.2", "msw-storybook-addon": "2.0.5", "orval": "7.10.0", "postcss": "8.5.6", - "prettier": "3.6.1", + "prettier": "3.6.2", "prettier-plugin-tailwindcss": "0.6.13", "require-in-the-middle": "7.5.2", - "storybook": "9.0.13", + "storybook": "9.0.14", "tailwindcss": "3.4.17", "typescript": "5.8.3" }, diff --git a/autogpt_platform/frontend/pnpm-lock.yaml b/autogpt_platform/frontend/pnpm-lock.yaml index f456c87c53..64b4f0a29c 100644 --- a/autogpt_platform/frontend/pnpm-lock.yaml +++ b/autogpt_platform/frontend/pnpm-lock.yaml @@ -16,7 +16,7 @@ importers: version: 5.1.1(react-hook-form@7.57.0(react@18.3.1)) '@next/third-parties': specifier: 15.3.3 - version: 15.3.3(next@15.3.3(@babel/core@7.27.4)(@opentelemetry/api@1.9.0)(@playwright/test@1.53.1)(react-dom@18.3.1(react@18.3.1))(react@18.3.1))(react@18.3.1) + version: 15.3.3(next@15.3.3(@babel/core@7.27.7)(@opentelemetry/api@1.9.0)(@playwright/test@1.53.1)(react-dom@18.3.1(react@18.3.1))(react@18.3.1))(react@18.3.1) '@phosphor-icons/react': specifier: 2.1.10 version: 2.1.10(react-dom@18.3.1(react@18.3.1))(react@18.3.1) @@ -79,7 +79,7 @@ importers: version: 1.2.7(@types/react-dom@18.3.5(@types/react@18.3.17))(@types/react@18.3.17)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) '@sentry/nextjs': specifier: 9.27.0 - version: 9.27.0(@opentelemetry/context-async-hooks@1.30.1(@opentelemetry/api@1.9.0))(@opentelemetry/core@1.30.1(@opentelemetry/api@1.9.0))(@opentelemetry/instrumentation@0.57.2(@opentelemetry/api@1.9.0))(@opentelemetry/sdk-trace-base@1.30.1(@opentelemetry/api@1.9.0))(next@15.3.3(@babel/core@7.27.4)(@opentelemetry/api@1.9.0)(@playwright/test@1.53.1)(react-dom@18.3.1(react@18.3.1))(react@18.3.1))(react@18.3.1)(webpack@5.99.9(esbuild@0.25.5)) + version: 9.27.0(@opentelemetry/context-async-hooks@1.30.1(@opentelemetry/api@1.9.0))(@opentelemetry/core@1.30.1(@opentelemetry/api@1.9.0))(@opentelemetry/instrumentation@0.57.2(@opentelemetry/api@1.9.0))(@opentelemetry/sdk-trace-base@1.30.1(@opentelemetry/api@1.9.0))(next@15.3.3(@babel/core@7.27.7)(@opentelemetry/api@1.9.0)(@playwright/test@1.53.1)(react-dom@18.3.1(react@18.3.1))(react@18.3.1))(react@18.3.1)(webpack@5.99.9(esbuild@0.25.5)) '@supabase/ssr': specifier: 0.6.1 version: 0.6.1(@supabase/supabase-js@2.50.0) @@ -133,7 +133,7 @@ importers: version: 12.16.0(@emotion/is-prop-valid@1.2.2)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) geist: specifier: 1.4.2 - version: 1.4.2(next@15.3.3(@babel/core@7.27.4)(@opentelemetry/api@1.9.0)(@playwright/test@1.53.1)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)) + version: 1.4.2(next@15.3.3(@babel/core@7.27.7)(@opentelemetry/api@1.9.0)(@playwright/test@1.53.1)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)) jaro-winkler: specifier: 0.2.8 version: 0.2.8 @@ -151,7 +151,7 @@ importers: version: 2.30.1 next: specifier: 15.3.3 - version: 15.3.3(@babel/core@7.27.4)(@opentelemetry/api@1.9.0)(@playwright/test@1.53.1)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + version: 15.3.3(@babel/core@7.27.7)(@opentelemetry/api@1.9.0)(@playwright/test@1.53.1)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) next-themes: specifier: 0.4.6 version: 0.4.6(react-dom@18.3.1(react@18.3.1))(react@18.3.1) @@ -209,31 +209,31 @@ importers: devDependencies: '@chromatic-com/storybook': specifier: 4.0.1 - version: 4.0.1(storybook@9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1)) + version: 4.0.1(storybook@9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2)) '@playwright/test': specifier: 1.53.1 version: 1.53.1 '@storybook/addon-a11y': - specifier: 9.0.13 - version: 9.0.13(storybook@9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1)) + specifier: 9.0.14 + version: 9.0.14(storybook@9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2)) '@storybook/addon-docs': - specifier: 9.0.13 - version: 9.0.13(@types/react@18.3.17)(storybook@9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1)) + specifier: 9.0.14 + version: 9.0.14(@types/react@18.3.17)(storybook@9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2)) '@storybook/addon-links': - specifier: 9.0.13 - version: 9.0.13(react@18.3.1)(storybook@9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1)) + specifier: 9.0.14 + version: 9.0.14(react@18.3.1)(storybook@9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2)) '@storybook/addon-onboarding': - specifier: 9.0.13 - version: 9.0.13(storybook@9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1)) + specifier: 9.0.14 + version: 9.0.14(storybook@9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2)) '@storybook/nextjs': - specifier: 9.0.13 - version: 9.0.13(esbuild@0.25.5)(next@15.3.3(@babel/core@7.27.4)(@opentelemetry/api@1.9.0)(@playwright/test@1.53.1)(react-dom@18.3.1(react@18.3.1))(react@18.3.1))(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(storybook@9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1))(type-fest@4.41.0)(typescript@5.8.3)(webpack-hot-middleware@2.26.1)(webpack@5.99.9(esbuild@0.25.5)) + specifier: 9.0.14 + version: 9.0.14(esbuild@0.25.5)(next@15.3.3(@babel/core@7.27.7)(@opentelemetry/api@1.9.0)(@playwright/test@1.53.1)(react-dom@18.3.1(react@18.3.1))(react@18.3.1))(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(storybook@9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2))(type-fest@4.41.0)(typescript@5.8.3)(webpack-hot-middleware@2.26.1)(webpack@5.99.9(esbuild@0.25.5)) '@tanstack/eslint-plugin-query': specifier: 5.81.2 version: 5.81.2(eslint@8.57.1)(typescript@5.8.3) '@tanstack/react-query-devtools': - specifier: 5.81.2 - version: 5.81.2(@tanstack/react-query@5.80.7(react@18.3.1))(react@18.3.1) + specifier: 5.81.5 + version: 5.81.5(@tanstack/react-query@5.80.7(react@18.3.1))(react@18.3.1) '@types/canvas-confetti': specifier: 1.9.0 version: 1.9.0 @@ -264,6 +264,9 @@ importers: concurrently: specifier: 9.2.0 version: 9.2.0 + cross-env: + specifier: 7.0.3 + version: 7.0.3 eslint: specifier: 8.57.1 version: 8.57.1 @@ -271,8 +274,8 @@ importers: specifier: 15.3.4 version: 15.3.4(eslint@8.57.1)(typescript@5.8.3) eslint-plugin-storybook: - specifier: 9.0.13 - version: 9.0.13(eslint@8.57.1)(storybook@9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1))(typescript@5.8.3) + specifier: 9.0.14 + version: 9.0.14(eslint@8.57.1)(storybook@9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2))(typescript@5.8.3) import-in-the-middle: specifier: 1.14.2 version: 1.14.2 @@ -289,17 +292,17 @@ importers: specifier: 8.5.6 version: 8.5.6 prettier: - specifier: 3.6.1 - version: 3.6.1 + specifier: 3.6.2 + version: 3.6.2 prettier-plugin-tailwindcss: specifier: 0.6.13 - version: 0.6.13(prettier@3.6.1) + version: 0.6.13(prettier@3.6.2) require-in-the-middle: specifier: 7.5.2 version: 7.5.2 storybook: - specifier: 9.0.13 - version: 9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1) + specifier: 9.0.14 + version: 9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2) tailwindcss: specifier: 3.4.17 version: 3.4.17 @@ -343,12 +346,12 @@ packages: resolution: {integrity: sha512-cjQ7ZlQ0Mv3b47hABuTevyTuYN4i+loJKGeV9flcCgIK37cCXRh+L1bd3iBHlynerhQ7BhCkn2BPbQUL+rGqFg==} engines: {node: '>=6.9.0'} - '@babel/compat-data@7.27.5': - resolution: {integrity: sha512-KiRAp/VoJaWkkte84TvUd9qjdbZAdiqyvMxrGl1N6vzFogKmaLgoM3L1kgtLicp2HP5fBJS8JrZKLVIZGVJAVg==} + '@babel/compat-data@7.27.7': + resolution: {integrity: sha512-xgu/ySj2mTiUFmdE9yCMfBxLp4DHd5DwmbbD05YAuICfodYT3VvRxbrh81LGQ/8UpSdtMdfKMn3KouYDX59DGQ==} engines: {node: '>=6.9.0'} - '@babel/core@7.27.4': - resolution: {integrity: sha512-bXYxrXFubeYdvB0NhD/NBB3Qi6aZeV20GOWVI47t2dkecCEoneR4NPVcb7abpXDEvejgrUfFtG6vG/zxAKmg+g==} + '@babel/core@7.27.7': + resolution: {integrity: sha512-BU2f9tlKQ5CAthiMIgpzAh4eDTLWo1mqi9jqE2OxMG0E/OM199VJt2q8BztTxpnSW0i1ymdwLXRJnYzvDM5r2w==} engines: {node: '>=6.9.0'} '@babel/generator@7.27.5': @@ -375,8 +378,8 @@ packages: peerDependencies: '@babel/core': ^7.0.0 - '@babel/helper-define-polyfill-provider@0.6.4': - resolution: {integrity: sha512-jljfR1rGnXXNWnmQg2K3+bvhkxB51Rl32QRaOTuwwjviGrHzIbSc8+x9CpraDtbT7mfyjXObULP4w/adunNwAw==} + '@babel/helper-define-polyfill-provider@0.6.5': + resolution: {integrity: sha512-uJnGFcPsWQK8fvjgGP5LZUZZsYGIoPeRjSF5PGwrelYgq7Q15/Ft9NGFp1zglwgIv//W0uG4BevRuSJRyylZPg==} peerDependencies: '@babel/core': ^7.4.0 || ^8.0.0-0 <8.0.0 @@ -438,8 +441,8 @@ packages: resolution: {integrity: sha512-muE8Tt8M22638HU31A3CgfSUciwz1fhATfoVai05aPXGor//CdWDCbnlY1yvBPo07njuVOCNGCSp/GTt12lIug==} engines: {node: '>=6.9.0'} - '@babel/parser@7.27.5': - resolution: {integrity: sha512-OsQd175SxWkGlzbny8J3K8TnnDD0N3lrIUtB92xwyRpzaenGZhxDvxN/JgU00U3CDZNj9tPuDJ5H0WS4Nt3vKg==} + '@babel/parser@7.27.7': + resolution: {integrity: sha512-qnzXzDXdr/po3bOTbTIQZ7+TxNKxpkN5IifVLXS+r7qwynkZfPyjZfE7hCXbo7IoO9TNcSyibgONsf2HauUd3Q==} engines: {node: '>=6.0.0'} hasBin: true @@ -561,8 +564,8 @@ packages: peerDependencies: '@babel/core': ^7.12.0 - '@babel/plugin-transform-classes@7.27.1': - resolution: {integrity: sha512-7iLhfFAubmpeJe/Wo2TVuDrykh/zlWXLzPNdL0Jqn/Xu8R3QQ8h9ff8FQoISZOsw74/HFqFI7NX63HN7QFIHKA==} + '@babel/plugin-transform-classes@7.27.7': + resolution: {integrity: sha512-CuLkokN1PEZ0Fsjtq+001aog/C2drDK9nTfK/NRK0n6rBin6cBrvM+zfQjDE+UllhR6/J4a6w8Xq9i4yi3mQrw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 @@ -573,8 +576,8 @@ packages: peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-destructuring@7.27.3': - resolution: {integrity: sha512-s4Jrok82JpiaIprtY2nHsYmrThKvvwgHwjgd7UMiYhZaN0asdXNLr0y+NjTfkA7SyQE5i2Fb7eawUOZmLvyqOA==} + '@babel/plugin-transform-destructuring@7.27.7': + resolution: {integrity: sha512-pg3ZLdIKWCP0CrJm0O4jYjVthyBeioVfvz9nwt6o5paUxsgJ/8GucSMAIaj6M7xA4WY+SrvtGu2LijzkdyecWQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 @@ -699,8 +702,8 @@ packages: peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-object-rest-spread@7.27.3': - resolution: {integrity: sha512-7ZZtznF9g4l2JCImCo5LNKFHB5eXnN39lLtLY5Tg+VkR0jwOt7TBciMckuiQIOIW7L5tkQOCh3bVGYeXgMx52Q==} + '@babel/plugin-transform-object-rest-spread@7.27.7': + resolution: {integrity: sha512-201B1kFTWhckclcXpWHc8uUpYziDX/Pl4rxl0ZX0DiCZ3jknwfSUALL3QCYeeXXB37yWxJbo+g+Vfq8pAaHi3w==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 @@ -723,8 +726,8 @@ packages: peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-parameters@7.27.1': - resolution: {integrity: sha512-018KRk76HWKeZ5l4oTj2zPpSh+NbGdt0st5S6x0pga6HgrjBOJb24mMDHorFopOOd6YHkLgOZ+zaCjZGPO4aKg==} + '@babel/plugin-transform-parameters@7.27.7': + resolution: {integrity: sha512-qBkYTYCb76RRxUM6CcZA5KRu8K4SM8ajzVeUgVdMVO9NN9uI/GaVmBg/WKJJGnNokV9SY8FxNOVWGXzqzUidBg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 @@ -886,12 +889,12 @@ packages: resolution: {integrity: sha512-LPDZ85aEJyYSd18/DkjNh4/y1ntkE5KwUHWTiqgRxruuZL2F1yuHligVHLvcHY2vMHXttKFpJn6LwfI7cw7ODw==} engines: {node: '>=6.9.0'} - '@babel/traverse@7.27.4': - resolution: {integrity: sha512-oNcu2QbHqts9BtOWJosOVJapWjBDSxGCpFvikNR5TGDYDQf3JwpIoMzIKrvfoti93cLfPJEG4tH9SPVeyCGgdA==} + '@babel/traverse@7.27.7': + resolution: {integrity: sha512-X6ZlfR/O/s5EQ/SnUSLzr+6kGnkg8HXGMzpgsMsrJVcfDtH1vIp6ctCN4eZ1LS5c0+te5Cb6Y514fASjMRJ1nw==} engines: {node: '>=6.9.0'} - '@babel/types@7.27.6': - resolution: {integrity: sha512-ETyHEk2VHHvl9b9jZP5IHPavHYk57EhanlRRuae9XCpb/j5bDCbPPMOBfCWhnl/7EDJz0jEMCi/RhccCE8r1+Q==} + '@babel/types@7.27.7': + resolution: {integrity: sha512-8OLQgDScAOHXnAz2cV+RfzzNMipuLVBz2biuAJFMV9bfkNf393je3VM8CLkjQodW5+iWsSJdSgSWT6rsZoXHPw==} engines: {node: '>=6.9.0'} '@bundled-es-modules/cookie@2.0.1': @@ -1300,6 +1303,9 @@ packages: resolution: {integrity: sha512-O8jcjabXaleOG9DQ0+ARXWZBTfnP4WNAqzuiJK7ll44AmxGKv/J2M4TPjxjY3znBCfvBXFzucm1twdyFybFqEA==} engines: {node: '>=12'} + '@jridgewell/gen-mapping@0.3.10': + resolution: {integrity: sha512-HM2F4B9N4cA0RH2KQiIZOHAZqtP4xGS4IZ+SFe1SIbO4dyjf9MTY2Bo3vHYnm0hglWfXqBrzUBSa+cJfl3Xvrg==} + '@jridgewell/gen-mapping@0.3.8': resolution: {integrity: sha512-imAbBGkb+ebQyxKgzv5Hu2nmROxoDOXHh80evxdoXNOrvAnVx7zimzc1Oo5h9RlfV4vPXaE2iM5pOFbvOCClWA==} engines: {node: '>=6.0.0'} @@ -1312,15 +1318,21 @@ packages: resolution: {integrity: sha512-R8gLRTZeyp03ymzP/6Lil/28tGeGEzhx1q2k703KGWRAI1VdvPIXdG70VJc2pAMw3NA6JKL5hhFu1sJX0Mnn/A==} engines: {node: '>=6.0.0'} - '@jridgewell/source-map@0.3.6': - resolution: {integrity: sha512-1ZJTZebgqllO79ue2bm3rIGud/bOe0pP5BjSRCRxxYkEZS8STV7zN84UBbiYu7jy+eCKSnVIUgoWWE/tt+shMQ==} + '@jridgewell/source-map@0.3.8': + resolution: {integrity: sha512-3EDAPd0B8X1gsQQgGHU8vyxSp2MB414z3roN67fY7nI0GV3GDthHfaWcbCfrC95tpAzA5xUvAuoO9Dxx/ywwRQ==} '@jridgewell/sourcemap-codec@1.5.0': resolution: {integrity: sha512-gv3ZRaISU3fjPAgNsriBRqGWQL6quFx04YMPW/zD8XMLsU32mhCCbfbO6KZFLjvYpCZ8zyDEgqsgf+PwPaM7GQ==} + '@jridgewell/sourcemap-codec@1.5.2': + resolution: {integrity: sha512-gKYheCylLIedI+CSZoDtGkFV9YEBxRRVcfCH7OfAqh4TyUyRjEE6WVE/aXDXX0p8BIe/QgLcaAoI0220KRRFgg==} + '@jridgewell/trace-mapping@0.3.25': resolution: {integrity: sha512-vNk6aEwybGtawWmy/PzwnGDOjCkLWSD2wqvjGGAgOAwCGWySYXfYoxt00IJkTF+8Lb57DwOb3Aa0o9CApepiYQ==} + '@jridgewell/trace-mapping@0.3.27': + resolution: {integrity: sha512-VO95AxtSFMelbg3ouljAYnfvTEwSWVt/2YLf+U5Ejd8iT5mXE2Sa/1LGyvySMne2CGsepGLI7KpF3EzE3Aq9Mg==} + '@jsdevtools/ono@7.1.3': resolution: {integrity: sha512-4JQNk+3mVzK3xh2rqd6RB4J46qUR19azEHBneZyTZM+c456qOrbbM/5xcR8huNCCcbVt7+UmizG6GuUvPvKUYg==} @@ -2549,48 +2561,48 @@ packages: resolution: {integrity: sha512-JZlVFE6/dYpP9tQmV0/ADfn32L9uFarHWxfcRhReKUnljz1ZiUM5zpX+PH8h5CJs6lao3TuFqnPm9IJJCEkE2w==} engines: {node: '>=10.8'} - '@storybook/addon-a11y@9.0.13': - resolution: {integrity: sha512-MVkfZx7ZeAOMGzeRLH6Rf2NMMA5ubTRR8EzW0x0kGXIfYhZxRj+hDEZl3ggMUo+A30w+hOi4d8OGFfWm45DTeg==} + '@storybook/addon-a11y@9.0.14': + resolution: {integrity: sha512-xDtzD89lyyq706yynJ8iAUjBfNebb7F5OoJXSAPYPnUiHoNHAcRT9ia2HrC6Yjp3f3JX2PRIEMjD5Myz3sL04A==} peerDependencies: - storybook: ^9.0.13 + storybook: ^9.0.14 - '@storybook/addon-docs@9.0.13': - resolution: {integrity: sha512-e9mCzgxsSz/FIHz08Gex71jF2tz5WNPgSxEg6Lb8jMWbfdgb2lEFyby/RV5qj8ajTXhheiGKZ3K9JESfLWm0ng==} + '@storybook/addon-docs@9.0.14': + resolution: {integrity: sha512-vjWH2FamLzoPZXitecbhRSUvQDj27q/dDaCKXSwCIwEVziIQrqHBGDmuJPCWoroCkKxLo8s8gwMi6wk5Minaqg==} peerDependencies: - storybook: ^9.0.13 + storybook: ^9.0.14 - '@storybook/addon-links@9.0.13': - resolution: {integrity: sha512-lYcy6ffYoTcWiQzqamf6fpvH6hwltgrvfaTBEyusoZwW8bYIzJkxAY/7jd6WVSohudKtdvnbvLiw40v/rEorVg==} + '@storybook/addon-links@9.0.14': + resolution: {integrity: sha512-qzlRT+GRInP3H0bfvTVgdxWqbbSNLyBln9RNm1t5H3DsHc4NFyYdpPXXUapyFrWW7O0ByWMWO94RG0T+qG5R3g==} peerDependencies: react: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0-beta - storybook: ^9.0.13 + storybook: ^9.0.14 peerDependenciesMeta: react: optional: true - '@storybook/addon-onboarding@9.0.13': - resolution: {integrity: sha512-xzmfTBpc+IK7LLJ0Xh73WGIqKYUYeB7rgRX2gbbgFmpu5itAYnguabNxHg09p0vSnsw+1yiKgqx4kk8PnjfOuA==} + '@storybook/addon-onboarding@9.0.14': + resolution: {integrity: sha512-oJdRbOp8OkmDit8KpvkcOccN7Xczqznz55WH2oxaSLg0pWqn493BQGaRvq7Tn8qxTomNg9ibqr0rsHRZQKGlbQ==} peerDependencies: - storybook: ^9.0.13 + storybook: ^9.0.14 - '@storybook/builder-webpack5@9.0.13': - resolution: {integrity: sha512-uQ6x4ReMzRPkiaEJbflxGf7qkLDqz2rI7xdrs98Vuu8lyejOFN5nT5NUi0VXsxRczlVeSO0fQq/H/kSFXOxlvg==} + '@storybook/builder-webpack5@9.0.14': + resolution: {integrity: sha512-wu7OC+WE+PK7IaKKUEFN7a04CeSKJWkAqlgTV7BrrExHIbbOVTrmQSn/q02SYZJRebr4lllAD9cD90TlO8aV+g==} peerDependencies: - storybook: ^9.0.13 + storybook: ^9.0.14 typescript: '*' peerDependenciesMeta: typescript: optional: true - '@storybook/core-webpack@9.0.13': - resolution: {integrity: sha512-jC6M5FOoTjsJ2FGmp8TAuQwjR22kGE30MfGav27XC1GZFghnzqgvAmoEXNR0QU6dBYinR5jEgx2O/iPgVGsOXw==} + '@storybook/core-webpack@9.0.14': + resolution: {integrity: sha512-LBWyCPKKBAb+Gb9QyIO2QcCf6QxRgzXfSyO1rnDqICrPdzukFtpEt4214v9cPw8wQqTclj7XADiOOsQMQjKmAA==} peerDependencies: - storybook: ^9.0.13 + storybook: ^9.0.14 - '@storybook/csf-plugin@9.0.13': - resolution: {integrity: sha512-yVBZERU2+FEqYFoRxK1sebP4aYZAwUFFG2MpD8YHM1g51lWpWDQsKkW57jPZ65GbuaK/DDLSldva6kF+tBk1DQ==} + '@storybook/csf-plugin@9.0.14': + resolution: {integrity: sha512-PKUmF5y/SfPOifC2bRo79YwfGv6TYISM5JK6r6FHVKMwV1nWLmj7Xx2t5aHa/5JggdBz/iGganTP7oo7QOn+0A==} peerDependencies: - storybook: ^9.0.13 + storybook: ^9.0.14 '@storybook/global@5.0.0': resolution: {integrity: sha512-FcOqPAXACP0I3oJ/ws6/rrPT9WGhu915Cg8D02a9YxLo0DE9zI+a9A5gRGvmQ09fiWPukqI8ZAEoQEdWUKMQdQ==} @@ -2602,14 +2614,14 @@ packages: react: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0-beta react-dom: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0-beta - '@storybook/nextjs@9.0.13': - resolution: {integrity: sha512-LD99cdm54LIcR+GSFs1RtIt2P5WpSgHoM/V/qzGz9+7cYSvSN2TZqeMxUNgNmrTxWrcb7nbQZuGOxNvB4liFOQ==} + '@storybook/nextjs@9.0.14': + resolution: {integrity: sha512-WZ1hExxB+XcbAsNDSpDyvqncoJGqoudsXrZoQuU9YXSOfddLVIVvDa9N7/q6d5UPKwAQwm2tuTup41Wy0octIg==} engines: {node: '>=20.0.0'} peerDependencies: next: ^14.1.0 || ^15.0.0 react: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0-beta react-dom: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0-beta - storybook: ^9.0.13 + storybook: ^9.0.14 typescript: '*' webpack: ^5.0.0 peerDependenciesMeta: @@ -2618,13 +2630,13 @@ packages: webpack: optional: true - '@storybook/preset-react-webpack@9.0.13': - resolution: {integrity: sha512-nbN7eNhfNcSasgeiYtS8hbxbcilxvCSy98VAG8Wnz0UWbje6eGt/rPY3dpGQGevJfxbG0vApjYb+6GFy1ZHn+Q==} + '@storybook/preset-react-webpack@9.0.14': + resolution: {integrity: sha512-T+djeLW4lHslFRhnlyVUcLVRMc2+tkmLHiv0ATzec/IipbMxHrZ5U5feWX6RuRsux6A00VWoG9Wdda59AJ7qwg==} engines: {node: '>=20.0.0'} peerDependencies: react: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0-beta react-dom: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0-beta - storybook: ^9.0.13 + storybook: ^9.0.14 typescript: '*' peerDependenciesMeta: typescript: @@ -2636,20 +2648,20 @@ packages: typescript: '>= 4.x' webpack: '>= 4' - '@storybook/react-dom-shim@9.0.13': - resolution: {integrity: sha512-k7fucEJu39cE7V31fX+cM2wbW869vuj9hFZJDIEPWwo33nKFFqr0f31ar01gCcYuMiad8KezbdzXnDcBw6c6Ww==} + '@storybook/react-dom-shim@9.0.14': + resolution: {integrity: sha512-fXMzhgFMnGZUhWm9zWiR8qOB90OykPhkB/qiebFbD/wUedPyp3H1+NAzX1/UWV2SYqr+aFK9vH1PokAYbpTRsw==} peerDependencies: react: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0-beta react-dom: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0-beta - storybook: ^9.0.13 + storybook: ^9.0.14 - '@storybook/react@9.0.13': - resolution: {integrity: sha512-kijh4vK7fSQCxs41SPCjN42gwD8I9vqgDYJV7XnQsIOJiwtWrsX+lMV4qVyN5SjTZF+HBV5oxD23XgQNlpZ31A==} + '@storybook/react@9.0.14': + resolution: {integrity: sha512-Ig4Y1xUOMcOWtQ/H73JZa4MeE0GJvYOcK16AhbfvPZMotdXCFyPbb1/pWhS209HuGwfNTVvWGz9rk7KrHmKsNw==} engines: {node: '>=20.0.0'} peerDependencies: react: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0-beta react-dom: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0-beta - storybook: ^9.0.13 + storybook: ^9.0.14 typescript: '>= 4.9.x' peerDependenciesMeta: typescript: @@ -2699,10 +2711,10 @@ packages: '@tanstack/query-devtools@5.81.2': resolution: {integrity: sha512-jCeJcDCwKfoyyBXjXe9+Lo8aTkavygHHsUHAlxQKKaDeyT0qyQNLKl7+UyqYH2dDF6UN/14873IPBHchcsU+Zg==} - '@tanstack/react-query-devtools@5.81.2': - resolution: {integrity: sha512-TX0OQ4cbgX6z2uN8c9x0QUNbyePGyUGdcgrGnV6TYEJc7KPT8PqeASuzoA5NGw1CiMGvyFAkIGA2KipvhM9d1g==} + '@tanstack/react-query-devtools@5.81.5': + resolution: {integrity: sha512-lCGMu4RX0uGnlrlLeSckBfnW/UV+KMlTBVqa97cwK7Z2ED5JKnZRSjNXwoma6sQBTJrcULvzgx2K6jEPvNUpDw==} peerDependencies: - '@tanstack/react-query': ^5.81.2 + '@tanstack/react-query': ^5.81.5 react: ^18 || ^19 '@tanstack/react-query@5.80.7': @@ -2756,6 +2768,9 @@ packages: '@types/canvas-confetti@1.9.0': resolution: {integrity: sha512-aBGj/dULrimR1XDZLtG9JwxX1b4HPRF6CX9Yfwh3NvstZEm1ZL7RBnel4keCPSqs1ANRu1u2Aoz9R+VmtjYuTg==} + '@types/chai@5.2.2': + resolution: {integrity: sha512-8kB30R7Hwqf40JPiKhVzodJs2Qc1ZJ5zuT3uzw5Hq/dhNCl3G3l83jfpdI1e20BP348+fV7VIL/+FxaXkqBmWg==} + '@types/connect@3.4.38': resolution: {integrity: sha512-K6uROf1LD88uDQqJCktA4yzL1YYAK6NgfsI0v/mTgyPKWsX1CnJ0XPSDhViejru1GcRkLWb8RlzFYJRqGUbaug==} @@ -2804,6 +2819,9 @@ packages: '@types/debug@4.1.12': resolution: {integrity: sha512-vIChWdVG3LG1SMxEvI/AK+FWJthlrqlTu7fbrlywTkkaONwk/UAGaULXRlf8vkzFBLVm0zkMdCquhL5aOjhXPQ==} + '@types/deep-eql@4.0.2': + resolution: {integrity: sha512-c9h9dVVMigMPc4bwTvC5dxqtqJZwQPePsWjPlpSOnojbor6pGqdk541lfA7AqFQr5pB1BRdq0juY9db81BwyFw==} + '@types/doctrine@0.0.9': resolution: {integrity: sha512-eOIHzCUSH7SMfonMG1LsC2f8vxBFtho6NGBznK41R84YzPuvSBzrhEps33IsQiOW9+VL6NQ9DbjQJznk/S4uRA==} @@ -2950,6 +2968,12 @@ packages: peerDependencies: typescript: '>=4.8.4 <5.9.0' + '@typescript-eslint/project-service@8.35.1': + resolution: {integrity: sha512-VYxn/5LOpVxADAuP3NrnxxHYfzVtQzLKeldIhDhzC8UHaiQvYlXvKuVho1qLduFbJjjy5U5bkGwa3rUGUb1Q6Q==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + peerDependencies: + typescript: '>=4.8.4 <5.9.0' + '@typescript-eslint/scope-manager@8.34.1': resolution: {integrity: sha512-beu6o6QY4hJAgL1E8RaXNC071G4Kso2MGmJskCFQhRhg8VOH/FDbC8soP8NHN7e/Hdphwp8G8cE6OBzC8o41ZA==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} @@ -2958,6 +2982,10 @@ packages: resolution: {integrity: sha512-+AgL5+mcoLxl1vGjwNfiWq5fLDZM1TmTPYs2UkyHfFhgERxBbqHlNjRzhThJqz+ktBqTChRYY6zwbMwy0591AA==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + '@typescript-eslint/scope-manager@8.35.1': + resolution: {integrity: sha512-s/Bpd4i7ht2934nG+UoSPlYXd08KYz3bmjLEb7Ye1UVob0d1ENiT3lY8bsCmik4RqfSbPw9xJJHbugpPpP5JUg==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + '@typescript-eslint/tsconfig-utils@8.34.1': resolution: {integrity: sha512-K4Sjdo4/xF9NEeA2khOb7Y5nY6NSXBnod87uniVYW9kHP+hNlDV8trUSFeynA2uxWam4gIWgWoygPrv9VMWrYg==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} @@ -2970,6 +2998,12 @@ packages: peerDependencies: typescript: '>=4.8.4 <5.9.0' + '@typescript-eslint/tsconfig-utils@8.35.1': + resolution: {integrity: sha512-K5/U9VmT9dTHoNowWZpz+/TObS3xqC5h0xAIjXPw+MNcKV9qg6eSatEnmeAwkjHijhACH0/N7bkhKvbt1+DXWQ==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + peerDependencies: + typescript: '>=4.8.4 <5.9.0' + '@typescript-eslint/type-utils@8.34.1': resolution: {integrity: sha512-Tv7tCCr6e5m8hP4+xFugcrwTOucB8lshffJ6zf1mF1TbU67R+ntCc6DzLNKM+s/uzDyv8gLq7tufaAhIBYeV8g==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} @@ -2985,6 +3019,10 @@ packages: resolution: {integrity: sha512-0mYH3emanku0vHw2aRLNGqe7EXh9WHEhi7kZzscrMDf6IIRUQ5Jk4wp1QrledE/36KtdZrVfKnE32eZCf/vaVQ==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + '@typescript-eslint/types@8.35.1': + resolution: {integrity: sha512-q/O04vVnKHfrrhNAscndAn1tuQhIkwqnaW+eu5waD5IPts2eX1dgJxgqcPx5BX109/qAz7IG6VrEPTOYKCNfRQ==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + '@typescript-eslint/typescript-estree@8.34.1': resolution: {integrity: sha512-rjCNqqYPuMUF5ODD+hWBNmOitjBWghkGKJg6hiCHzUvXRy6rK22Jd3rwbP2Xi+R7oYVvIKhokHVhH41BxPV5mA==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} @@ -2997,6 +3035,12 @@ packages: peerDependencies: typescript: '>=4.8.4 <5.9.0' + '@typescript-eslint/typescript-estree@8.35.1': + resolution: {integrity: sha512-Vvpuvj4tBxIka7cPs6Y1uvM7gJgdF5Uu9F+mBJBPY4MhvjrjWGK4H0lVgLJd/8PWZ23FTqsaJaLEkBCFUk8Y9g==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + peerDependencies: + typescript: '>=4.8.4 <5.9.0' + '@typescript-eslint/utils@8.34.1': resolution: {integrity: sha512-mqOwUdZ3KjtGk7xJJnLbHxTuWVn3GO2WZZuM+Slhkun4+qthLdXx32C8xIXbO1kfCECb3jIs3eoxK3eryk7aoQ==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} @@ -3011,6 +3055,13 @@ packages: eslint: ^8.57.0 || ^9.0.0 typescript: '>=4.8.4 <5.9.0' + '@typescript-eslint/utils@8.35.1': + resolution: {integrity: sha512-lhnwatFmOFcazAsUm3ZnZFpXSxiwoa1Lj50HphnDe1Et01NF4+hrdXONSUHIcbVu2eFb1bAf+5yjXkGVkXBKAQ==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + peerDependencies: + eslint: ^8.57.0 || ^9.0.0 + typescript: '>=4.8.4 <5.9.0' + '@typescript-eslint/visitor-keys@8.34.1': resolution: {integrity: sha512-xoh5rJ+tgsRKoXnkBPFRLZ7rjKM0AfVbC68UZ/ECXoDbfggb9RbEySN359acY1vS3qZ0jVTVWzbtfapwm5ztxw==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} @@ -3019,6 +3070,10 @@ packages: resolution: {integrity: sha512-zTh2+1Y8ZpmeQaQVIc/ZZxsx8UzgKJyNg1PTvjzC7WMhPSVS8bfDX34k1SrwOf016qd5RU3az2UxUNue3IfQ5g==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + '@typescript-eslint/visitor-keys@8.35.1': + resolution: {integrity: sha512-VRwixir4zBWCSTP/ljEo091lbpypz57PoeAQ9imjG+vbeof9LplljsL1mos4ccG6H9IjfrVGM359RozUnuFhpw==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + '@ungap/structured-clone@1.3.0': resolution: {integrity: sha512-WmoN8qaIAo7WTYWbAZuG8PYEhn5fkz7dZrqTBZ7dtt//lL2Gwms1IcnQ5yHqjDfX8Ft5j4YzDM23f87zBfDe9g==} @@ -3117,17 +3172,17 @@ packages: cpu: [x64] os: [win32] - '@vitest/expect@3.0.9': - resolution: {integrity: sha512-5eCqRItYgIML7NNVgJj6TVCmdzE7ZVgJhruW0ziSQV4V7PvLkDL1bBkBdcTs/VuIz0IxPb5da1IDSqc1TR9eig==} + '@vitest/expect@3.2.4': + resolution: {integrity: sha512-Io0yyORnB6sikFlt8QW5K7slY4OjqNX9jmJQ02QDda8lyM6B5oNgVWoSoKPac8/kgnCUzuHQKrSLtu/uOqqrig==} - '@vitest/pretty-format@3.0.9': - resolution: {integrity: sha512-OW9F8t2J3AwFEwENg3yMyKWweF7oRJlMyHOMIhO5F3n0+cgQAJZBjNgrF8dLwFTEXl5jUqBLXd9QyyKv8zEcmA==} + '@vitest/pretty-format@3.2.4': + resolution: {integrity: sha512-IVNZik8IVRJRTr9fxlitMKeJeXFFFN0JaB9PHPGQ8NKQbGpfjlTx9zO4RefN8gp7eqjNy8nyK3NZmBzOPeIxtA==} - '@vitest/spy@3.0.9': - resolution: {integrity: sha512-/CcK2UDl0aQ2wtkp3YVWldrpLRNCfVcIOFGlVGKO4R5eajsH393Z1yiXLVQ7vWsj26JOEjeZI0x5sm5P4OGUNQ==} + '@vitest/spy@3.2.4': + resolution: {integrity: sha512-vAfasCOe6AIK70iP5UD11Ac4siNUNJ9i/9PZ3NKx07sG6sUxeag1LWdNrMWeKKYBLlzuK+Gn65Yd5nyL6ds+nw==} - '@vitest/utils@3.0.9': - resolution: {integrity: sha512-ilHM5fHhZ89MCp5aAaM9uhfl1c2JdxVxl3McqsdVyVNN6JffnEen8UMCdRTzOhGXNQGo5GNL9QugHrz727Wnng==} + '@vitest/utils@3.2.4': + resolution: {integrity: sha512-fB2V0JFrQSMsCo9HiSq3Ezpdv4iYaXRG1Sx8edX3MwxfyNn83mKiGzOcH+Fkxt4MHxr3y42fQi1oeAInqgX2QA==} '@webassemblyjs/ast@1.14.1': resolution: {integrity: sha512-nuBEDgQfm1ccRp/8bCQrx1frohyufl4JlbMMZ4P1wpeOfDhF6FQkxZJ1b/e+PLwr6X1Nhw6OLme5usuBWYBvuQ==} @@ -3406,8 +3461,8 @@ packages: '@babel/core': ^7.12.0 webpack: '>=5' - babel-plugin-polyfill-corejs2@0.4.13: - resolution: {integrity: sha512-3sX/eOms8kd3q2KZ6DAhKPc0dgm525Gqq5NtWKZ7QYYZEv57OQ54KtblzJzH1lQF/eQxO8KjWGIK9IPUJNus5g==} + babel-plugin-polyfill-corejs2@0.4.14: + resolution: {integrity: sha512-Co2Y9wX854ts6U8gAAPXfn0GmAyctHuK8n0Yhfjd6t30g7yvKjspvvOo9yG+z52PZRgFErt7Ka2pYnXCjLKEpg==} peerDependencies: '@babel/core': ^7.4.0 || ^8.0.0-0 <8.0.0 @@ -3416,8 +3471,8 @@ packages: peerDependencies: '@babel/core': ^7.4.0 || ^8.0.0-0 <8.0.0 - babel-plugin-polyfill-regenerator@0.6.4: - resolution: {integrity: sha512-7gD3pRadPrbjhjLyxebmx/WrFYcuSjZ0XbdUujQMZ/fcE9oeewk2U/7PCvez84UeuK3oSjmPZ0Ch0dlupQvGzw==} + babel-plugin-polyfill-regenerator@0.6.5: + resolution: {integrity: sha512-ISqQ2frbiNU9vIJkzg7dlPpznPZ4jOiUQ1uSmB0fEHeowtN3COYRsXr/xexn64NpU13P06jc/L5TgiJXOgrbEg==} peerDependencies: '@babel/core': ^7.4.0 || ^8.0.0-0 <8.0.0 @@ -3757,6 +3812,16 @@ packages: create-hmac@1.1.7: resolution: {integrity: sha512-MJG9liiZ+ogc4TzUwuvbER1JRdgvUFSB5+VR/g5h82fGaIRWMWddtKBHi7/sVhfjQZ6SehlyhvQYrcYkaUIpLg==} + create-jest@29.7.0: + resolution: {integrity: sha512-Adz2bdH0Vq3F53KEMJOoftQFutWCukm6J24wbPWRO4k1kMY7gS7ds/uoJkNuV8wDCtWWnuwGcJwpWcih+zEW1Q==} + engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} + hasBin: true + + cross-env@7.0.3: + resolution: {integrity: sha512-+/HKd6EgcQCJGh2PSjZuUitQBQynKor4wrFbRg4DtAgS1aWO+gU52xpH7M9ScGgXSYmAVS9bIJ8EzuaGw0oNAw==} + engines: {node: '>=10.14', npm: '>=6', yarn: '>=1'} + hasBin: true + cross-spawn@7.0.6: resolution: {integrity: sha512-uV2QOWP2nWzsy2aMp8aRibhi9dlzF5Hgh5SHaB9OiTGEyDTiJJyx0uy51QXdyWbtAHNua4XJzUKca3OzKUd3vA==} engines: {node: '>= 8'} @@ -3787,8 +3852,8 @@ packages: css-to-react-native@3.2.0: resolution: {integrity: sha512-e8RKaLXMOFii+02mOlqwjbD00KSEKqblnpO9e++1aXS1fPQOpS1YoqdVHBqPjHNoxeF2mimzVqawm2KCbEdtHQ==} - css-what@6.1.0: - resolution: {integrity: sha512-HTUrgRJ7r4dsZKU6GjmpfRK1O76h97Z8MfS1G0FozR+oF2kG6Vfe8JE6zwrkbxigziPHinCJ+gCPjA9EaBDtRw==} + css-what@6.2.2: + resolution: {integrity: sha512-u/O3vwbptzhMs3L1fQE82ZSLHQQfto5gyZzwteVIEyeaY5Fc7R4dapF/BvRoSYFeqfBk4m0V1Vafq5Pjv25wvA==} engines: {node: '>= 6'} css.escape@1.5.1: @@ -4027,8 +4092,8 @@ packages: eastasianwidth@0.2.0: resolution: {integrity: sha512-I88TYZWc9XiYHRQ4/3c5rjjfgkjhLyW2luGIheGERbNQ6OY7yTybanSpDXZa8y7VUP9YmDcYa+eyq4ca7iLqWA==} - electron-to-chromium@1.5.176: - resolution: {integrity: sha512-2nDK9orkm7M9ZZkjO3PjbEd3VUulQLyg5T9O3enJdFvUg46Hzd4DUvTvAuEgbdHYXyFsiG4A5sO9IzToMH1cDg==} + electron-to-chromium@1.5.177: + resolution: {integrity: sha512-7EH2G59nLsEMj97fpDuvVcYi6lwTcM1xuWw3PssD8xzboAW7zj7iB3COEEEATUfjLHrs5uKBLQT03V/8URx06g==} elliptic@6.6.1: resolution: {integrity: sha512-RaddvvMatK2LJHqFJ+YA4WysVN5Ita9E35botqIYspQ4TkRAlCicdzKOjlyv/1Za5RyTNn7di//eEV0uTAfe3g==} @@ -4218,12 +4283,12 @@ packages: peerDependencies: eslint: ^3 || ^4 || ^5 || ^6 || ^7 || ^8 || ^9.7 - eslint-plugin-storybook@9.0.13: - resolution: {integrity: sha512-XnyE+3BmTe8jSzfHtPKTbzHkNpwrq2/e3Fy7l5Lr0NB1ykbblOCgS9kWWswX/1MQwFsEPt+TqRZvFhMX8tgy4g==} + eslint-plugin-storybook@9.0.14: + resolution: {integrity: sha512-YZsDhyFgVfeFPdvd7Xcl9ZusY7Jniq7AOAWN/cdg0a2Y+ywKKNYrQ+EfyuhXsiMjh58plYKMpJYxKVxeUwW9jw==} engines: {node: '>=20.0.0'} peerDependencies: eslint: '>=8' - storybook: ^9.0.13 + storybook: ^9.0.14 eslint-scope@5.1.1: resolution: {integrity: sha512-2NxwbF/hZ0KpepYN0cNbo+FN6XoK7GaHlQhgx/hIZl6Va0bF45RQOOwhLIy8lQDbuCiadSLCBnH2CFYquit5bw==} @@ -5829,8 +5894,8 @@ packages: prettier-plugin-svelte: optional: true - prettier@3.6.1: - resolution: {integrity: sha512-5xGWRa90Sp2+x1dQtNpIpeOQpTDBs9cZDmA/qs2vDNN2i18PdapqY7CmBeyLlMuGqXJRIOPaCaVZTLNQRWUH/A==} + prettier@3.6.2: + resolution: {integrity: sha512-I7AIg5boAr5R0FFtJ6rCfD+LFsWHp81dolrFD8S79U9tb8Az2nGrJncnMSnys+bpQJfRUzqs9hnA81OAA3hCuQ==} engines: {node: '>=14'} hasBin: true @@ -6368,8 +6433,8 @@ packages: resolution: {integrity: sha512-eLoXW/DHyl62zxY4SCaIgnRhuMr6ri4juEYARS8E6sCEqzKpOiE521Ucofdx+KnDZl5xmvGYaaKCk5FEOxJCoQ==} engines: {node: '>= 0.4'} - storybook@9.0.13: - resolution: {integrity: sha512-RMCTZ24IF8cMu1Ru1vUfnsP+w/OfI6Wm/wjjXaDMoTrriuQG24AF+VL+UipEoqkmZtqoZcfwRyiOgnEWQX8akw==} + storybook@9.0.14: + resolution: {integrity: sha512-PfVo9kSa4XsDTD2gXFvMRGix032+clBDcUMI4MhUzYxONLiZifnhwch4p/1lG+c3IVN4qkOEgGNc9PEgVMgApw==} hasBin: true peerDependencies: prettier: ^2 || ^3 @@ -6597,8 +6662,8 @@ packages: resolution: {integrity: sha512-op4nsTR47R6p0vMUUoYl/a+ljLFVtlfaXkLQmqfLR1qHma1h/ysYk4hEXZ880bf2CYgTskvTa/e196Vd5dDQXw==} engines: {node: '>=14.0.0'} - tinyspy@3.0.2: - resolution: {integrity: sha512-n1cw8k1k0x4pgA2+9XrOkFydTerNcJ1zWCO5Nn9scWHTD+5tp8dghT2x1uduQePZTZgd3Tupf+x9BxJjeJi77Q==} + tinyspy@4.0.3: + resolution: {integrity: sha512-t2T/WLB2WRgZ9EpE4jgPJ9w+i66UZfDc8wHh0xrwiRNN+UwH98GIJkTeZqX9rg0i0ptwzqW+uYeIF0T4F8LR7A==} engines: {node: '>=14.0.0'} to-buffer@1.2.1: @@ -6976,8 +7041,8 @@ packages: wrappy@1.0.2: resolution: {integrity: sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==} - ws@8.18.2: - resolution: {integrity: sha512-DMricUmwGZUVr++AEAe2uiVM7UoO9MAVZMDu05UQOaUII0lp+zOzLLU4Xqh/JvTqklB1T4uELaaPBKyjE1r4fQ==} + ws@8.18.3: + resolution: {integrity: sha512-PEIGCY5tSlUt50cqyMXfCzX+oOPqN0vuGqWzbcJ2xvnkzkq46oOpz7dQaTDBdfICb4N14+GARUDw2XV2N4tvzg==} engines: {node: '>=10.0.0'} peerDependencies: bufferutil: ^4.0.1 @@ -7061,8 +7126,8 @@ snapshots: '@ampproject/remapping@2.3.0': dependencies: - '@jridgewell/gen-mapping': 0.3.8 - '@jridgewell/trace-mapping': 0.3.25 + '@jridgewell/gen-mapping': 0.3.10 + '@jridgewell/trace-mapping': 0.3.27 '@apidevtools/json-schema-ref-parser@11.7.2': dependencies: @@ -7095,20 +7160,20 @@ snapshots: js-tokens: 4.0.0 picocolors: 1.1.1 - '@babel/compat-data@7.27.5': {} + '@babel/compat-data@7.27.7': {} - '@babel/core@7.27.4': + '@babel/core@7.27.7': dependencies: '@ampproject/remapping': 2.3.0 '@babel/code-frame': 7.27.1 '@babel/generator': 7.27.5 '@babel/helper-compilation-targets': 7.27.2 - '@babel/helper-module-transforms': 7.27.3(@babel/core@7.27.4) + '@babel/helper-module-transforms': 7.27.3(@babel/core@7.27.7) '@babel/helpers': 7.27.6 - '@babel/parser': 7.27.5 + '@babel/parser': 7.27.7 '@babel/template': 7.27.2 - '@babel/traverse': 7.27.4 - '@babel/types': 7.27.6 + '@babel/traverse': 7.27.7 + '@babel/types': 7.27.7 convert-source-map: 2.0.0 debug: 4.4.1 gensync: 1.0.0-beta.2 @@ -7119,47 +7184,47 @@ snapshots: '@babel/generator@7.27.5': dependencies: - '@babel/parser': 7.27.5 - '@babel/types': 7.27.6 - '@jridgewell/gen-mapping': 0.3.8 - '@jridgewell/trace-mapping': 0.3.25 + '@babel/parser': 7.27.7 + '@babel/types': 7.27.7 + '@jridgewell/gen-mapping': 0.3.10 + '@jridgewell/trace-mapping': 0.3.27 jsesc: 3.1.0 '@babel/helper-annotate-as-pure@7.27.3': dependencies: - '@babel/types': 7.27.6 + '@babel/types': 7.27.7 '@babel/helper-compilation-targets@7.27.2': dependencies: - '@babel/compat-data': 7.27.5 + '@babel/compat-data': 7.27.7 '@babel/helper-validator-option': 7.27.1 browserslist: 4.25.1 lru-cache: 5.1.1 semver: 6.3.1 - '@babel/helper-create-class-features-plugin@7.27.1(@babel/core@7.27.4)': + '@babel/helper-create-class-features-plugin@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-annotate-as-pure': 7.27.3 '@babel/helper-member-expression-to-functions': 7.27.1 '@babel/helper-optimise-call-expression': 7.27.1 - '@babel/helper-replace-supers': 7.27.1(@babel/core@7.27.4) + '@babel/helper-replace-supers': 7.27.1(@babel/core@7.27.7) '@babel/helper-skip-transparent-expression-wrappers': 7.27.1 - '@babel/traverse': 7.27.4 + '@babel/traverse': 7.27.7 semver: 6.3.1 transitivePeerDependencies: - supports-color - '@babel/helper-create-regexp-features-plugin@7.27.1(@babel/core@7.27.4)': + '@babel/helper-create-regexp-features-plugin@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-annotate-as-pure': 7.27.3 regexpu-core: 6.2.0 semver: 6.3.1 - '@babel/helper-define-polyfill-provider@0.6.4(@babel/core@7.27.4)': + '@babel/helper-define-polyfill-provider@0.6.5(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-compilation-targets': 7.27.2 '@babel/helper-plugin-utils': 7.27.1 debug: 4.4.1 @@ -7170,55 +7235,55 @@ snapshots: '@babel/helper-member-expression-to-functions@7.27.1': dependencies: - '@babel/traverse': 7.27.4 - '@babel/types': 7.27.6 + '@babel/traverse': 7.27.7 + '@babel/types': 7.27.7 transitivePeerDependencies: - supports-color '@babel/helper-module-imports@7.27.1': dependencies: - '@babel/traverse': 7.27.4 - '@babel/types': 7.27.6 + '@babel/traverse': 7.27.7 + '@babel/types': 7.27.7 transitivePeerDependencies: - supports-color - '@babel/helper-module-transforms@7.27.3(@babel/core@7.27.4)': + '@babel/helper-module-transforms@7.27.3(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-module-imports': 7.27.1 '@babel/helper-validator-identifier': 7.27.1 - '@babel/traverse': 7.27.4 + '@babel/traverse': 7.27.7 transitivePeerDependencies: - supports-color '@babel/helper-optimise-call-expression@7.27.1': dependencies: - '@babel/types': 7.27.6 + '@babel/types': 7.27.7 '@babel/helper-plugin-utils@7.27.1': {} - '@babel/helper-remap-async-to-generator@7.27.1(@babel/core@7.27.4)': + '@babel/helper-remap-async-to-generator@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-annotate-as-pure': 7.27.3 '@babel/helper-wrap-function': 7.27.1 - '@babel/traverse': 7.27.4 + '@babel/traverse': 7.27.7 transitivePeerDependencies: - supports-color - '@babel/helper-replace-supers@7.27.1(@babel/core@7.27.4)': + '@babel/helper-replace-supers@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-member-expression-to-functions': 7.27.1 '@babel/helper-optimise-call-expression': 7.27.1 - '@babel/traverse': 7.27.4 + '@babel/traverse': 7.27.7 transitivePeerDependencies: - supports-color '@babel/helper-skip-transparent-expression-wrappers@7.27.1': dependencies: - '@babel/traverse': 7.27.4 - '@babel/types': 7.27.6 + '@babel/traverse': 7.27.7 + '@babel/types': 7.27.7 transitivePeerDependencies: - supports-color @@ -7231,568 +7296,574 @@ snapshots: '@babel/helper-wrap-function@7.27.1': dependencies: '@babel/template': 7.27.2 - '@babel/traverse': 7.27.4 - '@babel/types': 7.27.6 + '@babel/traverse': 7.27.7 + '@babel/types': 7.27.7 transitivePeerDependencies: - supports-color '@babel/helpers@7.27.6': dependencies: '@babel/template': 7.27.2 - '@babel/types': 7.27.6 + '@babel/types': 7.27.7 - '@babel/parser@7.27.5': + '@babel/parser@7.27.7': dependencies: - '@babel/types': 7.27.6 + '@babel/types': 7.27.7 - '@babel/plugin-bugfix-firefox-class-in-computed-class-key@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-bugfix-firefox-class-in-computed-class-key@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/traverse': 7.27.4 + '@babel/traverse': 7.27.7 transitivePeerDependencies: - supports-color - '@babel/plugin-bugfix-safari-class-field-initializer-scope@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-bugfix-safari-class-field-initializer-scope@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 '@babel/helper-skip-transparent-expression-wrappers': 7.27.1 - '@babel/plugin-transform-optional-chaining': 7.27.1(@babel/core@7.27.4) + '@babel/plugin-transform-optional-chaining': 7.27.1(@babel/core@7.27.7) transitivePeerDependencies: - supports-color - '@babel/plugin-bugfix-v8-static-class-fields-redefine-readonly@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-bugfix-v8-static-class-fields-redefine-readonly@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/traverse': 7.27.4 + '@babel/traverse': 7.27.7 transitivePeerDependencies: - supports-color - '@babel/plugin-proposal-private-property-in-object@7.21.0-placeholder-for-preset-env.2(@babel/core@7.27.4)': + '@babel/plugin-proposal-private-property-in-object@7.21.0-placeholder-for-preset-env.2(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 - '@babel/plugin-syntax-bigint@7.8.3(@babel/core@7.27.4)': + '@babel/plugin-syntax-bigint@7.8.3(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-syntax-dynamic-import@7.8.3(@babel/core@7.27.4)': + '@babel/plugin-syntax-dynamic-import@7.8.3(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-syntax-import-assertions@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-syntax-import-assertions@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-syntax-import-attributes@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-syntax-import-attributes@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-syntax-jsx@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-syntax-jsx@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-syntax-typescript@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-syntax-typescript@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-syntax-unicode-sets-regex@7.18.6(@babel/core@7.27.4)': + '@babel/plugin-syntax-unicode-sets-regex@7.18.6(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 - '@babel/helper-create-regexp-features-plugin': 7.27.1(@babel/core@7.27.4) + '@babel/core': 7.27.7 + '@babel/helper-create-regexp-features-plugin': 7.27.1(@babel/core@7.27.7) '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-transform-arrow-functions@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-arrow-functions@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-transform-async-generator-functions@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-async-generator-functions@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/helper-remap-async-to-generator': 7.27.1(@babel/core@7.27.4) - '@babel/traverse': 7.27.4 + '@babel/helper-remap-async-to-generator': 7.27.1(@babel/core@7.27.7) + '@babel/traverse': 7.27.7 transitivePeerDependencies: - supports-color - '@babel/plugin-transform-async-to-generator@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-async-to-generator@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-module-imports': 7.27.1 '@babel/helper-plugin-utils': 7.27.1 - '@babel/helper-remap-async-to-generator': 7.27.1(@babel/core@7.27.4) + '@babel/helper-remap-async-to-generator': 7.27.1(@babel/core@7.27.7) transitivePeerDependencies: - supports-color - '@babel/plugin-transform-block-scoped-functions@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-block-scoped-functions@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-transform-block-scoping@7.27.5(@babel/core@7.27.4)': + '@babel/plugin-transform-block-scoping@7.27.5(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-transform-class-properties@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-class-properties@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 - '@babel/helper-create-class-features-plugin': 7.27.1(@babel/core@7.27.4) + '@babel/core': 7.27.7 + '@babel/helper-create-class-features-plugin': 7.27.1(@babel/core@7.27.7) '@babel/helper-plugin-utils': 7.27.1 transitivePeerDependencies: - supports-color - '@babel/plugin-transform-class-static-block@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-class-static-block@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 - '@babel/helper-create-class-features-plugin': 7.27.1(@babel/core@7.27.4) + '@babel/core': 7.27.7 + '@babel/helper-create-class-features-plugin': 7.27.1(@babel/core@7.27.7) '@babel/helper-plugin-utils': 7.27.1 transitivePeerDependencies: - supports-color - '@babel/plugin-transform-classes@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-classes@7.27.7(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-annotate-as-pure': 7.27.3 '@babel/helper-compilation-targets': 7.27.2 '@babel/helper-plugin-utils': 7.27.1 - '@babel/helper-replace-supers': 7.27.1(@babel/core@7.27.4) - '@babel/traverse': 7.27.4 + '@babel/helper-replace-supers': 7.27.1(@babel/core@7.27.7) + '@babel/traverse': 7.27.7 globals: 11.12.0 transitivePeerDependencies: - supports-color - '@babel/plugin-transform-computed-properties@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-computed-properties@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 '@babel/template': 7.27.2 - '@babel/plugin-transform-destructuring@7.27.3(@babel/core@7.27.4)': + '@babel/plugin-transform-destructuring@7.27.7(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 + '@babel/helper-plugin-utils': 7.27.1 + '@babel/traverse': 7.27.7 + transitivePeerDependencies: + - supports-color + + '@babel/plugin-transform-dotall-regex@7.27.1(@babel/core@7.27.7)': + dependencies: + '@babel/core': 7.27.7 + '@babel/helper-create-regexp-features-plugin': 7.27.1(@babel/core@7.27.7) '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-transform-dotall-regex@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-duplicate-keys@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 - '@babel/helper-create-regexp-features-plugin': 7.27.1(@babel/core@7.27.4) + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-transform-duplicate-keys@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-duplicate-named-capturing-groups-regex@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 + '@babel/helper-create-regexp-features-plugin': 7.27.1(@babel/core@7.27.7) '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-transform-duplicate-named-capturing-groups-regex@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-dynamic-import@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 - '@babel/helper-create-regexp-features-plugin': 7.27.1(@babel/core@7.27.4) + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-transform-dynamic-import@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-exponentiation-operator@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-transform-exponentiation-operator@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-export-namespace-from@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-transform-export-namespace-from@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-for-of@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 - '@babel/helper-plugin-utils': 7.27.1 - - '@babel/plugin-transform-for-of@7.27.1(@babel/core@7.27.4)': - dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 '@babel/helper-skip-transparent-expression-wrappers': 7.27.1 transitivePeerDependencies: - supports-color - '@babel/plugin-transform-function-name@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-function-name@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-compilation-targets': 7.27.2 '@babel/helper-plugin-utils': 7.27.1 - '@babel/traverse': 7.27.4 + '@babel/traverse': 7.27.7 transitivePeerDependencies: - supports-color - '@babel/plugin-transform-json-strings@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-json-strings@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-transform-literals@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-literals@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-transform-logical-assignment-operators@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-logical-assignment-operators@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-transform-member-expression-literals@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-member-expression-literals@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-transform-modules-amd@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-modules-amd@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 - '@babel/helper-module-transforms': 7.27.3(@babel/core@7.27.4) + '@babel/core': 7.27.7 + '@babel/helper-module-transforms': 7.27.3(@babel/core@7.27.7) '@babel/helper-plugin-utils': 7.27.1 transitivePeerDependencies: - supports-color - '@babel/plugin-transform-modules-commonjs@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-modules-commonjs@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 - '@babel/helper-module-transforms': 7.27.3(@babel/core@7.27.4) + '@babel/core': 7.27.7 + '@babel/helper-module-transforms': 7.27.3(@babel/core@7.27.7) '@babel/helper-plugin-utils': 7.27.1 transitivePeerDependencies: - supports-color - '@babel/plugin-transform-modules-systemjs@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-modules-systemjs@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 - '@babel/helper-module-transforms': 7.27.3(@babel/core@7.27.4) + '@babel/core': 7.27.7 + '@babel/helper-module-transforms': 7.27.3(@babel/core@7.27.7) '@babel/helper-plugin-utils': 7.27.1 '@babel/helper-validator-identifier': 7.27.1 - '@babel/traverse': 7.27.4 + '@babel/traverse': 7.27.7 transitivePeerDependencies: - supports-color - '@babel/plugin-transform-modules-umd@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-modules-umd@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 - '@babel/helper-module-transforms': 7.27.3(@babel/core@7.27.4) + '@babel/core': 7.27.7 + '@babel/helper-module-transforms': 7.27.3(@babel/core@7.27.7) '@babel/helper-plugin-utils': 7.27.1 transitivePeerDependencies: - supports-color - '@babel/plugin-transform-named-capturing-groups-regex@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-named-capturing-groups-regex@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 - '@babel/helper-create-regexp-features-plugin': 7.27.1(@babel/core@7.27.4) + '@babel/core': 7.27.7 + '@babel/helper-create-regexp-features-plugin': 7.27.1(@babel/core@7.27.7) '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-transform-new-target@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-new-target@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-transform-nullish-coalescing-operator@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-nullish-coalescing-operator@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-transform-numeric-separator@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-numeric-separator@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-transform-object-rest-spread@7.27.3(@babel/core@7.27.4)': + '@babel/plugin-transform-object-rest-spread@7.27.7(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-compilation-targets': 7.27.2 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-transform-destructuring': 7.27.3(@babel/core@7.27.4) - '@babel/plugin-transform-parameters': 7.27.1(@babel/core@7.27.4) - - '@babel/plugin-transform-object-super@7.27.1(@babel/core@7.27.4)': - dependencies: - '@babel/core': 7.27.4 - '@babel/helper-plugin-utils': 7.27.1 - '@babel/helper-replace-supers': 7.27.1(@babel/core@7.27.4) + '@babel/plugin-transform-destructuring': 7.27.7(@babel/core@7.27.7) + '@babel/plugin-transform-parameters': 7.27.7(@babel/core@7.27.7) + '@babel/traverse': 7.27.7 transitivePeerDependencies: - supports-color - '@babel/plugin-transform-optional-catch-binding@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-object-super@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 + '@babel/helper-plugin-utils': 7.27.1 + '@babel/helper-replace-supers': 7.27.1(@babel/core@7.27.7) + transitivePeerDependencies: + - supports-color + + '@babel/plugin-transform-optional-catch-binding@7.27.1(@babel/core@7.27.7)': + dependencies: + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-transform-optional-chaining@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-optional-chaining@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 '@babel/helper-skip-transparent-expression-wrappers': 7.27.1 transitivePeerDependencies: - supports-color - '@babel/plugin-transform-parameters@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-parameters@7.27.7(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-transform-private-methods@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-private-methods@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 - '@babel/helper-create-class-features-plugin': 7.27.1(@babel/core@7.27.4) + '@babel/core': 7.27.7 + '@babel/helper-create-class-features-plugin': 7.27.1(@babel/core@7.27.7) '@babel/helper-plugin-utils': 7.27.1 transitivePeerDependencies: - supports-color - '@babel/plugin-transform-private-property-in-object@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-private-property-in-object@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-annotate-as-pure': 7.27.3 - '@babel/helper-create-class-features-plugin': 7.27.1(@babel/core@7.27.4) + '@babel/helper-create-class-features-plugin': 7.27.1(@babel/core@7.27.7) '@babel/helper-plugin-utils': 7.27.1 transitivePeerDependencies: - supports-color - '@babel/plugin-transform-property-literals@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-property-literals@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-transform-react-display-name@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-react-display-name@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-transform-react-jsx-development@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-react-jsx-development@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 - '@babel/plugin-transform-react-jsx': 7.27.1(@babel/core@7.27.4) + '@babel/core': 7.27.7 + '@babel/plugin-transform-react-jsx': 7.27.1(@babel/core@7.27.7) transitivePeerDependencies: - supports-color - '@babel/plugin-transform-react-jsx@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-react-jsx@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-annotate-as-pure': 7.27.3 '@babel/helper-module-imports': 7.27.1 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-syntax-jsx': 7.27.1(@babel/core@7.27.4) - '@babel/types': 7.27.6 + '@babel/plugin-syntax-jsx': 7.27.1(@babel/core@7.27.7) + '@babel/types': 7.27.7 transitivePeerDependencies: - supports-color - '@babel/plugin-transform-react-pure-annotations@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-react-pure-annotations@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-annotate-as-pure': 7.27.3 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-transform-regenerator@7.27.5(@babel/core@7.27.4)': + '@babel/plugin-transform-regenerator@7.27.5(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-transform-regexp-modifiers@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-regexp-modifiers@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 - '@babel/helper-create-regexp-features-plugin': 7.27.1(@babel/core@7.27.4) + '@babel/core': 7.27.7 + '@babel/helper-create-regexp-features-plugin': 7.27.1(@babel/core@7.27.7) '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-transform-reserved-words@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-reserved-words@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-transform-runtime@7.27.4(@babel/core@7.27.4)': + '@babel/plugin-transform-runtime@7.27.4(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-module-imports': 7.27.1 '@babel/helper-plugin-utils': 7.27.1 - babel-plugin-polyfill-corejs2: 0.4.13(@babel/core@7.27.4) - babel-plugin-polyfill-corejs3: 0.11.1(@babel/core@7.27.4) - babel-plugin-polyfill-regenerator: 0.6.4(@babel/core@7.27.4) + babel-plugin-polyfill-corejs2: 0.4.14(@babel/core@7.27.7) + babel-plugin-polyfill-corejs3: 0.11.1(@babel/core@7.27.7) + babel-plugin-polyfill-regenerator: 0.6.5(@babel/core@7.27.7) semver: 6.3.1 transitivePeerDependencies: - supports-color - '@babel/plugin-transform-shorthand-properties@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-shorthand-properties@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-transform-spread@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-spread@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 '@babel/helper-skip-transparent-expression-wrappers': 7.27.1 transitivePeerDependencies: - supports-color - '@babel/plugin-transform-sticky-regex@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-sticky-regex@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-transform-template-literals@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-template-literals@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-transform-typeof-symbol@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-typeof-symbol@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-transform-typescript@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-typescript@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-annotate-as-pure': 7.27.3 - '@babel/helper-create-class-features-plugin': 7.27.1(@babel/core@7.27.4) + '@babel/helper-create-class-features-plugin': 7.27.1(@babel/core@7.27.7) '@babel/helper-plugin-utils': 7.27.1 '@babel/helper-skip-transparent-expression-wrappers': 7.27.1 - '@babel/plugin-syntax-typescript': 7.27.1(@babel/core@7.27.4) + '@babel/plugin-syntax-typescript': 7.27.1(@babel/core@7.27.7) transitivePeerDependencies: - supports-color - '@babel/plugin-transform-unicode-escapes@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-unicode-escapes@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-transform-unicode-property-regex@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-unicode-property-regex@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 - '@babel/helper-create-regexp-features-plugin': 7.27.1(@babel/core@7.27.4) + '@babel/core': 7.27.7 + '@babel/helper-create-regexp-features-plugin': 7.27.1(@babel/core@7.27.7) '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-transform-unicode-regex@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-unicode-regex@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 - '@babel/helper-create-regexp-features-plugin': 7.27.1(@babel/core@7.27.4) + '@babel/core': 7.27.7 + '@babel/helper-create-regexp-features-plugin': 7.27.1(@babel/core@7.27.7) '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-transform-unicode-sets-regex@7.27.1(@babel/core@7.27.4)': + '@babel/plugin-transform-unicode-sets-regex@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 - '@babel/helper-create-regexp-features-plugin': 7.27.1(@babel/core@7.27.4) + '@babel/core': 7.27.7 + '@babel/helper-create-regexp-features-plugin': 7.27.1(@babel/core@7.27.7) '@babel/helper-plugin-utils': 7.27.1 - '@babel/preset-env@7.27.2(@babel/core@7.27.4)': + '@babel/preset-env@7.27.2(@babel/core@7.27.7)': dependencies: - '@babel/compat-data': 7.27.5 - '@babel/core': 7.27.4 + '@babel/compat-data': 7.27.7 + '@babel/core': 7.27.7 '@babel/helper-compilation-targets': 7.27.2 '@babel/helper-plugin-utils': 7.27.1 '@babel/helper-validator-option': 7.27.1 - '@babel/plugin-bugfix-firefox-class-in-computed-class-key': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-bugfix-safari-class-field-initializer-scope': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-bugfix-v8-static-class-fields-redefine-readonly': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-proposal-private-property-in-object': 7.21.0-placeholder-for-preset-env.2(@babel/core@7.27.4) - '@babel/plugin-syntax-import-assertions': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-syntax-import-attributes': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-syntax-unicode-sets-regex': 7.18.6(@babel/core@7.27.4) - '@babel/plugin-transform-arrow-functions': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-async-generator-functions': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-async-to-generator': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-block-scoped-functions': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-block-scoping': 7.27.5(@babel/core@7.27.4) - '@babel/plugin-transform-class-properties': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-class-static-block': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-classes': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-computed-properties': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-destructuring': 7.27.3(@babel/core@7.27.4) - '@babel/plugin-transform-dotall-regex': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-duplicate-keys': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-duplicate-named-capturing-groups-regex': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-dynamic-import': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-exponentiation-operator': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-export-namespace-from': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-for-of': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-function-name': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-json-strings': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-literals': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-logical-assignment-operators': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-member-expression-literals': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-modules-amd': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-modules-commonjs': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-modules-systemjs': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-modules-umd': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-named-capturing-groups-regex': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-new-target': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-nullish-coalescing-operator': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-numeric-separator': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-object-rest-spread': 7.27.3(@babel/core@7.27.4) - '@babel/plugin-transform-object-super': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-optional-catch-binding': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-optional-chaining': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-parameters': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-private-methods': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-private-property-in-object': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-property-literals': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-regenerator': 7.27.5(@babel/core@7.27.4) - '@babel/plugin-transform-regexp-modifiers': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-reserved-words': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-shorthand-properties': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-spread': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-sticky-regex': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-template-literals': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-typeof-symbol': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-unicode-escapes': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-unicode-property-regex': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-unicode-regex': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-unicode-sets-regex': 7.27.1(@babel/core@7.27.4) - '@babel/preset-modules': 0.1.6-no-external-plugins(@babel/core@7.27.4) - babel-plugin-polyfill-corejs2: 0.4.13(@babel/core@7.27.4) - babel-plugin-polyfill-corejs3: 0.11.1(@babel/core@7.27.4) - babel-plugin-polyfill-regenerator: 0.6.4(@babel/core@7.27.4) + '@babel/plugin-bugfix-firefox-class-in-computed-class-key': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-bugfix-safari-class-field-initializer-scope': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-bugfix-v8-static-class-fields-redefine-readonly': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-proposal-private-property-in-object': 7.21.0-placeholder-for-preset-env.2(@babel/core@7.27.7) + '@babel/plugin-syntax-import-assertions': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-syntax-import-attributes': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-syntax-unicode-sets-regex': 7.18.6(@babel/core@7.27.7) + '@babel/plugin-transform-arrow-functions': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-async-generator-functions': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-async-to-generator': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-block-scoped-functions': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-block-scoping': 7.27.5(@babel/core@7.27.7) + '@babel/plugin-transform-class-properties': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-class-static-block': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-classes': 7.27.7(@babel/core@7.27.7) + '@babel/plugin-transform-computed-properties': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-destructuring': 7.27.7(@babel/core@7.27.7) + '@babel/plugin-transform-dotall-regex': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-duplicate-keys': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-duplicate-named-capturing-groups-regex': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-dynamic-import': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-exponentiation-operator': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-export-namespace-from': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-for-of': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-function-name': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-json-strings': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-literals': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-logical-assignment-operators': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-member-expression-literals': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-modules-amd': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-modules-commonjs': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-modules-systemjs': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-modules-umd': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-named-capturing-groups-regex': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-new-target': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-nullish-coalescing-operator': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-numeric-separator': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-object-rest-spread': 7.27.7(@babel/core@7.27.7) + '@babel/plugin-transform-object-super': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-optional-catch-binding': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-optional-chaining': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-parameters': 7.27.7(@babel/core@7.27.7) + '@babel/plugin-transform-private-methods': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-private-property-in-object': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-property-literals': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-regenerator': 7.27.5(@babel/core@7.27.7) + '@babel/plugin-transform-regexp-modifiers': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-reserved-words': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-shorthand-properties': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-spread': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-sticky-regex': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-template-literals': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-typeof-symbol': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-unicode-escapes': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-unicode-property-regex': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-unicode-regex': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-unicode-sets-regex': 7.27.1(@babel/core@7.27.7) + '@babel/preset-modules': 0.1.6-no-external-plugins(@babel/core@7.27.7) + babel-plugin-polyfill-corejs2: 0.4.14(@babel/core@7.27.7) + babel-plugin-polyfill-corejs3: 0.11.1(@babel/core@7.27.7) + babel-plugin-polyfill-regenerator: 0.6.5(@babel/core@7.27.7) core-js-compat: 3.43.0 semver: 6.3.1 transitivePeerDependencies: - supports-color - '@babel/preset-modules@0.1.6-no-external-plugins(@babel/core@7.27.4)': + '@babel/preset-modules@0.1.6-no-external-plugins(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/types': 7.27.6 + '@babel/types': 7.27.7 esutils: 2.0.3 - '@babel/preset-react@7.27.1(@babel/core@7.27.4)': + '@babel/preset-react@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 '@babel/helper-validator-option': 7.27.1 - '@babel/plugin-transform-react-display-name': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-react-jsx': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-react-jsx-development': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-react-pure-annotations': 7.27.1(@babel/core@7.27.4) + '@babel/plugin-transform-react-display-name': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-react-jsx': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-react-jsx-development': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-react-pure-annotations': 7.27.1(@babel/core@7.27.7) transitivePeerDependencies: - supports-color - '@babel/preset-typescript@7.27.1(@babel/core@7.27.4)': + '@babel/preset-typescript@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 '@babel/helper-validator-option': 7.27.1 - '@babel/plugin-syntax-jsx': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-modules-commonjs': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-typescript': 7.27.1(@babel/core@7.27.4) + '@babel/plugin-syntax-jsx': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-modules-commonjs': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-typescript': 7.27.1(@babel/core@7.27.7) transitivePeerDependencies: - supports-color @@ -7801,22 +7872,22 @@ snapshots: '@babel/template@7.27.2': dependencies: '@babel/code-frame': 7.27.1 - '@babel/parser': 7.27.5 - '@babel/types': 7.27.6 + '@babel/parser': 7.27.7 + '@babel/types': 7.27.7 - '@babel/traverse@7.27.4': + '@babel/traverse@7.27.7': dependencies: '@babel/code-frame': 7.27.1 '@babel/generator': 7.27.5 - '@babel/parser': 7.27.5 + '@babel/parser': 7.27.7 '@babel/template': 7.27.2 - '@babel/types': 7.27.6 + '@babel/types': 7.27.7 debug: 4.4.1 globals: 11.12.0 transitivePeerDependencies: - supports-color - '@babel/types@7.27.6': + '@babel/types@7.27.7': dependencies: '@babel/helper-string-parser': 7.27.1 '@babel/helper-validator-identifier': 7.27.1 @@ -7834,13 +7905,13 @@ snapshots: '@types/tough-cookie': 4.0.5 tough-cookie: 4.1.4 - '@chromatic-com/storybook@4.0.1(storybook@9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1))': + '@chromatic-com/storybook@4.0.1(storybook@9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2))': dependencies: '@neoconfetti/react': 1.0.0 chromatic: 12.2.0 filesize: 10.1.6 jsonfile: 6.1.0 - storybook: 9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1) + storybook: 9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2) strip-ansi: 7.1.0 transitivePeerDependencies: - '@chromatic-com/cypress' @@ -8150,6 +8221,11 @@ snapshots: wrap-ansi: 8.1.0 wrap-ansi-cjs: wrap-ansi@7.0.0 + '@jridgewell/gen-mapping@0.3.10': + dependencies: + '@jridgewell/sourcemap-codec': 1.5.2 + '@jridgewell/trace-mapping': 0.3.27 + '@jridgewell/gen-mapping@0.3.8': dependencies: '@jridgewell/set-array': 1.2.1 @@ -8160,18 +8236,25 @@ snapshots: '@jridgewell/set-array@1.2.1': {} - '@jridgewell/source-map@0.3.6': + '@jridgewell/source-map@0.3.8': dependencies: - '@jridgewell/gen-mapping': 0.3.8 - '@jridgewell/trace-mapping': 0.3.25 + '@jridgewell/gen-mapping': 0.3.10 + '@jridgewell/trace-mapping': 0.3.27 '@jridgewell/sourcemap-codec@1.5.0': {} + '@jridgewell/sourcemap-codec@1.5.2': {} + '@jridgewell/trace-mapping@0.3.25': dependencies: '@jridgewell/resolve-uri': 3.1.2 '@jridgewell/sourcemap-codec': 1.5.0 + '@jridgewell/trace-mapping@0.3.27': + dependencies: + '@jridgewell/resolve-uri': 3.1.2 + '@jridgewell/sourcemap-codec': 1.5.2 + '@jsdevtools/ono@7.1.3': {} '@jsep-plugin/assignment@1.3.0(jsep@1.4.0)': @@ -8240,9 +8323,9 @@ snapshots: '@next/swc-win32-x64-msvc@15.3.3': optional: true - '@next/third-parties@15.3.3(next@15.3.3(@babel/core@7.27.4)(@opentelemetry/api@1.9.0)(@playwright/test@1.53.1)(react-dom@18.3.1(react@18.3.1))(react@18.3.1))(react@18.3.1)': + '@next/third-parties@15.3.3(next@15.3.3(@babel/core@7.27.7)(@opentelemetry/api@1.9.0)(@playwright/test@1.53.1)(react-dom@18.3.1(react@18.3.1))(react@18.3.1))(react@18.3.1)': dependencies: - next: 15.3.3(@babel/core@7.27.4)(@opentelemetry/api@1.9.0)(@playwright/test@1.53.1)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + next: 15.3.3(@babel/core@7.27.7)(@opentelemetry/api@1.9.0)(@playwright/test@1.53.1)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) react: 18.3.1 third-party-capital: 1.0.20 @@ -9302,7 +9385,7 @@ snapshots: '@sentry/bundler-plugin-core@3.5.0': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@sentry/babel-plugin-component-annotate': 3.5.0 '@sentry/cli': 2.42.2 dotenv: 16.5.0 @@ -9356,7 +9439,7 @@ snapshots: '@sentry/core@9.27.0': {} - '@sentry/nextjs@9.27.0(@opentelemetry/context-async-hooks@1.30.1(@opentelemetry/api@1.9.0))(@opentelemetry/core@1.30.1(@opentelemetry/api@1.9.0))(@opentelemetry/instrumentation@0.57.2(@opentelemetry/api@1.9.0))(@opentelemetry/sdk-trace-base@1.30.1(@opentelemetry/api@1.9.0))(next@15.3.3(@babel/core@7.27.4)(@opentelemetry/api@1.9.0)(@playwright/test@1.53.1)(react-dom@18.3.1(react@18.3.1))(react@18.3.1))(react@18.3.1)(webpack@5.99.9(esbuild@0.25.5))': + '@sentry/nextjs@9.27.0(@opentelemetry/context-async-hooks@1.30.1(@opentelemetry/api@1.9.0))(@opentelemetry/core@1.30.1(@opentelemetry/api@1.9.0))(@opentelemetry/instrumentation@0.57.2(@opentelemetry/api@1.9.0))(@opentelemetry/sdk-trace-base@1.30.1(@opentelemetry/api@1.9.0))(next@15.3.3(@babel/core@7.27.7)(@opentelemetry/api@1.9.0)(@playwright/test@1.53.1)(react-dom@18.3.1(react@18.3.1))(react@18.3.1))(react@18.3.1)(webpack@5.99.9(esbuild@0.25.5))': dependencies: '@opentelemetry/api': 1.9.0 '@opentelemetry/semantic-conventions': 1.34.0 @@ -9369,7 +9452,7 @@ snapshots: '@sentry/vercel-edge': 9.27.0 '@sentry/webpack-plugin': 3.5.0(webpack@5.99.9(esbuild@0.25.5)) chalk: 3.0.0 - next: 15.3.3(@babel/core@7.27.4)(@opentelemetry/api@1.9.0)(@playwright/test@1.53.1)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + next: 15.3.3(@babel/core@7.27.7)(@opentelemetry/api@1.9.0)(@playwright/test@1.53.1)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) resolve: 1.22.8 rollup: 4.35.0 stacktrace-parser: 0.1.11 @@ -9639,39 +9722,39 @@ snapshots: '@stoplight/yaml-ast-parser': 0.0.50 tslib: 2.8.1 - '@storybook/addon-a11y@9.0.13(storybook@9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1))': + '@storybook/addon-a11y@9.0.14(storybook@9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2))': dependencies: '@storybook/global': 5.0.0 axe-core: 4.10.3 - storybook: 9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1) + storybook: 9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2) - '@storybook/addon-docs@9.0.13(@types/react@18.3.17)(storybook@9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1))': + '@storybook/addon-docs@9.0.14(@types/react@18.3.17)(storybook@9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2))': dependencies: '@mdx-js/react': 3.1.0(@types/react@18.3.17)(react@18.3.1) - '@storybook/csf-plugin': 9.0.13(storybook@9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1)) + '@storybook/csf-plugin': 9.0.14(storybook@9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2)) '@storybook/icons': 1.4.0(react-dom@18.3.1(react@18.3.1))(react@18.3.1) - '@storybook/react-dom-shim': 9.0.13(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(storybook@9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1)) + '@storybook/react-dom-shim': 9.0.14(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(storybook@9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2)) react: 18.3.1 react-dom: 18.3.1(react@18.3.1) - storybook: 9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1) + storybook: 9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2) ts-dedent: 2.2.0 transitivePeerDependencies: - '@types/react' - '@storybook/addon-links@9.0.13(react@18.3.1)(storybook@9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1))': + '@storybook/addon-links@9.0.14(react@18.3.1)(storybook@9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2))': dependencies: '@storybook/global': 5.0.0 - storybook: 9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1) + storybook: 9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2) optionalDependencies: react: 18.3.1 - '@storybook/addon-onboarding@9.0.13(storybook@9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1))': + '@storybook/addon-onboarding@9.0.14(storybook@9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2))': dependencies: - storybook: 9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1) + storybook: 9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2) - '@storybook/builder-webpack5@9.0.13(esbuild@0.25.5)(storybook@9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1))(typescript@5.8.3)': + '@storybook/builder-webpack5@9.0.14(esbuild@0.25.5)(storybook@9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2))(typescript@5.8.3)': dependencies: - '@storybook/core-webpack': 9.0.13(storybook@9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1)) + '@storybook/core-webpack': 9.0.14(storybook@9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2)) case-sensitive-paths-webpack-plugin: 2.4.0 cjs-module-lexer: 1.4.3 css-loader: 6.11.0(webpack@5.99.9(esbuild@0.25.5)) @@ -9679,7 +9762,7 @@ snapshots: fork-ts-checker-webpack-plugin: 8.0.0(typescript@5.8.3)(webpack@5.99.9(esbuild@0.25.5)) html-webpack-plugin: 5.6.3(webpack@5.99.9(esbuild@0.25.5)) magic-string: 0.30.17 - storybook: 9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1) + storybook: 9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2) style-loader: 3.3.4(webpack@5.99.9(esbuild@0.25.5)) terser-webpack-plugin: 5.3.14(esbuild@0.25.5)(webpack@5.99.9(esbuild@0.25.5)) ts-dedent: 2.2.0 @@ -9696,14 +9779,14 @@ snapshots: - uglify-js - webpack-cli - '@storybook/core-webpack@9.0.13(storybook@9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1))': + '@storybook/core-webpack@9.0.14(storybook@9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2))': dependencies: - storybook: 9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1) + storybook: 9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2) ts-dedent: 2.2.0 - '@storybook/csf-plugin@9.0.13(storybook@9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1))': + '@storybook/csf-plugin@9.0.14(storybook@9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2))': dependencies: - storybook: 9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1) + storybook: 9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2) unplugin: 1.16.1 '@storybook/global@5.0.0': {} @@ -9713,31 +9796,31 @@ snapshots: react: 18.3.1 react-dom: 18.3.1(react@18.3.1) - '@storybook/nextjs@9.0.13(esbuild@0.25.5)(next@15.3.3(@babel/core@7.27.4)(@opentelemetry/api@1.9.0)(@playwright/test@1.53.1)(react-dom@18.3.1(react@18.3.1))(react@18.3.1))(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(storybook@9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1))(type-fest@4.41.0)(typescript@5.8.3)(webpack-hot-middleware@2.26.1)(webpack@5.99.9(esbuild@0.25.5))': + '@storybook/nextjs@9.0.14(esbuild@0.25.5)(next@15.3.3(@babel/core@7.27.7)(@opentelemetry/api@1.9.0)(@playwright/test@1.53.1)(react-dom@18.3.1(react@18.3.1))(react@18.3.1))(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(storybook@9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2))(type-fest@4.41.0)(typescript@5.8.3)(webpack-hot-middleware@2.26.1)(webpack@5.99.9(esbuild@0.25.5))': dependencies: - '@babel/core': 7.27.4 - '@babel/plugin-syntax-bigint': 7.8.3(@babel/core@7.27.4) - '@babel/plugin-syntax-dynamic-import': 7.8.3(@babel/core@7.27.4) - '@babel/plugin-syntax-import-assertions': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-class-properties': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-export-namespace-from': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-numeric-separator': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-transform-object-rest-spread': 7.27.3(@babel/core@7.27.4) - '@babel/plugin-transform-runtime': 7.27.4(@babel/core@7.27.4) - '@babel/preset-env': 7.27.2(@babel/core@7.27.4) - '@babel/preset-react': 7.27.1(@babel/core@7.27.4) - '@babel/preset-typescript': 7.27.1(@babel/core@7.27.4) + '@babel/core': 7.27.7 + '@babel/plugin-syntax-bigint': 7.8.3(@babel/core@7.27.7) + '@babel/plugin-syntax-dynamic-import': 7.8.3(@babel/core@7.27.7) + '@babel/plugin-syntax-import-assertions': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-class-properties': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-export-namespace-from': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-numeric-separator': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-transform-object-rest-spread': 7.27.7(@babel/core@7.27.7) + '@babel/plugin-transform-runtime': 7.27.4(@babel/core@7.27.7) + '@babel/preset-env': 7.27.2(@babel/core@7.27.7) + '@babel/preset-react': 7.27.1(@babel/core@7.27.7) + '@babel/preset-typescript': 7.27.1(@babel/core@7.27.7) '@babel/runtime': 7.27.6 '@pmmmwh/react-refresh-webpack-plugin': 0.5.17(react-refresh@0.14.2)(type-fest@4.41.0)(webpack-hot-middleware@2.26.1)(webpack@5.99.9(esbuild@0.25.5)) - '@storybook/builder-webpack5': 9.0.13(esbuild@0.25.5)(storybook@9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1))(typescript@5.8.3) - '@storybook/preset-react-webpack': 9.0.13(esbuild@0.25.5)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(storybook@9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1))(typescript@5.8.3) - '@storybook/react': 9.0.13(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(storybook@9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1))(typescript@5.8.3) + '@storybook/builder-webpack5': 9.0.14(esbuild@0.25.5)(storybook@9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2))(typescript@5.8.3) + '@storybook/preset-react-webpack': 9.0.14(esbuild@0.25.5)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(storybook@9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2))(typescript@5.8.3) + '@storybook/react': 9.0.14(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(storybook@9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2))(typescript@5.8.3) '@types/semver': 7.7.0 - babel-loader: 9.2.1(@babel/core@7.27.4)(webpack@5.99.9(esbuild@0.25.5)) + babel-loader: 9.2.1(@babel/core@7.27.7)(webpack@5.99.9(esbuild@0.25.5)) css-loader: 6.11.0(webpack@5.99.9(esbuild@0.25.5)) image-size: 2.0.2 loader-utils: 3.3.1 - next: 15.3.3(@babel/core@7.27.4)(@opentelemetry/api@1.9.0)(@playwright/test@1.53.1)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + next: 15.3.3(@babel/core@7.27.7)(@opentelemetry/api@1.9.0)(@playwright/test@1.53.1)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) node-polyfill-webpack-plugin: 2.0.1(webpack@5.99.9(esbuild@0.25.5)) postcss: 8.5.6 postcss-loader: 8.1.1(postcss@8.5.6)(typescript@5.8.3)(webpack@5.99.9(esbuild@0.25.5)) @@ -9747,9 +9830,9 @@ snapshots: resolve-url-loader: 5.0.0 sass-loader: 14.2.1(webpack@5.99.9(esbuild@0.25.5)) semver: 7.7.2 - storybook: 9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1) + storybook: 9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2) style-loader: 3.3.4(webpack@5.99.9(esbuild@0.25.5)) - styled-jsx: 5.1.7(@babel/core@7.27.4)(react@18.3.1) + styled-jsx: 5.1.7(@babel/core@7.27.7)(react@18.3.1) tsconfig-paths: 4.2.0 tsconfig-paths-webpack-plugin: 4.2.0 optionalDependencies: @@ -9773,9 +9856,9 @@ snapshots: - webpack-hot-middleware - webpack-plugin-serve - '@storybook/preset-react-webpack@9.0.13(esbuild@0.25.5)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(storybook@9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1))(typescript@5.8.3)': + '@storybook/preset-react-webpack@9.0.14(esbuild@0.25.5)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(storybook@9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2))(typescript@5.8.3)': dependencies: - '@storybook/core-webpack': 9.0.13(storybook@9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1)) + '@storybook/core-webpack': 9.0.14(storybook@9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2)) '@storybook/react-docgen-typescript-plugin': 1.0.6--canary.9.0c3f3b7.0(typescript@5.8.3)(webpack@5.99.9(esbuild@0.25.5)) '@types/semver': 7.7.0 find-up: 7.0.0 @@ -9785,7 +9868,7 @@ snapshots: react-dom: 18.3.1(react@18.3.1) resolve: 1.22.10 semver: 7.7.2 - storybook: 9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1) + storybook: 9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2) tsconfig-paths: 4.2.0 webpack: 5.99.9(esbuild@0.25.5) optionalDependencies: @@ -9811,19 +9894,19 @@ snapshots: transitivePeerDependencies: - supports-color - '@storybook/react-dom-shim@9.0.13(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(storybook@9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1))': + '@storybook/react-dom-shim@9.0.14(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(storybook@9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2))': dependencies: react: 18.3.1 react-dom: 18.3.1(react@18.3.1) - storybook: 9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1) + storybook: 9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2) - '@storybook/react@9.0.13(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(storybook@9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1))(typescript@5.8.3)': + '@storybook/react@9.0.14(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(storybook@9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2))(typescript@5.8.3)': dependencies: '@storybook/global': 5.0.0 - '@storybook/react-dom-shim': 9.0.13(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(storybook@9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1)) + '@storybook/react-dom-shim': 9.0.14(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(storybook@9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2)) react: 18.3.1 react-dom: 18.3.1(react@18.3.1) - storybook: 9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1) + storybook: 9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2) optionalDependencies: typescript: 5.8.3 @@ -9848,7 +9931,7 @@ snapshots: '@supabase/node-fetch': 2.6.15 '@types/phoenix': 1.6.6 '@types/ws': 8.18.1 - ws: 8.18.2 + ws: 8.18.3 transitivePeerDependencies: - bufferutil - utf-8-validate @@ -9892,7 +9975,7 @@ snapshots: '@tanstack/query-devtools@5.81.2': {} - '@tanstack/react-query-devtools@5.81.2(@tanstack/react-query@5.80.7(react@18.3.1))(react@18.3.1)': + '@tanstack/react-query-devtools@5.81.5(@tanstack/react-query@5.80.7(react@18.3.1))(react@18.3.1)': dependencies: '@tanstack/query-devtools': 5.81.2 '@tanstack/react-query': 5.80.7(react@18.3.1) @@ -9945,27 +10028,31 @@ snapshots: '@types/babel__core@7.20.5': dependencies: - '@babel/parser': 7.27.5 - '@babel/types': 7.27.6 + '@babel/parser': 7.27.7 + '@babel/types': 7.27.7 '@types/babel__generator': 7.27.0 '@types/babel__template': 7.4.4 '@types/babel__traverse': 7.20.7 '@types/babel__generator@7.27.0': dependencies: - '@babel/types': 7.27.6 + '@babel/types': 7.27.7 '@types/babel__template@7.4.4': dependencies: - '@babel/parser': 7.27.5 - '@babel/types': 7.27.6 + '@babel/parser': 7.27.7 + '@babel/types': 7.27.7 '@types/babel__traverse@7.20.7': dependencies: - '@babel/types': 7.27.6 + '@babel/types': 7.27.7 '@types/canvas-confetti@1.9.0': {} + '@types/chai@5.2.2': + dependencies: + '@types/deep-eql': 4.0.2 + '@types/connect@3.4.38': dependencies: '@types/node': 22.15.30 @@ -10015,6 +10102,8 @@ snapshots: dependencies: '@types/ms': 2.1.0 + '@types/deep-eql@4.0.2': {} + '@types/doctrine@0.0.9': {} '@types/es-aggregate-error@1.0.6': @@ -10175,6 +10264,15 @@ snapshots: transitivePeerDependencies: - supports-color + '@typescript-eslint/project-service@8.35.1(typescript@5.8.3)': + dependencies: + '@typescript-eslint/tsconfig-utils': 8.35.1(typescript@5.8.3) + '@typescript-eslint/types': 8.35.1 + debug: 4.4.1 + typescript: 5.8.3 + transitivePeerDependencies: + - supports-color + '@typescript-eslint/scope-manager@8.34.1': dependencies: '@typescript-eslint/types': 8.34.1 @@ -10185,6 +10283,11 @@ snapshots: '@typescript-eslint/types': 8.35.0 '@typescript-eslint/visitor-keys': 8.35.0 + '@typescript-eslint/scope-manager@8.35.1': + dependencies: + '@typescript-eslint/types': 8.35.1 + '@typescript-eslint/visitor-keys': 8.35.1 + '@typescript-eslint/tsconfig-utils@8.34.1(typescript@5.8.3)': dependencies: typescript: 5.8.3 @@ -10193,6 +10296,10 @@ snapshots: dependencies: typescript: 5.8.3 + '@typescript-eslint/tsconfig-utils@8.35.1(typescript@5.8.3)': + dependencies: + typescript: 5.8.3 + '@typescript-eslint/type-utils@8.34.1(eslint@8.57.1)(typescript@5.8.3)': dependencies: '@typescript-eslint/typescript-estree': 8.34.1(typescript@5.8.3) @@ -10208,6 +10315,8 @@ snapshots: '@typescript-eslint/types@8.35.0': {} + '@typescript-eslint/types@8.35.1': {} + '@typescript-eslint/typescript-estree@8.34.1(typescript@5.8.3)': dependencies: '@typescript-eslint/project-service': 8.34.1(typescript@5.8.3) @@ -10240,6 +10349,22 @@ snapshots: transitivePeerDependencies: - supports-color + '@typescript-eslint/typescript-estree@8.35.1(typescript@5.8.3)': + dependencies: + '@typescript-eslint/project-service': 8.35.1(typescript@5.8.3) + '@typescript-eslint/tsconfig-utils': 8.35.1(typescript@5.8.3) + '@typescript-eslint/types': 8.35.1 + '@typescript-eslint/visitor-keys': 8.35.1 + debug: 4.4.1 + fast-glob: 3.3.3 + is-glob: 4.0.3 + minimatch: 9.0.5 + semver: 7.7.2 + ts-api-utils: 2.1.0(typescript@5.8.3) + typescript: 5.8.3 + transitivePeerDependencies: + - supports-color + '@typescript-eslint/utils@8.34.1(eslint@8.57.1)(typescript@5.8.3)': dependencies: '@eslint-community/eslint-utils': 4.7.0(eslint@8.57.1) @@ -10262,6 +10387,17 @@ snapshots: transitivePeerDependencies: - supports-color + '@typescript-eslint/utils@8.35.1(eslint@8.57.1)(typescript@5.8.3)': + dependencies: + '@eslint-community/eslint-utils': 4.7.0(eslint@8.57.1) + '@typescript-eslint/scope-manager': 8.35.1 + '@typescript-eslint/types': 8.35.1 + '@typescript-eslint/typescript-estree': 8.35.1(typescript@5.8.3) + eslint: 8.57.1 + typescript: 5.8.3 + transitivePeerDependencies: + - supports-color + '@typescript-eslint/visitor-keys@8.34.1': dependencies: '@typescript-eslint/types': 8.34.1 @@ -10272,6 +10408,11 @@ snapshots: '@typescript-eslint/types': 8.35.0 eslint-visitor-keys: 4.2.1 + '@typescript-eslint/visitor-keys@8.35.1': + dependencies: + '@typescript-eslint/types': 8.35.1 + eslint-visitor-keys: 4.2.1 + '@ungap/structured-clone@1.3.0': {} '@unrs/resolver-binding-android-arm-eabi@1.9.0': @@ -10333,24 +10474,25 @@ snapshots: '@unrs/resolver-binding-win32-x64-msvc@1.9.0': optional: true - '@vitest/expect@3.0.9': + '@vitest/expect@3.2.4': dependencies: - '@vitest/spy': 3.0.9 - '@vitest/utils': 3.0.9 + '@types/chai': 5.2.2 + '@vitest/spy': 3.2.4 + '@vitest/utils': 3.2.4 chai: 5.2.0 tinyrainbow: 2.0.0 - '@vitest/pretty-format@3.0.9': + '@vitest/pretty-format@3.2.4': dependencies: tinyrainbow: 2.0.0 - '@vitest/spy@3.0.9': + '@vitest/spy@3.2.4': dependencies: - tinyspy: 3.0.2 + tinyspy: 4.0.3 - '@vitest/utils@3.0.9': + '@vitest/utils@3.2.4': dependencies: - '@vitest/pretty-format': 3.0.9 + '@vitest/pretty-format': 3.2.4 loupe: 3.1.4 tinyrainbow: 2.0.0 @@ -10675,34 +10817,34 @@ snapshots: axobject-query@4.1.0: {} - babel-loader@9.2.1(@babel/core@7.27.4)(webpack@5.99.9(esbuild@0.25.5)): + babel-loader@9.2.1(@babel/core@7.27.7)(webpack@5.99.9(esbuild@0.25.5)): dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 find-cache-dir: 4.0.0 schema-utils: 4.3.2 webpack: 5.99.9(esbuild@0.25.5) - babel-plugin-polyfill-corejs2@0.4.13(@babel/core@7.27.4): + babel-plugin-polyfill-corejs2@0.4.14(@babel/core@7.27.7): dependencies: - '@babel/compat-data': 7.27.5 - '@babel/core': 7.27.4 - '@babel/helper-define-polyfill-provider': 0.6.4(@babel/core@7.27.4) + '@babel/compat-data': 7.27.7 + '@babel/core': 7.27.7 + '@babel/helper-define-polyfill-provider': 0.6.5(@babel/core@7.27.7) semver: 6.3.1 transitivePeerDependencies: - supports-color - babel-plugin-polyfill-corejs3@0.11.1(@babel/core@7.27.4): + babel-plugin-polyfill-corejs3@0.11.1(@babel/core@7.27.7): dependencies: - '@babel/core': 7.27.4 - '@babel/helper-define-polyfill-provider': 0.6.4(@babel/core@7.27.4) + '@babel/core': 7.27.7 + '@babel/helper-define-polyfill-provider': 0.6.5(@babel/core@7.27.7) core-js-compat: 3.43.0 transitivePeerDependencies: - supports-color - babel-plugin-polyfill-regenerator@0.6.4(@babel/core@7.27.4): + babel-plugin-polyfill-regenerator@0.6.5(@babel/core@7.27.7): dependencies: - '@babel/core': 7.27.4 - '@babel/helper-define-polyfill-provider': 0.6.4(@babel/core@7.27.4) + '@babel/core': 7.27.7 + '@babel/helper-define-polyfill-provider': 0.6.5(@babel/core@7.27.7) transitivePeerDependencies: - supports-color @@ -10791,7 +10933,7 @@ snapshots: browserslist@4.25.1: dependencies: caniuse-lite: 1.0.30001726 - electron-to-chromium: 1.5.176 + electron-to-chromium: 1.5.177 node-releases: 2.0.19 update-browserslist-db: 1.1.3(browserslist@4.25.1) @@ -11053,6 +11195,25 @@ snapshots: safe-buffer: 5.2.1 sha.js: 2.4.11 + create-jest@29.7.0(@types/node@22.15.30): + dependencies: + '@jest/types': 29.6.3 + chalk: 4.1.2 + exit: 0.1.2 + graceful-fs: 4.2.11 + jest-config: 29.7.0(@types/node@22.15.30) + jest-util: 29.7.0 + prompts: 2.4.2 + transitivePeerDependencies: + - '@types/node' + - babel-plugin-macros + - supports-color + - ts-node + + cross-env@7.0.3: + dependencies: + cross-spawn: 7.0.6 + cross-spawn@7.0.6: dependencies: path-key: 3.1.1 @@ -11092,7 +11253,7 @@ snapshots: css-select@4.3.0: dependencies: boolbase: 1.0.0 - css-what: 6.1.0 + css-what: 6.2.2 domhandler: 4.3.1 domutils: 2.8.0 nth-check: 2.1.1 @@ -11103,7 +11264,7 @@ snapshots: css-color-keywords: 1.0.0 postcss-value-parser: 4.2.0 - css-what@6.1.0: {} + css-what@6.2.2: {} css.escape@1.5.1: {} @@ -11325,7 +11486,7 @@ snapshots: eastasianwidth@0.2.0: {} - electron-to-chromium@1.5.176: {} + electron-to-chromium@1.5.177: {} elliptic@6.6.1: dependencies: @@ -11668,11 +11829,11 @@ snapshots: string.prototype.matchall: 4.0.12 string.prototype.repeat: 1.0.0 - eslint-plugin-storybook@9.0.13(eslint@8.57.1)(storybook@9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1))(typescript@5.8.3): + eslint-plugin-storybook@9.0.14(eslint@8.57.1)(storybook@9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2))(typescript@5.8.3): dependencies: - '@typescript-eslint/utils': 8.35.0(eslint@8.57.1)(typescript@5.8.3) + '@typescript-eslint/utils': 8.35.1(eslint@8.57.1)(typescript@5.8.3) eslint: 8.57.1 - storybook: 9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1) + storybook: 9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2) transitivePeerDependencies: - supports-color - typescript @@ -11954,9 +12115,9 @@ snapshots: functions-have-names@1.2.3: {} - geist@1.4.2(next@15.3.3(@babel/core@7.27.4)(@opentelemetry/api@1.9.0)(@playwright/test@1.53.1)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)): + geist@1.4.2(next@15.3.3(@babel/core@7.27.7)(@opentelemetry/api@1.9.0)(@playwright/test@1.53.1)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)): dependencies: - next: 15.3.3(@babel/core@7.27.4)(@opentelemetry/api@1.9.0)(@playwright/test@1.53.1)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + next: 15.3.3(@babel/core@7.27.7)(@opentelemetry/api@1.9.0)(@playwright/test@1.53.1)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) gensync@1.0.0-beta.2: {} @@ -12591,11 +12752,11 @@ snapshots: magic-string@0.30.17: dependencies: - '@jridgewell/sourcemap-codec': 1.5.0 + '@jridgewell/sourcemap-codec': 1.5.2 magic-string@0.30.8: dependencies: - '@jridgewell/sourcemap-codec': 1.5.0 + '@jridgewell/sourcemap-codec': 1.5.2 make-dir@3.1.0: dependencies: @@ -12961,7 +13122,7 @@ snapshots: react: 18.3.1 react-dom: 18.3.1(react@18.3.1) - next@15.3.3(@babel/core@7.27.4)(@opentelemetry/api@1.9.0)(@playwright/test@1.53.1)(react-dom@18.3.1(react@18.3.1))(react@18.3.1): + next@15.3.3(@babel/core@7.27.7)(@opentelemetry/api@1.9.0)(@playwright/test@1.53.1)(react-dom@18.3.1(react@18.3.1))(react@18.3.1): dependencies: '@next/env': 15.3.3 '@swc/counter': 0.1.3 @@ -12971,7 +13132,7 @@ snapshots: postcss: 8.4.31 react: 18.3.1 react-dom: 18.3.1(react@18.3.1) - styled-jsx: 5.1.6(@babel/core@7.27.4)(react@18.3.1) + styled-jsx: 5.1.6(@babel/core@7.27.7)(react@18.3.1) optionalDependencies: '@next/swc-darwin-arm64': 15.3.3 '@next/swc-darwin-x64': 15.3.3 @@ -13460,11 +13621,11 @@ snapshots: prelude-ls@1.2.1: {} - prettier-plugin-tailwindcss@0.6.13(prettier@3.6.1): + prettier-plugin-tailwindcss@0.6.13(prettier@3.6.2): dependencies: - prettier: 3.6.1 + prettier: 3.6.2 - prettier@3.6.1: {} + prettier@3.6.2: {} pretty-error@4.0.0: dependencies: @@ -13546,9 +13707,9 @@ snapshots: react-docgen@7.1.1: dependencies: - '@babel/core': 7.27.4 - '@babel/traverse': 7.27.4 - '@babel/types': 7.27.6 + '@babel/core': 7.27.7 + '@babel/traverse': 7.27.7 + '@babel/types': 7.27.7 '@types/babel__core': 7.20.5 '@types/babel__traverse': 7.20.7 '@types/doctrine': 0.0.9 @@ -14129,21 +14290,21 @@ snapshots: es-errors: 1.3.0 internal-slot: 1.1.0 - storybook@9.0.13(@testing-library/dom@10.4.0)(prettier@3.6.1): + storybook@9.0.14(@testing-library/dom@10.4.0)(prettier@3.6.2): dependencies: '@storybook/global': 5.0.0 '@testing-library/jest-dom': 6.6.3 '@testing-library/user-event': 14.6.1(@testing-library/dom@10.4.0) - '@vitest/expect': 3.0.9 - '@vitest/spy': 3.0.9 + '@vitest/expect': 3.2.4 + '@vitest/spy': 3.2.4 better-opn: 3.0.2 esbuild: 0.25.5 esbuild-register: 3.6.0(esbuild@0.25.5) recast: 0.23.11 semver: 7.7.2 - ws: 8.18.2 + ws: 8.18.3 optionalDependencies: - prettier: 3.6.1 + prettier: 3.6.2 transitivePeerDependencies: - '@testing-library/dom' - bufferutil @@ -14291,19 +14452,19 @@ snapshots: stylis: 4.3.2 tslib: 2.6.2 - styled-jsx@5.1.6(@babel/core@7.27.4)(react@18.3.1): + styled-jsx@5.1.6(@babel/core@7.27.7)(react@18.3.1): dependencies: client-only: 0.0.1 react: 18.3.1 optionalDependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 - styled-jsx@5.1.7(@babel/core@7.27.4)(react@18.3.1): + styled-jsx@5.1.7(@babel/core@7.27.7)(react@18.3.1): dependencies: client-only: 0.0.1 react: 18.3.1 optionalDependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 stylis@4.3.2: {} @@ -14380,7 +14541,7 @@ snapshots: terser-webpack-plugin@5.3.14(esbuild@0.25.5)(webpack@5.99.9(esbuild@0.25.5)): dependencies: - '@jridgewell/trace-mapping': 0.3.25 + '@jridgewell/trace-mapping': 0.3.27 jest-worker: 27.5.1 schema-utils: 4.3.2 serialize-javascript: 6.0.2 @@ -14391,7 +14552,7 @@ snapshots: terser@5.43.1: dependencies: - '@jridgewell/source-map': 0.3.6 + '@jridgewell/source-map': 0.3.8 acorn: 8.15.0 commander: 2.20.3 source-map-support: 0.5.21 @@ -14421,7 +14582,7 @@ snapshots: tinyrainbow@2.0.0: {} - tinyspy@3.0.2: {} + tinyspy@4.0.3: {} to-buffer@1.2.1: dependencies: @@ -14886,7 +15047,7 @@ snapshots: wrappy@1.0.2: {} - ws@8.18.2: {} + ws@8.18.3: {} xmlbuilder@15.1.1: {} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/endpoints/admin/admin.ts b/autogpt_platform/frontend/src/app/api/__generated__/endpoints/admin/admin.ts new file mode 100644 index 0000000000..adf5fa49d5 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/endpoints/admin/admin.ts @@ -0,0 +1,931 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import { useMutation, useQuery } from "@tanstack/react-query"; +import type { + DataTag, + DefinedInitialDataOptions, + DefinedUseQueryResult, + MutationFunction, + QueryClient, + QueryFunction, + QueryKey, + UndefinedInitialDataOptions, + UseMutationOptions, + UseMutationResult, + UseQueryOptions, + UseQueryResult, +} from "@tanstack/react-query"; + +import type { AddUserCreditsResponse } from "../../models/addUserCreditsResponse"; + +import type { BodyPostV2AddCreditsToUser } from "../../models/bodyPostV2AddCreditsToUser"; + +import type { GetV2GetAdminListingsHistoryParams } from "../../models/getV2GetAdminListingsHistoryParams"; + +import type { GetV2GetAllUsersHistoryParams } from "../../models/getV2GetAllUsersHistoryParams"; + +import type { HTTPValidationError } from "../../models/hTTPValidationError"; + +import type { ReviewSubmissionRequest } from "../../models/reviewSubmissionRequest"; + +import type { StoreListingsWithVersionsResponse } from "../../models/storeListingsWithVersionsResponse"; + +import type { StoreSubmission } from "../../models/storeSubmission"; + +import type { UserHistoryResponse } from "../../models/userHistoryResponse"; + +import { customMutator } from "../../../mutators/custom-mutator"; + +type SecondParameter unknown> = Parameters[1]; + +/** + * Get store listings with their version history for admins. + +This provides a consolidated view of listings with their versions, +allowing for an expandable UI in the admin dashboard. + +Args: + status: Filter by submission status (PENDING, APPROVED, REJECTED) + search: Search by name, description, or user email + page: Page number for pagination + page_size: Number of items per page + +Returns: + StoreListingsWithVersionsResponse with listings and their versions + * @summary Get Admin Listings History + */ +export type getV2GetAdminListingsHistoryResponse200 = { + data: StoreListingsWithVersionsResponse; + status: 200; +}; + +export type getV2GetAdminListingsHistoryResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type getV2GetAdminListingsHistoryResponseComposite = + | getV2GetAdminListingsHistoryResponse200 + | getV2GetAdminListingsHistoryResponse422; + +export type getV2GetAdminListingsHistoryResponse = + getV2GetAdminListingsHistoryResponseComposite & { + headers: Headers; + }; + +export const getGetV2GetAdminListingsHistoryUrl = ( + params?: GetV2GetAdminListingsHistoryParams, +) => { + const normalizedParams = new URLSearchParams(); + + Object.entries(params || {}).forEach(([key, value]) => { + if (value !== undefined) { + normalizedParams.append(key, value === null ? "null" : value.toString()); + } + }); + + const stringifiedParams = normalizedParams.toString(); + + return stringifiedParams.length > 0 + ? `/api/store/admin/listings?${stringifiedParams}` + : `/api/store/admin/listings`; +}; + +export const getV2GetAdminListingsHistory = async ( + params?: GetV2GetAdminListingsHistoryParams, + options?: RequestInit, +): Promise => { + return customMutator( + getGetV2GetAdminListingsHistoryUrl(params), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV2GetAdminListingsHistoryQueryKey = ( + params?: GetV2GetAdminListingsHistoryParams, +) => { + return [`/api/store/admin/listings`, ...(params ? [params] : [])] as const; +}; + +export const getGetV2GetAdminListingsHistoryQueryOptions = < + TData = Awaited>, + TError = HTTPValidationError, +>( + params?: GetV2GetAdminListingsHistoryParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, +) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = + queryOptions?.queryKey ?? getGetV2GetAdminListingsHistoryQueryKey(params); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => + getV2GetAdminListingsHistory(params, { signal, ...requestOptions }); + + return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV2GetAdminListingsHistoryQueryResult = NonNullable< + Awaited> +>; +export type GetV2GetAdminListingsHistoryQueryError = HTTPValidationError; + +export function useGetV2GetAdminListingsHistory< + TData = Awaited>, + TError = HTTPValidationError, +>( + params: undefined | GetV2GetAdminListingsHistoryParams, + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV2GetAdminListingsHistory< + TData = Awaited>, + TError = HTTPValidationError, +>( + params?: GetV2GetAdminListingsHistoryParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV2GetAdminListingsHistory< + TData = Awaited>, + TError = HTTPValidationError, +>( + params?: GetV2GetAdminListingsHistoryParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary Get Admin Listings History + */ + +export function useGetV2GetAdminListingsHistory< + TData = Awaited>, + TError = HTTPValidationError, +>( + params?: GetV2GetAdminListingsHistoryParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV2GetAdminListingsHistoryQueryOptions( + params, + options, + ); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * Review a store listing submission. + +Args: + store_listing_version_id: ID of the submission to review + request: Review details including approval status and comments + user: Authenticated admin user performing the review + +Returns: + StoreSubmission with updated review information + * @summary Review Store Submission + */ +export type postV2ReviewStoreSubmissionResponse200 = { + data: StoreSubmission; + status: 200; +}; + +export type postV2ReviewStoreSubmissionResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type postV2ReviewStoreSubmissionResponseComposite = + | postV2ReviewStoreSubmissionResponse200 + | postV2ReviewStoreSubmissionResponse422; + +export type postV2ReviewStoreSubmissionResponse = + postV2ReviewStoreSubmissionResponseComposite & { + headers: Headers; + }; + +export const getPostV2ReviewStoreSubmissionUrl = ( + storeListingVersionId: string, +) => { + return `/api/store/admin/submissions/${storeListingVersionId}/review`; +}; + +export const postV2ReviewStoreSubmission = async ( + storeListingVersionId: string, + reviewSubmissionRequest: ReviewSubmissionRequest, + options?: RequestInit, +): Promise => { + return customMutator( + getPostV2ReviewStoreSubmissionUrl(storeListingVersionId), + { + ...options, + method: "POST", + headers: { "Content-Type": "application/json", ...options?.headers }, + body: JSON.stringify(reviewSubmissionRequest), + }, + ); +}; + +export const getPostV2ReviewStoreSubmissionMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { storeListingVersionId: string; data: ReviewSubmissionRequest }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { storeListingVersionId: string; data: ReviewSubmissionRequest }, + TContext +> => { + const mutationKey = ["postV2ReviewStoreSubmission"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { storeListingVersionId: string; data: ReviewSubmissionRequest } + > = (props) => { + const { storeListingVersionId, data } = props ?? {}; + + return postV2ReviewStoreSubmission( + storeListingVersionId, + data, + requestOptions, + ); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PostV2ReviewStoreSubmissionMutationResult = NonNullable< + Awaited> +>; +export type PostV2ReviewStoreSubmissionMutationBody = ReviewSubmissionRequest; +export type PostV2ReviewStoreSubmissionMutationError = HTTPValidationError; + +/** + * @summary Review Store Submission + */ +export const usePostV2ReviewStoreSubmission = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { storeListingVersionId: string; data: ReviewSubmissionRequest }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { storeListingVersionId: string; data: ReviewSubmissionRequest }, + TContext +> => { + const mutationOptions = + getPostV2ReviewStoreSubmissionMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * Download the agent file by streaming its content. + +Args: + store_listing_version_id (str): The ID of the agent to download + +Returns: + StreamingResponse: A streaming response containing the agent's graph data. + +Raises: + HTTPException: If the agent is not found or an unexpected error occurs. + * @summary Admin Download Agent File + */ +export type getV2AdminDownloadAgentFileResponse200 = { + data: unknown; + status: 200; +}; + +export type getV2AdminDownloadAgentFileResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type getV2AdminDownloadAgentFileResponseComposite = + | getV2AdminDownloadAgentFileResponse200 + | getV2AdminDownloadAgentFileResponse422; + +export type getV2AdminDownloadAgentFileResponse = + getV2AdminDownloadAgentFileResponseComposite & { + headers: Headers; + }; + +export const getGetV2AdminDownloadAgentFileUrl = ( + storeListingVersionId: string, +) => { + return `/api/store/admin/submissions/download/${storeListingVersionId}`; +}; + +export const getV2AdminDownloadAgentFile = async ( + storeListingVersionId: string, + options?: RequestInit, +): Promise => { + return customMutator( + getGetV2AdminDownloadAgentFileUrl(storeListingVersionId), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV2AdminDownloadAgentFileQueryKey = ( + storeListingVersionId: string, +) => { + return [ + `/api/store/admin/submissions/download/${storeListingVersionId}`, + ] as const; +}; + +export const getGetV2AdminDownloadAgentFileQueryOptions = < + TData = Awaited>, + TError = HTTPValidationError, +>( + storeListingVersionId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, +) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = + queryOptions?.queryKey ?? + getGetV2AdminDownloadAgentFileQueryKey(storeListingVersionId); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => + getV2AdminDownloadAgentFile(storeListingVersionId, { + signal, + ...requestOptions, + }); + + return { + queryKey, + queryFn, + enabled: !!storeListingVersionId, + ...queryOptions, + } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV2AdminDownloadAgentFileQueryResult = NonNullable< + Awaited> +>; +export type GetV2AdminDownloadAgentFileQueryError = HTTPValidationError; + +export function useGetV2AdminDownloadAgentFile< + TData = Awaited>, + TError = HTTPValidationError, +>( + storeListingVersionId: string, + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV2AdminDownloadAgentFile< + TData = Awaited>, + TError = HTTPValidationError, +>( + storeListingVersionId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV2AdminDownloadAgentFile< + TData = Awaited>, + TError = HTTPValidationError, +>( + storeListingVersionId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary Admin Download Agent File + */ + +export function useGetV2AdminDownloadAgentFile< + TData = Awaited>, + TError = HTTPValidationError, +>( + storeListingVersionId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV2AdminDownloadAgentFileQueryOptions( + storeListingVersionId, + options, + ); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * @summary Add Credits to User + */ +export type postV2AddCreditsToUserResponse200 = { + data: AddUserCreditsResponse; + status: 200; +}; + +export type postV2AddCreditsToUserResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type postV2AddCreditsToUserResponseComposite = + | postV2AddCreditsToUserResponse200 + | postV2AddCreditsToUserResponse422; + +export type postV2AddCreditsToUserResponse = + postV2AddCreditsToUserResponseComposite & { + headers: Headers; + }; + +export const getPostV2AddCreditsToUserUrl = () => { + return `/api/credits/admin/add_credits`; +}; + +export const postV2AddCreditsToUser = async ( + bodyPostV2AddCreditsToUser: BodyPostV2AddCreditsToUser, + options?: RequestInit, +): Promise => { + return customMutator( + getPostV2AddCreditsToUserUrl(), + { + ...options, + method: "POST", + headers: { "Content-Type": "application/json", ...options?.headers }, + body: JSON.stringify(bodyPostV2AddCreditsToUser), + }, + ); +}; + +export const getPostV2AddCreditsToUserMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { data: BodyPostV2AddCreditsToUser }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { data: BodyPostV2AddCreditsToUser }, + TContext +> => { + const mutationKey = ["postV2AddCreditsToUser"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { data: BodyPostV2AddCreditsToUser } + > = (props) => { + const { data } = props ?? {}; + + return postV2AddCreditsToUser(data, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PostV2AddCreditsToUserMutationResult = NonNullable< + Awaited> +>; +export type PostV2AddCreditsToUserMutationBody = BodyPostV2AddCreditsToUser; +export type PostV2AddCreditsToUserMutationError = HTTPValidationError; + +/** + * @summary Add Credits to User + */ +export const usePostV2AddCreditsToUser = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { data: BodyPostV2AddCreditsToUser }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { data: BodyPostV2AddCreditsToUser }, + TContext +> => { + const mutationOptions = getPostV2AddCreditsToUserMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * @summary Get All Users History + */ +export type getV2GetAllUsersHistoryResponse200 = { + data: UserHistoryResponse; + status: 200; +}; + +export type getV2GetAllUsersHistoryResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type getV2GetAllUsersHistoryResponseComposite = + | getV2GetAllUsersHistoryResponse200 + | getV2GetAllUsersHistoryResponse422; + +export type getV2GetAllUsersHistoryResponse = + getV2GetAllUsersHistoryResponseComposite & { + headers: Headers; + }; + +export const getGetV2GetAllUsersHistoryUrl = ( + params?: GetV2GetAllUsersHistoryParams, +) => { + const normalizedParams = new URLSearchParams(); + + Object.entries(params || {}).forEach(([key, value]) => { + if (value !== undefined) { + normalizedParams.append(key, value === null ? "null" : value.toString()); + } + }); + + const stringifiedParams = normalizedParams.toString(); + + return stringifiedParams.length > 0 + ? `/api/credits/admin/users_history?${stringifiedParams}` + : `/api/credits/admin/users_history`; +}; + +export const getV2GetAllUsersHistory = async ( + params?: GetV2GetAllUsersHistoryParams, + options?: RequestInit, +): Promise => { + return customMutator( + getGetV2GetAllUsersHistoryUrl(params), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV2GetAllUsersHistoryQueryKey = ( + params?: GetV2GetAllUsersHistoryParams, +) => { + return [ + `/api/credits/admin/users_history`, + ...(params ? [params] : []), + ] as const; +}; + +export const getGetV2GetAllUsersHistoryQueryOptions = < + TData = Awaited>, + TError = HTTPValidationError, +>( + params?: GetV2GetAllUsersHistoryParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, +) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = + queryOptions?.queryKey ?? getGetV2GetAllUsersHistoryQueryKey(params); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => + getV2GetAllUsersHistory(params, { signal, ...requestOptions }); + + return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV2GetAllUsersHistoryQueryResult = NonNullable< + Awaited> +>; +export type GetV2GetAllUsersHistoryQueryError = HTTPValidationError; + +export function useGetV2GetAllUsersHistory< + TData = Awaited>, + TError = HTTPValidationError, +>( + params: undefined | GetV2GetAllUsersHistoryParams, + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV2GetAllUsersHistory< + TData = Awaited>, + TError = HTTPValidationError, +>( + params?: GetV2GetAllUsersHistoryParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV2GetAllUsersHistory< + TData = Awaited>, + TError = HTTPValidationError, +>( + params?: GetV2GetAllUsersHistoryParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary Get All Users History + */ + +export function useGetV2GetAllUsersHistory< + TData = Awaited>, + TError = HTTPValidationError, +>( + params?: GetV2GetAllUsersHistoryParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV2GetAllUsersHistoryQueryOptions(params, options); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/endpoints/analytics/analytics.ts b/autogpt_platform/frontend/src/app/api/__generated__/endpoints/analytics/analytics.ts new file mode 100644 index 0000000000..a297a7b0b7 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/endpoints/analytics/analytics.ts @@ -0,0 +1,245 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import { useMutation } from "@tanstack/react-query"; +import type { + MutationFunction, + QueryClient, + UseMutationOptions, + UseMutationResult, +} from "@tanstack/react-query"; + +import type { BodyPostV1LogRawAnalytics } from "../../models/bodyPostV1LogRawAnalytics"; + +import type { HTTPValidationError } from "../../models/hTTPValidationError"; + +import type { LogRawMetricRequest } from "../../models/logRawMetricRequest"; + +import { customMutator } from "../../../mutators/custom-mutator"; + +type SecondParameter unknown> = Parameters[1]; + +/** + * @summary Log Raw Metric + */ +export type postV1LogRawMetricResponse200 = { + data: unknown; + status: 200; +}; + +export type postV1LogRawMetricResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type postV1LogRawMetricResponseComposite = + | postV1LogRawMetricResponse200 + | postV1LogRawMetricResponse422; + +export type postV1LogRawMetricResponse = postV1LogRawMetricResponseComposite & { + headers: Headers; +}; + +export const getPostV1LogRawMetricUrl = () => { + return `/api/analytics/log_raw_metric`; +}; + +export const postV1LogRawMetric = async ( + logRawMetricRequest: LogRawMetricRequest, + options?: RequestInit, +): Promise => { + return customMutator(getPostV1LogRawMetricUrl(), { + ...options, + method: "POST", + headers: { "Content-Type": "application/json", ...options?.headers }, + body: JSON.stringify(logRawMetricRequest), + }); +}; + +export const getPostV1LogRawMetricMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { data: LogRawMetricRequest }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { data: LogRawMetricRequest }, + TContext +> => { + const mutationKey = ["postV1LogRawMetric"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { data: LogRawMetricRequest } + > = (props) => { + const { data } = props ?? {}; + + return postV1LogRawMetric(data, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PostV1LogRawMetricMutationResult = NonNullable< + Awaited> +>; +export type PostV1LogRawMetricMutationBody = LogRawMetricRequest; +export type PostV1LogRawMetricMutationError = HTTPValidationError; + +/** + * @summary Log Raw Metric + */ +export const usePostV1LogRawMetric = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { data: LogRawMetricRequest }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { data: LogRawMetricRequest }, + TContext +> => { + const mutationOptions = getPostV1LogRawMetricMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * @summary Log Raw Analytics + */ +export type postV1LogRawAnalyticsResponse200 = { + data: unknown; + status: 200; +}; + +export type postV1LogRawAnalyticsResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type postV1LogRawAnalyticsResponseComposite = + | postV1LogRawAnalyticsResponse200 + | postV1LogRawAnalyticsResponse422; + +export type postV1LogRawAnalyticsResponse = + postV1LogRawAnalyticsResponseComposite & { + headers: Headers; + }; + +export const getPostV1LogRawAnalyticsUrl = () => { + return `/api/analytics/log_raw_analytics`; +}; + +export const postV1LogRawAnalytics = async ( + bodyPostV1LogRawAnalytics: BodyPostV1LogRawAnalytics, + options?: RequestInit, +): Promise => { + return customMutator( + getPostV1LogRawAnalyticsUrl(), + { + ...options, + method: "POST", + headers: { "Content-Type": "application/json", ...options?.headers }, + body: JSON.stringify(bodyPostV1LogRawAnalytics), + }, + ); +}; + +export const getPostV1LogRawAnalyticsMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { data: BodyPostV1LogRawAnalytics }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { data: BodyPostV1LogRawAnalytics }, + TContext +> => { + const mutationKey = ["postV1LogRawAnalytics"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { data: BodyPostV1LogRawAnalytics } + > = (props) => { + const { data } = props ?? {}; + + return postV1LogRawAnalytics(data, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PostV1LogRawAnalyticsMutationResult = NonNullable< + Awaited> +>; +export type PostV1LogRawAnalyticsMutationBody = BodyPostV1LogRawAnalytics; +export type PostV1LogRawAnalyticsMutationError = HTTPValidationError; + +/** + * @summary Log Raw Analytics + */ +export const usePostV1LogRawAnalytics = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { data: BodyPostV1LogRawAnalytics }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { data: BodyPostV1LogRawAnalytics }, + TContext +> => { + const mutationOptions = getPostV1LogRawAnalyticsMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/endpoints/api-keys/api-keys.ts b/autogpt_platform/frontend/src/app/api/__generated__/endpoints/api-keys/api-keys.ts new file mode 100644 index 0000000000..9547793c15 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/endpoints/api-keys/api-keys.ts @@ -0,0 +1,857 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import { useMutation, useQuery } from "@tanstack/react-query"; +import type { + DataTag, + DefinedInitialDataOptions, + DefinedUseQueryResult, + MutationFunction, + QueryClient, + QueryFunction, + QueryKey, + UndefinedInitialDataOptions, + UseMutationOptions, + UseMutationResult, + UseQueryOptions, + UseQueryResult, +} from "@tanstack/react-query"; + +import type { APIKeyWithoutHash } from "../../models/aPIKeyWithoutHash"; + +import type { CreateAPIKeyRequest } from "../../models/createAPIKeyRequest"; + +import type { CreateAPIKeyResponse } from "../../models/createAPIKeyResponse"; + +import type { GetV1ListUserApiKeys200 } from "../../models/getV1ListUserApiKeys200"; + +import type { HTTPValidationError } from "../../models/hTTPValidationError"; + +import type { UpdatePermissionsRequest } from "../../models/updatePermissionsRequest"; + +import { customMutator } from "../../../mutators/custom-mutator"; + +type SecondParameter unknown> = Parameters[1]; + +/** + * List all API keys for the user + * @summary List user API keys + */ +export type getV1ListUserApiKeysResponse200 = { + data: GetV1ListUserApiKeys200; + status: 200; +}; + +export type getV1ListUserApiKeysResponseComposite = + getV1ListUserApiKeysResponse200; + +export type getV1ListUserApiKeysResponse = + getV1ListUserApiKeysResponseComposite & { + headers: Headers; + }; + +export const getGetV1ListUserApiKeysUrl = () => { + return `/api/api-keys`; +}; + +export const getV1ListUserApiKeys = async ( + options?: RequestInit, +): Promise => { + return customMutator( + getGetV1ListUserApiKeysUrl(), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV1ListUserApiKeysQueryKey = () => { + return [`/api/api-keys`] as const; +}; + +export const getGetV1ListUserApiKeysQueryOptions = < + TData = Awaited>, + TError = unknown, +>(options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; +}) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = queryOptions?.queryKey ?? getGetV1ListUserApiKeysQueryKey(); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => getV1ListUserApiKeys({ signal, ...requestOptions }); + + return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV1ListUserApiKeysQueryResult = NonNullable< + Awaited> +>; +export type GetV1ListUserApiKeysQueryError = unknown; + +export function useGetV1ListUserApiKeys< + TData = Awaited>, + TError = unknown, +>( + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1ListUserApiKeys< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1ListUserApiKeys< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary List user API keys + */ + +export function useGetV1ListUserApiKeys< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV1ListUserApiKeysQueryOptions(options); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * Create a new API key + * @summary Create new API key + */ +export type postV1CreateNewApiKeyResponse200 = { + data: CreateAPIKeyResponse; + status: 200; +}; + +export type postV1CreateNewApiKeyResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type postV1CreateNewApiKeyResponseComposite = + | postV1CreateNewApiKeyResponse200 + | postV1CreateNewApiKeyResponse422; + +export type postV1CreateNewApiKeyResponse = + postV1CreateNewApiKeyResponseComposite & { + headers: Headers; + }; + +export const getPostV1CreateNewApiKeyUrl = () => { + return `/api/api-keys`; +}; + +export const postV1CreateNewApiKey = async ( + createAPIKeyRequest: CreateAPIKeyRequest, + options?: RequestInit, +): Promise => { + return customMutator( + getPostV1CreateNewApiKeyUrl(), + { + ...options, + method: "POST", + headers: { "Content-Type": "application/json", ...options?.headers }, + body: JSON.stringify(createAPIKeyRequest), + }, + ); +}; + +export const getPostV1CreateNewApiKeyMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { data: CreateAPIKeyRequest }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { data: CreateAPIKeyRequest }, + TContext +> => { + const mutationKey = ["postV1CreateNewApiKey"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { data: CreateAPIKeyRequest } + > = (props) => { + const { data } = props ?? {}; + + return postV1CreateNewApiKey(data, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PostV1CreateNewApiKeyMutationResult = NonNullable< + Awaited> +>; +export type PostV1CreateNewApiKeyMutationBody = CreateAPIKeyRequest; +export type PostV1CreateNewApiKeyMutationError = HTTPValidationError; + +/** + * @summary Create new API key + */ +export const usePostV1CreateNewApiKey = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { data: CreateAPIKeyRequest }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { data: CreateAPIKeyRequest }, + TContext +> => { + const mutationOptions = getPostV1CreateNewApiKeyMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * Get a specific API key + * @summary Get specific API key + */ +export type getV1GetSpecificApiKeyResponse200 = { + data: APIKeyWithoutHash; + status: 200; +}; + +export type getV1GetSpecificApiKeyResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type getV1GetSpecificApiKeyResponseComposite = + | getV1GetSpecificApiKeyResponse200 + | getV1GetSpecificApiKeyResponse422; + +export type getV1GetSpecificApiKeyResponse = + getV1GetSpecificApiKeyResponseComposite & { + headers: Headers; + }; + +export const getGetV1GetSpecificApiKeyUrl = (keyId: string) => { + return `/api/api-keys/${keyId}`; +}; + +export const getV1GetSpecificApiKey = async ( + keyId: string, + options?: RequestInit, +): Promise => { + return customMutator( + getGetV1GetSpecificApiKeyUrl(keyId), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV1GetSpecificApiKeyQueryKey = (keyId: string) => { + return [`/api/api-keys/${keyId}`] as const; +}; + +export const getGetV1GetSpecificApiKeyQueryOptions = < + TData = Awaited>, + TError = HTTPValidationError, +>( + keyId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, +) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = + queryOptions?.queryKey ?? getGetV1GetSpecificApiKeyQueryKey(keyId); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => + getV1GetSpecificApiKey(keyId, { signal, ...requestOptions }); + + return { + queryKey, + queryFn, + enabled: !!keyId, + ...queryOptions, + } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV1GetSpecificApiKeyQueryResult = NonNullable< + Awaited> +>; +export type GetV1GetSpecificApiKeyQueryError = HTTPValidationError; + +export function useGetV1GetSpecificApiKey< + TData = Awaited>, + TError = HTTPValidationError, +>( + keyId: string, + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1GetSpecificApiKey< + TData = Awaited>, + TError = HTTPValidationError, +>( + keyId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1GetSpecificApiKey< + TData = Awaited>, + TError = HTTPValidationError, +>( + keyId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary Get specific API key + */ + +export function useGetV1GetSpecificApiKey< + TData = Awaited>, + TError = HTTPValidationError, +>( + keyId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV1GetSpecificApiKeyQueryOptions(keyId, options); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * Revoke an API key + * @summary Revoke API key + */ +export type deleteV1RevokeApiKeyResponse200 = { + data: APIKeyWithoutHash; + status: 200; +}; + +export type deleteV1RevokeApiKeyResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type deleteV1RevokeApiKeyResponseComposite = + | deleteV1RevokeApiKeyResponse200 + | deleteV1RevokeApiKeyResponse422; + +export type deleteV1RevokeApiKeyResponse = + deleteV1RevokeApiKeyResponseComposite & { + headers: Headers; + }; + +export const getDeleteV1RevokeApiKeyUrl = (keyId: string) => { + return `/api/api-keys/${keyId}`; +}; + +export const deleteV1RevokeApiKey = async ( + keyId: string, + options?: RequestInit, +): Promise => { + return customMutator( + getDeleteV1RevokeApiKeyUrl(keyId), + { + ...options, + method: "DELETE", + }, + ); +}; + +export const getDeleteV1RevokeApiKeyMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { keyId: string }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { keyId: string }, + TContext +> => { + const mutationKey = ["deleteV1RevokeApiKey"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { keyId: string } + > = (props) => { + const { keyId } = props ?? {}; + + return deleteV1RevokeApiKey(keyId, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type DeleteV1RevokeApiKeyMutationResult = NonNullable< + Awaited> +>; + +export type DeleteV1RevokeApiKeyMutationError = HTTPValidationError; + +/** + * @summary Revoke API key + */ +export const useDeleteV1RevokeApiKey = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { keyId: string }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { keyId: string }, + TContext +> => { + const mutationOptions = getDeleteV1RevokeApiKeyMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * Suspend an API key + * @summary Suspend API key + */ +export type postV1SuspendApiKeyResponse200 = { + data: APIKeyWithoutHash; + status: 200; +}; + +export type postV1SuspendApiKeyResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type postV1SuspendApiKeyResponseComposite = + | postV1SuspendApiKeyResponse200 + | postV1SuspendApiKeyResponse422; + +export type postV1SuspendApiKeyResponse = + postV1SuspendApiKeyResponseComposite & { + headers: Headers; + }; + +export const getPostV1SuspendApiKeyUrl = (keyId: string) => { + return `/api/api-keys/${keyId}/suspend`; +}; + +export const postV1SuspendApiKey = async ( + keyId: string, + options?: RequestInit, +): Promise => { + return customMutator( + getPostV1SuspendApiKeyUrl(keyId), + { + ...options, + method: "POST", + }, + ); +}; + +export const getPostV1SuspendApiKeyMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { keyId: string }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { keyId: string }, + TContext +> => { + const mutationKey = ["postV1SuspendApiKey"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { keyId: string } + > = (props) => { + const { keyId } = props ?? {}; + + return postV1SuspendApiKey(keyId, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PostV1SuspendApiKeyMutationResult = NonNullable< + Awaited> +>; + +export type PostV1SuspendApiKeyMutationError = HTTPValidationError; + +/** + * @summary Suspend API key + */ +export const usePostV1SuspendApiKey = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { keyId: string }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { keyId: string }, + TContext +> => { + const mutationOptions = getPostV1SuspendApiKeyMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * Update API key permissions + * @summary Update key permissions + */ +export type putV1UpdateKeyPermissionsResponse200 = { + data: APIKeyWithoutHash; + status: 200; +}; + +export type putV1UpdateKeyPermissionsResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type putV1UpdateKeyPermissionsResponseComposite = + | putV1UpdateKeyPermissionsResponse200 + | putV1UpdateKeyPermissionsResponse422; + +export type putV1UpdateKeyPermissionsResponse = + putV1UpdateKeyPermissionsResponseComposite & { + headers: Headers; + }; + +export const getPutV1UpdateKeyPermissionsUrl = (keyId: string) => { + return `/api/api-keys/${keyId}/permissions`; +}; + +export const putV1UpdateKeyPermissions = async ( + keyId: string, + updatePermissionsRequest: UpdatePermissionsRequest, + options?: RequestInit, +): Promise => { + return customMutator( + getPutV1UpdateKeyPermissionsUrl(keyId), + { + ...options, + method: "PUT", + headers: { "Content-Type": "application/json", ...options?.headers }, + body: JSON.stringify(updatePermissionsRequest), + }, + ); +}; + +export const getPutV1UpdateKeyPermissionsMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { keyId: string; data: UpdatePermissionsRequest }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { keyId: string; data: UpdatePermissionsRequest }, + TContext +> => { + const mutationKey = ["putV1UpdateKeyPermissions"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { keyId: string; data: UpdatePermissionsRequest } + > = (props) => { + const { keyId, data } = props ?? {}; + + return putV1UpdateKeyPermissions(keyId, data, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PutV1UpdateKeyPermissionsMutationResult = NonNullable< + Awaited> +>; +export type PutV1UpdateKeyPermissionsMutationBody = UpdatePermissionsRequest; +export type PutV1UpdateKeyPermissionsMutationError = HTTPValidationError; + +/** + * @summary Update key permissions + */ +export const usePutV1UpdateKeyPermissions = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { keyId: string; data: UpdatePermissionsRequest }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { keyId: string; data: UpdatePermissionsRequest }, + TContext +> => { + const mutationOptions = getPutV1UpdateKeyPermissionsMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/endpoints/auth/auth.ts b/autogpt_platform/frontend/src/app/api/__generated__/endpoints/auth/auth.ts new file mode 100644 index 0000000000..711bfb2cd2 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/endpoints/auth/auth.ts @@ -0,0 +1,535 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import { useMutation, useQuery } from "@tanstack/react-query"; +import type { + DataTag, + DefinedInitialDataOptions, + DefinedUseQueryResult, + MutationFunction, + QueryClient, + QueryFunction, + QueryKey, + UndefinedInitialDataOptions, + UseMutationOptions, + UseMutationResult, + UseQueryOptions, + UseQueryResult, +} from "@tanstack/react-query"; + +import type { HTTPValidationError } from "../../models/hTTPValidationError"; + +import type { NotificationPreference } from "../../models/notificationPreference"; + +import type { NotificationPreferenceDTO } from "../../models/notificationPreferenceDTO"; + +import type { PostV1UpdateUserEmail200 } from "../../models/postV1UpdateUserEmail200"; + +import { customMutator } from "../../../mutators/custom-mutator"; + +type SecondParameter unknown> = Parameters[1]; + +/** + * @summary Get or create user + */ +export type postV1GetOrCreateUserResponse200 = { + data: unknown; + status: 200; +}; + +export type postV1GetOrCreateUserResponseComposite = + postV1GetOrCreateUserResponse200; + +export type postV1GetOrCreateUserResponse = + postV1GetOrCreateUserResponseComposite & { + headers: Headers; + }; + +export const getPostV1GetOrCreateUserUrl = () => { + return `/api/auth/user`; +}; + +export const postV1GetOrCreateUser = async ( + options?: RequestInit, +): Promise => { + return customMutator( + getPostV1GetOrCreateUserUrl(), + { + ...options, + method: "POST", + }, + ); +}; + +export const getPostV1GetOrCreateUserMutationOptions = < + TError = unknown, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + void, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + void, + TContext +> => { + const mutationKey = ["postV1GetOrCreateUser"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + void + > = () => { + return postV1GetOrCreateUser(requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PostV1GetOrCreateUserMutationResult = NonNullable< + Awaited> +>; + +export type PostV1GetOrCreateUserMutationError = unknown; + +/** + * @summary Get or create user + */ +export const usePostV1GetOrCreateUser = ( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + void, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + void, + TContext +> => { + const mutationOptions = getPostV1GetOrCreateUserMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * @summary Update user email + */ +export type postV1UpdateUserEmailResponse200 = { + data: PostV1UpdateUserEmail200; + status: 200; +}; + +export type postV1UpdateUserEmailResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type postV1UpdateUserEmailResponseComposite = + | postV1UpdateUserEmailResponse200 + | postV1UpdateUserEmailResponse422; + +export type postV1UpdateUserEmailResponse = + postV1UpdateUserEmailResponseComposite & { + headers: Headers; + }; + +export const getPostV1UpdateUserEmailUrl = () => { + return `/api/auth/user/email`; +}; + +export const postV1UpdateUserEmail = async ( + postV1UpdateUserEmailBody: string, + options?: RequestInit, +): Promise => { + return customMutator( + getPostV1UpdateUserEmailUrl(), + { + ...options, + method: "POST", + headers: { "Content-Type": "application/json", ...options?.headers }, + body: JSON.stringify(postV1UpdateUserEmailBody), + }, + ); +}; + +export const getPostV1UpdateUserEmailMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { data: string }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { data: string }, + TContext +> => { + const mutationKey = ["postV1UpdateUserEmail"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { data: string } + > = (props) => { + const { data } = props ?? {}; + + return postV1UpdateUserEmail(data, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PostV1UpdateUserEmailMutationResult = NonNullable< + Awaited> +>; +export type PostV1UpdateUserEmailMutationBody = string; +export type PostV1UpdateUserEmailMutationError = HTTPValidationError; + +/** + * @summary Update user email + */ +export const usePostV1UpdateUserEmail = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { data: string }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { data: string }, + TContext +> => { + const mutationOptions = getPostV1UpdateUserEmailMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * @summary Get notification preferences + */ +export type getV1GetNotificationPreferencesResponse200 = { + data: NotificationPreference; + status: 200; +}; + +export type getV1GetNotificationPreferencesResponseComposite = + getV1GetNotificationPreferencesResponse200; + +export type getV1GetNotificationPreferencesResponse = + getV1GetNotificationPreferencesResponseComposite & { + headers: Headers; + }; + +export const getGetV1GetNotificationPreferencesUrl = () => { + return `/api/auth/user/preferences`; +}; + +export const getV1GetNotificationPreferences = async ( + options?: RequestInit, +): Promise => { + return customMutator( + getGetV1GetNotificationPreferencesUrl(), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV1GetNotificationPreferencesQueryKey = () => { + return [`/api/auth/user/preferences`] as const; +}; + +export const getGetV1GetNotificationPreferencesQueryOptions = < + TData = Awaited>, + TError = unknown, +>(options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; +}) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = + queryOptions?.queryKey ?? getGetV1GetNotificationPreferencesQueryKey(); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => + getV1GetNotificationPreferences({ signal, ...requestOptions }); + + return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV1GetNotificationPreferencesQueryResult = NonNullable< + Awaited> +>; +export type GetV1GetNotificationPreferencesQueryError = unknown; + +export function useGetV1GetNotificationPreferences< + TData = Awaited>, + TError = unknown, +>( + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1GetNotificationPreferences< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1GetNotificationPreferences< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary Get notification preferences + */ + +export function useGetV1GetNotificationPreferences< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV1GetNotificationPreferencesQueryOptions(options); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * @summary Update notification preferences + */ +export type postV1UpdateNotificationPreferencesResponse200 = { + data: NotificationPreference; + status: 200; +}; + +export type postV1UpdateNotificationPreferencesResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type postV1UpdateNotificationPreferencesResponseComposite = + | postV1UpdateNotificationPreferencesResponse200 + | postV1UpdateNotificationPreferencesResponse422; + +export type postV1UpdateNotificationPreferencesResponse = + postV1UpdateNotificationPreferencesResponseComposite & { + headers: Headers; + }; + +export const getPostV1UpdateNotificationPreferencesUrl = () => { + return `/api/auth/user/preferences`; +}; + +export const postV1UpdateNotificationPreferences = async ( + notificationPreferenceDTO: NotificationPreferenceDTO, + options?: RequestInit, +): Promise => { + return customMutator( + getPostV1UpdateNotificationPreferencesUrl(), + { + ...options, + method: "POST", + headers: { "Content-Type": "application/json", ...options?.headers }, + body: JSON.stringify(notificationPreferenceDTO), + }, + ); +}; + +export const getPostV1UpdateNotificationPreferencesMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { data: NotificationPreferenceDTO }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { data: NotificationPreferenceDTO }, + TContext +> => { + const mutationKey = ["postV1UpdateNotificationPreferences"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { data: NotificationPreferenceDTO } + > = (props) => { + const { data } = props ?? {}; + + return postV1UpdateNotificationPreferences(data, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PostV1UpdateNotificationPreferencesMutationResult = NonNullable< + Awaited> +>; +export type PostV1UpdateNotificationPreferencesMutationBody = + NotificationPreferenceDTO; +export type PostV1UpdateNotificationPreferencesMutationError = + HTTPValidationError; + +/** + * @summary Update notification preferences + */ +export const usePostV1UpdateNotificationPreferences = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { data: NotificationPreferenceDTO }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { data: NotificationPreferenceDTO }, + TContext +> => { + const mutationOptions = + getPostV1UpdateNotificationPreferencesMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/endpoints/blocks/blocks.ts b/autogpt_platform/frontend/src/app/api/__generated__/endpoints/blocks/blocks.ts new file mode 100644 index 0000000000..a11fb83730 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/endpoints/blocks/blocks.ts @@ -0,0 +1,322 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import { useMutation, useQuery } from "@tanstack/react-query"; +import type { + DataTag, + DefinedInitialDataOptions, + DefinedUseQueryResult, + MutationFunction, + QueryClient, + QueryFunction, + QueryKey, + UndefinedInitialDataOptions, + UseMutationOptions, + UseMutationResult, + UseQueryOptions, + UseQueryResult, +} from "@tanstack/react-query"; + +import type { GetV1ListAvailableBlocks200Item } from "../../models/getV1ListAvailableBlocks200Item"; + +import type { HTTPValidationError } from "../../models/hTTPValidationError"; + +import type { PostV1ExecuteGraphBlock200 } from "../../models/postV1ExecuteGraphBlock200"; + +import type { PostV1ExecuteGraphBlockBody } from "../../models/postV1ExecuteGraphBlockBody"; + +import { customMutator } from "../../../mutators/custom-mutator"; + +type SecondParameter unknown> = Parameters[1]; + +/** + * @summary List available blocks + */ +export type getV1ListAvailableBlocksResponse200 = { + data: GetV1ListAvailableBlocks200Item[]; + status: 200; +}; + +export type getV1ListAvailableBlocksResponseComposite = + getV1ListAvailableBlocksResponse200; + +export type getV1ListAvailableBlocksResponse = + getV1ListAvailableBlocksResponseComposite & { + headers: Headers; + }; + +export const getGetV1ListAvailableBlocksUrl = () => { + return `/api/blocks`; +}; + +export const getV1ListAvailableBlocks = async ( + options?: RequestInit, +): Promise => { + return customMutator( + getGetV1ListAvailableBlocksUrl(), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV1ListAvailableBlocksQueryKey = () => { + return [`/api/blocks`] as const; +}; + +export const getGetV1ListAvailableBlocksQueryOptions = < + TData = Awaited>, + TError = unknown, +>(options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; +}) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = + queryOptions?.queryKey ?? getGetV1ListAvailableBlocksQueryKey(); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => getV1ListAvailableBlocks({ signal, ...requestOptions }); + + return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV1ListAvailableBlocksQueryResult = NonNullable< + Awaited> +>; +export type GetV1ListAvailableBlocksQueryError = unknown; + +export function useGetV1ListAvailableBlocks< + TData = Awaited>, + TError = unknown, +>( + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1ListAvailableBlocks< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1ListAvailableBlocks< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary List available blocks + */ + +export function useGetV1ListAvailableBlocks< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV1ListAvailableBlocksQueryOptions(options); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * @summary Execute graph block + */ +export type postV1ExecuteGraphBlockResponse200 = { + data: PostV1ExecuteGraphBlock200; + status: 200; +}; + +export type postV1ExecuteGraphBlockResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type postV1ExecuteGraphBlockResponseComposite = + | postV1ExecuteGraphBlockResponse200 + | postV1ExecuteGraphBlockResponse422; + +export type postV1ExecuteGraphBlockResponse = + postV1ExecuteGraphBlockResponseComposite & { + headers: Headers; + }; + +export const getPostV1ExecuteGraphBlockUrl = (blockId: string) => { + return `/api/blocks/${blockId}/execute`; +}; + +export const postV1ExecuteGraphBlock = async ( + blockId: string, + postV1ExecuteGraphBlockBody: PostV1ExecuteGraphBlockBody, + options?: RequestInit, +): Promise => { + return customMutator( + getPostV1ExecuteGraphBlockUrl(blockId), + { + ...options, + method: "POST", + headers: { "Content-Type": "application/json", ...options?.headers }, + body: JSON.stringify(postV1ExecuteGraphBlockBody), + }, + ); +}; + +export const getPostV1ExecuteGraphBlockMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { blockId: string; data: PostV1ExecuteGraphBlockBody }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { blockId: string; data: PostV1ExecuteGraphBlockBody }, + TContext +> => { + const mutationKey = ["postV1ExecuteGraphBlock"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { blockId: string; data: PostV1ExecuteGraphBlockBody } + > = (props) => { + const { blockId, data } = props ?? {}; + + return postV1ExecuteGraphBlock(blockId, data, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PostV1ExecuteGraphBlockMutationResult = NonNullable< + Awaited> +>; +export type PostV1ExecuteGraphBlockMutationBody = PostV1ExecuteGraphBlockBody; +export type PostV1ExecuteGraphBlockMutationError = HTTPValidationError; + +/** + * @summary Execute graph block + */ +export const usePostV1ExecuteGraphBlock = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { blockId: string; data: PostV1ExecuteGraphBlockBody }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { blockId: string; data: PostV1ExecuteGraphBlockBody }, + TContext +> => { + const mutationOptions = getPostV1ExecuteGraphBlockMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/endpoints/credits/credits.ts b/autogpt_platform/frontend/src/app/api/__generated__/endpoints/credits/credits.ts new file mode 100644 index 0000000000..a6007de0f4 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/endpoints/credits/credits.ts @@ -0,0 +1,1480 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import { useMutation, useQuery } from "@tanstack/react-query"; +import type { + DataTag, + DefinedInitialDataOptions, + DefinedUseQueryResult, + MutationFunction, + QueryClient, + QueryFunction, + QueryKey, + UndefinedInitialDataOptions, + UseMutationOptions, + UseMutationResult, + UseQueryOptions, + UseQueryResult, +} from "@tanstack/react-query"; + +import type { AutoTopUpConfig } from "../../models/autoTopUpConfig"; + +import type { GetV1GetCreditHistoryParams } from "../../models/getV1GetCreditHistoryParams"; + +import type { GetV1GetUserCredits200 } from "../../models/getV1GetUserCredits200"; + +import type { GetV1ManagePaymentMethods200 } from "../../models/getV1ManagePaymentMethods200"; + +import type { HTTPValidationError } from "../../models/hTTPValidationError"; + +import type { PostV1RefundCreditTransactionBody } from "../../models/postV1RefundCreditTransactionBody"; + +import type { RefundRequest } from "../../models/refundRequest"; + +import type { RequestTopUp } from "../../models/requestTopUp"; + +import type { TransactionHistory } from "../../models/transactionHistory"; + +import { customMutator } from "../../../mutators/custom-mutator"; + +type SecondParameter unknown> = Parameters[1]; + +/** + * @summary Get user credits + */ +export type getV1GetUserCreditsResponse200 = { + data: GetV1GetUserCredits200; + status: 200; +}; + +export type getV1GetUserCreditsResponseComposite = + getV1GetUserCreditsResponse200; + +export type getV1GetUserCreditsResponse = + getV1GetUserCreditsResponseComposite & { + headers: Headers; + }; + +export const getGetV1GetUserCreditsUrl = () => { + return `/api/credits`; +}; + +export const getV1GetUserCredits = async ( + options?: RequestInit, +): Promise => { + return customMutator( + getGetV1GetUserCreditsUrl(), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV1GetUserCreditsQueryKey = () => { + return [`/api/credits`] as const; +}; + +export const getGetV1GetUserCreditsQueryOptions = < + TData = Awaited>, + TError = unknown, +>(options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; +}) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = queryOptions?.queryKey ?? getGetV1GetUserCreditsQueryKey(); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => getV1GetUserCredits({ signal, ...requestOptions }); + + return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV1GetUserCreditsQueryResult = NonNullable< + Awaited> +>; +export type GetV1GetUserCreditsQueryError = unknown; + +export function useGetV1GetUserCredits< + TData = Awaited>, + TError = unknown, +>( + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1GetUserCredits< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1GetUserCredits< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary Get user credits + */ + +export function useGetV1GetUserCredits< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV1GetUserCreditsQueryOptions(options); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * @summary Request credit top up + */ +export type postV1RequestCreditTopUpResponse200 = { + data: unknown; + status: 200; +}; + +export type postV1RequestCreditTopUpResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type postV1RequestCreditTopUpResponseComposite = + | postV1RequestCreditTopUpResponse200 + | postV1RequestCreditTopUpResponse422; + +export type postV1RequestCreditTopUpResponse = + postV1RequestCreditTopUpResponseComposite & { + headers: Headers; + }; + +export const getPostV1RequestCreditTopUpUrl = () => { + return `/api/credits`; +}; + +export const postV1RequestCreditTopUp = async ( + requestTopUp: RequestTopUp, + options?: RequestInit, +): Promise => { + return customMutator( + getPostV1RequestCreditTopUpUrl(), + { + ...options, + method: "POST", + headers: { "Content-Type": "application/json", ...options?.headers }, + body: JSON.stringify(requestTopUp), + }, + ); +}; + +export const getPostV1RequestCreditTopUpMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { data: RequestTopUp }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { data: RequestTopUp }, + TContext +> => { + const mutationKey = ["postV1RequestCreditTopUp"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { data: RequestTopUp } + > = (props) => { + const { data } = props ?? {}; + + return postV1RequestCreditTopUp(data, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PostV1RequestCreditTopUpMutationResult = NonNullable< + Awaited> +>; +export type PostV1RequestCreditTopUpMutationBody = RequestTopUp; +export type PostV1RequestCreditTopUpMutationError = HTTPValidationError; + +/** + * @summary Request credit top up + */ +export const usePostV1RequestCreditTopUp = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { data: RequestTopUp }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { data: RequestTopUp }, + TContext +> => { + const mutationOptions = getPostV1RequestCreditTopUpMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * @summary Fulfill checkout session + */ +export type patchV1FulfillCheckoutSessionResponse200 = { + data: unknown; + status: 200; +}; + +export type patchV1FulfillCheckoutSessionResponseComposite = + patchV1FulfillCheckoutSessionResponse200; + +export type patchV1FulfillCheckoutSessionResponse = + patchV1FulfillCheckoutSessionResponseComposite & { + headers: Headers; + }; + +export const getPatchV1FulfillCheckoutSessionUrl = () => { + return `/api/credits`; +}; + +export const patchV1FulfillCheckoutSession = async ( + options?: RequestInit, +): Promise => { + return customMutator( + getPatchV1FulfillCheckoutSessionUrl(), + { + ...options, + method: "PATCH", + }, + ); +}; + +export const getPatchV1FulfillCheckoutSessionMutationOptions = < + TError = unknown, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + void, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + void, + TContext +> => { + const mutationKey = ["patchV1FulfillCheckoutSession"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + void + > = () => { + return patchV1FulfillCheckoutSession(requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PatchV1FulfillCheckoutSessionMutationResult = NonNullable< + Awaited> +>; + +export type PatchV1FulfillCheckoutSessionMutationError = unknown; + +/** + * @summary Fulfill checkout session + */ +export const usePatchV1FulfillCheckoutSession = < + TError = unknown, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + void, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + void, + TContext +> => { + const mutationOptions = + getPatchV1FulfillCheckoutSessionMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * @summary Refund credit transaction + */ +export type postV1RefundCreditTransactionResponse200 = { + data: number; + status: 200; +}; + +export type postV1RefundCreditTransactionResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type postV1RefundCreditTransactionResponseComposite = + | postV1RefundCreditTransactionResponse200 + | postV1RefundCreditTransactionResponse422; + +export type postV1RefundCreditTransactionResponse = + postV1RefundCreditTransactionResponseComposite & { + headers: Headers; + }; + +export const getPostV1RefundCreditTransactionUrl = (transactionKey: string) => { + return `/api/credits/${transactionKey}/refund`; +}; + +export const postV1RefundCreditTransaction = async ( + transactionKey: string, + postV1RefundCreditTransactionBody: PostV1RefundCreditTransactionBody, + options?: RequestInit, +): Promise => { + return customMutator( + getPostV1RefundCreditTransactionUrl(transactionKey), + { + ...options, + method: "POST", + headers: { "Content-Type": "application/json", ...options?.headers }, + body: JSON.stringify(postV1RefundCreditTransactionBody), + }, + ); +}; + +export const getPostV1RefundCreditTransactionMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { transactionKey: string; data: PostV1RefundCreditTransactionBody }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { transactionKey: string; data: PostV1RefundCreditTransactionBody }, + TContext +> => { + const mutationKey = ["postV1RefundCreditTransaction"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { transactionKey: string; data: PostV1RefundCreditTransactionBody } + > = (props) => { + const { transactionKey, data } = props ?? {}; + + return postV1RefundCreditTransaction(transactionKey, data, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PostV1RefundCreditTransactionMutationResult = NonNullable< + Awaited> +>; +export type PostV1RefundCreditTransactionMutationBody = + PostV1RefundCreditTransactionBody; +export type PostV1RefundCreditTransactionMutationError = HTTPValidationError; + +/** + * @summary Refund credit transaction + */ +export const usePostV1RefundCreditTransaction = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { transactionKey: string; data: PostV1RefundCreditTransactionBody }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { transactionKey: string; data: PostV1RefundCreditTransactionBody }, + TContext +> => { + const mutationOptions = + getPostV1RefundCreditTransactionMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * @summary Get auto top up + */ +export type getV1GetAutoTopUpResponse200 = { + data: AutoTopUpConfig; + status: 200; +}; + +export type getV1GetAutoTopUpResponseComposite = getV1GetAutoTopUpResponse200; + +export type getV1GetAutoTopUpResponse = getV1GetAutoTopUpResponseComposite & { + headers: Headers; +}; + +export const getGetV1GetAutoTopUpUrl = () => { + return `/api/credits/auto-top-up`; +}; + +export const getV1GetAutoTopUp = async ( + options?: RequestInit, +): Promise => { + return customMutator(getGetV1GetAutoTopUpUrl(), { + ...options, + method: "GET", + }); +}; + +export const getGetV1GetAutoTopUpQueryKey = () => { + return [`/api/credits/auto-top-up`] as const; +}; + +export const getGetV1GetAutoTopUpQueryOptions = < + TData = Awaited>, + TError = unknown, +>(options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; +}) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = queryOptions?.queryKey ?? getGetV1GetAutoTopUpQueryKey(); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => getV1GetAutoTopUp({ signal, ...requestOptions }); + + return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV1GetAutoTopUpQueryResult = NonNullable< + Awaited> +>; +export type GetV1GetAutoTopUpQueryError = unknown; + +export function useGetV1GetAutoTopUp< + TData = Awaited>, + TError = unknown, +>( + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1GetAutoTopUp< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1GetAutoTopUp< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary Get auto top up + */ + +export function useGetV1GetAutoTopUp< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV1GetAutoTopUpQueryOptions(options); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * @summary Configure auto top up + */ +export type postV1ConfigureAutoTopUpResponse200 = { + data: string; + status: 200; +}; + +export type postV1ConfigureAutoTopUpResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type postV1ConfigureAutoTopUpResponseComposite = + | postV1ConfigureAutoTopUpResponse200 + | postV1ConfigureAutoTopUpResponse422; + +export type postV1ConfigureAutoTopUpResponse = + postV1ConfigureAutoTopUpResponseComposite & { + headers: Headers; + }; + +export const getPostV1ConfigureAutoTopUpUrl = () => { + return `/api/credits/auto-top-up`; +}; + +export const postV1ConfigureAutoTopUp = async ( + autoTopUpConfig: AutoTopUpConfig, + options?: RequestInit, +): Promise => { + return customMutator( + getPostV1ConfigureAutoTopUpUrl(), + { + ...options, + method: "POST", + headers: { "Content-Type": "application/json", ...options?.headers }, + body: JSON.stringify(autoTopUpConfig), + }, + ); +}; + +export const getPostV1ConfigureAutoTopUpMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { data: AutoTopUpConfig }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { data: AutoTopUpConfig }, + TContext +> => { + const mutationKey = ["postV1ConfigureAutoTopUp"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { data: AutoTopUpConfig } + > = (props) => { + const { data } = props ?? {}; + + return postV1ConfigureAutoTopUp(data, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PostV1ConfigureAutoTopUpMutationResult = NonNullable< + Awaited> +>; +export type PostV1ConfigureAutoTopUpMutationBody = AutoTopUpConfig; +export type PostV1ConfigureAutoTopUpMutationError = HTTPValidationError; + +/** + * @summary Configure auto top up + */ +export const usePostV1ConfigureAutoTopUp = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { data: AutoTopUpConfig }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { data: AutoTopUpConfig }, + TContext +> => { + const mutationOptions = getPostV1ConfigureAutoTopUpMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * @summary Handle Stripe webhooks + */ +export type postV1HandleStripeWebhooksResponse200 = { + data: unknown; + status: 200; +}; + +export type postV1HandleStripeWebhooksResponseComposite = + postV1HandleStripeWebhooksResponse200; + +export type postV1HandleStripeWebhooksResponse = + postV1HandleStripeWebhooksResponseComposite & { + headers: Headers; + }; + +export const getPostV1HandleStripeWebhooksUrl = () => { + return `/api/credits/stripe_webhook`; +}; + +export const postV1HandleStripeWebhooks = async ( + options?: RequestInit, +): Promise => { + return customMutator( + getPostV1HandleStripeWebhooksUrl(), + { + ...options, + method: "POST", + }, + ); +}; + +export const getPostV1HandleStripeWebhooksMutationOptions = < + TError = unknown, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + void, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + void, + TContext +> => { + const mutationKey = ["postV1HandleStripeWebhooks"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + void + > = () => { + return postV1HandleStripeWebhooks(requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PostV1HandleStripeWebhooksMutationResult = NonNullable< + Awaited> +>; + +export type PostV1HandleStripeWebhooksMutationError = unknown; + +/** + * @summary Handle Stripe webhooks + */ +export const usePostV1HandleStripeWebhooks = < + TError = unknown, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + void, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + void, + TContext +> => { + const mutationOptions = getPostV1HandleStripeWebhooksMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * @summary Manage payment methods + */ +export type getV1ManagePaymentMethodsResponse200 = { + data: GetV1ManagePaymentMethods200; + status: 200; +}; + +export type getV1ManagePaymentMethodsResponseComposite = + getV1ManagePaymentMethodsResponse200; + +export type getV1ManagePaymentMethodsResponse = + getV1ManagePaymentMethodsResponseComposite & { + headers: Headers; + }; + +export const getGetV1ManagePaymentMethodsUrl = () => { + return `/api/credits/manage`; +}; + +export const getV1ManagePaymentMethods = async ( + options?: RequestInit, +): Promise => { + return customMutator( + getGetV1ManagePaymentMethodsUrl(), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV1ManagePaymentMethodsQueryKey = () => { + return [`/api/credits/manage`] as const; +}; + +export const getGetV1ManagePaymentMethodsQueryOptions = < + TData = Awaited>, + TError = unknown, +>(options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; +}) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = + queryOptions?.queryKey ?? getGetV1ManagePaymentMethodsQueryKey(); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => getV1ManagePaymentMethods({ signal, ...requestOptions }); + + return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV1ManagePaymentMethodsQueryResult = NonNullable< + Awaited> +>; +export type GetV1ManagePaymentMethodsQueryError = unknown; + +export function useGetV1ManagePaymentMethods< + TData = Awaited>, + TError = unknown, +>( + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1ManagePaymentMethods< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1ManagePaymentMethods< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary Manage payment methods + */ + +export function useGetV1ManagePaymentMethods< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV1ManagePaymentMethodsQueryOptions(options); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * @summary Get credit history + */ +export type getV1GetCreditHistoryResponse200 = { + data: TransactionHistory; + status: 200; +}; + +export type getV1GetCreditHistoryResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type getV1GetCreditHistoryResponseComposite = + | getV1GetCreditHistoryResponse200 + | getV1GetCreditHistoryResponse422; + +export type getV1GetCreditHistoryResponse = + getV1GetCreditHistoryResponseComposite & { + headers: Headers; + }; + +export const getGetV1GetCreditHistoryUrl = ( + params?: GetV1GetCreditHistoryParams, +) => { + const normalizedParams = new URLSearchParams(); + + Object.entries(params || {}).forEach(([key, value]) => { + if (value !== undefined) { + normalizedParams.append(key, value === null ? "null" : value.toString()); + } + }); + + const stringifiedParams = normalizedParams.toString(); + + return stringifiedParams.length > 0 + ? `/api/credits/transactions?${stringifiedParams}` + : `/api/credits/transactions`; +}; + +export const getV1GetCreditHistory = async ( + params?: GetV1GetCreditHistoryParams, + options?: RequestInit, +): Promise => { + return customMutator( + getGetV1GetCreditHistoryUrl(params), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV1GetCreditHistoryQueryKey = ( + params?: GetV1GetCreditHistoryParams, +) => { + return [`/api/credits/transactions`, ...(params ? [params] : [])] as const; +}; + +export const getGetV1GetCreditHistoryQueryOptions = < + TData = Awaited>, + TError = HTTPValidationError, +>( + params?: GetV1GetCreditHistoryParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, +) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = + queryOptions?.queryKey ?? getGetV1GetCreditHistoryQueryKey(params); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => + getV1GetCreditHistory(params, { signal, ...requestOptions }); + + return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV1GetCreditHistoryQueryResult = NonNullable< + Awaited> +>; +export type GetV1GetCreditHistoryQueryError = HTTPValidationError; + +export function useGetV1GetCreditHistory< + TData = Awaited>, + TError = HTTPValidationError, +>( + params: undefined | GetV1GetCreditHistoryParams, + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1GetCreditHistory< + TData = Awaited>, + TError = HTTPValidationError, +>( + params?: GetV1GetCreditHistoryParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1GetCreditHistory< + TData = Awaited>, + TError = HTTPValidationError, +>( + params?: GetV1GetCreditHistoryParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary Get credit history + */ + +export function useGetV1GetCreditHistory< + TData = Awaited>, + TError = HTTPValidationError, +>( + params?: GetV1GetCreditHistoryParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV1GetCreditHistoryQueryOptions(params, options); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * @summary Get refund requests + */ +export type getV1GetRefundRequestsResponse200 = { + data: RefundRequest[]; + status: 200; +}; + +export type getV1GetRefundRequestsResponseComposite = + getV1GetRefundRequestsResponse200; + +export type getV1GetRefundRequestsResponse = + getV1GetRefundRequestsResponseComposite & { + headers: Headers; + }; + +export const getGetV1GetRefundRequestsUrl = () => { + return `/api/credits/refunds`; +}; + +export const getV1GetRefundRequests = async ( + options?: RequestInit, +): Promise => { + return customMutator( + getGetV1GetRefundRequestsUrl(), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV1GetRefundRequestsQueryKey = () => { + return [`/api/credits/refunds`] as const; +}; + +export const getGetV1GetRefundRequestsQueryOptions = < + TData = Awaited>, + TError = unknown, +>(options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; +}) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = + queryOptions?.queryKey ?? getGetV1GetRefundRequestsQueryKey(); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => getV1GetRefundRequests({ signal, ...requestOptions }); + + return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV1GetRefundRequestsQueryResult = NonNullable< + Awaited> +>; +export type GetV1GetRefundRequestsQueryError = unknown; + +export function useGetV1GetRefundRequests< + TData = Awaited>, + TError = unknown, +>( + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1GetRefundRequests< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1GetRefundRequests< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary Get refund requests + */ + +export function useGetV1GetRefundRequests< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV1GetRefundRequestsQueryOptions(options); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/endpoints/email/email.ts b/autogpt_platform/frontend/src/app/api/__generated__/endpoints/email/email.ts new file mode 100644 index 0000000000..fd0d22ee0b --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/endpoints/email/email.ts @@ -0,0 +1,265 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import { useMutation } from "@tanstack/react-query"; +import type { + MutationFunction, + QueryClient, + UseMutationOptions, + UseMutationResult, +} from "@tanstack/react-query"; + +import type { HTTPValidationError } from "../../models/hTTPValidationError"; + +import type { PostV1HandlePostmarkEmailWebhooksBody } from "../../models/postV1HandlePostmarkEmailWebhooksBody"; + +import type { PostV1OneClickEmailUnsubscribeParams } from "../../models/postV1OneClickEmailUnsubscribeParams"; + +import { customMutator } from "../../../mutators/custom-mutator"; + +type SecondParameter unknown> = Parameters[1]; + +/** + * @summary One Click Email Unsubscribe + */ +export type postV1OneClickEmailUnsubscribeResponse200 = { + data: unknown; + status: 200; +}; + +export type postV1OneClickEmailUnsubscribeResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type postV1OneClickEmailUnsubscribeResponseComposite = + | postV1OneClickEmailUnsubscribeResponse200 + | postV1OneClickEmailUnsubscribeResponse422; + +export type postV1OneClickEmailUnsubscribeResponse = + postV1OneClickEmailUnsubscribeResponseComposite & { + headers: Headers; + }; + +export const getPostV1OneClickEmailUnsubscribeUrl = ( + params: PostV1OneClickEmailUnsubscribeParams, +) => { + const normalizedParams = new URLSearchParams(); + + Object.entries(params || {}).forEach(([key, value]) => { + if (value !== undefined) { + normalizedParams.append(key, value === null ? "null" : value.toString()); + } + }); + + const stringifiedParams = normalizedParams.toString(); + + return stringifiedParams.length > 0 + ? `/api/email/unsubscribe?${stringifiedParams}` + : `/api/email/unsubscribe`; +}; + +export const postV1OneClickEmailUnsubscribe = async ( + params: PostV1OneClickEmailUnsubscribeParams, + options?: RequestInit, +): Promise => { + return customMutator( + getPostV1OneClickEmailUnsubscribeUrl(params), + { + ...options, + method: "POST", + }, + ); +}; + +export const getPostV1OneClickEmailUnsubscribeMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { params: PostV1OneClickEmailUnsubscribeParams }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { params: PostV1OneClickEmailUnsubscribeParams }, + TContext +> => { + const mutationKey = ["postV1OneClickEmailUnsubscribe"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { params: PostV1OneClickEmailUnsubscribeParams } + > = (props) => { + const { params } = props ?? {}; + + return postV1OneClickEmailUnsubscribe(params, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PostV1OneClickEmailUnsubscribeMutationResult = NonNullable< + Awaited> +>; + +export type PostV1OneClickEmailUnsubscribeMutationError = HTTPValidationError; + +/** + * @summary One Click Email Unsubscribe + */ +export const usePostV1OneClickEmailUnsubscribe = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { params: PostV1OneClickEmailUnsubscribeParams }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { params: PostV1OneClickEmailUnsubscribeParams }, + TContext +> => { + const mutationOptions = + getPostV1OneClickEmailUnsubscribeMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * @summary Handle Postmark Email Webhooks + */ +export type postV1HandlePostmarkEmailWebhooksResponse200 = { + data: unknown; + status: 200; +}; + +export type postV1HandlePostmarkEmailWebhooksResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type postV1HandlePostmarkEmailWebhooksResponseComposite = + | postV1HandlePostmarkEmailWebhooksResponse200 + | postV1HandlePostmarkEmailWebhooksResponse422; + +export type postV1HandlePostmarkEmailWebhooksResponse = + postV1HandlePostmarkEmailWebhooksResponseComposite & { + headers: Headers; + }; + +export const getPostV1HandlePostmarkEmailWebhooksUrl = () => { + return `/api/email/`; +}; + +export const postV1HandlePostmarkEmailWebhooks = async ( + postV1HandlePostmarkEmailWebhooksBody: PostV1HandlePostmarkEmailWebhooksBody, + options?: RequestInit, +): Promise => { + return customMutator( + getPostV1HandlePostmarkEmailWebhooksUrl(), + { + ...options, + method: "POST", + headers: { "Content-Type": "application/json", ...options?.headers }, + body: JSON.stringify(postV1HandlePostmarkEmailWebhooksBody), + }, + ); +}; + +export const getPostV1HandlePostmarkEmailWebhooksMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { data: PostV1HandlePostmarkEmailWebhooksBody }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { data: PostV1HandlePostmarkEmailWebhooksBody }, + TContext +> => { + const mutationKey = ["postV1HandlePostmarkEmailWebhooks"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { data: PostV1HandlePostmarkEmailWebhooksBody } + > = (props) => { + const { data } = props ?? {}; + + return postV1HandlePostmarkEmailWebhooks(data, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PostV1HandlePostmarkEmailWebhooksMutationResult = NonNullable< + Awaited> +>; +export type PostV1HandlePostmarkEmailWebhooksMutationBody = + PostV1HandlePostmarkEmailWebhooksBody; +export type PostV1HandlePostmarkEmailWebhooksMutationError = + HTTPValidationError; + +/** + * @summary Handle Postmark Email Webhooks + */ +export const usePostV1HandlePostmarkEmailWebhooks = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { data: PostV1HandlePostmarkEmailWebhooksBody }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { data: PostV1HandlePostmarkEmailWebhooksBody }, + TContext +> => { + const mutationOptions = + getPostV1HandlePostmarkEmailWebhooksMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/endpoints/graphs/graphs.ts b/autogpt_platform/frontend/src/app/api/__generated__/endpoints/graphs/graphs.ts new file mode 100644 index 0000000000..4f249e2548 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/endpoints/graphs/graphs.ts @@ -0,0 +1,2302 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import { useMutation, useQuery } from "@tanstack/react-query"; +import type { + DataTag, + DefinedInitialDataOptions, + DefinedUseQueryResult, + MutationFunction, + QueryClient, + QueryFunction, + QueryKey, + UndefinedInitialDataOptions, + UseMutationOptions, + UseMutationResult, + UseQueryOptions, + UseQueryResult, +} from "@tanstack/react-query"; + +import type { BodyPostV1ExecuteGraphAgent } from "../../models/bodyPostV1ExecuteGraphAgent"; + +import type { CreateGraph } from "../../models/createGraph"; + +import type { DeleteGraphResponse } from "../../models/deleteGraphResponse"; + +import type { ExecuteGraphResponse } from "../../models/executeGraphResponse"; + +import type { GetV1GetExecutionDetails200 } from "../../models/getV1GetExecutionDetails200"; + +import type { GetV1GetGraphVersionParams } from "../../models/getV1GetGraphVersionParams"; + +import type { GetV1GetSpecificGraphParams } from "../../models/getV1GetSpecificGraphParams"; + +import type { Graph } from "../../models/graph"; + +import type { GraphExecution } from "../../models/graphExecution"; + +import type { GraphExecutionMeta } from "../../models/graphExecutionMeta"; + +import type { GraphModel } from "../../models/graphModel"; + +import type { HTTPValidationError } from "../../models/hTTPValidationError"; + +import type { PostV1ExecuteGraphAgentParams } from "../../models/postV1ExecuteGraphAgentParams"; + +import type { SetGraphActiveVersion } from "../../models/setGraphActiveVersion"; + +import { customMutator } from "../../../mutators/custom-mutator"; + +type SecondParameter unknown> = Parameters[1]; + +/** + * @summary List user graphs + */ +export type getV1ListUserGraphsResponse200 = { + data: GraphModel[]; + status: 200; +}; + +export type getV1ListUserGraphsResponseComposite = + getV1ListUserGraphsResponse200; + +export type getV1ListUserGraphsResponse = + getV1ListUserGraphsResponseComposite & { + headers: Headers; + }; + +export const getGetV1ListUserGraphsUrl = () => { + return `/api/graphs`; +}; + +export const getV1ListUserGraphs = async ( + options?: RequestInit, +): Promise => { + return customMutator( + getGetV1ListUserGraphsUrl(), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV1ListUserGraphsQueryKey = () => { + return [`/api/graphs`] as const; +}; + +export const getGetV1ListUserGraphsQueryOptions = < + TData = Awaited>, + TError = unknown, +>(options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; +}) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = queryOptions?.queryKey ?? getGetV1ListUserGraphsQueryKey(); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => getV1ListUserGraphs({ signal, ...requestOptions }); + + return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV1ListUserGraphsQueryResult = NonNullable< + Awaited> +>; +export type GetV1ListUserGraphsQueryError = unknown; + +export function useGetV1ListUserGraphs< + TData = Awaited>, + TError = unknown, +>( + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1ListUserGraphs< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1ListUserGraphs< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary List user graphs + */ + +export function useGetV1ListUserGraphs< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV1ListUserGraphsQueryOptions(options); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * @summary Create new graph + */ +export type postV1CreateNewGraphResponse200 = { + data: GraphModel; + status: 200; +}; + +export type postV1CreateNewGraphResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type postV1CreateNewGraphResponseComposite = + | postV1CreateNewGraphResponse200 + | postV1CreateNewGraphResponse422; + +export type postV1CreateNewGraphResponse = + postV1CreateNewGraphResponseComposite & { + headers: Headers; + }; + +export const getPostV1CreateNewGraphUrl = () => { + return `/api/graphs`; +}; + +export const postV1CreateNewGraph = async ( + createGraph: CreateGraph, + options?: RequestInit, +): Promise => { + return customMutator( + getPostV1CreateNewGraphUrl(), + { + ...options, + method: "POST", + headers: { "Content-Type": "application/json", ...options?.headers }, + body: JSON.stringify(createGraph), + }, + ); +}; + +export const getPostV1CreateNewGraphMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { data: CreateGraph }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { data: CreateGraph }, + TContext +> => { + const mutationKey = ["postV1CreateNewGraph"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { data: CreateGraph } + > = (props) => { + const { data } = props ?? {}; + + return postV1CreateNewGraph(data, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PostV1CreateNewGraphMutationResult = NonNullable< + Awaited> +>; +export type PostV1CreateNewGraphMutationBody = CreateGraph; +export type PostV1CreateNewGraphMutationError = HTTPValidationError; + +/** + * @summary Create new graph + */ +export const usePostV1CreateNewGraph = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { data: CreateGraph }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { data: CreateGraph }, + TContext +> => { + const mutationOptions = getPostV1CreateNewGraphMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * @summary Get graph version + */ +export type getV1GetGraphVersionResponse200 = { + data: GraphModel; + status: 200; +}; + +export type getV1GetGraphVersionResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type getV1GetGraphVersionResponseComposite = + | getV1GetGraphVersionResponse200 + | getV1GetGraphVersionResponse422; + +export type getV1GetGraphVersionResponse = + getV1GetGraphVersionResponseComposite & { + headers: Headers; + }; + +export const getGetV1GetGraphVersionUrl = ( + graphId: string, + version: number | null, + params?: GetV1GetGraphVersionParams, +) => { + const normalizedParams = new URLSearchParams(); + + Object.entries(params || {}).forEach(([key, value]) => { + if (value !== undefined) { + normalizedParams.append(key, value === null ? "null" : value.toString()); + } + }); + + const stringifiedParams = normalizedParams.toString(); + + return stringifiedParams.length > 0 + ? `/api/graphs/${graphId}/versions/${version}?${stringifiedParams}` + : `/api/graphs/${graphId}/versions/${version}`; +}; + +export const getV1GetGraphVersion = async ( + graphId: string, + version: number | null, + params?: GetV1GetGraphVersionParams, + options?: RequestInit, +): Promise => { + return customMutator( + getGetV1GetGraphVersionUrl(graphId, version, params), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV1GetGraphVersionQueryKey = ( + graphId: string, + version: number | null, + params?: GetV1GetGraphVersionParams, +) => { + return [ + `/api/graphs/${graphId}/versions/${version}`, + ...(params ? [params] : []), + ] as const; +}; + +export const getGetV1GetGraphVersionQueryOptions = < + TData = Awaited>, + TError = HTTPValidationError, +>( + graphId: string, + version: number | null, + params?: GetV1GetGraphVersionParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, +) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = + queryOptions?.queryKey ?? + getGetV1GetGraphVersionQueryKey(graphId, version, params); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => + getV1GetGraphVersion(graphId, version, params, { + signal, + ...requestOptions, + }); + + return { + queryKey, + queryFn, + enabled: !!(graphId && version), + ...queryOptions, + } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV1GetGraphVersionQueryResult = NonNullable< + Awaited> +>; +export type GetV1GetGraphVersionQueryError = HTTPValidationError; + +export function useGetV1GetGraphVersion< + TData = Awaited>, + TError = HTTPValidationError, +>( + graphId: string, + version: number | null, + params: undefined | GetV1GetGraphVersionParams, + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1GetGraphVersion< + TData = Awaited>, + TError = HTTPValidationError, +>( + graphId: string, + version: number | null, + params?: GetV1GetGraphVersionParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1GetGraphVersion< + TData = Awaited>, + TError = HTTPValidationError, +>( + graphId: string, + version: number | null, + params?: GetV1GetGraphVersionParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary Get graph version + */ + +export function useGetV1GetGraphVersion< + TData = Awaited>, + TError = HTTPValidationError, +>( + graphId: string, + version: number | null, + params?: GetV1GetGraphVersionParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV1GetGraphVersionQueryOptions( + graphId, + version, + params, + options, + ); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * @summary Get specific graph + */ +export type getV1GetSpecificGraphResponse200 = { + data: GraphModel; + status: 200; +}; + +export type getV1GetSpecificGraphResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type getV1GetSpecificGraphResponseComposite = + | getV1GetSpecificGraphResponse200 + | getV1GetSpecificGraphResponse422; + +export type getV1GetSpecificGraphResponse = + getV1GetSpecificGraphResponseComposite & { + headers: Headers; + }; + +export const getGetV1GetSpecificGraphUrl = ( + graphId: string, + params?: GetV1GetSpecificGraphParams, +) => { + const normalizedParams = new URLSearchParams(); + + Object.entries(params || {}).forEach(([key, value]) => { + if (value !== undefined) { + normalizedParams.append(key, value === null ? "null" : value.toString()); + } + }); + + const stringifiedParams = normalizedParams.toString(); + + return stringifiedParams.length > 0 + ? `/api/graphs/${graphId}?${stringifiedParams}` + : `/api/graphs/${graphId}`; +}; + +export const getV1GetSpecificGraph = async ( + graphId: string, + params?: GetV1GetSpecificGraphParams, + options?: RequestInit, +): Promise => { + return customMutator( + getGetV1GetSpecificGraphUrl(graphId, params), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV1GetSpecificGraphQueryKey = ( + graphId: string, + params?: GetV1GetSpecificGraphParams, +) => { + return [`/api/graphs/${graphId}`, ...(params ? [params] : [])] as const; +}; + +export const getGetV1GetSpecificGraphQueryOptions = < + TData = Awaited>, + TError = HTTPValidationError, +>( + graphId: string, + params?: GetV1GetSpecificGraphParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, +) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = + queryOptions?.queryKey ?? getGetV1GetSpecificGraphQueryKey(graphId, params); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => + getV1GetSpecificGraph(graphId, params, { signal, ...requestOptions }); + + return { + queryKey, + queryFn, + enabled: !!graphId, + ...queryOptions, + } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV1GetSpecificGraphQueryResult = NonNullable< + Awaited> +>; +export type GetV1GetSpecificGraphQueryError = HTTPValidationError; + +export function useGetV1GetSpecificGraph< + TData = Awaited>, + TError = HTTPValidationError, +>( + graphId: string, + params: undefined | GetV1GetSpecificGraphParams, + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1GetSpecificGraph< + TData = Awaited>, + TError = HTTPValidationError, +>( + graphId: string, + params?: GetV1GetSpecificGraphParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1GetSpecificGraph< + TData = Awaited>, + TError = HTTPValidationError, +>( + graphId: string, + params?: GetV1GetSpecificGraphParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary Get specific graph + */ + +export function useGetV1GetSpecificGraph< + TData = Awaited>, + TError = HTTPValidationError, +>( + graphId: string, + params?: GetV1GetSpecificGraphParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV1GetSpecificGraphQueryOptions( + graphId, + params, + options, + ); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * @summary Delete graph permanently + */ +export type deleteV1DeleteGraphPermanentlyResponse200 = { + data: DeleteGraphResponse; + status: 200; +}; + +export type deleteV1DeleteGraphPermanentlyResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type deleteV1DeleteGraphPermanentlyResponseComposite = + | deleteV1DeleteGraphPermanentlyResponse200 + | deleteV1DeleteGraphPermanentlyResponse422; + +export type deleteV1DeleteGraphPermanentlyResponse = + deleteV1DeleteGraphPermanentlyResponseComposite & { + headers: Headers; + }; + +export const getDeleteV1DeleteGraphPermanentlyUrl = (graphId: string) => { + return `/api/graphs/${graphId}`; +}; + +export const deleteV1DeleteGraphPermanently = async ( + graphId: string, + options?: RequestInit, +): Promise => { + return customMutator( + getDeleteV1DeleteGraphPermanentlyUrl(graphId), + { + ...options, + method: "DELETE", + }, + ); +}; + +export const getDeleteV1DeleteGraphPermanentlyMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { graphId: string }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { graphId: string }, + TContext +> => { + const mutationKey = ["deleteV1DeleteGraphPermanently"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { graphId: string } + > = (props) => { + const { graphId } = props ?? {}; + + return deleteV1DeleteGraphPermanently(graphId, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type DeleteV1DeleteGraphPermanentlyMutationResult = NonNullable< + Awaited> +>; + +export type DeleteV1DeleteGraphPermanentlyMutationError = HTTPValidationError; + +/** + * @summary Delete graph permanently + */ +export const useDeleteV1DeleteGraphPermanently = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { graphId: string }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { graphId: string }, + TContext +> => { + const mutationOptions = + getDeleteV1DeleteGraphPermanentlyMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * @summary Update graph version + */ +export type putV1UpdateGraphVersionResponse200 = { + data: GraphModel; + status: 200; +}; + +export type putV1UpdateGraphVersionResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type putV1UpdateGraphVersionResponseComposite = + | putV1UpdateGraphVersionResponse200 + | putV1UpdateGraphVersionResponse422; + +export type putV1UpdateGraphVersionResponse = + putV1UpdateGraphVersionResponseComposite & { + headers: Headers; + }; + +export const getPutV1UpdateGraphVersionUrl = (graphId: string) => { + return `/api/graphs/${graphId}`; +}; + +export const putV1UpdateGraphVersion = async ( + graphId: string, + graph: Graph, + options?: RequestInit, +): Promise => { + return customMutator( + getPutV1UpdateGraphVersionUrl(graphId), + { + ...options, + method: "PUT", + headers: { "Content-Type": "application/json", ...options?.headers }, + body: JSON.stringify(graph), + }, + ); +}; + +export const getPutV1UpdateGraphVersionMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { graphId: string; data: Graph }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { graphId: string; data: Graph }, + TContext +> => { + const mutationKey = ["putV1UpdateGraphVersion"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { graphId: string; data: Graph } + > = (props) => { + const { graphId, data } = props ?? {}; + + return putV1UpdateGraphVersion(graphId, data, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PutV1UpdateGraphVersionMutationResult = NonNullable< + Awaited> +>; +export type PutV1UpdateGraphVersionMutationBody = Graph; +export type PutV1UpdateGraphVersionMutationError = HTTPValidationError; + +/** + * @summary Update graph version + */ +export const usePutV1UpdateGraphVersion = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { graphId: string; data: Graph }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { graphId: string; data: Graph }, + TContext +> => { + const mutationOptions = getPutV1UpdateGraphVersionMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * @summary Get all graph versions + */ +export type getV1GetAllGraphVersionsResponse200 = { + data: GraphModel[]; + status: 200; +}; + +export type getV1GetAllGraphVersionsResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type getV1GetAllGraphVersionsResponseComposite = + | getV1GetAllGraphVersionsResponse200 + | getV1GetAllGraphVersionsResponse422; + +export type getV1GetAllGraphVersionsResponse = + getV1GetAllGraphVersionsResponseComposite & { + headers: Headers; + }; + +export const getGetV1GetAllGraphVersionsUrl = (graphId: string) => { + return `/api/graphs/${graphId}/versions`; +}; + +export const getV1GetAllGraphVersions = async ( + graphId: string, + options?: RequestInit, +): Promise => { + return customMutator( + getGetV1GetAllGraphVersionsUrl(graphId), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV1GetAllGraphVersionsQueryKey = (graphId: string) => { + return [`/api/graphs/${graphId}/versions`] as const; +}; + +export const getGetV1GetAllGraphVersionsQueryOptions = < + TData = Awaited>, + TError = HTTPValidationError, +>( + graphId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, +) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = + queryOptions?.queryKey ?? getGetV1GetAllGraphVersionsQueryKey(graphId); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => + getV1GetAllGraphVersions(graphId, { signal, ...requestOptions }); + + return { + queryKey, + queryFn, + enabled: !!graphId, + ...queryOptions, + } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV1GetAllGraphVersionsQueryResult = NonNullable< + Awaited> +>; +export type GetV1GetAllGraphVersionsQueryError = HTTPValidationError; + +export function useGetV1GetAllGraphVersions< + TData = Awaited>, + TError = HTTPValidationError, +>( + graphId: string, + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1GetAllGraphVersions< + TData = Awaited>, + TError = HTTPValidationError, +>( + graphId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1GetAllGraphVersions< + TData = Awaited>, + TError = HTTPValidationError, +>( + graphId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary Get all graph versions + */ + +export function useGetV1GetAllGraphVersions< + TData = Awaited>, + TError = HTTPValidationError, +>( + graphId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV1GetAllGraphVersionsQueryOptions( + graphId, + options, + ); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * @summary Set active graph version + */ +export type putV1SetActiveGraphVersionResponse200 = { + data: unknown; + status: 200; +}; + +export type putV1SetActiveGraphVersionResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type putV1SetActiveGraphVersionResponseComposite = + | putV1SetActiveGraphVersionResponse200 + | putV1SetActiveGraphVersionResponse422; + +export type putV1SetActiveGraphVersionResponse = + putV1SetActiveGraphVersionResponseComposite & { + headers: Headers; + }; + +export const getPutV1SetActiveGraphVersionUrl = (graphId: string) => { + return `/api/graphs/${graphId}/versions/active`; +}; + +export const putV1SetActiveGraphVersion = async ( + graphId: string, + setGraphActiveVersion: SetGraphActiveVersion, + options?: RequestInit, +): Promise => { + return customMutator( + getPutV1SetActiveGraphVersionUrl(graphId), + { + ...options, + method: "PUT", + headers: { "Content-Type": "application/json", ...options?.headers }, + body: JSON.stringify(setGraphActiveVersion), + }, + ); +}; + +export const getPutV1SetActiveGraphVersionMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { graphId: string; data: SetGraphActiveVersion }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { graphId: string; data: SetGraphActiveVersion }, + TContext +> => { + const mutationKey = ["putV1SetActiveGraphVersion"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { graphId: string; data: SetGraphActiveVersion } + > = (props) => { + const { graphId, data } = props ?? {}; + + return putV1SetActiveGraphVersion(graphId, data, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PutV1SetActiveGraphVersionMutationResult = NonNullable< + Awaited> +>; +export type PutV1SetActiveGraphVersionMutationBody = SetGraphActiveVersion; +export type PutV1SetActiveGraphVersionMutationError = HTTPValidationError; + +/** + * @summary Set active graph version + */ +export const usePutV1SetActiveGraphVersion = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { graphId: string; data: SetGraphActiveVersion }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { graphId: string; data: SetGraphActiveVersion }, + TContext +> => { + const mutationOptions = getPutV1SetActiveGraphVersionMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * @summary Execute graph agent + */ +export type postV1ExecuteGraphAgentResponse200 = { + data: ExecuteGraphResponse; + status: 200; +}; + +export type postV1ExecuteGraphAgentResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type postV1ExecuteGraphAgentResponseComposite = + | postV1ExecuteGraphAgentResponse200 + | postV1ExecuteGraphAgentResponse422; + +export type postV1ExecuteGraphAgentResponse = + postV1ExecuteGraphAgentResponseComposite & { + headers: Headers; + }; + +export const getPostV1ExecuteGraphAgentUrl = ( + graphId: string, + graphVersion: number | null, + params?: PostV1ExecuteGraphAgentParams, +) => { + const normalizedParams = new URLSearchParams(); + + Object.entries(params || {}).forEach(([key, value]) => { + if (value !== undefined) { + normalizedParams.append(key, value === null ? "null" : value.toString()); + } + }); + + const stringifiedParams = normalizedParams.toString(); + + return stringifiedParams.length > 0 + ? `/api/graphs/${graphId}/execute/${graphVersion}?${stringifiedParams}` + : `/api/graphs/${graphId}/execute/${graphVersion}`; +}; + +export const postV1ExecuteGraphAgent = async ( + graphId: string, + graphVersion: number | null, + bodyPostV1ExecuteGraphAgent: BodyPostV1ExecuteGraphAgent, + params?: PostV1ExecuteGraphAgentParams, + options?: RequestInit, +): Promise => { + return customMutator( + getPostV1ExecuteGraphAgentUrl(graphId, graphVersion, params), + { + ...options, + method: "POST", + headers: { "Content-Type": "application/json", ...options?.headers }, + body: JSON.stringify(bodyPostV1ExecuteGraphAgent), + }, + ); +}; + +export const getPostV1ExecuteGraphAgentMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { + graphId: string; + graphVersion: number | null; + data: BodyPostV1ExecuteGraphAgent; + params?: PostV1ExecuteGraphAgentParams; + }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { + graphId: string; + graphVersion: number | null; + data: BodyPostV1ExecuteGraphAgent; + params?: PostV1ExecuteGraphAgentParams; + }, + TContext +> => { + const mutationKey = ["postV1ExecuteGraphAgent"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { + graphId: string; + graphVersion: number | null; + data: BodyPostV1ExecuteGraphAgent; + params?: PostV1ExecuteGraphAgentParams; + } + > = (props) => { + const { graphId, graphVersion, data, params } = props ?? {}; + + return postV1ExecuteGraphAgent( + graphId, + graphVersion, + data, + params, + requestOptions, + ); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PostV1ExecuteGraphAgentMutationResult = NonNullable< + Awaited> +>; +export type PostV1ExecuteGraphAgentMutationBody = BodyPostV1ExecuteGraphAgent; +export type PostV1ExecuteGraphAgentMutationError = HTTPValidationError; + +/** + * @summary Execute graph agent + */ +export const usePostV1ExecuteGraphAgent = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { + graphId: string; + graphVersion: number | null; + data: BodyPostV1ExecuteGraphAgent; + params?: PostV1ExecuteGraphAgentParams; + }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { + graphId: string; + graphVersion: number | null; + data: BodyPostV1ExecuteGraphAgent; + params?: PostV1ExecuteGraphAgentParams; + }, + TContext +> => { + const mutationOptions = getPostV1ExecuteGraphAgentMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * @summary Stop graph execution + */ +export type postV1StopGraphExecutionResponse200 = { + data: GraphExecution; + status: 200; +}; + +export type postV1StopGraphExecutionResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type postV1StopGraphExecutionResponseComposite = + | postV1StopGraphExecutionResponse200 + | postV1StopGraphExecutionResponse422; + +export type postV1StopGraphExecutionResponse = + postV1StopGraphExecutionResponseComposite & { + headers: Headers; + }; + +export const getPostV1StopGraphExecutionUrl = ( + graphId: string, + graphExecId: string, +) => { + return `/api/graphs/${graphId}/executions/${graphExecId}/stop`; +}; + +export const postV1StopGraphExecution = async ( + graphId: string, + graphExecId: string, + options?: RequestInit, +): Promise => { + return customMutator( + getPostV1StopGraphExecutionUrl(graphId, graphExecId), + { + ...options, + method: "POST", + }, + ); +}; + +export const getPostV1StopGraphExecutionMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { graphId: string; graphExecId: string }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { graphId: string; graphExecId: string }, + TContext +> => { + const mutationKey = ["postV1StopGraphExecution"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { graphId: string; graphExecId: string } + > = (props) => { + const { graphId, graphExecId } = props ?? {}; + + return postV1StopGraphExecution(graphId, graphExecId, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PostV1StopGraphExecutionMutationResult = NonNullable< + Awaited> +>; + +export type PostV1StopGraphExecutionMutationError = HTTPValidationError; + +/** + * @summary Stop graph execution + */ +export const usePostV1StopGraphExecution = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { graphId: string; graphExecId: string }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { graphId: string; graphExecId: string }, + TContext +> => { + const mutationOptions = getPostV1StopGraphExecutionMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * @summary Get all executions + */ +export type getV1GetAllExecutionsResponse200 = { + data: GraphExecutionMeta[]; + status: 200; +}; + +export type getV1GetAllExecutionsResponseComposite = + getV1GetAllExecutionsResponse200; + +export type getV1GetAllExecutionsResponse = + getV1GetAllExecutionsResponseComposite & { + headers: Headers; + }; + +export const getGetV1GetAllExecutionsUrl = () => { + return `/api/executions`; +}; + +export const getV1GetAllExecutions = async ( + options?: RequestInit, +): Promise => { + return customMutator( + getGetV1GetAllExecutionsUrl(), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV1GetAllExecutionsQueryKey = () => { + return [`/api/executions`] as const; +}; + +export const getGetV1GetAllExecutionsQueryOptions = < + TData = Awaited>, + TError = unknown, +>(options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; +}) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = queryOptions?.queryKey ?? getGetV1GetAllExecutionsQueryKey(); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => getV1GetAllExecutions({ signal, ...requestOptions }); + + return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV1GetAllExecutionsQueryResult = NonNullable< + Awaited> +>; +export type GetV1GetAllExecutionsQueryError = unknown; + +export function useGetV1GetAllExecutions< + TData = Awaited>, + TError = unknown, +>( + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1GetAllExecutions< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1GetAllExecutions< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary Get all executions + */ + +export function useGetV1GetAllExecutions< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV1GetAllExecutionsQueryOptions(options); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * @summary Get graph executions + */ +export type getV1GetGraphExecutionsResponse200 = { + data: GraphExecutionMeta[]; + status: 200; +}; + +export type getV1GetGraphExecutionsResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type getV1GetGraphExecutionsResponseComposite = + | getV1GetGraphExecutionsResponse200 + | getV1GetGraphExecutionsResponse422; + +export type getV1GetGraphExecutionsResponse = + getV1GetGraphExecutionsResponseComposite & { + headers: Headers; + }; + +export const getGetV1GetGraphExecutionsUrl = (graphId: string) => { + return `/api/graphs/${graphId}/executions`; +}; + +export const getV1GetGraphExecutions = async ( + graphId: string, + options?: RequestInit, +): Promise => { + return customMutator( + getGetV1GetGraphExecutionsUrl(graphId), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV1GetGraphExecutionsQueryKey = (graphId: string) => { + return [`/api/graphs/${graphId}/executions`] as const; +}; + +export const getGetV1GetGraphExecutionsQueryOptions = < + TData = Awaited>, + TError = HTTPValidationError, +>( + graphId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, +) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = + queryOptions?.queryKey ?? getGetV1GetGraphExecutionsQueryKey(graphId); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => + getV1GetGraphExecutions(graphId, { signal, ...requestOptions }); + + return { + queryKey, + queryFn, + enabled: !!graphId, + ...queryOptions, + } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV1GetGraphExecutionsQueryResult = NonNullable< + Awaited> +>; +export type GetV1GetGraphExecutionsQueryError = HTTPValidationError; + +export function useGetV1GetGraphExecutions< + TData = Awaited>, + TError = HTTPValidationError, +>( + graphId: string, + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1GetGraphExecutions< + TData = Awaited>, + TError = HTTPValidationError, +>( + graphId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1GetGraphExecutions< + TData = Awaited>, + TError = HTTPValidationError, +>( + graphId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary Get graph executions + */ + +export function useGetV1GetGraphExecutions< + TData = Awaited>, + TError = HTTPValidationError, +>( + graphId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV1GetGraphExecutionsQueryOptions(graphId, options); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * @summary Get execution details + */ +export type getV1GetExecutionDetailsResponse200 = { + data: GetV1GetExecutionDetails200; + status: 200; +}; + +export type getV1GetExecutionDetailsResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type getV1GetExecutionDetailsResponseComposite = + | getV1GetExecutionDetailsResponse200 + | getV1GetExecutionDetailsResponse422; + +export type getV1GetExecutionDetailsResponse = + getV1GetExecutionDetailsResponseComposite & { + headers: Headers; + }; + +export const getGetV1GetExecutionDetailsUrl = ( + graphId: string, + graphExecId: string, +) => { + return `/api/graphs/${graphId}/executions/${graphExecId}`; +}; + +export const getV1GetExecutionDetails = async ( + graphId: string, + graphExecId: string, + options?: RequestInit, +): Promise => { + return customMutator( + getGetV1GetExecutionDetailsUrl(graphId, graphExecId), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV1GetExecutionDetailsQueryKey = ( + graphId: string, + graphExecId: string, +) => { + return [`/api/graphs/${graphId}/executions/${graphExecId}`] as const; +}; + +export const getGetV1GetExecutionDetailsQueryOptions = < + TData = Awaited>, + TError = HTTPValidationError, +>( + graphId: string, + graphExecId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, +) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = + queryOptions?.queryKey ?? + getGetV1GetExecutionDetailsQueryKey(graphId, graphExecId); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => + getV1GetExecutionDetails(graphId, graphExecId, { + signal, + ...requestOptions, + }); + + return { + queryKey, + queryFn, + enabled: !!(graphId && graphExecId), + ...queryOptions, + } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV1GetExecutionDetailsQueryResult = NonNullable< + Awaited> +>; +export type GetV1GetExecutionDetailsQueryError = HTTPValidationError; + +export function useGetV1GetExecutionDetails< + TData = Awaited>, + TError = HTTPValidationError, +>( + graphId: string, + graphExecId: string, + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1GetExecutionDetails< + TData = Awaited>, + TError = HTTPValidationError, +>( + graphId: string, + graphExecId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1GetExecutionDetails< + TData = Awaited>, + TError = HTTPValidationError, +>( + graphId: string, + graphExecId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary Get execution details + */ + +export function useGetV1GetExecutionDetails< + TData = Awaited>, + TError = HTTPValidationError, +>( + graphId: string, + graphExecId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV1GetExecutionDetailsQueryOptions( + graphId, + graphExecId, + options, + ); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * @summary Delete graph execution + */ +export type deleteV1DeleteGraphExecutionResponse204 = { + data: void; + status: 204; +}; + +export type deleteV1DeleteGraphExecutionResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type deleteV1DeleteGraphExecutionResponseComposite = + | deleteV1DeleteGraphExecutionResponse204 + | deleteV1DeleteGraphExecutionResponse422; + +export type deleteV1DeleteGraphExecutionResponse = + deleteV1DeleteGraphExecutionResponseComposite & { + headers: Headers; + }; + +export const getDeleteV1DeleteGraphExecutionUrl = (graphExecId: string) => { + return `/api/executions/${graphExecId}`; +}; + +export const deleteV1DeleteGraphExecution = async ( + graphExecId: string, + options?: RequestInit, +): Promise => { + return customMutator( + getDeleteV1DeleteGraphExecutionUrl(graphExecId), + { + ...options, + method: "DELETE", + }, + ); +}; + +export const getDeleteV1DeleteGraphExecutionMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { graphExecId: string }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { graphExecId: string }, + TContext +> => { + const mutationKey = ["deleteV1DeleteGraphExecution"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { graphExecId: string } + > = (props) => { + const { graphExecId } = props ?? {}; + + return deleteV1DeleteGraphExecution(graphExecId, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type DeleteV1DeleteGraphExecutionMutationResult = NonNullable< + Awaited> +>; + +export type DeleteV1DeleteGraphExecutionMutationError = HTTPValidationError; + +/** + * @summary Delete graph execution + */ +export const useDeleteV1DeleteGraphExecution = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { graphExecId: string }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { graphExecId: string }, + TContext +> => { + const mutationOptions = + getDeleteV1DeleteGraphExecutionMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/endpoints/health/health.ts b/autogpt_platform/frontend/src/app/api/__generated__/endpoints/health/health.ts new file mode 100644 index 0000000000..3ea4b5be7b --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/endpoints/health/health.ts @@ -0,0 +1,187 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import { useQuery } from "@tanstack/react-query"; +import type { + DataTag, + DefinedInitialDataOptions, + DefinedUseQueryResult, + QueryClient, + QueryFunction, + QueryKey, + UndefinedInitialDataOptions, + UseQueryOptions, + UseQueryResult, +} from "@tanstack/react-query"; + +import { customMutator } from "../../../mutators/custom-mutator"; + +type SecondParameter unknown> = Parameters[1]; + +/** + * @summary Health + */ +export type getHealthHealthResponse200 = { + data: unknown; + status: 200; +}; + +export type getHealthHealthResponseComposite = getHealthHealthResponse200; + +export type getHealthHealthResponse = getHealthHealthResponseComposite & { + headers: Headers; +}; + +export const getGetHealthHealthUrl = () => { + return `/health`; +}; + +export const getHealthHealth = async ( + options?: RequestInit, +): Promise => { + return customMutator(getGetHealthHealthUrl(), { + ...options, + method: "GET", + }); +}; + +export const getGetHealthHealthQueryKey = () => { + return [`/health`] as const; +}; + +export const getGetHealthHealthQueryOptions = < + TData = Awaited>, + TError = unknown, +>(options?: { + query?: Partial< + UseQueryOptions>, TError, TData> + >; + request?: SecondParameter; +}) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = queryOptions?.queryKey ?? getGetHealthHealthQueryKey(); + + const queryFn: QueryFunction>> = ({ + signal, + }) => getHealthHealth({ signal, ...requestOptions }); + + return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetHealthHealthQueryResult = NonNullable< + Awaited> +>; +export type GetHealthHealthQueryError = unknown; + +export function useGetHealthHealth< + TData = Awaited>, + TError = unknown, +>( + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetHealthHealth< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetHealthHealth< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary Health + */ + +export function useGetHealthHealth< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetHealthHealthQueryOptions(options); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/endpoints/integrations/integrations.ts b/autogpt_platform/frontend/src/app/api/__generated__/endpoints/integrations/integrations.ts new file mode 100644 index 0000000000..bff97a64d4 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/endpoints/integrations/integrations.ts @@ -0,0 +1,1423 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import { useMutation, useQuery } from "@tanstack/react-query"; +import type { + DataTag, + DefinedInitialDataOptions, + DefinedUseQueryResult, + MutationFunction, + QueryClient, + QueryFunction, + QueryKey, + UndefinedInitialDataOptions, + UseMutationOptions, + UseMutationResult, + UseQueryOptions, + UseQueryResult, +} from "@tanstack/react-query"; + +import type { BodyPostV1Callback } from "../../models/bodyPostV1Callback"; + +import type { CredentialsMetaResponse } from "../../models/credentialsMetaResponse"; + +import type { DeleteV1DeleteCredentials200 } from "../../models/deleteV1DeleteCredentials200"; + +import type { DeleteV1DeleteCredentialsParams } from "../../models/deleteV1DeleteCredentialsParams"; + +import type { GetV1GetCredential200 } from "../../models/getV1GetCredential200"; + +import type { GetV1LoginParams } from "../../models/getV1LoginParams"; + +import type { HTTPValidationError } from "../../models/hTTPValidationError"; + +import type { LoginResponse } from "../../models/loginResponse"; + +import type { PostV1CreateCredentials201 } from "../../models/postV1CreateCredentials201"; + +import type { PostV1CreateCredentialsBody } from "../../models/postV1CreateCredentialsBody"; + +import type { ProviderName } from "../../models/providerName"; + +import { customMutator } from "../../../mutators/custom-mutator"; + +type SecondParameter unknown> = Parameters[1]; + +/** + * @summary Login + */ +export type getV1LoginResponse200 = { + data: LoginResponse; + status: 200; +}; + +export type getV1LoginResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type getV1LoginResponseComposite = + | getV1LoginResponse200 + | getV1LoginResponse422; + +export type getV1LoginResponse = getV1LoginResponseComposite & { + headers: Headers; +}; + +export const getGetV1LoginUrl = ( + provider: ProviderName, + params?: GetV1LoginParams, +) => { + const normalizedParams = new URLSearchParams(); + + Object.entries(params || {}).forEach(([key, value]) => { + if (value !== undefined) { + normalizedParams.append(key, value === null ? "null" : value.toString()); + } + }); + + const stringifiedParams = normalizedParams.toString(); + + return stringifiedParams.length > 0 + ? `/api/integrations/${provider}/login?${stringifiedParams}` + : `/api/integrations/${provider}/login`; +}; + +export const getV1Login = async ( + provider: ProviderName, + params?: GetV1LoginParams, + options?: RequestInit, +): Promise => { + return customMutator(getGetV1LoginUrl(provider, params), { + ...options, + method: "GET", + }); +}; + +export const getGetV1LoginQueryKey = ( + provider: ProviderName, + params?: GetV1LoginParams, +) => { + return [ + `/api/integrations/${provider}/login`, + ...(params ? [params] : []), + ] as const; +}; + +export const getGetV1LoginQueryOptions = < + TData = Awaited>, + TError = HTTPValidationError, +>( + provider: ProviderName, + params?: GetV1LoginParams, + options?: { + query?: Partial< + UseQueryOptions>, TError, TData> + >; + request?: SecondParameter; + }, +) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = + queryOptions?.queryKey ?? getGetV1LoginQueryKey(provider, params); + + const queryFn: QueryFunction>> = ({ + signal, + }) => getV1Login(provider, params, { signal, ...requestOptions }); + + return { + queryKey, + queryFn, + enabled: !!provider, + ...queryOptions, + } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV1LoginQueryResult = NonNullable< + Awaited> +>; +export type GetV1LoginQueryError = HTTPValidationError; + +export function useGetV1Login< + TData = Awaited>, + TError = HTTPValidationError, +>( + provider: ProviderName, + params: undefined | GetV1LoginParams, + options: { + query: Partial< + UseQueryOptions>, TError, TData> + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1Login< + TData = Awaited>, + TError = HTTPValidationError, +>( + provider: ProviderName, + params?: GetV1LoginParams, + options?: { + query?: Partial< + UseQueryOptions>, TError, TData> + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1Login< + TData = Awaited>, + TError = HTTPValidationError, +>( + provider: ProviderName, + params?: GetV1LoginParams, + options?: { + query?: Partial< + UseQueryOptions>, TError, TData> + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary Login + */ + +export function useGetV1Login< + TData = Awaited>, + TError = HTTPValidationError, +>( + provider: ProviderName, + params?: GetV1LoginParams, + options?: { + query?: Partial< + UseQueryOptions>, TError, TData> + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV1LoginQueryOptions(provider, params, options); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * @summary Callback + */ +export type postV1CallbackResponse200 = { + data: CredentialsMetaResponse; + status: 200; +}; + +export type postV1CallbackResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type postV1CallbackResponseComposite = + | postV1CallbackResponse200 + | postV1CallbackResponse422; + +export type postV1CallbackResponse = postV1CallbackResponseComposite & { + headers: Headers; +}; + +export const getPostV1CallbackUrl = (provider: ProviderName) => { + return `/api/integrations/${provider}/callback`; +}; + +export const postV1Callback = async ( + provider: ProviderName, + bodyPostV1Callback: BodyPostV1Callback, + options?: RequestInit, +): Promise => { + return customMutator(getPostV1CallbackUrl(provider), { + ...options, + method: "POST", + headers: { "Content-Type": "application/json", ...options?.headers }, + body: JSON.stringify(bodyPostV1Callback), + }); +}; + +export const getPostV1CallbackMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { provider: ProviderName; data: BodyPostV1Callback }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { provider: ProviderName; data: BodyPostV1Callback }, + TContext +> => { + const mutationKey = ["postV1Callback"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { provider: ProviderName; data: BodyPostV1Callback } + > = (props) => { + const { provider, data } = props ?? {}; + + return postV1Callback(provider, data, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PostV1CallbackMutationResult = NonNullable< + Awaited> +>; +export type PostV1CallbackMutationBody = BodyPostV1Callback; +export type PostV1CallbackMutationError = HTTPValidationError; + +/** + * @summary Callback + */ +export const usePostV1Callback = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { provider: ProviderName; data: BodyPostV1Callback }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { provider: ProviderName; data: BodyPostV1Callback }, + TContext +> => { + const mutationOptions = getPostV1CallbackMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * @summary List Credentials + */ +export type getV1ListCredentialsResponse200 = { + data: CredentialsMetaResponse[]; + status: 200; +}; + +export type getV1ListCredentialsResponseComposite = + getV1ListCredentialsResponse200; + +export type getV1ListCredentialsResponse = + getV1ListCredentialsResponseComposite & { + headers: Headers; + }; + +export const getGetV1ListCredentialsUrl = () => { + return `/api/integrations/credentials`; +}; + +export const getV1ListCredentials = async ( + options?: RequestInit, +): Promise => { + return customMutator( + getGetV1ListCredentialsUrl(), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV1ListCredentialsQueryKey = () => { + return [`/api/integrations/credentials`] as const; +}; + +export const getGetV1ListCredentialsQueryOptions = < + TData = Awaited>, + TError = unknown, +>(options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; +}) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = queryOptions?.queryKey ?? getGetV1ListCredentialsQueryKey(); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => getV1ListCredentials({ signal, ...requestOptions }); + + return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV1ListCredentialsQueryResult = NonNullable< + Awaited> +>; +export type GetV1ListCredentialsQueryError = unknown; + +export function useGetV1ListCredentials< + TData = Awaited>, + TError = unknown, +>( + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1ListCredentials< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1ListCredentials< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary List Credentials + */ + +export function useGetV1ListCredentials< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV1ListCredentialsQueryOptions(options); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * @summary List Credentials By Provider + */ +export type getV1ListCredentialsByProviderResponse200 = { + data: CredentialsMetaResponse[]; + status: 200; +}; + +export type getV1ListCredentialsByProviderResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type getV1ListCredentialsByProviderResponseComposite = + | getV1ListCredentialsByProviderResponse200 + | getV1ListCredentialsByProviderResponse422; + +export type getV1ListCredentialsByProviderResponse = + getV1ListCredentialsByProviderResponseComposite & { + headers: Headers; + }; + +export const getGetV1ListCredentialsByProviderUrl = ( + provider: ProviderName, +) => { + return `/api/integrations/${provider}/credentials`; +}; + +export const getV1ListCredentialsByProvider = async ( + provider: ProviderName, + options?: RequestInit, +): Promise => { + return customMutator( + getGetV1ListCredentialsByProviderUrl(provider), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV1ListCredentialsByProviderQueryKey = ( + provider: ProviderName, +) => { + return [`/api/integrations/${provider}/credentials`] as const; +}; + +export const getGetV1ListCredentialsByProviderQueryOptions = < + TData = Awaited>, + TError = HTTPValidationError, +>( + provider: ProviderName, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, +) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = + queryOptions?.queryKey ?? + getGetV1ListCredentialsByProviderQueryKey(provider); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => + getV1ListCredentialsByProvider(provider, { signal, ...requestOptions }); + + return { + queryKey, + queryFn, + enabled: !!provider, + ...queryOptions, + } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV1ListCredentialsByProviderQueryResult = NonNullable< + Awaited> +>; +export type GetV1ListCredentialsByProviderQueryError = HTTPValidationError; + +export function useGetV1ListCredentialsByProvider< + TData = Awaited>, + TError = HTTPValidationError, +>( + provider: ProviderName, + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1ListCredentialsByProvider< + TData = Awaited>, + TError = HTTPValidationError, +>( + provider: ProviderName, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1ListCredentialsByProvider< + TData = Awaited>, + TError = HTTPValidationError, +>( + provider: ProviderName, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary List Credentials By Provider + */ + +export function useGetV1ListCredentialsByProvider< + TData = Awaited>, + TError = HTTPValidationError, +>( + provider: ProviderName, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV1ListCredentialsByProviderQueryOptions( + provider, + options, + ); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * @summary Create Credentials + */ +export type postV1CreateCredentialsResponse201 = { + data: PostV1CreateCredentials201; + status: 201; +}; + +export type postV1CreateCredentialsResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type postV1CreateCredentialsResponseComposite = + | postV1CreateCredentialsResponse201 + | postV1CreateCredentialsResponse422; + +export type postV1CreateCredentialsResponse = + postV1CreateCredentialsResponseComposite & { + headers: Headers; + }; + +export const getPostV1CreateCredentialsUrl = (provider: ProviderName) => { + return `/api/integrations/${provider}/credentials`; +}; + +export const postV1CreateCredentials = async ( + provider: ProviderName, + postV1CreateCredentialsBody: PostV1CreateCredentialsBody, + options?: RequestInit, +): Promise => { + return customMutator( + getPostV1CreateCredentialsUrl(provider), + { + ...options, + method: "POST", + headers: { "Content-Type": "application/json", ...options?.headers }, + body: JSON.stringify(postV1CreateCredentialsBody), + }, + ); +}; + +export const getPostV1CreateCredentialsMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { provider: ProviderName; data: PostV1CreateCredentialsBody }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { provider: ProviderName; data: PostV1CreateCredentialsBody }, + TContext +> => { + const mutationKey = ["postV1CreateCredentials"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { provider: ProviderName; data: PostV1CreateCredentialsBody } + > = (props) => { + const { provider, data } = props ?? {}; + + return postV1CreateCredentials(provider, data, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PostV1CreateCredentialsMutationResult = NonNullable< + Awaited> +>; +export type PostV1CreateCredentialsMutationBody = PostV1CreateCredentialsBody; +export type PostV1CreateCredentialsMutationError = HTTPValidationError; + +/** + * @summary Create Credentials + */ +export const usePostV1CreateCredentials = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { provider: ProviderName; data: PostV1CreateCredentialsBody }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { provider: ProviderName; data: PostV1CreateCredentialsBody }, + TContext +> => { + const mutationOptions = getPostV1CreateCredentialsMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * @summary Get Credential + */ +export type getV1GetCredentialResponse200 = { + data: GetV1GetCredential200; + status: 200; +}; + +export type getV1GetCredentialResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type getV1GetCredentialResponseComposite = + | getV1GetCredentialResponse200 + | getV1GetCredentialResponse422; + +export type getV1GetCredentialResponse = getV1GetCredentialResponseComposite & { + headers: Headers; +}; + +export const getGetV1GetCredentialUrl = ( + provider: ProviderName, + credId: string, +) => { + return `/api/integrations/${provider}/credentials/${credId}`; +}; + +export const getV1GetCredential = async ( + provider: ProviderName, + credId: string, + options?: RequestInit, +): Promise => { + return customMutator( + getGetV1GetCredentialUrl(provider, credId), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV1GetCredentialQueryKey = ( + provider: ProviderName, + credId: string, +) => { + return [`/api/integrations/${provider}/credentials/${credId}`] as const; +}; + +export const getGetV1GetCredentialQueryOptions = < + TData = Awaited>, + TError = HTTPValidationError, +>( + provider: ProviderName, + credId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, +) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = + queryOptions?.queryKey ?? getGetV1GetCredentialQueryKey(provider, credId); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => + getV1GetCredential(provider, credId, { signal, ...requestOptions }); + + return { + queryKey, + queryFn, + enabled: !!(provider && credId), + ...queryOptions, + } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV1GetCredentialQueryResult = NonNullable< + Awaited> +>; +export type GetV1GetCredentialQueryError = HTTPValidationError; + +export function useGetV1GetCredential< + TData = Awaited>, + TError = HTTPValidationError, +>( + provider: ProviderName, + credId: string, + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1GetCredential< + TData = Awaited>, + TError = HTTPValidationError, +>( + provider: ProviderName, + credId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1GetCredential< + TData = Awaited>, + TError = HTTPValidationError, +>( + provider: ProviderName, + credId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary Get Credential + */ + +export function useGetV1GetCredential< + TData = Awaited>, + TError = HTTPValidationError, +>( + provider: ProviderName, + credId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV1GetCredentialQueryOptions( + provider, + credId, + options, + ); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * @summary Delete Credentials + */ +export type deleteV1DeleteCredentialsResponse200 = { + data: DeleteV1DeleteCredentials200; + status: 200; +}; + +export type deleteV1DeleteCredentialsResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type deleteV1DeleteCredentialsResponseComposite = + | deleteV1DeleteCredentialsResponse200 + | deleteV1DeleteCredentialsResponse422; + +export type deleteV1DeleteCredentialsResponse = + deleteV1DeleteCredentialsResponseComposite & { + headers: Headers; + }; + +export const getDeleteV1DeleteCredentialsUrl = ( + provider: ProviderName, + credId: string, + params?: DeleteV1DeleteCredentialsParams, +) => { + const normalizedParams = new URLSearchParams(); + + Object.entries(params || {}).forEach(([key, value]) => { + if (value !== undefined) { + normalizedParams.append(key, value === null ? "null" : value.toString()); + } + }); + + const stringifiedParams = normalizedParams.toString(); + + return stringifiedParams.length > 0 + ? `/api/integrations/${provider}/credentials/${credId}?${stringifiedParams}` + : `/api/integrations/${provider}/credentials/${credId}`; +}; + +export const deleteV1DeleteCredentials = async ( + provider: ProviderName, + credId: string, + params?: DeleteV1DeleteCredentialsParams, + options?: RequestInit, +): Promise => { + return customMutator( + getDeleteV1DeleteCredentialsUrl(provider, credId, params), + { + ...options, + method: "DELETE", + }, + ); +}; + +export const getDeleteV1DeleteCredentialsMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { + provider: ProviderName; + credId: string; + params?: DeleteV1DeleteCredentialsParams; + }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { + provider: ProviderName; + credId: string; + params?: DeleteV1DeleteCredentialsParams; + }, + TContext +> => { + const mutationKey = ["deleteV1DeleteCredentials"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { + provider: ProviderName; + credId: string; + params?: DeleteV1DeleteCredentialsParams; + } + > = (props) => { + const { provider, credId, params } = props ?? {}; + + return deleteV1DeleteCredentials(provider, credId, params, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type DeleteV1DeleteCredentialsMutationResult = NonNullable< + Awaited> +>; + +export type DeleteV1DeleteCredentialsMutationError = HTTPValidationError; + +/** + * @summary Delete Credentials + */ +export const useDeleteV1DeleteCredentials = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { + provider: ProviderName; + credId: string; + params?: DeleteV1DeleteCredentialsParams; + }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { + provider: ProviderName; + credId: string; + params?: DeleteV1DeleteCredentialsParams; + }, + TContext +> => { + const mutationOptions = getDeleteV1DeleteCredentialsMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * @summary Webhook Ingress Generic + */ +export type postV1WebhookIngressGenericResponse200 = { + data: unknown; + status: 200; +}; + +export type postV1WebhookIngressGenericResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type postV1WebhookIngressGenericResponseComposite = + | postV1WebhookIngressGenericResponse200 + | postV1WebhookIngressGenericResponse422; + +export type postV1WebhookIngressGenericResponse = + postV1WebhookIngressGenericResponseComposite & { + headers: Headers; + }; + +export const getPostV1WebhookIngressGenericUrl = ( + provider: ProviderName, + webhookId: string, +) => { + return `/api/integrations/${provider}/webhooks/${webhookId}/ingress`; +}; + +export const postV1WebhookIngressGeneric = async ( + provider: ProviderName, + webhookId: string, + options?: RequestInit, +): Promise => { + return customMutator( + getPostV1WebhookIngressGenericUrl(provider, webhookId), + { + ...options, + method: "POST", + }, + ); +}; + +export const getPostV1WebhookIngressGenericMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { provider: ProviderName; webhookId: string }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { provider: ProviderName; webhookId: string }, + TContext +> => { + const mutationKey = ["postV1WebhookIngressGeneric"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { provider: ProviderName; webhookId: string } + > = (props) => { + const { provider, webhookId } = props ?? {}; + + return postV1WebhookIngressGeneric(provider, webhookId, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PostV1WebhookIngressGenericMutationResult = NonNullable< + Awaited> +>; + +export type PostV1WebhookIngressGenericMutationError = HTTPValidationError; + +/** + * @summary Webhook Ingress Generic + */ +export const usePostV1WebhookIngressGeneric = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { provider: ProviderName; webhookId: string }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { provider: ProviderName; webhookId: string }, + TContext +> => { + const mutationOptions = + getPostV1WebhookIngressGenericMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * @summary Webhook Ping + */ +export type postV1WebhookPingResponse200 = { + data: unknown; + status: 200; +}; + +export type postV1WebhookPingResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type postV1WebhookPingResponseComposite = + | postV1WebhookPingResponse200 + | postV1WebhookPingResponse422; + +export type postV1WebhookPingResponse = postV1WebhookPingResponseComposite & { + headers: Headers; +}; + +export const getPostV1WebhookPingUrl = (webhookId: string) => { + return `/api/integrations/webhooks/${webhookId}/ping`; +}; + +export const postV1WebhookPing = async ( + webhookId: string, + options?: RequestInit, +): Promise => { + return customMutator( + getPostV1WebhookPingUrl(webhookId), + { + ...options, + method: "POST", + }, + ); +}; + +export const getPostV1WebhookPingMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { webhookId: string }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { webhookId: string }, + TContext +> => { + const mutationKey = ["postV1WebhookPing"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { webhookId: string } + > = (props) => { + const { webhookId } = props ?? {}; + + return postV1WebhookPing(webhookId, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PostV1WebhookPingMutationResult = NonNullable< + Awaited> +>; + +export type PostV1WebhookPingMutationError = HTTPValidationError; + +/** + * @summary Webhook Ping + */ +export const usePostV1WebhookPing = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { webhookId: string }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { webhookId: string }, + TContext +> => { + const mutationOptions = getPostV1WebhookPingMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/endpoints/library/library.ts b/autogpt_platform/frontend/src/app/api/__generated__/endpoints/library/library.ts new file mode 100644 index 0000000000..6560be16d7 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/endpoints/library/library.ts @@ -0,0 +1,1704 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import { useInfiniteQuery, useMutation, useQuery } from "@tanstack/react-query"; +import type { + DataTag, + DefinedInitialDataOptions, + DefinedUseInfiniteQueryResult, + DefinedUseQueryResult, + InfiniteData, + MutationFunction, + QueryClient, + QueryFunction, + QueryKey, + UndefinedInitialDataOptions, + UseInfiniteQueryOptions, + UseInfiniteQueryResult, + UseMutationOptions, + UseMutationResult, + UseQueryOptions, + UseQueryResult, +} from "@tanstack/react-query"; + +import type { BodyPostV2AddMarketplaceAgent } from "../../models/bodyPostV2AddMarketplaceAgent"; + +import type { GetV2GetAgentByStoreId200 } from "../../models/getV2GetAgentByStoreId200"; + +import type { GetV2GetLibraryAgentByGraphIdParams } from "../../models/getV2GetLibraryAgentByGraphIdParams"; + +import type { GetV2ListLibraryAgentsParams } from "../../models/getV2ListLibraryAgentsParams"; + +import type { HTTPValidationError } from "../../models/hTTPValidationError"; + +import type { LibraryAgent } from "../../models/libraryAgent"; + +import type { LibraryAgentPreset } from "../../models/libraryAgentPreset"; + +import type { LibraryAgentResponse } from "../../models/libraryAgentResponse"; + +import type { LibraryAgentUpdateRequest } from "../../models/libraryAgentUpdateRequest"; + +import type { TriggeredPresetSetupParams } from "../../models/triggeredPresetSetupParams"; + +import { customMutator } from "../../../mutators/custom-mutator"; + +type SecondParameter unknown> = Parameters[1]; + +/** + * Get all agents in the user's library (both created and saved). + +Args: + user_id: ID of the authenticated user. + search_term: Optional search term to filter agents by name/description. + filter_by: List of filters to apply (favorites, created by user). + sort_by: List of sorting criteria (created date, updated date). + page: Page number to retrieve. + page_size: Number of agents per page. + +Returns: + A LibraryAgentResponse containing agents and pagination metadata. + +Raises: + HTTPException: If a server/database error occurs. + * @summary List Library Agents + */ +export type getV2ListLibraryAgentsResponse200 = { + data: LibraryAgentResponse; + status: 200; +}; + +export type getV2ListLibraryAgentsResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type getV2ListLibraryAgentsResponseComposite = + | getV2ListLibraryAgentsResponse200 + | getV2ListLibraryAgentsResponse422; + +export type getV2ListLibraryAgentsResponse = + getV2ListLibraryAgentsResponseComposite & { + headers: Headers; + }; + +export const getGetV2ListLibraryAgentsUrl = ( + params?: GetV2ListLibraryAgentsParams, +) => { + const normalizedParams = new URLSearchParams(); + + Object.entries(params || {}).forEach(([key, value]) => { + if (value !== undefined) { + normalizedParams.append(key, value === null ? "null" : value.toString()); + } + }); + + const stringifiedParams = normalizedParams.toString(); + + return stringifiedParams.length > 0 + ? `/api/library/agents?${stringifiedParams}` + : `/api/library/agents`; +}; + +export const getV2ListLibraryAgents = async ( + params?: GetV2ListLibraryAgentsParams, + options?: RequestInit, +): Promise => { + return customMutator( + getGetV2ListLibraryAgentsUrl(params), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV2ListLibraryAgentsQueryKey = ( + params?: GetV2ListLibraryAgentsParams, +) => { + return [`/api/library/agents`, ...(params ? [params] : [])] as const; +}; + +export const getGetV2ListLibraryAgentsInfiniteQueryOptions = < + TData = InfiniteData< + Awaited>, + GetV2ListLibraryAgentsParams["page"] + >, + TError = HTTPValidationError, +>( + params?: GetV2ListLibraryAgentsParams, + options?: { + query?: Partial< + UseInfiniteQueryOptions< + Awaited>, + TError, + TData, + QueryKey, + GetV2ListLibraryAgentsParams["page"] + > + >; + request?: SecondParameter; + }, +) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = + queryOptions?.queryKey ?? getGetV2ListLibraryAgentsQueryKey(params); + + const queryFn: QueryFunction< + Awaited>, + QueryKey, + GetV2ListLibraryAgentsParams["page"] + > = ({ signal, pageParam }) => + getV2ListLibraryAgents( + { ...params, page: pageParam || params?.["page"] }, + { signal, ...requestOptions }, + ); + + return { queryKey, queryFn, ...queryOptions } as UseInfiniteQueryOptions< + Awaited>, + TError, + TData, + QueryKey, + GetV2ListLibraryAgentsParams["page"] + > & { queryKey: DataTag }; +}; + +export type GetV2ListLibraryAgentsInfiniteQueryResult = NonNullable< + Awaited> +>; +export type GetV2ListLibraryAgentsInfiniteQueryError = HTTPValidationError; + +export function useGetV2ListLibraryAgentsInfinite< + TData = InfiniteData< + Awaited>, + GetV2ListLibraryAgentsParams["page"] + >, + TError = HTTPValidationError, +>( + params: undefined | GetV2ListLibraryAgentsParams, + options: { + query: Partial< + UseInfiniteQueryOptions< + Awaited>, + TError, + TData, + QueryKey, + GetV2ListLibraryAgentsParams["page"] + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited>, + QueryKey + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseInfiniteQueryResult & { + queryKey: DataTag; +}; +export function useGetV2ListLibraryAgentsInfinite< + TData = InfiniteData< + Awaited>, + GetV2ListLibraryAgentsParams["page"] + >, + TError = HTTPValidationError, +>( + params?: GetV2ListLibraryAgentsParams, + options?: { + query?: Partial< + UseInfiniteQueryOptions< + Awaited>, + TError, + TData, + QueryKey, + GetV2ListLibraryAgentsParams["page"] + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited>, + QueryKey + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseInfiniteQueryResult & { + queryKey: DataTag; +}; +export function useGetV2ListLibraryAgentsInfinite< + TData = InfiniteData< + Awaited>, + GetV2ListLibraryAgentsParams["page"] + >, + TError = HTTPValidationError, +>( + params?: GetV2ListLibraryAgentsParams, + options?: { + query?: Partial< + UseInfiniteQueryOptions< + Awaited>, + TError, + TData, + QueryKey, + GetV2ListLibraryAgentsParams["page"] + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseInfiniteQueryResult & { + queryKey: DataTag; +}; +/** + * @summary List Library Agents + */ + +export function useGetV2ListLibraryAgentsInfinite< + TData = InfiniteData< + Awaited>, + GetV2ListLibraryAgentsParams["page"] + >, + TError = HTTPValidationError, +>( + params?: GetV2ListLibraryAgentsParams, + options?: { + query?: Partial< + UseInfiniteQueryOptions< + Awaited>, + TError, + TData, + QueryKey, + GetV2ListLibraryAgentsParams["page"] + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseInfiniteQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV2ListLibraryAgentsInfiniteQueryOptions( + params, + options, + ); + + const query = useInfiniteQuery( + queryOptions, + queryClient, + ) as UseInfiniteQueryResult & { + queryKey: DataTag; + }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +export const getGetV2ListLibraryAgentsQueryOptions = < + TData = Awaited>, + TError = HTTPValidationError, +>( + params?: GetV2ListLibraryAgentsParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, +) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = + queryOptions?.queryKey ?? getGetV2ListLibraryAgentsQueryKey(params); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => + getV2ListLibraryAgents(params, { signal, ...requestOptions }); + + return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV2ListLibraryAgentsQueryResult = NonNullable< + Awaited> +>; +export type GetV2ListLibraryAgentsQueryError = HTTPValidationError; + +export function useGetV2ListLibraryAgents< + TData = Awaited>, + TError = HTTPValidationError, +>( + params: undefined | GetV2ListLibraryAgentsParams, + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV2ListLibraryAgents< + TData = Awaited>, + TError = HTTPValidationError, +>( + params?: GetV2ListLibraryAgentsParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV2ListLibraryAgents< + TData = Awaited>, + TError = HTTPValidationError, +>( + params?: GetV2ListLibraryAgentsParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary List Library Agents + */ + +export function useGetV2ListLibraryAgents< + TData = Awaited>, + TError = HTTPValidationError, +>( + params?: GetV2ListLibraryAgentsParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV2ListLibraryAgentsQueryOptions(params, options); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * Add an agent from the marketplace to the user's library. + +Args: + store_listing_version_id: ID of the store listing version to add. + user_id: ID of the authenticated user. + +Returns: + library_model.LibraryAgent: Agent added to the library + +Raises: + HTTPException(404): If the listing version is not found. + HTTPException(500): If a server/database error occurs. + * @summary Add Marketplace Agent + */ +export type postV2AddMarketplaceAgentResponse201 = { + data: LibraryAgent; + status: 201; +}; + +export type postV2AddMarketplaceAgentResponse404 = { + data: void; + status: 404; +}; + +export type postV2AddMarketplaceAgentResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type postV2AddMarketplaceAgentResponseComposite = + | postV2AddMarketplaceAgentResponse201 + | postV2AddMarketplaceAgentResponse404 + | postV2AddMarketplaceAgentResponse422; + +export type postV2AddMarketplaceAgentResponse = + postV2AddMarketplaceAgentResponseComposite & { + headers: Headers; + }; + +export const getPostV2AddMarketplaceAgentUrl = () => { + return `/api/library/agents`; +}; + +export const postV2AddMarketplaceAgent = async ( + bodyPostV2AddMarketplaceAgent: BodyPostV2AddMarketplaceAgent, + options?: RequestInit, +): Promise => { + return customMutator( + getPostV2AddMarketplaceAgentUrl(), + { + ...options, + method: "POST", + headers: { "Content-Type": "application/json", ...options?.headers }, + body: JSON.stringify(bodyPostV2AddMarketplaceAgent), + }, + ); +}; + +export const getPostV2AddMarketplaceAgentMutationOptions = < + TError = void | HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { data: BodyPostV2AddMarketplaceAgent }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { data: BodyPostV2AddMarketplaceAgent }, + TContext +> => { + const mutationKey = ["postV2AddMarketplaceAgent"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { data: BodyPostV2AddMarketplaceAgent } + > = (props) => { + const { data } = props ?? {}; + + return postV2AddMarketplaceAgent(data, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PostV2AddMarketplaceAgentMutationResult = NonNullable< + Awaited> +>; +export type PostV2AddMarketplaceAgentMutationBody = + BodyPostV2AddMarketplaceAgent; +export type PostV2AddMarketplaceAgentMutationError = void | HTTPValidationError; + +/** + * @summary Add Marketplace Agent + */ +export const usePostV2AddMarketplaceAgent = < + TError = void | HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { data: BodyPostV2AddMarketplaceAgent }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { data: BodyPostV2AddMarketplaceAgent }, + TContext +> => { + const mutationOptions = getPostV2AddMarketplaceAgentMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * @summary Get Library Agent + */ +export type getV2GetLibraryAgentResponse200 = { + data: LibraryAgent; + status: 200; +}; + +export type getV2GetLibraryAgentResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type getV2GetLibraryAgentResponseComposite = + | getV2GetLibraryAgentResponse200 + | getV2GetLibraryAgentResponse422; + +export type getV2GetLibraryAgentResponse = + getV2GetLibraryAgentResponseComposite & { + headers: Headers; + }; + +export const getGetV2GetLibraryAgentUrl = (libraryAgentId: string) => { + return `/api/library/agents/${libraryAgentId}`; +}; + +export const getV2GetLibraryAgent = async ( + libraryAgentId: string, + options?: RequestInit, +): Promise => { + return customMutator( + getGetV2GetLibraryAgentUrl(libraryAgentId), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV2GetLibraryAgentQueryKey = (libraryAgentId: string) => { + return [`/api/library/agents/${libraryAgentId}`] as const; +}; + +export const getGetV2GetLibraryAgentQueryOptions = < + TData = Awaited>, + TError = HTTPValidationError, +>( + libraryAgentId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, +) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = + queryOptions?.queryKey ?? getGetV2GetLibraryAgentQueryKey(libraryAgentId); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => + getV2GetLibraryAgent(libraryAgentId, { signal, ...requestOptions }); + + return { + queryKey, + queryFn, + enabled: !!libraryAgentId, + ...queryOptions, + } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV2GetLibraryAgentQueryResult = NonNullable< + Awaited> +>; +export type GetV2GetLibraryAgentQueryError = HTTPValidationError; + +export function useGetV2GetLibraryAgent< + TData = Awaited>, + TError = HTTPValidationError, +>( + libraryAgentId: string, + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV2GetLibraryAgent< + TData = Awaited>, + TError = HTTPValidationError, +>( + libraryAgentId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV2GetLibraryAgent< + TData = Awaited>, + TError = HTTPValidationError, +>( + libraryAgentId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary Get Library Agent + */ + +export function useGetV2GetLibraryAgent< + TData = Awaited>, + TError = HTTPValidationError, +>( + libraryAgentId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV2GetLibraryAgentQueryOptions( + libraryAgentId, + options, + ); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * Update the library agent with the given fields. + +Args: + library_agent_id: ID of the library agent to update. + payload: Fields to update (auto_update_version, is_favorite, etc.). + user_id: ID of the authenticated user. + +Raises: + HTTPException(500): If a server/database error occurs. + * @summary Update Library Agent + */ +export type patchV2UpdateLibraryAgentResponse200 = { + data: LibraryAgent; + status: 200; +}; + +export type patchV2UpdateLibraryAgentResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type patchV2UpdateLibraryAgentResponse500 = { + data: void; + status: 500; +}; + +export type patchV2UpdateLibraryAgentResponseComposite = + | patchV2UpdateLibraryAgentResponse200 + | patchV2UpdateLibraryAgentResponse422 + | patchV2UpdateLibraryAgentResponse500; + +export type patchV2UpdateLibraryAgentResponse = + patchV2UpdateLibraryAgentResponseComposite & { + headers: Headers; + }; + +export const getPatchV2UpdateLibraryAgentUrl = (libraryAgentId: string) => { + return `/api/library/agents/${libraryAgentId}`; +}; + +export const patchV2UpdateLibraryAgent = async ( + libraryAgentId: string, + libraryAgentUpdateRequest: LibraryAgentUpdateRequest, + options?: RequestInit, +): Promise => { + return customMutator( + getPatchV2UpdateLibraryAgentUrl(libraryAgentId), + { + ...options, + method: "PATCH", + headers: { "Content-Type": "application/json", ...options?.headers }, + body: JSON.stringify(libraryAgentUpdateRequest), + }, + ); +}; + +export const getPatchV2UpdateLibraryAgentMutationOptions = < + TError = HTTPValidationError | void, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { libraryAgentId: string; data: LibraryAgentUpdateRequest }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { libraryAgentId: string; data: LibraryAgentUpdateRequest }, + TContext +> => { + const mutationKey = ["patchV2UpdateLibraryAgent"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { libraryAgentId: string; data: LibraryAgentUpdateRequest } + > = (props) => { + const { libraryAgentId, data } = props ?? {}; + + return patchV2UpdateLibraryAgent(libraryAgentId, data, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PatchV2UpdateLibraryAgentMutationResult = NonNullable< + Awaited> +>; +export type PatchV2UpdateLibraryAgentMutationBody = LibraryAgentUpdateRequest; +export type PatchV2UpdateLibraryAgentMutationError = HTTPValidationError | void; + +/** + * @summary Update Library Agent + */ +export const usePatchV2UpdateLibraryAgent = < + TError = HTTPValidationError | void, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { libraryAgentId: string; data: LibraryAgentUpdateRequest }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { libraryAgentId: string; data: LibraryAgentUpdateRequest }, + TContext +> => { + const mutationOptions = getPatchV2UpdateLibraryAgentMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * Soft-delete the specified library agent. + +Args: + library_agent_id: ID of the library agent to delete. + user_id: ID of the authenticated user. + +Returns: + 204 No Content if successful. + +Raises: + HTTPException(404): If the agent does not exist. + HTTPException(500): If a server/database error occurs. + * @summary Delete Library Agent + */ +export type deleteV2DeleteLibraryAgentResponse200 = { + data: unknown; + status: 200; +}; + +export type deleteV2DeleteLibraryAgentResponse204 = { + data: void; + status: 204; +}; + +export type deleteV2DeleteLibraryAgentResponse404 = { + data: void; + status: 404; +}; + +export type deleteV2DeleteLibraryAgentResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type deleteV2DeleteLibraryAgentResponseComposite = + | deleteV2DeleteLibraryAgentResponse200 + | deleteV2DeleteLibraryAgentResponse204 + | deleteV2DeleteLibraryAgentResponse404 + | deleteV2DeleteLibraryAgentResponse422; + +export type deleteV2DeleteLibraryAgentResponse = + deleteV2DeleteLibraryAgentResponseComposite & { + headers: Headers; + }; + +export const getDeleteV2DeleteLibraryAgentUrl = (libraryAgentId: string) => { + return `/api/library/agents/${libraryAgentId}`; +}; + +export const deleteV2DeleteLibraryAgent = async ( + libraryAgentId: string, + options?: RequestInit, +): Promise => { + return customMutator( + getDeleteV2DeleteLibraryAgentUrl(libraryAgentId), + { + ...options, + method: "DELETE", + }, + ); +}; + +export const getDeleteV2DeleteLibraryAgentMutationOptions = < + TError = void | HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { libraryAgentId: string }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { libraryAgentId: string }, + TContext +> => { + const mutationKey = ["deleteV2DeleteLibraryAgent"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { libraryAgentId: string } + > = (props) => { + const { libraryAgentId } = props ?? {}; + + return deleteV2DeleteLibraryAgent(libraryAgentId, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type DeleteV2DeleteLibraryAgentMutationResult = NonNullable< + Awaited> +>; + +export type DeleteV2DeleteLibraryAgentMutationError = + void | HTTPValidationError; + +/** + * @summary Delete Library Agent + */ +export const useDeleteV2DeleteLibraryAgent = < + TError = void | HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { libraryAgentId: string }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { libraryAgentId: string }, + TContext +> => { + const mutationOptions = getDeleteV2DeleteLibraryAgentMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * @summary Get Library Agent By Graph Id + */ +export type getV2GetLibraryAgentByGraphIdResponse200 = { + data: LibraryAgent; + status: 200; +}; + +export type getV2GetLibraryAgentByGraphIdResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type getV2GetLibraryAgentByGraphIdResponseComposite = + | getV2GetLibraryAgentByGraphIdResponse200 + | getV2GetLibraryAgentByGraphIdResponse422; + +export type getV2GetLibraryAgentByGraphIdResponse = + getV2GetLibraryAgentByGraphIdResponseComposite & { + headers: Headers; + }; + +export const getGetV2GetLibraryAgentByGraphIdUrl = ( + graphId: string, + params?: GetV2GetLibraryAgentByGraphIdParams, +) => { + const normalizedParams = new URLSearchParams(); + + Object.entries(params || {}).forEach(([key, value]) => { + if (value !== undefined) { + normalizedParams.append(key, value === null ? "null" : value.toString()); + } + }); + + const stringifiedParams = normalizedParams.toString(); + + return stringifiedParams.length > 0 + ? `/api/library/agents/by-graph/${graphId}?${stringifiedParams}` + : `/api/library/agents/by-graph/${graphId}`; +}; + +export const getV2GetLibraryAgentByGraphId = async ( + graphId: string, + params?: GetV2GetLibraryAgentByGraphIdParams, + options?: RequestInit, +): Promise => { + return customMutator( + getGetV2GetLibraryAgentByGraphIdUrl(graphId, params), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV2GetLibraryAgentByGraphIdQueryKey = ( + graphId: string, + params?: GetV2GetLibraryAgentByGraphIdParams, +) => { + return [ + `/api/library/agents/by-graph/${graphId}`, + ...(params ? [params] : []), + ] as const; +}; + +export const getGetV2GetLibraryAgentByGraphIdQueryOptions = < + TData = Awaited>, + TError = HTTPValidationError, +>( + graphId: string, + params?: GetV2GetLibraryAgentByGraphIdParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, +) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = + queryOptions?.queryKey ?? + getGetV2GetLibraryAgentByGraphIdQueryKey(graphId, params); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => + getV2GetLibraryAgentByGraphId(graphId, params, { + signal, + ...requestOptions, + }); + + return { + queryKey, + queryFn, + enabled: !!graphId, + ...queryOptions, + } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV2GetLibraryAgentByGraphIdQueryResult = NonNullable< + Awaited> +>; +export type GetV2GetLibraryAgentByGraphIdQueryError = HTTPValidationError; + +export function useGetV2GetLibraryAgentByGraphId< + TData = Awaited>, + TError = HTTPValidationError, +>( + graphId: string, + params: undefined | GetV2GetLibraryAgentByGraphIdParams, + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV2GetLibraryAgentByGraphId< + TData = Awaited>, + TError = HTTPValidationError, +>( + graphId: string, + params?: GetV2GetLibraryAgentByGraphIdParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV2GetLibraryAgentByGraphId< + TData = Awaited>, + TError = HTTPValidationError, +>( + graphId: string, + params?: GetV2GetLibraryAgentByGraphIdParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary Get Library Agent By Graph Id + */ + +export function useGetV2GetLibraryAgentByGraphId< + TData = Awaited>, + TError = HTTPValidationError, +>( + graphId: string, + params?: GetV2GetLibraryAgentByGraphIdParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV2GetLibraryAgentByGraphIdQueryOptions( + graphId, + params, + options, + ); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * Get Library Agent from Store Listing Version ID. + * @summary Get Agent By Store ID + */ +export type getV2GetAgentByStoreIdResponse200 = { + data: GetV2GetAgentByStoreId200; + status: 200; +}; + +export type getV2GetAgentByStoreIdResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type getV2GetAgentByStoreIdResponseComposite = + | getV2GetAgentByStoreIdResponse200 + | getV2GetAgentByStoreIdResponse422; + +export type getV2GetAgentByStoreIdResponse = + getV2GetAgentByStoreIdResponseComposite & { + headers: Headers; + }; + +export const getGetV2GetAgentByStoreIdUrl = (storeListingVersionId: string) => { + return `/api/library/agents/marketplace/${storeListingVersionId}`; +}; + +export const getV2GetAgentByStoreId = async ( + storeListingVersionId: string, + options?: RequestInit, +): Promise => { + return customMutator( + getGetV2GetAgentByStoreIdUrl(storeListingVersionId), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV2GetAgentByStoreIdQueryKey = ( + storeListingVersionId: string, +) => { + return [`/api/library/agents/marketplace/${storeListingVersionId}`] as const; +}; + +export const getGetV2GetAgentByStoreIdQueryOptions = < + TData = Awaited>, + TError = HTTPValidationError, +>( + storeListingVersionId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, +) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = + queryOptions?.queryKey ?? + getGetV2GetAgentByStoreIdQueryKey(storeListingVersionId); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => + getV2GetAgentByStoreId(storeListingVersionId, { + signal, + ...requestOptions, + }); + + return { + queryKey, + queryFn, + enabled: !!storeListingVersionId, + ...queryOptions, + } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV2GetAgentByStoreIdQueryResult = NonNullable< + Awaited> +>; +export type GetV2GetAgentByStoreIdQueryError = HTTPValidationError; + +export function useGetV2GetAgentByStoreId< + TData = Awaited>, + TError = HTTPValidationError, +>( + storeListingVersionId: string, + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV2GetAgentByStoreId< + TData = Awaited>, + TError = HTTPValidationError, +>( + storeListingVersionId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV2GetAgentByStoreId< + TData = Awaited>, + TError = HTTPValidationError, +>( + storeListingVersionId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary Get Agent By Store ID + */ + +export function useGetV2GetAgentByStoreId< + TData = Awaited>, + TError = HTTPValidationError, +>( + storeListingVersionId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV2GetAgentByStoreIdQueryOptions( + storeListingVersionId, + options, + ); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * @summary Fork Library Agent + */ +export type postV2ForkLibraryAgentResponse200 = { + data: LibraryAgent; + status: 200; +}; + +export type postV2ForkLibraryAgentResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type postV2ForkLibraryAgentResponseComposite = + | postV2ForkLibraryAgentResponse200 + | postV2ForkLibraryAgentResponse422; + +export type postV2ForkLibraryAgentResponse = + postV2ForkLibraryAgentResponseComposite & { + headers: Headers; + }; + +export const getPostV2ForkLibraryAgentUrl = (libraryAgentId: string) => { + return `/api/library/agents/${libraryAgentId}/fork`; +}; + +export const postV2ForkLibraryAgent = async ( + libraryAgentId: string, + options?: RequestInit, +): Promise => { + return customMutator( + getPostV2ForkLibraryAgentUrl(libraryAgentId), + { + ...options, + method: "POST", + }, + ); +}; + +export const getPostV2ForkLibraryAgentMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { libraryAgentId: string }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { libraryAgentId: string }, + TContext +> => { + const mutationKey = ["postV2ForkLibraryAgent"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { libraryAgentId: string } + > = (props) => { + const { libraryAgentId } = props ?? {}; + + return postV2ForkLibraryAgent(libraryAgentId, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PostV2ForkLibraryAgentMutationResult = NonNullable< + Awaited> +>; + +export type PostV2ForkLibraryAgentMutationError = HTTPValidationError; + +/** + * @summary Fork Library Agent + */ +export const usePostV2ForkLibraryAgent = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { libraryAgentId: string }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { libraryAgentId: string }, + TContext +> => { + const mutationOptions = getPostV2ForkLibraryAgentMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * Sets up a webhook-triggered `LibraryAgentPreset` for a `LibraryAgent`. +Returns the correspondingly created `LibraryAgentPreset` with `webhook_id` set. + * @summary Setup Trigger + */ +export type postV2SetupTriggerResponse200 = { + data: LibraryAgentPreset; + status: 200; +}; + +export type postV2SetupTriggerResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type postV2SetupTriggerResponseComposite = + | postV2SetupTriggerResponse200 + | postV2SetupTriggerResponse422; + +export type postV2SetupTriggerResponse = postV2SetupTriggerResponseComposite & { + headers: Headers; +}; + +export const getPostV2SetupTriggerUrl = (libraryAgentId: string) => { + return `/api/library/agents/${libraryAgentId}/setup-trigger`; +}; + +export const postV2SetupTrigger = async ( + libraryAgentId: string, + triggeredPresetSetupParams: TriggeredPresetSetupParams, + options?: RequestInit, +): Promise => { + return customMutator( + getPostV2SetupTriggerUrl(libraryAgentId), + { + ...options, + method: "POST", + headers: { "Content-Type": "application/json", ...options?.headers }, + body: JSON.stringify(triggeredPresetSetupParams), + }, + ); +}; + +export const getPostV2SetupTriggerMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { libraryAgentId: string; data: TriggeredPresetSetupParams }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { libraryAgentId: string; data: TriggeredPresetSetupParams }, + TContext +> => { + const mutationKey = ["postV2SetupTrigger"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { libraryAgentId: string; data: TriggeredPresetSetupParams } + > = (props) => { + const { libraryAgentId, data } = props ?? {}; + + return postV2SetupTrigger(libraryAgentId, data, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PostV2SetupTriggerMutationResult = NonNullable< + Awaited> +>; +export type PostV2SetupTriggerMutationBody = TriggeredPresetSetupParams; +export type PostV2SetupTriggerMutationError = HTTPValidationError; + +/** + * @summary Setup Trigger + */ +export const usePostV2SetupTrigger = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { libraryAgentId: string; data: TriggeredPresetSetupParams }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { libraryAgentId: string; data: TriggeredPresetSetupParams }, + TContext +> => { + const mutationOptions = getPostV2SetupTriggerMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/endpoints/onboarding/onboarding.ts b/autogpt_platform/frontend/src/app/api/__generated__/endpoints/onboarding/onboarding.ts new file mode 100644 index 0000000000..74b107a15a --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/endpoints/onboarding/onboarding.ts @@ -0,0 +1,666 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import { useMutation, useQuery } from "@tanstack/react-query"; +import type { + DataTag, + DefinedInitialDataOptions, + DefinedUseQueryResult, + MutationFunction, + QueryClient, + QueryFunction, + QueryKey, + UndefinedInitialDataOptions, + UseMutationOptions, + UseMutationResult, + UseQueryOptions, + UseQueryResult, +} from "@tanstack/react-query"; + +import type { HTTPValidationError } from "../../models/hTTPValidationError"; + +import type { UserOnboardingUpdate } from "../../models/userOnboardingUpdate"; + +import { customMutator } from "../../../mutators/custom-mutator"; + +type SecondParameter unknown> = Parameters[1]; + +/** + * @summary Get onboarding status + */ +export type getV1GetOnboardingStatusResponse200 = { + data: unknown; + status: 200; +}; + +export type getV1GetOnboardingStatusResponseComposite = + getV1GetOnboardingStatusResponse200; + +export type getV1GetOnboardingStatusResponse = + getV1GetOnboardingStatusResponseComposite & { + headers: Headers; + }; + +export const getGetV1GetOnboardingStatusUrl = () => { + return `/api/onboarding`; +}; + +export const getV1GetOnboardingStatus = async ( + options?: RequestInit, +): Promise => { + return customMutator( + getGetV1GetOnboardingStatusUrl(), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV1GetOnboardingStatusQueryKey = () => { + return [`/api/onboarding`] as const; +}; + +export const getGetV1GetOnboardingStatusQueryOptions = < + TData = Awaited>, + TError = unknown, +>(options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; +}) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = + queryOptions?.queryKey ?? getGetV1GetOnboardingStatusQueryKey(); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => getV1GetOnboardingStatus({ signal, ...requestOptions }); + + return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV1GetOnboardingStatusQueryResult = NonNullable< + Awaited> +>; +export type GetV1GetOnboardingStatusQueryError = unknown; + +export function useGetV1GetOnboardingStatus< + TData = Awaited>, + TError = unknown, +>( + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1GetOnboardingStatus< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1GetOnboardingStatus< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary Get onboarding status + */ + +export function useGetV1GetOnboardingStatus< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV1GetOnboardingStatusQueryOptions(options); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * @summary Update onboarding progress + */ +export type patchV1UpdateOnboardingProgressResponse200 = { + data: unknown; + status: 200; +}; + +export type patchV1UpdateOnboardingProgressResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type patchV1UpdateOnboardingProgressResponseComposite = + | patchV1UpdateOnboardingProgressResponse200 + | patchV1UpdateOnboardingProgressResponse422; + +export type patchV1UpdateOnboardingProgressResponse = + patchV1UpdateOnboardingProgressResponseComposite & { + headers: Headers; + }; + +export const getPatchV1UpdateOnboardingProgressUrl = () => { + return `/api/onboarding`; +}; + +export const patchV1UpdateOnboardingProgress = async ( + userOnboardingUpdate: UserOnboardingUpdate, + options?: RequestInit, +): Promise => { + return customMutator( + getPatchV1UpdateOnboardingProgressUrl(), + { + ...options, + method: "PATCH", + headers: { "Content-Type": "application/json", ...options?.headers }, + body: JSON.stringify(userOnboardingUpdate), + }, + ); +}; + +export const getPatchV1UpdateOnboardingProgressMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { data: UserOnboardingUpdate }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { data: UserOnboardingUpdate }, + TContext +> => { + const mutationKey = ["patchV1UpdateOnboardingProgress"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { data: UserOnboardingUpdate } + > = (props) => { + const { data } = props ?? {}; + + return patchV1UpdateOnboardingProgress(data, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PatchV1UpdateOnboardingProgressMutationResult = NonNullable< + Awaited> +>; +export type PatchV1UpdateOnboardingProgressMutationBody = UserOnboardingUpdate; +export type PatchV1UpdateOnboardingProgressMutationError = HTTPValidationError; + +/** + * @summary Update onboarding progress + */ +export const usePatchV1UpdateOnboardingProgress = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { data: UserOnboardingUpdate }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { data: UserOnboardingUpdate }, + TContext +> => { + const mutationOptions = + getPatchV1UpdateOnboardingProgressMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * @summary Get recommended agents + */ +export type getV1GetRecommendedAgentsResponse200 = { + data: unknown; + status: 200; +}; + +export type getV1GetRecommendedAgentsResponseComposite = + getV1GetRecommendedAgentsResponse200; + +export type getV1GetRecommendedAgentsResponse = + getV1GetRecommendedAgentsResponseComposite & { + headers: Headers; + }; + +export const getGetV1GetRecommendedAgentsUrl = () => { + return `/api/onboarding/agents`; +}; + +export const getV1GetRecommendedAgents = async ( + options?: RequestInit, +): Promise => { + return customMutator( + getGetV1GetRecommendedAgentsUrl(), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV1GetRecommendedAgentsQueryKey = () => { + return [`/api/onboarding/agents`] as const; +}; + +export const getGetV1GetRecommendedAgentsQueryOptions = < + TData = Awaited>, + TError = unknown, +>(options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; +}) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = + queryOptions?.queryKey ?? getGetV1GetRecommendedAgentsQueryKey(); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => getV1GetRecommendedAgents({ signal, ...requestOptions }); + + return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV1GetRecommendedAgentsQueryResult = NonNullable< + Awaited> +>; +export type GetV1GetRecommendedAgentsQueryError = unknown; + +export function useGetV1GetRecommendedAgents< + TData = Awaited>, + TError = unknown, +>( + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1GetRecommendedAgents< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1GetRecommendedAgents< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary Get recommended agents + */ + +export function useGetV1GetRecommendedAgents< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV1GetRecommendedAgentsQueryOptions(options); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * @summary Check onboarding enabled + */ +export type getV1CheckOnboardingEnabledResponse200 = { + data: unknown; + status: 200; +}; + +export type getV1CheckOnboardingEnabledResponseComposite = + getV1CheckOnboardingEnabledResponse200; + +export type getV1CheckOnboardingEnabledResponse = + getV1CheckOnboardingEnabledResponseComposite & { + headers: Headers; + }; + +export const getGetV1CheckOnboardingEnabledUrl = () => { + return `/api/onboarding/enabled`; +}; + +export const getV1CheckOnboardingEnabled = async ( + options?: RequestInit, +): Promise => { + return customMutator( + getGetV1CheckOnboardingEnabledUrl(), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV1CheckOnboardingEnabledQueryKey = () => { + return [`/api/onboarding/enabled`] as const; +}; + +export const getGetV1CheckOnboardingEnabledQueryOptions = < + TData = Awaited>, + TError = unknown, +>(options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; +}) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = + queryOptions?.queryKey ?? getGetV1CheckOnboardingEnabledQueryKey(); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => + getV1CheckOnboardingEnabled({ signal, ...requestOptions }); + + return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV1CheckOnboardingEnabledQueryResult = NonNullable< + Awaited> +>; +export type GetV1CheckOnboardingEnabledQueryError = unknown; + +export function useGetV1CheckOnboardingEnabled< + TData = Awaited>, + TError = unknown, +>( + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1CheckOnboardingEnabled< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1CheckOnboardingEnabled< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary Check onboarding enabled + */ + +export function useGetV1CheckOnboardingEnabled< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV1CheckOnboardingEnabledQueryOptions(options); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/endpoints/otto/otto.ts b/autogpt_platform/frontend/src/app/api/__generated__/endpoints/otto/otto.ts new file mode 100644 index 0000000000..9096ff2be8 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/endpoints/otto/otto.ts @@ -0,0 +1,139 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import { useMutation } from "@tanstack/react-query"; +import type { + MutationFunction, + QueryClient, + UseMutationOptions, + UseMutationResult, +} from "@tanstack/react-query"; + +import type { ApiResponse } from "../../models/apiResponse"; + +import type { ChatRequest } from "../../models/chatRequest"; + +import type { HTTPValidationError } from "../../models/hTTPValidationError"; + +import { customMutator } from "../../../mutators/custom-mutator"; + +type SecondParameter unknown> = Parameters[1]; + +/** + * Proxy requests to Otto API while adding necessary security headers and logging. +Requires an authenticated user. + * @summary Proxy Otto Chat Request + */ +export type postV2ProxyOttoChatRequestResponse200 = { + data: ApiResponse; + status: 200; +}; + +export type postV2ProxyOttoChatRequestResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type postV2ProxyOttoChatRequestResponseComposite = + | postV2ProxyOttoChatRequestResponse200 + | postV2ProxyOttoChatRequestResponse422; + +export type postV2ProxyOttoChatRequestResponse = + postV2ProxyOttoChatRequestResponseComposite & { + headers: Headers; + }; + +export const getPostV2ProxyOttoChatRequestUrl = () => { + return `/api/otto/ask`; +}; + +export const postV2ProxyOttoChatRequest = async ( + chatRequest: ChatRequest, + options?: RequestInit, +): Promise => { + return customMutator( + getPostV2ProxyOttoChatRequestUrl(), + { + ...options, + method: "POST", + headers: { "Content-Type": "application/json", ...options?.headers }, + body: JSON.stringify(chatRequest), + }, + ); +}; + +export const getPostV2ProxyOttoChatRequestMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { data: ChatRequest }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { data: ChatRequest }, + TContext +> => { + const mutationKey = ["postV2ProxyOttoChatRequest"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { data: ChatRequest } + > = (props) => { + const { data } = props ?? {}; + + return postV2ProxyOttoChatRequest(data, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PostV2ProxyOttoChatRequestMutationResult = NonNullable< + Awaited> +>; +export type PostV2ProxyOttoChatRequestMutationBody = ChatRequest; +export type PostV2ProxyOttoChatRequestMutationError = HTTPValidationError; + +/** + * @summary Proxy Otto Chat Request + */ +export const usePostV2ProxyOttoChatRequest = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { data: ChatRequest }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { data: ChatRequest }, + TContext +> => { + const mutationOptions = getPostV2ProxyOttoChatRequestMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/endpoints/presets/presets.ts b/autogpt_platform/frontend/src/app/api/__generated__/endpoints/presets/presets.ts new file mode 100644 index 0000000000..1fade88cb8 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/endpoints/presets/presets.ts @@ -0,0 +1,895 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import { useMutation, useQuery } from "@tanstack/react-query"; +import type { + DataTag, + DefinedInitialDataOptions, + DefinedUseQueryResult, + MutationFunction, + QueryClient, + QueryFunction, + QueryKey, + UndefinedInitialDataOptions, + UseMutationOptions, + UseMutationResult, + UseQueryOptions, + UseQueryResult, +} from "@tanstack/react-query"; + +import type { BodyPostV2ExecuteAPreset } from "../../models/bodyPostV2ExecuteAPreset"; + +import type { GetV2ListPresetsParams } from "../../models/getV2ListPresetsParams"; + +import type { HTTPValidationError } from "../../models/hTTPValidationError"; + +import type { LibraryAgentPreset } from "../../models/libraryAgentPreset"; + +import type { LibraryAgentPresetResponse } from "../../models/libraryAgentPresetResponse"; + +import type { LibraryAgentPresetUpdatable } from "../../models/libraryAgentPresetUpdatable"; + +import type { PostV2CreateANewPresetBody } from "../../models/postV2CreateANewPresetBody"; + +import type { PostV2ExecuteAPreset200 } from "../../models/postV2ExecuteAPreset200"; + +import { customMutator } from "../../../mutators/custom-mutator"; + +type SecondParameter unknown> = Parameters[1]; + +/** + * Retrieve a paginated list of presets for the current user. + * @summary List presets + */ +export type getV2ListPresetsResponse200 = { + data: LibraryAgentPresetResponse; + status: 200; +}; + +export type getV2ListPresetsResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type getV2ListPresetsResponseComposite = + | getV2ListPresetsResponse200 + | getV2ListPresetsResponse422; + +export type getV2ListPresetsResponse = getV2ListPresetsResponseComposite & { + headers: Headers; +}; + +export const getGetV2ListPresetsUrl = (params: GetV2ListPresetsParams) => { + const normalizedParams = new URLSearchParams(); + + Object.entries(params || {}).forEach(([key, value]) => { + if (value !== undefined) { + normalizedParams.append(key, value === null ? "null" : value.toString()); + } + }); + + const stringifiedParams = normalizedParams.toString(); + + return stringifiedParams.length > 0 + ? `/api/library/presets?${stringifiedParams}` + : `/api/library/presets`; +}; + +export const getV2ListPresets = async ( + params: GetV2ListPresetsParams, + options?: RequestInit, +): Promise => { + return customMutator( + getGetV2ListPresetsUrl(params), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV2ListPresetsQueryKey = (params: GetV2ListPresetsParams) => { + return [`/api/library/presets`, ...(params ? [params] : [])] as const; +}; + +export const getGetV2ListPresetsQueryOptions = < + TData = Awaited>, + TError = HTTPValidationError, +>( + params: GetV2ListPresetsParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, +) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = + queryOptions?.queryKey ?? getGetV2ListPresetsQueryKey(params); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => getV2ListPresets(params, { signal, ...requestOptions }); + + return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV2ListPresetsQueryResult = NonNullable< + Awaited> +>; +export type GetV2ListPresetsQueryError = HTTPValidationError; + +export function useGetV2ListPresets< + TData = Awaited>, + TError = HTTPValidationError, +>( + params: GetV2ListPresetsParams, + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV2ListPresets< + TData = Awaited>, + TError = HTTPValidationError, +>( + params: GetV2ListPresetsParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV2ListPresets< + TData = Awaited>, + TError = HTTPValidationError, +>( + params: GetV2ListPresetsParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary List presets + */ + +export function useGetV2ListPresets< + TData = Awaited>, + TError = HTTPValidationError, +>( + params: GetV2ListPresetsParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV2ListPresetsQueryOptions(params, options); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * Create a new preset for the current user. + * @summary Create a new preset + */ +export type postV2CreateANewPresetResponse200 = { + data: LibraryAgentPreset; + status: 200; +}; + +export type postV2CreateANewPresetResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type postV2CreateANewPresetResponseComposite = + | postV2CreateANewPresetResponse200 + | postV2CreateANewPresetResponse422; + +export type postV2CreateANewPresetResponse = + postV2CreateANewPresetResponseComposite & { + headers: Headers; + }; + +export const getPostV2CreateANewPresetUrl = () => { + return `/api/library/presets`; +}; + +export const postV2CreateANewPreset = async ( + postV2CreateANewPresetBody: PostV2CreateANewPresetBody, + options?: RequestInit, +): Promise => { + return customMutator( + getPostV2CreateANewPresetUrl(), + { + ...options, + method: "POST", + headers: { "Content-Type": "application/json", ...options?.headers }, + body: JSON.stringify(postV2CreateANewPresetBody), + }, + ); +}; + +export const getPostV2CreateANewPresetMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { data: PostV2CreateANewPresetBody }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { data: PostV2CreateANewPresetBody }, + TContext +> => { + const mutationKey = ["postV2CreateANewPreset"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { data: PostV2CreateANewPresetBody } + > = (props) => { + const { data } = props ?? {}; + + return postV2CreateANewPreset(data, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PostV2CreateANewPresetMutationResult = NonNullable< + Awaited> +>; +export type PostV2CreateANewPresetMutationBody = PostV2CreateANewPresetBody; +export type PostV2CreateANewPresetMutationError = HTTPValidationError; + +/** + * @summary Create a new preset + */ +export const usePostV2CreateANewPreset = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { data: PostV2CreateANewPresetBody }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { data: PostV2CreateANewPresetBody }, + TContext +> => { + const mutationOptions = getPostV2CreateANewPresetMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * Retrieve details for a specific preset by its ID. + * @summary Get a specific preset + */ +export type getV2GetASpecificPresetResponse200 = { + data: LibraryAgentPreset; + status: 200; +}; + +export type getV2GetASpecificPresetResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type getV2GetASpecificPresetResponseComposite = + | getV2GetASpecificPresetResponse200 + | getV2GetASpecificPresetResponse422; + +export type getV2GetASpecificPresetResponse = + getV2GetASpecificPresetResponseComposite & { + headers: Headers; + }; + +export const getGetV2GetASpecificPresetUrl = (presetId: string) => { + return `/api/library/presets/${presetId}`; +}; + +export const getV2GetASpecificPreset = async ( + presetId: string, + options?: RequestInit, +): Promise => { + return customMutator( + getGetV2GetASpecificPresetUrl(presetId), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV2GetASpecificPresetQueryKey = (presetId: string) => { + return [`/api/library/presets/${presetId}`] as const; +}; + +export const getGetV2GetASpecificPresetQueryOptions = < + TData = Awaited>, + TError = HTTPValidationError, +>( + presetId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, +) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = + queryOptions?.queryKey ?? getGetV2GetASpecificPresetQueryKey(presetId); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => + getV2GetASpecificPreset(presetId, { signal, ...requestOptions }); + + return { + queryKey, + queryFn, + enabled: !!presetId, + ...queryOptions, + } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV2GetASpecificPresetQueryResult = NonNullable< + Awaited> +>; +export type GetV2GetASpecificPresetQueryError = HTTPValidationError; + +export function useGetV2GetASpecificPreset< + TData = Awaited>, + TError = HTTPValidationError, +>( + presetId: string, + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV2GetASpecificPreset< + TData = Awaited>, + TError = HTTPValidationError, +>( + presetId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV2GetASpecificPreset< + TData = Awaited>, + TError = HTTPValidationError, +>( + presetId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary Get a specific preset + */ + +export function useGetV2GetASpecificPreset< + TData = Awaited>, + TError = HTTPValidationError, +>( + presetId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV2GetASpecificPresetQueryOptions( + presetId, + options, + ); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * Update an existing preset by its ID. + * @summary Update an existing preset + */ +export type patchV2UpdateAnExistingPresetResponse200 = { + data: LibraryAgentPreset; + status: 200; +}; + +export type patchV2UpdateAnExistingPresetResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type patchV2UpdateAnExistingPresetResponseComposite = + | patchV2UpdateAnExistingPresetResponse200 + | patchV2UpdateAnExistingPresetResponse422; + +export type patchV2UpdateAnExistingPresetResponse = + patchV2UpdateAnExistingPresetResponseComposite & { + headers: Headers; + }; + +export const getPatchV2UpdateAnExistingPresetUrl = (presetId: string) => { + return `/api/library/presets/${presetId}`; +}; + +export const patchV2UpdateAnExistingPreset = async ( + presetId: string, + libraryAgentPresetUpdatable: LibraryAgentPresetUpdatable, + options?: RequestInit, +): Promise => { + return customMutator( + getPatchV2UpdateAnExistingPresetUrl(presetId), + { + ...options, + method: "PATCH", + headers: { "Content-Type": "application/json", ...options?.headers }, + body: JSON.stringify(libraryAgentPresetUpdatable), + }, + ); +}; + +export const getPatchV2UpdateAnExistingPresetMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { presetId: string; data: LibraryAgentPresetUpdatable }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { presetId: string; data: LibraryAgentPresetUpdatable }, + TContext +> => { + const mutationKey = ["patchV2UpdateAnExistingPreset"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { presetId: string; data: LibraryAgentPresetUpdatable } + > = (props) => { + const { presetId, data } = props ?? {}; + + return patchV2UpdateAnExistingPreset(presetId, data, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PatchV2UpdateAnExistingPresetMutationResult = NonNullable< + Awaited> +>; +export type PatchV2UpdateAnExistingPresetMutationBody = + LibraryAgentPresetUpdatable; +export type PatchV2UpdateAnExistingPresetMutationError = HTTPValidationError; + +/** + * @summary Update an existing preset + */ +export const usePatchV2UpdateAnExistingPreset = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { presetId: string; data: LibraryAgentPresetUpdatable }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { presetId: string; data: LibraryAgentPresetUpdatable }, + TContext +> => { + const mutationOptions = + getPatchV2UpdateAnExistingPresetMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * Delete an existing preset by its ID. + * @summary Delete a preset + */ +export type deleteV2DeleteAPresetResponse204 = { + data: void; + status: 204; +}; + +export type deleteV2DeleteAPresetResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type deleteV2DeleteAPresetResponseComposite = + | deleteV2DeleteAPresetResponse204 + | deleteV2DeleteAPresetResponse422; + +export type deleteV2DeleteAPresetResponse = + deleteV2DeleteAPresetResponseComposite & { + headers: Headers; + }; + +export const getDeleteV2DeleteAPresetUrl = (presetId: string) => { + return `/api/library/presets/${presetId}`; +}; + +export const deleteV2DeleteAPreset = async ( + presetId: string, + options?: RequestInit, +): Promise => { + return customMutator( + getDeleteV2DeleteAPresetUrl(presetId), + { + ...options, + method: "DELETE", + }, + ); +}; + +export const getDeleteV2DeleteAPresetMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { presetId: string }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { presetId: string }, + TContext +> => { + const mutationKey = ["deleteV2DeleteAPreset"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { presetId: string } + > = (props) => { + const { presetId } = props ?? {}; + + return deleteV2DeleteAPreset(presetId, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type DeleteV2DeleteAPresetMutationResult = NonNullable< + Awaited> +>; + +export type DeleteV2DeleteAPresetMutationError = HTTPValidationError; + +/** + * @summary Delete a preset + */ +export const useDeleteV2DeleteAPreset = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { presetId: string }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { presetId: string }, + TContext +> => { + const mutationOptions = getDeleteV2DeleteAPresetMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * Execute a preset with the given graph and node input for the current user. + * @summary Execute a preset + */ +export type postV2ExecuteAPresetResponse200 = { + data: PostV2ExecuteAPreset200; + status: 200; +}; + +export type postV2ExecuteAPresetResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type postV2ExecuteAPresetResponseComposite = + | postV2ExecuteAPresetResponse200 + | postV2ExecuteAPresetResponse422; + +export type postV2ExecuteAPresetResponse = + postV2ExecuteAPresetResponseComposite & { + headers: Headers; + }; + +export const getPostV2ExecuteAPresetUrl = (presetId: string) => { + return `/api/library/presets/${presetId}/execute`; +}; + +export const postV2ExecuteAPreset = async ( + presetId: string, + bodyPostV2ExecuteAPreset: BodyPostV2ExecuteAPreset, + options?: RequestInit, +): Promise => { + return customMutator( + getPostV2ExecuteAPresetUrl(presetId), + { + ...options, + method: "POST", + headers: { "Content-Type": "application/json", ...options?.headers }, + body: JSON.stringify(bodyPostV2ExecuteAPreset), + }, + ); +}; + +export const getPostV2ExecuteAPresetMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { presetId: string; data: BodyPostV2ExecuteAPreset }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { presetId: string; data: BodyPostV2ExecuteAPreset }, + TContext +> => { + const mutationKey = ["postV2ExecuteAPreset"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { presetId: string; data: BodyPostV2ExecuteAPreset } + > = (props) => { + const { presetId, data } = props ?? {}; + + return postV2ExecuteAPreset(presetId, data, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PostV2ExecuteAPresetMutationResult = NonNullable< + Awaited> +>; +export type PostV2ExecuteAPresetMutationBody = BodyPostV2ExecuteAPreset; +export type PostV2ExecuteAPresetMutationError = HTTPValidationError; + +/** + * @summary Execute a preset + */ +export const usePostV2ExecuteAPreset = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { presetId: string; data: BodyPostV2ExecuteAPreset }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { presetId: string; data: BodyPostV2ExecuteAPreset }, + TContext +> => { + const mutationOptions = getPostV2ExecuteAPresetMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/endpoints/schedules/schedules.ts b/autogpt_platform/frontend/src/app/api/__generated__/endpoints/schedules/schedules.ts new file mode 100644 index 0000000000..6d0e9f655a --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/endpoints/schedules/schedules.ts @@ -0,0 +1,640 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import { useMutation, useQuery } from "@tanstack/react-query"; +import type { + DataTag, + DefinedInitialDataOptions, + DefinedUseQueryResult, + MutationFunction, + QueryClient, + QueryFunction, + QueryKey, + UndefinedInitialDataOptions, + UseMutationOptions, + UseMutationResult, + UseQueryOptions, + UseQueryResult, +} from "@tanstack/react-query"; + +import type { DeleteV1DeleteExecutionSchedule200 } from "../../models/deleteV1DeleteExecutionSchedule200"; + +import type { GraphExecutionJobInfo } from "../../models/graphExecutionJobInfo"; + +import type { HTTPValidationError } from "../../models/hTTPValidationError"; + +import type { ScheduleCreationRequest } from "../../models/scheduleCreationRequest"; + +import { customMutator } from "../../../mutators/custom-mutator"; + +type SecondParameter unknown> = Parameters[1]; + +/** + * @summary Create execution schedule + */ +export type postV1CreateExecutionScheduleResponse200 = { + data: GraphExecutionJobInfo; + status: 200; +}; + +export type postV1CreateExecutionScheduleResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type postV1CreateExecutionScheduleResponseComposite = + | postV1CreateExecutionScheduleResponse200 + | postV1CreateExecutionScheduleResponse422; + +export type postV1CreateExecutionScheduleResponse = + postV1CreateExecutionScheduleResponseComposite & { + headers: Headers; + }; + +export const getPostV1CreateExecutionScheduleUrl = (graphId: string) => { + return `/api/graphs/${graphId}/schedules`; +}; + +export const postV1CreateExecutionSchedule = async ( + graphId: string, + scheduleCreationRequest: ScheduleCreationRequest, + options?: RequestInit, +): Promise => { + return customMutator( + getPostV1CreateExecutionScheduleUrl(graphId), + { + ...options, + method: "POST", + headers: { "Content-Type": "application/json", ...options?.headers }, + body: JSON.stringify(scheduleCreationRequest), + }, + ); +}; + +export const getPostV1CreateExecutionScheduleMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { graphId: string; data: ScheduleCreationRequest }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { graphId: string; data: ScheduleCreationRequest }, + TContext +> => { + const mutationKey = ["postV1CreateExecutionSchedule"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { graphId: string; data: ScheduleCreationRequest } + > = (props) => { + const { graphId, data } = props ?? {}; + + return postV1CreateExecutionSchedule(graphId, data, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PostV1CreateExecutionScheduleMutationResult = NonNullable< + Awaited> +>; +export type PostV1CreateExecutionScheduleMutationBody = ScheduleCreationRequest; +export type PostV1CreateExecutionScheduleMutationError = HTTPValidationError; + +/** + * @summary Create execution schedule + */ +export const usePostV1CreateExecutionSchedule = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { graphId: string; data: ScheduleCreationRequest }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { graphId: string; data: ScheduleCreationRequest }, + TContext +> => { + const mutationOptions = + getPostV1CreateExecutionScheduleMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * @summary List execution schedules for a graph + */ +export type getV1ListExecutionSchedulesForAGraphResponse200 = { + data: GraphExecutionJobInfo[]; + status: 200; +}; + +export type getV1ListExecutionSchedulesForAGraphResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type getV1ListExecutionSchedulesForAGraphResponseComposite = + | getV1ListExecutionSchedulesForAGraphResponse200 + | getV1ListExecutionSchedulesForAGraphResponse422; + +export type getV1ListExecutionSchedulesForAGraphResponse = + getV1ListExecutionSchedulesForAGraphResponseComposite & { + headers: Headers; + }; + +export const getGetV1ListExecutionSchedulesForAGraphUrl = (graphId: string) => { + return `/api/graphs/${graphId}/schedules`; +}; + +export const getV1ListExecutionSchedulesForAGraph = async ( + graphId: string, + options?: RequestInit, +): Promise => { + return customMutator( + getGetV1ListExecutionSchedulesForAGraphUrl(graphId), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV1ListExecutionSchedulesForAGraphQueryKey = ( + graphId: string, +) => { + return [`/api/graphs/${graphId}/schedules`] as const; +}; + +export const getGetV1ListExecutionSchedulesForAGraphQueryOptions = < + TData = Awaited>, + TError = HTTPValidationError, +>( + graphId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, +) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = + queryOptions?.queryKey ?? + getGetV1ListExecutionSchedulesForAGraphQueryKey(graphId); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => + getV1ListExecutionSchedulesForAGraph(graphId, { + signal, + ...requestOptions, + }); + + return { + queryKey, + queryFn, + enabled: !!graphId, + ...queryOptions, + } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV1ListExecutionSchedulesForAGraphQueryResult = NonNullable< + Awaited> +>; +export type GetV1ListExecutionSchedulesForAGraphQueryError = + HTTPValidationError; + +export function useGetV1ListExecutionSchedulesForAGraph< + TData = Awaited>, + TError = HTTPValidationError, +>( + graphId: string, + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1ListExecutionSchedulesForAGraph< + TData = Awaited>, + TError = HTTPValidationError, +>( + graphId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1ListExecutionSchedulesForAGraph< + TData = Awaited>, + TError = HTTPValidationError, +>( + graphId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary List execution schedules for a graph + */ + +export function useGetV1ListExecutionSchedulesForAGraph< + TData = Awaited>, + TError = HTTPValidationError, +>( + graphId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV1ListExecutionSchedulesForAGraphQueryOptions( + graphId, + options, + ); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * @summary List execution schedules for a user + */ +export type getV1ListExecutionSchedulesForAUserResponse200 = { + data: GraphExecutionJobInfo[]; + status: 200; +}; + +export type getV1ListExecutionSchedulesForAUserResponseComposite = + getV1ListExecutionSchedulesForAUserResponse200; + +export type getV1ListExecutionSchedulesForAUserResponse = + getV1ListExecutionSchedulesForAUserResponseComposite & { + headers: Headers; + }; + +export const getGetV1ListExecutionSchedulesForAUserUrl = () => { + return `/api/schedules`; +}; + +export const getV1ListExecutionSchedulesForAUser = async ( + options?: RequestInit, +): Promise => { + return customMutator( + getGetV1ListExecutionSchedulesForAUserUrl(), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV1ListExecutionSchedulesForAUserQueryKey = () => { + return [`/api/schedules`] as const; +}; + +export const getGetV1ListExecutionSchedulesForAUserQueryOptions = < + TData = Awaited>, + TError = unknown, +>(options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; +}) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = + queryOptions?.queryKey ?? getGetV1ListExecutionSchedulesForAUserQueryKey(); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => + getV1ListExecutionSchedulesForAUser({ signal, ...requestOptions }); + + return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV1ListExecutionSchedulesForAUserQueryResult = NonNullable< + Awaited> +>; +export type GetV1ListExecutionSchedulesForAUserQueryError = unknown; + +export function useGetV1ListExecutionSchedulesForAUser< + TData = Awaited>, + TError = unknown, +>( + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1ListExecutionSchedulesForAUser< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV1ListExecutionSchedulesForAUser< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary List execution schedules for a user + */ + +export function useGetV1ListExecutionSchedulesForAUser< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = + getGetV1ListExecutionSchedulesForAUserQueryOptions(options); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * @summary Delete execution schedule + */ +export type deleteV1DeleteExecutionScheduleResponse200 = { + data: DeleteV1DeleteExecutionSchedule200; + status: 200; +}; + +export type deleteV1DeleteExecutionScheduleResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type deleteV1DeleteExecutionScheduleResponseComposite = + | deleteV1DeleteExecutionScheduleResponse200 + | deleteV1DeleteExecutionScheduleResponse422; + +export type deleteV1DeleteExecutionScheduleResponse = + deleteV1DeleteExecutionScheduleResponseComposite & { + headers: Headers; + }; + +export const getDeleteV1DeleteExecutionScheduleUrl = (scheduleId: string) => { + return `/api/schedules/${scheduleId}`; +}; + +export const deleteV1DeleteExecutionSchedule = async ( + scheduleId: string, + options?: RequestInit, +): Promise => { + return customMutator( + getDeleteV1DeleteExecutionScheduleUrl(scheduleId), + { + ...options, + method: "DELETE", + }, + ); +}; + +export const getDeleteV1DeleteExecutionScheduleMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { scheduleId: string }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { scheduleId: string }, + TContext +> => { + const mutationKey = ["deleteV1DeleteExecutionSchedule"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { scheduleId: string } + > = (props) => { + const { scheduleId } = props ?? {}; + + return deleteV1DeleteExecutionSchedule(scheduleId, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type DeleteV1DeleteExecutionScheduleMutationResult = NonNullable< + Awaited> +>; + +export type DeleteV1DeleteExecutionScheduleMutationError = HTTPValidationError; + +/** + * @summary Delete execution schedule + */ +export const useDeleteV1DeleteExecutionSchedule = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { scheduleId: string }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { scheduleId: string }, + TContext +> => { + const mutationOptions = + getDeleteV1DeleteExecutionScheduleMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/endpoints/store/store.ts b/autogpt_platform/frontend/src/app/api/__generated__/endpoints/store/store.ts new file mode 100644 index 0000000000..5970371244 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/endpoints/store/store.ts @@ -0,0 +1,2841 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import { useMutation, useQuery } from "@tanstack/react-query"; +import type { + DataTag, + DefinedInitialDataOptions, + DefinedUseQueryResult, + MutationFunction, + QueryClient, + QueryFunction, + QueryKey, + UndefinedInitialDataOptions, + UseMutationOptions, + UseMutationResult, + UseQueryOptions, + UseQueryResult, +} from "@tanstack/react-query"; + +import type { BodyPostV2UploadSubmissionMedia } from "../../models/bodyPostV2UploadSubmissionMedia"; + +import type { CreatorDetails } from "../../models/creatorDetails"; + +import type { CreatorsResponse } from "../../models/creatorsResponse"; + +import type { GetV2ListMySubmissionsParams } from "../../models/getV2ListMySubmissionsParams"; + +import type { GetV2ListStoreAgentsParams } from "../../models/getV2ListStoreAgentsParams"; + +import type { GetV2ListStoreCreatorsParams } from "../../models/getV2ListStoreCreatorsParams"; + +import type { HTTPValidationError } from "../../models/hTTPValidationError"; + +import type { MyAgentsResponse } from "../../models/myAgentsResponse"; + +import type { PostV2GenerateSubmissionImageParams } from "../../models/postV2GenerateSubmissionImageParams"; + +import type { Profile } from "../../models/profile"; + +import type { ProfileDetails } from "../../models/profileDetails"; + +import type { StoreAgentDetails } from "../../models/storeAgentDetails"; + +import type { StoreAgentsResponse } from "../../models/storeAgentsResponse"; + +import type { StoreReview } from "../../models/storeReview"; + +import type { StoreReviewCreate } from "../../models/storeReviewCreate"; + +import type { StoreSubmission } from "../../models/storeSubmission"; + +import type { StoreSubmissionRequest } from "../../models/storeSubmissionRequest"; + +import type { StoreSubmissionsResponse } from "../../models/storeSubmissionsResponse"; + +import { customMutator } from "../../../mutators/custom-mutator"; + +type SecondParameter unknown> = Parameters[1]; + +/** + * Get the profile details for the authenticated user. + * @summary Get user profile + */ +export type getV2GetUserProfileResponse200 = { + data: ProfileDetails; + status: 200; +}; + +export type getV2GetUserProfileResponseComposite = + getV2GetUserProfileResponse200; + +export type getV2GetUserProfileResponse = + getV2GetUserProfileResponseComposite & { + headers: Headers; + }; + +export const getGetV2GetUserProfileUrl = () => { + return `/api/store/profile`; +}; + +export const getV2GetUserProfile = async ( + options?: RequestInit, +): Promise => { + return customMutator( + getGetV2GetUserProfileUrl(), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV2GetUserProfileQueryKey = () => { + return [`/api/store/profile`] as const; +}; + +export const getGetV2GetUserProfileQueryOptions = < + TData = Awaited>, + TError = unknown, +>(options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; +}) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = queryOptions?.queryKey ?? getGetV2GetUserProfileQueryKey(); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => getV2GetUserProfile({ signal, ...requestOptions }); + + return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV2GetUserProfileQueryResult = NonNullable< + Awaited> +>; +export type GetV2GetUserProfileQueryError = unknown; + +export function useGetV2GetUserProfile< + TData = Awaited>, + TError = unknown, +>( + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV2GetUserProfile< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV2GetUserProfile< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary Get user profile + */ + +export function useGetV2GetUserProfile< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV2GetUserProfileQueryOptions(options); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * Update the store profile for the authenticated user. + +Args: + profile (Profile): The updated profile details + user_id (str): ID of the authenticated user + +Returns: + CreatorDetails: The updated profile + +Raises: + HTTPException: If there is an error updating the profile + * @summary Update user profile + */ +export type postV2UpdateUserProfileResponse200 = { + data: CreatorDetails; + status: 200; +}; + +export type postV2UpdateUserProfileResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type postV2UpdateUserProfileResponseComposite = + | postV2UpdateUserProfileResponse200 + | postV2UpdateUserProfileResponse422; + +export type postV2UpdateUserProfileResponse = + postV2UpdateUserProfileResponseComposite & { + headers: Headers; + }; + +export const getPostV2UpdateUserProfileUrl = () => { + return `/api/store/profile`; +}; + +export const postV2UpdateUserProfile = async ( + profile: Profile, + options?: RequestInit, +): Promise => { + return customMutator( + getPostV2UpdateUserProfileUrl(), + { + ...options, + method: "POST", + headers: { "Content-Type": "application/json", ...options?.headers }, + body: JSON.stringify(profile), + }, + ); +}; + +export const getPostV2UpdateUserProfileMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { data: Profile }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { data: Profile }, + TContext +> => { + const mutationKey = ["postV2UpdateUserProfile"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { data: Profile } + > = (props) => { + const { data } = props ?? {}; + + return postV2UpdateUserProfile(data, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PostV2UpdateUserProfileMutationResult = NonNullable< + Awaited> +>; +export type PostV2UpdateUserProfileMutationBody = Profile; +export type PostV2UpdateUserProfileMutationError = HTTPValidationError; + +/** + * @summary Update user profile + */ +export const usePostV2UpdateUserProfile = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { data: Profile }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { data: Profile }, + TContext +> => { + const mutationOptions = getPostV2UpdateUserProfileMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * Get a paginated list of agents from the store with optional filtering and sorting. + +Args: + featured (bool, optional): Filter to only show featured agents. Defaults to False. + creator (str | None, optional): Filter agents by creator username. Defaults to None. + sorted_by (str | None, optional): Sort agents by "runs" or "rating". Defaults to None. + search_query (str | None, optional): Search agents by name, subheading and description. Defaults to None. + category (str | None, optional): Filter agents by category. Defaults to None. + page (int, optional): Page number for pagination. Defaults to 1. + page_size (int, optional): Number of agents per page. Defaults to 20. + +Returns: + StoreAgentsResponse: Paginated list of agents matching the filters + +Raises: + HTTPException: If page or page_size are less than 1 + +Used for: +- Home Page Featured Agents +- Home Page Top Agents +- Search Results +- Agent Details - Other Agents By Creator +- Agent Details - Similar Agents +- Creator Details - Agents By Creator + * @summary List store agents + */ +export type getV2ListStoreAgentsResponse200 = { + data: StoreAgentsResponse; + status: 200; +}; + +export type getV2ListStoreAgentsResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type getV2ListStoreAgentsResponseComposite = + | getV2ListStoreAgentsResponse200 + | getV2ListStoreAgentsResponse422; + +export type getV2ListStoreAgentsResponse = + getV2ListStoreAgentsResponseComposite & { + headers: Headers; + }; + +export const getGetV2ListStoreAgentsUrl = ( + params?: GetV2ListStoreAgentsParams, +) => { + const normalizedParams = new URLSearchParams(); + + Object.entries(params || {}).forEach(([key, value]) => { + if (value !== undefined) { + normalizedParams.append(key, value === null ? "null" : value.toString()); + } + }); + + const stringifiedParams = normalizedParams.toString(); + + return stringifiedParams.length > 0 + ? `/api/store/agents?${stringifiedParams}` + : `/api/store/agents`; +}; + +export const getV2ListStoreAgents = async ( + params?: GetV2ListStoreAgentsParams, + options?: RequestInit, +): Promise => { + return customMutator( + getGetV2ListStoreAgentsUrl(params), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV2ListStoreAgentsQueryKey = ( + params?: GetV2ListStoreAgentsParams, +) => { + return [`/api/store/agents`, ...(params ? [params] : [])] as const; +}; + +export const getGetV2ListStoreAgentsQueryOptions = < + TData = Awaited>, + TError = HTTPValidationError, +>( + params?: GetV2ListStoreAgentsParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, +) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = + queryOptions?.queryKey ?? getGetV2ListStoreAgentsQueryKey(params); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => + getV2ListStoreAgents(params, { signal, ...requestOptions }); + + return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV2ListStoreAgentsQueryResult = NonNullable< + Awaited> +>; +export type GetV2ListStoreAgentsQueryError = HTTPValidationError; + +export function useGetV2ListStoreAgents< + TData = Awaited>, + TError = HTTPValidationError, +>( + params: undefined | GetV2ListStoreAgentsParams, + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV2ListStoreAgents< + TData = Awaited>, + TError = HTTPValidationError, +>( + params?: GetV2ListStoreAgentsParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV2ListStoreAgents< + TData = Awaited>, + TError = HTTPValidationError, +>( + params?: GetV2ListStoreAgentsParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary List store agents + */ + +export function useGetV2ListStoreAgents< + TData = Awaited>, + TError = HTTPValidationError, +>( + params?: GetV2ListStoreAgentsParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV2ListStoreAgentsQueryOptions(params, options); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * This is only used on the AgentDetails Page + +It returns the store listing agents details. + * @summary Get specific agent + */ +export type getV2GetSpecificAgentResponse200 = { + data: StoreAgentDetails; + status: 200; +}; + +export type getV2GetSpecificAgentResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type getV2GetSpecificAgentResponseComposite = + | getV2GetSpecificAgentResponse200 + | getV2GetSpecificAgentResponse422; + +export type getV2GetSpecificAgentResponse = + getV2GetSpecificAgentResponseComposite & { + headers: Headers; + }; + +export const getGetV2GetSpecificAgentUrl = ( + username: string, + agentName: string, +) => { + return `/api/store/agents/${username}/${agentName}`; +}; + +export const getV2GetSpecificAgent = async ( + username: string, + agentName: string, + options?: RequestInit, +): Promise => { + return customMutator( + getGetV2GetSpecificAgentUrl(username, agentName), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV2GetSpecificAgentQueryKey = ( + username: string, + agentName: string, +) => { + return [`/api/store/agents/${username}/${agentName}`] as const; +}; + +export const getGetV2GetSpecificAgentQueryOptions = < + TData = Awaited>, + TError = HTTPValidationError, +>( + username: string, + agentName: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, +) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = + queryOptions?.queryKey ?? + getGetV2GetSpecificAgentQueryKey(username, agentName); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => + getV2GetSpecificAgent(username, agentName, { signal, ...requestOptions }); + + return { + queryKey, + queryFn, + enabled: !!(username && agentName), + ...queryOptions, + } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV2GetSpecificAgentQueryResult = NonNullable< + Awaited> +>; +export type GetV2GetSpecificAgentQueryError = HTTPValidationError; + +export function useGetV2GetSpecificAgent< + TData = Awaited>, + TError = HTTPValidationError, +>( + username: string, + agentName: string, + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV2GetSpecificAgent< + TData = Awaited>, + TError = HTTPValidationError, +>( + username: string, + agentName: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV2GetSpecificAgent< + TData = Awaited>, + TError = HTTPValidationError, +>( + username: string, + agentName: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary Get specific agent + */ + +export function useGetV2GetSpecificAgent< + TData = Awaited>, + TError = HTTPValidationError, +>( + username: string, + agentName: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV2GetSpecificAgentQueryOptions( + username, + agentName, + options, + ); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * Get Agent Graph from Store Listing Version ID. + * @summary Get agent graph + */ +export type getV2GetAgentGraphResponse200 = { + data: unknown; + status: 200; +}; + +export type getV2GetAgentGraphResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type getV2GetAgentGraphResponseComposite = + | getV2GetAgentGraphResponse200 + | getV2GetAgentGraphResponse422; + +export type getV2GetAgentGraphResponse = getV2GetAgentGraphResponseComposite & { + headers: Headers; +}; + +export const getGetV2GetAgentGraphUrl = (storeListingVersionId: string) => { + return `/api/store/graph/${storeListingVersionId}`; +}; + +export const getV2GetAgentGraph = async ( + storeListingVersionId: string, + options?: RequestInit, +): Promise => { + return customMutator( + getGetV2GetAgentGraphUrl(storeListingVersionId), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV2GetAgentGraphQueryKey = ( + storeListingVersionId: string, +) => { + return [`/api/store/graph/${storeListingVersionId}`] as const; +}; + +export const getGetV2GetAgentGraphQueryOptions = < + TData = Awaited>, + TError = HTTPValidationError, +>( + storeListingVersionId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, +) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = + queryOptions?.queryKey ?? + getGetV2GetAgentGraphQueryKey(storeListingVersionId); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => + getV2GetAgentGraph(storeListingVersionId, { signal, ...requestOptions }); + + return { + queryKey, + queryFn, + enabled: !!storeListingVersionId, + ...queryOptions, + } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV2GetAgentGraphQueryResult = NonNullable< + Awaited> +>; +export type GetV2GetAgentGraphQueryError = HTTPValidationError; + +export function useGetV2GetAgentGraph< + TData = Awaited>, + TError = HTTPValidationError, +>( + storeListingVersionId: string, + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV2GetAgentGraph< + TData = Awaited>, + TError = HTTPValidationError, +>( + storeListingVersionId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV2GetAgentGraph< + TData = Awaited>, + TError = HTTPValidationError, +>( + storeListingVersionId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary Get agent graph + */ + +export function useGetV2GetAgentGraph< + TData = Awaited>, + TError = HTTPValidationError, +>( + storeListingVersionId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV2GetAgentGraphQueryOptions( + storeListingVersionId, + options, + ); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * Get Store Agent Details from Store Listing Version ID. + * @summary Get agent by version + */ +export type getV2GetAgentByVersionResponse200 = { + data: StoreAgentDetails; + status: 200; +}; + +export type getV2GetAgentByVersionResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type getV2GetAgentByVersionResponseComposite = + | getV2GetAgentByVersionResponse200 + | getV2GetAgentByVersionResponse422; + +export type getV2GetAgentByVersionResponse = + getV2GetAgentByVersionResponseComposite & { + headers: Headers; + }; + +export const getGetV2GetAgentByVersionUrl = (storeListingVersionId: string) => { + return `/api/store/agents/${storeListingVersionId}`; +}; + +export const getV2GetAgentByVersion = async ( + storeListingVersionId: string, + options?: RequestInit, +): Promise => { + return customMutator( + getGetV2GetAgentByVersionUrl(storeListingVersionId), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV2GetAgentByVersionQueryKey = ( + storeListingVersionId: string, +) => { + return [`/api/store/agents/${storeListingVersionId}`] as const; +}; + +export const getGetV2GetAgentByVersionQueryOptions = < + TData = Awaited>, + TError = HTTPValidationError, +>( + storeListingVersionId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, +) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = + queryOptions?.queryKey ?? + getGetV2GetAgentByVersionQueryKey(storeListingVersionId); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => + getV2GetAgentByVersion(storeListingVersionId, { + signal, + ...requestOptions, + }); + + return { + queryKey, + queryFn, + enabled: !!storeListingVersionId, + ...queryOptions, + } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV2GetAgentByVersionQueryResult = NonNullable< + Awaited> +>; +export type GetV2GetAgentByVersionQueryError = HTTPValidationError; + +export function useGetV2GetAgentByVersion< + TData = Awaited>, + TError = HTTPValidationError, +>( + storeListingVersionId: string, + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV2GetAgentByVersion< + TData = Awaited>, + TError = HTTPValidationError, +>( + storeListingVersionId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV2GetAgentByVersion< + TData = Awaited>, + TError = HTTPValidationError, +>( + storeListingVersionId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary Get agent by version + */ + +export function useGetV2GetAgentByVersion< + TData = Awaited>, + TError = HTTPValidationError, +>( + storeListingVersionId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV2GetAgentByVersionQueryOptions( + storeListingVersionId, + options, + ); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * Create a review for a store agent. + +Args: + username: Creator's username + agent_name: Name/slug of the agent + review: Review details including score and optional comments + user_id: ID of authenticated user creating the review + +Returns: + The created review + * @summary Create agent review + */ +export type postV2CreateAgentReviewResponse200 = { + data: StoreReview; + status: 200; +}; + +export type postV2CreateAgentReviewResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type postV2CreateAgentReviewResponseComposite = + | postV2CreateAgentReviewResponse200 + | postV2CreateAgentReviewResponse422; + +export type postV2CreateAgentReviewResponse = + postV2CreateAgentReviewResponseComposite & { + headers: Headers; + }; + +export const getPostV2CreateAgentReviewUrl = ( + username: string, + agentName: string, +) => { + return `/api/store/agents/${username}/${agentName}/review`; +}; + +export const postV2CreateAgentReview = async ( + username: string, + agentName: string, + storeReviewCreate: StoreReviewCreate, + options?: RequestInit, +): Promise => { + return customMutator( + getPostV2CreateAgentReviewUrl(username, agentName), + { + ...options, + method: "POST", + headers: { "Content-Type": "application/json", ...options?.headers }, + body: JSON.stringify(storeReviewCreate), + }, + ); +}; + +export const getPostV2CreateAgentReviewMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { username: string; agentName: string; data: StoreReviewCreate }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { username: string; agentName: string; data: StoreReviewCreate }, + TContext +> => { + const mutationKey = ["postV2CreateAgentReview"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { username: string; agentName: string; data: StoreReviewCreate } + > = (props) => { + const { username, agentName, data } = props ?? {}; + + return postV2CreateAgentReview(username, agentName, data, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PostV2CreateAgentReviewMutationResult = NonNullable< + Awaited> +>; +export type PostV2CreateAgentReviewMutationBody = StoreReviewCreate; +export type PostV2CreateAgentReviewMutationError = HTTPValidationError; + +/** + * @summary Create agent review + */ +export const usePostV2CreateAgentReview = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { username: string; agentName: string; data: StoreReviewCreate }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { username: string; agentName: string; data: StoreReviewCreate }, + TContext +> => { + const mutationOptions = getPostV2CreateAgentReviewMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * This is needed for: +- Home Page Featured Creators +- Search Results Page + +--- + +To support this functionality we need: +- featured: bool - to limit the list to just featured agents +- search_query: str - vector search based on the creators profile description. +- sorted_by: [agent_rating, agent_runs] - + * @summary List store creators + */ +export type getV2ListStoreCreatorsResponse200 = { + data: CreatorsResponse; + status: 200; +}; + +export type getV2ListStoreCreatorsResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type getV2ListStoreCreatorsResponseComposite = + | getV2ListStoreCreatorsResponse200 + | getV2ListStoreCreatorsResponse422; + +export type getV2ListStoreCreatorsResponse = + getV2ListStoreCreatorsResponseComposite & { + headers: Headers; + }; + +export const getGetV2ListStoreCreatorsUrl = ( + params?: GetV2ListStoreCreatorsParams, +) => { + const normalizedParams = new URLSearchParams(); + + Object.entries(params || {}).forEach(([key, value]) => { + if (value !== undefined) { + normalizedParams.append(key, value === null ? "null" : value.toString()); + } + }); + + const stringifiedParams = normalizedParams.toString(); + + return stringifiedParams.length > 0 + ? `/api/store/creators?${stringifiedParams}` + : `/api/store/creators`; +}; + +export const getV2ListStoreCreators = async ( + params?: GetV2ListStoreCreatorsParams, + options?: RequestInit, +): Promise => { + return customMutator( + getGetV2ListStoreCreatorsUrl(params), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV2ListStoreCreatorsQueryKey = ( + params?: GetV2ListStoreCreatorsParams, +) => { + return [`/api/store/creators`, ...(params ? [params] : [])] as const; +}; + +export const getGetV2ListStoreCreatorsQueryOptions = < + TData = Awaited>, + TError = HTTPValidationError, +>( + params?: GetV2ListStoreCreatorsParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, +) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = + queryOptions?.queryKey ?? getGetV2ListStoreCreatorsQueryKey(params); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => + getV2ListStoreCreators(params, { signal, ...requestOptions }); + + return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV2ListStoreCreatorsQueryResult = NonNullable< + Awaited> +>; +export type GetV2ListStoreCreatorsQueryError = HTTPValidationError; + +export function useGetV2ListStoreCreators< + TData = Awaited>, + TError = HTTPValidationError, +>( + params: undefined | GetV2ListStoreCreatorsParams, + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV2ListStoreCreators< + TData = Awaited>, + TError = HTTPValidationError, +>( + params?: GetV2ListStoreCreatorsParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV2ListStoreCreators< + TData = Awaited>, + TError = HTTPValidationError, +>( + params?: GetV2ListStoreCreatorsParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary List store creators + */ + +export function useGetV2ListStoreCreators< + TData = Awaited>, + TError = HTTPValidationError, +>( + params?: GetV2ListStoreCreatorsParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV2ListStoreCreatorsQueryOptions(params, options); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * Get the details of a creator +- Creator Details Page + * @summary Get creator details + */ +export type getV2GetCreatorDetailsResponse200 = { + data: CreatorDetails; + status: 200; +}; + +export type getV2GetCreatorDetailsResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type getV2GetCreatorDetailsResponseComposite = + | getV2GetCreatorDetailsResponse200 + | getV2GetCreatorDetailsResponse422; + +export type getV2GetCreatorDetailsResponse = + getV2GetCreatorDetailsResponseComposite & { + headers: Headers; + }; + +export const getGetV2GetCreatorDetailsUrl = (username: string) => { + return `/api/store/creator/${username}`; +}; + +export const getV2GetCreatorDetails = async ( + username: string, + options?: RequestInit, +): Promise => { + return customMutator( + getGetV2GetCreatorDetailsUrl(username), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV2GetCreatorDetailsQueryKey = (username: string) => { + return [`/api/store/creator/${username}`] as const; +}; + +export const getGetV2GetCreatorDetailsQueryOptions = < + TData = Awaited>, + TError = HTTPValidationError, +>( + username: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, +) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = + queryOptions?.queryKey ?? getGetV2GetCreatorDetailsQueryKey(username); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => + getV2GetCreatorDetails(username, { signal, ...requestOptions }); + + return { + queryKey, + queryFn, + enabled: !!username, + ...queryOptions, + } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV2GetCreatorDetailsQueryResult = NonNullable< + Awaited> +>; +export type GetV2GetCreatorDetailsQueryError = HTTPValidationError; + +export function useGetV2GetCreatorDetails< + TData = Awaited>, + TError = HTTPValidationError, +>( + username: string, + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV2GetCreatorDetails< + TData = Awaited>, + TError = HTTPValidationError, +>( + username: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV2GetCreatorDetails< + TData = Awaited>, + TError = HTTPValidationError, +>( + username: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary Get creator details + */ + +export function useGetV2GetCreatorDetails< + TData = Awaited>, + TError = HTTPValidationError, +>( + username: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV2GetCreatorDetailsQueryOptions(username, options); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * @summary Get my agents + */ +export type getV2GetMyAgentsResponse200 = { + data: MyAgentsResponse; + status: 200; +}; + +export type getV2GetMyAgentsResponseComposite = getV2GetMyAgentsResponse200; + +export type getV2GetMyAgentsResponse = getV2GetMyAgentsResponseComposite & { + headers: Headers; +}; + +export const getGetV2GetMyAgentsUrl = () => { + return `/api/store/myagents`; +}; + +export const getV2GetMyAgents = async ( + options?: RequestInit, +): Promise => { + return customMutator(getGetV2GetMyAgentsUrl(), { + ...options, + method: "GET", + }); +}; + +export const getGetV2GetMyAgentsQueryKey = () => { + return [`/api/store/myagents`] as const; +}; + +export const getGetV2GetMyAgentsQueryOptions = < + TData = Awaited>, + TError = unknown, +>(options?: { + query?: Partial< + UseQueryOptions>, TError, TData> + >; + request?: SecondParameter; +}) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = queryOptions?.queryKey ?? getGetV2GetMyAgentsQueryKey(); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => getV2GetMyAgents({ signal, ...requestOptions }); + + return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV2GetMyAgentsQueryResult = NonNullable< + Awaited> +>; +export type GetV2GetMyAgentsQueryError = unknown; + +export function useGetV2GetMyAgents< + TData = Awaited>, + TError = unknown, +>( + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV2GetMyAgents< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV2GetMyAgents< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary Get my agents + */ + +export function useGetV2GetMyAgents< + TData = Awaited>, + TError = unknown, +>( + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV2GetMyAgentsQueryOptions(options); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * Delete a store listing submission. + +Args: + user_id (str): ID of the authenticated user + submission_id (str): ID of the submission to be deleted + +Returns: + bool: True if the submission was successfully deleted, False otherwise + * @summary Delete store submission + */ +export type deleteV2DeleteStoreSubmissionResponse200 = { + data: boolean; + status: 200; +}; + +export type deleteV2DeleteStoreSubmissionResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type deleteV2DeleteStoreSubmissionResponseComposite = + | deleteV2DeleteStoreSubmissionResponse200 + | deleteV2DeleteStoreSubmissionResponse422; + +export type deleteV2DeleteStoreSubmissionResponse = + deleteV2DeleteStoreSubmissionResponseComposite & { + headers: Headers; + }; + +export const getDeleteV2DeleteStoreSubmissionUrl = (submissionId: string) => { + return `/api/store/submissions/${submissionId}`; +}; + +export const deleteV2DeleteStoreSubmission = async ( + submissionId: string, + options?: RequestInit, +): Promise => { + return customMutator( + getDeleteV2DeleteStoreSubmissionUrl(submissionId), + { + ...options, + method: "DELETE", + }, + ); +}; + +export const getDeleteV2DeleteStoreSubmissionMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { submissionId: string }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { submissionId: string }, + TContext +> => { + const mutationKey = ["deleteV2DeleteStoreSubmission"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { submissionId: string } + > = (props) => { + const { submissionId } = props ?? {}; + + return deleteV2DeleteStoreSubmission(submissionId, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type DeleteV2DeleteStoreSubmissionMutationResult = NonNullable< + Awaited> +>; + +export type DeleteV2DeleteStoreSubmissionMutationError = HTTPValidationError; + +/** + * @summary Delete store submission + */ +export const useDeleteV2DeleteStoreSubmission = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { submissionId: string }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { submissionId: string }, + TContext +> => { + const mutationOptions = + getDeleteV2DeleteStoreSubmissionMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * Get a paginated list of store submissions for the authenticated user. + +Args: + user_id (str): ID of the authenticated user + page (int, optional): Page number for pagination. Defaults to 1. + page_size (int, optional): Number of submissions per page. Defaults to 20. + +Returns: + StoreListingsResponse: Paginated list of store submissions + +Raises: + HTTPException: If page or page_size are less than 1 + * @summary List my submissions + */ +export type getV2ListMySubmissionsResponse200 = { + data: StoreSubmissionsResponse; + status: 200; +}; + +export type getV2ListMySubmissionsResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type getV2ListMySubmissionsResponseComposite = + | getV2ListMySubmissionsResponse200 + | getV2ListMySubmissionsResponse422; + +export type getV2ListMySubmissionsResponse = + getV2ListMySubmissionsResponseComposite & { + headers: Headers; + }; + +export const getGetV2ListMySubmissionsUrl = ( + params?: GetV2ListMySubmissionsParams, +) => { + const normalizedParams = new URLSearchParams(); + + Object.entries(params || {}).forEach(([key, value]) => { + if (value !== undefined) { + normalizedParams.append(key, value === null ? "null" : value.toString()); + } + }); + + const stringifiedParams = normalizedParams.toString(); + + return stringifiedParams.length > 0 + ? `/api/store/submissions?${stringifiedParams}` + : `/api/store/submissions`; +}; + +export const getV2ListMySubmissions = async ( + params?: GetV2ListMySubmissionsParams, + options?: RequestInit, +): Promise => { + return customMutator( + getGetV2ListMySubmissionsUrl(params), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV2ListMySubmissionsQueryKey = ( + params?: GetV2ListMySubmissionsParams, +) => { + return [`/api/store/submissions`, ...(params ? [params] : [])] as const; +}; + +export const getGetV2ListMySubmissionsQueryOptions = < + TData = Awaited>, + TError = HTTPValidationError, +>( + params?: GetV2ListMySubmissionsParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, +) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = + queryOptions?.queryKey ?? getGetV2ListMySubmissionsQueryKey(params); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => + getV2ListMySubmissions(params, { signal, ...requestOptions }); + + return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV2ListMySubmissionsQueryResult = NonNullable< + Awaited> +>; +export type GetV2ListMySubmissionsQueryError = HTTPValidationError; + +export function useGetV2ListMySubmissions< + TData = Awaited>, + TError = HTTPValidationError, +>( + params: undefined | GetV2ListMySubmissionsParams, + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV2ListMySubmissions< + TData = Awaited>, + TError = HTTPValidationError, +>( + params?: GetV2ListMySubmissionsParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV2ListMySubmissions< + TData = Awaited>, + TError = HTTPValidationError, +>( + params?: GetV2ListMySubmissionsParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary List my submissions + */ + +export function useGetV2ListMySubmissions< + TData = Awaited>, + TError = HTTPValidationError, +>( + params?: GetV2ListMySubmissionsParams, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV2ListMySubmissionsQueryOptions(params, options); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} + +/** + * Create a new store listing submission. + +Args: + submission_request (StoreSubmissionRequest): The submission details + user_id (str): ID of the authenticated user submitting the listing + +Returns: + StoreSubmission: The created store submission + +Raises: + HTTPException: If there is an error creating the submission + * @summary Create store submission + */ +export type postV2CreateStoreSubmissionResponse200 = { + data: StoreSubmission; + status: 200; +}; + +export type postV2CreateStoreSubmissionResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type postV2CreateStoreSubmissionResponseComposite = + | postV2CreateStoreSubmissionResponse200 + | postV2CreateStoreSubmissionResponse422; + +export type postV2CreateStoreSubmissionResponse = + postV2CreateStoreSubmissionResponseComposite & { + headers: Headers; + }; + +export const getPostV2CreateStoreSubmissionUrl = () => { + return `/api/store/submissions`; +}; + +export const postV2CreateStoreSubmission = async ( + storeSubmissionRequest: StoreSubmissionRequest, + options?: RequestInit, +): Promise => { + return customMutator( + getPostV2CreateStoreSubmissionUrl(), + { + ...options, + method: "POST", + headers: { "Content-Type": "application/json", ...options?.headers }, + body: JSON.stringify(storeSubmissionRequest), + }, + ); +}; + +export const getPostV2CreateStoreSubmissionMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { data: StoreSubmissionRequest }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { data: StoreSubmissionRequest }, + TContext +> => { + const mutationKey = ["postV2CreateStoreSubmission"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { data: StoreSubmissionRequest } + > = (props) => { + const { data } = props ?? {}; + + return postV2CreateStoreSubmission(data, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PostV2CreateStoreSubmissionMutationResult = NonNullable< + Awaited> +>; +export type PostV2CreateStoreSubmissionMutationBody = StoreSubmissionRequest; +export type PostV2CreateStoreSubmissionMutationError = HTTPValidationError; + +/** + * @summary Create store submission + */ +export const usePostV2CreateStoreSubmission = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { data: StoreSubmissionRequest }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { data: StoreSubmissionRequest }, + TContext +> => { + const mutationOptions = + getPostV2CreateStoreSubmissionMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * Upload media (images/videos) for a store listing submission. + +Args: + file (UploadFile): The media file to upload + user_id (str): ID of the authenticated user uploading the media + +Returns: + str: URL of the uploaded media file + +Raises: + HTTPException: If there is an error uploading the media + * @summary Upload submission media + */ +export type postV2UploadSubmissionMediaResponse200 = { + data: unknown; + status: 200; +}; + +export type postV2UploadSubmissionMediaResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type postV2UploadSubmissionMediaResponseComposite = + | postV2UploadSubmissionMediaResponse200 + | postV2UploadSubmissionMediaResponse422; + +export type postV2UploadSubmissionMediaResponse = + postV2UploadSubmissionMediaResponseComposite & { + headers: Headers; + }; + +export const getPostV2UploadSubmissionMediaUrl = () => { + return `/api/store/submissions/media`; +}; + +export const postV2UploadSubmissionMedia = async ( + bodyPostV2UploadSubmissionMedia: BodyPostV2UploadSubmissionMedia, + options?: RequestInit, +): Promise => { + const formData = new FormData(); + formData.append(`file`, bodyPostV2UploadSubmissionMedia.file); + + return customMutator( + getPostV2UploadSubmissionMediaUrl(), + { + ...options, + method: "POST", + body: formData, + }, + ); +}; + +export const getPostV2UploadSubmissionMediaMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { data: BodyPostV2UploadSubmissionMedia }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { data: BodyPostV2UploadSubmissionMedia }, + TContext +> => { + const mutationKey = ["postV2UploadSubmissionMedia"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { data: BodyPostV2UploadSubmissionMedia } + > = (props) => { + const { data } = props ?? {}; + + return postV2UploadSubmissionMedia(data, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PostV2UploadSubmissionMediaMutationResult = NonNullable< + Awaited> +>; +export type PostV2UploadSubmissionMediaMutationBody = + BodyPostV2UploadSubmissionMedia; +export type PostV2UploadSubmissionMediaMutationError = HTTPValidationError; + +/** + * @summary Upload submission media + */ +export const usePostV2UploadSubmissionMedia = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { data: BodyPostV2UploadSubmissionMedia }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { data: BodyPostV2UploadSubmissionMedia }, + TContext +> => { + const mutationOptions = + getPostV2UploadSubmissionMediaMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * Generate an image for a store listing submission. + +Args: + agent_id (str): ID of the agent to generate an image for + user_id (str): ID of the authenticated user + +Returns: + JSONResponse: JSON containing the URL of the generated image + * @summary Generate submission image + */ +export type postV2GenerateSubmissionImageResponse200 = { + data: unknown; + status: 200; +}; + +export type postV2GenerateSubmissionImageResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type postV2GenerateSubmissionImageResponseComposite = + | postV2GenerateSubmissionImageResponse200 + | postV2GenerateSubmissionImageResponse422; + +export type postV2GenerateSubmissionImageResponse = + postV2GenerateSubmissionImageResponseComposite & { + headers: Headers; + }; + +export const getPostV2GenerateSubmissionImageUrl = ( + params: PostV2GenerateSubmissionImageParams, +) => { + const normalizedParams = new URLSearchParams(); + + Object.entries(params || {}).forEach(([key, value]) => { + if (value !== undefined) { + normalizedParams.append(key, value === null ? "null" : value.toString()); + } + }); + + const stringifiedParams = normalizedParams.toString(); + + return stringifiedParams.length > 0 + ? `/api/store/submissions/generate_image?${stringifiedParams}` + : `/api/store/submissions/generate_image`; +}; + +export const postV2GenerateSubmissionImage = async ( + params: PostV2GenerateSubmissionImageParams, + options?: RequestInit, +): Promise => { + return customMutator( + getPostV2GenerateSubmissionImageUrl(params), + { + ...options, + method: "POST", + }, + ); +}; + +export const getPostV2GenerateSubmissionImageMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { params: PostV2GenerateSubmissionImageParams }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { params: PostV2GenerateSubmissionImageParams }, + TContext +> => { + const mutationKey = ["postV2GenerateSubmissionImage"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { params: PostV2GenerateSubmissionImageParams } + > = (props) => { + const { params } = props ?? {}; + + return postV2GenerateSubmissionImage(params, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PostV2GenerateSubmissionImageMutationResult = NonNullable< + Awaited> +>; + +export type PostV2GenerateSubmissionImageMutationError = HTTPValidationError; + +/** + * @summary Generate submission image + */ +export const usePostV2GenerateSubmissionImage = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { params: PostV2GenerateSubmissionImageParams }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { params: PostV2GenerateSubmissionImageParams }, + TContext +> => { + const mutationOptions = + getPostV2GenerateSubmissionImageMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; +/** + * Download the agent file by streaming its content. + +Args: + store_listing_version_id (str): The ID of the agent to download + +Returns: + StreamingResponse: A streaming response containing the agent's graph data. + +Raises: + HTTPException: If the agent is not found or an unexpected error occurs. + * @summary Download agent file + */ +export type getV2DownloadAgentFileResponse200 = { + data: unknown; + status: 200; +}; + +export type getV2DownloadAgentFileResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type getV2DownloadAgentFileResponseComposite = + | getV2DownloadAgentFileResponse200 + | getV2DownloadAgentFileResponse422; + +export type getV2DownloadAgentFileResponse = + getV2DownloadAgentFileResponseComposite & { + headers: Headers; + }; + +export const getGetV2DownloadAgentFileUrl = (storeListingVersionId: string) => { + return `/api/store/download/agents/${storeListingVersionId}`; +}; + +export const getV2DownloadAgentFile = async ( + storeListingVersionId: string, + options?: RequestInit, +): Promise => { + return customMutator( + getGetV2DownloadAgentFileUrl(storeListingVersionId), + { + ...options, + method: "GET", + }, + ); +}; + +export const getGetV2DownloadAgentFileQueryKey = ( + storeListingVersionId: string, +) => { + return [`/api/store/download/agents/${storeListingVersionId}`] as const; +}; + +export const getGetV2DownloadAgentFileQueryOptions = < + TData = Awaited>, + TError = HTTPValidationError, +>( + storeListingVersionId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, +) => { + const { query: queryOptions, request: requestOptions } = options ?? {}; + + const queryKey = + queryOptions?.queryKey ?? + getGetV2DownloadAgentFileQueryKey(storeListingVersionId); + + const queryFn: QueryFunction< + Awaited> + > = ({ signal }) => + getV2DownloadAgentFile(storeListingVersionId, { + signal, + ...requestOptions, + }); + + return { + queryKey, + queryFn, + enabled: !!storeListingVersionId, + ...queryOptions, + } as UseQueryOptions< + Awaited>, + TError, + TData + > & { queryKey: DataTag }; +}; + +export type GetV2DownloadAgentFileQueryResult = NonNullable< + Awaited> +>; +export type GetV2DownloadAgentFileQueryError = HTTPValidationError; + +export function useGetV2DownloadAgentFile< + TData = Awaited>, + TError = HTTPValidationError, +>( + storeListingVersionId: string, + options: { + query: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + DefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): DefinedUseQueryResult & { + queryKey: DataTag; +}; +export function useGetV2DownloadAgentFile< + TData = Awaited>, + TError = HTTPValidationError, +>( + storeListingVersionId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + > & + Pick< + UndefinedInitialDataOptions< + Awaited>, + TError, + Awaited> + >, + "initialData" + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +export function useGetV2DownloadAgentFile< + TData = Awaited>, + TError = HTTPValidationError, +>( + storeListingVersionId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +}; +/** + * @summary Download agent file + */ + +export function useGetV2DownloadAgentFile< + TData = Awaited>, + TError = HTTPValidationError, +>( + storeListingVersionId: string, + options?: { + query?: Partial< + UseQueryOptions< + Awaited>, + TError, + TData + > + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseQueryResult & { + queryKey: DataTag; +} { + const queryOptions = getGetV2DownloadAgentFileQueryOptions( + storeListingVersionId, + options, + ); + + const query = useQuery(queryOptions, queryClient) as UseQueryResult< + TData, + TError + > & { queryKey: DataTag }; + + query.queryKey = queryOptions.queryKey; + + return query; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/endpoints/turnstile/turnstile.ts b/autogpt_platform/frontend/src/app/api/__generated__/endpoints/turnstile/turnstile.ts new file mode 100644 index 0000000000..6d9d937486 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/endpoints/turnstile/turnstile.ts @@ -0,0 +1,140 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import { useMutation } from "@tanstack/react-query"; +import type { + MutationFunction, + QueryClient, + UseMutationOptions, + UseMutationResult, +} from "@tanstack/react-query"; + +import type { HTTPValidationError } from "../../models/hTTPValidationError"; + +import type { TurnstileVerifyRequest } from "../../models/turnstileVerifyRequest"; + +import type { TurnstileVerifyResponse } from "../../models/turnstileVerifyResponse"; + +import { customMutator } from "../../../mutators/custom-mutator"; + +type SecondParameter unknown> = Parameters[1]; + +/** + * Verify a Cloudflare Turnstile token. +This endpoint verifies a token returned by the Cloudflare Turnstile challenge +on the client side. It returns whether the verification was successful. + * @summary Verify Turnstile Token + */ +export type postV2VerifyTurnstileTokenResponse200 = { + data: TurnstileVerifyResponse; + status: 200; +}; + +export type postV2VerifyTurnstileTokenResponse422 = { + data: HTTPValidationError; + status: 422; +}; + +export type postV2VerifyTurnstileTokenResponseComposite = + | postV2VerifyTurnstileTokenResponse200 + | postV2VerifyTurnstileTokenResponse422; + +export type postV2VerifyTurnstileTokenResponse = + postV2VerifyTurnstileTokenResponseComposite & { + headers: Headers; + }; + +export const getPostV2VerifyTurnstileTokenUrl = () => { + return `/api/turnstile/verify`; +}; + +export const postV2VerifyTurnstileToken = async ( + turnstileVerifyRequest: TurnstileVerifyRequest, + options?: RequestInit, +): Promise => { + return customMutator( + getPostV2VerifyTurnstileTokenUrl(), + { + ...options, + method: "POST", + headers: { "Content-Type": "application/json", ...options?.headers }, + body: JSON.stringify(turnstileVerifyRequest), + }, + ); +}; + +export const getPostV2VerifyTurnstileTokenMutationOptions = < + TError = HTTPValidationError, + TContext = unknown, +>(options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { data: TurnstileVerifyRequest }, + TContext + >; + request?: SecondParameter; +}): UseMutationOptions< + Awaited>, + TError, + { data: TurnstileVerifyRequest }, + TContext +> => { + const mutationKey = ["postV2VerifyTurnstileToken"]; + const { mutation: mutationOptions, request: requestOptions } = options + ? options.mutation && + "mutationKey" in options.mutation && + options.mutation.mutationKey + ? options + : { ...options, mutation: { ...options.mutation, mutationKey } } + : { mutation: { mutationKey }, request: undefined }; + + const mutationFn: MutationFunction< + Awaited>, + { data: TurnstileVerifyRequest } + > = (props) => { + const { data } = props ?? {}; + + return postV2VerifyTurnstileToken(data, requestOptions); + }; + + return { mutationFn, ...mutationOptions }; +}; + +export type PostV2VerifyTurnstileTokenMutationResult = NonNullable< + Awaited> +>; +export type PostV2VerifyTurnstileTokenMutationBody = TurnstileVerifyRequest; +export type PostV2VerifyTurnstileTokenMutationError = HTTPValidationError; + +/** + * @summary Verify Turnstile Token + */ +export const usePostV2VerifyTurnstileToken = < + TError = HTTPValidationError, + TContext = unknown, +>( + options?: { + mutation?: UseMutationOptions< + Awaited>, + TError, + { data: TurnstileVerifyRequest }, + TContext + >; + request?: SecondParameter; + }, + queryClient?: QueryClient, +): UseMutationResult< + Awaited>, + TError, + { data: TurnstileVerifyRequest }, + TContext +> => { + const mutationOptions = getPostV2VerifyTurnstileTokenMutationOptions(options); + + return useMutation(mutationOptions, queryClient); +}; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/aPIKeyCredentials.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/aPIKeyCredentials.ts new file mode 100644 index 0000000000..b91310a3ff --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/aPIKeyCredentials.ts @@ -0,0 +1,19 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { APIKeyCredentialsTitle } from "./aPIKeyCredentialsTitle"; +import type { APIKeyCredentialsExpiresAt } from "./aPIKeyCredentialsExpiresAt"; + +export interface APIKeyCredentials { + id?: string; + provider: string; + title?: APIKeyCredentialsTitle; + type?: "api_key"; + api_key: string; + /** Unix timestamp (seconds) indicating when the API key expires (if at all) */ + expires_at?: APIKeyCredentialsExpiresAt; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/aPIKeyCredentialsExpiresAt.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/aPIKeyCredentialsExpiresAt.ts new file mode 100644 index 0000000000..a33e4a5a0d --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/aPIKeyCredentialsExpiresAt.ts @@ -0,0 +1,12 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +/** + * Unix timestamp (seconds) indicating when the API key expires (if at all) + */ +export type APIKeyCredentialsExpiresAt = number | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/aPIKeyCredentialsTitle.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/aPIKeyCredentialsTitle.ts new file mode 100644 index 0000000000..476b44abae --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/aPIKeyCredentialsTitle.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type APIKeyCredentialsTitle = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/aPIKeyPermission.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/aPIKeyPermission.ts new file mode 100644 index 0000000000..bae84cd1fd --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/aPIKeyPermission.ts @@ -0,0 +1,18 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type APIKeyPermission = + (typeof APIKeyPermission)[keyof typeof APIKeyPermission]; + +// eslint-disable-next-line @typescript-eslint/no-redeclare +export const APIKeyPermission = { + EXECUTE_GRAPH: "EXECUTE_GRAPH", + READ_GRAPH: "READ_GRAPH", + EXECUTE_BLOCK: "EXECUTE_BLOCK", + READ_BLOCK: "READ_BLOCK", +} as const; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/aPIKeyStatus.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/aPIKeyStatus.ts new file mode 100644 index 0000000000..88dc84ae77 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/aPIKeyStatus.ts @@ -0,0 +1,16 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type APIKeyStatus = (typeof APIKeyStatus)[keyof typeof APIKeyStatus]; + +// eslint-disable-next-line @typescript-eslint/no-redeclare +export const APIKeyStatus = { + ACTIVE: "ACTIVE", + REVOKED: "REVOKED", + SUSPENDED: "SUSPENDED", +} as const; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/aPIKeyWithoutHash.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/aPIKeyWithoutHash.ts new file mode 100644 index 0000000000..0165c66c18 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/aPIKeyWithoutHash.ts @@ -0,0 +1,26 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { APIKeyStatus } from "./aPIKeyStatus"; +import type { APIKeyPermission } from "./aPIKeyPermission"; +import type { APIKeyWithoutHashLastUsedAt } from "./aPIKeyWithoutHashLastUsedAt"; +import type { APIKeyWithoutHashRevokedAt } from "./aPIKeyWithoutHashRevokedAt"; +import type { APIKeyWithoutHashDescription } from "./aPIKeyWithoutHashDescription"; + +export interface APIKeyWithoutHash { + id: string; + name: string; + prefix: string; + postfix: string; + status: APIKeyStatus; + permissions: APIKeyPermission[]; + created_at: string; + last_used_at: APIKeyWithoutHashLastUsedAt; + revoked_at: APIKeyWithoutHashRevokedAt; + description: APIKeyWithoutHashDescription; + user_id: string; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/aPIKeyWithoutHashDescription.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/aPIKeyWithoutHashDescription.ts new file mode 100644 index 0000000000..46c9963d10 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/aPIKeyWithoutHashDescription.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type APIKeyWithoutHashDescription = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/aPIKeyWithoutHashLastUsedAt.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/aPIKeyWithoutHashLastUsedAt.ts new file mode 100644 index 0000000000..b8e1188d44 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/aPIKeyWithoutHashLastUsedAt.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type APIKeyWithoutHashLastUsedAt = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/aPIKeyWithoutHashRevokedAt.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/aPIKeyWithoutHashRevokedAt.ts new file mode 100644 index 0000000000..bd658f4624 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/aPIKeyWithoutHashRevokedAt.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type APIKeyWithoutHashRevokedAt = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/addUserCreditsResponse.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/addUserCreditsResponse.ts new file mode 100644 index 0000000000..7b5401117c --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/addUserCreditsResponse.ts @@ -0,0 +1,12 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export interface AddUserCreditsResponse { + new_balance: number; + transaction_key: string; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/agentExecutionStatus.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/agentExecutionStatus.ts new file mode 100644 index 0000000000..59e5c6f655 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/agentExecutionStatus.ts @@ -0,0 +1,20 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type AgentExecutionStatus = + (typeof AgentExecutionStatus)[keyof typeof AgentExecutionStatus]; + +// eslint-disable-next-line @typescript-eslint/no-redeclare +export const AgentExecutionStatus = { + INCOMPLETE: "INCOMPLETE", + QUEUED: "QUEUED", + RUNNING: "RUNNING", + COMPLETED: "COMPLETED", + TERMINATED: "TERMINATED", + FAILED: "FAILED", +} as const; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/apiResponse.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/apiResponse.ts new file mode 100644 index 0000000000..a238870205 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/apiResponse.ts @@ -0,0 +1,14 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { Document } from "./document"; + +export interface ApiResponse { + answer: string; + documents: Document[]; + success: boolean; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/autoTopUpConfig.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/autoTopUpConfig.ts new file mode 100644 index 0000000000..eb5e978069 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/autoTopUpConfig.ts @@ -0,0 +1,12 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export interface AutoTopUpConfig { + amount: number; + threshold: number; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/baseGraphInput.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/baseGraphInput.ts new file mode 100644 index 0000000000..fa830948f6 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/baseGraphInput.ts @@ -0,0 +1,23 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { Node } from "./node"; +import type { Link } from "./link"; +import type { BaseGraphInputForkedFromId } from "./baseGraphInputForkedFromId"; +import type { BaseGraphInputForkedFromVersion } from "./baseGraphInputForkedFromVersion"; + +export interface BaseGraphInput { + id?: string; + version?: number; + is_active?: boolean; + name: string; + description: string; + nodes?: Node[]; + links?: Link[]; + forked_from_id?: BaseGraphInputForkedFromId; + forked_from_version?: BaseGraphInputForkedFromVersion; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/baseGraphInputForkedFromId.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/baseGraphInputForkedFromId.ts new file mode 100644 index 0000000000..a7636e58e2 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/baseGraphInputForkedFromId.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type BaseGraphInputForkedFromId = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/baseGraphInputForkedFromVersion.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/baseGraphInputForkedFromVersion.ts new file mode 100644 index 0000000000..65dc4e6004 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/baseGraphInputForkedFromVersion.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type BaseGraphInputForkedFromVersion = number | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/baseGraphOutput.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/baseGraphOutput.ts new file mode 100644 index 0000000000..22946f2918 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/baseGraphOutput.ts @@ -0,0 +1,27 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { Node } from "./node"; +import type { Link } from "./link"; +import type { BaseGraphOutputForkedFromId } from "./baseGraphOutputForkedFromId"; +import type { BaseGraphOutputForkedFromVersion } from "./baseGraphOutputForkedFromVersion"; +import type { BaseGraphOutputInputSchema } from "./baseGraphOutputInputSchema"; +import type { BaseGraphOutputOutputSchema } from "./baseGraphOutputOutputSchema"; + +export interface BaseGraphOutput { + id?: string; + version?: number; + is_active?: boolean; + name: string; + description: string; + nodes?: Node[]; + links?: Link[]; + forked_from_id?: BaseGraphOutputForkedFromId; + forked_from_version?: BaseGraphOutputForkedFromVersion; + readonly input_schema: BaseGraphOutputInputSchema; + readonly output_schema: BaseGraphOutputOutputSchema; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/baseGraphOutputForkedFromId.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/baseGraphOutputForkedFromId.ts new file mode 100644 index 0000000000..3775a99a5c --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/baseGraphOutputForkedFromId.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type BaseGraphOutputForkedFromId = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/baseGraphOutputForkedFromVersion.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/baseGraphOutputForkedFromVersion.ts new file mode 100644 index 0000000000..b2f46fca2a --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/baseGraphOutputForkedFromVersion.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type BaseGraphOutputForkedFromVersion = number | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/baseGraphOutputInputSchema.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/baseGraphOutputInputSchema.ts new file mode 100644 index 0000000000..8b64c5e137 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/baseGraphOutputInputSchema.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type BaseGraphOutputInputSchema = { [key: string]: unknown }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/baseGraphOutputOutputSchema.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/baseGraphOutputOutputSchema.ts new file mode 100644 index 0000000000..ace1f96737 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/baseGraphOutputOutputSchema.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type BaseGraphOutputOutputSchema = { [key: string]: unknown }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/bodyPostV1Callback.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/bodyPostV1Callback.ts new file mode 100644 index 0000000000..5d6db6f166 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/bodyPostV1Callback.ts @@ -0,0 +1,12 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export interface BodyPostV1Callback { + code: string; + state_token: string; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/bodyPostV1ExecuteGraphAgent.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/bodyPostV1ExecuteGraphAgent.ts new file mode 100644 index 0000000000..1bab4130ae --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/bodyPostV1ExecuteGraphAgent.ts @@ -0,0 +1,14 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { BodyPostV1ExecuteGraphAgentInputs } from "./bodyPostV1ExecuteGraphAgentInputs"; +import type { BodyPostV1ExecuteGraphAgentCredentialsInputs } from "./bodyPostV1ExecuteGraphAgentCredentialsInputs"; + +export interface BodyPostV1ExecuteGraphAgent { + inputs?: BodyPostV1ExecuteGraphAgentInputs; + credentials_inputs?: BodyPostV1ExecuteGraphAgentCredentialsInputs; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/bodyPostV1ExecuteGraphAgentCredentialsInputs.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/bodyPostV1ExecuteGraphAgentCredentialsInputs.ts new file mode 100644 index 0000000000..6c37b20ef4 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/bodyPostV1ExecuteGraphAgentCredentialsInputs.ts @@ -0,0 +1,12 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { CredentialsMetaInput } from "./credentialsMetaInput"; + +export type BodyPostV1ExecuteGraphAgentCredentialsInputs = { + [key: string]: CredentialsMetaInput; +}; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/bodyPostV1ExecuteGraphAgentInputs.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/bodyPostV1ExecuteGraphAgentInputs.ts new file mode 100644 index 0000000000..759c51fc1a --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/bodyPostV1ExecuteGraphAgentInputs.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type BodyPostV1ExecuteGraphAgentInputs = { [key: string]: unknown }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/bodyPostV1LogRawAnalytics.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/bodyPostV1LogRawAnalytics.ts new file mode 100644 index 0000000000..92362203ae --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/bodyPostV1LogRawAnalytics.ts @@ -0,0 +1,16 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { BodyPostV1LogRawAnalyticsData } from "./bodyPostV1LogRawAnalyticsData"; + +export interface BodyPostV1LogRawAnalytics { + type: string; + /** The data to log */ + data: BodyPostV1LogRawAnalyticsData; + /** Indexable field for any count based analytical measures like page order clicking, tutorial step completion, etc. */ + data_index: string; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/bodyPostV1LogRawAnalyticsData.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/bodyPostV1LogRawAnalyticsData.ts new file mode 100644 index 0000000000..0ef9be6f56 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/bodyPostV1LogRawAnalyticsData.ts @@ -0,0 +1,12 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +/** + * The data to log + */ +export type BodyPostV1LogRawAnalyticsData = { [key: string]: unknown }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/bodyPostV2AddCreditsToUser.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/bodyPostV2AddCreditsToUser.ts new file mode 100644 index 0000000000..af7f628315 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/bodyPostV2AddCreditsToUser.ts @@ -0,0 +1,13 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export interface BodyPostV2AddCreditsToUser { + user_id: string; + amount: number; + comments: string; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/bodyPostV2AddMarketplaceAgent.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/bodyPostV2AddMarketplaceAgent.ts new file mode 100644 index 0000000000..154ae8047c --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/bodyPostV2AddMarketplaceAgent.ts @@ -0,0 +1,11 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export interface BodyPostV2AddMarketplaceAgent { + store_listing_version_id: string; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/bodyPostV2ExecuteAPreset.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/bodyPostV2ExecuteAPreset.ts new file mode 100644 index 0000000000..33041abadc --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/bodyPostV2ExecuteAPreset.ts @@ -0,0 +1,12 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { BodyPostV2ExecuteAPresetInputs } from "./bodyPostV2ExecuteAPresetInputs"; + +export interface BodyPostV2ExecuteAPreset { + inputs?: BodyPostV2ExecuteAPresetInputs; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/bodyPostV2ExecuteAPresetInputs.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/bodyPostV2ExecuteAPresetInputs.ts new file mode 100644 index 0000000000..fbfdc61bf2 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/bodyPostV2ExecuteAPresetInputs.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type BodyPostV2ExecuteAPresetInputs = { [key: string]: unknown }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/bodyPostV2UploadSubmissionMedia.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/bodyPostV2UploadSubmissionMedia.ts new file mode 100644 index 0000000000..0fe626c328 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/bodyPostV2UploadSubmissionMedia.ts @@ -0,0 +1,11 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export interface BodyPostV2UploadSubmissionMedia { + file: Blob; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/chatRequest.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/chatRequest.ts new file mode 100644 index 0000000000..b50b426282 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/chatRequest.ts @@ -0,0 +1,17 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { Message } from "./message"; +import type { ChatRequestGraphId } from "./chatRequestGraphId"; + +export interface ChatRequest { + query: string; + conversation_history: Message[]; + message_id: string; + include_graph_data?: boolean; + graph_id?: ChatRequestGraphId; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/chatRequestGraphId.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/chatRequestGraphId.ts new file mode 100644 index 0000000000..c5f583ee62 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/chatRequestGraphId.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type ChatRequestGraphId = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/createAPIKeyRequest.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/createAPIKeyRequest.ts new file mode 100644 index 0000000000..660f5023ab --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/createAPIKeyRequest.ts @@ -0,0 +1,15 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { APIKeyPermission } from "./aPIKeyPermission"; +import type { CreateAPIKeyRequestDescription } from "./createAPIKeyRequestDescription"; + +export interface CreateAPIKeyRequest { + name: string; + permissions: APIKeyPermission[]; + description?: CreateAPIKeyRequestDescription; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/createAPIKeyRequestDescription.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/createAPIKeyRequestDescription.ts new file mode 100644 index 0000000000..e284be9925 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/createAPIKeyRequestDescription.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type CreateAPIKeyRequestDescription = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/createAPIKeyResponse.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/createAPIKeyResponse.ts new file mode 100644 index 0000000000..bfd8cf62eb --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/createAPIKeyResponse.ts @@ -0,0 +1,13 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { APIKeyWithoutHash } from "./aPIKeyWithoutHash"; + +export interface CreateAPIKeyResponse { + api_key: APIKeyWithoutHash; + plain_text_key: string; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/createGraph.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/createGraph.ts new file mode 100644 index 0000000000..8548196cce --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/createGraph.ts @@ -0,0 +1,12 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { Graph } from "./graph"; + +export interface CreateGraph { + graph: Graph; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/creator.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/creator.ts new file mode 100644 index 0000000000..78744ea400 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/creator.ts @@ -0,0 +1,18 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export interface Creator { + name: string; + username: string; + description: string; + avatar_url: string; + num_agents: number; + agent_rating: number; + agent_runs: number; + is_featured: boolean; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/creatorDetails.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/creatorDetails.ts new file mode 100644 index 0000000000..a28c983faa --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/creatorDetails.ts @@ -0,0 +1,18 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export interface CreatorDetails { + name: string; + username: string; + description: string; + links: string[]; + avatar_url: string; + agent_rating: number; + agent_runs: number; + top_categories: string[]; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/creatorsResponse.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/creatorsResponse.ts new file mode 100644 index 0000000000..315cbd1e34 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/creatorsResponse.ts @@ -0,0 +1,14 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { Creator } from "./creator"; +import type { Pagination } from "./pagination"; + +export interface CreatorsResponse { + creators: Creator[]; + pagination: Pagination; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/credentialsDeletionNeedsConfirmationResponse.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/credentialsDeletionNeedsConfirmationResponse.ts new file mode 100644 index 0000000000..6352fc9c39 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/credentialsDeletionNeedsConfirmationResponse.ts @@ -0,0 +1,13 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export interface CredentialsDeletionNeedsConfirmationResponse { + deleted?: false; + need_confirmation?: true; + message: string; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/credentialsDeletionResponse.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/credentialsDeletionResponse.ts new file mode 100644 index 0000000000..2c2a424aca --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/credentialsDeletionResponse.ts @@ -0,0 +1,14 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { CredentialsDeletionResponseRevoked } from "./credentialsDeletionResponseRevoked"; + +export interface CredentialsDeletionResponse { + deleted?: true; + /** Indicates whether the credentials were also revoked by their provider. `None`/`null` if not applicable, e.g. when deleting non-revocable credentials such as API keys. */ + revoked: CredentialsDeletionResponseRevoked; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/credentialsDeletionResponseRevoked.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/credentialsDeletionResponseRevoked.ts new file mode 100644 index 0000000000..08a8b79bd9 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/credentialsDeletionResponseRevoked.ts @@ -0,0 +1,12 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +/** + * Indicates whether the credentials were also revoked by their provider. `None`/`null` if not applicable, e.g. when deleting non-revocable credentials such as API keys. + */ +export type CredentialsDeletionResponseRevoked = boolean | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/credentialsMetaInput.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/credentialsMetaInput.ts new file mode 100644 index 0000000000..bbff8a8227 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/credentialsMetaInput.ts @@ -0,0 +1,17 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { CredentialsMetaInputTitle } from "./credentialsMetaInputTitle"; +import type { ProviderName } from "./providerName"; +import type { CredentialsMetaInputType } from "./credentialsMetaInputType"; + +export interface CredentialsMetaInput { + id: string; + title?: CredentialsMetaInputTitle; + provider: ProviderName; + type: CredentialsMetaInputType; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/credentialsMetaInputTitle.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/credentialsMetaInputTitle.ts new file mode 100644 index 0000000000..1befe2af4e --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/credentialsMetaInputTitle.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type CredentialsMetaInputTitle = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/credentialsMetaInputType.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/credentialsMetaInputType.ts new file mode 100644 index 0000000000..ec13a6f1a5 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/credentialsMetaInputType.ts @@ -0,0 +1,18 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type CredentialsMetaInputType = + (typeof CredentialsMetaInputType)[keyof typeof CredentialsMetaInputType]; + +// eslint-disable-next-line @typescript-eslint/no-redeclare +export const CredentialsMetaInputType = { + api_key: "api_key", + oauth2: "oauth2", + user_password: "user_password", + host_scoped: "host_scoped", +} as const; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/credentialsMetaResponse.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/credentialsMetaResponse.ts new file mode 100644 index 0000000000..bff9e1b95d --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/credentialsMetaResponse.ts @@ -0,0 +1,23 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { CredentialsMetaResponseType } from "./credentialsMetaResponseType"; +import type { CredentialsMetaResponseTitle } from "./credentialsMetaResponseTitle"; +import type { CredentialsMetaResponseScopes } from "./credentialsMetaResponseScopes"; +import type { CredentialsMetaResponseUsername } from "./credentialsMetaResponseUsername"; +import type { CredentialsMetaResponseHost } from "./credentialsMetaResponseHost"; + +export interface CredentialsMetaResponse { + id: string; + provider: string; + type: CredentialsMetaResponseType; + title: CredentialsMetaResponseTitle; + scopes: CredentialsMetaResponseScopes; + username: CredentialsMetaResponseUsername; + /** Host pattern for host-scoped credentials */ + host?: CredentialsMetaResponseHost; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/credentialsMetaResponseHost.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/credentialsMetaResponseHost.ts new file mode 100644 index 0000000000..d6b4a38cb3 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/credentialsMetaResponseHost.ts @@ -0,0 +1,12 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +/** + * Host pattern for host-scoped credentials + */ +export type CredentialsMetaResponseHost = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/credentialsMetaResponseScopes.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/credentialsMetaResponseScopes.ts new file mode 100644 index 0000000000..fe012b2bc2 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/credentialsMetaResponseScopes.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type CredentialsMetaResponseScopes = string[] | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/credentialsMetaResponseTitle.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/credentialsMetaResponseTitle.ts new file mode 100644 index 0000000000..915705495b --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/credentialsMetaResponseTitle.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type CredentialsMetaResponseTitle = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/credentialsMetaResponseType.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/credentialsMetaResponseType.ts new file mode 100644 index 0000000000..a8b1fce8dc --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/credentialsMetaResponseType.ts @@ -0,0 +1,18 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type CredentialsMetaResponseType = + (typeof CredentialsMetaResponseType)[keyof typeof CredentialsMetaResponseType]; + +// eslint-disable-next-line @typescript-eslint/no-redeclare +export const CredentialsMetaResponseType = { + api_key: "api_key", + oauth2: "oauth2", + user_password: "user_password", + host_scoped: "host_scoped", +} as const; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/credentialsMetaResponseUsername.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/credentialsMetaResponseUsername.ts new file mode 100644 index 0000000000..79c173f738 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/credentialsMetaResponseUsername.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type CredentialsMetaResponseUsername = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/creditTransactionType.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/creditTransactionType.ts new file mode 100644 index 0000000000..030b6258a6 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/creditTransactionType.ts @@ -0,0 +1,19 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type CreditTransactionType = + (typeof CreditTransactionType)[keyof typeof CreditTransactionType]; + +// eslint-disable-next-line @typescript-eslint/no-redeclare +export const CreditTransactionType = { + TOP_UP: "TOP_UP", + USAGE: "USAGE", + GRANT: "GRANT", + REFUND: "REFUND", + CARD_CHECK: "CARD_CHECK", +} as const; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/deleteGraphResponse.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/deleteGraphResponse.ts new file mode 100644 index 0000000000..202d0d83af --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/deleteGraphResponse.ts @@ -0,0 +1,11 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export interface DeleteGraphResponse { + version_counts: number; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/deleteV1DeleteCredentials200.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/deleteV1DeleteCredentials200.ts new file mode 100644 index 0000000000..0673a0189f --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/deleteV1DeleteCredentials200.ts @@ -0,0 +1,13 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { CredentialsDeletionResponse } from "./credentialsDeletionResponse"; +import type { CredentialsDeletionNeedsConfirmationResponse } from "./credentialsDeletionNeedsConfirmationResponse"; + +export type DeleteV1DeleteCredentials200 = + | CredentialsDeletionResponse + | CredentialsDeletionNeedsConfirmationResponse; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/deleteV1DeleteCredentialsParams.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/deleteV1DeleteCredentialsParams.ts new file mode 100644 index 0000000000..33a1c58020 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/deleteV1DeleteCredentialsParams.ts @@ -0,0 +1,11 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type DeleteV1DeleteCredentialsParams = { + force?: boolean; +}; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/deleteV1DeleteExecutionSchedule200.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/deleteV1DeleteExecutionSchedule200.ts new file mode 100644 index 0000000000..9f19067bc1 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/deleteV1DeleteExecutionSchedule200.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type DeleteV1DeleteExecutionSchedule200 = { [key: string]: unknown }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/document.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/document.ts new file mode 100644 index 0000000000..f65ea6887f --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/document.ts @@ -0,0 +1,12 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export interface Document { + url: string; + relevance_score: number; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/executeGraphResponse.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/executeGraphResponse.ts new file mode 100644 index 0000000000..28971aec93 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/executeGraphResponse.ts @@ -0,0 +1,11 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export interface ExecuteGraphResponse { + graph_exec_id: string; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/getV1GetCredential200.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/getV1GetCredential200.ts new file mode 100644 index 0000000000..2cba7f9def --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/getV1GetCredential200.ts @@ -0,0 +1,17 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { OAuth2Credentials } from "./oAuth2Credentials"; +import type { APIKeyCredentials } from "./aPIKeyCredentials"; +import type { UserPasswordCredentials } from "./userPasswordCredentials"; +import type { HostScopedCredentialsOutput } from "./hostScopedCredentialsOutput"; + +export type GetV1GetCredential200 = + | OAuth2Credentials + | APIKeyCredentials + | UserPasswordCredentials + | HostScopedCredentialsOutput; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/getV1GetCreditHistoryParams.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/getV1GetCreditHistoryParams.ts new file mode 100644 index 0000000000..90c8ecd364 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/getV1GetCreditHistoryParams.ts @@ -0,0 +1,13 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type GetV1GetCreditHistoryParams = { + transaction_time?: string | null; + transaction_type?: string | null; + transaction_count_limit?: number; +}; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/getV1GetExecutionDetails200.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/getV1GetExecutionDetails200.ts new file mode 100644 index 0000000000..2bbd8a1492 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/getV1GetExecutionDetails200.ts @@ -0,0 +1,13 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { GraphExecution } from "./graphExecution"; +import type { GraphExecutionWithNodes } from "./graphExecutionWithNodes"; + +export type GetV1GetExecutionDetails200 = + | GraphExecution + | GraphExecutionWithNodes; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/getV1GetGraphVersionParams.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/getV1GetGraphVersionParams.ts new file mode 100644 index 0000000000..521a8754ac --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/getV1GetGraphVersionParams.ts @@ -0,0 +1,11 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type GetV1GetGraphVersionParams = { + for_export?: boolean; +}; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/getV1GetSpecificGraphParams.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/getV1GetSpecificGraphParams.ts new file mode 100644 index 0000000000..e30abfea86 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/getV1GetSpecificGraphParams.ts @@ -0,0 +1,12 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type GetV1GetSpecificGraphParams = { + version?: number | null; + for_export?: boolean; +}; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/getV1GetUserCredits200.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/getV1GetUserCredits200.ts new file mode 100644 index 0000000000..fb035936b6 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/getV1GetUserCredits200.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type GetV1GetUserCredits200 = { [key: string]: number }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/getV1ListAvailableBlocks200Item.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/getV1ListAvailableBlocks200Item.ts new file mode 100644 index 0000000000..7a6892363d --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/getV1ListAvailableBlocks200Item.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type GetV1ListAvailableBlocks200Item = { [key: string]: unknown }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/getV1ListUserApiKeys200.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/getV1ListUserApiKeys200.ts new file mode 100644 index 0000000000..e919f16d5b --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/getV1ListUserApiKeys200.ts @@ -0,0 +1,13 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { APIKeyWithoutHash } from "./aPIKeyWithoutHash"; +import type { GetV1ListUserApiKeys200AnyOf } from "./getV1ListUserApiKeys200AnyOf"; + +export type GetV1ListUserApiKeys200 = + | APIKeyWithoutHash[] + | GetV1ListUserApiKeys200AnyOf; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/getV1ListUserApiKeys200AnyOf.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/getV1ListUserApiKeys200AnyOf.ts new file mode 100644 index 0000000000..39163009f0 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/getV1ListUserApiKeys200AnyOf.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type GetV1ListUserApiKeys200AnyOf = { [key: string]: string }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/getV1LoginParams.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/getV1LoginParams.ts new file mode 100644 index 0000000000..1b87a2aa67 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/getV1LoginParams.ts @@ -0,0 +1,11 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type GetV1LoginParams = { + scopes?: string; +}; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/getV1ManagePaymentMethods200.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/getV1ManagePaymentMethods200.ts new file mode 100644 index 0000000000..9668a380fa --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/getV1ManagePaymentMethods200.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type GetV1ManagePaymentMethods200 = { [key: string]: string }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/getV2GetAdminListingsHistoryParams.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/getV2GetAdminListingsHistoryParams.ts new file mode 100644 index 0000000000..44e04a8175 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/getV2GetAdminListingsHistoryParams.ts @@ -0,0 +1,15 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { SubmissionStatus } from "./submissionStatus"; + +export type GetV2GetAdminListingsHistoryParams = { + status?: SubmissionStatus | null; + search?: string | null; + page?: number; + page_size?: number; +}; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/getV2GetAgentByStoreId200.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/getV2GetAgentByStoreId200.ts new file mode 100644 index 0000000000..350cf20566 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/getV2GetAgentByStoreId200.ts @@ -0,0 +1,10 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { LibraryAgent } from "./libraryAgent"; + +export type GetV2GetAgentByStoreId200 = LibraryAgent | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/getV2GetAllUsersHistoryParams.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/getV2GetAllUsersHistoryParams.ts new file mode 100644 index 0000000000..2b1a82a100 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/getV2GetAllUsersHistoryParams.ts @@ -0,0 +1,15 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { CreditTransactionType } from "./creditTransactionType"; + +export type GetV2GetAllUsersHistoryParams = { + search?: string | null; + page?: number; + page_size?: number; + transaction_filter?: CreditTransactionType | null; +}; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/getV2GetLibraryAgentByGraphIdParams.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/getV2GetLibraryAgentByGraphIdParams.ts new file mode 100644 index 0000000000..0bb87f620a --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/getV2GetLibraryAgentByGraphIdParams.ts @@ -0,0 +1,11 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type GetV2GetLibraryAgentByGraphIdParams = { + version?: number | null; +}; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/getV2ListLibraryAgentsParams.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/getV2ListLibraryAgentsParams.ts new file mode 100644 index 0000000000..df934ad491 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/getV2ListLibraryAgentsParams.ts @@ -0,0 +1,29 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { LibraryAgentSort } from "./libraryAgentSort"; + +export type GetV2ListLibraryAgentsParams = { + /** + * Search term to filter agents + */ + search_term?: string | null; + /** + * Criteria to sort results by + */ + sort_by?: LibraryAgentSort; + /** + * Page number to retrieve (must be >= 1) + * @minimum 1 + */ + page?: number; + /** + * Number of agents per page (must be >= 1) + * @minimum 1 + */ + page_size?: number; +}; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/getV2ListMySubmissionsParams.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/getV2ListMySubmissionsParams.ts new file mode 100644 index 0000000000..515a5f04b8 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/getV2ListMySubmissionsParams.ts @@ -0,0 +1,12 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type GetV2ListMySubmissionsParams = { + page?: number; + page_size?: number; +}; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/getV2ListPresetsParams.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/getV2ListPresetsParams.ts new file mode 100644 index 0000000000..cf7fc3b2b6 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/getV2ListPresetsParams.ts @@ -0,0 +1,22 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type GetV2ListPresetsParams = { + /** + * @minimum 1 + */ + page?: number; + /** + * @minimum 1 + */ + page_size?: number; + /** + * Allows to filter presets by a specific agent graph + */ + graph_id: string | null; +}; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/getV2ListStoreAgentsParams.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/getV2ListStoreAgentsParams.ts new file mode 100644 index 0000000000..dc3461ec61 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/getV2ListStoreAgentsParams.ts @@ -0,0 +1,17 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type GetV2ListStoreAgentsParams = { + featured?: boolean; + creator?: string | null; + sorted_by?: string | null; + search_query?: string | null; + category?: string | null; + page?: number; + page_size?: number; +}; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/getV2ListStoreCreatorsParams.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/getV2ListStoreCreatorsParams.ts new file mode 100644 index 0000000000..61dfb39be0 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/getV2ListStoreCreatorsParams.ts @@ -0,0 +1,15 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type GetV2ListStoreCreatorsParams = { + featured?: boolean; + search_query?: string | null; + sorted_by?: string | null; + page?: number; + page_size?: number; +}; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/graph.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/graph.ts new file mode 100644 index 0000000000..02516bee1f --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/graph.ts @@ -0,0 +1,25 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { Node } from "./node"; +import type { Link } from "./link"; +import type { GraphForkedFromId } from "./graphForkedFromId"; +import type { GraphForkedFromVersion } from "./graphForkedFromVersion"; +import type { BaseGraphInput } from "./baseGraphInput"; + +export interface Graph { + id?: string; + version?: number; + is_active?: boolean; + name: string; + description: string; + nodes?: Node[]; + links?: Link[]; + forked_from_id?: GraphForkedFromId; + forked_from_version?: GraphForkedFromVersion; + sub_graphs?: BaseGraphInput[]; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecution.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecution.ts new file mode 100644 index 0000000000..34ddcf3c3a --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecution.ts @@ -0,0 +1,26 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { GraphExecutionPresetId } from "./graphExecutionPresetId"; +import type { AgentExecutionStatus } from "./agentExecutionStatus"; +import type { GraphExecutionStats } from "./graphExecutionStats"; +import type { GraphExecutionInputs } from "./graphExecutionInputs"; +import type { GraphExecutionOutputs } from "./graphExecutionOutputs"; + +export interface GraphExecution { + id?: string; + user_id: string; + graph_id: string; + graph_version: number; + preset_id?: GraphExecutionPresetId; + status: AgentExecutionStatus; + started_at: string; + ended_at: string; + stats: GraphExecutionStats; + inputs: GraphExecutionInputs; + outputs: GraphExecutionOutputs; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionInputs.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionInputs.ts new file mode 100644 index 0000000000..9fcd2c1d52 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionInputs.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type GraphExecutionInputs = { [key: string]: unknown }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionJobInfo.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionJobInfo.ts new file mode 100644 index 0000000000..e195389275 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionJobInfo.ts @@ -0,0 +1,21 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { GraphExecutionJobInfoInputData } from "./graphExecutionJobInfoInputData"; +import type { GraphExecutionJobInfoInputCredentials } from "./graphExecutionJobInfoInputCredentials"; + +export interface GraphExecutionJobInfo { + user_id: string; + graph_id: string; + graph_version: number; + cron: string; + input_data: GraphExecutionJobInfoInputData; + input_credentials?: GraphExecutionJobInfoInputCredentials; + id: string; + name: string; + next_run_time: string; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionJobInfoInputCredentials.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionJobInfoInputCredentials.ts new file mode 100644 index 0000000000..1f24a877d5 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionJobInfoInputCredentials.ts @@ -0,0 +1,12 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { CredentialsMetaInput } from "./credentialsMetaInput"; + +export type GraphExecutionJobInfoInputCredentials = { + [key: string]: CredentialsMetaInput; +}; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionJobInfoInputData.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionJobInfoInputData.ts new file mode 100644 index 0000000000..270e530af5 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionJobInfoInputData.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type GraphExecutionJobInfoInputData = { [key: string]: unknown }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionMeta.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionMeta.ts new file mode 100644 index 0000000000..387ccd4a65 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionMeta.ts @@ -0,0 +1,22 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { GraphExecutionMetaPresetId } from "./graphExecutionMetaPresetId"; +import type { AgentExecutionStatus } from "./agentExecutionStatus"; +import type { GraphExecutionMetaStats } from "./graphExecutionMetaStats"; + +export interface GraphExecutionMeta { + id?: string; + user_id: string; + graph_id: string; + graph_version: number; + preset_id?: GraphExecutionMetaPresetId; + status: AgentExecutionStatus; + started_at: string; + ended_at: string; + stats: GraphExecutionMetaStats; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionMetaPresetId.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionMetaPresetId.ts new file mode 100644 index 0000000000..d2db05f894 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionMetaPresetId.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type GraphExecutionMetaPresetId = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionMetaStats.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionMetaStats.ts new file mode 100644 index 0000000000..db50ec5495 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionMetaStats.ts @@ -0,0 +1,10 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { Stats } from "./stats"; + +export type GraphExecutionMetaStats = Stats | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionOutputs.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionOutputs.ts new file mode 100644 index 0000000000..52b6d3ea17 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionOutputs.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type GraphExecutionOutputs = { [key: string]: unknown[] }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionPresetId.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionPresetId.ts new file mode 100644 index 0000000000..42789ed3d7 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionPresetId.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type GraphExecutionPresetId = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionStats.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionStats.ts new file mode 100644 index 0000000000..0db91702a1 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionStats.ts @@ -0,0 +1,10 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { Stats } from "./stats"; + +export type GraphExecutionStats = Stats | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionWithNodes.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionWithNodes.ts new file mode 100644 index 0000000000..e0d552ad64 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionWithNodes.ts @@ -0,0 +1,28 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { GraphExecutionWithNodesPresetId } from "./graphExecutionWithNodesPresetId"; +import type { AgentExecutionStatus } from "./agentExecutionStatus"; +import type { GraphExecutionWithNodesStats } from "./graphExecutionWithNodesStats"; +import type { GraphExecutionWithNodesInputs } from "./graphExecutionWithNodesInputs"; +import type { GraphExecutionWithNodesOutputs } from "./graphExecutionWithNodesOutputs"; +import type { NodeExecutionResult } from "./nodeExecutionResult"; + +export interface GraphExecutionWithNodes { + id?: string; + user_id: string; + graph_id: string; + graph_version: number; + preset_id?: GraphExecutionWithNodesPresetId; + status: AgentExecutionStatus; + started_at: string; + ended_at: string; + stats: GraphExecutionWithNodesStats; + inputs: GraphExecutionWithNodesInputs; + outputs: GraphExecutionWithNodesOutputs; + node_executions: NodeExecutionResult[]; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionWithNodesInputs.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionWithNodesInputs.ts new file mode 100644 index 0000000000..33beb34983 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionWithNodesInputs.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type GraphExecutionWithNodesInputs = { [key: string]: unknown }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionWithNodesOutputs.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionWithNodesOutputs.ts new file mode 100644 index 0000000000..4b8169fb37 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionWithNodesOutputs.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type GraphExecutionWithNodesOutputs = { [key: string]: unknown[] }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionWithNodesPresetId.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionWithNodesPresetId.ts new file mode 100644 index 0000000000..b212be4963 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionWithNodesPresetId.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type GraphExecutionWithNodesPresetId = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionWithNodesStats.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionWithNodesStats.ts new file mode 100644 index 0000000000..73164b7376 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/graphExecutionWithNodesStats.ts @@ -0,0 +1,10 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { Stats } from "./stats"; + +export type GraphExecutionWithNodesStats = Stats | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/graphForkedFromId.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/graphForkedFromId.ts new file mode 100644 index 0000000000..1b1f6e28a7 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/graphForkedFromId.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type GraphForkedFromId = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/graphForkedFromVersion.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/graphForkedFromVersion.ts new file mode 100644 index 0000000000..1d2d2f4ac4 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/graphForkedFromVersion.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type GraphForkedFromVersion = number | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/graphModel.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/graphModel.ts new file mode 100644 index 0000000000..aa7a59e662 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/graphModel.ts @@ -0,0 +1,33 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { NodeModel } from "./nodeModel"; +import type { Link } from "./link"; +import type { GraphModelForkedFromId } from "./graphModelForkedFromId"; +import type { GraphModelForkedFromVersion } from "./graphModelForkedFromVersion"; +import type { BaseGraphOutput } from "./baseGraphOutput"; +import type { GraphModelInputSchema } from "./graphModelInputSchema"; +import type { GraphModelOutputSchema } from "./graphModelOutputSchema"; +import type { GraphModelCredentialsInputSchema } from "./graphModelCredentialsInputSchema"; + +export interface GraphModel { + id?: string; + version?: number; + is_active?: boolean; + name: string; + description: string; + nodes?: NodeModel[]; + links?: Link[]; + forked_from_id?: GraphModelForkedFromId; + forked_from_version?: GraphModelForkedFromVersion; + sub_graphs?: BaseGraphOutput[]; + user_id: string; + readonly input_schema: GraphModelInputSchema; + readonly output_schema: GraphModelOutputSchema; + readonly credentials_input_schema: GraphModelCredentialsInputSchema; + readonly has_webhook_trigger: boolean; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/graphModelCredentialsInputSchema.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/graphModelCredentialsInputSchema.ts new file mode 100644 index 0000000000..90ce351a5b --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/graphModelCredentialsInputSchema.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type GraphModelCredentialsInputSchema = { [key: string]: unknown }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/graphModelForkedFromId.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/graphModelForkedFromId.ts new file mode 100644 index 0000000000..fcf3d0efa8 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/graphModelForkedFromId.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type GraphModelForkedFromId = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/graphModelForkedFromVersion.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/graphModelForkedFromVersion.ts new file mode 100644 index 0000000000..8b4f889115 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/graphModelForkedFromVersion.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type GraphModelForkedFromVersion = number | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/graphModelInputSchema.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/graphModelInputSchema.ts new file mode 100644 index 0000000000..76da0b5642 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/graphModelInputSchema.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type GraphModelInputSchema = { [key: string]: unknown }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/graphModelOutputSchema.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/graphModelOutputSchema.ts new file mode 100644 index 0000000000..8d2b9560a2 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/graphModelOutputSchema.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type GraphModelOutputSchema = { [key: string]: unknown }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/hTTPValidationError.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/hTTPValidationError.ts new file mode 100644 index 0000000000..b216ede240 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/hTTPValidationError.ts @@ -0,0 +1,12 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { ValidationError } from "./validationError"; + +export interface HTTPValidationError { + detail?: ValidationError[]; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/hostScopedCredentialsInput.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/hostScopedCredentialsInput.ts new file mode 100644 index 0000000000..e46e6d7979 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/hostScopedCredentialsInput.ts @@ -0,0 +1,20 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { HostScopedCredentialsInputTitle } from "./hostScopedCredentialsInputTitle"; +import type { HostScopedCredentialsInputHeaders } from "./hostScopedCredentialsInputHeaders"; + +export interface HostScopedCredentialsInput { + id?: string; + provider: string; + title?: HostScopedCredentialsInputTitle; + type?: "host_scoped"; + /** The host/URI pattern to match against request URLs */ + host: string; + /** Key-value header map to add to matching requests */ + headers?: HostScopedCredentialsInputHeaders; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/hostScopedCredentialsInputHeaders.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/hostScopedCredentialsInputHeaders.ts new file mode 100644 index 0000000000..97971ba57c --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/hostScopedCredentialsInputHeaders.ts @@ -0,0 +1,12 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +/** + * Key-value header map to add to matching requests + */ +export type HostScopedCredentialsInputHeaders = { [key: string]: string }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/hostScopedCredentialsInputTitle.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/hostScopedCredentialsInputTitle.ts new file mode 100644 index 0000000000..718198d2b3 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/hostScopedCredentialsInputTitle.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type HostScopedCredentialsInputTitle = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/hostScopedCredentialsOutput.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/hostScopedCredentialsOutput.ts new file mode 100644 index 0000000000..2fe39782db --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/hostScopedCredentialsOutput.ts @@ -0,0 +1,20 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { HostScopedCredentialsOutputTitle } from "./hostScopedCredentialsOutputTitle"; +import type { HostScopedCredentialsOutputHeaders } from "./hostScopedCredentialsOutputHeaders"; + +export interface HostScopedCredentialsOutput { + id?: string; + provider: string; + title?: HostScopedCredentialsOutputTitle; + type?: "host_scoped"; + /** The host/URI pattern to match against request URLs */ + host: string; + /** Key-value header map to add to matching requests */ + headers?: HostScopedCredentialsOutputHeaders; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/hostScopedCredentialsOutputHeaders.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/hostScopedCredentialsOutputHeaders.ts new file mode 100644 index 0000000000..d5962d20bb --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/hostScopedCredentialsOutputHeaders.ts @@ -0,0 +1,12 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +/** + * Key-value header map to add to matching requests + */ +export type HostScopedCredentialsOutputHeaders = { [key: string]: string }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/hostScopedCredentialsOutputTitle.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/hostScopedCredentialsOutputTitle.ts new file mode 100644 index 0000000000..bc96d6f738 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/hostScopedCredentialsOutputTitle.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type HostScopedCredentialsOutputTitle = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgent.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgent.ts new file mode 100644 index 0000000000..583be8150b --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgent.ts @@ -0,0 +1,38 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { LibraryAgentImageUrl } from "./libraryAgentImageUrl"; +import type { LibraryAgentStatus } from "./libraryAgentStatus"; +import type { LibraryAgentInputSchema } from "./libraryAgentInputSchema"; +import type { LibraryAgentCredentialsInputSchema } from "./libraryAgentCredentialsInputSchema"; +import type { LibraryAgentTriggerSetupInfo } from "./libraryAgentTriggerSetupInfo"; + +/** + * Represents an agent in the library, including metadata for display and +user interaction within the system. + */ +export interface LibraryAgent { + id: string; + graph_id: string; + graph_version: number; + image_url: LibraryAgentImageUrl; + creator_name: string; + creator_image_url: string; + status: LibraryAgentStatus; + updated_at: string; + name: string; + description: string; + input_schema: LibraryAgentInputSchema; + /** Input schema for credentials required by the agent */ + credentials_input_schema: LibraryAgentCredentialsInputSchema; + /** Whether the agent has an external trigger (e.g. webhook) node */ + has_external_trigger: boolean; + trigger_setup_info?: LibraryAgentTriggerSetupInfo; + new_output: boolean; + can_access_graph: boolean; + is_latest_version: boolean; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentCredentialsInputSchema.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentCredentialsInputSchema.ts new file mode 100644 index 0000000000..8c957f3be5 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentCredentialsInputSchema.ts @@ -0,0 +1,12 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +/** + * Input schema for credentials required by the agent + */ +export type LibraryAgentCredentialsInputSchema = { [key: string]: unknown }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentImageUrl.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentImageUrl.ts new file mode 100644 index 0000000000..cf329fdbfc --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentImageUrl.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type LibraryAgentImageUrl = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentInputSchema.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentInputSchema.ts new file mode 100644 index 0000000000..d2e5e527c9 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentInputSchema.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type LibraryAgentInputSchema = { [key: string]: unknown }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPreset.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPreset.ts new file mode 100644 index 0000000000..ce067a2850 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPreset.ts @@ -0,0 +1,27 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { LibraryAgentPresetInputs } from "./libraryAgentPresetInputs"; +import type { LibraryAgentPresetCredentials } from "./libraryAgentPresetCredentials"; +import type { LibraryAgentPresetWebhookId } from "./libraryAgentPresetWebhookId"; + +/** + * Represents a preset configuration for a library agent. + */ +export interface LibraryAgentPreset { + graph_id: string; + graph_version: number; + inputs: LibraryAgentPresetInputs; + credentials: LibraryAgentPresetCredentials; + name: string; + description: string; + is_active?: boolean; + webhook_id?: LibraryAgentPresetWebhookId; + id: string; + user_id: string; + updated_at: string; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetCreatable.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetCreatable.ts new file mode 100644 index 0000000000..38f9c1ed53 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetCreatable.ts @@ -0,0 +1,24 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { LibraryAgentPresetCreatableInputs } from "./libraryAgentPresetCreatableInputs"; +import type { LibraryAgentPresetCreatableCredentials } from "./libraryAgentPresetCreatableCredentials"; +import type { LibraryAgentPresetCreatableWebhookId } from "./libraryAgentPresetCreatableWebhookId"; + +/** + * Request model used when creating a new preset for a library agent. + */ +export interface LibraryAgentPresetCreatable { + graph_id: string; + graph_version: number; + inputs: LibraryAgentPresetCreatableInputs; + credentials: LibraryAgentPresetCreatableCredentials; + name: string; + description: string; + is_active?: boolean; + webhook_id?: LibraryAgentPresetCreatableWebhookId; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetCreatableCredentials.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetCreatableCredentials.ts new file mode 100644 index 0000000000..857ff545db --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetCreatableCredentials.ts @@ -0,0 +1,12 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { CredentialsMetaInput } from "./credentialsMetaInput"; + +export type LibraryAgentPresetCreatableCredentials = { + [key: string]: CredentialsMetaInput; +}; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetCreatableFromGraphExecution.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetCreatableFromGraphExecution.ts new file mode 100644 index 0000000000..90aea688b4 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetCreatableFromGraphExecution.ts @@ -0,0 +1,17 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +/** + * Request model used when creating a new preset for a library agent. + */ +export interface LibraryAgentPresetCreatableFromGraphExecution { + graph_execution_id: string; + name: string; + description: string; + is_active?: boolean; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetCreatableInputs.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetCreatableInputs.ts new file mode 100644 index 0000000000..f1d90905ae --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetCreatableInputs.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type LibraryAgentPresetCreatableInputs = { [key: string]: unknown }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetCreatableWebhookId.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetCreatableWebhookId.ts new file mode 100644 index 0000000000..9b35cd693f --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetCreatableWebhookId.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type LibraryAgentPresetCreatableWebhookId = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetCredentials.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetCredentials.ts new file mode 100644 index 0000000000..f583a776fa --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetCredentials.ts @@ -0,0 +1,12 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { CredentialsMetaInput } from "./credentialsMetaInput"; + +export type LibraryAgentPresetCredentials = { + [key: string]: CredentialsMetaInput; +}; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetInputs.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetInputs.ts new file mode 100644 index 0000000000..ad5ee445bb --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetInputs.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type LibraryAgentPresetInputs = { [key: string]: unknown }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetResponse.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetResponse.ts new file mode 100644 index 0000000000..2f24c2dff4 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetResponse.ts @@ -0,0 +1,17 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { LibraryAgentPreset } from "./libraryAgentPreset"; +import type { Pagination } from "./pagination"; + +/** + * Response schema for a list of agent presets and pagination info. + */ +export interface LibraryAgentPresetResponse { + presets: LibraryAgentPreset[]; + pagination: Pagination; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetUpdatable.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetUpdatable.ts new file mode 100644 index 0000000000..672420da8e --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetUpdatable.ts @@ -0,0 +1,23 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { LibraryAgentPresetUpdatableInputs } from "./libraryAgentPresetUpdatableInputs"; +import type { LibraryAgentPresetUpdatableCredentials } from "./libraryAgentPresetUpdatableCredentials"; +import type { LibraryAgentPresetUpdatableName } from "./libraryAgentPresetUpdatableName"; +import type { LibraryAgentPresetUpdatableDescription } from "./libraryAgentPresetUpdatableDescription"; +import type { LibraryAgentPresetUpdatableIsActive } from "./libraryAgentPresetUpdatableIsActive"; + +/** + * Request model used when updating a preset for a library agent. + */ +export interface LibraryAgentPresetUpdatable { + inputs?: LibraryAgentPresetUpdatableInputs; + credentials?: LibraryAgentPresetUpdatableCredentials; + name?: LibraryAgentPresetUpdatableName; + description?: LibraryAgentPresetUpdatableDescription; + is_active?: LibraryAgentPresetUpdatableIsActive; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetUpdatableCredentials.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetUpdatableCredentials.ts new file mode 100644 index 0000000000..a30e3377bb --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetUpdatableCredentials.ts @@ -0,0 +1,11 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { LibraryAgentPresetUpdatableCredentialsAnyOf } from "./libraryAgentPresetUpdatableCredentialsAnyOf"; + +export type LibraryAgentPresetUpdatableCredentials = + LibraryAgentPresetUpdatableCredentialsAnyOf | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetUpdatableCredentialsAnyOf.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetUpdatableCredentialsAnyOf.ts new file mode 100644 index 0000000000..d36196eb05 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetUpdatableCredentialsAnyOf.ts @@ -0,0 +1,12 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { CredentialsMetaInput } from "./credentialsMetaInput"; + +export type LibraryAgentPresetUpdatableCredentialsAnyOf = { + [key: string]: CredentialsMetaInput; +}; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetUpdatableDescription.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetUpdatableDescription.ts new file mode 100644 index 0000000000..485a8363f2 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetUpdatableDescription.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type LibraryAgentPresetUpdatableDescription = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetUpdatableInputs.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetUpdatableInputs.ts new file mode 100644 index 0000000000..487b08ab1a --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetUpdatableInputs.ts @@ -0,0 +1,11 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { LibraryAgentPresetUpdatableInputsAnyOf } from "./libraryAgentPresetUpdatableInputsAnyOf"; + +export type LibraryAgentPresetUpdatableInputs = + LibraryAgentPresetUpdatableInputsAnyOf | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetUpdatableInputsAnyOf.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetUpdatableInputsAnyOf.ts new file mode 100644 index 0000000000..96010a9fb0 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetUpdatableInputsAnyOf.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type LibraryAgentPresetUpdatableInputsAnyOf = { [key: string]: unknown }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetUpdatableIsActive.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetUpdatableIsActive.ts new file mode 100644 index 0000000000..de763759d8 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetUpdatableIsActive.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type LibraryAgentPresetUpdatableIsActive = boolean | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetUpdatableName.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetUpdatableName.ts new file mode 100644 index 0000000000..450e5a964f --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetUpdatableName.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type LibraryAgentPresetUpdatableName = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetWebhookId.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetWebhookId.ts new file mode 100644 index 0000000000..c09d7ad733 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentPresetWebhookId.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type LibraryAgentPresetWebhookId = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentResponse.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentResponse.ts new file mode 100644 index 0000000000..2bc52229d5 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentResponse.ts @@ -0,0 +1,17 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { LibraryAgent } from "./libraryAgent"; +import type { Pagination } from "./pagination"; + +/** + * Response schema for a list of library agents and pagination info. + */ +export interface LibraryAgentResponse { + agents: LibraryAgent[]; + pagination: Pagination; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentSort.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentSort.ts new file mode 100644 index 0000000000..9d077ad28e --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentSort.ts @@ -0,0 +1,19 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +/** + * Possible sort options for sorting library agents. + */ +export type LibraryAgentSort = + (typeof LibraryAgentSort)[keyof typeof LibraryAgentSort]; + +// eslint-disable-next-line @typescript-eslint/no-redeclare +export const LibraryAgentSort = { + createdAt: "createdAt", + updatedAt: "updatedAt", +} as const; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentStatus.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentStatus.ts new file mode 100644 index 0000000000..f47b34fce1 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentStatus.ts @@ -0,0 +1,18 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type LibraryAgentStatus = + (typeof LibraryAgentStatus)[keyof typeof LibraryAgentStatus]; + +// eslint-disable-next-line @typescript-eslint/no-redeclare +export const LibraryAgentStatus = { + COMPLETED: "COMPLETED", + HEALTHY: "HEALTHY", + WAITING: "WAITING", + ERROR: "ERROR", +} as const; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentTriggerInfo.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentTriggerInfo.ts new file mode 100644 index 0000000000..5f8338f9b0 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentTriggerInfo.ts @@ -0,0 +1,17 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { ProviderName } from "./providerName"; +import type { LibraryAgentTriggerInfoConfigSchema } from "./libraryAgentTriggerInfoConfigSchema"; +import type { LibraryAgentTriggerInfoCredentialsInputName } from "./libraryAgentTriggerInfoCredentialsInputName"; + +export interface LibraryAgentTriggerInfo { + provider: ProviderName; + /** Input schema for the trigger block */ + config_schema: LibraryAgentTriggerInfoConfigSchema; + credentials_input_name: LibraryAgentTriggerInfoCredentialsInputName; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentTriggerInfoConfigSchema.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentTriggerInfoConfigSchema.ts new file mode 100644 index 0000000000..2d002f0d4c --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentTriggerInfoConfigSchema.ts @@ -0,0 +1,12 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +/** + * Input schema for the trigger block + */ +export type LibraryAgentTriggerInfoConfigSchema = { [key: string]: unknown }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentTriggerInfoCredentialsInputName.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentTriggerInfoCredentialsInputName.ts new file mode 100644 index 0000000000..3915d46216 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentTriggerInfoCredentialsInputName.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type LibraryAgentTriggerInfoCredentialsInputName = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentTriggerSetupInfo.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentTriggerSetupInfo.ts new file mode 100644 index 0000000000..2f7bb2bf3d --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentTriggerSetupInfo.ts @@ -0,0 +1,10 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { LibraryAgentTriggerInfo } from "./libraryAgentTriggerInfo"; + +export type LibraryAgentTriggerSetupInfo = LibraryAgentTriggerInfo | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentUpdateRequest.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentUpdateRequest.ts new file mode 100644 index 0000000000..17185d05ac --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentUpdateRequest.ts @@ -0,0 +1,25 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { LibraryAgentUpdateRequestAutoUpdateVersion } from "./libraryAgentUpdateRequestAutoUpdateVersion"; +import type { LibraryAgentUpdateRequestIsFavorite } from "./libraryAgentUpdateRequestIsFavorite"; +import type { LibraryAgentUpdateRequestIsArchived } from "./libraryAgentUpdateRequestIsArchived"; + +/** + * Schema for updating a library agent via PUT. + +Includes flags for auto-updating version, marking as favorite, +archiving, or deleting. + */ +export interface LibraryAgentUpdateRequest { + /** Auto-update the agent version */ + auto_update_version?: LibraryAgentUpdateRequestAutoUpdateVersion; + /** Mark the agent as a favorite */ + is_favorite?: LibraryAgentUpdateRequestIsFavorite; + /** Archive the agent */ + is_archived?: LibraryAgentUpdateRequestIsArchived; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentUpdateRequestAutoUpdateVersion.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentUpdateRequestAutoUpdateVersion.ts new file mode 100644 index 0000000000..c3760774bf --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentUpdateRequestAutoUpdateVersion.ts @@ -0,0 +1,12 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +/** + * Auto-update the agent version + */ +export type LibraryAgentUpdateRequestAutoUpdateVersion = boolean | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentUpdateRequestIsArchived.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentUpdateRequestIsArchived.ts new file mode 100644 index 0000000000..1bcc3b1032 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentUpdateRequestIsArchived.ts @@ -0,0 +1,12 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +/** + * Archive the agent + */ +export type LibraryAgentUpdateRequestIsArchived = boolean | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentUpdateRequestIsFavorite.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentUpdateRequestIsFavorite.ts new file mode 100644 index 0000000000..8c8af320aa --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/libraryAgentUpdateRequestIsFavorite.ts @@ -0,0 +1,12 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +/** + * Mark the agent as a favorite + */ +export type LibraryAgentUpdateRequestIsFavorite = boolean | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/link.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/link.ts new file mode 100644 index 0000000000..a23f8a1c47 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/link.ts @@ -0,0 +1,16 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export interface Link { + id?: string; + source_id: string; + sink_id: string; + source_name: string; + sink_name: string; + is_static?: boolean; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/logRawMetricRequest.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/logRawMetricRequest.ts new file mode 100644 index 0000000000..89e0f1037e --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/logRawMetricRequest.ts @@ -0,0 +1,15 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export interface LogRawMetricRequest { + /** @minLength 1 */ + metric_name: string; + metric_value: number; + /** @minLength 1 */ + data_string: string; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/loginResponse.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/loginResponse.ts new file mode 100644 index 0000000000..59d221aec2 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/loginResponse.ts @@ -0,0 +1,12 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export interface LoginResponse { + login_url: string; + state_token: string; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/message.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/message.ts new file mode 100644 index 0000000000..488998be60 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/message.ts @@ -0,0 +1,12 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export interface Message { + query: string; + response: string; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/myAgent.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/myAgent.ts new file mode 100644 index 0000000000..d998aa62f4 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/myAgent.ts @@ -0,0 +1,17 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { MyAgentAgentImage } from "./myAgentAgentImage"; + +export interface MyAgent { + agent_id: string; + agent_version: number; + agent_name: string; + agent_image?: MyAgentAgentImage; + description: string; + last_edited: string; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/myAgentAgentImage.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/myAgentAgentImage.ts new file mode 100644 index 0000000000..36c088d6bb --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/myAgentAgentImage.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type MyAgentAgentImage = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/myAgentsResponse.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/myAgentsResponse.ts new file mode 100644 index 0000000000..ad054e547b --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/myAgentsResponse.ts @@ -0,0 +1,14 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { MyAgent } from "./myAgent"; +import type { Pagination } from "./pagination"; + +export interface MyAgentsResponse { + agents: MyAgent[]; + pagination: Pagination; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/node.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/node.ts new file mode 100644 index 0000000000..9f3740a02b --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/node.ts @@ -0,0 +1,19 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { NodeInputDefault } from "./nodeInputDefault"; +import type { NodeMetadata } from "./nodeMetadata"; +import type { Link } from "./link"; + +export interface Node { + id?: string; + block_id: string; + input_default?: NodeInputDefault; + metadata?: NodeMetadata; + input_links?: Link[]; + output_links?: Link[]; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/nodeExecutionResult.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/nodeExecutionResult.ts new file mode 100644 index 0000000000..b87ee7aa22 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/nodeExecutionResult.ts @@ -0,0 +1,30 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { AgentExecutionStatus } from "./agentExecutionStatus"; +import type { NodeExecutionResultInputData } from "./nodeExecutionResultInputData"; +import type { NodeExecutionResultOutputData } from "./nodeExecutionResultOutputData"; +import type { NodeExecutionResultQueueTime } from "./nodeExecutionResultQueueTime"; +import type { NodeExecutionResultStartTime } from "./nodeExecutionResultStartTime"; +import type { NodeExecutionResultEndTime } from "./nodeExecutionResultEndTime"; + +export interface NodeExecutionResult { + user_id: string; + graph_id: string; + graph_version: number; + graph_exec_id: string; + node_exec_id: string; + node_id: string; + block_id: string; + status: AgentExecutionStatus; + input_data: NodeExecutionResultInputData; + output_data: NodeExecutionResultOutputData; + add_time: string; + queue_time: NodeExecutionResultQueueTime; + start_time: NodeExecutionResultStartTime; + end_time: NodeExecutionResultEndTime; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/nodeExecutionResultEndTime.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/nodeExecutionResultEndTime.ts new file mode 100644 index 0000000000..e86cccf507 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/nodeExecutionResultEndTime.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type NodeExecutionResultEndTime = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/nodeExecutionResultInputData.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/nodeExecutionResultInputData.ts new file mode 100644 index 0000000000..9e4033a46d --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/nodeExecutionResultInputData.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type NodeExecutionResultInputData = { [key: string]: unknown }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/nodeExecutionResultOutputData.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/nodeExecutionResultOutputData.ts new file mode 100644 index 0000000000..746d6e85e5 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/nodeExecutionResultOutputData.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type NodeExecutionResultOutputData = { [key: string]: unknown[] }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/nodeExecutionResultQueueTime.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/nodeExecutionResultQueueTime.ts new file mode 100644 index 0000000000..438572926a --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/nodeExecutionResultQueueTime.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type NodeExecutionResultQueueTime = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/nodeExecutionResultStartTime.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/nodeExecutionResultStartTime.ts new file mode 100644 index 0000000000..a8c389e19c --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/nodeExecutionResultStartTime.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type NodeExecutionResultStartTime = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/nodeInputDefault.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/nodeInputDefault.ts new file mode 100644 index 0000000000..191a06379d --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/nodeInputDefault.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type NodeInputDefault = { [key: string]: unknown }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/nodeMetadata.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/nodeMetadata.ts new file mode 100644 index 0000000000..3b3ab525e6 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/nodeMetadata.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type NodeMetadata = { [key: string]: unknown }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/nodeModel.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/nodeModel.ts new file mode 100644 index 0000000000..f81abc5f88 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/nodeModel.ts @@ -0,0 +1,25 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { NodeModelInputDefault } from "./nodeModelInputDefault"; +import type { NodeModelMetadata } from "./nodeModelMetadata"; +import type { Link } from "./link"; +import type { NodeModelWebhookId } from "./nodeModelWebhookId"; +import type { NodeModelWebhook } from "./nodeModelWebhook"; + +export interface NodeModel { + id?: string; + block_id: string; + input_default?: NodeModelInputDefault; + metadata?: NodeModelMetadata; + input_links?: Link[]; + output_links?: Link[]; + graph_id: string; + graph_version: number; + webhook_id?: NodeModelWebhookId; + webhook?: NodeModelWebhook; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/nodeModelInputDefault.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/nodeModelInputDefault.ts new file mode 100644 index 0000000000..4ec2ae5204 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/nodeModelInputDefault.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type NodeModelInputDefault = { [key: string]: unknown }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/nodeModelMetadata.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/nodeModelMetadata.ts new file mode 100644 index 0000000000..8cf1fbdf95 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/nodeModelMetadata.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type NodeModelMetadata = { [key: string]: unknown }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/nodeModelWebhook.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/nodeModelWebhook.ts new file mode 100644 index 0000000000..fe03e981e3 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/nodeModelWebhook.ts @@ -0,0 +1,10 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { Webhook } from "./webhook"; + +export type NodeModelWebhook = Webhook | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/nodeModelWebhookId.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/nodeModelWebhookId.ts new file mode 100644 index 0000000000..82eb4173a5 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/nodeModelWebhookId.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type NodeModelWebhookId = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/notificationPreference.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/notificationPreference.ts new file mode 100644 index 0000000000..08bedfc794 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/notificationPreference.ts @@ -0,0 +1,18 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { NotificationPreferencePreferences } from "./notificationPreferencePreferences"; + +export interface NotificationPreference { + user_id: string; + email: string; + /** Which notifications the user wants */ + preferences?: NotificationPreferencePreferences; + daily_limit?: number; + emails_sent_today?: number; + last_reset_date?: string; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/notificationPreferenceDTO.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/notificationPreferenceDTO.ts new file mode 100644 index 0000000000..97cefcc15c --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/notificationPreferenceDTO.ts @@ -0,0 +1,17 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { NotificationPreferenceDTOPreferences } from "./notificationPreferenceDTOPreferences"; + +export interface NotificationPreferenceDTO { + /** User's email address */ + email: string; + /** Which notifications the user wants */ + preferences: NotificationPreferenceDTOPreferences; + /** Max emails per day */ + daily_limit: number; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/notificationPreferenceDTOPreferences.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/notificationPreferenceDTOPreferences.ts new file mode 100644 index 0000000000..66c2762295 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/notificationPreferenceDTOPreferences.ts @@ -0,0 +1,12 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +/** + * Which notifications the user wants + */ +export type NotificationPreferenceDTOPreferences = { [key: string]: boolean }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/notificationPreferencePreferences.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/notificationPreferencePreferences.ts new file mode 100644 index 0000000000..efdcd19d9c --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/notificationPreferencePreferences.ts @@ -0,0 +1,12 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +/** + * Which notifications the user wants + */ +export type NotificationPreferencePreferences = { [key: string]: boolean }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/notificationType.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/notificationType.ts new file mode 100644 index 0000000000..2a57ec2170 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/notificationType.ts @@ -0,0 +1,24 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type NotificationType = + (typeof NotificationType)[keyof typeof NotificationType]; + +// eslint-disable-next-line @typescript-eslint/no-redeclare +export const NotificationType = { + AGENT_RUN: "AGENT_RUN", + ZERO_BALANCE: "ZERO_BALANCE", + LOW_BALANCE: "LOW_BALANCE", + BLOCK_EXECUTION_FAILED: "BLOCK_EXECUTION_FAILED", + CONTINUOUS_AGENT_ERROR: "CONTINUOUS_AGENT_ERROR", + DAILY_SUMMARY: "DAILY_SUMMARY", + WEEKLY_SUMMARY: "WEEKLY_SUMMARY", + MONTHLY_SUMMARY: "MONTHLY_SUMMARY", + REFUND_REQUEST: "REFUND_REQUEST", + REFUND_PROCESSED: "REFUND_PROCESSED", +} as const; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/oAuth2Credentials.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/oAuth2Credentials.ts new file mode 100644 index 0000000000..bb722084fd --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/oAuth2Credentials.ts @@ -0,0 +1,27 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { OAuth2CredentialsTitle } from "./oAuth2CredentialsTitle"; +import type { OAuth2CredentialsUsername } from "./oAuth2CredentialsUsername"; +import type { OAuth2CredentialsAccessTokenExpiresAt } from "./oAuth2CredentialsAccessTokenExpiresAt"; +import type { OAuth2CredentialsRefreshToken } from "./oAuth2CredentialsRefreshToken"; +import type { OAuth2CredentialsRefreshTokenExpiresAt } from "./oAuth2CredentialsRefreshTokenExpiresAt"; +import type { OAuth2CredentialsMetadata } from "./oAuth2CredentialsMetadata"; + +export interface OAuth2Credentials { + id?: string; + provider: string; + title?: OAuth2CredentialsTitle; + type?: "oauth2"; + username?: OAuth2CredentialsUsername; + access_token: string; + access_token_expires_at?: OAuth2CredentialsAccessTokenExpiresAt; + refresh_token?: OAuth2CredentialsRefreshToken; + refresh_token_expires_at?: OAuth2CredentialsRefreshTokenExpiresAt; + scopes: string[]; + metadata?: OAuth2CredentialsMetadata; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/oAuth2CredentialsAccessTokenExpiresAt.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/oAuth2CredentialsAccessTokenExpiresAt.ts new file mode 100644 index 0000000000..d4b56c864a --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/oAuth2CredentialsAccessTokenExpiresAt.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type OAuth2CredentialsAccessTokenExpiresAt = number | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/oAuth2CredentialsMetadata.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/oAuth2CredentialsMetadata.ts new file mode 100644 index 0000000000..c9dda9c940 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/oAuth2CredentialsMetadata.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type OAuth2CredentialsMetadata = { [key: string]: unknown }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/oAuth2CredentialsRefreshToken.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/oAuth2CredentialsRefreshToken.ts new file mode 100644 index 0000000000..eafe163e24 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/oAuth2CredentialsRefreshToken.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type OAuth2CredentialsRefreshToken = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/oAuth2CredentialsRefreshTokenExpiresAt.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/oAuth2CredentialsRefreshTokenExpiresAt.ts new file mode 100644 index 0000000000..5587d031e6 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/oAuth2CredentialsRefreshTokenExpiresAt.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type OAuth2CredentialsRefreshTokenExpiresAt = number | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/oAuth2CredentialsTitle.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/oAuth2CredentialsTitle.ts new file mode 100644 index 0000000000..d7c1351893 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/oAuth2CredentialsTitle.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type OAuth2CredentialsTitle = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/oAuth2CredentialsUsername.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/oAuth2CredentialsUsername.ts new file mode 100644 index 0000000000..653dd0bbea --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/oAuth2CredentialsUsername.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type OAuth2CredentialsUsername = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/onboardingStep.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/onboardingStep.ts new file mode 100644 index 0000000000..877b52ab8f --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/onboardingStep.ts @@ -0,0 +1,29 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type OnboardingStep = + (typeof OnboardingStep)[keyof typeof OnboardingStep]; + +// eslint-disable-next-line @typescript-eslint/no-redeclare +export const OnboardingStep = { + WELCOME: "WELCOME", + USAGE_REASON: "USAGE_REASON", + INTEGRATIONS: "INTEGRATIONS", + AGENT_CHOICE: "AGENT_CHOICE", + AGENT_NEW_RUN: "AGENT_NEW_RUN", + AGENT_INPUT: "AGENT_INPUT", + CONGRATS: "CONGRATS", + GET_RESULTS: "GET_RESULTS", + RUN_AGENTS: "RUN_AGENTS", + MARKETPLACE_VISIT: "MARKETPLACE_VISIT", + MARKETPLACE_ADD_AGENT: "MARKETPLACE_ADD_AGENT", + MARKETPLACE_RUN_AGENT: "MARKETPLACE_RUN_AGENT", + BUILDER_OPEN: "BUILDER_OPEN", + BUILDER_SAVE_AGENT: "BUILDER_SAVE_AGENT", + BUILDER_RUN_AGENT: "BUILDER_RUN_AGENT", +} as const; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/pagination.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/pagination.ts new file mode 100644 index 0000000000..7590f225f8 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/pagination.ts @@ -0,0 +1,18 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export interface Pagination { + /** Total number of items. */ + total_items: number; + /** Total number of pages. */ + total_pages: number; + /** Current_page page number. */ + current_page: number; + /** Number of items per page. */ + page_size: number; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/postV1CreateCredentials201.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/postV1CreateCredentials201.ts new file mode 100644 index 0000000000..95ff25b5a1 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/postV1CreateCredentials201.ts @@ -0,0 +1,17 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { OAuth2Credentials } from "./oAuth2Credentials"; +import type { APIKeyCredentials } from "./aPIKeyCredentials"; +import type { UserPasswordCredentials } from "./userPasswordCredentials"; +import type { HostScopedCredentialsOutput } from "./hostScopedCredentialsOutput"; + +export type PostV1CreateCredentials201 = + | OAuth2Credentials + | APIKeyCredentials + | UserPasswordCredentials + | HostScopedCredentialsOutput; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/postV1CreateCredentialsBody.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/postV1CreateCredentialsBody.ts new file mode 100644 index 0000000000..ec8f114071 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/postV1CreateCredentialsBody.ts @@ -0,0 +1,17 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { OAuth2Credentials } from "./oAuth2Credentials"; +import type { APIKeyCredentials } from "./aPIKeyCredentials"; +import type { UserPasswordCredentials } from "./userPasswordCredentials"; +import type { HostScopedCredentialsInput } from "./hostScopedCredentialsInput"; + +export type PostV1CreateCredentialsBody = + | OAuth2Credentials + | APIKeyCredentials + | UserPasswordCredentials + | HostScopedCredentialsInput; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/postV1ExecuteGraphAgentParams.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/postV1ExecuteGraphAgentParams.ts new file mode 100644 index 0000000000..72c8020c5e --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/postV1ExecuteGraphAgentParams.ts @@ -0,0 +1,11 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type PostV1ExecuteGraphAgentParams = { + preset_id?: string | null; +}; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/postV1ExecuteGraphBlock200.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/postV1ExecuteGraphBlock200.ts new file mode 100644 index 0000000000..3bf2112f45 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/postV1ExecuteGraphBlock200.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type PostV1ExecuteGraphBlock200 = { [key: string]: unknown[] }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/postV1ExecuteGraphBlockBody.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/postV1ExecuteGraphBlockBody.ts new file mode 100644 index 0000000000..dd2a65d662 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/postV1ExecuteGraphBlockBody.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type PostV1ExecuteGraphBlockBody = { [key: string]: unknown }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/postV1HandlePostmarkEmailWebhooksBody.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/postV1HandlePostmarkEmailWebhooksBody.ts new file mode 100644 index 0000000000..699f5aa124 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/postV1HandlePostmarkEmailWebhooksBody.ts @@ -0,0 +1,21 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { PostmarkDeliveryWebhook } from "./postmarkDeliveryWebhook"; +import type { PostmarkBounceWebhook } from "./postmarkBounceWebhook"; +import type { PostmarkSpamComplaintWebhook } from "./postmarkSpamComplaintWebhook"; +import type { PostmarkOpenWebhook } from "./postmarkOpenWebhook"; +import type { PostmarkClickWebhook } from "./postmarkClickWebhook"; +import type { PostmarkSubscriptionChangeWebhook } from "./postmarkSubscriptionChangeWebhook"; + +export type PostV1HandlePostmarkEmailWebhooksBody = + | PostmarkDeliveryWebhook + | PostmarkBounceWebhook + | PostmarkSpamComplaintWebhook + | PostmarkOpenWebhook + | PostmarkClickWebhook + | PostmarkSubscriptionChangeWebhook; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/postV1OneClickEmailUnsubscribeParams.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/postV1OneClickEmailUnsubscribeParams.ts new file mode 100644 index 0000000000..c577d928be --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/postV1OneClickEmailUnsubscribeParams.ts @@ -0,0 +1,11 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type PostV1OneClickEmailUnsubscribeParams = { + token: string; +}; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/postV1RefundCreditTransactionBody.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/postV1RefundCreditTransactionBody.ts new file mode 100644 index 0000000000..32b2fdb83e --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/postV1RefundCreditTransactionBody.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type PostV1RefundCreditTransactionBody = { [key: string]: string }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/postV1UpdateUserEmail200.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/postV1UpdateUserEmail200.ts new file mode 100644 index 0000000000..02089a2200 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/postV1UpdateUserEmail200.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type PostV1UpdateUserEmail200 = { [key: string]: string }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/postV2CreateANewPresetBody.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/postV2CreateANewPresetBody.ts new file mode 100644 index 0000000000..36b8114b61 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/postV2CreateANewPresetBody.ts @@ -0,0 +1,13 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { LibraryAgentPresetCreatable } from "./libraryAgentPresetCreatable"; +import type { LibraryAgentPresetCreatableFromGraphExecution } from "./libraryAgentPresetCreatableFromGraphExecution"; + +export type PostV2CreateANewPresetBody = + | LibraryAgentPresetCreatable + | LibraryAgentPresetCreatableFromGraphExecution; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/postV2ExecuteAPreset200.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/postV2ExecuteAPreset200.ts new file mode 100644 index 0000000000..fc0248fbe3 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/postV2ExecuteAPreset200.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type PostV2ExecuteAPreset200 = { [key: string]: unknown }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/postV2GenerateSubmissionImageParams.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/postV2GenerateSubmissionImageParams.ts new file mode 100644 index 0000000000..952b6e684f --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/postV2GenerateSubmissionImageParams.ts @@ -0,0 +1,11 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type PostV2GenerateSubmissionImageParams = { + agent_id: string; +}; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkBounceEnum.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkBounceEnum.ts new file mode 100644 index 0000000000..b9f7d70c36 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkBounceEnum.ts @@ -0,0 +1,36 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type PostmarkBounceEnum = + (typeof PostmarkBounceEnum)[keyof typeof PostmarkBounceEnum]; + +// eslint-disable-next-line @typescript-eslint/no-redeclare +export const PostmarkBounceEnum = { + NUMBER_1: 1, + NUMBER_2: 2, + NUMBER_16: 16, + NUMBER_32: 32, + NUMBER_64: 64, + NUMBER_128: 128, + NUMBER_256: 256, + NUMBER_512: 512, + NUMBER_1024: 1024, + NUMBER_2048: 2048, + NUMBER_4096: 4096, + NUMBER_8192: 8192, + NUMBER_16384: 16384, + NUMBER_100000: 100000, + NUMBER_100001: 100001, + NUMBER_100002: 100002, + NUMBER_100003: 100003, + NUMBER_100006: 100006, + NUMBER_100007: 100007, + NUMBER_100008: 100008, + NUMBER_100009: 100009, + NUMBER_100010: 100010, +} as const; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkBounceWebhook.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkBounceWebhook.ts new file mode 100644 index 0000000000..8705792b6c --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkBounceWebhook.ts @@ -0,0 +1,32 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { PostmarkBounceEnum } from "./postmarkBounceEnum"; +import type { PostmarkBounceWebhookMetadata } from "./postmarkBounceWebhookMetadata"; + +export interface PostmarkBounceWebhook { + RecordType?: "Bounce"; + ID: number; + Type: string; + TypeCode: PostmarkBounceEnum; + Tag: string; + MessageID: string; + Details: string; + Email: string; + From: string; + BouncedAt: string; + Inactive: boolean; + DumpAvailable: boolean; + CanActivate: boolean; + Subject: string; + ServerID: number; + MessageStream: string; + Content: string; + Name: string; + Description: string; + Metadata: PostmarkBounceWebhookMetadata; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkBounceWebhookMetadata.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkBounceWebhookMetadata.ts new file mode 100644 index 0000000000..b44b9760bd --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkBounceWebhookMetadata.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type PostmarkBounceWebhookMetadata = { [key: string]: string }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkClickWebhook.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkClickWebhook.ts new file mode 100644 index 0000000000..69923fa136 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkClickWebhook.ts @@ -0,0 +1,28 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { PostmarkClickWebhookMetadata } from "./postmarkClickWebhookMetadata"; +import type { PostmarkClickWebhookOS } from "./postmarkClickWebhookOS"; +import type { PostmarkClickWebhookClient } from "./postmarkClickWebhookClient"; +import type { PostmarkClickWebhookGeo } from "./postmarkClickWebhookGeo"; + +export interface PostmarkClickWebhook { + RecordType?: "Click"; + MessageStream: string; + Metadata: PostmarkClickWebhookMetadata; + Recipient: string; + MessageID: string; + ReceivedAt: string; + Platform: string; + ClickLocation: string; + OriginalLink: string; + Tag: string; + UserAgent: string; + OS: PostmarkClickWebhookOS; + Client: PostmarkClickWebhookClient; + Geo: PostmarkClickWebhookGeo; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkClickWebhookClient.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkClickWebhookClient.ts new file mode 100644 index 0000000000..1153e6ab27 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkClickWebhookClient.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type PostmarkClickWebhookClient = { [key: string]: string }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkClickWebhookGeo.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkClickWebhookGeo.ts new file mode 100644 index 0000000000..3236c128ef --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkClickWebhookGeo.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type PostmarkClickWebhookGeo = { [key: string]: string }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkClickWebhookMetadata.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkClickWebhookMetadata.ts new file mode 100644 index 0000000000..1c105912b2 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkClickWebhookMetadata.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type PostmarkClickWebhookMetadata = { [key: string]: string }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkClickWebhookOS.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkClickWebhookOS.ts new file mode 100644 index 0000000000..b61d05a9aa --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkClickWebhookOS.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type PostmarkClickWebhookOS = { [key: string]: string }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkDeliveryWebhook.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkDeliveryWebhook.ts new file mode 100644 index 0000000000..f4fd9be417 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkDeliveryWebhook.ts @@ -0,0 +1,20 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { PostmarkDeliveryWebhookMetadata } from "./postmarkDeliveryWebhookMetadata"; + +export interface PostmarkDeliveryWebhook { + RecordType?: "Delivery"; + ServerID: number; + MessageStream: string; + MessageID: string; + Recipient: string; + Tag: string; + DeliveredAt: string; + Details: string; + Metadata: PostmarkDeliveryWebhookMetadata; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkDeliveryWebhookMetadata.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkDeliveryWebhookMetadata.ts new file mode 100644 index 0000000000..ec054608e8 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkDeliveryWebhookMetadata.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type PostmarkDeliveryWebhookMetadata = { [key: string]: string }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkOpenWebhook.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkOpenWebhook.ts new file mode 100644 index 0000000000..c31c737c19 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkOpenWebhook.ts @@ -0,0 +1,28 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { PostmarkOpenWebhookMetadata } from "./postmarkOpenWebhookMetadata"; +import type { PostmarkOpenWebhookOS } from "./postmarkOpenWebhookOS"; +import type { PostmarkOpenWebhookClient } from "./postmarkOpenWebhookClient"; +import type { PostmarkOpenWebhookGeo } from "./postmarkOpenWebhookGeo"; + +export interface PostmarkOpenWebhook { + RecordType?: "Open"; + MessageStream: string; + Metadata: PostmarkOpenWebhookMetadata; + FirstOpen: boolean; + Recipient: string; + MessageID: string; + ReceivedAt: string; + Platform: string; + ReadSeconds: number; + Tag: string; + UserAgent: string; + OS: PostmarkOpenWebhookOS; + Client: PostmarkOpenWebhookClient; + Geo: PostmarkOpenWebhookGeo; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkOpenWebhookClient.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkOpenWebhookClient.ts new file mode 100644 index 0000000000..92bb4ca083 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkOpenWebhookClient.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type PostmarkOpenWebhookClient = { [key: string]: string }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkOpenWebhookGeo.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkOpenWebhookGeo.ts new file mode 100644 index 0000000000..f1523d16c2 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkOpenWebhookGeo.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type PostmarkOpenWebhookGeo = { [key: string]: string }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkOpenWebhookMetadata.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkOpenWebhookMetadata.ts new file mode 100644 index 0000000000..1fb7dcf546 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkOpenWebhookMetadata.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type PostmarkOpenWebhookMetadata = { [key: string]: string }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkOpenWebhookOS.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkOpenWebhookOS.ts new file mode 100644 index 0000000000..003197ae47 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkOpenWebhookOS.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type PostmarkOpenWebhookOS = { [key: string]: string }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkSpamComplaintWebhook.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkSpamComplaintWebhook.ts new file mode 100644 index 0000000000..6752559fd0 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkSpamComplaintWebhook.ts @@ -0,0 +1,31 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { PostmarkSpamComplaintWebhookMetadata } from "./postmarkSpamComplaintWebhookMetadata"; + +export interface PostmarkSpamComplaintWebhook { + RecordType?: "SpamComplaint"; + ID: number; + Type: string; + TypeCode: number; + Tag: string; + MessageID: string; + Details: string; + Email: string; + From: string; + BouncedAt: string; + Inactive: boolean; + DumpAvailable: boolean; + CanActivate: boolean; + Subject: string; + ServerID: number; + MessageStream: string; + Content: string; + Name: string; + Description: string; + Metadata: PostmarkSpamComplaintWebhookMetadata; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkSpamComplaintWebhookMetadata.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkSpamComplaintWebhookMetadata.ts new file mode 100644 index 0000000000..9f2c41f27e --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkSpamComplaintWebhookMetadata.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type PostmarkSpamComplaintWebhookMetadata = { [key: string]: string }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkSubscriptionChangeWebhook.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkSubscriptionChangeWebhook.ts new file mode 100644 index 0000000000..cf8c1c540b --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkSubscriptionChangeWebhook.ts @@ -0,0 +1,22 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { PostmarkSubscriptionChangeWebhookMetadata } from "./postmarkSubscriptionChangeWebhookMetadata"; + +export interface PostmarkSubscriptionChangeWebhook { + RecordType?: "SubscriptionChange"; + MessageID: string; + ServerID: number; + MessageStream: string; + ChangedAt: string; + Recipient: string; + Origin: string; + SuppressSending: boolean; + SuppressionReason: string; + Tag: string; + Metadata: PostmarkSubscriptionChangeWebhookMetadata; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkSubscriptionChangeWebhookMetadata.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkSubscriptionChangeWebhookMetadata.ts new file mode 100644 index 0000000000..e534c685c4 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/postmarkSubscriptionChangeWebhookMetadata.ts @@ -0,0 +1,11 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type PostmarkSubscriptionChangeWebhookMetadata = { + [key: string]: string; +}; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/profile.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/profile.ts new file mode 100644 index 0000000000..072e9ae270 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/profile.ts @@ -0,0 +1,16 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export interface Profile { + name: string; + username: string; + description: string; + links: string[]; + avatar_url: string; + is_featured?: boolean; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/profileDetails.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/profileDetails.ts new file mode 100644 index 0000000000..e92dbab59d --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/profileDetails.ts @@ -0,0 +1,16 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { ProfileDetailsAvatarUrl } from "./profileDetailsAvatarUrl"; + +export interface ProfileDetails { + name: string; + username: string; + description: string; + links: string[]; + avatar_url?: ProfileDetailsAvatarUrl; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/profileDetailsAvatarUrl.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/profileDetailsAvatarUrl.ts new file mode 100644 index 0000000000..ff303842e5 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/profileDetailsAvatarUrl.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type ProfileDetailsAvatarUrl = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/providerName.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/providerName.ts new file mode 100644 index 0000000000..198bb7a5bf --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/providerName.ts @@ -0,0 +1,53 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type ProviderName = (typeof ProviderName)[keyof typeof ProviderName]; + +// eslint-disable-next-line @typescript-eslint/no-redeclare +export const ProviderName = { + aiml_api: "aiml_api", + anthropic: "anthropic", + apollo: "apollo", + compass: "compass", + discord: "discord", + d_id: "d_id", + e2b: "e2b", + exa: "exa", + fal: "fal", + generic_webhook: "generic_webhook", + github: "github", + google: "google", + google_maps: "google_maps", + groq: "groq", + http: "http", + hubspot: "hubspot", + ideogram: "ideogram", + jina: "jina", + linear: "linear", + llama_api: "llama_api", + medium: "medium", + mem0: "mem0", + notion: "notion", + nvidia: "nvidia", + ollama: "ollama", + openai: "openai", + openweathermap: "openweathermap", + open_router: "open_router", + pinecone: "pinecone", + reddit: "reddit", + replicate: "replicate", + revid: "revid", + screenshotone: "screenshotone", + slant3d: "slant3d", + smartlead: "smartlead", + smtp: "smtp", + twitter: "twitter", + todoist: "todoist", + unreal_speech: "unreal_speech", + zerobounce: "zerobounce", +} as const; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/refundRequest.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/refundRequest.ts new file mode 100644 index 0000000000..1b658170af --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/refundRequest.ts @@ -0,0 +1,20 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { RefundRequestResult } from "./refundRequestResult"; + +export interface RefundRequest { + id: string; + user_id: string; + transaction_key: string; + amount: number; + reason: string; + result?: RefundRequestResult; + status: string; + created_at: string; + updated_at: string; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/refundRequestResult.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/refundRequestResult.ts new file mode 100644 index 0000000000..165c4832ef --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/refundRequestResult.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type RefundRequestResult = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/requestTopUp.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/requestTopUp.ts new file mode 100644 index 0000000000..12d9a4b9fd --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/requestTopUp.ts @@ -0,0 +1,11 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export interface RequestTopUp { + credit_amount: number; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/reviewSubmissionRequest.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/reviewSubmissionRequest.ts new file mode 100644 index 0000000000..b987faedcd --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/reviewSubmissionRequest.ts @@ -0,0 +1,15 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { ReviewSubmissionRequestInternalComments } from "./reviewSubmissionRequestInternalComments"; + +export interface ReviewSubmissionRequest { + store_listing_version_id: string; + is_approved: boolean; + comments: string; + internal_comments?: ReviewSubmissionRequestInternalComments; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/reviewSubmissionRequestInternalComments.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/reviewSubmissionRequestInternalComments.ts new file mode 100644 index 0000000000..d3969adb0e --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/reviewSubmissionRequestInternalComments.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type ReviewSubmissionRequestInternalComments = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/scheduleCreationRequest.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/scheduleCreationRequest.ts new file mode 100644 index 0000000000..5f530cc843 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/scheduleCreationRequest.ts @@ -0,0 +1,18 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { ScheduleCreationRequestGraphVersion } from "./scheduleCreationRequestGraphVersion"; +import type { ScheduleCreationRequestInputs } from "./scheduleCreationRequestInputs"; +import type { ScheduleCreationRequestCredentials } from "./scheduleCreationRequestCredentials"; + +export interface ScheduleCreationRequest { + graph_version?: ScheduleCreationRequestGraphVersion; + name: string; + cron: string; + inputs: ScheduleCreationRequestInputs; + credentials?: ScheduleCreationRequestCredentials; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/scheduleCreationRequestCredentials.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/scheduleCreationRequestCredentials.ts new file mode 100644 index 0000000000..c57c8604e4 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/scheduleCreationRequestCredentials.ts @@ -0,0 +1,12 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { CredentialsMetaInput } from "./credentialsMetaInput"; + +export type ScheduleCreationRequestCredentials = { + [key: string]: CredentialsMetaInput; +}; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/scheduleCreationRequestGraphVersion.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/scheduleCreationRequestGraphVersion.ts new file mode 100644 index 0000000000..8049053e55 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/scheduleCreationRequestGraphVersion.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type ScheduleCreationRequestGraphVersion = number | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/scheduleCreationRequestInputs.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/scheduleCreationRequestInputs.ts new file mode 100644 index 0000000000..ce851b98f6 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/scheduleCreationRequestInputs.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type ScheduleCreationRequestInputs = { [key: string]: unknown }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/setGraphActiveVersion.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/setGraphActiveVersion.ts new file mode 100644 index 0000000000..d057bd2cc2 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/setGraphActiveVersion.ts @@ -0,0 +1,11 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export interface SetGraphActiveVersion { + active_graph_version: number; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/stats.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/stats.ts new file mode 100644 index 0000000000..a98a0e45d7 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/stats.ts @@ -0,0 +1,28 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { StatsError } from "./statsError"; + +export interface Stats { + /** Execution cost (cents) */ + cost?: number; + /** Seconds from start to end of run */ + duration?: number; + /** CPU sec of duration */ + duration_cpu_only?: number; + /** Seconds of total node runtime */ + node_exec_time?: number; + /** CPU sec of node_exec_time */ + node_exec_time_cpu_only?: number; + /** Number of node executions */ + node_exec_count?: number; + /** Number of node errors */ + node_error_count?: number; + /** Error message if any */ + error?: StatsError; + [key: string]: unknown; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/statsError.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/statsError.ts new file mode 100644 index 0000000000..c2e0f8b5f8 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/statsError.ts @@ -0,0 +1,12 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +/** + * Error message if any + */ +export type StatsError = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/storeAgent.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/storeAgent.ts new file mode 100644 index 0000000000..f34807629a --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/storeAgent.ts @@ -0,0 +1,19 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export interface StoreAgent { + slug: string; + agent_name: string; + agent_image: string; + creator: string; + creator_avatar: string; + sub_heading: string; + description: string; + runs: number; + rating: number; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/storeAgentDetails.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/storeAgentDetails.ts new file mode 100644 index 0000000000..3f64cc9699 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/storeAgentDetails.ts @@ -0,0 +1,27 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { StoreAgentDetailsActiveVersionId } from "./storeAgentDetailsActiveVersionId"; + +export interface StoreAgentDetails { + store_listing_version_id: string; + slug: string; + agent_name: string; + agent_video: string; + agent_image: string[]; + creator: string; + creator_avatar: string; + sub_heading: string; + description: string; + categories: string[]; + runs: number; + rating: number; + versions: string[]; + last_updated: string; + active_version_id?: StoreAgentDetailsActiveVersionId; + has_approved_version?: boolean; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/storeAgentDetailsActiveVersionId.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/storeAgentDetailsActiveVersionId.ts new file mode 100644 index 0000000000..cb8f6a67a3 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/storeAgentDetailsActiveVersionId.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type StoreAgentDetailsActiveVersionId = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/storeAgentsResponse.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/storeAgentsResponse.ts new file mode 100644 index 0000000000..aa18e6e06b --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/storeAgentsResponse.ts @@ -0,0 +1,14 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { StoreAgent } from "./storeAgent"; +import type { Pagination } from "./pagination"; + +export interface StoreAgentsResponse { + agents: StoreAgent[]; + pagination: Pagination; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/storeListingWithVersions.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/storeListingWithVersions.ts new file mode 100644 index 0000000000..c4facb7fb5 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/storeListingWithVersions.ts @@ -0,0 +1,26 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { StoreListingWithVersionsActiveVersionId } from "./storeListingWithVersionsActiveVersionId"; +import type { StoreListingWithVersionsCreatorEmail } from "./storeListingWithVersionsCreatorEmail"; +import type { StoreListingWithVersionsLatestVersion } from "./storeListingWithVersionsLatestVersion"; +import type { StoreSubmission } from "./storeSubmission"; + +/** + * A store listing with its version history + */ +export interface StoreListingWithVersions { + listing_id: string; + slug: string; + agent_id: string; + agent_version: number; + active_version_id?: StoreListingWithVersionsActiveVersionId; + has_approved_version?: boolean; + creator_email?: StoreListingWithVersionsCreatorEmail; + latest_version?: StoreListingWithVersionsLatestVersion; + versions?: StoreSubmission[]; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/storeListingWithVersionsActiveVersionId.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/storeListingWithVersionsActiveVersionId.ts new file mode 100644 index 0000000000..d497a65921 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/storeListingWithVersionsActiveVersionId.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type StoreListingWithVersionsActiveVersionId = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/storeListingWithVersionsCreatorEmail.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/storeListingWithVersionsCreatorEmail.ts new file mode 100644 index 0000000000..bb1be13a85 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/storeListingWithVersionsCreatorEmail.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type StoreListingWithVersionsCreatorEmail = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/storeListingWithVersionsLatestVersion.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/storeListingWithVersionsLatestVersion.ts new file mode 100644 index 0000000000..b5306f0a2b --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/storeListingWithVersionsLatestVersion.ts @@ -0,0 +1,10 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { StoreSubmission } from "./storeSubmission"; + +export type StoreListingWithVersionsLatestVersion = StoreSubmission | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/storeListingsWithVersionsResponse.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/storeListingsWithVersionsResponse.ts new file mode 100644 index 0000000000..0d1ac8aeb3 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/storeListingsWithVersionsResponse.ts @@ -0,0 +1,17 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { StoreListingWithVersions } from "./storeListingWithVersions"; +import type { Pagination } from "./pagination"; + +/** + * Response model for listings with version history + */ +export interface StoreListingsWithVersionsResponse { + listings: StoreListingWithVersions[]; + pagination: Pagination; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/storeReview.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/storeReview.ts new file mode 100644 index 0000000000..3a36db855b --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/storeReview.ts @@ -0,0 +1,13 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { StoreReviewComments } from "./storeReviewComments"; + +export interface StoreReview { + score: number; + comments?: StoreReviewComments; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/storeReviewComments.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/storeReviewComments.ts new file mode 100644 index 0000000000..4506670bec --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/storeReviewComments.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type StoreReviewComments = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/storeReviewCreate.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/storeReviewCreate.ts new file mode 100644 index 0000000000..936598e927 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/storeReviewCreate.ts @@ -0,0 +1,14 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { StoreReviewCreateComments } from "./storeReviewCreateComments"; + +export interface StoreReviewCreate { + store_listing_version_id: string; + score: number; + comments?: StoreReviewCreateComments; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/storeReviewCreateComments.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/storeReviewCreateComments.ts new file mode 100644 index 0000000000..64a98a6252 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/storeReviewCreateComments.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type StoreReviewCreateComments = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/storeSubmission.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/storeSubmission.ts new file mode 100644 index 0000000000..9bc1db6f7a --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/storeSubmission.ts @@ -0,0 +1,36 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { SubmissionStatus } from "./submissionStatus"; +import type { StoreSubmissionStoreListingVersionId } from "./storeSubmissionStoreListingVersionId"; +import type { StoreSubmissionVersion } from "./storeSubmissionVersion"; +import type { StoreSubmissionReviewerId } from "./storeSubmissionReviewerId"; +import type { StoreSubmissionReviewComments } from "./storeSubmissionReviewComments"; +import type { StoreSubmissionInternalComments } from "./storeSubmissionInternalComments"; +import type { StoreSubmissionReviewedAt } from "./storeSubmissionReviewedAt"; +import type { StoreSubmissionChangesSummary } from "./storeSubmissionChangesSummary"; + +export interface StoreSubmission { + agent_id: string; + agent_version: number; + name: string; + sub_heading: string; + slug: string; + description: string; + image_urls: string[]; + date_submitted: string; + status: SubmissionStatus; + runs: number; + rating: number; + store_listing_version_id?: StoreSubmissionStoreListingVersionId; + version?: StoreSubmissionVersion; + reviewer_id?: StoreSubmissionReviewerId; + review_comments?: StoreSubmissionReviewComments; + internal_comments?: StoreSubmissionInternalComments; + reviewed_at?: StoreSubmissionReviewedAt; + changes_summary?: StoreSubmissionChangesSummary; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/storeSubmissionChangesSummary.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/storeSubmissionChangesSummary.ts new file mode 100644 index 0000000000..e093e8b4e9 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/storeSubmissionChangesSummary.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type StoreSubmissionChangesSummary = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/storeSubmissionInternalComments.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/storeSubmissionInternalComments.ts new file mode 100644 index 0000000000..ce3c6c45b1 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/storeSubmissionInternalComments.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type StoreSubmissionInternalComments = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/storeSubmissionRequest.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/storeSubmissionRequest.ts new file mode 100644 index 0000000000..20cf007b2a --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/storeSubmissionRequest.ts @@ -0,0 +1,22 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { StoreSubmissionRequestVideoUrl } from "./storeSubmissionRequestVideoUrl"; +import type { StoreSubmissionRequestChangesSummary } from "./storeSubmissionRequestChangesSummary"; + +export interface StoreSubmissionRequest { + agent_id: string; + agent_version: number; + slug: string; + name: string; + sub_heading: string; + video_url?: StoreSubmissionRequestVideoUrl; + image_urls?: string[]; + description?: string; + categories?: string[]; + changes_summary?: StoreSubmissionRequestChangesSummary; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/storeSubmissionRequestChangesSummary.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/storeSubmissionRequestChangesSummary.ts new file mode 100644 index 0000000000..1078c1f1cd --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/storeSubmissionRequestChangesSummary.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type StoreSubmissionRequestChangesSummary = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/storeSubmissionRequestVideoUrl.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/storeSubmissionRequestVideoUrl.ts new file mode 100644 index 0000000000..7ce72c00ff --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/storeSubmissionRequestVideoUrl.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type StoreSubmissionRequestVideoUrl = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/storeSubmissionReviewComments.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/storeSubmissionReviewComments.ts new file mode 100644 index 0000000000..13ae778840 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/storeSubmissionReviewComments.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type StoreSubmissionReviewComments = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/storeSubmissionReviewedAt.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/storeSubmissionReviewedAt.ts new file mode 100644 index 0000000000..5e12ef999c --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/storeSubmissionReviewedAt.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type StoreSubmissionReviewedAt = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/storeSubmissionReviewerId.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/storeSubmissionReviewerId.ts new file mode 100644 index 0000000000..a89c18be9a --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/storeSubmissionReviewerId.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type StoreSubmissionReviewerId = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/storeSubmissionStoreListingVersionId.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/storeSubmissionStoreListingVersionId.ts new file mode 100644 index 0000000000..87be23bc93 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/storeSubmissionStoreListingVersionId.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type StoreSubmissionStoreListingVersionId = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/storeSubmissionVersion.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/storeSubmissionVersion.ts new file mode 100644 index 0000000000..7a9623e1bc --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/storeSubmissionVersion.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type StoreSubmissionVersion = number | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/storeSubmissionsResponse.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/storeSubmissionsResponse.ts new file mode 100644 index 0000000000..0995244b9c --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/storeSubmissionsResponse.ts @@ -0,0 +1,14 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { StoreSubmission } from "./storeSubmission"; +import type { Pagination } from "./pagination"; + +export interface StoreSubmissionsResponse { + submissions: StoreSubmission[]; + pagination: Pagination; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/submissionStatus.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/submissionStatus.ts new file mode 100644 index 0000000000..fd3a42fea5 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/submissionStatus.ts @@ -0,0 +1,18 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type SubmissionStatus = + (typeof SubmissionStatus)[keyof typeof SubmissionStatus]; + +// eslint-disable-next-line @typescript-eslint/no-redeclare +export const SubmissionStatus = { + DRAFT: "DRAFT", + PENDING: "PENDING", + APPROVED: "APPROVED", + REJECTED: "REJECTED", +} as const; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/transactionHistory.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/transactionHistory.ts new file mode 100644 index 0000000000..20303cbaa1 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/transactionHistory.ts @@ -0,0 +1,14 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { UserTransaction } from "./userTransaction"; +import type { TransactionHistoryNextTransactionTime } from "./transactionHistoryNextTransactionTime"; + +export interface TransactionHistory { + transactions: UserTransaction[]; + next_transaction_time: TransactionHistoryNextTransactionTime; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/transactionHistoryNextTransactionTime.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/transactionHistoryNextTransactionTime.ts new file mode 100644 index 0000000000..e18d217480 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/transactionHistoryNextTransactionTime.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type TransactionHistoryNextTransactionTime = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/triggeredPresetSetupParams.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/triggeredPresetSetupParams.ts new file mode 100644 index 0000000000..005fbf1042 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/triggeredPresetSetupParams.ts @@ -0,0 +1,16 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { TriggeredPresetSetupParamsTriggerConfig } from "./triggeredPresetSetupParamsTriggerConfig"; +import type { TriggeredPresetSetupParamsAgentCredentials } from "./triggeredPresetSetupParamsAgentCredentials"; + +export interface TriggeredPresetSetupParams { + name: string; + description?: string; + trigger_config: TriggeredPresetSetupParamsTriggerConfig; + agent_credentials?: TriggeredPresetSetupParamsAgentCredentials; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/triggeredPresetSetupParamsAgentCredentials.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/triggeredPresetSetupParamsAgentCredentials.ts new file mode 100644 index 0000000000..03f52d444f --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/triggeredPresetSetupParamsAgentCredentials.ts @@ -0,0 +1,12 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { CredentialsMetaInput } from "./credentialsMetaInput"; + +export type TriggeredPresetSetupParamsAgentCredentials = { + [key: string]: CredentialsMetaInput; +}; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/triggeredPresetSetupParamsTriggerConfig.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/triggeredPresetSetupParamsTriggerConfig.ts new file mode 100644 index 0000000000..3d515dfd09 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/triggeredPresetSetupParamsTriggerConfig.ts @@ -0,0 +1,11 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type TriggeredPresetSetupParamsTriggerConfig = { + [key: string]: unknown; +}; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/turnstileVerifyRequest.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/turnstileVerifyRequest.ts new file mode 100644 index 0000000000..75bdc2f91e --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/turnstileVerifyRequest.ts @@ -0,0 +1,18 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { TurnstileVerifyRequestAction } from "./turnstileVerifyRequestAction"; + +/** + * Request model for verifying a Turnstile token. + */ +export interface TurnstileVerifyRequest { + /** The Turnstile token to verify */ + token: string; + /** The action that the user is attempting to perform */ + action?: TurnstileVerifyRequestAction; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/turnstileVerifyRequestAction.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/turnstileVerifyRequestAction.ts new file mode 100644 index 0000000000..9506b2993b --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/turnstileVerifyRequestAction.ts @@ -0,0 +1,12 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +/** + * The action that the user is attempting to perform + */ +export type TurnstileVerifyRequestAction = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/turnstileVerifyResponse.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/turnstileVerifyResponse.ts new file mode 100644 index 0000000000..6ee4d8966d --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/turnstileVerifyResponse.ts @@ -0,0 +1,27 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { TurnstileVerifyResponseError } from "./turnstileVerifyResponseError"; +import type { TurnstileVerifyResponseChallengeTimestamp } from "./turnstileVerifyResponseChallengeTimestamp"; +import type { TurnstileVerifyResponseHostname } from "./turnstileVerifyResponseHostname"; +import type { TurnstileVerifyResponseAction } from "./turnstileVerifyResponseAction"; + +/** + * Response model for the Turnstile verification endpoint. + */ +export interface TurnstileVerifyResponse { + /** Whether the token verification was successful */ + success: boolean; + /** Error message if verification failed */ + error?: TurnstileVerifyResponseError; + /** Timestamp of the challenge (ISO format) */ + challenge_timestamp?: TurnstileVerifyResponseChallengeTimestamp; + /** Hostname of the site where the challenge was solved */ + hostname?: TurnstileVerifyResponseHostname; + /** The action associated with this verification */ + action?: TurnstileVerifyResponseAction; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/turnstileVerifyResponseAction.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/turnstileVerifyResponseAction.ts new file mode 100644 index 0000000000..254fb74a27 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/turnstileVerifyResponseAction.ts @@ -0,0 +1,12 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +/** + * The action associated with this verification + */ +export type TurnstileVerifyResponseAction = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/turnstileVerifyResponseChallengeTimestamp.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/turnstileVerifyResponseChallengeTimestamp.ts new file mode 100644 index 0000000000..b0a4d5dbfc --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/turnstileVerifyResponseChallengeTimestamp.ts @@ -0,0 +1,12 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +/** + * Timestamp of the challenge (ISO format) + */ +export type TurnstileVerifyResponseChallengeTimestamp = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/turnstileVerifyResponseError.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/turnstileVerifyResponseError.ts new file mode 100644 index 0000000000..b9a3d06271 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/turnstileVerifyResponseError.ts @@ -0,0 +1,12 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +/** + * Error message if verification failed + */ +export type TurnstileVerifyResponseError = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/turnstileVerifyResponseHostname.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/turnstileVerifyResponseHostname.ts new file mode 100644 index 0000000000..f293b4baec --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/turnstileVerifyResponseHostname.ts @@ -0,0 +1,12 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +/** + * Hostname of the site where the challenge was solved + */ +export type TurnstileVerifyResponseHostname = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/updatePermissionsRequest.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/updatePermissionsRequest.ts new file mode 100644 index 0000000000..add6cd2895 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/updatePermissionsRequest.ts @@ -0,0 +1,12 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { APIKeyPermission } from "./aPIKeyPermission"; + +export interface UpdatePermissionsRequest { + permissions: APIKeyPermission[]; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/userHistoryResponse.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/userHistoryResponse.ts new file mode 100644 index 0000000000..5cbfe74cf6 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/userHistoryResponse.ts @@ -0,0 +1,17 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { UserTransaction } from "./userTransaction"; +import type { Pagination } from "./pagination"; + +/** + * Response model for listings with version history + */ +export interface UserHistoryResponse { + history: UserTransaction[]; + pagination: Pagination; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/userOnboardingUpdate.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/userOnboardingUpdate.ts new file mode 100644 index 0000000000..4772393d30 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/userOnboardingUpdate.ts @@ -0,0 +1,30 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { UserOnboardingUpdateCompletedSteps } from "./userOnboardingUpdateCompletedSteps"; +import type { UserOnboardingUpdateNotificationDot } from "./userOnboardingUpdateNotificationDot"; +import type { UserOnboardingUpdateNotified } from "./userOnboardingUpdateNotified"; +import type { UserOnboardingUpdateUsageReason } from "./userOnboardingUpdateUsageReason"; +import type { UserOnboardingUpdateIntegrations } from "./userOnboardingUpdateIntegrations"; +import type { UserOnboardingUpdateOtherIntegrations } from "./userOnboardingUpdateOtherIntegrations"; +import type { UserOnboardingUpdateSelectedStoreListingVersionId } from "./userOnboardingUpdateSelectedStoreListingVersionId"; +import type { UserOnboardingUpdateAgentInput } from "./userOnboardingUpdateAgentInput"; +import type { UserOnboardingUpdateOnboardingAgentExecutionId } from "./userOnboardingUpdateOnboardingAgentExecutionId"; +import type { UserOnboardingUpdateAgentRuns } from "./userOnboardingUpdateAgentRuns"; + +export interface UserOnboardingUpdate { + completedSteps?: UserOnboardingUpdateCompletedSteps; + notificationDot?: UserOnboardingUpdateNotificationDot; + notified?: UserOnboardingUpdateNotified; + usageReason?: UserOnboardingUpdateUsageReason; + integrations?: UserOnboardingUpdateIntegrations; + otherIntegrations?: UserOnboardingUpdateOtherIntegrations; + selectedStoreListingVersionId?: UserOnboardingUpdateSelectedStoreListingVersionId; + agentInput?: UserOnboardingUpdateAgentInput; + onboardingAgentExecutionId?: UserOnboardingUpdateOnboardingAgentExecutionId; + agentRuns?: UserOnboardingUpdateAgentRuns; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/userOnboardingUpdateAgentInput.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/userOnboardingUpdateAgentInput.ts new file mode 100644 index 0000000000..7aff087768 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/userOnboardingUpdateAgentInput.ts @@ -0,0 +1,11 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { UserOnboardingUpdateAgentInputAnyOf } from "./userOnboardingUpdateAgentInputAnyOf"; + +export type UserOnboardingUpdateAgentInput = + UserOnboardingUpdateAgentInputAnyOf | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/userOnboardingUpdateAgentInputAnyOf.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/userOnboardingUpdateAgentInputAnyOf.ts new file mode 100644 index 0000000000..e80858c009 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/userOnboardingUpdateAgentInputAnyOf.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type UserOnboardingUpdateAgentInputAnyOf = { [key: string]: unknown }; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/userOnboardingUpdateAgentRuns.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/userOnboardingUpdateAgentRuns.ts new file mode 100644 index 0000000000..86b63b2d36 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/userOnboardingUpdateAgentRuns.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type UserOnboardingUpdateAgentRuns = number | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/userOnboardingUpdateCompletedSteps.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/userOnboardingUpdateCompletedSteps.ts new file mode 100644 index 0000000000..587c501dfe --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/userOnboardingUpdateCompletedSteps.ts @@ -0,0 +1,10 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { OnboardingStep } from "./onboardingStep"; + +export type UserOnboardingUpdateCompletedSteps = OnboardingStep[] | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/userOnboardingUpdateIntegrations.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/userOnboardingUpdateIntegrations.ts new file mode 100644 index 0000000000..2b9d88820a --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/userOnboardingUpdateIntegrations.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type UserOnboardingUpdateIntegrations = string[] | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/userOnboardingUpdateNotificationDot.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/userOnboardingUpdateNotificationDot.ts new file mode 100644 index 0000000000..8e3b3f5715 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/userOnboardingUpdateNotificationDot.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type UserOnboardingUpdateNotificationDot = boolean | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/userOnboardingUpdateNotified.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/userOnboardingUpdateNotified.ts new file mode 100644 index 0000000000..5b6bfe7f2f --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/userOnboardingUpdateNotified.ts @@ -0,0 +1,10 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { OnboardingStep } from "./onboardingStep"; + +export type UserOnboardingUpdateNotified = OnboardingStep[] | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/userOnboardingUpdateOnboardingAgentExecutionId.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/userOnboardingUpdateOnboardingAgentExecutionId.ts new file mode 100644 index 0000000000..22a9287ef6 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/userOnboardingUpdateOnboardingAgentExecutionId.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type UserOnboardingUpdateOnboardingAgentExecutionId = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/userOnboardingUpdateOtherIntegrations.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/userOnboardingUpdateOtherIntegrations.ts new file mode 100644 index 0000000000..646db4c056 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/userOnboardingUpdateOtherIntegrations.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type UserOnboardingUpdateOtherIntegrations = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/userOnboardingUpdateSelectedStoreListingVersionId.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/userOnboardingUpdateSelectedStoreListingVersionId.ts new file mode 100644 index 0000000000..a4e565d2dd --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/userOnboardingUpdateSelectedStoreListingVersionId.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type UserOnboardingUpdateSelectedStoreListingVersionId = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/userOnboardingUpdateUsageReason.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/userOnboardingUpdateUsageReason.ts new file mode 100644 index 0000000000..27963ed9b4 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/userOnboardingUpdateUsageReason.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type UserOnboardingUpdateUsageReason = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/userPasswordCredentials.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/userPasswordCredentials.ts new file mode 100644 index 0000000000..b1738849cb --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/userPasswordCredentials.ts @@ -0,0 +1,17 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { UserPasswordCredentialsTitle } from "./userPasswordCredentialsTitle"; + +export interface UserPasswordCredentials { + id?: string; + provider: string; + title?: UserPasswordCredentialsTitle; + type?: "user_password"; + username: string; + password: string; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/userPasswordCredentialsTitle.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/userPasswordCredentialsTitle.ts new file mode 100644 index 0000000000..c23ec7506a --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/userPasswordCredentialsTitle.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type UserPasswordCredentialsTitle = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/userTransaction.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/userTransaction.ts new file mode 100644 index 0000000000..a43062920e --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/userTransaction.ts @@ -0,0 +1,34 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { CreditTransactionType } from "./creditTransactionType"; +import type { UserTransactionDescription } from "./userTransactionDescription"; +import type { UserTransactionUsageGraphId } from "./userTransactionUsageGraphId"; +import type { UserTransactionUsageExecutionId } from "./userTransactionUsageExecutionId"; +import type { UserTransactionUserEmail } from "./userTransactionUserEmail"; +import type { UserTransactionReason } from "./userTransactionReason"; +import type { UserTransactionAdminEmail } from "./userTransactionAdminEmail"; +import type { UserTransactionExtraData } from "./userTransactionExtraData"; + +export interface UserTransaction { + transaction_key?: string; + transaction_time?: string; + transaction_type?: CreditTransactionType; + amount?: number; + running_balance?: number; + current_balance?: number; + description?: UserTransactionDescription; + usage_graph_id?: UserTransactionUsageGraphId; + usage_execution_id?: UserTransactionUsageExecutionId; + usage_node_count?: number; + usage_start_time?: string; + user_id: string; + user_email?: UserTransactionUserEmail; + reason?: UserTransactionReason; + admin_email?: UserTransactionAdminEmail; + extra_data?: UserTransactionExtraData; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/userTransactionAdminEmail.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/userTransactionAdminEmail.ts new file mode 100644 index 0000000000..6caa54836a --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/userTransactionAdminEmail.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type UserTransactionAdminEmail = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/userTransactionDescription.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/userTransactionDescription.ts new file mode 100644 index 0000000000..2e47fb2436 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/userTransactionDescription.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type UserTransactionDescription = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/userTransactionExtraData.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/userTransactionExtraData.ts new file mode 100644 index 0000000000..2d1150ae93 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/userTransactionExtraData.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type UserTransactionExtraData = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/userTransactionReason.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/userTransactionReason.ts new file mode 100644 index 0000000000..6a5dfd23d1 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/userTransactionReason.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type UserTransactionReason = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/userTransactionUsageExecutionId.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/userTransactionUsageExecutionId.ts new file mode 100644 index 0000000000..cd5675662b --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/userTransactionUsageExecutionId.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type UserTransactionUsageExecutionId = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/userTransactionUsageGraphId.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/userTransactionUsageGraphId.ts new file mode 100644 index 0000000000..57eaa4505b --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/userTransactionUsageGraphId.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type UserTransactionUsageGraphId = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/userTransactionUserEmail.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/userTransactionUserEmail.ts new file mode 100644 index 0000000000..f3fa396804 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/userTransactionUserEmail.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type UserTransactionUserEmail = string | null; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/validationError.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/validationError.ts new file mode 100644 index 0000000000..0d6b4688dd --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/validationError.ts @@ -0,0 +1,14 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { ValidationErrorLocItem } from "./validationErrorLocItem"; + +export interface ValidationError { + loc: ValidationErrorLocItem[]; + msg: string; + type: string; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/validationErrorLocItem.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/validationErrorLocItem.ts new file mode 100644 index 0000000000..28822590d3 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/validationErrorLocItem.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type ValidationErrorLocItem = string | number; diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/webhook.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/webhook.ts new file mode 100644 index 0000000000..0f48986b6a --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/webhook.ts @@ -0,0 +1,23 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ +import type { ProviderName } from "./providerName"; +import type { WebhookConfig } from "./webhookConfig"; + +export interface Webhook { + id?: string; + user_id: string; + provider: ProviderName; + credentials_id: string; + webhook_type: string; + resource: string; + events: string[]; + config?: WebhookConfig; + secret: string; + provider_webhook_id: string; + readonly url: string; +} diff --git a/autogpt_platform/frontend/src/app/api/__generated__/models/webhookConfig.ts b/autogpt_platform/frontend/src/app/api/__generated__/models/webhookConfig.ts new file mode 100644 index 0000000000..0a6619bbb0 --- /dev/null +++ b/autogpt_platform/frontend/src/app/api/__generated__/models/webhookConfig.ts @@ -0,0 +1,9 @@ +/** + * Generated by orval v7.10.0 🍺 + * Do not edit manually. + * AutoGPT Agent Server + * This server is used to execute agents that are created by the AutoGPT system. + * OpenAPI spec version: 0.1 + */ + +export type WebhookConfig = { [key: string]: unknown }; diff --git a/autogpt_platform/frontend/src/app/api/proxy/[...path]/route.ts b/autogpt_platform/frontend/src/app/api/proxy/[...path]/route.ts index dd959a31cd..4ef22629ba 100644 --- a/autogpt_platform/frontend/src/app/api/proxy/[...path]/route.ts +++ b/autogpt_platform/frontend/src/app/api/proxy/[...path]/route.ts @@ -1,15 +1,20 @@ -import { NextRequest, NextResponse } from "next/server"; import { - makeAuthenticatedRequest, makeAuthenticatedFileUpload, + makeAuthenticatedRequest, } from "@/lib/autogpt-server-api/helpers"; +import { NextRequest, NextResponse } from "next/server"; -const BACKEND_BASE_URL = - process.env.NEXT_PUBLIC_AGPT_SERVER_BASE_URL || "http://localhost:8006"; +function getBackendBaseUrl() { + if (process.env.NEXT_PUBLIC_AGPT_SERVER_URL) { + return process.env.NEXT_PUBLIC_AGPT_SERVER_URL.replace("/api", ""); + } + + return "http://localhost:8006"; +} function buildBackendUrl(path: string[], queryString: string): string { const backendPath = path.join("/"); - return `${BACKEND_BASE_URL}/${backendPath}${queryString}`; + return `${getBackendBaseUrl()}/${backendPath}${queryString}`; } async function handleJsonRequest( @@ -145,9 +150,9 @@ async function handler( } export { + handler as DELETE, handler as GET, + handler as PATCH, handler as POST, handler as PUT, - handler as PATCH, - handler as DELETE, }; diff --git a/autogpt_platform/installer/setup-autogpt.bat b/autogpt_platform/installer/setup-autogpt.bat new file mode 100644 index 0000000000..f78a50de71 --- /dev/null +++ b/autogpt_platform/installer/setup-autogpt.bat @@ -0,0 +1,132 @@ +@echo off +setlocal enabledelayedexpansion + +goto :main + +REM --- Helper: Check command existence --- +:check_command +if "%1"=="" ( + echo ERROR: check_command called with no command argument! + pause + exit /b 1 +) +where %1 >nul 2>nul +if errorlevel 1 ( + echo %2 is not installed. Please install it and try again. + pause + exit /b 1 +) else ( + echo %2 is installed. +) +goto :eof + +:main +echo ============================= +echo AutoGPT Windows Setup +echo ============================= +echo. + +REM --- Variables --- +set SCRIPT_DIR=%~dp0 +set LOG_DIR=%SCRIPT_DIR%logs +set BACKEND_LOG=%LOG_DIR%\backend_setup.log +set FRONTEND_LOG=%LOG_DIR%\frontend_setup.log +set CLONE_NEEDED=0 +set REPO_DIR=%SCRIPT_DIR%..\.. + +REM --- Create logs folder immediately --- +if not exist "%LOG_DIR%" mkdir "%LOG_DIR%" + +echo Checking prerequisites... +call :check_command git Git +call :check_command docker Docker +call :check_command npm Node.js +call :check_command pnpm pnpm +echo. + +REM --- Detect repo --- +if exist "%REPO_DIR%\.git" ( + set CLONE_NEEDED=0 +) else ( + set REPO_DIR=%SCRIPT_DIR%AutoGPT + set CLONE_NEEDED=1 +) + +REM --- Clone repo if needed --- +if %CLONE_NEEDED%==1 ( + echo Cloning AutoGPT repository... + git clone https://github.com/Significant-Gravitas/AutoGPT.git "%REPO_DIR%" + if errorlevel 1 ( + echo Failed to clone repository. + pause + exit /b 1 + ) +) else ( + echo Using existing AutoGPT repository. +) +echo. + +REM --- Prompt for Sentry enablement --- +set SENTRY_ENABLED=0 +echo Would you like to enable debug information to be shared so we can fix your issues? [Y/n] +set /p sentry_answer="Enable Sentry? [Y/n]: " +if /I "%sentry_answer%"=="" set SENTRY_ENABLED=1 +if /I "%sentry_answer%"=="y" set SENTRY_ENABLED=1 +if /I "%sentry_answer%"=="yes" set SENTRY_ENABLED=1 +if /I "%sentry_answer%"=="n" set SENTRY_ENABLED=0 +if /I "%sentry_answer%"=="no" set SENTRY_ENABLED=0 + +REM --- Setup backend --- +echo Setting up backend services... +echo. +cd /d "%REPO_DIR%\autogpt_platform" +if exist .env.example copy /Y .env.example .env >nul +cd backend +if exist .env.example copy /Y .env.example .env >nul + +REM --- Set SENTRY_DSN in backend/.env --- +set SENTRY_DSN=https://11d0640fef35640e0eb9f022eb7d7626@o4505260022104064.ingest.us.sentry.io/4507890252447744 +if %SENTRY_ENABLED%==1 ( + powershell -Command "(Get-Content .env) -replace '^SENTRY_DSN=.*', 'SENTRY_DSN=%SENTRY_DSN%' | Set-Content .env" + echo Sentry enabled in backend. +) else ( + powershell -Command "(Get-Content .env) -replace '^SENTRY_DSN=.*', 'SENTRY_DSN=' | Set-Content .env" + echo Sentry not enabled in backend. +) +cd .. + +docker compose down > "%BACKEND_LOG%" 2>&1 +if errorlevel 1 echo (docker compose down failed, continuing...) +docker compose up -d --build >> "%BACKEND_LOG%" 2>&1 +if errorlevel 1 ( + echo Backend setup failed. See log: %BACKEND_LOG% + pause + exit /b 1 +) +echo Backend services started successfully. +echo. + +REM --- Setup frontend --- +echo Setting up frontend application... +echo. +cd frontend +if exist .env.example copy /Y .env.example .env >nul +call pnpm.cmd install +if errorlevel 1 ( + echo pnpm install failed! + pause + exit /b 1 +) +echo Frontend dependencies installed successfully. +echo. + +REM --- Start frontend dev server in the same terminal --- +echo Setup complete! +echo Access AutoGPT at: http://localhost:3000 +echo To stop services, press Ctrl+C and run "docker compose down" in %REPO_DIR%\autogpt_platform +echo. +echo The frontend will now start in this terminal. Closing this window will stop the frontend. +echo Press Ctrl+C to stop the frontend at any time. +echo. + +call pnpm.cmd dev \ No newline at end of file diff --git a/autogpt_platform/installer/setup-autogpt.sh b/autogpt_platform/installer/setup-autogpt.sh new file mode 100644 index 0000000000..4afdbce51a --- /dev/null +++ b/autogpt_platform/installer/setup-autogpt.sh @@ -0,0 +1,339 @@ +#!/bin/bash + +# ------------------------------------------------------------------------------ +# AutoGPT Setup Script +# ------------------------------------------------------------------------------ +# This script automates the installation and setup of AutoGPT on Linux systems. +# It checks prerequisites, clones the repository, sets up backend and frontend, +# configures Sentry (optional), and starts all services. Designed for clarity +# and maintainability. Run this script from a terminal. +# ------------------------------------------------------------------------------ + +# --- Global Variables --- +GREEN='\033[0;32m' +BLUE='\033[0;34m' +YELLOW='\033[1;33m' +RED='\033[0;31m' +NC='\033[0m' # No Color +REPO_DIR="" +CLONE_NEEDED=false +DOCKER_CMD="docker" +DOCKER_COMPOSE_CMD="docker compose" +LOG_DIR="" +SENTRY_ENABLED=0 + +# ------------------------------------------------------------------------------ +# Helper Functions +# ------------------------------------------------------------------------------ + +# Print colored text +print_color() { + printf "${!1}%s${NC}\n" "$2" +} + +# Print the ASCII banner +print_banner() { + print_color "BLUE" " + d8888 888 .d8888b. 8888888b. 88888888888 + d88888 888 d88P Y88b 888 Y88b 888 + d88P888 888 888 888 888 888 888 + d88P 888 888 888 888888 .d88b. 888 888 d88P 888 + d88P 888 888 888 888 d88\"\"88b 888 88888 8888888P\" 888 + d88P 888 888 888 888 888 888 888 888 888 888 + d8888888888 Y88b 888 Y88b. Y88..88P Y88b d88P 888 888 +d88P 888 \"Y88888 \"Y888 \"Y88P\" \"Y8888P88 888 888 +" +} + +# Handle errors and exit +handle_error() { + echo "" + print_color "RED" "Error: $1" + print_color "YELLOW" "Press Enter to exit..." + read -r + exit 1 +} + +# ------------------------------------------------------------------------------ +# Logging Functions +# ------------------------------------------------------------------------------ + +# Prepare log directory +setup_logs() { + LOG_DIR="$REPO_DIR/autogpt_platform/logs" + mkdir -p "$LOG_DIR" +} + +# ------------------------------------------------------------------------------ +# Health Check Functions +# ------------------------------------------------------------------------------ + +# Check service health by polling an endpoint +check_health() { + local url=$1 + local expected=$2 + local name=$3 + local max_attempts=$4 + local timeout=$5 + + if ! command -v curl &> /dev/null; then + echo "curl not found. Skipping health check for $name." + return 0 + fi + + echo "Checking $name health..." + for ((attempt=1; attempt<=max_attempts; attempt++)); do + echo "Attempt $attempt/$max_attempts" + response=$(curl -s --max-time "$timeout" "$url") + if [[ "$response" == *"$expected"* ]]; then + echo "✓ $name is healthy" + return 0 + fi + echo "Waiting 5s before next attempt..." + sleep 5 + done + echo "✗ $name health check failed after $max_attempts attempts" + return 1 +} + +# ------------------------------------------------------------------------------ +# Prerequisite and Environment Functions +# ------------------------------------------------------------------------------ + +# Check for required commands +check_command() { + local cmd=$1 + local name=$2 + local url=$3 + + if ! command -v "$cmd" &> /dev/null; then + handle_error "$name is not installed. Please install it and try again. Visit $url" + else + print_color "GREEN" "✓ $name is installed" + fi +} + +# Check for optional commands +check_command_optional() { + local cmd=$1 + if command -v "$cmd" &> /dev/null; then + print_color "GREEN" "✓ $cmd is installed" + else + print_color "YELLOW" "$cmd is not installed. Some features will be skipped." + fi +} + +# Check Docker permissions and adjust commands if needed +check_docker_permissions() { + if ! docker info &> /dev/null; then + print_color "YELLOW" "Docker requires elevated privileges. Using sudo for Docker commands..." + DOCKER_CMD="sudo docker" + DOCKER_COMPOSE_CMD="sudo docker compose" + fi +} + +# Check all prerequisites +check_prerequisites() { + print_color "GREEN" "AutoGPT's Automated Setup Script" + print_color "GREEN" "-------------------------------" + print_color "BLUE" "This script will automatically install and set up AutoGPT for you." + echo "" + print_color "YELLOW" "Checking prerequisites:" + + check_command git "Git" "https://git-scm.com/downloads" + check_command docker "Docker" "https://docs.docker.com/get-docker/" + check_docker_permissions + check_command npm "npm (Node.js)" "https://nodejs.org/en/download/" + check_command pnpm "pnpm (Node.js package manager)" "https://pnpm.io/installation" + check_command_optional curl "curl" + + print_color "GREEN" "All prerequisites are installed! Starting installation..." + echo "" +} + +# Detect installation mode and set repo directory +# (Clones if not in a repo, otherwise uses current directory) +detect_installation_mode() { + if [[ "$PWD" == */autogpt_platform/installer ]]; then + if [[ -d "../../.git" ]]; then + REPO_DIR="$(cd ../..; pwd)" + CLONE_NEEDED=false + cd ../.. || handle_error "Failed to navigate to repository root." + else + CLONE_NEEDED=true + REPO_DIR="$(pwd)/AutoGPT" + cd "$(dirname \"$(dirname \"$(dirname \"$PWD\")\")\")" || handle_error "Failed to navigate to parent directory." + fi + elif [[ -d ".git" && -d "autogpt_platform/installer" ]]; then + REPO_DIR="$PWD" + CLONE_NEEDED=false + else + CLONE_NEEDED=true + REPO_DIR="$(pwd)/AutoGPT" + fi +} + +# Clone the repository if needed +clone_repository() { + if [ "$CLONE_NEEDED" = true ]; then + print_color "BLUE" "Cloning AutoGPT repository..." + if git clone https://github.com/Significant-Gravitas/AutoGPT.git "$REPO_DIR"; then + print_color "GREEN" "✓ Repo cloned successfully!" + else + handle_error "Failed to clone the repository." + fi + else + print_color "GREEN" "Using existing AutoGPT repository" + fi +} + +# Prompt for Sentry enablement and set global flag +prompt_sentry_enablement() { + print_color "YELLOW" "Would you like to enable debug information to be shared so we can fix your issues? [Y/n]" + read -r sentry_answer + case "${sentry_answer,,}" in + ""|y|yes) + SENTRY_ENABLED=1 + ;; + n|no) + SENTRY_ENABLED=0 + ;; + *) + print_color "YELLOW" "Invalid input. Defaulting to yes. Sentry will be enabled." + SENTRY_ENABLED=1 + ;; + esac +} + +# ------------------------------------------------------------------------------ +# Setup Functions +# ------------------------------------------------------------------------------ + +# Set up backend services and configure Sentry if enabled +setup_backend() { + print_color "BLUE" "Setting up backend services..." + cd "$REPO_DIR/autogpt_platform" || handle_error "Failed to navigate to backend directory." + cp .env.example .env || handle_error "Failed to copy environment file." + + # Set SENTRY_DSN in backend/.env + cd backend || handle_error "Failed to navigate to backend subdirectory." + cp .env.example .env || handle_error "Failed to copy backend environment file." + sentry_url="https://11d0640fef35640e0eb9f022eb7d7626@o4505260022104064.ingest.us.sentry.io/4507890252447744" + if [ "$SENTRY_ENABLED" = "1" ]; then + sed -i "s|^SENTRY_DSN=.*$|SENTRY_DSN=$sentry_url|" .env || echo "SENTRY_DSN=$sentry_url" >> .env + print_color "GREEN" "Sentry enabled in backend." + else + sed -i "s|^SENTRY_DSN=.*$|SENTRY_DSN=|" .env || echo "SENTRY_DSN=" >> .env + print_color "YELLOW" "Sentry not enabled in backend." + fi + cd .. # back to autogpt_platform + + $DOCKER_COMPOSE_CMD down || handle_error "Failed to stop existing backend services." + $DOCKER_COMPOSE_CMD up -d --build || handle_error "Failed to start backend services." + print_color "GREEN" "✓ Backend services started successfully" +} + +# Set up frontend application +setup_frontend() { + print_color "BLUE" "Setting up frontend application..." + cd "$REPO_DIR/autogpt_platform/frontend" || handle_error "Failed to navigate to frontend directory." + cp .env.example .env || handle_error "Failed to copy frontend environment file." + corepack enable || handle_error "Failed to enable corepack." + pnpm install || handle_error "Failed to install frontend dependencies." + print_color "GREEN" "✓ Frontend dependencies installed successfully" +} + +# Run backend and frontend setup concurrently and manage logs +run_concurrent_setup() { + setup_logs + backend_log="$LOG_DIR/backend_setup.log" + frontend_log="$LOG_DIR/frontend_setup.log" + + : > "$backend_log" + : > "$frontend_log" + + setup_backend > "$backend_log" 2>&1 & + backend_pid=$! + echo "Backend setup finished." + + setup_frontend > "$frontend_log" 2>&1 & + frontend_pid=$! + echo "Frontend setup finished." + + show_spinner "$backend_pid" "$frontend_pid" + + wait $backend_pid; backend_status=$? + wait $frontend_pid; frontend_status=$? + + if [ $backend_status -ne 0 ]; then + print_color "RED" "Backend setup failed. See log: $backend_log" + exit 1 + fi + + if [ $frontend_status -ne 0 ]; then + print_color "RED" "Frontend setup failed. See log: $frontend_log" + exit 1 + fi + +} + +# Show a spinner while background jobs run +show_spinner() { + local backend_pid=$1 + local frontend_pid=$2 + spin='-\|/' + i=0 + messages=("Working..." "Still working..." "Setting up dependencies..." "Almost there...") + msg_index=0 + msg_counter=0 + clear_line=" " + + while kill -0 $backend_pid 2>/dev/null || kill -0 $frontend_pid 2>/dev/null; do + i=$(( (i+1) % 4 )) + msg_counter=$(( (msg_counter+1) % 300 )) + if [ $msg_counter -eq 0 ]; then + msg_index=$(( (msg_index+1) % ${#messages[@]} )) + fi + printf "\r${clear_line}\r${YELLOW}[%c]${NC} %s" "${spin:$i:1}" "${messages[$msg_index]}" + sleep .1 + done + printf "\r${clear_line}\r${GREEN}[✓]${NC} Setup completed!\n" +} + +# ------------------------------------------------------------------------------ +# Main Entry Point +# ------------------------------------------------------------------------------ + +main() { + print_banner + check_prerequisites + prompt_sentry_enablement + detect_installation_mode + clone_repository + setup_logs + run_concurrent_setup + + print_color "YELLOW" "Starting frontend..." + (cd "$REPO_DIR/autogpt_platform/frontend" && pnpm dev > "$LOG_DIR/frontend_dev.log" 2>&1 &) + + print_color "YELLOW" "Waiting for services to start..." + sleep 20 + + print_color "YELLOW" "Verifying services health..." + check_health "http://localhost:8006/health" "\"status\":\"healthy\"" "Backend" 6 15 + check_health "http://localhost:3000/health" "Yay im healthy" "Frontend" 6 15 + + if [ $backend_status -ne 0 ] || [ $frontend_status -ne 0 ]; then + print_color "RED" "Setup failed. See logs for details." + exit 1 + fi + + print_color "GREEN" "Setup complete!" + print_color "BLUE" "Access AutoGPT at: http://localhost:3000" + print_color "YELLOW" "To stop services, press Ctrl+C and run 'docker compose down' in $REPO_DIR/autogpt_platform" + echo "" + print_color "GREEN" "Press Enter to exit (services will keep running)..." + read -r +} + +main diff --git a/docs/content/platform/installer.md b/docs/content/platform/installer.md new file mode 100644 index 0000000000..3faf6a8239 --- /dev/null +++ b/docs/content/platform/installer.md @@ -0,0 +1,70 @@ +# AutoGPT Platform Installer + +The AutoGPT Platform provides easy-to-use installers to help you quickly set up the platform on your system. This page covers how to use the installer scripts for both Linux/macOS and Windows. + +## What the Installer Does + +The installer scripts will: + +1. Check for required prerequisites (Git, Docker, npm) +2. Clone the AutoGPT repository +3. Set up the backend services using Docker +4. Set up the frontend application +5. Start both the backend and frontend services + +## Prerequisites + +Before running the installer, make sure you have the following installed: + +- **Git**: For cloning the repository +- **Docker**: For running the backend services +- **Node.js and npm**: For the frontend application + +## Quick One-Liner Installation + +For convenience, you can use the following one-liner commands to install AutoGPT Platform: + +### Linux/macOS + +```bash +curl -fsSL https://setup.agpt.co/install.sh -o install.sh && bash install.sh +``` + +### Windows + +```powershell +powershell -c "iwr https://setup.agpt.co/install.bat -o install.bat; ./install.bat" +``` + +## Manual Installation + +If you prefer, you can manually download and run the installer scripts: + +- **Linux/macOS:** `setup-autogpt.sh` +- **Windows:** `setup-autogpt.bat` + +Follow the instructions in the [installer README](../../../../autogpt_platform/installer/README.md) for more details. + +## After Installation + +Once the installation is complete: +- The backend services will be running in Docker containers +- The frontend application will be available at http://localhost:3000 + +## Stopping the Services + +To stop the services, press Ctrl+C in the terminal where the frontend is running, then run: + +```bash +cd AutoGPT/autogpt_platform +docker compose down +``` + +## Troubleshooting + +If you encounter any issues during installation: + +1. Make sure all prerequisites are correctly installed +2. Check that Docker is running +3. Ensure you have a stable internet connection +4. Verify you have sufficient permissions to create directories and run Docker \ No newline at end of file