@rnsk/toolkits 0.0.1 → 0.0.2
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/dist/core/index.d.ts +1 -0
- package/dist/core/index.js +1 -0
- package/dist/core/scope.d.ts +4 -0
- package/dist/core/scope.js +12 -0
- package/dist/index.d.ts +5 -1
- package/dist/index.js +15 -2
- package/dist/runtime/meta-tools.js +2 -0
- package/dist/toolkits/github/icon.d.ts +5 -0
- package/dist/toolkits/github/icon.js +15 -0
- package/dist/toolkits/github/manifest.d.ts +3 -0
- package/dist/toolkits/github/manifest.js +36 -0
- package/dist/toolkits/github/tools/Actions/delete-artifact.d.ts +13 -0
- package/dist/toolkits/github/tools/Actions/delete-artifact.js +31 -0
- package/dist/toolkits/github/tools/Actions/get-artifact.d.ts +31 -0
- package/dist/toolkits/github/tools/Actions/get-artifact.js +39 -0
- package/dist/toolkits/github/tools/Actions/get-workflow-job.d.ts +36 -0
- package/dist/toolkits/github/tools/Actions/get-workflow-job.js +48 -0
- package/dist/toolkits/github/tools/Actions/list-artifacts.d.ts +23 -0
- package/dist/toolkits/github/tools/Actions/list-artifacts.js +43 -0
- package/dist/toolkits/github/tools/Actions/list-workflow-jobs.d.ts +27 -0
- package/dist/toolkits/github/tools/Actions/list-workflow-jobs.js +49 -0
- package/dist/toolkits/github/tools/Actions/list-workflow-run-artifacts.d.ts +24 -0
- package/dist/toolkits/github/tools/Actions/list-workflow-run-artifacts.js +45 -0
- package/dist/toolkits/github/tools/Activity/list-notifications.d.ts +24 -0
- package/dist/toolkits/github/tools/Activity/list-notifications.js +45 -0
- package/dist/toolkits/github/tools/Activity/list-public-events.d.ts +18 -0
- package/dist/toolkits/github/tools/Activity/list-public-events.js +37 -0
- package/dist/toolkits/github/tools/Activity/list-repo-events.d.ts +19 -0
- package/dist/toolkits/github/tools/Activity/list-repo-events.js +40 -0
- package/dist/toolkits/github/tools/Activity/list-user-events.d.ts +17 -0
- package/dist/toolkits/github/tools/Activity/list-user-events.js +37 -0
- package/dist/toolkits/github/tools/Activity/mark-notifications-read.d.ts +11 -0
- package/dist/toolkits/github/tools/Activity/mark-notifications-read.js +27 -0
- package/dist/toolkits/github/tools/Apps/get-authenticated-app.d.ts +24 -0
- package/dist/toolkits/github/tools/Apps/get-authenticated-app.js +36 -0
- package/dist/toolkits/github/tools/Apps/get-installation.d.ts +76 -0
- package/dist/toolkits/github/tools/Apps/get-installation.js +36 -0
- package/dist/toolkits/github/tools/Apps/list-installations.d.ts +19 -0
- package/dist/toolkits/github/tools/Apps/list-installations.js +38 -0
- package/dist/toolkits/github/tools/Checks/create-check-run.d.ts +24 -0
- package/dist/toolkits/github/tools/Checks/create-check-run.js +43 -0
- package/dist/toolkits/github/tools/Checks/create-check-suite.d.ts +21 -0
- package/dist/toolkits/github/tools/Checks/create-check-suite.js +37 -0
- package/dist/toolkits/github/tools/Checks/get-check-run.d.ts +25 -0
- package/dist/toolkits/github/tools/Checks/get-check-run.js +39 -0
- package/dist/toolkits/github/tools/Checks/get-check-suite.d.ts +25 -0
- package/dist/toolkits/github/tools/Checks/get-check-suite.js +39 -0
- package/dist/toolkits/github/tools/Checks/list-check-runs.d.ts +27 -0
- package/dist/toolkits/github/tools/Checks/list-check-runs.js +50 -0
- package/dist/toolkits/github/tools/Checks/update-check-run.d.ts +23 -0
- package/dist/toolkits/github/tools/Checks/update-check-run.js +41 -0
- package/dist/toolkits/github/tools/CodeScanning/get-alert.d.ts +25 -0
- package/dist/toolkits/github/tools/CodeScanning/get-alert.js +41 -0
- package/dist/toolkits/github/tools/CodeScanning/list-alerts.d.ts +23 -0
- package/dist/toolkits/github/tools/CodeScanning/list-alerts.js +50 -0
- package/dist/toolkits/github/tools/CodeScanning/update-alert.d.ts +19 -0
- package/dist/toolkits/github/tools/CodeScanning/update-alert.js +39 -0
- package/dist/toolkits/github/tools/Collaborators/add-collaborator.d.ts +14 -0
- package/dist/toolkits/github/tools/Collaborators/add-collaborator.js +33 -0
- package/dist/toolkits/github/tools/Collaborators/check-collaborator.d.ts +13 -0
- package/dist/toolkits/github/tools/Collaborators/check-collaborator.js +34 -0
- package/dist/toolkits/github/tools/Collaborators/list-collaborators.d.ts +25 -0
- package/dist/toolkits/github/tools/Collaborators/list-collaborators.js +41 -0
- package/dist/toolkits/github/tools/Collaborators/remove-collaborator.d.ts +13 -0
- package/dist/toolkits/github/tools/Collaborators/remove-collaborator.js +31 -0
- package/dist/toolkits/github/tools/Commits/compare-commits.d.ts +30 -0
- package/dist/toolkits/github/tools/Commits/compare-commits.js +37 -0
- package/dist/toolkits/github/tools/Commits/get-commit.d.ts +46 -0
- package/dist/toolkits/github/tools/Commits/get-commit.js +35 -0
- package/dist/toolkits/github/tools/Commits/list-branches-for-head-commit.d.ts +20 -0
- package/dist/toolkits/github/tools/Commits/list-branches-for-head-commit.js +31 -0
- package/dist/toolkits/github/tools/Commits/list-commits.d.ts +21 -0
- package/dist/toolkits/github/tools/Commits/list-commits.js +43 -0
- package/dist/toolkits/github/tools/Commits/list-pull-requests-associated-with-commit.d.ts +81 -0
- package/dist/toolkits/github/tools/Commits/list-pull-requests-associated-with-commit.js +35 -0
- package/dist/toolkits/github/tools/Dependabot/get-alert.d.ts +53 -0
- package/dist/toolkits/github/tools/Dependabot/get-alert.js +37 -0
- package/dist/toolkits/github/tools/Dependabot/list-alerts.d.ts +23 -0
- package/dist/toolkits/github/tools/Dependabot/list-alerts.js +46 -0
- package/dist/toolkits/github/tools/Dependabot/update-alert.d.ts +19 -0
- package/dist/toolkits/github/tools/Dependabot/update-alert.js +39 -0
- package/dist/toolkits/github/tools/DeployKeys/create-deploy-key.d.ts +23 -0
- package/dist/toolkits/github/tools/DeployKeys/create-deploy-key.js +43 -0
- package/dist/toolkits/github/tools/DeployKeys/delete-deploy-key.d.ts +13 -0
- package/dist/toolkits/github/tools/DeployKeys/delete-deploy-key.js +31 -0
- package/dist/toolkits/github/tools/DeployKeys/get-deploy-key.d.ts +21 -0
- package/dist/toolkits/github/tools/DeployKeys/get-deploy-key.js +39 -0
- package/dist/toolkits/github/tools/DeployKeys/list-deploy-keys.d.ts +21 -0
- package/dist/toolkits/github/tools/DeployKeys/list-deploy-keys.js +44 -0
- package/dist/toolkits/github/tools/Deployments/create-deployment.d.ts +33 -0
- package/dist/toolkits/github/tools/Deployments/create-deployment.js +51 -0
- package/dist/toolkits/github/tools/Deployments/delete-deployment.d.ts +13 -0
- package/dist/toolkits/github/tools/Deployments/delete-deployment.js +31 -0
- package/dist/toolkits/github/tools/Deployments/get-deployment.d.ts +27 -0
- package/dist/toolkits/github/tools/Deployments/get-deployment.js +42 -0
- package/dist/toolkits/github/tools/Deployments/list-deployments.d.ts +27 -0
- package/dist/toolkits/github/tools/Deployments/list-deployments.js +52 -0
- package/dist/toolkits/github/tools/Environments/create-or-update-environment.d.ts +32 -0
- package/dist/toolkits/github/tools/Environments/create-or-update-environment.js +50 -0
- package/dist/toolkits/github/tools/Environments/delete-environment.d.ts +13 -0
- package/dist/toolkits/github/tools/Environments/delete-environment.js +31 -0
- package/dist/toolkits/github/tools/Environments/get-environment.d.ts +48 -0
- package/dist/toolkits/github/tools/Environments/get-environment.js +42 -0
- package/dist/toolkits/github/tools/Environments/list-environments.d.ts +23 -0
- package/dist/toolkits/github/tools/Environments/list-environments.js +45 -0
- package/dist/toolkits/github/tools/Files/create-or-update-file.d.ts +21 -0
- package/dist/toolkits/github/tools/Files/create-or-update-file.js +44 -0
- package/dist/toolkits/github/tools/Files/delete-file.d.ts +18 -0
- package/dist/toolkits/github/tools/Files/delete-file.js +40 -0
- package/dist/toolkits/github/tools/Files/get-file-content.d.ts +32 -0
- package/dist/toolkits/github/tools/Files/get-file-content.js +51 -0
- package/dist/toolkits/github/tools/Gists/create-gist.d.ts +19 -0
- package/dist/toolkits/github/tools/Gists/create-gist.js +37 -0
- package/dist/toolkits/github/tools/Gists/get-gist.d.ts +23 -0
- package/dist/toolkits/github/tools/Gists/get-gist.js +43 -0
- package/dist/toolkits/github/tools/Gists/list-gists.d.ts +19 -0
- package/dist/toolkits/github/tools/Gists/list-gists.js +38 -0
- package/dist/toolkits/github/tools/Git/create-blob.d.ts +16 -0
- package/dist/toolkits/github/tools/Git/create-blob.js +38 -0
- package/dist/toolkits/github/tools/Git/create-git-commit.d.ts +47 -0
- package/dist/toolkits/github/tools/Git/create-git-commit.js +51 -0
- package/dist/toolkits/github/tools/Git/create-ref.d.ts +24 -0
- package/dist/toolkits/github/tools/Git/create-ref.js +40 -0
- package/dist/toolkits/github/tools/Git/create-tree.d.ts +31 -0
- package/dist/toolkits/github/tools/Git/create-tree.js +52 -0
- package/dist/toolkits/github/tools/Git/delete-ref.d.ts +13 -0
- package/dist/toolkits/github/tools/Git/delete-ref.js +31 -0
- package/dist/toolkits/github/tools/Git/get-blob.d.ts +21 -0
- package/dist/toolkits/github/tools/Git/get-blob.js +39 -0
- package/dist/toolkits/github/tools/Git/get-git-commit.d.ts +40 -0
- package/dist/toolkits/github/tools/Git/get-git-commit.js +41 -0
- package/dist/toolkits/github/tools/Git/get-ref.d.ts +18 -0
- package/dist/toolkits/github/tools/Git/get-ref.js +42 -0
- package/dist/toolkits/github/tools/Git/get-tree.d.ts +27 -0
- package/dist/toolkits/github/tools/Git/get-tree.js +47 -0
- package/dist/toolkits/github/tools/Git/update-ref.d.ts +25 -0
- package/dist/toolkits/github/tools/Git/update-ref.js +42 -0
- package/dist/toolkits/github/tools/Issues/add-issue-assignees.d.ts +14 -0
- package/dist/toolkits/github/tools/Issues/add-issue-assignees.js +35 -0
- package/dist/toolkits/github/tools/Issues/add-issue-comment.d.ts +20 -0
- package/dist/toolkits/github/tools/Issues/add-issue-comment.js +38 -0
- package/dist/toolkits/github/tools/Issues/add-issue-labels.d.ts +14 -0
- package/dist/toolkits/github/tools/Issues/add-issue-labels.js +35 -0
- package/dist/toolkits/github/tools/Issues/create-issue.d.ts +22 -0
- package/dist/toolkits/github/tools/Issues/create-issue.js +34 -0
- package/dist/toolkits/github/tools/Issues/get-issue.d.ts +29 -0
- package/dist/toolkits/github/tools/Issues/get-issue.js +36 -0
- package/dist/toolkits/github/tools/Issues/list-authenticated-user-issues.d.ts +21 -0
- package/dist/toolkits/github/tools/Issues/list-authenticated-user-issues.js +34 -0
- package/dist/toolkits/github/tools/Issues/list-issue-comments.d.ts +19 -0
- package/dist/toolkits/github/tools/Issues/list-issue-comments.js +40 -0
- package/dist/toolkits/github/tools/Issues/list-org-issues.d.ts +22 -0
- package/dist/toolkits/github/tools/Issues/list-org-issues.js +38 -0
- package/dist/toolkits/github/tools/Issues/list-repo-issues.d.ts +28 -0
- package/dist/toolkits/github/tools/Issues/list-repo-issues.js +42 -0
- package/dist/toolkits/github/tools/Issues/list-user-account-issues.d.ts +21 -0
- package/dist/toolkits/github/tools/Issues/list-user-account-issues.js +36 -0
- package/dist/toolkits/github/tools/Issues/lock-issue.d.ts +15 -0
- package/dist/toolkits/github/tools/Issues/lock-issue.js +44 -0
- package/dist/toolkits/github/tools/Issues/remove-issue-label.d.ts +14 -0
- package/dist/toolkits/github/tools/Issues/remove-issue-label.js +33 -0
- package/dist/toolkits/github/tools/Issues/unlock-issue.d.ts +13 -0
- package/dist/toolkits/github/tools/Issues/unlock-issue.js +31 -0
- package/dist/toolkits/github/tools/Issues/update-issue.d.ts +22 -0
- package/dist/toolkits/github/tools/Issues/update-issue.js +42 -0
- package/dist/toolkits/github/tools/Licenses/get-license.d.ts +33 -0
- package/dist/toolkits/github/tools/Licenses/get-license.js +42 -0
- package/dist/toolkits/github/tools/Licenses/get-repo-license.d.ts +47 -0
- package/dist/toolkits/github/tools/Licenses/get-repo-license.js +45 -0
- package/dist/toolkits/github/tools/Licenses/list-licenses.d.ts +12 -0
- package/dist/toolkits/github/tools/Licenses/list-licenses.js +32 -0
- package/dist/toolkits/github/tools/Markdown/render-markdown.d.ts +13 -0
- package/dist/toolkits/github/tools/Markdown/render-markdown.js +31 -0
- package/dist/toolkits/github/tools/Organizations/get-org-membership.d.ts +58 -0
- package/dist/toolkits/github/tools/Organizations/get-org-membership.js +38 -0
- package/dist/toolkits/github/tools/Organizations/get-organization.d.ts +65 -0
- package/dist/toolkits/github/tools/Organizations/get-organization.js +58 -0
- package/dist/toolkits/github/tools/Organizations/list-org-members.d.ts +18 -0
- package/dist/toolkits/github/tools/Organizations/list-org-members.js +44 -0
- package/dist/toolkits/github/tools/Organizations/list-org-repositories.d.ts +50 -0
- package/dist/toolkits/github/tools/Organizations/list-org-repositories.js +69 -0
- package/dist/toolkits/github/tools/Organizations/list-organizations.d.ts +13 -0
- package/dist/toolkits/github/tools/Organizations/list-organizations.js +36 -0
- package/dist/toolkits/github/tools/Organizations/list-user-organizations.d.ts +20 -0
- package/dist/toolkits/github/tools/Organizations/list-user-organizations.js +43 -0
- package/dist/toolkits/github/tools/Organizations/update-organization.d.ts +33 -0
- package/dist/toolkits/github/tools/Organizations/update-organization.js +50 -0
- package/dist/toolkits/github/tools/PRs/check-pull-request-merged.d.ts +13 -0
- package/dist/toolkits/github/tools/PRs/check-pull-request-merged.js +34 -0
- package/dist/toolkits/github/tools/PRs/create-pull-request-review.d.ts +19 -0
- package/dist/toolkits/github/tools/PRs/create-pull-request-review.js +39 -0
- package/dist/toolkits/github/tools/PRs/create-pull-request.d.ts +23 -0
- package/dist/toolkits/github/tools/PRs/create-pull-request.js +44 -0
- package/dist/toolkits/github/tools/PRs/get-pull-request.d.ts +41 -0
- package/dist/toolkits/github/tools/PRs/get-pull-request.js +47 -0
- package/dist/toolkits/github/tools/PRs/list-pull-request-commits.d.ts +15 -0
- package/dist/toolkits/github/tools/PRs/list-pull-request-commits.js +37 -0
- package/dist/toolkits/github/tools/PRs/list-pull-request-files.d.ts +22 -0
- package/dist/toolkits/github/tools/PRs/list-pull-request-files.js +42 -0
- package/dist/toolkits/github/tools/PRs/list-pull-requests.d.ts +24 -0
- package/dist/toolkits/github/tools/PRs/list-pull-requests.js +44 -0
- package/dist/toolkits/github/tools/PRs/merge-pull-request.d.ts +20 -0
- package/dist/toolkits/github/tools/PRs/merge-pull-request.js +41 -0
- package/dist/toolkits/github/tools/PRs/update-pull-request-branch.d.ts +16 -0
- package/dist/toolkits/github/tools/PRs/update-pull-request-branch.js +36 -0
- package/dist/toolkits/github/tools/PRs/update-pull-request.d.ts +26 -0
- package/dist/toolkits/github/tools/PRs/update-pull-request.js +47 -0
- package/dist/toolkits/github/tools/Projects/create-org-project.d.ts +27 -0
- package/dist/toolkits/github/tools/Projects/create-org-project.js +43 -0
- package/dist/toolkits/github/tools/Projects/delete-project.d.ts +11 -0
- package/dist/toolkits/github/tools/Projects/delete-project.js +27 -0
- package/dist/toolkits/github/tools/Projects/get-project.d.ts +31 -0
- package/dist/toolkits/github/tools/Projects/get-project.js +42 -0
- package/dist/toolkits/github/tools/Projects/list-org-projects.d.ts +20 -0
- package/dist/toolkits/github/tools/Projects/list-org-projects.js +45 -0
- package/dist/toolkits/github/tools/Projects/list-project-columns.d.ts +16 -0
- package/dist/toolkits/github/tools/Projects/list-project-columns.js +40 -0
- package/dist/toolkits/github/tools/Projects/list-repo-projects.d.ts +21 -0
- package/dist/toolkits/github/tools/Projects/list-repo-projects.js +47 -0
- package/dist/toolkits/github/tools/Projects/update-project.d.ts +22 -0
- package/dist/toolkits/github/tools/Projects/update-project.js +41 -0
- package/dist/toolkits/github/tools/RateLimit/get-rate-limit.d.ts +19 -0
- package/dist/toolkits/github/tools/RateLimit/get-rate-limit.js +26 -0
- package/dist/toolkits/github/tools/Reactions/create-commit-comment-reaction.d.ts +20 -0
- package/dist/toolkits/github/tools/Reactions/create-commit-comment-reaction.js +40 -0
- package/dist/toolkits/github/tools/Reactions/create-issue-reaction.d.ts +20 -0
- package/dist/toolkits/github/tools/Reactions/create-issue-reaction.js +40 -0
- package/dist/toolkits/github/tools/Reactions/delete-reaction.d.ts +11 -0
- package/dist/toolkits/github/tools/Reactions/delete-reaction.js +27 -0
- package/dist/toolkits/github/tools/Reactions/list-commit-comment-reactions.d.ts +17 -0
- package/dist/toolkits/github/tools/Reactions/list-commit-comment-reactions.js +44 -0
- package/dist/toolkits/github/tools/Reactions/list-issue-reactions.d.ts +17 -0
- package/dist/toolkits/github/tools/Reactions/list-issue-reactions.js +44 -0
- package/dist/toolkits/github/tools/Reactions/list-pr-comment-reactions.d.ts +17 -0
- package/dist/toolkits/github/tools/Reactions/list-pr-comment-reactions.js +44 -0
- package/dist/toolkits/github/tools/Releases/create-release.d.ts +27 -0
- package/dist/toolkits/github/tools/Releases/create-release.js +45 -0
- package/dist/toolkits/github/tools/Releases/delete-release.d.ts +13 -0
- package/dist/toolkits/github/tools/Releases/delete-release.js +31 -0
- package/dist/toolkits/github/tools/Releases/generate-release-notes.d.ts +18 -0
- package/dist/toolkits/github/tools/Releases/generate-release-notes.js +39 -0
- package/dist/toolkits/github/tools/Releases/get-latest-release.d.ts +22 -0
- package/dist/toolkits/github/tools/Releases/get-latest-release.js +38 -0
- package/dist/toolkits/github/tools/Releases/get-release.d.ts +37 -0
- package/dist/toolkits/github/tools/Releases/get-release.js +50 -0
- package/dist/toolkits/github/tools/Releases/list-releases.d.ts +22 -0
- package/dist/toolkits/github/tools/Releases/list-releases.js +47 -0
- package/dist/toolkits/github/tools/Releases/update-release.d.ts +27 -0
- package/dist/toolkits/github/tools/Releases/update-release.js +46 -0
- package/dist/toolkits/github/tools/Repos/create-repo.d.ts +32 -0
- package/dist/toolkits/github/tools/Repos/create-repo.js +57 -0
- package/dist/toolkits/github/tools/Repos/fork-repo.d.ts +17 -0
- package/dist/toolkits/github/tools/Repos/fork-repo.js +35 -0
- package/dist/toolkits/github/tools/Repos/get-repo-contributors.d.ts +20 -0
- package/dist/toolkits/github/tools/Repos/get-repo-contributors.js +39 -0
- package/dist/toolkits/github/tools/Repos/get-repo-languages.d.ts +14 -0
- package/dist/toolkits/github/tools/Repos/get-repo-languages.js +29 -0
- package/dist/toolkits/github/tools/Repos/get-repo.d.ts +36 -0
- package/dist/toolkits/github/tools/Repos/get-repo.js +43 -0
- package/dist/toolkits/github/tools/Repos/list-branches.d.ts +17 -0
- package/dist/toolkits/github/tools/Repos/list-branches.js +37 -0
- package/dist/toolkits/github/tools/Repos/list-repos.d.ts +22 -0
- package/dist/toolkits/github/tools/Repos/list-repos.js +36 -0
- package/dist/toolkits/github/tools/Repos/star-repo.d.ts +13 -0
- package/dist/toolkits/github/tools/Repos/star-repo.js +39 -0
- package/dist/toolkits/github/tools/Repos/watch-repo.d.ts +18 -0
- package/dist/toolkits/github/tools/Repos/watch-repo.js +37 -0
- package/dist/toolkits/github/tools/Search/search-code.d.ts +14 -0
- package/dist/toolkits/github/tools/Search/search-code.js +33 -0
- package/dist/toolkits/github/tools/Search/search-commits.d.ts +14 -0
- package/dist/toolkits/github/tools/Search/search-commits.js +33 -0
- package/dist/toolkits/github/tools/Search/search-issues.d.ts +23 -0
- package/dist/toolkits/github/tools/Search/search-issues.js +43 -0
- package/dist/toolkits/github/tools/Search/search-labels.d.ts +15 -0
- package/dist/toolkits/github/tools/Search/search-labels.js +35 -0
- package/dist/toolkits/github/tools/Search/search-repos.d.ts +22 -0
- package/dist/toolkits/github/tools/Search/search-repos.js +47 -0
- package/dist/toolkits/github/tools/Search/search-topics.d.ts +12 -0
- package/dist/toolkits/github/tools/Search/search-topics.js +29 -0
- package/dist/toolkits/github/tools/Search/search-users.d.ts +21 -0
- package/dist/toolkits/github/tools/Search/search-users.js +41 -0
- package/dist/toolkits/github/tools/SecretScanning/get-alert.d.ts +33 -0
- package/dist/toolkits/github/tools/SecretScanning/get-alert.js +45 -0
- package/dist/toolkits/github/tools/SecretScanning/list-alerts.d.ts +25 -0
- package/dist/toolkits/github/tools/SecretScanning/list-alerts.js +53 -0
- package/dist/toolkits/github/tools/SecretScanning/update-alert.d.ts +19 -0
- package/dist/toolkits/github/tools/SecretScanning/update-alert.js +41 -0
- package/dist/toolkits/github/tools/SecurityAdvisories/create-repository-advisory.d.ts +34 -0
- package/dist/toolkits/github/tools/SecurityAdvisories/create-repository-advisory.js +52 -0
- package/dist/toolkits/github/tools/SecurityAdvisories/get-repository-advisory.d.ts +27 -0
- package/dist/toolkits/github/tools/SecurityAdvisories/get-repository-advisory.js +42 -0
- package/dist/toolkits/github/tools/SecurityAdvisories/list-global-advisories.d.ts +14 -0
- package/dist/toolkits/github/tools/SecurityAdvisories/list-global-advisories.js +37 -0
- package/dist/toolkits/github/tools/SecurityAdvisories/list-repository-advisories.d.ts +22 -0
- package/dist/toolkits/github/tools/SecurityAdvisories/list-repository-advisories.js +47 -0
- package/dist/toolkits/github/tools/Stars/check-repo-starred.d.ts +12 -0
- package/dist/toolkits/github/tools/Stars/check-repo-starred.js +32 -0
- package/dist/toolkits/github/tools/Stars/list-stargazers.d.ts +15 -0
- package/dist/toolkits/github/tools/Stars/list-stargazers.js +40 -0
- package/dist/toolkits/github/tools/Stars/list-starred-repos.d.ts +15 -0
- package/dist/toolkits/github/tools/Stars/list-starred-repos.js +38 -0
- package/dist/toolkits/github/tools/Stars/star-repo.d.ts +12 -0
- package/dist/toolkits/github/tools/Stars/star-repo.js +29 -0
- package/dist/toolkits/github/tools/Stars/unstar-repo.d.ts +12 -0
- package/dist/toolkits/github/tools/Stars/unstar-repo.js +29 -0
- package/dist/toolkits/github/tools/Statuses/create-commit-status.d.ts +25 -0
- package/dist/toolkits/github/tools/Statuses/create-commit-status.js +44 -0
- package/dist/toolkits/github/tools/Statuses/get-combined-status.d.ts +26 -0
- package/dist/toolkits/github/tools/Statuses/get-combined-status.js +44 -0
- package/dist/toolkits/github/tools/Statuses/list-commit-statuses.d.ts +18 -0
- package/dist/toolkits/github/tools/Statuses/list-commit-statuses.js +44 -0
- package/dist/toolkits/github/tools/Teams/add-team-repo.d.ts +15 -0
- package/dist/toolkits/github/tools/Teams/add-team-repo.js +35 -0
- package/dist/toolkits/github/tools/Teams/create-team.d.ts +32 -0
- package/dist/toolkits/github/tools/Teams/create-team.js +46 -0
- package/dist/toolkits/github/tools/Teams/delete-team.d.ts +12 -0
- package/dist/toolkits/github/tools/Teams/delete-team.js +29 -0
- package/dist/toolkits/github/tools/Teams/get-team.d.ts +28 -0
- package/dist/toolkits/github/tools/Teams/get-team.js +41 -0
- package/dist/toolkits/github/tools/Teams/list-team-members.d.ts +16 -0
- package/dist/toolkits/github/tools/Teams/list-team-members.js +42 -0
- package/dist/toolkits/github/tools/Teams/list-team-repos.d.ts +22 -0
- package/dist/toolkits/github/tools/Teams/list-team-repos.js +41 -0
- package/dist/toolkits/github/tools/Teams/list-teams.d.ts +18 -0
- package/dist/toolkits/github/tools/Teams/list-teams.js +42 -0
- package/dist/toolkits/github/tools/Teams/remove-team-repo.d.ts +14 -0
- package/dist/toolkits/github/tools/Teams/remove-team-repo.js +33 -0
- package/dist/toolkits/github/tools/Teams/update-team.d.ts +27 -0
- package/dist/toolkits/github/tools/Teams/update-team.js +44 -0
- package/dist/toolkits/github/tools/Users/follow-user.d.ts +12 -0
- package/dist/toolkits/github/tools/Users/follow-user.js +36 -0
- package/dist/toolkits/github/tools/Users/get-github-user.d.ts +64 -0
- package/dist/toolkits/github/tools/Users/get-github-user.js +48 -0
- package/dist/toolkits/github/tools/Users/get-user-by-id.d.ts +53 -0
- package/dist/toolkits/github/tools/Users/get-user-by-id.js +27 -0
- package/dist/toolkits/github/tools/Users/get-user-context.d.ts +14 -0
- package/dist/toolkits/github/tools/Users/get-user-context.js +32 -0
- package/dist/toolkits/github/tools/Users/get-user.d.ts +53 -0
- package/dist/toolkits/github/tools/Users/get-user.js +27 -0
- package/dist/toolkits/github/tools/Users/list-users.d.ts +31 -0
- package/dist/toolkits/github/tools/Users/list-users.js +29 -0
- package/dist/toolkits/github/tools/Users/update-authenticated-user.d.ts +62 -0
- package/dist/toolkits/github/tools/Users/update-authenticated-user.js +39 -0
- package/dist/toolkits/github/tools/Webhooks/create-repo-webhook.d.ts +34 -0
- package/dist/toolkits/github/tools/Webhooks/create-repo-webhook.js +47 -0
- package/dist/toolkits/github/tools/Webhooks/delete-repo-webhook.d.ts +13 -0
- package/dist/toolkits/github/tools/Webhooks/delete-repo-webhook.js +31 -0
- package/dist/toolkits/github/tools/Webhooks/get-repo-webhook.d.ts +30 -0
- package/dist/toolkits/github/tools/Webhooks/get-repo-webhook.js +41 -0
- package/dist/toolkits/github/tools/Webhooks/list-repo-webhooks.d.ts +31 -0
- package/dist/toolkits/github/tools/Webhooks/list-repo-webhooks.js +47 -0
- package/dist/toolkits/github/tools/Webhooks/update-repo-webhook.d.ts +36 -0
- package/dist/toolkits/github/tools/Webhooks/update-repo-webhook.js +50 -0
- package/dist/toolkits/github/tools/Workflows/get-workflow-run.d.ts +31 -0
- package/dist/toolkits/github/tools/Workflows/get-workflow-run.js +42 -0
- package/dist/toolkits/github/tools/Workflows/list-workflow-runs.d.ts +25 -0
- package/dist/toolkits/github/tools/Workflows/list-workflow-runs.js +59 -0
- package/dist/toolkits/github/tools/Workflows/list-workflows.d.ts +21 -0
- package/dist/toolkits/github/tools/Workflows/list-workflows.js +40 -0
- package/dist/toolkits/github/tools/Workflows/trigger-workflow.d.ts +15 -0
- package/dist/toolkits/github/tools/Workflows/trigger-workflow.js +35 -0
- package/dist/toolkits/github/tools/index.d.ts +176 -0
- package/dist/toolkits/github/tools/index.js +646 -0
- package/dist/toolkits/gmail/icon.js +25 -1
- package/dist/toolkits/google-calendar/icon.d.ts +5 -0
- package/dist/toolkits/google-calendar/icon.js +6 -0
- package/dist/toolkits/google-calendar/manifest.d.ts +3 -0
- package/dist/toolkits/google-calendar/manifest.js +45 -0
- package/dist/toolkits/google-calendar/tools/create-event.d.ts +27 -0
- package/dist/toolkits/google-calendar/tools/create-event.js +54 -0
- package/dist/toolkits/google-calendar/tools/index.d.ts +7 -0
- package/dist/toolkits/google-calendar/tools/index.js +18 -0
- package/dist/toolkits/google-calendar/tools/list-events.d.ts +24 -0
- package/dist/toolkits/google-calendar/tools/list-events.js +46 -0
- package/dist/toolkits/google-sheets/icon.d.ts +5 -0
- package/dist/toolkits/google-sheets/icon.js +13 -0
- package/dist/toolkits/google-sheets/manifest.d.ts +3 -0
- package/dist/toolkits/google-sheets/manifest.js +45 -0
- package/dist/toolkits/google-sheets/tools/get-spreadsheet.d.ts +5 -0
- package/dist/toolkits/google-sheets/tools/get-spreadsheet.js +33 -0
- package/dist/toolkits/google-sheets/tools/get-values.d.ts +6 -0
- package/dist/toolkits/google-sheets/tools/get-values.js +34 -0
- package/dist/toolkits/google-sheets/tools/index.d.ts +11 -0
- package/dist/toolkits/google-sheets/tools/index.js +26 -0
- package/dist/toolkits/google-sheets/tools/list-spreadsheets.d.ts +21 -0
- package/dist/toolkits/google-sheets/tools/list-spreadsheets.js +43 -0
- package/dist/toolkits/linear/icon.js +24 -1
- package/dist/toolkits/mathematics/icon.js +1 -1
- package/dist/toolkits/notion/icon.d.ts +5 -0
- package/dist/toolkits/notion/icon.js +10 -0
- package/dist/toolkits/notion/manifest.d.ts +3 -0
- package/dist/toolkits/notion/manifest.js +37 -0
- package/dist/toolkits/notion/tools/append-block-children.d.ts +6 -0
- package/dist/toolkits/notion/tools/append-block-children.js +30 -0
- package/dist/toolkits/notion/tools/create-page.d.ts +12 -0
- package/dist/toolkits/notion/tools/create-page.js +40 -0
- package/dist/toolkits/notion/tools/get-database.d.ts +5 -0
- package/dist/toolkits/notion/tools/get-database.js +25 -0
- package/dist/toolkits/notion/tools/get-page.d.ts +15 -0
- package/dist/toolkits/notion/tools/get-page.js +42 -0
- package/dist/toolkits/notion/tools/index.d.ts +16 -0
- package/dist/toolkits/notion/tools/index.js +61 -0
- package/dist/toolkits/notion/tools/list-databases.d.ts +5 -0
- package/dist/toolkits/notion/tools/list-databases.js +33 -0
- package/dist/toolkits/notion/tools/query-database.d.ts +8 -0
- package/dist/toolkits/notion/tools/query-database.js +34 -0
- package/dist/toolkits/notion/tools/search.d.ts +14 -0
- package/dist/toolkits/notion/tools/search.js +41 -0
- package/dist/toolkits/notion/tools/update-page.d.ts +9 -0
- package/dist/toolkits/notion/tools/update-page.js +36 -0
- package/dist/toolkits/web-search/icon.js +3 -1
- package/package.json +4 -2
- package/dist/core/categories.d.ts.map +0 -1
- package/dist/core/categories.js.map +0 -1
- package/dist/core/define.d.ts.map +0 -1
- package/dist/core/define.js.map +0 -1
- package/dist/core/index.d.ts.map +0 -1
- package/dist/core/index.js.map +0 -1
- package/dist/core/types.d.ts.map +0 -1
- package/dist/core/types.js.map +0 -1
- package/dist/core/validate.d.ts.map +0 -1
- package/dist/core/validate.js.map +0 -1
- package/dist/index.d.ts.map +0 -1
- package/dist/index.js.map +0 -1
- package/dist/runtime/credentials.d.ts.map +0 -1
- package/dist/runtime/credentials.js.map +0 -1
- package/dist/runtime/index.d.ts.map +0 -1
- package/dist/runtime/index.js.map +0 -1
- package/dist/runtime/meta-tools.d.ts.map +0 -1
- package/dist/runtime/meta-tools.js.map +0 -1
- package/dist/runtime/registry.d.ts.map +0 -1
- package/dist/runtime/registry.js.map +0 -1
- package/dist/runtime/schema-helpers.d.ts.map +0 -1
- package/dist/runtime/schema-helpers.js.map +0 -1
- package/dist/toolkits/gmail/icon.d.ts.map +0 -1
- package/dist/toolkits/gmail/icon.js.map +0 -1
- package/dist/toolkits/gmail/manifest.d.ts.map +0 -1
- package/dist/toolkits/gmail/manifest.js.map +0 -1
- package/dist/toolkits/gmail/tools/get-message.d.ts.map +0 -1
- package/dist/toolkits/gmail/tools/get-message.js.map +0 -1
- package/dist/toolkits/gmail/tools/list-messages.d.ts.map +0 -1
- package/dist/toolkits/gmail/tools/list-messages.js.map +0 -1
- package/dist/toolkits/gmail/tools/send-message.d.ts.map +0 -1
- package/dist/toolkits/gmail/tools/send-message.js.map +0 -1
- package/dist/toolkits/linear/icon.d.ts.map +0 -1
- package/dist/toolkits/linear/icon.js.map +0 -1
- package/dist/toolkits/linear/manifest.d.ts.map +0 -1
- package/dist/toolkits/linear/manifest.js.map +0 -1
- package/dist/toolkits/linear/tools/create-issue.d.ts.map +0 -1
- package/dist/toolkits/linear/tools/create-issue.js.map +0 -1
- package/dist/toolkits/linear/tools/list-teams.d.ts.map +0 -1
- package/dist/toolkits/linear/tools/list-teams.js.map +0 -1
- package/dist/toolkits/linear/tools/search-issues.d.ts.map +0 -1
- package/dist/toolkits/linear/tools/search-issues.js.map +0 -1
- package/dist/toolkits/mathematics/icon.d.ts.map +0 -1
- package/dist/toolkits/mathematics/icon.js.map +0 -1
- package/dist/toolkits/mathematics/manifest.d.ts.map +0 -1
- package/dist/toolkits/mathematics/manifest.js.map +0 -1
- package/dist/toolkits/mathematics/tools/calculate-combinatorics.d.ts.map +0 -1
- package/dist/toolkits/mathematics/tools/calculate-combinatorics.js.map +0 -1
- package/dist/toolkits/mathematics/tools/calculate-matrix-determinant.d.ts.map +0 -1
- package/dist/toolkits/mathematics/tools/calculate-matrix-determinant.js.map +0 -1
- package/dist/toolkits/mathematics/tools/calculate-percentage.d.ts.map +0 -1
- package/dist/toolkits/mathematics/tools/calculate-percentage.js.map +0 -1
- package/dist/toolkits/mathematics/tools/calculate-product.d.ts.map +0 -1
- package/dist/toolkits/mathematics/tools/calculate-product.js.map +0 -1
- package/dist/toolkits/mathematics/tools/calculate-quadratic-roots.d.ts.map +0 -1
- package/dist/toolkits/mathematics/tools/calculate-quadratic-roots.js.map +0 -1
- package/dist/toolkits/mathematics/tools/calculate-statistics.d.ts.map +0 -1
- package/dist/toolkits/mathematics/tools/calculate-statistics.js.map +0 -1
- package/dist/toolkits/mathematics/tools/calculate-sum.d.ts.map +0 -1
- package/dist/toolkits/mathematics/tools/calculate-sum.js.map +0 -1
- package/dist/toolkits/mathematics/tools/get-random-number.d.ts.map +0 -1
- package/dist/toolkits/mathematics/tools/get-random-number.js.map +0 -1
- package/dist/toolkits/mathematics/tools/solve-linear-equations.d.ts.map +0 -1
- package/dist/toolkits/mathematics/tools/solve-linear-equations.js.map +0 -1
- package/dist/toolkits/web-search/icon.d.ts.map +0 -1
- package/dist/toolkits/web-search/icon.js.map +0 -1
- package/dist/toolkits/web-search/manifest.d.ts.map +0 -1
- package/dist/toolkits/web-search/manifest.js.map +0 -1
- package/dist/toolkits/web-search/tools/firecrawl-client.d.ts.map +0 -1
- package/dist/toolkits/web-search/tools/firecrawl-client.js.map +0 -1
- package/dist/toolkits/web-search/tools/web-scrape.d.ts.map +0 -1
- package/dist/toolkits/web-search/tools/web-scrape.js.map +0 -1
- package/dist/toolkits/web-search/tools/web-search.d.ts.map +0 -1
- package/dist/toolkits/web-search/tools/web-search.js.map +0 -1
package/dist/core/index.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
export { CONNECTOR_CATEGORIES, type ConnectorCategory } from './categories.js';
|
|
2
2
|
export { defineToolkit, defineTool, toolkitCamelId } from './define.js';
|
|
3
|
+
export { inferToolScope } from './scope.js';
|
|
3
4
|
export { validateManifests, getAuthType, } from './validate.js';
|
|
4
5
|
export type { ToolkitManifest, ToolDefinition, ToolkitIcon, ToolkitAuthSpec, ToolkitAuthType, ToolScope, OAuthProviderSpec, EnvVarSpec, ToolkitAvailability, } from './types.js';
|
|
5
6
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/core/index.js
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
export { CONNECTOR_CATEGORIES } from './categories.js';
|
|
2
2
|
export { defineToolkit, defineTool, toolkitCamelId } from './define.js';
|
|
3
|
+
export { inferToolScope } from './scope.js';
|
|
3
4
|
export { validateManifests, getAuthType, } from './validate.js';
|
|
4
5
|
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/** Heuristic scope inference for migrated tools; explicit scope in manifests is preferred. */
|
|
2
|
+
export function inferToolScope(name) {
|
|
3
|
+
const normalized = name.toLowerCase();
|
|
4
|
+
if (/^(delete|remove|unfollow|unstar|destroy|revoke|cancel)/.test(normalized)) {
|
|
5
|
+
return 'delete';
|
|
6
|
+
}
|
|
7
|
+
if (/^(create|add|update|send|post|put|patch|trigger|generate|follow|star|merge|approve|dispatch|set|invite|assign|upload|publish|enable|disable|lock|unlock|rerun|reopen|close|append|fork|watch)/.test(normalized)) {
|
|
8
|
+
return 'write';
|
|
9
|
+
}
|
|
10
|
+
return 'read';
|
|
11
|
+
}
|
|
12
|
+
//# sourceMappingURL=scope.js.map
|
package/dist/index.d.ts
CHANGED
|
@@ -2,9 +2,13 @@ import mathematics from './toolkits/mathematics/manifest.js';
|
|
|
2
2
|
import linear from './toolkits/linear/manifest.js';
|
|
3
3
|
import gmail from './toolkits/gmail/manifest.js';
|
|
4
4
|
import webSearch from './toolkits/web-search/manifest.js';
|
|
5
|
+
import github from './toolkits/github/manifest.js';
|
|
6
|
+
import notion from './toolkits/notion/manifest.js';
|
|
7
|
+
import googleCalendar from './toolkits/google-calendar/manifest.js';
|
|
8
|
+
import googleSheets from './toolkits/google-sheets/manifest.js';
|
|
5
9
|
import type { ToolkitManifest } from './core/types.js';
|
|
6
10
|
export declare const toolkits: ToolkitManifest[];
|
|
7
|
-
export { mathematics, linear, gmail, webSearch };
|
|
11
|
+
export { mathematics, linear, gmail, webSearch, github, notion, googleCalendar, googleSheets, };
|
|
8
12
|
export * from './core/index.js';
|
|
9
13
|
export * from './runtime/index.js';
|
|
10
14
|
export declare function getAllTools(): {
|
package/dist/index.js
CHANGED
|
@@ -2,8 +2,21 @@ import mathematics from './toolkits/mathematics/manifest.js';
|
|
|
2
2
|
import linear from './toolkits/linear/manifest.js';
|
|
3
3
|
import gmail from './toolkits/gmail/manifest.js';
|
|
4
4
|
import webSearch from './toolkits/web-search/manifest.js';
|
|
5
|
-
|
|
6
|
-
|
|
5
|
+
import github from './toolkits/github/manifest.js';
|
|
6
|
+
import notion from './toolkits/notion/manifest.js';
|
|
7
|
+
import googleCalendar from './toolkits/google-calendar/manifest.js';
|
|
8
|
+
import googleSheets from './toolkits/google-sheets/manifest.js';
|
|
9
|
+
export const toolkits = [
|
|
10
|
+
mathematics,
|
|
11
|
+
linear,
|
|
12
|
+
gmail,
|
|
13
|
+
webSearch,
|
|
14
|
+
github,
|
|
15
|
+
notion,
|
|
16
|
+
googleCalendar,
|
|
17
|
+
googleSheets,
|
|
18
|
+
];
|
|
19
|
+
export { mathematics, linear, gmail, webSearch, github, notion, googleCalendar, googleSheets, };
|
|
7
20
|
export * from './core/index.js';
|
|
8
21
|
export * from './runtime/index.js';
|
|
9
22
|
export function getAllTools() {
|
|
@@ -199,6 +199,7 @@ export function createMetaTools({ registry, credentials, hooks = {} }) {
|
|
|
199
199
|
const result = await toolInstance.execute(argsWithToken);
|
|
200
200
|
return sanitizeToolPayload({
|
|
201
201
|
toolName,
|
|
202
|
+
toolkitId: toolMetadata.toolkitId,
|
|
202
203
|
success: true,
|
|
203
204
|
result: sanitizeToolResult(result),
|
|
204
205
|
});
|
|
@@ -225,6 +226,7 @@ export function createMetaTools({ registry, credentials, hooks = {} }) {
|
|
|
225
226
|
const result = await toolInstance.execute(argsWithToken);
|
|
226
227
|
return sanitizeToolPayload({
|
|
227
228
|
toolName,
|
|
229
|
+
toolkitId: toolMetadata.toolkitId,
|
|
228
230
|
success: true,
|
|
229
231
|
result: sanitizeToolResult(result),
|
|
230
232
|
});
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
const SVG = `<svg width="98" height="96" viewBox="0 0 98 96" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<g clipPath="url(#clip0_730_27126)">
|
|
3
|
+
<path d="M41.4395 69.3848C28.8066 67.8535 19.9062 58.7617 19.9062 46.9902C19.9062 42.2051 21.6289 37.0371 24.5 33.5918C23.2559 30.4336 23.4473 23.7344 24.8828 20.959C28.7109 20.4805 33.8789 22.4902 36.9414 25.2656C40.5781 24.1172 44.4062 23.543 49.0957 23.543C53.7852 23.543 57.6133 24.1172 61.0586 25.1699C64.0254 22.4902 69.2891 20.4805 73.1172 20.959C74.457 23.543 74.6484 30.2422 73.4043 33.4961C76.4668 37.1328 78.0937 42.0137 78.0937 46.9902C78.0937 58.7617 69.1934 67.6621 56.3691 69.2891C59.623 71.3945 61.8242 75.9883 61.8242 81.252L61.8242 91.2051C61.8242 94.0762 64.2168 95.7031 67.0879 94.5547C84.4102 87.9512 98 70.6289 98 49.1914C98 22.1074 75.9883 6.69539e-07 48.9043 4.309e-07C21.8203 1.92261e-07 -1.9479e-07 22.1074 -4.3343e-07 49.1914C-6.20631e-07 70.4375 13.4941 88.0469 31.6777 94.6504C34.2617 95.6074 36.75 93.8848 36.75 91.3008L36.75 83.6445C35.4102 84.2188 33.6875 84.6016 32.1562 84.6016C25.8398 84.6016 22.1074 81.1563 19.4277 74.7441C18.375 72.1602 17.2266 70.6289 15.0254 70.3418C13.877 70.2461 13.4941 69.7676 13.4941 69.1934C13.4941 68.0449 15.4082 67.1836 17.3223 67.1836C20.0977 67.1836 22.4902 68.9063 24.9785 72.4473C26.8926 75.2227 28.9023 76.4668 31.2949 76.4668C33.6875 76.4668 35.2187 75.6055 37.4199 73.4043C39.0469 71.7773 40.291 70.3418 41.4395 69.3848Z" fill="black"/>
|
|
4
|
+
</g>
|
|
5
|
+
<defs>
|
|
6
|
+
<clipPath id="clip0_730_27126">
|
|
7
|
+
<rect width="98" height="96" fill="white"/>
|
|
8
|
+
</clipPath>
|
|
9
|
+
</defs>
|
|
10
|
+
</svg>`;
|
|
11
|
+
export const GITHUB_ICON = {
|
|
12
|
+
kind: 'svg',
|
|
13
|
+
dataUri: `data:image/svg+xml;base64,${Buffer.from(SVG).toString('base64')}`,
|
|
14
|
+
};
|
|
15
|
+
//# sourceMappingURL=icon.js.map
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { defineToolkit, defineTool } from '../../core/define.js';
|
|
2
|
+
import { inferToolScope } from '../../core/scope.js';
|
|
3
|
+
import { GITHUB_ICON } from './icon.js';
|
|
4
|
+
import { githubTools } from './tools/index.js';
|
|
5
|
+
export default defineToolkit({
|
|
6
|
+
id: 'github',
|
|
7
|
+
displayName: 'GitHub',
|
|
8
|
+
shortDescription: 'Repositories, issues, pull requests, actions, and more.',
|
|
9
|
+
category: 'Developer Tools & DevOps',
|
|
10
|
+
icon: GITHUB_ICON,
|
|
11
|
+
auth: {
|
|
12
|
+
type: 'oauth2',
|
|
13
|
+
tokenField: 'githubToken',
|
|
14
|
+
provider: {
|
|
15
|
+
slug: 'github',
|
|
16
|
+
env: { clientId: 'GITHUB_CLIENT_ID', clientSecret: 'GITHUB_CLIENT_SECRET' },
|
|
17
|
+
authorizeUrl: 'https://github.com/login/oauth/authorize',
|
|
18
|
+
tokenUrl: 'https://github.com/login/oauth/access_token',
|
|
19
|
+
scopes: ['repo', 'read:user'],
|
|
20
|
+
exchangeStyle: 'json',
|
|
21
|
+
connectDescription: 'Connect GitHub to access repositories, issues, pull requests, and actions.',
|
|
22
|
+
callbackPath: '/api/auth/github/callback',
|
|
23
|
+
stateCookie: 'github_oauth_state',
|
|
24
|
+
},
|
|
25
|
+
},
|
|
26
|
+
allowedHosts: ['api.github.com'],
|
|
27
|
+
tools: githubTools.map((entry) => defineTool({
|
|
28
|
+
name: entry.name,
|
|
29
|
+
description: entry.description,
|
|
30
|
+
tool: entry.tool,
|
|
31
|
+
requiredAuth: entry.requiredAuth,
|
|
32
|
+
scope: inferToolScope(entry.name),
|
|
33
|
+
})),
|
|
34
|
+
meta: { since: '0.0.2' },
|
|
35
|
+
});
|
|
36
|
+
//# sourceMappingURL=manifest.js.map
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
export declare const deleteArtifact: import("ai").Tool<{
|
|
2
|
+
repo: string;
|
|
3
|
+
owner: string;
|
|
4
|
+
artifact_id: number;
|
|
5
|
+
githubToken?: string | undefined;
|
|
6
|
+
}, {
|
|
7
|
+
error: string;
|
|
8
|
+
message?: undefined;
|
|
9
|
+
} | {
|
|
10
|
+
message: string;
|
|
11
|
+
error?: undefined;
|
|
12
|
+
}>;
|
|
13
|
+
//# sourceMappingURL=delete-artifact.d.ts.map
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
// @ts-nocheck
|
|
2
|
+
import { tool } from 'ai';
|
|
3
|
+
import { z } from 'zod';
|
|
4
|
+
import { Octokit } from 'octokit';
|
|
5
|
+
export const deleteArtifact = tool({
|
|
6
|
+
description: 'Delete an artifact from a GitHub repository.',
|
|
7
|
+
inputSchema: z.object({
|
|
8
|
+
githubToken: z.string().optional().describe('Injected by system; do not provide'),
|
|
9
|
+
owner: z.string().describe('Repository owner (username or org)'),
|
|
10
|
+
repo: z.string().describe('Repository name'),
|
|
11
|
+
artifact_id: z.number().describe('The unique identifier of the artifact to delete'),
|
|
12
|
+
}),
|
|
13
|
+
execute: async ({ githubToken, owner, repo, artifact_id }) => {
|
|
14
|
+
if (!githubToken) {
|
|
15
|
+
return { error: 'GitHub token is required. Connect GitHub first.' };
|
|
16
|
+
}
|
|
17
|
+
const octokit = new Octokit({ auth: githubToken });
|
|
18
|
+
try {
|
|
19
|
+
await octokit.rest.actions.deleteArtifact({
|
|
20
|
+
owner,
|
|
21
|
+
repo,
|
|
22
|
+
artifact_id,
|
|
23
|
+
});
|
|
24
|
+
return { message: `Successfully deleted artifact ${artifact_id}` };
|
|
25
|
+
}
|
|
26
|
+
catch (error) {
|
|
27
|
+
return { error: `Failed to delete artifact: ${error.message}` };
|
|
28
|
+
}
|
|
29
|
+
},
|
|
30
|
+
});
|
|
31
|
+
//# sourceMappingURL=delete-artifact.js.map
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
export declare const getArtifact: import("ai").Tool<{
|
|
2
|
+
repo: string;
|
|
3
|
+
owner: string;
|
|
4
|
+
artifact_id: number;
|
|
5
|
+
githubToken?: string | undefined;
|
|
6
|
+
}, {
|
|
7
|
+
error: string;
|
|
8
|
+
id?: undefined;
|
|
9
|
+
name?: undefined;
|
|
10
|
+
size_in_bytes?: undefined;
|
|
11
|
+
created_at?: undefined;
|
|
12
|
+
expired?: undefined;
|
|
13
|
+
expires_at?: undefined;
|
|
14
|
+
workflow_run?: undefined;
|
|
15
|
+
} | {
|
|
16
|
+
id: number;
|
|
17
|
+
name: string;
|
|
18
|
+
size_in_bytes: number;
|
|
19
|
+
created_at: string | null;
|
|
20
|
+
expired: boolean;
|
|
21
|
+
expires_at: string | null;
|
|
22
|
+
workflow_run: {
|
|
23
|
+
id?: number;
|
|
24
|
+
repository_id?: number;
|
|
25
|
+
head_repository_id?: number;
|
|
26
|
+
head_branch?: string;
|
|
27
|
+
head_sha?: string;
|
|
28
|
+
} | null | undefined;
|
|
29
|
+
error?: undefined;
|
|
30
|
+
}>;
|
|
31
|
+
//# sourceMappingURL=get-artifact.d.ts.map
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
// @ts-nocheck
|
|
2
|
+
import { tool } from 'ai';
|
|
3
|
+
import { z } from 'zod';
|
|
4
|
+
import { Octokit } from 'octokit';
|
|
5
|
+
export const getArtifact = tool({
|
|
6
|
+
description: 'Get a specific artifact from a GitHub repository by its ID.',
|
|
7
|
+
inputSchema: z.object({
|
|
8
|
+
githubToken: z.string().optional().describe('Injected by system; do not provide'),
|
|
9
|
+
owner: z.string().describe('Repository owner (username or org)'),
|
|
10
|
+
repo: z.string().describe('Repository name'),
|
|
11
|
+
artifact_id: z.number().describe('The unique identifier of the artifact'),
|
|
12
|
+
}),
|
|
13
|
+
execute: async ({ githubToken, owner, repo, artifact_id }) => {
|
|
14
|
+
if (!githubToken) {
|
|
15
|
+
return { error: 'GitHub token is required. Connect GitHub first.' };
|
|
16
|
+
}
|
|
17
|
+
const octokit = new Octokit({ auth: githubToken });
|
|
18
|
+
try {
|
|
19
|
+
const { data } = await octokit.rest.actions.getArtifact({
|
|
20
|
+
owner,
|
|
21
|
+
repo,
|
|
22
|
+
artifact_id,
|
|
23
|
+
});
|
|
24
|
+
return {
|
|
25
|
+
id: data.id,
|
|
26
|
+
name: data.name,
|
|
27
|
+
size_in_bytes: data.size_in_bytes,
|
|
28
|
+
created_at: data.created_at,
|
|
29
|
+
expired: data.expired,
|
|
30
|
+
expires_at: data.expires_at,
|
|
31
|
+
workflow_run: data.workflow_run,
|
|
32
|
+
};
|
|
33
|
+
}
|
|
34
|
+
catch (error) {
|
|
35
|
+
return { error: `Failed to get artifact: ${error.message}` };
|
|
36
|
+
}
|
|
37
|
+
},
|
|
38
|
+
});
|
|
39
|
+
//# sourceMappingURL=get-artifact.js.map
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
export declare const getWorkflowJob: import("ai").Tool<{
|
|
2
|
+
repo: string;
|
|
3
|
+
owner: string;
|
|
4
|
+
job_id: number;
|
|
5
|
+
githubToken?: string | undefined;
|
|
6
|
+
}, {
|
|
7
|
+
error: string;
|
|
8
|
+
id?: undefined;
|
|
9
|
+
run_id?: undefined;
|
|
10
|
+
name?: undefined;
|
|
11
|
+
status?: undefined;
|
|
12
|
+
conclusion?: undefined;
|
|
13
|
+
started_at?: undefined;
|
|
14
|
+
completed_at?: undefined;
|
|
15
|
+
html_url?: undefined;
|
|
16
|
+
steps?: undefined;
|
|
17
|
+
} | {
|
|
18
|
+
id: number;
|
|
19
|
+
run_id: number;
|
|
20
|
+
name: string;
|
|
21
|
+
status: "queued" | "in_progress" | "completed" | "waiting" | "requested" | "pending";
|
|
22
|
+
conclusion: "success" | "failure" | "neutral" | "cancelled" | "skipped" | "timed_out" | "action_required" | null;
|
|
23
|
+
started_at: string;
|
|
24
|
+
completed_at: string | null;
|
|
25
|
+
html_url: string | null;
|
|
26
|
+
steps: {
|
|
27
|
+
name: string;
|
|
28
|
+
status: "queued" | "in_progress" | "completed";
|
|
29
|
+
conclusion: string | null;
|
|
30
|
+
number: number;
|
|
31
|
+
started_at: string | null | undefined;
|
|
32
|
+
completed_at: string | null | undefined;
|
|
33
|
+
}[] | undefined;
|
|
34
|
+
error?: undefined;
|
|
35
|
+
}>;
|
|
36
|
+
//# sourceMappingURL=get-workflow-job.d.ts.map
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
// @ts-nocheck
|
|
2
|
+
import { tool } from 'ai';
|
|
3
|
+
import { z } from 'zod';
|
|
4
|
+
import { Octokit } from 'octokit';
|
|
5
|
+
export const getWorkflowJob = tool({
|
|
6
|
+
description: 'Get a specific job for a workflow run. Returns detailed job information including steps.',
|
|
7
|
+
inputSchema: z.object({
|
|
8
|
+
githubToken: z.string().optional().describe('Injected by system; do not provide'),
|
|
9
|
+
owner: z.string().describe('Repository owner (username or org)'),
|
|
10
|
+
repo: z.string().describe('Repository name'),
|
|
11
|
+
job_id: z.number().describe('The unique identifier of the job'),
|
|
12
|
+
}),
|
|
13
|
+
execute: async ({ githubToken, owner, repo, job_id }) => {
|
|
14
|
+
if (!githubToken) {
|
|
15
|
+
return { error: 'GitHub token is required. Connect GitHub first.' };
|
|
16
|
+
}
|
|
17
|
+
const octokit = new Octokit({ auth: githubToken });
|
|
18
|
+
try {
|
|
19
|
+
const { data } = await octokit.rest.actions.getJobForWorkflowRun({
|
|
20
|
+
owner,
|
|
21
|
+
repo,
|
|
22
|
+
job_id,
|
|
23
|
+
});
|
|
24
|
+
return {
|
|
25
|
+
id: data.id,
|
|
26
|
+
run_id: data.run_id,
|
|
27
|
+
name: data.name,
|
|
28
|
+
status: data.status,
|
|
29
|
+
conclusion: data.conclusion,
|
|
30
|
+
started_at: data.started_at,
|
|
31
|
+
completed_at: data.completed_at,
|
|
32
|
+
html_url: data.html_url,
|
|
33
|
+
steps: data.steps?.map(step => ({
|
|
34
|
+
name: step.name,
|
|
35
|
+
status: step.status,
|
|
36
|
+
conclusion: step.conclusion,
|
|
37
|
+
number: step.number,
|
|
38
|
+
started_at: step.started_at,
|
|
39
|
+
completed_at: step.completed_at,
|
|
40
|
+
})),
|
|
41
|
+
};
|
|
42
|
+
}
|
|
43
|
+
catch (error) {
|
|
44
|
+
return { error: `Failed to get workflow job: ${error.message}` };
|
|
45
|
+
}
|
|
46
|
+
},
|
|
47
|
+
});
|
|
48
|
+
//# sourceMappingURL=get-workflow-job.js.map
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
export declare const listArtifacts: import("ai").Tool<{
|
|
2
|
+
repo: string;
|
|
3
|
+
owner: string;
|
|
4
|
+
githubToken?: string | undefined;
|
|
5
|
+
per_page?: number | undefined;
|
|
6
|
+
page?: number | undefined;
|
|
7
|
+
}, {
|
|
8
|
+
error: string;
|
|
9
|
+
total_count?: undefined;
|
|
10
|
+
artifacts?: undefined;
|
|
11
|
+
} | {
|
|
12
|
+
total_count: number;
|
|
13
|
+
artifacts: {
|
|
14
|
+
id: number;
|
|
15
|
+
name: string;
|
|
16
|
+
size_in_bytes: number;
|
|
17
|
+
created_at: string | null;
|
|
18
|
+
expired: boolean;
|
|
19
|
+
expires_at: string | null;
|
|
20
|
+
}[];
|
|
21
|
+
error?: undefined;
|
|
22
|
+
}>;
|
|
23
|
+
//# sourceMappingURL=list-artifacts.d.ts.map
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
// @ts-nocheck
|
|
2
|
+
import { tool } from 'ai';
|
|
3
|
+
import { z } from 'zod';
|
|
4
|
+
import { Octokit } from 'octokit';
|
|
5
|
+
export const listArtifacts = tool({
|
|
6
|
+
description: 'List artifacts for a GitHub repository. Returns workflow run artifacts with their names, sizes, and download URLs.',
|
|
7
|
+
inputSchema: z.object({
|
|
8
|
+
githubToken: z.string().optional().describe('Injected by system; do not provide'),
|
|
9
|
+
owner: z.string().describe('Repository owner (username or org)'),
|
|
10
|
+
repo: z.string().describe('Repository name'),
|
|
11
|
+
per_page: z.number().optional().describe('Number of results per page (max 100)'),
|
|
12
|
+
page: z.number().optional().describe('Page number of results to fetch'),
|
|
13
|
+
}),
|
|
14
|
+
execute: async ({ githubToken, owner, repo, per_page, page }) => {
|
|
15
|
+
if (!githubToken) {
|
|
16
|
+
return { error: 'GitHub token is required. Connect GitHub first.' };
|
|
17
|
+
}
|
|
18
|
+
const octokit = new Octokit({ auth: githubToken });
|
|
19
|
+
try {
|
|
20
|
+
const { data } = await octokit.rest.actions.listArtifactsForRepo({
|
|
21
|
+
owner,
|
|
22
|
+
repo,
|
|
23
|
+
per_page: per_page ?? 30,
|
|
24
|
+
page: page ?? 1,
|
|
25
|
+
});
|
|
26
|
+
return {
|
|
27
|
+
total_count: data.total_count,
|
|
28
|
+
artifacts: data.artifacts.map(artifact => ({
|
|
29
|
+
id: artifact.id,
|
|
30
|
+
name: artifact.name,
|
|
31
|
+
size_in_bytes: artifact.size_in_bytes,
|
|
32
|
+
created_at: artifact.created_at,
|
|
33
|
+
expired: artifact.expired,
|
|
34
|
+
expires_at: artifact.expires_at,
|
|
35
|
+
})),
|
|
36
|
+
};
|
|
37
|
+
}
|
|
38
|
+
catch (error) {
|
|
39
|
+
return { error: `Failed to list artifacts: ${error.message}` };
|
|
40
|
+
}
|
|
41
|
+
},
|
|
42
|
+
});
|
|
43
|
+
//# sourceMappingURL=list-artifacts.js.map
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
export declare const listWorkflowJobs: import("ai").Tool<{
|
|
2
|
+
repo: string;
|
|
3
|
+
owner: string;
|
|
4
|
+
run_id: number;
|
|
5
|
+
filter?: "latest" | "all" | undefined;
|
|
6
|
+
githubToken?: string | undefined;
|
|
7
|
+
per_page?: number | undefined;
|
|
8
|
+
page?: number | undefined;
|
|
9
|
+
}, {
|
|
10
|
+
error: string;
|
|
11
|
+
total_count?: undefined;
|
|
12
|
+
jobs?: undefined;
|
|
13
|
+
} | {
|
|
14
|
+
total_count: number;
|
|
15
|
+
jobs: {
|
|
16
|
+
id: number;
|
|
17
|
+
run_id: number;
|
|
18
|
+
name: string;
|
|
19
|
+
status: "queued" | "in_progress" | "completed" | "waiting" | "requested" | "pending";
|
|
20
|
+
conclusion: "success" | "failure" | "neutral" | "cancelled" | "skipped" | "timed_out" | "action_required" | null;
|
|
21
|
+
started_at: string;
|
|
22
|
+
completed_at: string | null;
|
|
23
|
+
html_url: string | null;
|
|
24
|
+
}[];
|
|
25
|
+
error?: undefined;
|
|
26
|
+
}>;
|
|
27
|
+
//# sourceMappingURL=list-workflow-jobs.d.ts.map
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
// @ts-nocheck
|
|
2
|
+
import { tool } from 'ai';
|
|
3
|
+
import { z } from 'zod';
|
|
4
|
+
import { Octokit } from 'octokit';
|
|
5
|
+
export const listWorkflowJobs = tool({
|
|
6
|
+
description: 'List jobs for a workflow run. Returns job details including status, conclusion, and steps.',
|
|
7
|
+
inputSchema: z.object({
|
|
8
|
+
githubToken: z.string().optional().describe('Injected by system; do not provide'),
|
|
9
|
+
owner: z.string().describe('Repository owner (username or org)'),
|
|
10
|
+
repo: z.string().describe('Repository name'),
|
|
11
|
+
run_id: z.number().describe('The unique identifier of the workflow run'),
|
|
12
|
+
filter: z.enum(['latest', 'all']).optional().describe('Filter jobs by latest or all attempts'),
|
|
13
|
+
per_page: z.number().optional().describe('Number of results per page (max 100)'),
|
|
14
|
+
page: z.number().optional().describe('Page number of results to fetch'),
|
|
15
|
+
}),
|
|
16
|
+
execute: async ({ githubToken, owner, repo, run_id, filter, per_page, page }) => {
|
|
17
|
+
if (!githubToken) {
|
|
18
|
+
return { error: 'GitHub token is required. Connect GitHub first.' };
|
|
19
|
+
}
|
|
20
|
+
const octokit = new Octokit({ auth: githubToken });
|
|
21
|
+
try {
|
|
22
|
+
const { data } = await octokit.rest.actions.listJobsForWorkflowRun({
|
|
23
|
+
owner,
|
|
24
|
+
repo,
|
|
25
|
+
run_id,
|
|
26
|
+
filter: filter ?? 'latest',
|
|
27
|
+
per_page: per_page ?? 30,
|
|
28
|
+
page: page ?? 1,
|
|
29
|
+
});
|
|
30
|
+
return {
|
|
31
|
+
total_count: data.total_count,
|
|
32
|
+
jobs: data.jobs.map(job => ({
|
|
33
|
+
id: job.id,
|
|
34
|
+
run_id: job.run_id,
|
|
35
|
+
name: job.name,
|
|
36
|
+
status: job.status,
|
|
37
|
+
conclusion: job.conclusion,
|
|
38
|
+
started_at: job.started_at,
|
|
39
|
+
completed_at: job.completed_at,
|
|
40
|
+
html_url: job.html_url,
|
|
41
|
+
})),
|
|
42
|
+
};
|
|
43
|
+
}
|
|
44
|
+
catch (error) {
|
|
45
|
+
return { error: `Failed to list workflow jobs: ${error.message}` };
|
|
46
|
+
}
|
|
47
|
+
},
|
|
48
|
+
});
|
|
49
|
+
//# sourceMappingURL=list-workflow-jobs.js.map
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
export declare const listWorkflowRunArtifacts: import("ai").Tool<{
|
|
2
|
+
repo: string;
|
|
3
|
+
owner: string;
|
|
4
|
+
run_id: number;
|
|
5
|
+
githubToken?: string | undefined;
|
|
6
|
+
per_page?: number | undefined;
|
|
7
|
+
page?: number | undefined;
|
|
8
|
+
}, {
|
|
9
|
+
error: string;
|
|
10
|
+
total_count?: undefined;
|
|
11
|
+
artifacts?: undefined;
|
|
12
|
+
} | {
|
|
13
|
+
total_count: number;
|
|
14
|
+
artifacts: {
|
|
15
|
+
id: number;
|
|
16
|
+
name: string;
|
|
17
|
+
size_in_bytes: number;
|
|
18
|
+
created_at: string | null;
|
|
19
|
+
expired: boolean;
|
|
20
|
+
expires_at: string | null;
|
|
21
|
+
}[];
|
|
22
|
+
error?: undefined;
|
|
23
|
+
}>;
|
|
24
|
+
//# sourceMappingURL=list-workflow-run-artifacts.d.ts.map
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
// @ts-nocheck
|
|
2
|
+
import { tool } from 'ai';
|
|
3
|
+
import { z } from 'zod';
|
|
4
|
+
import { Octokit } from 'octokit';
|
|
5
|
+
export const listWorkflowRunArtifacts = tool({
|
|
6
|
+
description: 'List artifacts for a specific workflow run.',
|
|
7
|
+
inputSchema: z.object({
|
|
8
|
+
githubToken: z.string().optional().describe('Injected by system; do not provide'),
|
|
9
|
+
owner: z.string().describe('Repository owner (username or org)'),
|
|
10
|
+
repo: z.string().describe('Repository name'),
|
|
11
|
+
run_id: z.number().describe('The unique identifier of the workflow run'),
|
|
12
|
+
per_page: z.number().optional().describe('Number of results per page (max 100)'),
|
|
13
|
+
page: z.number().optional().describe('Page number of results to fetch'),
|
|
14
|
+
}),
|
|
15
|
+
execute: async ({ githubToken, owner, repo, run_id, per_page, page }) => {
|
|
16
|
+
if (!githubToken) {
|
|
17
|
+
return { error: 'GitHub token is required. Connect GitHub first.' };
|
|
18
|
+
}
|
|
19
|
+
const octokit = new Octokit({ auth: githubToken });
|
|
20
|
+
try {
|
|
21
|
+
const { data } = await octokit.rest.actions.listWorkflowRunArtifacts({
|
|
22
|
+
owner,
|
|
23
|
+
repo,
|
|
24
|
+
run_id,
|
|
25
|
+
per_page: per_page ?? 30,
|
|
26
|
+
page: page ?? 1,
|
|
27
|
+
});
|
|
28
|
+
return {
|
|
29
|
+
total_count: data.total_count,
|
|
30
|
+
artifacts: data.artifacts.map(artifact => ({
|
|
31
|
+
id: artifact.id,
|
|
32
|
+
name: artifact.name,
|
|
33
|
+
size_in_bytes: artifact.size_in_bytes,
|
|
34
|
+
created_at: artifact.created_at,
|
|
35
|
+
expired: artifact.expired,
|
|
36
|
+
expires_at: artifact.expires_at,
|
|
37
|
+
})),
|
|
38
|
+
};
|
|
39
|
+
}
|
|
40
|
+
catch (error) {
|
|
41
|
+
return { error: `Failed to list workflow run artifacts: ${error.message}` };
|
|
42
|
+
}
|
|
43
|
+
},
|
|
44
|
+
});
|
|
45
|
+
//# sourceMappingURL=list-workflow-run-artifacts.js.map
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
export declare const listNotifications: import("ai").Tool<{
|
|
2
|
+
githubToken?: string | undefined;
|
|
3
|
+
per_page?: number | undefined;
|
|
4
|
+
page?: number | undefined;
|
|
5
|
+
all?: boolean | undefined;
|
|
6
|
+
participating?: boolean | undefined;
|
|
7
|
+
}, {
|
|
8
|
+
error: string;
|
|
9
|
+
notifications?: undefined;
|
|
10
|
+
} | {
|
|
11
|
+
notifications: {
|
|
12
|
+
id: string;
|
|
13
|
+
repository: string;
|
|
14
|
+
subject: {
|
|
15
|
+
title: string;
|
|
16
|
+
type: string;
|
|
17
|
+
};
|
|
18
|
+
reason: string;
|
|
19
|
+
unread: boolean;
|
|
20
|
+
updated_at: string;
|
|
21
|
+
}[];
|
|
22
|
+
error?: undefined;
|
|
23
|
+
}>;
|
|
24
|
+
//# sourceMappingURL=list-notifications.d.ts.map
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
// @ts-nocheck
|
|
2
|
+
import { tool } from 'ai';
|
|
3
|
+
import { z } from 'zod';
|
|
4
|
+
import { Octokit } from 'octokit';
|
|
5
|
+
export const listNotifications = tool({
|
|
6
|
+
description: 'List notifications for the authenticated user. Returns unread notifications by default.',
|
|
7
|
+
inputSchema: z.object({
|
|
8
|
+
githubToken: z.string().optional().describe('Injected by system; do not provide'),
|
|
9
|
+
all: z.boolean().optional().describe('If true, show notifications marked as read'),
|
|
10
|
+
participating: z.boolean().optional().describe('If true, only show notifications in which the user is directly participating'),
|
|
11
|
+
per_page: z.number().optional().describe('Number of results per page (max 100)'),
|
|
12
|
+
page: z.number().optional().describe('Page number of results to fetch'),
|
|
13
|
+
}),
|
|
14
|
+
execute: async ({ githubToken, all, participating, per_page, page }) => {
|
|
15
|
+
if (!githubToken) {
|
|
16
|
+
return { error: 'GitHub token is required. Connect GitHub first.' };
|
|
17
|
+
}
|
|
18
|
+
const octokit = new Octokit({ auth: githubToken });
|
|
19
|
+
try {
|
|
20
|
+
const { data } = await octokit.rest.activity.listNotificationsForAuthenticatedUser({
|
|
21
|
+
all: all ?? false,
|
|
22
|
+
participating: participating ?? false,
|
|
23
|
+
per_page: per_page ?? 30,
|
|
24
|
+
page: page ?? 1,
|
|
25
|
+
});
|
|
26
|
+
return {
|
|
27
|
+
notifications: data.map(notification => ({
|
|
28
|
+
id: notification.id,
|
|
29
|
+
repository: notification.repository?.full_name,
|
|
30
|
+
subject: {
|
|
31
|
+
title: notification.subject?.title,
|
|
32
|
+
type: notification.subject?.type,
|
|
33
|
+
},
|
|
34
|
+
reason: notification.reason,
|
|
35
|
+
unread: notification.unread,
|
|
36
|
+
updated_at: notification.updated_at,
|
|
37
|
+
})),
|
|
38
|
+
};
|
|
39
|
+
}
|
|
40
|
+
catch (error) {
|
|
41
|
+
return { error: `Failed to list notifications: ${error.message}` };
|
|
42
|
+
}
|
|
43
|
+
},
|
|
44
|
+
});
|
|
45
|
+
//# sourceMappingURL=list-notifications.js.map
|