Classify a Website with the Klazify MCP
Your ad-placement pipeline has a website to review, but a domain name alone does not tell you what content appears there. By the end of this guide, you will know how to use Klazify through an MCP client to request a classification, interpret the returned categories, and route the result to an audit or review workflow.
Why use domain classification in an MCP workflow?
MCP gives an assistant or other compatible client a way to request domain intelligence while working on a task. Rather than asking the client to infer a site’s subject from its name, you can use Klazify’s content analysis and inspect the categories returned for the site.
Klazify supports a hierarchical categorization system and IAB taxonomy mapping. That is useful for ad operations: an internal reviewer can compare a returned category with the organization’s placement policy while retaining the original classification for audit. The same information can support content filtering or CRM enrichment, although each use case needs its own decision rules.
The service can analyze website content rather than relying only on metadata, and its multilingual capabilities are relevant when a review queue includes sites from different markets. A classification is still evidence for a policy decision, not proof that every page on a domain is appropriate for every campaign. Keep an explicit path for uncertain results and human review.
Connect a client and choose the right tool
The Klazify MCP host is https://mcp.klazify.com/mcp. The documented tools cover three distinct tasks:
| Tool | Purpose | When to use it |
|---|---|---|
klazify.categorize |
Website categorization | Classify a site before applying a filtering or placement policy. |
klazify.domain_company |
Company data | Enrich a signup or lead with available company information. |
klazify.domain_logo |
Logo information | Retrieve a logo for an enrichment or presentation workflow. |
For an ad-placement audit, start with klazify.categorize. Request company or logo data only when the workflow needs it: each tool call counts as one API request. Categorization is not a substitute for a separate assessment of whether a site is malicious.
Claude uses mcp-remote to connect to the MCP host. ChatGPT uses the OpenAI-compatible proxy at /v1/chat/completions. Configure the client using the current Documentation for authentication and tool invocation; a plain GET request to /mcp returns 405 and is not a classification request.
The REST categorization endpoint is https://www.klazify.com/api/categorize. MCP and the REST endpoint are different integration paths, so use the documented request format for the path you choose rather than assuming that an MCP tool call has the same shape as a REST request.
Read the classification response
The following is Klazify’s example categorization response. It includes category, company, logo, registration and related-domain information; the fields relevant to a particular MCP tool call can differ, so handle absent fields as well as fields explicitly set to null.
{
"domain": {
"categories": [
{
"confidence": 0.92,
"name": "/Computers & Electronics/Consumer Electronics",
"IAB-632-596": "Consumer Electronics/Technology & Computing/Consumer Electronics"
},
{
"confidence": 0.89,
"name": "/Internet & Telecom/Mobile & Wireless/Mobile Phones"
}
],
"social_media": null,
"logo_url": "https://klazify.s3.amazonaws.com/2110787991611585019600ed5fb1d1300.04730104.png"
},
"success": true,
"objects": {
"company": {
"url": "https://www.apple.com/",
"name": "Apple",
"city": "Cupertino",
"stateCode": "CA",
"countryCode": "US",
"employeesRange": "100K+",
"revenue": 274515000000,
"raised": null,
"tags": [
"E-commerce",
"Consumer Electronics",
"Mobile",
"B2C"
],
"tech": [
"omniture_adobe_analytics",
"atlassian_confluence",
"successfactors",
"apache_apex",
"talend",
"oracle_peoplesoft",
"salesforce",
"stripe",
"dell_boomi_atomsphere",
"gigya",
"sage_50cloud",
"quickbooks",
"webmethods",
"apache_tomcat",
"alteryx",
"tibco_rendezvous",
"atlassian_jira",
"..."
]
}
},
"domain_registration_data": {
"domain_age_date": "1987-02-19",
"domain_age_days_ago": "13026",
"domain_expiration_date": "2030-02-20",
"domain_expiration_days_left": "123"
},
"similar_domains": [
"bestbuy.com",
"icloud.com",
"microsoft.com",
"macrumors.com",
"google.com",
"samsung.com",
"twitter.com",
"hp.com",
"bhphotovideo.com",
"dell.com"
]
}
Check success before using the result. The domain.categories array contains category names and confidence values; the first entry also includes an IAB mapping under IAB-632-596. Not every category entry in this example has that mapping, so do not assume the key is always present.
For a placement audit, preserve the returned category name, confidence and any IAB mapping alongside your own decision. For lead enrichment, objects.company provides fields such as name, location and employeesRange. The sample also illustrates that social_media and raised can be null; neither should be treated as an empty verified fact.
logo_url, company tags, technology entries, registration data and similar_domains can provide context, but they answer different questions from the category list. In particular, a related domain is not automatically an approved ad placement. Registration values in this example are sample data and should not be treated as a current countdown.
Process the fields in Python
Once your client has obtained a categorization response, the following script reads that JSON from standard input. It sends the two example category names to a review path and leaves other or missing categories unmapped. Replace that small mapping with your organization’s policy before using it in production.
import json
import sys
data = json.load(sys.stdin)
if data.get("success") is not True:
print("Classification was not successful; retry or review.")
sys.exit(1)
domain = data.get("domain") or {}
categories = domain.get("categories") or []
review_categories = {
"/Computers & Electronics/Consumer Electronics",
"/Internet & Telecom/Mobile & Wireless/Mobile Phones",
}
matched = False
for category in categories:
name = category.get("name")
print("Category:", name)
print("Confidence:", category.get("confidence"))
print("IAB mapping:", category.get("IAB-632-596"))
if name in review_categories:
matched = True
if matched:
print("Action: review against placement policy.")
else:
print("Action: unmapped; do not make an automatic decision.")
company = (data.get("objects") or {}).get("company") or {}
if company.get("name"):
print("Company:", company["name"])
Save a response as JSON and pipe it into the script to test the decision logic independently of the client connection. The script checks every returned category rather than assuming the first one is the only relevant result. It also avoids converting a missing IAB mapping into a policy decision.
Turn categories into reliable pipeline decisions
A useful integration separates the provider’s classification from your organization’s action. Maintain a mapping from returned category names or available IAB mappings to internal outcomes such as review, allow or block. Store the original values with the mapped outcome so an auditor can distinguish a change in policy from a change in classification.
Decide how to handle multiple categories before enabling automated enforcement. For example, a placement may require review if any returned category maps to your review policy. An unmapped category, an empty category list or an unsuccessful lookup should follow an explicit unknown path rather than silently becoming an approval.
Confidence can inform that workflow, but choose thresholds according to your own tolerance for false positives and missed classifications. Evaluate them against reviewed examples from your traffic. A confidence value is not, by itself, a guarantee that an individual page is safe or unsafe.
Plan for scale and changing sites
Cache results per normalized domain when your decision concerns the domain as a whole. Record when your system fetched the result and refresh it according to the cost and risk of stale data. Sites change, so a cached classification should not be treated as permanent.
If the decision concerns a specific page, preserve the requested URL and avoid assuming that a domain-level cache entry describes every page on that domain. URL classification is useful for sites with varied content, but the cache key and review policy need to reflect the level you actually requested.
For large queues, deduplicate domains before requesting classifications and process work in controlled batches on your side. Observe the rate limits applicable to your account, limit concurrency, and use a retry queue rather than immediately repeating every unsuccessful request. Each MCP tool call is an API request; failed or unreachable calls are not billed, but they still need operational handling.
New or unreachable domains need a separate state from a successful classification. Retain enough information to retry later, and route time-sensitive decisions to review or another policy-defined fallback. Do not manufacture a category when the response is missing or unsuccessful.
Monitor the share of requests that are unmapped, unsuccessful or awaiting review, along with the age of cached results. Those signals help identify a taxonomy mapping that needs maintenance or a queue that is accumulating unresolved domains. They also make it easier to distinguish integration problems from legitimate unknown sites.
FAQ
Can I test the MCP host with a browser GET request?
No. GET /mcp returns 405. Use an MCP-compatible client configured for the host and its documented tool invocation.
Does every MCP tool call count as a request?
Yes. Calls to klazify.categorize, klazify.domain_company and klazify.domain_logo each count as an API request. Request only the data your workflow needs.
What should I do when no category is available?
Keep the domain in an unknown or review state, and retry according to your workflow. An absent category is not evidence that a site is suitable for an ad or exempt from a filter.
Can I use the IAB mapping directly as my policy?
You can use it as an input, but maintain an explicit mapping to your own policy and handle entries without an IAB mapping. Preserve the source category and confidence for review.
Ready to test a classification workflow? Register for a free account, connect your client, and start by routing returned categories into a review queue.
Ready to use Klazify?
Start classifying websites, enriching company data, and exploring web intelligence.
Get Started Free