Skip to main content

MCP Insights tutorial

Use IQM Model Context Protocol (MCP) to interact with the Insights API.

Overview​

This tutorial guides you through using IQM MCP to generate Insights reports and templates.

Before you begin​

To manage Insights reports using IQM MCP, the following are required:

  1. An account on the IQM platform
    • See Before you begin to create an account and request a Client ID and Client Secret
  2. IQM MCP set up on your computer
    • See the MCP Setup guide to set up MCP with your authorization credentials
  3. An audience and campaign that meet the eligibility requirements for generating Insights reports

About IQM Insights​

Insights reports are one of IQM's analytics tools that help Advertisers quickly identify trends and apply precise adjustments to deliver better results for campaigns.

With pre-defined metrics and dimensions, Insights reports can be generated for the following areas:

TypeDescription
Campaign Bidding InsightsCampaign Bidding Insights capture rejected campaigns and segment them based on rejection reason, allowing you to assess which parameters are limiting a campaign's success.
Audience InsightsAudience Insights provide in-depth reports of audience characteristics, interests, and behaviors to give you a deeper understanding of your target audience and create targeted and personalized advertising strategies.
Audience Quality (AQ)AQ Insights leverage third-party healthcare data from PurpleLab to confirm audience exposure based on patient-level targeting criteria including prescriptions, diagnoses, and procedures.
Voter Level Data (VLD)VLD Insights offer Insights about targeting in current or prior political campaigns. These reports include ad exposure, engagement data, demographic data, and voting-history details by voter.
Script Lift Study (SLS)SLS Insights include key details about prescribing behaviors and how they're influenced by current and previous healthcare campaigns.
Provider Level Data (PLD)PLD Insights include details about healthcare professionals targeted in your campaigns, and provide similar details as VLD Insights while adhering to healthcare data privacy regulations.
Nurse Level Data (NLD)NLD Insights offer deeper visibility into how Non-NPI nurses engage with your campaigns. They uncover ad-exposure, engagement, demographic, and physician-specialty data to reveal reach and impact.
Integrated Care Team (ICT)ICT Insights uncover key details about the ICT audiences you've targeted in previous and current campaigns.
NOTE

Some Insights reports need to be enabled by an administrator before you can access them. By default, VLD, PLD, SLS, and AQ reports are not accessible to advertiser users.

You can check an advertiser's access to Insights reports with the Get Customer Config Details endpoint.

More resources​

Generate Audience Insights reports​

You can use IQM MCP to generate Insights reports for eligible audiences. Use the following prompts to generate Insights reports for your audiences:

PromptResponse exampleNotes
Show me a list of audiences eligible for generating Insights reportsCheck for Insights-eligible audiences first, or provide an Audience ID directly to generate reports for.
Generate an Insights report for each of those audiences
Create download links for each of those reports

Create Insights report templates​

You can also use IQM MCP to create Insights report templates for PLD, NLD, and ICT. Use the following prompts to create report templates:

PromptResponse exampleNotes
Get a list of eligible audiences for the PLD templates for the healthcare WorkspaceMCP notes that PLD templates require eligible campaigns, not audiences, and suggests the correct tool.
Create a PLD template for campaign 590512MCP prompts the user for the necessary template details: frequency, aggregation, and name. MCP then uses tools to validate the name and find frequency details.
Create an NLD template with these details: campaign 590516, frequency monthly, name "NLD Report 1", and not aggregatedMCP validates the request details and asks for any missing parameters.
Get me a list of MCP templates
Update template 705 to be inactive, then update template 700 to weekly frequencyMCP notes that it has to update the start date in order to update the template correctly.

Tools index​

In the tables below you can find the complete set of Insights tools available in MCP, categorized by report type.

Each tool includes a brief description and a link to the corresponding API documentation for more details on its functionality and usage.

Use this index as a reference to explore the various Insights capabilities of MCP and how they relate to the Insights API endpoints.

Insights report details​

Tool nameDescriptionDocumentation
getInsightsDetailListGet a list of Insights reportsGet a list of Insights reports
getCampaignBiddingInsightGet Campaign Bidding Insights data for a campaignGet Campaign Bidding Insights
getInsightsTypeWiseCountGet Insights report counts grouped by typeGet Insights reports count by type
getStatusWiseCampaignsForInsightsReportsGet a status-wise list of campaigns eligible for Insights reportsGet eligible campaigns
computeInsightsReportsCompute Insights reports for the given campaignsCalculate Insights computation

Insights report management​

Tool nameDescriptionDocumentation
deleteInsightsDelete Insights report records by IDDelete Insights report record
regenerateInsightsRegenerate a failed Insights reportRegenerate Insights report
sendInsightsEmailEmail an Insights report to recipientsSend Insights report email

Audience Insights report​

Tool nameDescriptionDocumentation
getInsightsCreateEligibleAudienceListGet a list of audiences eligible for Audience Insights report generationGet a list of eligible audiences
createInsightsDetailsCreate an Audience Insights report for one or more audiencesCreate Audience Insights report
downloadInsightsDownload an Audience Insights report (PDF or XLSX)Download Insights report

Power Segment Insights (PSI)​

Tool nameDescriptionDocumentation
generateReportGenerate a Power Segment Insights reportGenerate PSI report
getPowerSegmentsDetailListGet a list of Power Segment Insights reportsGet Power Segment Insights list
downloadReportDownload a Power Segment Insights reportDownload PSI report
sendReportEmailEmail a Power Segment Insights report to recipientsEmail PSI report
getPsiCategoryTypesGet the list of Power Segment Insights category typesGet Power Segment Insights category types

Audience Quality (AQ) Insights reports​

Tool nameDescriptionDocumentation
getReportDetailListGet a paginated list of AQ Insights reportsGet list of AQ Insights reports
getStatusWiseCampaignsForReportsGet a status-wise list of campaigns eligible for AQ Insights reportsGet list of campaigns eligible for AQ Insights reports
validateAQSReportNameValidate an AQ Insights report nameValidate AQ Insights report name
computeReportsGet cost and impression estimates for an AQ Insights reportCompute AQ Insights report cost
generateAQReportsGenerate an AQ Insights reportGenerate AQ Insights report
getAQSReportTypesGet the list of available AQ Insights report typesGet AQ Insights report types
getAQSReportDownloadUrlDownload an AQ Insights reportDownload AQ Insights report
deleteFailedReportsDelete a failed AQ Insights reportDelete AQ Insights report
emailEmail an AQ Insights report to recipients

Voter Level Data (VLD) Insights reports​

Tool nameDescriptionDocumentation
getVLDReportListGet a list of VLD Insights reportsGet list of VLD Insights reports
getStatusWiseCampaignsForVLDReportsGet a list of campaigns eligible for VLD Insights reportsGet list of campaigns eligible for VLD Insights reports
generateVLDReportsGenerate a VLD Insights reportGenerate VLD Insights report
getChargeableImpressionsDataForVLDReportsGet cost and impression estimates for a VLD Insights reportGet cost assessment for VLD Insights report
getVLDReportDownloadUrlDownload a VLD Insights reportDownload VLD Insights report
deleteFailedVLDReportDelete a failed VLD Insights reportDelete VLD Insights report
sendMailForVlDReportEmail a VLD Insights report to recipients

Script Lift Study (SLS) Insights reports​

Tool nameDescriptionDocumentation
getSLSReportListGet a list of SLS Insights reportsGet list of SLS Insights reports
getStatusWiseCampaignsForSLSReportsGet a status-wise list of campaigns eligible for SLS Insights reportsGet list of campaigns eligible for SLS Insights reports
generateSLSReportsGenerate an SLS Insights reportGenerate SLS Insights report
getChargeableImpressionsDataForSLSReportsGet cost and impression estimates for an SLS Insights reportSLS Insights reports computation
validateSlsReportNameValidate an SLS Insights report nameValidate SLS Insights report name
getSLSReportDownloadUrlDownload an SLS Insights reportDownload SLS Insights report
deleteFailedSLSReportDelete a failed SLS Insights reportDelete SLS Insights report
sendMailForSlsReportEmail an SLS Insights report to recipients

Provider Level Data (PLD) Insights reports​

Tool nameDescriptionDocumentation
getPLDReportListGet a list of PLD Insights reports
generatePLDReportsGenerate a PLD Insights report
getChargeableImpressionsDataForPLDReportsGet cost and impression estimates for a PLD Insights report
fetchPLDReportSelectedColumnsGet the user-selected columns for PLD Insights reports
saveOrUpdatePLDReportSelectedColumnsSave or update the user-selected columns for PLD Insights reports
getReportIntervalGet the reporting interval for a PLD Insights report template

Report templates​

Tool nameDescriptionDocumentation
getTemplatesGet a list of report templatesGet list of templates
createTemplateCreate a report templateCreate report template
updateTemplateUpdate a report templateUpdate report template
validateTemplateNameValidate a report template nameValidate template name
getTemplateByIdGet report template details by IDGet template details
getReportsForTemplateGet the reports generated for a templateGet template reports

Report management​

Tool nameDescriptionDocumentation
getReportDownloadUrlDownload an Insights reportDownload report
deleteFailedReportDelete a failed reportDelete report
sendMailForReportEmail an Insights report to recipientsEmail report
regenerateReportsRegenerate a failed schedulable reportRegenerate report

Static / reference data​

Tool nameDescriptionDocumentation
getInsightsTypeGet the list of Insights typesGet list of Insights types
getInsightsStatusGet the list of Insights status typesGet list of Insights status types
getTemplateStatusesGet the list of template status typesGet list of template status types
getFrequencyMetadataGet delivery frequency metadata for scheduling templatesGet scheduling frequencies
getReportStatusesGet the list of report statuses
getPropertiesOfReportsGet environment-wide default report properties
Have a question?
Was this page helpful?