# Japanese Website Contact Sales Policy Finder (`hoanp/japanese-website-contact-sales-policy-finder`) Actor

Automatically crawl websites to locate contact pages, detect Sales NG policies (pitch bans), analyze contact forms, and identify CAPTCHAs. Optimized for Japanese B2B outreach compliance with high speed and low resource usage.

- **URL**: https://apify.com/hoanp/japanese-website-contact-sales-policy-finder.md
- **Developed by:** [Phuong Hoa Nguyen](https://apify.com/hoanp) (community)
- **Categories:**
- **Stats:** 1 total users, 0 monthly users, 0.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $5.00 / 1,000 analyzed websites

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

Actors are web data automations that power AI and operations. They run on the Apify platform to scrape websites, process data, connect APIs, and automate workflows.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.
Actors are written with capital "A".

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.
The best way to integrate Actors is as follows.

- **AI agents and MCP clients** — the [Apify MCP server](https://docs.apify.com/integrations/mcp.md) at `https://mcp.apify.com` (remote, streamable HTTP, OAuth on first use).
- **Agentic workflows and local Actor development** — [Agent Skills](https://apify.com/.well-known/agent-skills/index.json) with the [Apify CLI](https://docs.apify.com/cli/docs.md): `npm install -g apify-cli`, then `apify login`.
- **JavaScript/TypeScript projects** — the official [JS/TS client](https://docs.apify.com/api/client/js/docs.md): `npm install apify-client`.
- **Python projects** — the official [Python client](https://docs.apify.com/api/client/python/docs.md): `pip install apify-client`.
- **Any other language** — the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).

# README

## Contact Page & Sales NG Policy Detector

An ultra-fast, lightweight Apify Actor designed to crawl business websites, locate **Contact Pages**, detect **Sales NG policies** (bans on commercial outreach/pitches), evaluate **Contact Forms**, and identify **CAPTCHA protection**.

Engineered specifically for B2B cold outreach compliance (with deep multi-level Japanese linguistic analysis) and bulk processing of up to **1,000 websites per batch**.

***

### 🚀 Key Features

- **🎯 Smart Contact Page Finder:** Uses a multi-criteria scoring algorithm (URL patterns, anchor text, header/footer context, `onclick` handlers) to accurately pinpoint contact pages.
- **🚫 Sales NG Policy Detection:** Multi-level semantic analysis to identify explicit bans on sales, pitches, or unsolicited emails (e.g., `営業目的...ご遠慮ください`).
- **📝 Form & Field Analytics:** Detects active HTML `<form>` elements and counts interactive user fields (`input`, `textarea`, `select`).
- **🛡️ CAPTCHA Recognition:** Identifies Google reCAPTCHA, hCaptcha, Cloudflare Turnstile, and Japanese verification systems (`画像認証`).
- **⚡ Resource & Speed Optimized:** Blocks images, media, fonts, and tracking scripts to run with ultra-low RAM/CPU overhead and maximum execution speed.

***

### 📥 Input Configuration

The Actor expects a JSON input containing a direct link to a CSV file hosted on an **Apify Key-Value Store** (or any public HTTP URL).

#### Input JSON Example

```json
{
  "inputFile": "https://api.apify.com/v2/key-value-stores/YOUR_STORE_ID/records/input.csv",
  "maxPages": 20
}
```

#### Input Parameters

| Parameter | Type | Required | Default | Description |
| :--- | :--- | :---: | :---: | :--- |
| `inputFile` | String | **Yes** | - | Public URL to the CSV file stored in an Apify Key-Value Store. |
| `maxPages` | Integer | No | `20` | Maximum pages processed per crawl execution. |

#### CSV File Requirements

The CSV file must contain a header with **exactly two columns**: `id` (integer) and `url` (valid website URL). Supports up to **1,000 URLs per run**.

```csv
id,url
1,https://example.com
2,https://www.beautygarage.co.jp
```

***

### 📤 Output Data Format

The results are stored in the default **Apify Dataset** as JSON items:

#### Sample Dataset Output

```json
{
  "id": 2,
  "url": "https://www.beautygarage.co.jp",
  "contactPage": "https://www.beautygarage.co.jp/inquiry/",
  "contactPageFound": true,
  "salesStatus": "RESTRICTED",
  "restrictionScore": 100,
  "restrictionReason": "営業目的 + ご遠慮ください | 営業目的のお問い合わせはご遠慮ください。",
  "matchedSubjects": "営業目的",
  "matchedPredicates": "ご遠慮ください",
  "hasForm": true,
  "formCount": 1,
  "fieldCount": 5,
  "captcha": true,
  "captchaType": "reCAPTCHA",
  "captchaCount": 1,
  "error": null
}
```

#### Dataset Field Descriptions

| Field | Type | Description |
| :--- | :--- | :--- |
| `id` | Integer | The unique ID supplied in your input CSV. |
| `url` | String | The target homepage URL. |
| `contactPage` | String / Null | Discovered URL of the contact page. |
| `contactPageFound` | Boolean | `true` if a contact page was successfully identified. |
| `salesStatus` | String | Sales policy status: `ALLOW`, `WARNING`, `RESTRICTED`, or `ERROR`. |
| `restrictionScore` | Integer | Risk score (0 = Safe, 30–40 = Warning, 100 = Explicitly Restricted). |
| `restrictionReason` | String | Contextual proof (Subject + Predicate + Matched sentence). |
| `matchedSubjects` | String | Matched commercial outreach subjects (e.g., `営業目的`, `セールス`). |
| `matchedPredicates` | String | Matched rejection/restriction terms (e.g., `ご遠慮ください`, `お断り`). |
| `hasForm` | Boolean | `true` if interactive contact forms exist on the page. |
| `formCount` | Integer | Total count of `<form>` tags found. |
| `fieldCount` | Integer | Count of usable input fields (`input`, `textarea`, `select`). |
| `captcha` | Boolean | `true` if CAPTCHA mechanisms were detected. |
| `captchaType` | String | Type of CAPTCHA detected (reCAPTCHA, hCaptcha, Turnstile, CAPTCHA). |
| `captchaCount` | Integer | Occurrences of CAPTCHA indicators in page sources. |
| `error` | String / Null | Error message if the navigation or crawl failed. |

***

### 🚦 Understanding `salesStatus`

- **`RESTRICTED` (Score: 100):** The target page explicitly forbids commercial pitches or sales forms. Do **not** send outreach emails or submit forms here to avoid domain blacklisting.
- **`WARNING` (Score: 30–40):** Isolated sales or rejection keywords were detected, but no definitive restriction sentence was formed. Proceed with caution.
- **`ALLOW` (Score: 0):** No restriction policies detected. Safe for outreach.
- **`ERROR`:** Website failed to load or timed out during navigation.

***

# Actor input Schema

## `inputFile` (type: `string`):

Upload a CSV file containing two columns: id (integer) and url (string).

## `maxPages` (type: `integer`):

Maximum number of pages the Actor can inspect on each website when looking for the contact page.

## Actor input object example

```json
{
  "inputFile": "https://api.apify.com/v2/key-value-stores/JmgKSr4FCgVtDaCJm/records/test.csv",
  "maxPages": 20
}
```

# Actor output Schema

## `results` (type: `string`):

No description

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {};

// Run the Actor and wait for it to finish
const run = await client.actor("hoanp/japanese-website-contact-sales-policy-finder").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {}

# Run the Actor and wait for it to finish
run = client.actor("hoanp/japanese-website-contact-sales-policy-finder").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{}' |
apify call hoanp/japanese-website-contact-sales-policy-finder --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,hoanp/japanese-website-contact-sales-policy-finder"
        }
    }
}

```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/tx88PzrcmLgDT4BJG/builds/ZpCeGqTiY7Ed1pqMJ/openapi.json
