diff --git a/static/openapi/mcp-reports.json b/static/openapi/mcp-reports.json index 9289dc6f..f84e46f9 100644 --- a/static/openapi/mcp-reports.json +++ b/static/openapi/mcp-reports.json @@ -2,7 +2,7 @@ "openapi": "3.0.1", "info": { "title": "MCP Reports API Specification", - "version": "1.1.0", + "version": "1.1.1", "description": "IQM Reports API for custom, ad-hoc, saved, and scheduled report construction and delivery. Use these tools to select dimensions, metrics, columns, filters, templates, reporting periods, and email schedules.", "contact": { "name": "IQM Support", @@ -29,7 +29,7 @@ "MCP" ], "summary": "Run (execute) a custom report and return its rows and totals", - "description": "Report-builder routing: Use this IQM Reports API tool to create, configure, save, execute, schedule, email, list, or manage a custom report. Use it for report dimensions, metrics, columns, filters, templates, and reporting periods.\n\nRuns a saved or ad-hoc report and returns its rows and totals in the response; it does not save anything (to export a CSV or XLSX file use downloadReport). Run a saved report by `id`, or an ad-hoc report by sending `dimensions`, `columns`, `startDate`, `endDate`, `timezoneId`, `timezoneName`, `requestType` and `reportAggregated`.\n\nThe response `data` contains `data` (one row per dimension combination, only rows with impressions; omitted when there are no rows), `total` (a single totals row) and `totalRecords` (number of rows across all pages). Rows are paginated with `pageNo` and `noOfEntries` and sorted by `sortBy` (default `-impressions`). Daily rows include a `date` (MM/DD/YYYY); weekly and monthly rows include a `dateRange`.\n\nDates are epoch milliseconds (end after start; at most 365 days apart), and `timezoneName` controls how they are bucketed into days, weeks and months. Metrics that require the finance permission return 0 for users without it.\n\n**Request Body Description:**\n\n| **Field** | **Type** | **Description** |\n| --- | --- | --- |\n| id | Integer | [Optional] - Run a saved report by its ID. When supplied, the saved definition replaces dimensions, columns, customerIds, startDate, endDate, timezoneId, timezoneName, requestType and reportAggregated; only pageNo, noOfEntries, sortBy, searchField, filters and resultType are read from the request. |\n| dimensions | JSON String | [Required unless `id` is supplied] - JSON string representing dimension details. |\n| columns | Array of String | [Required unless `id` is supplied] - Metrics for showing serving result. Must be exact `key` values from GET /api/v3/ra/report/dimension-metrics/detail's `metrics` -- each category in that array (e.g. \"Counts\") maps to a list of metric objects, and `key` is a field on each of those objects. No fuzzy or case-insensitive matching. |\n| customerIds | Array of Integer | [Optional] - Workspace users: customers assigned to the user to include; omit to include all assigned customers. Ignored for advertiser users. |\n| filters | Object | [Optional] - Additional filters, distinct from per-dimension value filtering. Known keys: campaignIds (array of Integer), creativeTypeIds (array of Integer), campaignStatuses (array of String, e.g. \"running\"/\"expired\"; only applied when the report has a campaign or campaignStatus dimension). |\n| searchField | String | [Optional] - Text matched (case-insensitive, partial) against the names, and numeric IDs, of the report's dimension values, e.g. campaign names. |\n| requestType | Integer | [Required unless `id` is supplied; no default is applied if omitted] - Time breakdown of the rows.
sample : [1 - Daily, 2 - Aggregated (no time breakdown), 3 - Weekly, 4 - Monthly] |\n| reportAggregated | String | [Required unless `id` is supplied; no default is applied if omitted] - \"1\" aggregates over the first dimension (it is left out of the grouping); \"0\" groups by every dimension.
sample : [0- Not aggregated, 1- Aggregated] |\n| startDate | Long | [Required unless `id` is supplied] - Report start time as a Unix epoch timestamp in milliseconds.|\n| endDate | Long | [Required unless `id` is supplied] - Report end time as a Unix epoch timestamp in milliseconds. Must be after startDate and at most 365 days later.|\n| timezoneId | Integer | [Required unless `id` is supplied; no default is applied if omitted] - Timezone ID|\n| timezoneName | String | [Required unless `id` is supplied; no default is applied if omitted] - Timezone name used to bucket dates into days, weeks and months, e.g. US/Eastern. With `id`, the saved report's timezone is used.|\n| sortBy | String | [Optional] - Field to sort by. Prefix with minus(-) for descending or plus(+) for ascending; no prefix sorts descending. Only one field is used.
Default value is '-impressions'|\n| pageNo | Integer | [Optional] - Page number, 1 or greater.
Default value is 1|\n| noOfEntries | Integer | [Optional] - The maximum number of returned results per page.
Default value is 50|\n", + "description": "Report-builder routing: Use this IQM Reports API tool to create, configure, save, execute, schedule, email, list, or manage a custom report. Use it for report dimensions, metrics, columns, filters, templates, and reporting periods.\n\nRun (execute) a saved or ad-hoc report and return its rows and totals in the response; nothing is saved. For a file, see downloadReport. Pass a saved report's `id`, or define an ad-hoc report by sending `dimensions`, `columns`, `startDate`, `endDate`, `timezoneId`, `timezoneName`, `requestType` and `reportAggregated`.\n\nThe response `data` contains `data` (one row per dimension combination, only rows with impressions; omitted when there are no rows), `total` (a single totals row) and `totalRecords` (number of rows across all pages). Rows are paginated with `pageNo` and `noOfEntries` and sorted by `sortBy` (default `-impressions`). Daily rows include a `date` (MM/DD/YYYY); weekly and monthly rows include a `dateRange`.\n\nDates are epoch milliseconds (end after start; at most 365 days apart), and `timezoneName` controls how they are bucketed into days, weeks and months. Metrics that require the finance permission return 0 for users without it.\n\n**Request Body Description:**\n\n| **Field** | **Type** | **Description** |\n| --- | --- | --- |\n| id | Integer | [Optional] - Run a saved report by its ID. When supplied, the saved definition replaces dimensions, columns, customerIds, startDate, endDate, timezoneId, timezoneName, requestType and reportAggregated; only pageNo, noOfEntries, sortBy, searchField, filters and resultType are read from the request. |\n| dimensions | JSON String | [Required unless `id` is supplied] - JSON string representing dimension details. |\n| columns | Array of String | [Required unless `id` is supplied] - Metrics for showing serving result. Must be exact `key` values from GET /api/v3/ra/report/dimension-metrics/detail's `metrics` -- each category in that array (e.g. \"Counts\") maps to a list of metric objects, and `key` is a field on each of those objects. No fuzzy or case-insensitive matching. |\n| customerIds | Array of Integer | [Optional] - Workspace users: customers assigned to the user to include; omit to include all assigned customers. Ignored for advertiser users. |\n| filters | Object | [Optional] - Additional filters, distinct from per-dimension value filtering. Known keys: campaignIds (array of Integer), creativeTypeIds (array of Integer), campaignStatuses (array of String, e.g. \"running\"/\"expired\"; only applied when the report has a campaign or campaignStatus dimension). |\n| searchField | String | [Optional] - Text matched (case-insensitive, partial) against the names, and numeric IDs, of the report's dimension values, e.g. campaign names. |\n| requestType | Integer | [Required unless `id` is supplied; no default is applied if omitted] - Time breakdown of the rows.
sample : [1 - Daily, 2 - Aggregated (no time breakdown), 3 - Weekly, 4 - Monthly] |\n| reportAggregated | String | [Required unless `id` is supplied; no default is applied if omitted] - \"1\" aggregates over the first dimension (it is left out of the grouping); \"0\" groups by every dimension.
sample : [0- Not aggregated, 1- Aggregated] |\n| startDate | Long | [Required unless `id` is supplied] - Report start time as a Unix epoch timestamp in milliseconds.|\n| endDate | Long | [Required unless `id` is supplied] - Report end time as a Unix epoch timestamp in milliseconds. Must be after startDate and at most 365 days later.|\n| timezoneId | Integer | [Required unless `id` is supplied; no default is applied if omitted] - Timezone ID|\n| timezoneName | String | [Required unless `id` is supplied; no default is applied if omitted] - Timezone name used to bucket dates into days, weeks and months, e.g. US/Eastern. With `id`, the saved report's timezone is used.|\n| sortBy | String | [Optional] - Field to sort by. Prefix with minus(-) for descending or plus(+) for ascending; no prefix sorts descending. Only one field is used.
Default value is '-impressions'|\n| pageNo | Integer | [Optional] - Page number, 1 or greater.
Default value is 1|\n| noOfEntries | Integer | [Optional] - The maximum number of returned results per page.
Default value is 50|\n", "operationId": "executeReportData", "parameters": [ { @@ -634,7 +634,7 @@ "MCP" ], "summary": "Download (export) a custom report as a CSV or XLSX file", - "description": "Report-builder routing: Use this IQM Reports API tool to create, configure, save, execute, schedule, email, list, or manage a custom report. Use it for report dimensions, metrics, columns, filters, templates, and reporting periods.\n\nRuns a saved or ad-hoc report and exports it as a CSV or XLSX file, returning a temporary download URL in `data.url`; it does not save anything (to get rows in the response use executeReportData). The URL is set to expire after 3 hours, and `url` is null if the file could not be uploaded.\n\nThe request body is the same as executeReportData: run a saved report by `id`, or define an ad-hoc report in the request (`dimensions`, `columns`, `startDate`, `endDate`, `timezoneId`, `timezoneName`, `requestType` and `reportAggregated`). `fileType` is always required: 1 = CSV, 2 = XLSX.\n\nThe file contains up to 20,000 rows in `sortBy` order; `pageNo` and `noOfEntries` do not limit the download. Columns for the report's dimensions are added to the file automatically, plus a `date` column for daily reports or a `dateRange` column for weekly and monthly reports (except when `reportAggregated` is \"1\" with a single dimension). When the report has a name, the file starts with the report name and time range. XLSX files end with a totals row; CSV files have no totals row.\n\n**Request Body Details:**\n\n| **Field** | **Type** | **Description** |\n| --- | --- | --- |\n| fileType | Integer | [Required] - File format of the download.
sample : [1 - CSV, 2 - XLSX] |\n| id | Integer | [Optional] - Run a saved report by its ID. When supplied, the saved definition replaces dimensions, columns, customerIds, startDate, endDate, timezoneId, timezoneName, requestType and reportAggregated. |\n| dimensions | JSON String | [Required unless `id` is supplied] - JSON string representing dimension details. |\n| columns | Array of String | [Required unless `id` is supplied] - Metric keys to include in the file. |\n| customerIds | Array of Integer | [Optional] - Workspace users: customers assigned to the user to include; omit to include all assigned customers. Ignored for advertiser users. |\n| requestType | Integer | [Required unless `id` is supplied] - Time breakdown of the rows.
sample : [1 - Daily, 2 - Aggregated (no time breakdown), 3 - Weekly, 4 - Monthly] |\n| reportAggregated | String | [Required unless `id` is supplied] - \"1\" aggregates over the first dimension (it is left out of the grouping); \"0\" groups by every dimension.
sample : [0- Not aggregated, 1- Aggregated] |\n| startDate | Long | [Required unless `id` is supplied] - Report start time as a Unix epoch timestamp in milliseconds. |\n| endDate | Long | [Required unless `id` is supplied] - Report end time as a Unix epoch timestamp in milliseconds. Must be after startDate and at most 365 days later. |\n| timezoneId | Integer | [Required unless `id` is supplied] - Timezone ID|\n| timezoneName | String | [Required unless `id` is supplied] - Timezone name used to bucket dates, e.g. US/Eastern|\n| sortBy | String | [Optional] - Field to sort by. Prefix with minus(-) for descending or plus(+) for ascending; no prefix sorts descending.
Default value is '-impressions'|\n| pageNo | Integer | [Optional] - Must be 1 or greater. Does not limit the download.
Default value is 1|\n| noOfEntries | Integer | [Optional] - Does not limit the download, which contains up to 20,000 rows.
Default value is 50|\n", + "description": "Report-builder routing: Use this IQM Reports API tool to create, configure, save, execute, schedule, email, list, or manage a custom report. Use it for report dimensions, metrics, columns, filters, templates, and reporting periods.\n\nDownload (export) a saved or ad-hoc report as a CSV or XLSX file, returning a temporary download URL in `data.url`; nothing is saved. For rows in the response, see executeReportData. The URL is set to expire after 3 hours, and `url` is null if the file could not be uploaded.\n\nThe request body is the same as executeReportData: pass a saved report's `id`, or define an ad-hoc report in the request (`dimensions`, `columns`, `startDate`, `endDate`, `timezoneId`, `timezoneName`, `requestType` and `reportAggregated`). `fileType` is always required: 1 = CSV, 2 = XLSX.\n\nThe file contains up to 20,000 rows in `sortBy` order; `pageNo` and `noOfEntries` do not limit the download. Columns for the report's dimensions are added to the file automatically, plus a `date` column for daily reports or a `dateRange` column for weekly and monthly reports (except when `reportAggregated` is \"1\" with a single dimension). When the report has a name, the file starts with the report name and time range. XLSX files end with a totals row; CSV files have no totals row.\n\n**Request Body Details:**\n\n| **Field** | **Type** | **Description** |\n| --- | --- | --- |\n| fileType | Integer | [Required] - File format of the download.
sample : [1 - CSV, 2 - XLSX] |\n| id | Integer | [Optional] - ID of the saved report to download. When supplied, the saved definition replaces dimensions, columns, customerIds, startDate, endDate, timezoneId, timezoneName, requestType and reportAggregated. |\n| dimensions | JSON String | [Required unless `id` is supplied] - JSON string representing dimension details. |\n| columns | Array of String | [Required unless `id` is supplied] - Metric keys to include in the file. |\n| customerIds | Array of Integer | [Optional] - Workspace users: customers assigned to the user to include; omit to include all assigned customers. Ignored for advertiser users. |\n| requestType | Integer | [Required unless `id` is supplied] - Time breakdown of the rows.
sample : [1 - Daily, 2 - Aggregated (no time breakdown), 3 - Weekly, 4 - Monthly] |\n| reportAggregated | String | [Required unless `id` is supplied] - \"1\" aggregates over the first dimension (it is left out of the grouping); \"0\" groups by every dimension.
sample : [0- Not aggregated, 1- Aggregated] |\n| startDate | Long | [Required unless `id` is supplied] - Report start time as a Unix epoch timestamp in milliseconds. |\n| endDate | Long | [Required unless `id` is supplied] - Report end time as a Unix epoch timestamp in milliseconds. Must be after startDate and at most 365 days later. |\n| timezoneId | Integer | [Required unless `id` is supplied] - Timezone ID|\n| timezoneName | String | [Required unless `id` is supplied] - Timezone name used to bucket dates, e.g. US/Eastern|\n| sortBy | String | [Optional] - Field to sort by. Prefix with minus(-) for descending or plus(+) for ascending; no prefix sorts descending.
Default value is '-impressions'|\n| pageNo | Integer | [Optional] - Must be 1 or greater. Does not limit the download.
Default value is 1|\n| noOfEntries | Integer | [Optional] - Does not limit the download, which contains up to 20,000 rows.
Default value is 50|\n", "operationId": "downloadReport", "parameters": [ { @@ -1591,7 +1591,7 @@ "MCP" ], "summary": "Create (save) a custom report definition", - "description": "Report-builder routing: Use this IQM Reports API tool to create, configure, save, execute, schedule, email, list, or manage a custom report. Use it for report dimensions, metrics, columns, filters, templates, and reporting periods.\n\nSaves a new report definition without running it and returns its ID in `data` (to copy an existing report use duplicateReport; to change one use updateReport). Run it afterwards with executeReportData or downloadReport using that `id`.\n\nRequired: `reportName` (up to 255 characters), `dimensions`, `columns`, `startDate` and `endDate` (epoch milliseconds; end after start; at most 365 days apart), `timezoneId`, `requestType` and `reportAggregated`. Dimension and column keys must exactly match keys from getDimensionAndMetricDetails for the caller's organization type.\n\nCustomers: for workspace users, `customerIds` must be customers assigned to the user; omit it to include all assigned customers. For advertiser users `customerIds` is ignored.\n\n`reportSchedulingEventDetails` is validated if sent but is not saved: no schedule or email is created. To schedule emails, create the report first and then call saveReportScheduleEvent with the new report ID. `timezoneName` is not stored; the saved report's timezone comes from `timezoneId`.\n", + "description": "Report-builder routing: Use this IQM Reports API tool to create, configure, save, execute, schedule, email, list, or manage a custom report. Use it for report dimensions, metrics, columns, filters, templates, and reporting periods.\n\nSave (create) a new custom report definition and return its ID in `data`; the report is not executed. For existing reports, see duplicateReport or updateReport. Afterwards, pass that `id` to executeReportData or downloadReport.\n\nRequired: `reportName` (up to 255 characters), `dimensions`, `columns`, `startDate` and `endDate` (epoch milliseconds; end after start; at most 365 days apart), `timezoneId`, `requestType` and `reportAggregated`. Dimension and column keys must exactly match keys from getDimensionAndMetricDetails for the caller's organization type.\n\nCustomers: for workspace users, `customerIds` must be customers assigned to the user; omit it to include all assigned customers. For advertiser users `customerIds` is ignored.\n\n`reportSchedulingEventDetails` is validated if sent but is not saved: no schedule or email is created. To schedule emails, create the report first and then call saveReportScheduleEvent with the new report ID. `timezoneName` is not stored; the saved report's timezone comes from `timezoneId`.\n", "operationId": "saveReport", "parameters": [ { @@ -1759,7 +1759,7 @@ "MCP" ], "summary": "Duplicate (copy) a saved custom report", - "description": "Report-builder routing: Use this IQM Reports API tool to create, configure, save, execute, schedule, email, list, or manage a custom report. Use it for report dimensions, metrics, columns, filters, templates, and reporting periods.\n\nCopies an existing saved report (`id`, required) into a new saved report, optionally renamed, and returns a message containing the new report ID; it does not run the report (to define a new report from scratch use saveReport).\n\nEverything except the name is copied from the original: dimensions, columns, dates, customers, timezone, `requestType` and `reportAggregated`. The new report is named `reportName` if sent (up to 255 characters), otherwise \"Copy of \". Email schedules are not copied. All other request fields are ignored; to change the copy, call updateReport afterwards.\n\nThe original report must belong to the caller's organization, and for workspace users all of its customers must be assigned to the user.\n", + "description": "Report-builder routing: Use this IQM Reports API tool to create, configure, save, execute, schedule, email, list, or manage a custom report. Use it for report dimensions, metrics, columns, filters, templates, and reporting periods.\n\nCopy (duplicate) an existing saved report (`id`, required) into a new saved report, optionally renamed, and return a message containing the new report ID; the report is not executed. To define a report from scratch, see saveReport.\n\nEverything except the name is copied from the original: dimensions, columns, dates, customers, timezone, `requestType` and `reportAggregated`. The new report is named `reportName` if sent (up to 255 characters), otherwise \"Copy of \". Email schedules are not copied. All other request fields are ignored; to change the copy, call updateReport afterwards.\n\nThe original report must belong to the caller's organization, and for workspace users all of its customers must be assigned to the user.\n", "operationId": "duplicateReport", "parameters": [ { @@ -2164,7 +2164,7 @@ "MCP" ], "summary": "Update (edit) fields of a saved custom report", - "description": "Report-builder routing: Use this IQM Reports API tool to create, configure, save, execute, schedule, email, list, or manage a custom report. Use it for report dimensions, metrics, columns, filters, templates, and reporting periods.\n\nChanges fields of an existing saved report: a partial update of the report identified by the `reportId` path parameter. It does not run the report (to create a new report use saveReport or duplicateReport).\n\nOnly fields sent with a meaningful value change: non-blank `reportName` (up to 255 characters) and `dimensions`, non-empty `columns` and `customerIds`, positive `startDate`, `endDate`, `timezoneId` and `requestType` (1-4), and `reportAggregated` (\"0\" or \"1\"). Omitted fields keep their saved values. An empty `dimensions` string or empty `columns` list is rejected.\n\nDates follow the same rules as create (epoch milliseconds; end after start; at most 365 days apart). If only one date is sent, it is checked against the saved value of the other. Unlike create, edit does not check dimension and column keys against the allowed list, so use the exact keys from getDimensionAndMetricDetails.\n\nCustomers: workspace users may send `customerIds` (customers assigned to them), or `[]` to use all assigned customers. Advertiser users must not send `customerIds`. Changing `timezoneId` also updates the timezone of the report's email schedule, if it has one. `reportSchedulingEventDetails` is ignored; manage schedules with the report email schedule operations. The report must belong to the caller's organization.\n", + "description": "Report-builder routing: Use this IQM Reports API tool to create, configure, save, execute, schedule, email, list, or manage a custom report. Use it for report dimensions, metrics, columns, filters, templates, and reporting periods.\n\nEdit (update) fields of an existing saved report: a partial update of the report identified by the `reportId` path parameter; the report is not executed. To make a new report, see saveReport or duplicateReport.\n\nOnly fields sent with a meaningful value change: non-blank `reportName` (up to 255 characters) and `dimensions`, non-empty `columns` and `customerIds`, positive `startDate`, `endDate`, `timezoneId` and `requestType` (1-4), and `reportAggregated` (\"0\" or \"1\"). Omitted fields keep their saved values. An empty `dimensions` string or empty `columns` list is rejected.\n\nDates follow the same rules as saveReport (epoch milliseconds; end after start; at most 365 days apart). If only one date is sent, it is checked against the saved value of the other. Unlike saveReport, this operation does not check dimension and column keys against the allowed list, so use the exact keys from getDimensionAndMetricDetails.\n\nCustomers: workspace users may send `customerIds` (customers assigned to them), or `[]` to use all assigned customers. Advertiser users must not send `customerIds`. Changing `timezoneId` also updates the timezone of the report's email schedule, if it has one. `reportSchedulingEventDetails` is ignored; manage schedules with the report email schedule operations. The report must belong to the caller's organization.\n", "operationId": "updateReport", "parameters": [ {