@atlaskit/ads-mcp 0.17.0 → 0.17.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/CHANGELOG.md +12 -0
- package/README.md +88 -0
- package/dist/cjs/index.js +5 -18
- package/dist/cjs/tools/get-all-icons/icons.js +43 -0
- package/dist/cjs/tools/get-all-icons/index.js +4 -19
- package/dist/cjs/tools/get-all-tokens/index.js +3 -6
- package/dist/cjs/tools/get-all-tokens/tokens.js +18 -0
- package/dist/cjs/tools/get-components/components.codegen.js +3984 -0
- package/dist/cjs/tools/get-components/components.js +423 -235
- package/dist/cjs/tools/get-components/index.js +2 -2
- package/dist/cjs/tools/get-components/load-all-components.js +16 -0
- package/dist/cjs/tools/get-guidelines/guidelines-structured-content.codegen.js +72 -6
- package/dist/cjs/tools/get-lint-rules/lint-rules-structured-content.codegen.js +7 -7
- package/dist/cjs/tools/search-components/index.js +13 -12
- package/dist/cjs/tools/search-icons/index.js +7 -24
- package/dist/es2019/index.js +5 -17
- package/dist/es2019/tools/get-all-icons/icons.js +25 -0
- package/dist/es2019/tools/get-all-icons/index.js +1 -10
- package/dist/es2019/tools/get-all-tokens/index.js +2 -5
- package/dist/es2019/tools/get-all-tokens/tokens.js +13 -0
- package/dist/es2019/tools/get-components/components.codegen.js +3978 -0
- package/dist/es2019/tools/get-components/components.js +423 -235
- package/dist/es2019/tools/get-components/index.js +11 -9
- package/dist/es2019/tools/get-components/load-all-components.js +10 -0
- package/dist/es2019/tools/get-guidelines/guidelines-structured-content.codegen.js +72 -6
- package/dist/es2019/tools/get-lint-rules/lint-rules-structured-content.codegen.js +7 -7
- package/dist/es2019/tools/search-components/index.js +2 -1
- package/dist/es2019/tools/search-icons/index.js +1 -10
- package/dist/esm/index.js +5 -18
- package/dist/esm/tools/get-all-icons/icons.js +37 -0
- package/dist/esm/tools/get-all-icons/index.js +3 -18
- package/dist/esm/tools/get-all-tokens/index.js +2 -5
- package/dist/esm/tools/get-all-tokens/tokens.js +13 -0
- package/dist/esm/tools/get-components/components.codegen.js +3978 -0
- package/dist/esm/tools/get-components/components.js +423 -235
- package/dist/esm/tools/get-components/index.js +2 -2
- package/dist/esm/tools/get-components/load-all-components.js +10 -0
- package/dist/esm/tools/get-guidelines/guidelines-structured-content.codegen.js +72 -6
- package/dist/esm/tools/get-lint-rules/lint-rules-structured-content.codegen.js +7 -7
- package/dist/esm/tools/search-components/index.js +9 -8
- package/dist/esm/tools/search-icons/index.js +3 -20
- package/dist/types/tools/get-all-icons/icons.d.ts +11 -0
- package/dist/types/tools/get-all-tokens/tokens.d.ts +7 -0
- package/dist/types/tools/get-components/components.codegen.d.ts +10 -0
- package/dist/types/tools/get-components/components.d.ts +1 -1
- package/dist/types/tools/get-components/load-all-components.d.ts +2 -0
- package/dist/types/tools/get-components/types.d.ts +20 -14
- package/dist/types/tools/get-guidelines/guidelines-structured-content.codegen.d.ts +1 -1
- package/dist/types/tools/get-lint-rules/lint-rules-structured-content.codegen.d.ts +1 -1
- package/dist/types-ts4.5/tools/get-all-icons/icons.d.ts +11 -0
- package/dist/types-ts4.5/tools/get-all-tokens/tokens.d.ts +7 -0
- package/dist/types-ts4.5/tools/get-components/components.codegen.d.ts +10 -0
- package/dist/types-ts4.5/tools/get-components/components.d.ts +1 -1
- package/dist/types-ts4.5/tools/get-components/load-all-components.d.ts +2 -0
- package/dist/types-ts4.5/tools/get-components/types.d.ts +20 -14
- package/dist/types-ts4.5/tools/get-guidelines/guidelines-structured-content.codegen.d.ts +1 -1
- package/dist/types-ts4.5/tools/get-lint-rules/lint-rules-structured-content.codegen.d.ts +1 -1
- package/package.json +5 -3
- package/dist/cjs/tools/get-icons/icon-mcp-structured-content.codegen.js +0 -8
- package/dist/cjs/tools/get-icons/icon-structured-content.codegen.js +0 -8
- package/dist/cjs/tools/get-icons/index.js +0 -135
- package/dist/cjs/tools/get-tokens/index.js +0 -125
- package/dist/cjs/tools/get-tokens/token-mcp-structured-content.codegen.js +0 -2356
- package/dist/cjs/tools/get-tokens/token-structured-content.codegen.js +0 -2356
- package/dist/es2019/tools/get-icons/icon-mcp-structured-content.codegen.js +0 -8
- package/dist/es2019/tools/get-icons/icon-structured-content.codegen.js +0 -8
- package/dist/es2019/tools/get-icons/index.js +0 -110
- package/dist/es2019/tools/get-tokens/index.js +0 -100
- package/dist/es2019/tools/get-tokens/token-mcp-structured-content.codegen.js +0 -2350
- package/dist/es2019/tools/get-tokens/token-structured-content.codegen.js +0 -2350
- package/dist/esm/tools/get-icons/icon-mcp-structured-content.codegen.js +0 -8
- package/dist/esm/tools/get-icons/icon-structured-content.codegen.js +0 -8
- package/dist/esm/tools/get-icons/index.js +0 -128
- package/dist/esm/tools/get-tokens/index.js +0 -118
- package/dist/esm/tools/get-tokens/token-mcp-structured-content.codegen.js +0 -2350
- package/dist/esm/tools/get-tokens/token-structured-content.codegen.js +0 -2350
- package/dist/types/tools/get-icons/icon-mcp-structured-content.codegen.d.ts +0 -13
- package/dist/types/tools/get-icons/icon-structured-content.codegen.d.ts +0 -13
- package/dist/types/tools/get-icons/index.d.ts +0 -35
- package/dist/types/tools/get-tokens/index.d.ts +0 -35
- package/dist/types/tools/get-tokens/token-mcp-structured-content.codegen.d.ts +0 -13
- package/dist/types/tools/get-tokens/token-structured-content.codegen.d.ts +0 -13
- package/dist/types-ts4.5/tools/get-icons/icon-mcp-structured-content.codegen.d.ts +0 -13
- package/dist/types-ts4.5/tools/get-icons/icon-structured-content.codegen.d.ts +0 -13
- package/dist/types-ts4.5/tools/get-icons/index.d.ts +0 -35
- package/dist/types-ts4.5/tools/get-tokens/index.d.ts +0 -35
- package/dist/types-ts4.5/tools/get-tokens/token-mcp-structured-content.codegen.d.ts +0 -13
- package/dist/types-ts4.5/tools/get-tokens/token-structured-content.codegen.d.ts +0 -13
package/CHANGELOG.md
CHANGED
package/README.md
CHANGED
|
@@ -5,6 +5,15 @@ Current state: Early Access
|
|
|
5
5
|
The official Model Context Protocol (MCP) server for the Atlassian Design System. This server
|
|
6
6
|
provides tools to access design tokens, icons, and components/primitives programmatically.
|
|
7
7
|
|
|
8
|
+
**New: Remote MCP Server** A hosted version of the ADS MCP server is now available at
|
|
9
|
+
`https://mcp.atlassian.com/v1/ads/public/mcp`. Simply point your MCP client to this URL to get
|
|
10
|
+
started. See the [Usage](#usage) section for per-IDE configuration examples.
|
|
11
|
+
|
|
12
|
+
Or, just click one of the buttons below to easily add the server to Cursor or VS Code.
|
|
13
|
+
|
|
14
|
+
[](vscode:mcp/install?%7B%22name%22%3A%22ads-mcp%22%2C%22type%22%3A%22http%22%2C%22url%22%3A%22https%3A%2F%2Fmcp.atlassian.com%2Fv1%2Fads%2Fpublic%2Fmcp%22%7D)
|
|
15
|
+
[](vscode:mcp/install?%7B%22name%22%3A%22ads-mcp%22%2C%22type%22%3A%22http%22%2C%22url%22%3A%22https%3A%2F%2Fmcp.atlassian.com%2Fv1%2Fads%2Fpublic%2Fmcp%22%7D)
|
|
16
|
+
|
|
8
17
|
**New: Accessibility Analysis & Guidance** The server now includes comprehensive accessibility tools
|
|
9
18
|
to help ensure your interfaces are accessible to all users.
|
|
10
19
|
|
|
@@ -19,10 +28,18 @@ to help ensure your interfaces are accessible to all users.
|
|
|
19
28
|
- [For AFM Users (internal Atlassians only)](#for-afm-users-internal-atlassians-only)
|
|
20
29
|
- [For non-AFM Users](#for-non-afm-users)
|
|
21
30
|
- [Cursor IDE](#cursor-ide)
|
|
31
|
+
- [Local (stdio)](#local-stdio)
|
|
32
|
+
- [Remote](#remote)
|
|
22
33
|
- [Visual Studio Code](#visual-studio-code)
|
|
23
34
|
- [Github Copilot](#github-copilot)
|
|
35
|
+
- [Local (stdio)](#local-stdio-1)
|
|
36
|
+
- [Remote](#remote-1)
|
|
24
37
|
- [Codelassian](#codelassian)
|
|
38
|
+
- [Local (stdio)](#local-stdio-2)
|
|
39
|
+
- [Remote](#remote-2)
|
|
25
40
|
- [Rovodev](#rovodev)
|
|
41
|
+
- [Local (stdio)](#local-stdio-3)
|
|
42
|
+
- [Remote](#remote-3)
|
|
26
43
|
- [MCP Plugin for Atlas CLI](#mcp-plugin-for-atlas-cli)
|
|
27
44
|
- [Environment Variables](#environment-variables)
|
|
28
45
|
- [Analytics](#analytics)
|
|
@@ -142,6 +159,8 @@ ads-mcp.
|
|
|
142
159
|
|
|
143
160
|
#### Cursor IDE
|
|
144
161
|
|
|
162
|
+
##### Local (stdio)
|
|
163
|
+
|
|
145
164
|
Add the following entry to your `mcp.json` file (located at `~/.cursor/mcp.json` for user-level or
|
|
146
165
|
`.cursor/mcp.json` in your workspace):
|
|
147
166
|
|
|
@@ -159,10 +178,28 @@ Add the following entry to your `mcp.json` file (located at `~/.cursor/mcp.json`
|
|
|
159
178
|
}
|
|
160
179
|
```
|
|
161
180
|
|
|
181
|
+
##### Remote
|
|
182
|
+
|
|
183
|
+
Click
|
|
184
|
+
[](vscode:mcp/install?%7B%22name%22%3A%22ads-mcp%22%2C%22type%22%3A%22http%22%2C%22url%22%3A%22https%3A%2F%2Fmcp.atlassian.com%2Fv1%2Fads%2Fpublic%2Fmcp%22%7D)
|
|
185
|
+
to add or add the following to the same `mcp.json` file:
|
|
186
|
+
|
|
187
|
+
```json
|
|
188
|
+
{
|
|
189
|
+
"mcpServers": {
|
|
190
|
+
"ads-mcp": {
|
|
191
|
+
"url": "https://mcp.atlassian.com/v1/ads/public/mcp"
|
|
192
|
+
}
|
|
193
|
+
}
|
|
194
|
+
}
|
|
195
|
+
```
|
|
196
|
+
|
|
162
197
|
#### Visual Studio Code
|
|
163
198
|
|
|
164
199
|
##### Github Copilot
|
|
165
200
|
|
|
201
|
+
###### Local (stdio)
|
|
202
|
+
|
|
166
203
|
Add the following entry to your `mcp.json` file (located at
|
|
167
204
|
`~/Library/Application Support/Code/User/mcp.json` for user-level or `.vscode/mcp.json` in your
|
|
168
205
|
workspace):
|
|
@@ -182,8 +219,27 @@ workspace):
|
|
|
182
219
|
}
|
|
183
220
|
```
|
|
184
221
|
|
|
222
|
+
###### Remote
|
|
223
|
+
|
|
224
|
+
Click
|
|
225
|
+
[](vscode:mcp/install?%7B%22name%22%3A%22ads-mcp%22%2C%22type%22%3A%22http%22%2C%22url%22%3A%22https%3A%2F%2Fmcp.atlassian.com%2Fv1%2Fads%2Fpublic%2Fmcp%22%7D)
|
|
226
|
+
or add the following to the same `mcp.json` file:
|
|
227
|
+
|
|
228
|
+
```json
|
|
229
|
+
{
|
|
230
|
+
"servers": {
|
|
231
|
+
"ads-mcp": {
|
|
232
|
+
"type": "http",
|
|
233
|
+
"url": "https://mcp.atlassian.com/v1/ads/public/mcp"
|
|
234
|
+
}
|
|
235
|
+
}
|
|
236
|
+
}
|
|
237
|
+
```
|
|
238
|
+
|
|
185
239
|
##### Codelassian
|
|
186
240
|
|
|
241
|
+
###### Local (stdio)
|
|
242
|
+
|
|
187
243
|
Add the following entry to your `mcp.json` file (located at `~/.codelassian/mcp.json` for user-level
|
|
188
244
|
or `.codelassian/mcp.json` in your workspace):
|
|
189
245
|
|
|
@@ -201,8 +257,26 @@ or `.codelassian/mcp.json` in your workspace):
|
|
|
201
257
|
}
|
|
202
258
|
```
|
|
203
259
|
|
|
260
|
+
###### Remote
|
|
261
|
+
|
|
262
|
+
No local installation required. Add the following to the same `mcp.json` file:
|
|
263
|
+
|
|
264
|
+
```json
|
|
265
|
+
{
|
|
266
|
+
"mcpServers": {
|
|
267
|
+
"ads-mcp": {
|
|
268
|
+
"type": "streamableHttp",
|
|
269
|
+
"url": "https://mcp.atlassian.com/v1/ads/public/mcp",
|
|
270
|
+
"disabled": false
|
|
271
|
+
}
|
|
272
|
+
}
|
|
273
|
+
}
|
|
274
|
+
```
|
|
275
|
+
|
|
204
276
|
#### Rovodev
|
|
205
277
|
|
|
278
|
+
##### Local (stdio)
|
|
279
|
+
|
|
206
280
|
Add the following entry to your `mcp.json` file (located at `~/.rovodev/mcp.json` for user-level or
|
|
207
281
|
`mcp.json` in your workspace):
|
|
208
282
|
|
|
@@ -226,6 +300,20 @@ Add the following entry to your `mcp.json` file (located at `~/.rovodev/mcp.json
|
|
|
226
300
|
> terminating the process if it becomes unresponsive. Adjust this value as needed for your
|
|
227
301
|
> environment or workflow.
|
|
228
302
|
|
|
303
|
+
##### Remote
|
|
304
|
+
|
|
305
|
+
No local installation required. Add the following to the same `mcp.json` file:
|
|
306
|
+
|
|
307
|
+
```json
|
|
308
|
+
{
|
|
309
|
+
"mcpServers": {
|
|
310
|
+
"ads-mcp": {
|
|
311
|
+
"url": "https://mcp.atlassian.com/v1/ads/public/mcp"
|
|
312
|
+
}
|
|
313
|
+
}
|
|
314
|
+
}
|
|
315
|
+
```
|
|
316
|
+
|
|
229
317
|
#### MCP Plugin for Atlas CLI
|
|
230
318
|
|
|
231
319
|
Atlas CLI provides a plugin for managing MCP servers, including listing available servers from a
|
package/dist/cjs/index.js
CHANGED
|
@@ -21,9 +21,7 @@ var _getAllIcons = require("./tools/get-all-icons");
|
|
|
21
21
|
var _getAllTokens = require("./tools/get-all-tokens");
|
|
22
22
|
var _getComponents = require("./tools/get-components");
|
|
23
23
|
var _getGuidelines = require("./tools/get-guidelines");
|
|
24
|
-
var _getIcons = require("./tools/get-icons");
|
|
25
24
|
var _getLintRules = require("./tools/get-lint-rules");
|
|
26
|
-
var _getTokens = require("./tools/get-tokens");
|
|
27
25
|
var _i18nConversion = require("./tools/i18n-conversion");
|
|
28
26
|
var _migrationGuides = require("./tools/migration-guides");
|
|
29
27
|
var _plan = require("./tools/plan");
|
|
@@ -65,7 +63,7 @@ var generateLogger = function generateLogger(level) {
|
|
|
65
63
|
};
|
|
66
64
|
};
|
|
67
65
|
var getToolRegistry = exports.getToolRegistry = function getToolRegistry() {
|
|
68
|
-
var baseTools = (0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)({}, _analyzeA11y.listAnalyzeA11yTool.name, {
|
|
66
|
+
var baseTools = (0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)({}, _analyzeA11y.listAnalyzeA11yTool.name, {
|
|
69
67
|
handler: _analyzeA11y.analyzeA11yTool,
|
|
70
68
|
inputSchema: _analyzeA11y.analyzeA11yInputSchema,
|
|
71
69
|
tool: _analyzeA11y.listAnalyzeA11yTool
|
|
@@ -97,30 +95,19 @@ var getToolRegistry = exports.getToolRegistry = function getToolRegistry() {
|
|
|
97
95
|
handler: _i18nConversion.i18nConversionTool,
|
|
98
96
|
inputSchema: _i18nConversion.i18nConversionInputSchema,
|
|
99
97
|
tool: _i18nConversion.listI18nConversionTool
|
|
98
|
+
}), _getGuidelines.listGetGuidelinesTool.name, {
|
|
99
|
+
handler: _getGuidelines.getGuidelinesTool,
|
|
100
|
+
inputSchema: _getGuidelines.getGuidelinesInputSchema,
|
|
101
|
+
tool: _getGuidelines.listGetGuidelinesTool
|
|
100
102
|
});
|
|
101
103
|
|
|
102
104
|
// Conditionally add token and icon tools based on feature flag
|
|
103
105
|
if ((0, _platformFeatureFlags.fg)('design_system_mcp_structured_content')) {
|
|
104
|
-
baseTools[_getTokens.listGetTokensTool.name] = {
|
|
105
|
-
handler: _getTokens.getTokensTool,
|
|
106
|
-
inputSchema: _getTokens.getTokensInputSchema,
|
|
107
|
-
tool: _getTokens.listGetTokensTool
|
|
108
|
-
};
|
|
109
|
-
baseTools[_getIcons.listGetIconsTool.name] = {
|
|
110
|
-
handler: _getIcons.getIconsTool,
|
|
111
|
-
inputSchema: _getIcons.getIconsInputSchema,
|
|
112
|
-
tool: _getIcons.listGetIconsTool
|
|
113
|
-
};
|
|
114
106
|
baseTools[_getLintRules.listGetLintRulesTool.name] = {
|
|
115
107
|
handler: _getLintRules.getLintRulesTool,
|
|
116
108
|
inputSchema: _getLintRules.getLintRulesInputSchema,
|
|
117
109
|
tool: _getLintRules.listGetLintRulesTool
|
|
118
110
|
};
|
|
119
|
-
baseTools[_getGuidelines.listGetGuidelinesTool.name] = {
|
|
120
|
-
handler: _getGuidelines.getGuidelinesTool,
|
|
121
|
-
inputSchema: _getGuidelines.getGuidelinesInputSchema,
|
|
122
|
-
tool: _getGuidelines.listGetGuidelinesTool
|
|
123
|
-
};
|
|
124
111
|
} else {
|
|
125
112
|
baseTools[_getAllTokens.listGetAllTokensTool.name] = {
|
|
126
113
|
handler: _getAllTokens.getAllTokensTool,
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
+
Object.defineProperty(exports, "__esModule", {
|
|
5
|
+
value: true
|
|
6
|
+
});
|
|
7
|
+
exports.icons = void 0;
|
|
8
|
+
var _slicedToArray2 = _interopRequireDefault(require("@babel/runtime/helpers/slicedToArray"));
|
|
9
|
+
var _toConsumableArray2 = _interopRequireDefault(require("@babel/runtime/helpers/toConsumableArray"));
|
|
10
|
+
var _metadata = _interopRequireDefault(require("@atlaskit/icon-lab/metadata"));
|
|
11
|
+
var _metadata2 = require("@atlaskit/icon/metadata");
|
|
12
|
+
// https://hello.atlassian.net/wiki/spaces/DST/pages/6558719954/Icon+content+type
|
|
13
|
+
|
|
14
|
+
var icons = exports.icons = [].concat((0, _toConsumableArray2.default)(Object.entries(_metadata2.coreIconMetadata).map(function (_ref) {
|
|
15
|
+
var _ref2 = (0, _slicedToArray2.default)(_ref, 2),
|
|
16
|
+
_key = _ref2[0],
|
|
17
|
+
icon = _ref2[1];
|
|
18
|
+
return {
|
|
19
|
+
componentName: icon.componentName,
|
|
20
|
+
package: icon.package,
|
|
21
|
+
categorization: icon.categorization,
|
|
22
|
+
keywords: icon.keywords,
|
|
23
|
+
status: icon.status,
|
|
24
|
+
usage: icon.usage,
|
|
25
|
+
shouldRecommendSmallIcon: icon.shouldRecommendSmallIcon,
|
|
26
|
+
team: icon.team
|
|
27
|
+
};
|
|
28
|
+
})), (0, _toConsumableArray2.default)(Object.entries(_metadata.default).map(function (_ref3) {
|
|
29
|
+
var _ref4 = (0, _slicedToArray2.default)(_ref3, 2),
|
|
30
|
+
_key = _ref4[0],
|
|
31
|
+
icon = _ref4[1];
|
|
32
|
+
return {
|
|
33
|
+
componentName: icon.componentName,
|
|
34
|
+
package: icon.package,
|
|
35
|
+
categorization: icon.categorization,
|
|
36
|
+
//???
|
|
37
|
+
keywords: icon.keywords,
|
|
38
|
+
status: icon.status,
|
|
39
|
+
usage: icon.usage,
|
|
40
|
+
shouldRecommendSmallIcon: icon.shouldRecommendSmallIcon,
|
|
41
|
+
team: icon.team
|
|
42
|
+
};
|
|
43
|
+
})));
|
|
@@ -7,26 +7,11 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
7
7
|
exports.listGetAllIconsTool = exports.getAllIconsTool = void 0;
|
|
8
8
|
var _regenerator = _interopRequireDefault(require("@babel/runtime/regenerator"));
|
|
9
9
|
var _asyncToGenerator2 = _interopRequireDefault(require("@babel/runtime/helpers/asyncToGenerator"));
|
|
10
|
-
var _slicedToArray2 = _interopRequireDefault(require("@babel/runtime/helpers/slicedToArray"));
|
|
11
10
|
var _zod = require("zod");
|
|
12
|
-
var _metadata = require("@atlaskit/icon/metadata");
|
|
13
11
|
var _helpers = require("../../helpers");
|
|
12
|
+
var _icons = require("./icons");
|
|
14
13
|
/* eslint-disable-next-line import/extensions -- MCP SDK requires .js extensions for ESM imports */
|
|
15
14
|
|
|
16
|
-
var icons = Object.entries(_metadata.coreIconMetadata).map(function (_ref) {
|
|
17
|
-
var _ref2 = (0, _slicedToArray2.default)(_ref, 2),
|
|
18
|
-
_key = _ref2[0],
|
|
19
|
-
icon = _ref2[1];
|
|
20
|
-
return {
|
|
21
|
-
componentName: icon.componentName,
|
|
22
|
-
package: icon.package,
|
|
23
|
-
categorization: icon.categorization,
|
|
24
|
-
keywords: icon.keywords,
|
|
25
|
-
status: icon.status,
|
|
26
|
-
usage: icon.usage,
|
|
27
|
-
shouldRecommendSmallIcon: icon.shouldRecommendSmallIcon
|
|
28
|
-
};
|
|
29
|
-
});
|
|
30
15
|
var listGetAllIconsTool = exports.listGetAllIconsTool = {
|
|
31
16
|
name: 'ads_get_all_icons',
|
|
32
17
|
description: "Fetch all Atlassian Design System icons. Only use when `ads_search_icons` does not return what you're looking for.",
|
|
@@ -40,12 +25,12 @@ var listGetAllIconsTool = exports.listGetAllIconsTool = {
|
|
|
40
25
|
inputSchema: (0, _helpers.zodToJsonSchema)(_zod.z.object({}))
|
|
41
26
|
};
|
|
42
27
|
var getAllIconsTool = exports.getAllIconsTool = /*#__PURE__*/function () {
|
|
43
|
-
var
|
|
28
|
+
var _ref = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee() {
|
|
44
29
|
return _regenerator.default.wrap(function _callee$(_context) {
|
|
45
30
|
while (1) switch (_context.prev = _context.next) {
|
|
46
31
|
case 0:
|
|
47
32
|
return _context.abrupt("return", {
|
|
48
|
-
content: icons.map(function (icon) {
|
|
33
|
+
content: _icons.icons.map(function (icon) {
|
|
49
34
|
return {
|
|
50
35
|
// NOTE: Ideally one day the MCP would support structured content…
|
|
51
36
|
// eg. `type: 'object', data: icon`
|
|
@@ -61,6 +46,6 @@ var getAllIconsTool = exports.getAllIconsTool = /*#__PURE__*/function () {
|
|
|
61
46
|
}, _callee);
|
|
62
47
|
}));
|
|
63
48
|
return function getAllIconsTool() {
|
|
64
|
-
return
|
|
49
|
+
return _ref.apply(this, arguments);
|
|
65
50
|
};
|
|
66
51
|
}();
|
|
@@ -8,8 +8,8 @@ exports.listGetAllTokensTool = exports.getAllTokensTool = void 0;
|
|
|
8
8
|
var _regenerator = _interopRequireDefault(require("@babel/runtime/regenerator"));
|
|
9
9
|
var _asyncToGenerator2 = _interopRequireDefault(require("@babel/runtime/helpers/asyncToGenerator"));
|
|
10
10
|
var _zod = require("zod");
|
|
11
|
-
var _tokenMetadata = require("@atlaskit/tokens/token-metadata");
|
|
12
11
|
var _helpers = require("../../helpers");
|
|
12
|
+
var _tokens = require("./tokens");
|
|
13
13
|
/* eslint-disable-next-line import/extensions -- MCP SDK requires .js extensions for ESM imports */
|
|
14
14
|
|
|
15
15
|
var inputSchema = _zod.z.object({});
|
|
@@ -31,15 +31,12 @@ var getAllTokensTool = exports.getAllTokensTool = /*#__PURE__*/function () {
|
|
|
31
31
|
while (1) switch (_context.prev = _context.next) {
|
|
32
32
|
case 0:
|
|
33
33
|
return _context.abrupt("return", {
|
|
34
|
-
content:
|
|
34
|
+
content: _tokens.tokens.map(function (token) {
|
|
35
35
|
return {
|
|
36
36
|
// NOTE: Ideally one day the MCP would support structured content…
|
|
37
37
|
// eg. `type: 'object', data: token`
|
|
38
38
|
type: 'text',
|
|
39
|
-
text: JSON.stringify(
|
|
40
|
-
name: token.name,
|
|
41
|
-
exampleValue: token.exampleValue
|
|
42
|
-
}, null, 2)
|
|
39
|
+
text: JSON.stringify(token, null, 2)
|
|
43
40
|
};
|
|
44
41
|
})
|
|
45
42
|
});
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.tokens = void 0;
|
|
7
|
+
var _tokenMetadata = require("@atlaskit/tokens/token-metadata");
|
|
8
|
+
// https://hello.atlassian.net/wiki/spaces/DST/pages/6558592429/Token+content+type
|
|
9
|
+
|
|
10
|
+
var tokens = exports.tokens = _tokenMetadata.tokens.map(function (metadata) {
|
|
11
|
+
var _metadata$exampleValu;
|
|
12
|
+
return {
|
|
13
|
+
name: metadata.name,
|
|
14
|
+
path: metadata.path,
|
|
15
|
+
description: metadata.description,
|
|
16
|
+
exampleValue: String((_metadata$exampleValu = metadata.exampleValue) !== null && _metadata$exampleValu !== void 0 ? _metadata$exampleValu : '')
|
|
17
|
+
};
|
|
18
|
+
});
|