@aqajooon/mcp-server-azure-devops 0.0.0-stage → 0.1.55
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +318 -2
- package/dist/clients/azure-devops.d.ts +105 -0
- package/dist/clients/azure-devops.js +501 -0
- package/dist/clients/azure-devops.js.map +1 -0
- package/dist/features/environments/feature.d.ts +24 -0
- package/dist/features/environments/feature.js +48 -0
- package/dist/features/environments/feature.js.map +1 -0
- package/dist/features/environments/index.d.ts +10 -0
- package/dist/features/environments/index.js +42 -0
- package/dist/features/environments/index.js.map +1 -0
- package/dist/features/environments/schema.d.ts +7 -0
- package/dist/features/environments/schema.js +28 -0
- package/dist/features/environments/schema.js.map +1 -0
- package/dist/features/libraries/feature.d.ts +27 -0
- package/dist/features/libraries/feature.js +47 -0
- package/dist/features/libraries/feature.js.map +1 -0
- package/dist/features/libraries/index.d.ts +10 -0
- package/dist/features/libraries/index.js +42 -0
- package/dist/features/libraries/index.js.map +1 -0
- package/dist/features/libraries/schema.d.ts +7 -0
- package/dist/features/libraries/schema.js +27 -0
- package/dist/features/libraries/schema.js.map +1 -0
- package/dist/features/organizations/__test__/test-helpers.d.ts +13 -0
- package/dist/features/organizations/__test__/test-helpers.js +38 -0
- package/dist/features/organizations/__test__/test-helpers.js.map +1 -0
- package/dist/features/organizations/index.d.ts +13 -0
- package/dist/features/organizations/index.js +63 -0
- package/dist/features/organizations/index.js.map +1 -0
- package/dist/features/organizations/list-organizations/feature.d.ts +13 -0
- package/dist/features/organizations/list-organizations/feature.js +101 -0
- package/dist/features/organizations/list-organizations/feature.js.map +1 -0
- package/dist/features/organizations/list-organizations/index.d.ts +2 -0
- package/dist/features/organizations/list-organizations/index.js +19 -0
- package/dist/features/organizations/list-organizations/index.js.map +1 -0
- package/dist/features/organizations/list-organizations/schema.d.ts +2 -0
- package/dist/features/organizations/list-organizations/schema.js +6 -0
- package/dist/features/organizations/list-organizations/schema.js.map +1 -0
- package/dist/features/organizations/schemas.d.ts +6 -0
- package/dist/features/organizations/schemas.js +10 -0
- package/dist/features/organizations/schemas.js.map +1 -0
- package/dist/features/organizations/tool-definitions.d.ts +5 -0
- package/dist/features/organizations/tool-definitions.js +16 -0
- package/dist/features/organizations/tool-definitions.js.map +1 -0
- package/dist/features/organizations/types.d.ts +21 -0
- package/dist/features/organizations/types.js +8 -0
- package/dist/features/organizations/types.js.map +1 -0
- package/dist/features/pipelines/artifacts.d.ts +11 -0
- package/dist/features/pipelines/artifacts.js +288 -0
- package/dist/features/pipelines/artifacts.js.map +1 -0
- package/dist/features/pipelines/download-pipeline-artifact/feature.d.ts +3 -0
- package/dist/features/pipelines/download-pipeline-artifact/feature.js +222 -0
- package/dist/features/pipelines/download-pipeline-artifact/feature.js.map +1 -0
- package/dist/features/pipelines/download-pipeline-artifact/index.d.ts +2 -0
- package/dist/features/pipelines/download-pipeline-artifact/index.js +19 -0
- package/dist/features/pipelines/download-pipeline-artifact/index.js.map +1 -0
- package/dist/features/pipelines/download-pipeline-artifact/schema.d.ts +7 -0
- package/dist/features/pipelines/download-pipeline-artifact/schema.js +23 -0
- package/dist/features/pipelines/download-pipeline-artifact/schema.js.map +1 -0
- package/dist/features/pipelines/get-pipeline/feature.d.ts +10 -0
- package/dist/features/pipelines/get-pipeline/feature.js +46 -0
- package/dist/features/pipelines/get-pipeline/feature.js.map +1 -0
- package/dist/features/pipelines/get-pipeline/index.d.ts +2 -0
- package/dist/features/pipelines/get-pipeline/index.js +19 -0
- package/dist/features/pipelines/get-pipeline/index.js.map +1 -0
- package/dist/features/pipelines/get-pipeline/schema.d.ts +9 -0
- package/dist/features/pipelines/get-pipeline/schema.js +29 -0
- package/dist/features/pipelines/get-pipeline/schema.js.map +1 -0
- package/dist/features/pipelines/get-pipeline-log/feature.d.ts +3 -0
- package/dist/features/pipelines/get-pipeline-log/feature.js +57 -0
- package/dist/features/pipelines/get-pipeline-log/feature.js.map +1 -0
- package/dist/features/pipelines/get-pipeline-log/index.d.ts +2 -0
- package/dist/features/pipelines/get-pipeline-log/index.js +19 -0
- package/dist/features/pipelines/get-pipeline-log/index.js.map +1 -0
- package/dist/features/pipelines/get-pipeline-log/schema.d.ts +13 -0
- package/dist/features/pipelines/get-pipeline-log/schema.js +40 -0
- package/dist/features/pipelines/get-pipeline-log/schema.js.map +1 -0
- package/dist/features/pipelines/get-pipeline-run/feature.d.ts +3 -0
- package/dist/features/pipelines/get-pipeline-run/feature.js +76 -0
- package/dist/features/pipelines/get-pipeline-run/feature.js.map +1 -0
- package/dist/features/pipelines/get-pipeline-run/index.d.ts +2 -0
- package/dist/features/pipelines/get-pipeline-run/index.js +19 -0
- package/dist/features/pipelines/get-pipeline-run/index.js.map +1 -0
- package/dist/features/pipelines/get-pipeline-run/schema.d.ts +6 -0
- package/dist/features/pipelines/get-pipeline-run/schema.js +19 -0
- package/dist/features/pipelines/get-pipeline-run/schema.js.map +1 -0
- package/dist/features/pipelines/get-pipeline-run-sources/feature.d.ts +26 -0
- package/dist/features/pipelines/get-pipeline-run-sources/feature.js +105 -0
- package/dist/features/pipelines/get-pipeline-run-sources/feature.js.map +1 -0
- package/dist/features/pipelines/get-pipeline-run-sources/index.d.ts +2 -0
- package/dist/features/pipelines/get-pipeline-run-sources/index.js +19 -0
- package/dist/features/pipelines/get-pipeline-run-sources/index.js.map +1 -0
- package/dist/features/pipelines/get-pipeline-run-sources/schema.d.ts +6 -0
- package/dist/features/pipelines/get-pipeline-run-sources/schema.js +19 -0
- package/dist/features/pipelines/get-pipeline-run-sources/schema.js.map +1 -0
- package/dist/features/pipelines/get-pipeline-run-stage-tasks/feature.d.ts +47 -0
- package/dist/features/pipelines/get-pipeline-run-stage-tasks/feature.js +185 -0
- package/dist/features/pipelines/get-pipeline-run-stage-tasks/feature.js.map +1 -0
- package/dist/features/pipelines/get-pipeline-run-stage-tasks/index.d.ts +2 -0
- package/dist/features/pipelines/get-pipeline-run-stage-tasks/index.js +19 -0
- package/dist/features/pipelines/get-pipeline-run-stage-tasks/index.js.map +1 -0
- package/dist/features/pipelines/get-pipeline-run-stage-tasks/schema.d.ts +7 -0
- package/dist/features/pipelines/get-pipeline-run-stage-tasks/schema.js +21 -0
- package/dist/features/pipelines/get-pipeline-run-stage-tasks/schema.js.map +1 -0
- package/dist/features/pipelines/get-pipeline-run-yaml/feature.d.ts +41 -0
- package/dist/features/pipelines/get-pipeline-run-yaml/feature.js +450 -0
- package/dist/features/pipelines/get-pipeline-run-yaml/feature.js.map +1 -0
- package/dist/features/pipelines/get-pipeline-run-yaml/index.d.ts +2 -0
- package/dist/features/pipelines/get-pipeline-run-yaml/index.js +19 -0
- package/dist/features/pipelines/get-pipeline-run-yaml/index.js.map +1 -0
- package/dist/features/pipelines/get-pipeline-run-yaml/schema.d.ts +6 -0
- package/dist/features/pipelines/get-pipeline-run-yaml/schema.js +19 -0
- package/dist/features/pipelines/get-pipeline-run-yaml/schema.js.map +1 -0
- package/dist/features/pipelines/helpers.d.ts +3 -0
- package/dist/features/pipelines/helpers.js +29 -0
- package/dist/features/pipelines/helpers.js.map +1 -0
- package/dist/features/pipelines/index.d.ts +22 -0
- package/dist/features/pipelines/index.js +216 -0
- package/dist/features/pipelines/index.js.map +1 -0
- package/dist/features/pipelines/list-pipeline-runs/feature.d.ts +3 -0
- package/dist/features/pipelines/list-pipeline-runs/feature.js +98 -0
- package/dist/features/pipelines/list-pipeline-runs/feature.js.map +1 -0
- package/dist/features/pipelines/list-pipeline-runs/index.d.ts +2 -0
- package/dist/features/pipelines/list-pipeline-runs/index.js +19 -0
- package/dist/features/pipelines/list-pipeline-runs/index.js.map +1 -0
- package/dist/features/pipelines/list-pipeline-runs/schema.d.ts +28 -0
- package/dist/features/pipelines/list-pipeline-runs/schema.js +50 -0
- package/dist/features/pipelines/list-pipeline-runs/schema.js.map +1 -0
- package/dist/features/pipelines/list-pipelines/feature.d.ts +10 -0
- package/dist/features/pipelines/list-pipelines/feature.js +42 -0
- package/dist/features/pipelines/list-pipelines/feature.js.map +1 -0
- package/dist/features/pipelines/list-pipelines/index.d.ts +2 -0
- package/dist/features/pipelines/list-pipelines/index.js +19 -0
- package/dist/features/pipelines/list-pipelines/index.js.map +1 -0
- package/dist/features/pipelines/list-pipelines/schema.d.ts +9 -0
- package/dist/features/pipelines/list-pipelines/schema.js +23 -0
- package/dist/features/pipelines/list-pipelines/schema.js.map +1 -0
- package/dist/features/pipelines/pipeline-timeline/feature.d.ts +3 -0
- package/dist/features/pipelines/pipeline-timeline/feature.js +95 -0
- package/dist/features/pipelines/pipeline-timeline/feature.js.map +1 -0
- package/dist/features/pipelines/pipeline-timeline/index.d.ts +2 -0
- package/dist/features/pipelines/pipeline-timeline/index.js +19 -0
- package/dist/features/pipelines/pipeline-timeline/index.js.map +1 -0
- package/dist/features/pipelines/pipeline-timeline/schema.d.ts +31 -0
- package/dist/features/pipelines/pipeline-timeline/schema.js +51 -0
- package/dist/features/pipelines/pipeline-timeline/schema.js.map +1 -0
- package/dist/features/pipelines/tool-definitions.d.ts +5 -0
- package/dist/features/pipelines/tool-definitions.js +87 -0
- package/dist/features/pipelines/tool-definitions.js.map +1 -0
- package/dist/features/pipelines/trigger-pipeline/feature.d.ts +10 -0
- package/dist/features/pipelines/trigger-pipeline/feature.js +65 -0
- package/dist/features/pipelines/trigger-pipeline/feature.js.map +1 -0
- package/dist/features/pipelines/trigger-pipeline/index.d.ts +2 -0
- package/dist/features/pipelines/trigger-pipeline/index.js +8 -0
- package/dist/features/pipelines/trigger-pipeline/index.js.map +1 -0
- package/dist/features/pipelines/trigger-pipeline/schema.d.ts +15 -0
- package/dist/features/pipelines/trigger-pipeline/schema.js +45 -0
- package/dist/features/pipelines/trigger-pipeline/schema.js.map +1 -0
- package/dist/features/pipelines/types.d.ts +122 -0
- package/dist/features/pipelines/types.js +3 -0
- package/dist/features/pipelines/types.js.map +1 -0
- package/dist/features/projects/__test__/test-helpers.d.ts +13 -0
- package/dist/features/projects/__test__/test-helpers.js +35 -0
- package/dist/features/projects/__test__/test-helpers.js.map +1 -0
- package/dist/features/projects/get-project/feature.d.ts +11 -0
- package/dist/features/projects/get-project/feature.js +29 -0
- package/dist/features/projects/get-project/feature.js.map +1 -0
- package/dist/features/projects/get-project/index.d.ts +2 -0
- package/dist/features/projects/get-project/index.js +19 -0
- package/dist/features/projects/get-project/index.js.map +1 -0
- package/dist/features/projects/get-project/schema.d.ts +2 -0
- package/dist/features/projects/get-project/schema.js +6 -0
- package/dist/features/projects/get-project/schema.js.map +1 -0
- package/dist/features/projects/get-project-details/feature.d.ts +78 -0
- package/dist/features/projects/get-project-details/feature.js +185 -0
- package/dist/features/projects/get-project-details/feature.js.map +1 -0
- package/dist/features/projects/get-project-details/index.d.ts +2 -0
- package/dist/features/projects/get-project-details/index.js +8 -0
- package/dist/features/projects/get-project-details/index.js.map +1 -0
- package/dist/features/projects/get-project-details/schema.d.ts +2 -0
- package/dist/features/projects/get-project-details/schema.js +6 -0
- package/dist/features/projects/get-project-details/schema.js.map +1 -0
- package/dist/features/projects/index.d.ts +15 -0
- package/dist/features/projects/index.js +80 -0
- package/dist/features/projects/index.js.map +1 -0
- package/dist/features/projects/list-projects/feature.d.ts +10 -0
- package/dist/features/projects/list-projects/feature.js +25 -0
- package/dist/features/projects/list-projects/feature.js.map +1 -0
- package/dist/features/projects/list-projects/index.d.ts +2 -0
- package/dist/features/projects/list-projects/index.js +19 -0
- package/dist/features/projects/list-projects/index.js.map +1 -0
- package/dist/features/projects/list-projects/schema.d.ts +2 -0
- package/dist/features/projects/list-projects/schema.js +6 -0
- package/dist/features/projects/list-projects/schema.js.map +1 -0
- package/dist/features/projects/schemas.d.ts +30 -0
- package/dist/features/projects/schemas.js +76 -0
- package/dist/features/projects/schemas.js.map +1 -0
- package/dist/features/projects/tool-definitions.d.ts +5 -0
- package/dist/features/projects/tool-definitions.js +26 -0
- package/dist/features/projects/tool-definitions.js.map +1 -0
- package/dist/features/projects/types.d.ts +11 -0
- package/dist/features/projects/types.js +3 -0
- package/dist/features/projects/types.js.map +1 -0
- package/dist/features/pull-requests/add-pull-request-comment/feature.d.ts +13 -0
- package/dist/features/pull-requests/add-pull-request-comment/feature.js +161 -0
- package/dist/features/pull-requests/add-pull-request-comment/feature.js.map +1 -0
- package/dist/features/pull-requests/add-pull-request-comment/index.d.ts +1 -0
- package/dist/features/pull-requests/add-pull-request-comment/index.js +18 -0
- package/dist/features/pull-requests/add-pull-request-comment/index.js.map +1 -0
- package/dist/features/pull-requests/create-pull-request/feature.d.ts +12 -0
- package/dist/features/pull-requests/create-pull-request/feature.js +99 -0
- package/dist/features/pull-requests/create-pull-request/feature.js.map +1 -0
- package/dist/features/pull-requests/create-pull-request/index.d.ts +2 -0
- package/dist/features/pull-requests/create-pull-request/index.js +19 -0
- package/dist/features/pull-requests/create-pull-request/index.js.map +1 -0
- package/dist/features/pull-requests/create-pull-request/schema.d.ts +2 -0
- package/dist/features/pull-requests/create-pull-request/schema.js +6 -0
- package/dist/features/pull-requests/create-pull-request/schema.js.map +1 -0
- package/dist/features/pull-requests/get-pull-request/feature.d.ts +6 -0
- package/dist/features/pull-requests/get-pull-request/feature.js +22 -0
- package/dist/features/pull-requests/get-pull-request/feature.js.map +1 -0
- package/dist/features/pull-requests/get-pull-request/index.d.ts +2 -0
- package/dist/features/pull-requests/get-pull-request/index.js +19 -0
- package/dist/features/pull-requests/get-pull-request/index.js.map +1 -0
- package/dist/features/pull-requests/get-pull-request/schema.d.ts +1 -0
- package/dist/features/pull-requests/get-pull-request/schema.js +6 -0
- package/dist/features/pull-requests/get-pull-request/schema.js.map +1 -0
- package/dist/features/pull-requests/get-pull-request-changes/feature.d.ts +22 -0
- package/dist/features/pull-requests/get-pull-request-changes/feature.js +60 -0
- package/dist/features/pull-requests/get-pull-request-changes/feature.js.map +1 -0
- package/dist/features/pull-requests/get-pull-request-changes/index.d.ts +1 -0
- package/dist/features/pull-requests/get-pull-request-changes/index.js +18 -0
- package/dist/features/pull-requests/get-pull-request-changes/index.js.map +1 -0
- package/dist/features/pull-requests/get-pull-request-checks/feature.d.ts +51 -0
- package/dist/features/pull-requests/get-pull-request-checks/feature.js +259 -0
- package/dist/features/pull-requests/get-pull-request-checks/feature.js.map +1 -0
- package/dist/features/pull-requests/get-pull-request-checks/index.d.ts +1 -0
- package/dist/features/pull-requests/get-pull-request-checks/index.js +18 -0
- package/dist/features/pull-requests/get-pull-request-checks/index.js.map +1 -0
- package/dist/features/pull-requests/get-pull-request-comments/feature.d.ts +13 -0
- package/dist/features/pull-requests/get-pull-request-comments/feature.js +88 -0
- package/dist/features/pull-requests/get-pull-request-comments/feature.js.map +1 -0
- package/dist/features/pull-requests/get-pull-request-comments/index.d.ts +1 -0
- package/dist/features/pull-requests/get-pull-request-comments/index.js +18 -0
- package/dist/features/pull-requests/get-pull-request-comments/index.js.map +1 -0
- package/dist/features/pull-requests/index.d.ts +21 -0
- package/dist/features/pull-requests/index.js +167 -0
- package/dist/features/pull-requests/index.js.map +1 -0
- package/dist/features/pull-requests/list-pull-requests/feature.d.ts +17 -0
- package/dist/features/pull-requests/list-pull-requests/feature.js +81 -0
- package/dist/features/pull-requests/list-pull-requests/feature.js.map +1 -0
- package/dist/features/pull-requests/list-pull-requests/index.d.ts +2 -0
- package/dist/features/pull-requests/list-pull-requests/index.js +19 -0
- package/dist/features/pull-requests/list-pull-requests/index.js.map +1 -0
- package/dist/features/pull-requests/list-pull-requests/schema.d.ts +1 -0
- package/dist/features/pull-requests/list-pull-requests/schema.js +6 -0
- package/dist/features/pull-requests/list-pull-requests/schema.js.map +1 -0
- package/dist/features/pull-requests/schemas.d.ts +157 -0
- package/dist/features/pull-requests/schemas.js +337 -0
- package/dist/features/pull-requests/schemas.js.map +1 -0
- package/dist/features/pull-requests/tool-definitions.d.ts +5 -0
- package/dist/features/pull-requests/tool-definitions.js +60 -0
- package/dist/features/pull-requests/tool-definitions.js.map +1 -0
- package/dist/features/pull-requests/types.d.ts +118 -0
- package/dist/features/pull-requests/types.js +3 -0
- package/dist/features/pull-requests/types.js.map +1 -0
- package/dist/features/pull-requests/update-pull-request/feature.d.ts +9 -0
- package/dist/features/pull-requests/update-pull-request/feature.js +250 -0
- package/dist/features/pull-requests/update-pull-request/feature.js.map +1 -0
- package/dist/features/pull-requests/update-pull-request/index.d.ts +1 -0
- package/dist/features/pull-requests/update-pull-request/index.js +18 -0
- package/dist/features/pull-requests/update-pull-request/index.js.map +1 -0
- package/dist/features/pull-requests/update-pull-request-thread-status/feature.d.ts +14 -0
- package/dist/features/pull-requests/update-pull-request-thread-status/feature.js +87 -0
- package/dist/features/pull-requests/update-pull-request-thread-status/feature.js.map +1 -0
- package/dist/features/pull-requests/update-pull-request-thread-status/index.d.ts +1 -0
- package/dist/features/pull-requests/update-pull-request-thread-status/index.js +18 -0
- package/dist/features/pull-requests/update-pull-request-thread-status/index.js.map +1 -0
- package/dist/features/repositories/__test__/test-helpers.d.ts +13 -0
- package/dist/features/repositories/__test__/test-helpers.js +35 -0
- package/dist/features/repositories/__test__/test-helpers.js.map +1 -0
- package/dist/features/repositories/create-branch/feature.d.ts +6 -0
- package/dist/features/repositories/create-branch/feature.js +33 -0
- package/dist/features/repositories/create-branch/feature.js.map +1 -0
- package/dist/features/repositories/create-branch/index.d.ts +1 -0
- package/dist/features/repositories/create-branch/index.js +18 -0
- package/dist/features/repositories/create-branch/index.js.map +1 -0
- package/dist/features/repositories/create-commit/feature.d.ts +6 -0
- package/dist/features/repositories/create-commit/feature.js +122 -0
- package/dist/features/repositories/create-commit/feature.js.map +1 -0
- package/dist/features/repositories/create-commit/index.d.ts +1 -0
- package/dist/features/repositories/create-commit/index.js +18 -0
- package/dist/features/repositories/create-commit/index.js.map +1 -0
- package/dist/features/repositories/get-all-repositories-tree/feature.d.ts +22 -0
- package/dist/features/repositories/get-all-repositories-tree/feature.js +303 -0
- package/dist/features/repositories/get-all-repositories-tree/feature.js.map +1 -0
- package/dist/features/repositories/get-all-repositories-tree/index.d.ts +2 -0
- package/dist/features/repositories/get-all-repositories-tree/index.js +19 -0
- package/dist/features/repositories/get-all-repositories-tree/index.js.map +1 -0
- package/dist/features/repositories/get-all-repositories-tree/schema.d.ts +2 -0
- package/dist/features/repositories/get-all-repositories-tree/schema.js +6 -0
- package/dist/features/repositories/get-all-repositories-tree/schema.js.map +1 -0
- package/dist/features/repositories/get-file-content/feature.d.ts +23 -0
- package/dist/features/repositories/get-file-content/feature.js +96 -0
- package/dist/features/repositories/get-file-content/feature.js.map +1 -0
- package/dist/features/repositories/get-file-content/index.d.ts +2 -0
- package/dist/features/repositories/get-file-content/index.js +19 -0
- package/dist/features/repositories/get-file-content/index.js.map +1 -0
- package/dist/features/repositories/get-file-content/schema.d.ts +2 -0
- package/dist/features/repositories/get-file-content/schema.js +6 -0
- package/dist/features/repositories/get-file-content/schema.js.map +1 -0
- package/dist/features/repositories/get-repository/feature.d.ts +12 -0
- package/dist/features/repositories/get-repository/feature.js +30 -0
- package/dist/features/repositories/get-repository/feature.js.map +1 -0
- package/dist/features/repositories/get-repository/index.d.ts +2 -0
- package/dist/features/repositories/get-repository/index.js +19 -0
- package/dist/features/repositories/get-repository/index.js.map +1 -0
- package/dist/features/repositories/get-repository/schema.d.ts +2 -0
- package/dist/features/repositories/get-repository/schema.js +6 -0
- package/dist/features/repositories/get-repository/schema.js.map +1 -0
- package/dist/features/repositories/get-repository-details/feature.d.ts +11 -0
- package/dist/features/repositories/get-repository-details/feature.js +67 -0
- package/dist/features/repositories/get-repository-details/feature.js.map +1 -0
- package/dist/features/repositories/get-repository-details/index.d.ts +2 -0
- package/dist/features/repositories/get-repository-details/index.js +19 -0
- package/dist/features/repositories/get-repository-details/index.js.map +1 -0
- package/dist/features/repositories/get-repository-details/schema.d.ts +2 -0
- package/dist/features/repositories/get-repository-details/schema.js +6 -0
- package/dist/features/repositories/get-repository-details/schema.js.map +1 -0
- package/dist/features/repositories/get-repository-tree/feature.d.ts +6 -0
- package/dist/features/repositories/get-repository-tree/feature.js +65 -0
- package/dist/features/repositories/get-repository-tree/feature.js.map +1 -0
- package/dist/features/repositories/get-repository-tree/index.d.ts +1 -0
- package/dist/features/repositories/get-repository-tree/index.js +18 -0
- package/dist/features/repositories/get-repository-tree/index.js.map +1 -0
- package/dist/features/repositories/index.d.ts +23 -0
- package/dist/features/repositories/index.js +207 -0
- package/dist/features/repositories/index.js.map +1 -0
- package/dist/features/repositories/list-branches/feature.d.ts +14 -0
- package/dist/features/repositories/list-branches/feature.js +56 -0
- package/dist/features/repositories/list-branches/feature.js.map +1 -0
- package/dist/features/repositories/list-branches/index.d.ts +2 -0
- package/dist/features/repositories/list-branches/index.js +19 -0
- package/dist/features/repositories/list-branches/index.js.map +1 -0
- package/dist/features/repositories/list-branches/schema.d.ts +8 -0
- package/dist/features/repositories/list-branches/schema.js +28 -0
- package/dist/features/repositories/list-branches/schema.js.map +1 -0
- package/dist/features/repositories/list-commits/feature.d.ts +6 -0
- package/dist/features/repositories/list-commits/feature.js +75 -0
- package/dist/features/repositories/list-commits/feature.js.map +1 -0
- package/dist/features/repositories/list-commits/index.d.ts +1 -0
- package/dist/features/repositories/list-commits/index.js +18 -0
- package/dist/features/repositories/list-commits/index.js.map +1 -0
- package/dist/features/repositories/list-repositories/feature.d.ts +10 -0
- package/dist/features/repositories/list-repositories/feature.js +25 -0
- package/dist/features/repositories/list-repositories/feature.js.map +1 -0
- package/dist/features/repositories/list-repositories/index.d.ts +2 -0
- package/dist/features/repositories/list-repositories/index.js +19 -0
- package/dist/features/repositories/list-repositories/index.js.map +1 -0
- package/dist/features/repositories/list-repositories/schema.d.ts +2 -0
- package/dist/features/repositories/list-repositories/schema.js +6 -0
- package/dist/features/repositories/list-repositories/schema.js.map +1 -0
- package/dist/features/repositories/list-tags/feature.d.ts +13 -0
- package/dist/features/repositories/list-tags/feature.js +52 -0
- package/dist/features/repositories/list-tags/feature.js.map +1 -0
- package/dist/features/repositories/list-tags/index.d.ts +2 -0
- package/dist/features/repositories/list-tags/index.js +19 -0
- package/dist/features/repositories/list-tags/index.js.map +1 -0
- package/dist/features/repositories/list-tags/schema.d.ts +8 -0
- package/dist/features/repositories/list-tags/schema.js +28 -0
- package/dist/features/repositories/list-tags/schema.js.map +1 -0
- package/dist/features/repositories/schemas.d.ts +101 -0
- package/dist/features/repositories/schemas.js +306 -0
- package/dist/features/repositories/schemas.js.map +1 -0
- package/dist/features/repositories/tool-definitions.d.ts +5 -0
- package/dist/features/repositories/tool-definitions.js +106 -0
- package/dist/features/repositories/tool-definitions.js.map +1 -0
- package/dist/features/repositories/types.d.ts +167 -0
- package/dist/features/repositories/types.js +3 -0
- package/dist/features/repositories/types.js.map +1 -0
- package/dist/features/search/index.d.ts +15 -0
- package/dist/features/search/index.js +65 -0
- package/dist/features/search/index.js.map +1 -0
- package/dist/features/search/schemas.d.ts +58 -0
- package/dist/features/search/schemas.js +159 -0
- package/dist/features/search/schemas.js.map +1 -0
- package/dist/features/search/search-code/feature.d.ts +10 -0
- package/dist/features/search/search-code/feature.js +178 -0
- package/dist/features/search/search-code/feature.js.map +1 -0
- package/dist/features/search/search-code/index.d.ts +2 -0
- package/dist/features/search/search-code/index.js +19 -0
- package/dist/features/search/search-code/index.js.map +1 -0
- package/dist/features/search/search-wiki/feature.d.ts +10 -0
- package/dist/features/search/search-wiki/feature.js +133 -0
- package/dist/features/search/search-wiki/feature.js.map +1 -0
- package/dist/features/search/search-wiki/index.d.ts +1 -0
- package/dist/features/search/search-wiki/index.js +18 -0
- package/dist/features/search/search-wiki/index.js.map +1 -0
- package/dist/features/search/search-work-items/feature.d.ts +10 -0
- package/dist/features/search/search-work-items/feature.js +119 -0
- package/dist/features/search/search-work-items/feature.js.map +1 -0
- package/dist/features/search/search-work-items/index.d.ts +1 -0
- package/dist/features/search/search-work-items/index.js +18 -0
- package/dist/features/search/search-work-items/index.js.map +1 -0
- package/dist/features/search/tool-definitions.d.ts +5 -0
- package/dist/features/search/tool-definitions.js +26 -0
- package/dist/features/search/tool-definitions.js.map +1 -0
- package/dist/features/search/types.d.ts +537 -0
- package/dist/features/search/types.js +3 -0
- package/dist/features/search/types.js.map +1 -0
- package/dist/features/service-connections/feature.d.ts +21 -0
- package/dist/features/service-connections/feature.js +51 -0
- package/dist/features/service-connections/feature.js.map +1 -0
- package/dist/features/service-connections/index.d.ts +10 -0
- package/dist/features/service-connections/index.js +42 -0
- package/dist/features/service-connections/index.js.map +1 -0
- package/dist/features/service-connections/schema.d.ts +8 -0
- package/dist/features/service-connections/schema.js +28 -0
- package/dist/features/service-connections/schema.js.map +1 -0
- package/dist/features/users/get-me/feature.d.ts +12 -0
- package/dist/features/users/get-me/feature.js +96 -0
- package/dist/features/users/get-me/feature.js.map +1 -0
- package/dist/features/users/get-me/index.d.ts +2 -0
- package/dist/features/users/get-me/index.js +19 -0
- package/dist/features/users/get-me/index.js.map +1 -0
- package/dist/features/users/get-me/schema.d.ts +2 -0
- package/dist/features/users/get-me/schema.js +6 -0
- package/dist/features/users/get-me/schema.js.map +1 -0
- package/dist/features/users/index.d.ts +17 -0
- package/dist/features/users/index.js +52 -0
- package/dist/features/users/index.js.map +1 -0
- package/dist/features/users/schemas.d.ts +5 -0
- package/dist/features/users/schemas.js +9 -0
- package/dist/features/users/schemas.js.map +1 -0
- package/dist/features/users/tool-definitions.d.ts +5 -0
- package/dist/features/users/tool-definitions.js +16 -0
- package/dist/features/users/tool-definitions.js.map +1 -0
- package/dist/features/users/types.d.ts +17 -0
- package/dist/features/users/types.js +3 -0
- package/dist/features/users/types.js.map +1 -0
- package/dist/features/wikis/create-wiki/feature.d.ts +49 -0
- package/dist/features/wikis/create-wiki/feature.js +56 -0
- package/dist/features/wikis/create-wiki/feature.js.map +1 -0
- package/dist/features/wikis/create-wiki/index.d.ts +2 -0
- package/dist/features/wikis/create-wiki/index.js +9 -0
- package/dist/features/wikis/create-wiki/index.js.map +1 -0
- package/dist/features/wikis/create-wiki/schema.d.ts +25 -0
- package/dist/features/wikis/create-wiki/schema.js +60 -0
- package/dist/features/wikis/create-wiki/schema.js.map +1 -0
- package/dist/features/wikis/create-wiki-page/feature.d.ts +18 -0
- package/dist/features/wikis/create-wiki-page/feature.js +95 -0
- package/dist/features/wikis/create-wiki-page/feature.js.map +1 -0
- package/dist/features/wikis/create-wiki-page/index.d.ts +2 -0
- package/dist/features/wikis/create-wiki-page/index.js +8 -0
- package/dist/features/wikis/create-wiki-page/index.js.map +1 -0
- package/dist/features/wikis/create-wiki-page/schema.d.ts +12 -0
- package/dist/features/wikis/create-wiki-page/schema.js +36 -0
- package/dist/features/wikis/create-wiki-page/schema.js.map +1 -0
- package/dist/features/wikis/get-wiki-page/feature.d.ts +33 -0
- package/dist/features/wikis/get-wiki-page/feature.js +68 -0
- package/dist/features/wikis/get-wiki-page/feature.js.map +1 -0
- package/dist/features/wikis/get-wiki-page/index.d.ts +2 -0
- package/dist/features/wikis/get-wiki-page/index.js +8 -0
- package/dist/features/wikis/get-wiki-page/index.js.map +1 -0
- package/dist/features/wikis/get-wiki-page/schema.d.ts +10 -0
- package/dist/features/wikis/get-wiki-page/schema.js +23 -0
- package/dist/features/wikis/get-wiki-page/schema.js.map +1 -0
- package/dist/features/wikis/get-wikis/feature.d.ts +25 -0
- package/dist/features/wikis/get-wikis/feature.js +37 -0
- package/dist/features/wikis/get-wikis/feature.js.map +1 -0
- package/dist/features/wikis/get-wikis/index.d.ts +2 -0
- package/dist/features/wikis/get-wikis/index.js +8 -0
- package/dist/features/wikis/get-wikis/index.js.map +1 -0
- package/dist/features/wikis/get-wikis/schema.d.ts +8 -0
- package/dist/features/wikis/get-wikis/schema.js +21 -0
- package/dist/features/wikis/get-wikis/schema.js.map +1 -0
- package/dist/features/wikis/index.d.ts +16 -0
- package/dist/features/wikis/index.js +141 -0
- package/dist/features/wikis/index.js.map +1 -0
- package/dist/features/wikis/list-wiki-pages/feature.d.ts +20 -0
- package/dist/features/wikis/list-wiki-pages/feature.js +79 -0
- package/dist/features/wikis/list-wiki-pages/feature.js.map +1 -0
- package/dist/features/wikis/list-wiki-pages/index.d.ts +2 -0
- package/dist/features/wikis/list-wiki-pages/index.js +8 -0
- package/dist/features/wikis/list-wiki-pages/index.js.map +1 -0
- package/dist/features/wikis/list-wiki-pages/schema.d.ts +10 -0
- package/dist/features/wikis/list-wiki-pages/schema.js +22 -0
- package/dist/features/wikis/list-wiki-pages/schema.js.map +1 -0
- package/dist/features/wikis/tool-definitions.d.ts +5 -0
- package/dist/features/wikis/tool-definitions.js +46 -0
- package/dist/features/wikis/tool-definitions.js.map +1 -0
- package/dist/features/wikis/update-wiki-page/feature.d.ts +12 -0
- package/dist/features/wikis/update-wiki-page/feature.js +63 -0
- package/dist/features/wikis/update-wiki-page/feature.js.map +1 -0
- package/dist/features/wikis/update-wiki-page/index.d.ts +2 -0
- package/dist/features/wikis/update-wiki-page/index.js +8 -0
- package/dist/features/wikis/update-wiki-page/index.js.map +1 -0
- package/dist/features/wikis/update-wiki-page/schema.d.ts +12 -0
- package/dist/features/wikis/update-wiki-page/schema.js +32 -0
- package/dist/features/wikis/update-wiki-page/schema.js.map +1 -0
- package/dist/features/work-items/__test__/fixtures.d.ts +9 -0
- package/dist/features/work-items/__test__/fixtures.js +28 -0
- package/dist/features/work-items/__test__/fixtures.js.map +1 -0
- package/dist/features/work-items/__test__/test-helpers.d.ts +13 -0
- package/dist/features/work-items/__test__/test-helpers.js +35 -0
- package/dist/features/work-items/__test__/test-helpers.js.map +1 -0
- package/dist/features/work-items/__test__/test-utils.d.ts +17 -0
- package/dist/features/work-items/__test__/test-utils.js +39 -0
- package/dist/features/work-items/__test__/test-utils.js.map +1 -0
- package/dist/features/work-items/attachment-schemas.d.ts +24 -0
- package/dist/features/work-items/attachment-schemas.js +46 -0
- package/dist/features/work-items/attachment-schemas.js.map +1 -0
- package/dist/features/work-items/create-work-item/feature.d.ts +12 -0
- package/dist/features/work-items/create-work-item/feature.js +107 -0
- package/dist/features/work-items/create-work-item/feature.js.map +1 -0
- package/dist/features/work-items/create-work-item/index.d.ts +2 -0
- package/dist/features/work-items/create-work-item/index.js +19 -0
- package/dist/features/work-items/create-work-item/index.js.map +1 -0
- package/dist/features/work-items/create-work-item/schema.d.ts +2 -0
- package/dist/features/work-items/create-work-item/schema.js +6 -0
- package/dist/features/work-items/create-work-item/schema.js.map +1 -0
- package/dist/features/work-items/create-work-item-attachment/feature.d.ts +11 -0
- package/dist/features/work-items/create-work-item-attachment/feature.js +107 -0
- package/dist/features/work-items/create-work-item-attachment/feature.js.map +1 -0
- package/dist/features/work-items/create-work-item-attachment/index.d.ts +2 -0
- package/dist/features/work-items/create-work-item-attachment/index.js +19 -0
- package/dist/features/work-items/create-work-item-attachment/index.js.map +1 -0
- package/dist/features/work-items/create-work-item-attachment/schema.d.ts +2 -0
- package/dist/features/work-items/create-work-item-attachment/schema.js +6 -0
- package/dist/features/work-items/create-work-item-attachment/schema.js.map +1 -0
- package/dist/features/work-items/delete-work-item-attachment/feature.d.ts +10 -0
- package/dist/features/work-items/delete-work-item-attachment/feature.js +51 -0
- package/dist/features/work-items/delete-work-item-attachment/feature.js.map +1 -0
- package/dist/features/work-items/delete-work-item-attachment/index.d.ts +2 -0
- package/dist/features/work-items/delete-work-item-attachment/index.js +19 -0
- package/dist/features/work-items/delete-work-item-attachment/index.js.map +1 -0
- package/dist/features/work-items/delete-work-item-attachment/schema.d.ts +2 -0
- package/dist/features/work-items/delete-work-item-attachment/schema.js +6 -0
- package/dist/features/work-items/delete-work-item-attachment/schema.js.map +1 -0
- package/dist/features/work-items/get-work-item/feature.d.ts +12 -0
- package/dist/features/work-items/get-work-item/feature.js +69 -0
- package/dist/features/work-items/get-work-item/feature.js.map +1 -0
- package/dist/features/work-items/get-work-item/index.d.ts +2 -0
- package/dist/features/work-items/get-work-item/index.js +19 -0
- package/dist/features/work-items/get-work-item/index.js.map +1 -0
- package/dist/features/work-items/get-work-item/schema.d.ts +2 -0
- package/dist/features/work-items/get-work-item/schema.js +6 -0
- package/dist/features/work-items/get-work-item/schema.js.map +1 -0
- package/dist/features/work-items/get-work-item-attachment/feature.d.ts +10 -0
- package/dist/features/work-items/get-work-item-attachment/feature.js +108 -0
- package/dist/features/work-items/get-work-item-attachment/feature.js.map +1 -0
- package/dist/features/work-items/get-work-item-attachment/index.d.ts +2 -0
- package/dist/features/work-items/get-work-item-attachment/index.js +19 -0
- package/dist/features/work-items/get-work-item-attachment/index.js.map +1 -0
- package/dist/features/work-items/get-work-item-attachment/schema.d.ts +2 -0
- package/dist/features/work-items/get-work-item-attachment/schema.js +6 -0
- package/dist/features/work-items/get-work-item-attachment/schema.js.map +1 -0
- package/dist/features/work-items/get-work-item-comments/feature.d.ts +10 -0
- package/dist/features/work-items/get-work-item-comments/feature.js +78 -0
- package/dist/features/work-items/get-work-item-comments/feature.js.map +1 -0
- package/dist/features/work-items/get-work-item-comments/index.d.ts +2 -0
- package/dist/features/work-items/get-work-item-comments/index.js +19 -0
- package/dist/features/work-items/get-work-item-comments/index.js.map +1 -0
- package/dist/features/work-items/get-work-item-comments/schema.d.ts +2 -0
- package/dist/features/work-items/get-work-item-comments/schema.js +6 -0
- package/dist/features/work-items/get-work-item-comments/schema.js.map +1 -0
- package/dist/features/work-items/index.d.ts +21 -0
- package/dist/features/work-items/index.js +181 -0
- package/dist/features/work-items/index.js.map +1 -0
- package/dist/features/work-items/list-work-items/feature.d.ts +10 -0
- package/dist/features/work-items/list-work-items/feature.js +92 -0
- package/dist/features/work-items/list-work-items/feature.js.map +1 -0
- package/dist/features/work-items/list-work-items/index.d.ts +2 -0
- package/dist/features/work-items/list-work-items/index.js +19 -0
- package/dist/features/work-items/list-work-items/index.js.map +1 -0
- package/dist/features/work-items/list-work-items/schema.d.ts +2 -0
- package/dist/features/work-items/list-work-items/schema.js +6 -0
- package/dist/features/work-items/list-work-items/schema.js.map +1 -0
- package/dist/features/work-items/manage-work-item-link/feature.d.ts +24 -0
- package/dist/features/work-items/manage-work-item-link/feature.js +91 -0
- package/dist/features/work-items/manage-work-item-link/feature.js.map +1 -0
- package/dist/features/work-items/manage-work-item-link/index.d.ts +2 -0
- package/dist/features/work-items/manage-work-item-link/index.js +8 -0
- package/dist/features/work-items/manage-work-item-link/index.js.map +1 -0
- package/dist/features/work-items/manage-work-item-link/schema.d.ts +2 -0
- package/dist/features/work-items/manage-work-item-link/schema.js +6 -0
- package/dist/features/work-items/manage-work-item-link/schema.js.map +1 -0
- package/dist/features/work-items/schemas.d.ts +99 -0
- package/dist/features/work-items/schemas.js +181 -0
- package/dist/features/work-items/schemas.js.map +1 -0
- package/dist/features/work-items/tool-definitions.d.ts +5 -0
- package/dist/features/work-items/tool-definitions.js +56 -0
- package/dist/features/work-items/tool-definitions.js.map +1 -0
- package/dist/features/work-items/types.d.ts +87 -0
- package/dist/features/work-items/types.js +3 -0
- package/dist/features/work-items/types.js.map +1 -0
- package/dist/features/work-items/update-work-item/feature.d.ts +12 -0
- package/dist/features/work-items/update-work-item/feature.js +155 -0
- package/dist/features/work-items/update-work-item/feature.js.map +1 -0
- package/dist/features/work-items/update-work-item/index.d.ts +2 -0
- package/dist/features/work-items/update-work-item/index.js +19 -0
- package/dist/features/work-items/update-work-item/index.js.map +1 -0
- package/dist/features/work-items/update-work-item/schema.d.ts +2 -0
- package/dist/features/work-items/update-work-item/schema.js +6 -0
- package/dist/features/work-items/update-work-item/schema.js.map +1 -0
- package/dist/http-server.d.ts +22 -0
- package/dist/http-server.js +137 -0
- package/dist/http-server.js.map +1 -0
- package/dist/index.d.ts +14 -0
- package/dist/index.js +138 -0
- package/dist/index.js.map +1 -0
- package/dist/server.d.ts +21 -0
- package/dist/server.js +379 -0
- package/dist/server.js.map +1 -0
- package/dist/shared/api/client.d.ts +91 -0
- package/dist/shared/api/client.js +242 -0
- package/dist/shared/api/client.js.map +1 -0
- package/dist/shared/api/index.d.ts +1 -0
- package/dist/shared/api/index.js +18 -0
- package/dist/shared/api/index.js.map +1 -0
- package/dist/shared/auth/auth-factory.d.ts +53 -0
- package/dist/shared/auth/auth-factory.js +194 -0
- package/dist/shared/auth/auth-factory.js.map +1 -0
- package/dist/shared/auth/client-factory.d.ts +109 -0
- package/dist/shared/auth/client-factory.js +272 -0
- package/dist/shared/auth/client-factory.js.map +1 -0
- package/dist/shared/auth/index.d.ts +11 -0
- package/dist/shared/auth/index.js +18 -0
- package/dist/shared/auth/index.js.map +1 -0
- package/dist/shared/azure-devops-url.d.ts +17 -0
- package/dist/shared/azure-devops-url.js +120 -0
- package/dist/shared/azure-devops-url.js.map +1 -0
- package/dist/shared/config/index.d.ts +1 -0
- package/dist/shared/config/index.js +18 -0
- package/dist/shared/config/index.js.map +1 -0
- package/dist/shared/config/version.d.ts +4 -0
- package/dist/shared/config/version.js +8 -0
- package/dist/shared/config/version.js.map +1 -0
- package/dist/shared/enums/index.d.ts +40 -0
- package/dist/shared/enums/index.js +87 -0
- package/dist/shared/enums/index.js.map +1 -0
- package/dist/shared/errors/azure-devops-errors.d.ts +107 -0
- package/dist/shared/errors/azure-devops-errors.js +161 -0
- package/dist/shared/errors/azure-devops-errors.js.map +1 -0
- package/dist/shared/errors/handle-request-error.d.ts +32 -0
- package/dist/shared/errors/handle-request-error.js +121 -0
- package/dist/shared/errors/handle-request-error.js.map +1 -0
- package/dist/shared/errors/index.d.ts +1 -0
- package/dist/shared/errors/index.js +18 -0
- package/dist/shared/errors/index.js.map +1 -0
- package/dist/shared/test/test-helpers.d.ts +20 -0
- package/dist/shared/test/test-helpers.js +57 -0
- package/dist/shared/test/test-helpers.js.map +1 -0
- package/dist/shared/test/text-content.d.ts +10 -0
- package/dist/shared/test/text-content.js +20 -0
- package/dist/shared/test/text-content.js.map +1 -0
- package/dist/shared/types/config.d.ts +27 -0
- package/dist/shared/types/config.js +3 -0
- package/dist/shared/types/config.js.map +1 -0
- package/dist/shared/types/index.d.ts +1 -0
- package/dist/shared/types/index.js +18 -0
- package/dist/shared/types/index.js.map +1 -0
- package/dist/shared/types/request-handler.d.ts +21 -0
- package/dist/shared/types/request-handler.js +3 -0
- package/dist/shared/types/request-handler.js.map +1 -0
- package/dist/shared/types/tool-definition.d.ts +9 -0
- package/dist/shared/types/tool-definition.js +3 -0
- package/dist/shared/types/tool-definition.js.map +1 -0
- package/dist/shared/utils/to-json-schema.d.ts +6 -0
- package/dist/shared/utils/to-json-schema.js +12 -0
- package/dist/shared/utils/to-json-schema.js.map +1 -0
- package/dist/utils/environment.d.ts +21 -0
- package/dist/utils/environment.js +58 -0
- package/dist/utils/environment.js.map +1 -0
- package/docs/SOLUTION_SUMMARY.md +145 -0
- package/docs/authentication.md +293 -0
- package/docs/azure-identity-authentication.md +187 -0
- package/docs/ci-setup.md +61 -0
- package/docs/docker.md +135 -0
- package/docs/examples/README.md +33 -0
- package/docs/examples/azure-cli-authentication.env +25 -0
- package/docs/examples/azure-identity-authentication.env +33 -0
- package/docs/examples/pat-authentication.env +24 -0
- package/docs/important-knowledge/azure-devops-rest-api-research.md +88 -0
- package/docs/important-knowledge/llm-tldr-cli.md +37 -0
- package/docs/npm-trusted-publishers-migration.md +142 -0
- package/docs/release-troubleshooting.md +153 -0
- package/docs/testing/README.md +140 -0
- package/docs/testing/setup.md +72 -0
- package/docs/tools/README.md +76 -0
- package/docs/tools/core-navigation.md +114 -0
- package/docs/tools/organizations.md +73 -0
- package/docs/tools/pipelines.md +532 -0
- package/docs/tools/projects.md +114 -0
- package/docs/tools/pull-requests.md +1110 -0
- package/docs/tools/repositories.md +610 -0
- package/docs/tools/resources.md +133 -0
- package/docs/tools/search.md +165 -0
- package/docs/tools/user-tools.md +39 -0
- package/docs/tools/wiki.md +192 -0
- package/docs/tools/work-items.md +244 -0
- package/package.json +125 -4
|
@@ -0,0 +1,167 @@
|
|
|
1
|
+
import { GitRepository, GitBranchStats, GitRef, GitItem } from 'azure-devops-node-api/interfaces/GitInterfaces';
|
|
2
|
+
/**
|
|
3
|
+
* Options for listing repositories
|
|
4
|
+
*/
|
|
5
|
+
export interface ListRepositoriesOptions {
|
|
6
|
+
projectId: string;
|
|
7
|
+
includeLinks?: boolean;
|
|
8
|
+
}
|
|
9
|
+
/**
|
|
10
|
+
* Options for getting repository details
|
|
11
|
+
*/
|
|
12
|
+
export interface GetRepositoryDetailsOptions {
|
|
13
|
+
projectId: string;
|
|
14
|
+
repositoryId: string;
|
|
15
|
+
includeStatistics?: boolean;
|
|
16
|
+
includeRefs?: boolean;
|
|
17
|
+
refFilter?: string;
|
|
18
|
+
branchName?: string;
|
|
19
|
+
}
|
|
20
|
+
/**
|
|
21
|
+
* Repository details response
|
|
22
|
+
*/
|
|
23
|
+
export interface RepositoryDetails {
|
|
24
|
+
repository: GitRepository;
|
|
25
|
+
statistics?: {
|
|
26
|
+
branches: GitBranchStats[];
|
|
27
|
+
};
|
|
28
|
+
refs?: {
|
|
29
|
+
value: GitRef[];
|
|
30
|
+
count: number;
|
|
31
|
+
};
|
|
32
|
+
}
|
|
33
|
+
/**
|
|
34
|
+
* Options for getting all repositories tree
|
|
35
|
+
*/
|
|
36
|
+
export interface GetAllRepositoriesTreeOptions {
|
|
37
|
+
organizationId: string;
|
|
38
|
+
projectId: string;
|
|
39
|
+
repositoryPattern?: string;
|
|
40
|
+
depth?: number;
|
|
41
|
+
pattern?: string;
|
|
42
|
+
}
|
|
43
|
+
/**
|
|
44
|
+
* Options for getting a repository tree starting at a specific path
|
|
45
|
+
*/
|
|
46
|
+
export interface GetRepositoryTreeOptions {
|
|
47
|
+
projectId: string;
|
|
48
|
+
repositoryId: string;
|
|
49
|
+
/**
|
|
50
|
+
* Path within the repository to start from. Defaults to '/'
|
|
51
|
+
*/
|
|
52
|
+
path?: string;
|
|
53
|
+
/**
|
|
54
|
+
* Maximum depth to traverse (0 = unlimited)
|
|
55
|
+
*/
|
|
56
|
+
depth?: number;
|
|
57
|
+
}
|
|
58
|
+
/**
|
|
59
|
+
* Options for creating a new branch from an existing one
|
|
60
|
+
*/
|
|
61
|
+
export interface CreateBranchOptions {
|
|
62
|
+
projectId: string;
|
|
63
|
+
repositoryId: string;
|
|
64
|
+
/** Source branch name to copy from */
|
|
65
|
+
sourceBranch: string;
|
|
66
|
+
/** Name of the new branch to create */
|
|
67
|
+
newBranch: string;
|
|
68
|
+
}
|
|
69
|
+
/**
|
|
70
|
+
* Description of a single file change for commit creation
|
|
71
|
+
*/
|
|
72
|
+
export interface FileChange {
|
|
73
|
+
/**
|
|
74
|
+
* Optional path hint for the change. If omitted, the path from the diff
|
|
75
|
+
* header will be used.
|
|
76
|
+
*/
|
|
77
|
+
path?: string;
|
|
78
|
+
/** Unified diff patch representing the change */
|
|
79
|
+
patch?: string;
|
|
80
|
+
/**
|
|
81
|
+
* Alternative to patch: exact string to search for in the file.
|
|
82
|
+
* Must be used together with 'replace'. The server will generate the diff.
|
|
83
|
+
*/
|
|
84
|
+
search?: string;
|
|
85
|
+
/**
|
|
86
|
+
* Alternative to patch: exact string to replace 'search' with.
|
|
87
|
+
* Must be used together with 'search'. The server will generate the diff.
|
|
88
|
+
*/
|
|
89
|
+
replace?: string;
|
|
90
|
+
}
|
|
91
|
+
/**
|
|
92
|
+
* Options for creating a commit with multiple file changes
|
|
93
|
+
*/
|
|
94
|
+
export interface CreateCommitOptions {
|
|
95
|
+
projectId: string;
|
|
96
|
+
repositoryId: string;
|
|
97
|
+
branchName: string;
|
|
98
|
+
commitMessage: string;
|
|
99
|
+
changes: FileChange[];
|
|
100
|
+
}
|
|
101
|
+
/**
|
|
102
|
+
* Options for listing commits within a repository branch
|
|
103
|
+
*/
|
|
104
|
+
export interface ListCommitsOptions {
|
|
105
|
+
projectId: string;
|
|
106
|
+
repositoryId: string;
|
|
107
|
+
branchName: string;
|
|
108
|
+
top?: number;
|
|
109
|
+
skip?: number;
|
|
110
|
+
}
|
|
111
|
+
/**
|
|
112
|
+
* Representation of a commit along with the file diffs it touches
|
|
113
|
+
*/
|
|
114
|
+
export interface CommitWithContent {
|
|
115
|
+
commitId: string;
|
|
116
|
+
comment?: string;
|
|
117
|
+
author?: {
|
|
118
|
+
name?: string;
|
|
119
|
+
email?: string;
|
|
120
|
+
date?: Date;
|
|
121
|
+
};
|
|
122
|
+
committer?: {
|
|
123
|
+
name?: string;
|
|
124
|
+
email?: string;
|
|
125
|
+
date?: Date;
|
|
126
|
+
};
|
|
127
|
+
url?: string;
|
|
128
|
+
parents?: string[];
|
|
129
|
+
files: Array<{
|
|
130
|
+
path: string;
|
|
131
|
+
patch: string;
|
|
132
|
+
}>;
|
|
133
|
+
}
|
|
134
|
+
/**
|
|
135
|
+
* Response for listing commits with their associated content
|
|
136
|
+
*/
|
|
137
|
+
export interface ListCommitsResponse {
|
|
138
|
+
commits: CommitWithContent[];
|
|
139
|
+
}
|
|
140
|
+
/**
|
|
141
|
+
* Repository tree item representation for output
|
|
142
|
+
*/
|
|
143
|
+
export interface RepositoryTreeItem {
|
|
144
|
+
name: string;
|
|
145
|
+
path: string;
|
|
146
|
+
isFolder: boolean;
|
|
147
|
+
level: number;
|
|
148
|
+
}
|
|
149
|
+
/**
|
|
150
|
+
* Repository tree response for a single repository
|
|
151
|
+
*/
|
|
152
|
+
export interface RepositoryTreeResponse {
|
|
153
|
+
name: string;
|
|
154
|
+
tree: RepositoryTreeItem[];
|
|
155
|
+
stats: {
|
|
156
|
+
directories: number;
|
|
157
|
+
files: number;
|
|
158
|
+
};
|
|
159
|
+
error?: string;
|
|
160
|
+
}
|
|
161
|
+
/**
|
|
162
|
+
* Complete all repositories tree response
|
|
163
|
+
*/
|
|
164
|
+
export interface AllRepositoriesTreeResponse {
|
|
165
|
+
repositories: RepositoryTreeResponse[];
|
|
166
|
+
}
|
|
167
|
+
export type { GitRepository, GitBranchStats, GitRef, GitItem };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../src/features/repositories/types.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export * from './schemas';
|
|
2
|
+
export * from './types';
|
|
3
|
+
export * from './search-code';
|
|
4
|
+
export * from './search-wiki';
|
|
5
|
+
export * from './search-work-items';
|
|
6
|
+
export * from './tool-definitions';
|
|
7
|
+
import { RequestIdentifier, RequestHandler } from '../../shared/types/request-handler';
|
|
8
|
+
/**
|
|
9
|
+
* Checks if the request is for the search feature
|
|
10
|
+
*/
|
|
11
|
+
export declare const isSearchRequest: RequestIdentifier;
|
|
12
|
+
/**
|
|
13
|
+
* Handles search feature requests
|
|
14
|
+
*/
|
|
15
|
+
export declare const handleSearchRequest: RequestHandler;
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
exports.handleSearchRequest = exports.isSearchRequest = void 0;
|
|
18
|
+
__exportStar(require("./schemas"), exports);
|
|
19
|
+
__exportStar(require("./types"), exports);
|
|
20
|
+
__exportStar(require("./search-code"), exports);
|
|
21
|
+
__exportStar(require("./search-wiki"), exports);
|
|
22
|
+
__exportStar(require("./search-work-items"), exports);
|
|
23
|
+
// Export tool definitions
|
|
24
|
+
__exportStar(require("./tool-definitions"), exports);
|
|
25
|
+
const _1 = require("./");
|
|
26
|
+
/**
|
|
27
|
+
* Checks if the request is for the search feature
|
|
28
|
+
*/
|
|
29
|
+
const isSearchRequest = (request) => {
|
|
30
|
+
const toolName = request.params.name;
|
|
31
|
+
return ['search_code', 'search_wiki', 'search_work_items'].includes(toolName);
|
|
32
|
+
};
|
|
33
|
+
exports.isSearchRequest = isSearchRequest;
|
|
34
|
+
/**
|
|
35
|
+
* Handles search feature requests
|
|
36
|
+
*/
|
|
37
|
+
const handleSearchRequest = async (connection, request) => {
|
|
38
|
+
switch (request.params.name) {
|
|
39
|
+
case 'search_code': {
|
|
40
|
+
const args = _1.SearchCodeSchema.parse(request.params.arguments);
|
|
41
|
+
const result = await (0, _1.searchCode)(connection, args);
|
|
42
|
+
return {
|
|
43
|
+
content: [{ type: 'text', text: JSON.stringify(result, null, 2) }],
|
|
44
|
+
};
|
|
45
|
+
}
|
|
46
|
+
case 'search_wiki': {
|
|
47
|
+
const args = _1.SearchWikiSchema.parse(request.params.arguments);
|
|
48
|
+
const result = await (0, _1.searchWiki)(connection, args);
|
|
49
|
+
return {
|
|
50
|
+
content: [{ type: 'text', text: JSON.stringify(result, null, 2) }],
|
|
51
|
+
};
|
|
52
|
+
}
|
|
53
|
+
case 'search_work_items': {
|
|
54
|
+
const args = _1.SearchWorkItemsSchema.parse(request.params.arguments);
|
|
55
|
+
const result = await (0, _1.searchWorkItems)(connection, args);
|
|
56
|
+
return {
|
|
57
|
+
content: [{ type: 'text', text: JSON.stringify(result, null, 2) }],
|
|
58
|
+
};
|
|
59
|
+
}
|
|
60
|
+
default:
|
|
61
|
+
throw new Error(`Unknown search tool: ${request.params.name}`);
|
|
62
|
+
}
|
|
63
|
+
};
|
|
64
|
+
exports.handleSearchRequest = handleSearchRequest;
|
|
65
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/features/search/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;AAAA,4CAA0B;AAC1B,0CAAwB;AACxB,gDAA8B;AAC9B,gDAA8B;AAC9B,sDAAoC;AAEpC,0B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YACzB,MAAM,IAAI,GAAG,wBAAqB,CAAC,KAAK,CAAC,OAAO,CAAC,MAAM,CAAC,SAAS,CAAC,CAAC;YACnE,MAAM,MAAM,GAAG,MAAM,IAAA,kBAAe,EAAC,UAAU,EAAE,IAAI,CAAC,CAAC;YACvD,OAAO;gBACL,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC,MAAM,EAAE,IAAI,EAAE,CAAC,CAAC,EAAE,CAAC;aACnE,CAAC;QACJ,CAAC;QACD;YACE,MAAM,IAAI,KAAK,CAAC,wBAAwB,OAAO,CAAC,MAAM,CAAC,IAAI,EAAE,CAAC,CAAC;IACnE,CAAC;AACH,CAAC,CAAC;AA7BW,QAAA,mBAAmB,GAAnB,mBAAmB,CA6B9B"}
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
/**
|
|
3
|
+
* Schema for searching code in Azure DevOps repositories
|
|
4
|
+
*/
|
|
5
|
+
export declare const SearchCodeSchema: z.ZodObject<{
|
|
6
|
+
searchText: z.ZodString;
|
|
7
|
+
organizationId: z.ZodOptional<z.ZodString>;
|
|
8
|
+
projectId: z.ZodOptional<z.ZodString>;
|
|
9
|
+
filters: z.ZodOptional<z.ZodObject<{
|
|
10
|
+
Repository: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
11
|
+
Path: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
12
|
+
Branch: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
13
|
+
CodeElement: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
14
|
+
}, z.core.$strip>>;
|
|
15
|
+
top: z.ZodDefault<z.ZodNumber>;
|
|
16
|
+
skip: z.ZodDefault<z.ZodNumber>;
|
|
17
|
+
includeSnippet: z.ZodDefault<z.ZodBoolean>;
|
|
18
|
+
includeContent: z.ZodDefault<z.ZodBoolean>;
|
|
19
|
+
}, z.core.$strip>;
|
|
20
|
+
/**
|
|
21
|
+
* Schema for searching wiki pages in Azure DevOps projects
|
|
22
|
+
*/
|
|
23
|
+
export declare const SearchWikiSchema: z.ZodObject<{
|
|
24
|
+
searchText: z.ZodString;
|
|
25
|
+
organizationId: z.ZodOptional<z.ZodString>;
|
|
26
|
+
projectId: z.ZodOptional<z.ZodString>;
|
|
27
|
+
filters: z.ZodOptional<z.ZodObject<{
|
|
28
|
+
Project: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
29
|
+
}, z.core.$strip>>;
|
|
30
|
+
top: z.ZodDefault<z.ZodNumber>;
|
|
31
|
+
skip: z.ZodDefault<z.ZodNumber>;
|
|
32
|
+
includeFacets: z.ZodDefault<z.ZodBoolean>;
|
|
33
|
+
}, z.core.$strip>;
|
|
34
|
+
/**
|
|
35
|
+
* Schema for searching work items in Azure DevOps projects
|
|
36
|
+
*/
|
|
37
|
+
export declare const SearchWorkItemsSchema: z.ZodObject<{
|
|
38
|
+
searchText: z.ZodString;
|
|
39
|
+
organizationId: z.ZodOptional<z.ZodString>;
|
|
40
|
+
projectId: z.ZodOptional<z.ZodString>;
|
|
41
|
+
filters: z.ZodOptional<z.ZodObject<{
|
|
42
|
+
'System.TeamProject': z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
43
|
+
'System.WorkItemType': z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
44
|
+
'System.State': z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
45
|
+
'System.AssignedTo': z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
46
|
+
'System.AreaPath': z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
47
|
+
}, z.core.$strip>>;
|
|
48
|
+
top: z.ZodDefault<z.ZodNumber>;
|
|
49
|
+
skip: z.ZodDefault<z.ZodNumber>;
|
|
50
|
+
includeFacets: z.ZodDefault<z.ZodBoolean>;
|
|
51
|
+
orderBy: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
52
|
+
field: z.ZodString;
|
|
53
|
+
sortOrder: z.ZodEnum<{
|
|
54
|
+
ASC: "ASC";
|
|
55
|
+
DESC: "DESC";
|
|
56
|
+
}>;
|
|
57
|
+
}, z.core.$strip>>>;
|
|
58
|
+
}, z.core.$strip>;
|
|
@@ -0,0 +1,159 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.SearchWorkItemsSchema = exports.SearchWikiSchema = exports.SearchCodeSchema = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
const environment_1 = require("../../utils/environment");
|
|
6
|
+
/**
|
|
7
|
+
* Schema for searching code in Azure DevOps repositories
|
|
8
|
+
*/
|
|
9
|
+
exports.SearchCodeSchema = zod_1.z.object({
|
|
10
|
+
searchText: zod_1.z.string().describe('The text to search for'),
|
|
11
|
+
organizationId: zod_1.z
|
|
12
|
+
.string()
|
|
13
|
+
.optional()
|
|
14
|
+
.describe(`The ID or name of the organization (Default: ${environment_1.defaultOrg})`),
|
|
15
|
+
projectId: zod_1.z
|
|
16
|
+
.string()
|
|
17
|
+
.optional()
|
|
18
|
+
.describe(`The ID or name of the project to search in (Default: ${environment_1.defaultProject}). If not provided, the default project will be used.`),
|
|
19
|
+
filters: zod_1.z
|
|
20
|
+
.object({
|
|
21
|
+
Repository: zod_1.z
|
|
22
|
+
.array(zod_1.z.string())
|
|
23
|
+
.optional()
|
|
24
|
+
.describe('Filter by repository names'),
|
|
25
|
+
Path: zod_1.z.array(zod_1.z.string()).optional().describe('Filter by file paths'),
|
|
26
|
+
Branch: zod_1.z.array(zod_1.z.string()).optional().describe('Filter by branch names'),
|
|
27
|
+
CodeElement: zod_1.z
|
|
28
|
+
.array(zod_1.z.string())
|
|
29
|
+
.optional()
|
|
30
|
+
.describe('Filter by code element types (function, class, etc.)'),
|
|
31
|
+
})
|
|
32
|
+
.optional()
|
|
33
|
+
.describe('Optional filters to narrow search results'),
|
|
34
|
+
top: zod_1.z
|
|
35
|
+
.number()
|
|
36
|
+
.int()
|
|
37
|
+
.min(1)
|
|
38
|
+
.max(1000)
|
|
39
|
+
.default(100)
|
|
40
|
+
.describe('Number of results to return (default: 100, max: 1000)'),
|
|
41
|
+
skip: zod_1.z
|
|
42
|
+
.number()
|
|
43
|
+
.int()
|
|
44
|
+
.min(0)
|
|
45
|
+
.default(0)
|
|
46
|
+
.describe('Number of results to skip for pagination (default: 0)'),
|
|
47
|
+
includeSnippet: zod_1.z
|
|
48
|
+
.boolean()
|
|
49
|
+
.default(true)
|
|
50
|
+
.describe('Whether to include code snippets in results (default: true)'),
|
|
51
|
+
includeContent: zod_1.z
|
|
52
|
+
.boolean()
|
|
53
|
+
.default(true)
|
|
54
|
+
.describe('Whether to include full file content in results (default: true)'),
|
|
55
|
+
});
|
|
56
|
+
/**
|
|
57
|
+
* Schema for searching wiki pages in Azure DevOps projects
|
|
58
|
+
*/
|
|
59
|
+
exports.SearchWikiSchema = zod_1.z.object({
|
|
60
|
+
searchText: zod_1.z.string().describe('The text to search for in wikis'),
|
|
61
|
+
organizationId: zod_1.z
|
|
62
|
+
.string()
|
|
63
|
+
.optional()
|
|
64
|
+
.describe(`The ID or name of the organization (Default: ${environment_1.defaultOrg})`),
|
|
65
|
+
projectId: zod_1.z
|
|
66
|
+
.string()
|
|
67
|
+
.optional()
|
|
68
|
+
.describe('The ID or name of the project to search in. If omitted, the search runs across the organization when supported.'),
|
|
69
|
+
filters: zod_1.z
|
|
70
|
+
.object({
|
|
71
|
+
Project: zod_1.z
|
|
72
|
+
.array(zod_1.z.string())
|
|
73
|
+
.optional()
|
|
74
|
+
.describe('Filter by project names'),
|
|
75
|
+
})
|
|
76
|
+
.optional()
|
|
77
|
+
.describe('Optional filters to narrow search results'),
|
|
78
|
+
top: zod_1.z
|
|
79
|
+
.number()
|
|
80
|
+
.int()
|
|
81
|
+
.min(1)
|
|
82
|
+
.max(1000)
|
|
83
|
+
.default(100)
|
|
84
|
+
.describe('Number of results to return (default: 100, max: 1000)'),
|
|
85
|
+
skip: zod_1.z
|
|
86
|
+
.number()
|
|
87
|
+
.int()
|
|
88
|
+
.min(0)
|
|
89
|
+
.default(0)
|
|
90
|
+
.describe('Number of results to skip for pagination (default: 0)'),
|
|
91
|
+
includeFacets: zod_1.z
|
|
92
|
+
.boolean()
|
|
93
|
+
.default(true)
|
|
94
|
+
.describe('Whether to include faceting in results (default: true)'),
|
|
95
|
+
});
|
|
96
|
+
/**
|
|
97
|
+
* Schema for searching work items in Azure DevOps projects
|
|
98
|
+
*/
|
|
99
|
+
exports.SearchWorkItemsSchema = zod_1.z.object({
|
|
100
|
+
searchText: zod_1.z.string().describe('The text to search for in work items'),
|
|
101
|
+
organizationId: zod_1.z
|
|
102
|
+
.string()
|
|
103
|
+
.optional()
|
|
104
|
+
.describe(`The ID or name of the organization (Default: ${environment_1.defaultOrg})`),
|
|
105
|
+
projectId: zod_1.z
|
|
106
|
+
.string()
|
|
107
|
+
.optional()
|
|
108
|
+
.describe('The ID or name of the project to search in. If omitted, the search runs across the organization when supported.'),
|
|
109
|
+
filters: zod_1.z
|
|
110
|
+
.object({
|
|
111
|
+
'System.TeamProject': zod_1.z
|
|
112
|
+
.array(zod_1.z.string())
|
|
113
|
+
.optional()
|
|
114
|
+
.describe('Filter by project names'),
|
|
115
|
+
'System.WorkItemType': zod_1.z
|
|
116
|
+
.array(zod_1.z.string())
|
|
117
|
+
.optional()
|
|
118
|
+
.describe('Filter by work item types (Bug, Task, User Story, etc.)'),
|
|
119
|
+
'System.State': zod_1.z
|
|
120
|
+
.array(zod_1.z.string())
|
|
121
|
+
.optional()
|
|
122
|
+
.describe('Filter by work item states (New, Active, Closed, etc.)'),
|
|
123
|
+
'System.AssignedTo': zod_1.z
|
|
124
|
+
.array(zod_1.z.string())
|
|
125
|
+
.optional()
|
|
126
|
+
.describe('Filter by assigned users'),
|
|
127
|
+
'System.AreaPath': zod_1.z
|
|
128
|
+
.array(zod_1.z.string())
|
|
129
|
+
.optional()
|
|
130
|
+
.describe('Filter by area paths'),
|
|
131
|
+
})
|
|
132
|
+
.optional()
|
|
133
|
+
.describe('Optional filters to narrow search results'),
|
|
134
|
+
top: zod_1.z
|
|
135
|
+
.number()
|
|
136
|
+
.int()
|
|
137
|
+
.min(1)
|
|
138
|
+
.max(1000)
|
|
139
|
+
.default(100)
|
|
140
|
+
.describe('Number of results to return (default: 100, max: 1000)'),
|
|
141
|
+
skip: zod_1.z
|
|
142
|
+
.number()
|
|
143
|
+
.int()
|
|
144
|
+
.min(0)
|
|
145
|
+
.default(0)
|
|
146
|
+
.describe('Number of results to skip for pagination (default: 0)'),
|
|
147
|
+
includeFacets: zod_1.z
|
|
148
|
+
.boolean()
|
|
149
|
+
.default(true)
|
|
150
|
+
.describe('Whether to include faceting in results (default: true)'),
|
|
151
|
+
orderBy: zod_1.z
|
|
152
|
+
.array(zod_1.z.object({
|
|
153
|
+
field: zod_1.z.string().describe('Field to sort by'),
|
|
154
|
+
sortOrder: zod_1.z.enum(['ASC', 'DESC']).describe('Sort order (ASC/DESC)'),
|
|
155
|
+
}))
|
|
156
|
+
.optional()
|
|
157
|
+
.describe('Options for sorting search results'),
|
|
158
|
+
});
|
|
159
|
+
//# sourceMappingURL=schemas.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"schemas.js","sourceRoot":"","sources":["../../../src/features/search/schemas.ts"],"names":[],"mappings":";;;AAAA,6BAAwB;AACxB,yDAAqE;AAErE;;GAEG;AACU,QAAA,gBAAgB,GAAG,OAAC,CAAC,MAAM,CAAC;IACvC,UAAU,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,wBAAwB,CAAC;IACzD,cAAc,EAAE,OAAC;SACd,MAAM,EAAE;SACR,QAAQ,EAAE;SACV,QAAQ,CAAC,gDAAgD,wBAAU,GAAG,CAAC;IAC1E,SAAS,EAAE,OAAC;SACT,MAAM,EAAE;SACR,QAAQ,EAAE;SACV,QAAQ,CACP,wDAAwD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ACP,KAAK,CACJ,OAAC,CAAC,MAAM,CAAC;QACP,KAAK,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,kBAAkB,CAAC;QAC9C,SAAS,EAAE,OAAC,CAAC,IAAI,CAAC,CAAC,KAAK,EAAE,MAAM,CAAC,CAAC,CAAC,QAAQ,CAAC,uBAAuB,CAAC;KACrE,CAAC,CACH;SACA,QAAQ,EAAE;SACV,QAAQ,CAAC,oCAAoC,CAAC;CAClD,CAAC,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { WebApi } from 'azure-devops-node-api';
|
|
2
|
+
import { SearchCodeOptions, CodeSearchResponse } from '../types';
|
|
3
|
+
/**
|
|
4
|
+
* Search for code in Azure DevOps repositories
|
|
5
|
+
*
|
|
6
|
+
* @param connection The Azure DevOps WebApi connection
|
|
7
|
+
* @param options Parameters for searching code
|
|
8
|
+
* @returns Search results with optional file content
|
|
9
|
+
*/
|
|
10
|
+
export declare function searchCode(connection: WebApi, options: SearchCodeOptions): Promise<CodeSearchResponse>;
|
|
@@ -0,0 +1,178 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.searchCode = searchCode;
|
|
7
|
+
const axios_1 = __importDefault(require("axios"));
|
|
8
|
+
const identity_1 = require("@azure/identity");
|
|
9
|
+
const errors_1 = require("../../../shared/errors");
|
|
10
|
+
const azure_devops_url_1 = require("../../../shared/azure-devops-url");
|
|
11
|
+
const environment_1 = require("../../../utils/environment");
|
|
12
|
+
const GitInterfaces_1 = require("azure-devops-node-api/interfaces/GitInterfaces");
|
|
13
|
+
/**
|
|
14
|
+
* Search for code in Azure DevOps repositories
|
|
15
|
+
*
|
|
16
|
+
* @param connection The Azure DevOps WebApi connection
|
|
17
|
+
* @param options Parameters for searching code
|
|
18
|
+
* @returns Search results with optional file content
|
|
19
|
+
*/
|
|
20
|
+
async function searchCode(connection, options) {
|
|
21
|
+
try {
|
|
22
|
+
// When includeContent is true, limit results to prevent timeouts
|
|
23
|
+
const top = options.includeContent
|
|
24
|
+
? Math.min(options.top || 10, 10)
|
|
25
|
+
: options.top;
|
|
26
|
+
// Get the project ID (either provided or default)
|
|
27
|
+
const projectId = options.projectId || process.env.AZURE_DEVOPS_DEFAULT_PROJECT;
|
|
28
|
+
if (!projectId) {
|
|
29
|
+
throw new errors_1.AzureDevOpsValidationError('Project ID is required. Either provide a projectId or set the AZURE_DEVOPS_DEFAULT_PROJECT environment variable.');
|
|
30
|
+
}
|
|
31
|
+
// Prepare the search request
|
|
32
|
+
const searchRequest = {
|
|
33
|
+
searchText: options.searchText,
|
|
34
|
+
$skip: options.skip,
|
|
35
|
+
$top: top, // Use limited top value when includeContent is true
|
|
36
|
+
filters: {
|
|
37
|
+
Project: [projectId],
|
|
38
|
+
...(options.filters || {}),
|
|
39
|
+
},
|
|
40
|
+
includeFacets: true,
|
|
41
|
+
includeSnippet: options.includeSnippet,
|
|
42
|
+
};
|
|
43
|
+
// Get the authorization header from the connection
|
|
44
|
+
const authHeader = await getAuthorizationHeader();
|
|
45
|
+
const baseUrls = (0, azure_devops_url_1.resolveAzureDevOpsBaseUrls)(connection.serverUrl, {
|
|
46
|
+
organizationId: options.organizationId,
|
|
47
|
+
projectId,
|
|
48
|
+
});
|
|
49
|
+
// Make the search API request with the project ID
|
|
50
|
+
const searchUrl = `${baseUrls.searchBaseUrl}/${projectId}/_apis/search/codesearchresults?api-version=${environment_1.apiVersion}`;
|
|
51
|
+
const searchResponse = await axios_1.default.post(searchUrl, searchRequest, {
|
|
52
|
+
headers: {
|
|
53
|
+
Authorization: authHeader,
|
|
54
|
+
'Content-Type': 'application/json',
|
|
55
|
+
},
|
|
56
|
+
});
|
|
57
|
+
const results = searchResponse.data;
|
|
58
|
+
// If includeContent is true, fetch the content for each result
|
|
59
|
+
if (options.includeContent && results.results.length > 0) {
|
|
60
|
+
await enrichResultsWithContent(connection, results.results);
|
|
61
|
+
}
|
|
62
|
+
return results;
|
|
63
|
+
}
|
|
64
|
+
catch (error) {
|
|
65
|
+
if (error instanceof errors_1.AzureDevOpsError) {
|
|
66
|
+
throw error;
|
|
67
|
+
}
|
|
68
|
+
if (axios_1.default.isAxiosError(error)) {
|
|
69
|
+
const status = error.response?.status;
|
|
70
|
+
if (status === 404) {
|
|
71
|
+
throw new errors_1.AzureDevOpsResourceNotFoundError('Repository or project not found', { cause: error });
|
|
72
|
+
}
|
|
73
|
+
if (status === 400) {
|
|
74
|
+
throw new errors_1.AzureDevOpsValidationError('Invalid search parameters', error.response?.data, { cause: error });
|
|
75
|
+
}
|
|
76
|
+
if (status === 401) {
|
|
77
|
+
throw new errors_1.AzureDevOpsAuthenticationError('Authentication failed', {
|
|
78
|
+
cause: error,
|
|
79
|
+
});
|
|
80
|
+
}
|
|
81
|
+
if (status === 403) {
|
|
82
|
+
throw new errors_1.AzureDevOpsPermissionError('Permission denied to access repository', { cause: error });
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
throw new errors_1.AzureDevOpsError('Failed to search code', { cause: error });
|
|
86
|
+
}
|
|
87
|
+
}
|
|
88
|
+
/**
|
|
89
|
+
* Get the authorization header from the connection
|
|
90
|
+
*
|
|
91
|
+
* @returns The authorization header
|
|
92
|
+
*/
|
|
93
|
+
async function getAuthorizationHeader() {
|
|
94
|
+
try {
|
|
95
|
+
// For PAT authentication, we can construct the header directly
|
|
96
|
+
if (process.env.AZURE_DEVOPS_AUTH_METHOD?.toLowerCase() === 'pat' &&
|
|
97
|
+
process.env.AZURE_DEVOPS_PAT) {
|
|
98
|
+
// For PAT auth, we can construct the Basic auth header directly
|
|
99
|
+
const token = process.env.AZURE_DEVOPS_PAT;
|
|
100
|
+
const base64Token = Buffer.from(`:${token}`).toString('base64');
|
|
101
|
+
return `Basic ${base64Token}`;
|
|
102
|
+
}
|
|
103
|
+
// For Azure Identity / Azure CLI auth, we need to get a token
|
|
104
|
+
// using the Azure DevOps resource ID
|
|
105
|
+
// Choose the appropriate credential based on auth method
|
|
106
|
+
const credential = process.env.AZURE_DEVOPS_AUTH_METHOD?.toLowerCase() === 'azure-cli'
|
|
107
|
+
? new identity_1.AzureCliCredential()
|
|
108
|
+
: new identity_1.DefaultAzureCredential();
|
|
109
|
+
// Azure DevOps resource ID for token acquisition
|
|
110
|
+
const AZURE_DEVOPS_RESOURCE_ID = '499b84ac-1321-427f-aa17-267ca6975798';
|
|
111
|
+
// Get token for Azure DevOps
|
|
112
|
+
const token = await credential.getToken(`${AZURE_DEVOPS_RESOURCE_ID}/.default`);
|
|
113
|
+
if (!token || !token.token) {
|
|
114
|
+
throw new Error('Failed to acquire token for Azure DevOps');
|
|
115
|
+
}
|
|
116
|
+
return `Bearer ${token.token}`;
|
|
117
|
+
}
|
|
118
|
+
catch (error) {
|
|
119
|
+
throw new errors_1.AzureDevOpsValidationError(`Failed to get authorization header: ${error instanceof Error ? error.message : String(error)}`);
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
/**
|
|
123
|
+
* Enrich search results with file content
|
|
124
|
+
*
|
|
125
|
+
* @param connection The Azure DevOps WebApi connection
|
|
126
|
+
* @param results The search results to enrich
|
|
127
|
+
*/
|
|
128
|
+
async function enrichResultsWithContent(connection, results) {
|
|
129
|
+
try {
|
|
130
|
+
const gitApi = await connection.getGitApi();
|
|
131
|
+
// Process each result in parallel
|
|
132
|
+
await Promise.all(results.map(async (result) => {
|
|
133
|
+
try {
|
|
134
|
+
// Get the file content using the Git API
|
|
135
|
+
// Pass only the required parameters to avoid the "path" and "scopePath" conflict
|
|
136
|
+
const contentStream = await gitApi.getItemContent(result.repository.id, result.path, result.project.name, undefined, // No version descriptor object
|
|
137
|
+
undefined, // No recursion level
|
|
138
|
+
undefined, // Don't include content metadata
|
|
139
|
+
undefined, // No latest processed change
|
|
140
|
+
false, // Don't download
|
|
141
|
+
{
|
|
142
|
+
version: result.versions[0]?.changeId,
|
|
143
|
+
versionType: GitInterfaces_1.GitVersionType.Commit,
|
|
144
|
+
}, // Version descriptor
|
|
145
|
+
true);
|
|
146
|
+
// Convert the stream to a string and store it in the result
|
|
147
|
+
if (contentStream) {
|
|
148
|
+
// Since getItemContent always returns NodeJS.ReadableStream, we need to read the stream
|
|
149
|
+
const chunks = [];
|
|
150
|
+
// Listen for data events to collect chunks
|
|
151
|
+
contentStream.on('data', (chunk) => {
|
|
152
|
+
chunks.push(Buffer.from(chunk));
|
|
153
|
+
});
|
|
154
|
+
// Use a promise to wait for the stream to finish
|
|
155
|
+
result.content = await new Promise((resolve, reject) => {
|
|
156
|
+
contentStream.on('end', () => {
|
|
157
|
+
// Concatenate all chunks and convert to string
|
|
158
|
+
const buffer = Buffer.concat(chunks);
|
|
159
|
+
resolve(buffer.toString('utf8'));
|
|
160
|
+
});
|
|
161
|
+
contentStream.on('error', (err) => {
|
|
162
|
+
reject(err);
|
|
163
|
+
});
|
|
164
|
+
});
|
|
165
|
+
}
|
|
166
|
+
}
|
|
167
|
+
catch (error) {
|
|
168
|
+
// Log the error but don't fail the entire operation
|
|
169
|
+
console.error(`Failed to fetch content for ${result.path}: ${error instanceof Error ? error.message : String(error)}`);
|
|
170
|
+
}
|
|
171
|
+
}));
|
|
172
|
+
}
|
|
173
|
+
catch (error) {
|
|
174
|
+
// Log the error but don't fail the entire operation
|
|
175
|
+
console.error(`Failed to enrich results with content: ${error instanceof Error ? error.message : String(error)}`);
|
|
176
|
+
}
|
|
177
|
+
}
|
|
178
|
+
//# sourceMappingURL=feature.js.map
|