|
| 1 | +import { AdminConnectAccountTool } from './tools/admin-connect-account.js'; |
| 2 | +import { AdminDisconnectAccountTool } from './tools/admin-disconnect-account.js'; |
| 3 | +import { AdminGetAccountsTool } from './tools/admin-get-accounts.js'; |
| 4 | +import { AdminGetLimitsUsageTool } from './tools/admin-get-limits-usage.js'; |
| 5 | +import { AdminGetSeatsTool } from './tools/admin-get-seats.js'; |
| 6 | +import { AdminGetSubscriptionStatusTool } from './tools/admin-get-subscription-status.js'; |
| 7 | +import { AdminRegenerateTokenTool } from './tools/admin-regenerate-token.js'; |
| 8 | +import { AdminResetLimitsTool } from './tools/admin-reset-limits.js'; |
| 9 | +import { AdminSetLimitsTool } from './tools/admin-set-limits.js'; |
| 10 | +import { AdminSetSeatsTool } from './tools/admin-set-seats.js'; |
1 | 11 | import { CheckConnectionStatusTool } from './tools/check-connection-status.js'; |
2 | 12 | import { CommentOnPostTool } from './tools/comment-on-post.js'; |
3 | 13 | import { CreatePostTool } from './tools/create-post.js'; |
@@ -25,11 +35,13 @@ import { SearchPeopleTool } from './tools/search-people.js'; |
25 | 35 | import { SendConnectionRequestTool } from './tools/send-connection-request.js'; |
26 | 36 | import { SendMessageTool } from './tools/send-message.js'; |
27 | 37 | import { WithdrawConnectionRequestTool } from './tools/withdraw-connection-request.js'; |
| 38 | +import { AdminTool } from './utils/admin-tool.js'; |
28 | 39 | import { LinkedApiTool } from './utils/linked-api-tool.js'; |
29 | 40 | import { LinkedApiProgressNotification } from './utils/types.js'; |
30 | 41 |
|
31 | 42 | export class LinkedApiTools { |
32 | 43 | public readonly tools: ReadonlyArray<LinkedApiTool<unknown, unknown>>; |
| 44 | + public readonly adminTools: ReadonlyArray<AdminTool<unknown, unknown>>; |
33 | 45 |
|
34 | 46 | constructor(progressCallback: (progress: LinkedApiProgressNotification) => void) { |
35 | 47 | this.tools = [ |
@@ -64,9 +76,26 @@ export class LinkedApiTools { |
64 | 76 | new GetWorkflowResultTool(progressCallback), |
65 | 77 | new GetApiUsageTool(progressCallback), |
66 | 78 | ]; |
| 79 | + |
| 80 | + this.adminTools = [ |
| 81 | + new AdminGetSubscriptionStatusTool(), |
| 82 | + new AdminGetSeatsTool(), |
| 83 | + new AdminSetSeatsTool(), |
| 84 | + new AdminGetAccountsTool(), |
| 85 | + new AdminConnectAccountTool(), |
| 86 | + new AdminDisconnectAccountTool(), |
| 87 | + new AdminRegenerateTokenTool(), |
| 88 | + new AdminGetLimitsUsageTool(), |
| 89 | + new AdminSetLimitsTool(), |
| 90 | + new AdminResetLimitsTool(), |
| 91 | + ]; |
67 | 92 | } |
68 | 93 |
|
69 | 94 | public toolByName(name: string): LinkedApiTool<unknown, unknown> | undefined { |
70 | 95 | return this.tools.find((tool) => tool.name === name); |
71 | 96 | } |
| 97 | + |
| 98 | + public adminToolByName(name: string): AdminTool<unknown, unknown> | undefined { |
| 99 | + return this.adminTools.find((tool) => tool.name === name); |
| 100 | + } |
72 | 101 | } |
0 commit comments