EmailmoversMyDataHub docs
Browse the docs

Reference / MCP tool reference

Reference

Preview sample records

preview_records: Returns up to 25 masked sample rows (10 by default) for an audience or a count id, each with verification badges, why it matches and a provenance card.

Generated from the contractsView as Markdown

Returns up to 25 masked sample rows (10 by default) for an audience or a count id, each with verification badges, why it matches and a provenance card. Use it after count_audience to show the user what the records look like before quoting. Free: emails and phones are masked on the server, a repeat returns the same rows, and no rows come back when the count is under 25. Call quote_order next to price the records. Lawful basis is UK GDPR Article 6(1)(f) legitimate interests; email audiences include corporate subscribers only by default (PECR), so sole traders and ordinary partnerships are left out unless the toggle is changed.

PropertyValue
Tool namepreview_records
Position in tools/list9 of 22
CostFree
ScopeNone. Works without an account.
AnnotationsreadOnlyHint true, destructiveHint false, idempotentHint true, openWorldHint false
KindRead only; idempotent, not destructive, closed world
REST equivalentPOST /v1/previews

Input

The schema sets additionalProperties to false, so a member that is not listed is refused.

MemberTypeRequiredDescription
audiencestring or AudiencenoAn audience definition (mydatahub.audience/1) inline, or the aud_ id of a saved audience.
count_idstringnoA count id instead of an audience.
limitinteger (1 to 25)noRows to return, 1 to 25. Default 10. Default 10.
shufflebooleannoDraw a new seed. Counts against your rate budget and is logged. Default false, so a repeat returns the same rows. Default false.

Example call

The params of a tools/call request:

{
  "name": "preview_records",
  "arguments": {
    "count_id": "cnt_7K2PQ4MAXN3R6TBY5WDZ",
    "limit": 10
  }
}

Output

The result carries structuredContent that matches this schema, and one line of text that leads with the number.

MemberTypeAlways presentDescription
idstringyesFormat: a preview id: prv_ followed by a 26 character ULID in upper case Crockford base32, such as prv_01JB4H3M7Q2V7XN3M9R6T1Y5W8.
count_idstringyesFormat: a count id: cnt_ followed by 20 base32 characters (A to Z and 2 to 7), such as cnt_7K2PQ4MAXN3R6TBY5WDZ.
dataset_versionstringyesThe immutable weekly build a count is bound to, such as 2026-W39. The last 52 stay queryable.
seedstringyesThe seed the rows came from; the same audience gives the same seed.
countinteger (0 or more)yesThe count the rows were drawn from, rounded as disclosure says.
disclosureDisclosureyesWhether these numbers are exact or protected: "under 10" cells, rounding to 5 and secondary suppression for anonymous and trial callers.
disclosure.levelenum: exact, roundedyesexact for authenticated paid callers; rounded for anonymous and trial callers, whose counts under 100 and every cell are rounded to the nearest 5.
disclosure.rounded_tointeger or nullyes5 when numbers are rounded; null when they are exact.
disclosure.secondary_suppressionbooleanyesTrue when cross-tab or breakdown cells of 10 or more were hidden as "suppressed" so totals cannot be differenced.
disclosure.notesarray of stringyes
rowsarray of PreviewRowyes
rows[].idstringyesA session-scoped id standing in for the record. It never reveals contact_ ids.
rows[].titlestringyes
rows[].job_levelstring or nullyesThe level, such as Director; null when the level is not known.
rows[].job_functionstring or nullyes
rows[].companyobjectyes
rows[].siteobjectyes
rows[].email_maskedstring or nullyesFirst character of the local part plus the top level domain, such as j••••@••••.co.uk.
rows[].email_typeenum: named, generic_local_part, generic_domain or nullyes
rows[].phone_maskedstring or nullyesTo the area code, such as 0113 ••• •••1.
rows[].tps_ctps_statusenum: clear, tps_registered, ctps_registered, tps_or_ctps_registered, not_screened or nullyes
rows[].badgesarray of VerifiedBadge or OtherBadgeyes
rows[].why_it_matchesarray of WhyItMatchesyes
rows[].provenanceProvenanceCardyesThe ICO due diligence answers for one record, as shown on the sample row.
rows[].complianceComplianceObjectyesCarried by every preview row, order record, lookup and enrichment, and repeated as CSV columns and as the MyDataHub property group on CRM push.
withheldobject or nullyesRows held back: all of them when the count is under 25, or rows whose title fewer than 10 people hold.
withheld.rowsinteger (0 or more)yes
withheld.reasonstringyes
maskedtrueyes
watermarkstring or nullyesThe account id watermarked into sample CSVs; null when signed out.
created_atstring (date-time)yes

Errors

A failed call returns isError true. The text content leads with the sentence a person acts on, then the whole problem as JSON, with code, detail, next_step and did_you_mean. A 401 and a step-up 403 are answered at HTTP level so the client can start authorisation. See Errors.