Microsoft Clarity
Ask your agent to summarize recent website traffic and engagement from your Clarity project. The connector reads dashboard metrics through Data Export. Browser tracking, heatmaps and session recordings are managed in Clarity.
How to get credentials
- Open your project in Microsoft Clarity.
- As a project admin, open Settings > Data Export and generate an API token.
- Add Microsoft Clarity in FlyMyAI and paste that token into Microsoft Clarity API Token. Save the connection.
- Ask for a report for the last day. This first export verifies access and uses one request from the project's daily allowance.
Saving or testing the connection does not run an export. Clarity has no separate token-check endpoint for this connector, so a saved token is not proof of access. Use the project API token, not a browser tracking ID. Your normal FlyMyAI execution charges apply; your own Clarity account provides access.
Fields to fill in FlyMyAI
| FlyMyAI field | Where it comes from |
|---|---|
| Microsoft Clarity API Token | API token generated by an admin of the project you want to read. |
Try it
Export my Clarity dashboard metrics for the last day, grouped by operating system. Summarize traffic and engagement using the fields returned.
Read the last three days of Clarity metrics by device and country. Explain which groups have the most sessions and flag missing metrics.
All actions
| Action | Purpose |
|---|---|
microsoft_clarity_data_export | Export recent dashboard metrics with up to three breakdown dimensions. |
Action reference
microsoft-clarity-data-export
microsoft_clarity_data_export - Read the connected project's dashboard metrics
for the preceding 24, 48 or 72 hours. This action reads data and does not change
the project. Existing uppercase MICROSOFT_CLARITY_DATA_EXPORT calls remain
accepted with the same input names.
Dimension values are Browser, Device, Country/Region, OS, Source,
Medium, Campaign, Channel and URL. Omit dimensions for an ungrouped
report. Unlisted input fields are rejected.
Clarity allows ten exports per project per day, limits a response to 1,000 rows and offers no pagination for this endpoint. A call makes one export request, with a 20-second deadline and a 1 MiB response limit. Responses beyond the limit fail without returning a partial report. The connector does not automatically retry an export or fetch additional pages.
Local JSON limits also apply: nesting depth 16, 100,000 items and 256 KiB per UTF-8 string. A response with HTTP 200 can still fail if it exceeds these limits, contains malformed JSON or duplicate keys, has a non-JSON content type, or does not match the metric and row structure described below.
A 401 response means the token needs checking; 403 indicates denied export access, and 429 means the provider is limiting requests. Saving the connection does not verify the token or use an export. All calls use the connected project's API token and consume that project's allowance.
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
numOfDays | integer | Yes | None | 1, 2 or 3, meaning the preceding 24, 48 or 72 hours. JSON strings and booleans are not accepted. |
dimension1 | string or null | No | null | First breakdown dimension. Use an exact value listed above; null omits the dimension. |
dimension2 | string or null | No | null | Second breakdown dimension. Use an exact value listed above; null omits the dimension. |
dimension3 | string or null | No | null | Third breakdown dimension. Use an exact value listed above; null omits the dimension. |
Result: An array of metric objects. Each has string metricName and an information array of row objects. Fields vary by metric and dimensions; additional provider fields are preserved, including numeric strings. An empty array is a valid result. Times use UTC.
Example arguments:
{"numOfDays": 1, "dimension1": "OS"}
Illustrative result, with invented values:
[
{
"metricName": "Traffic",
"information": [
{
"totalSessionCount": "120",
"totalBotSessionCount": "8",
"distantUserCount": "97",
"PagesPerSessionPercentage": 1.4,
"OS": "Android"
}
]
}
]
The provider's field distantUserCount keeps its original spelling. Available
metrics can include traffic, engagement time, scroll depth and click or script
errors; do not assume every metric or row contains the same fields.
Sharing
You can share this connection from Shared by me with a verified recipient. The recipient receives access to this exact connection's reviewed read action; the token stays on the server. The recipient pays FlyMyAI execution from their own wallet, and exports consume the source project's Clarity allowance. Revoke the grant to stop further shared calls. Replacing the token requires renewed sharing consent.
Troubleshooting
- 401: Check whether the project token is missing, invalid or expired.
- 403: Check the token's permission to export the project.
- 400: Use an integer from 1 to 3 and the exact dimension spellings above.
- 429: The provider's quota is exhausted. Wait until Clarity allows another export; repeated requests do not increase the daily allowance.
- Response too large or timeout: Try a smaller period or fewer dimensions. A provider response can still exceed the connector's limits.
- Invalid dashboard response: Clarity returned malformed JSON, an unexpected content type or an invalid metric or row structure. No partial report is returned; an HTTP 200 status alone does not mean the export is usable.
- Connection saved but export fails: Saving a token does not call Clarity. Access is checked by an actual export.