Skip to content

Commit 490fcc9

Browse files
fix: change pageURL parameter type from Array<string> to string for accessibility scan function
1 parent 157ef90 commit 490fcc9

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

src/tools/accessibility.ts

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,11 @@ const reportFetcher = new AccessibilityReportFetcher();
1111

1212
async function runAccessibilityScan(
1313
name: string,
14-
pageURL: Array<string>,
14+
pageURL: string,
1515
context: any,
1616
): Promise<CallToolResult> {
1717
// Start scan
18-
const startResp = await scanner.startScan(name, pageURL);
18+
const startResp = await scanner.startScan(name, [pageURL]);
1919
const scanId = startResp.data!.id;
2020
const scanRunId = startResp.data!.scanRunId;
2121

@@ -48,8 +48,7 @@ async function runAccessibilityScan(
4848
// Fetch CSV report link
4949
const reportLink = await reportFetcher.getReportLink(scanId, scanRunId);
5050

51-
const { records, next_page } =
52-
await parseAccessibilityReportFromCSV(reportLink);
51+
const { records } = await parseAccessibilityReportFromCSV(reportLink);
5352

5453
return {
5554
content: [
@@ -72,7 +71,7 @@ export default function addAccessibilityTools(server: McpServer) {
7271
{
7372
name: z.string().describe("Name of the accessibility scan"),
7473
pageURL: z
75-
.array(z.string())
74+
.string()
7675
.describe("The URL to scan for accessibility issues"),
7776
},
7877
async (args, context) => {

0 commit comments

Comments
 (0)