You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+2Lines changed: 2 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -12,6 +12,7 @@ It provides analytics tools for sites, reports, processed report data, goals, se
12
12
2. Activate **McpServer** in **Administration -> Plugins**.
13
13
3. Enable MCP in **Administration -> System -> Plugin Settings -> McpServer**.
14
14
4. Configure your MCP client with the endpoint and a Matomo `token_auth` that already has access to the data you want to expose.
15
+
5. If needed, restrict the maximum allowed MCP privilege level in plugin settings or use a separate lower-privilege Matomo user for MCP access.
15
16
16
17
For the recommended end-user setup flow, use the in-product connect guide at **Administration -> Platform -> MCP Server**.
17
18
@@ -21,6 +22,7 @@ For the recommended end-user setup flow, use the in-product connect guide at **A
21
22
- Raw Matomo API discovery and execution tools are separately disabled by default and must be enabled by an administrator.
22
23
- The plugin uses Matomo authentication.
23
24
- Data access is limited to the same sites and reports the Matomo user can already access.
25
+
- Administrators can optionally restrict MCP usage to users or tokens at or below a configured privilege level.
24
26
- When raw API access is enabled, MCP clients can access the same Matomo API surface available to the authenticated user, including state-changing methods if an administrator has allowed them.
25
27
- If features such as the Visitor Log are available to that user, MCP clients may access the same underlying data scope.
26
28
- Review privacy, security, and compliance requirements before enabling raw API access.
Copy file name to clipboardExpand all lines: docs/faq.md
+8-1Lines changed: 8 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -38,6 +38,13 @@ Configure raw Matomo API tool access in **Administration -> System -> Plugin Set
38
38
- Low-confidence or unclassified direct API methods require `Full API access`.
39
39
- Direct API access can expose raw or personal data depending on enabled Matomo features. Review privacy and security requirements before enabling it, and consult your DPO or compliance owner when needed.
40
40
41
+
Configure MCP privilege limits in **Administration -> System -> Plugin Settings -> McpServer**:
42
+
43
+
- Use **Maximum allowed MCP privilege level** to deny MCP access for users authenticated with a higher Matomo privilege.
44
+
-`No privilege limit` (default): follows the usual Matomo access model and does not add an extra MCP privilege cap.
45
+
-`View access`, `Write access`, or `Admin access`: allows only users whose highest privilege across all sites is at or below the selected level.
46
+
- For stricter separation, create a separate Matomo user or token with reduced permissions for MCP use.
47
+
41
48
## Enabling MCP
42
49
43
50
MCP access is disabled by default and must be enabled in **Administration -> System -> Plugin Settings -> McpServer**.
@@ -62,5 +69,5 @@ The plugin is focused on read-oriented analytics workflows. The exact tool surfa
62
69
## Troubleshooting
63
70
64
71
-`401 Unauthorized`: verify the Bearer token is present, active, and belongs to a user with access to the requested site data.
65
-
-`403 Forbidden`: if MCP is disabled, enable MCP in **Administration -> System -> Plugin Settings -> McpServer**. If MCP is already enabled, verify the authenticated Matomo user has access to the requested site or report data.
72
+
-`403 Forbidden`: if MCP is disabled, enable MCP in **Administration -> System -> Plugin Settings -> McpServer**. If MCP is already enabled, verify the authenticated Matomo user has access to the requested site or report data and does not exceed the configured maximum MCP privilege level.
66
73
-`400 Bad Request`: verify the client is using the exact MCP endpoint and is not proxying requests through `API.getBulkRequest`.
Copy file name to clipboardExpand all lines: lang/en.json
+8Lines changed: 8 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -32,6 +32,14 @@
32
32
"EnableMcpHelpPurpose": "Enable the Matomo MCP Server (Model Context Protocol) to allow AI tools and assistants to access analytics context from your Matomo instance.",
33
33
"EnableMcpHelpUrl": "Your MCP URL: %1$s%2$s%3$s",
34
34
"EnableMcpTitle": "Enable MCP Server (Model Context Protocol)",
35
+
"MaximumMcpAccessLevelAdmin": "Admin access",
36
+
"MaximumMcpAccessLevelHelpPurpose": "Choose the highest Matomo privilege level allowed to use the MCP endpoint. Users authenticated with a higher privilege level will be denied.",
37
+
"MaximumMcpAccessLevelHelpSeparateUser": "If you need tighter isolation, create a separate Matomo user for MCP with only the required site permissions.",
38
+
"MaximumMcpAccessLevelHelpTokens": "Use this setting to limit MCP access to lower-privilege users or tokens.",
"MaximumMcpAccessLevelUnlimited": "No privilege limit",
41
+
"MaximumMcpAccessLevelView": "View access",
42
+
"MaximumMcpAccessLevelWrite": "Write access",
35
43
"RawApiAccessHelpDataScope": "Direct Matomo API access can expose the same data available through the Matomo user interface or direct API endpoints, including raw or personal data when features such as the Visitor Log are enabled.",
36
44
"RawApiAccessHelpDestructive": "Partial API access can enable create, update, and delete methods through the selected checkboxes below. Full API access can execute any allowed state-changing or destructive API methods, including actions that modify configuration or delete data.",
37
45
"RawApiAccessHelpPolicy": "Before enabling direct API access, ensure this complies with your organization's privacy and security policies and applicable regulations. You may need approval from your data protection officer (DPO) or another compliance owner.",
0 commit comments