# US Customs Bill-of-Lading & Import Intelligence (ImportYeti) (`xtracto/us-customs-bol`) Actor

Extract US maritime import intelligence per company — supplier relationships, shipment volume, HS codes, TEU, and contacts — from ImportYeti. Underlying data is US CBP vessel-manifest public record.

- **URL**: https://apify.com/xtracto/us-customs-bol.md
- **Developed by:** [xtractoo](https://apify.com/xtracto) (community)
- **Categories:** Lead generation, Other
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, NaN bookmarks
- **User rating**: No ratings yet

## Pricing

from $1.00 / 1,000 results

This Actor is paid per event and usage. You are charged both the fixed price for specific events and for Apify platform usage.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

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

## What's an Apify Actor?

Actors are a software tools running on the Apify platform, for all kinds of web data extraction and automation use cases.
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.

In JavaScript/TypeScript projects, use official [JavaScript/TypeScript client](https://docs.apify.com/api/client/js.md):

```bash
npm install apify-client
```

In Python projects, use official [Python client library](https://docs.apify.com/api/client/python.md):

```bash
pip install apify-client
```

In shell scripts, use [Apify CLI](https://docs.apify.com/cli/docs.md):

````bash
# MacOS / Linux
curl -fsSL https://apify.com/install-cli.sh | bash
# Windows
irm https://apify.com/install-cli.ps1 | iex
```bash

In AI frameworks, you might use the [Apify MCP server](https://docs.apify.com/platform/integrations/mcp.md).

If your project is in a different language, use 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

## US Customs Bill-of-Lading & Import Intelligence (ImportYeti)

Extract **US maritime import intelligence** for any company — its overseas **supplier relationships**, **shipment volume**, **HS codes**, **TEU**, multi-location addresses, and **direct contacts** — sourced from ImportYeti. The underlying data class is **US CBP vessel-manifest (bill-of-lading) public record**.

Built for equity/credit analysts (import volume as a COGS/revenue signal), B2B sales teams hunting a competitor's real suppliers, and supply-chain risk desks.

---

### Why use this actor

- **No account, no API key.** Reads the public company page.
- **Rich aggregate per company** — not just a name: total shipments, 12-month shipments, average TEU/month, total shipping cost, top supplier, country mix, HS codes, time-series, phone, website, and up to five geocoded addresses.
- **Stable extraction** — pulls the structured company object directly from the page's embedded data (Next.js RSC flight), not brittle HTML scraping.

### Input

| Field | Description |
| --- | --- |
| `companies` | ImportYeti company slug (`apple`) or a full `/company/<slug>` URL. |
| `maxConcurrency` | Companies in parallel (default 3). |
| `proxyConfiguration` | Cloudflare-fronted; residential recommended at scale. |

### Output — `COMPANY_PROFILE`

Dataset envelope (`_input`, `_source`, `_scrapedAt`) + `recordType: "COMPANY_PROFILE"`, then the ImportYeti company aggregate **with upstream field names preserved**:

```json
{
  "_input": "apple",
  "_source": "S2-nextflight",
  "_scrapedAt": "2026-06-03T10:00:00Z",
  "recordType": "COMPANY_PROFILE",
  "company_slug": "apple",
  "profile_url": "https://www.importyeti.com/company/apple",
  "ld_name": "Apple - ... - company Report - Import Yeti",
  "ld_description": "Apple's top supplier is Hon Hai Precision Industrial ... with 2449 shipments",
  "company_name": "...",
  "company_address_country_name": "...",
  "total_shipments": 0,
  "shipments_12m": 0,
  "avg_teu_per_month": 0,
  "total_shipping_cost": 0,
  "company_website": "...",
  "company_phone_number": "...",
  "company_hs_codes": [],
  "company_time_series": [],
  "company_address_loc1": "...", "company_address_loc1_lat": 0, "company_address_loc1_long": 0
  // ... ~90 upstream fields total, verbatim
}
````

`_source` is `S2-nextflight` when the embedded aggregate is found, or `S1-ldjson` (summary only) as a degraded fallback. If neither layer yields data the record is an `_error: "no_data_extracted"` — **never a silent empty object**.

**`PRODUCT_BREAKDOWN`** (one per top HTS-code group embedded in the page — raw upstream fields):

```json
{
  "_input": "apple",
  "_source": "S2-nextflight",
  "_scrapedAt": "2026-06-03T10:00:00Z",
  "recordType": "PRODUCT_BREAKDOWN",
  "company_slug": "apple",
  "hts_code": "8504.40.9999",
  "description": "Static converters",
  "shipments": 128,
  "most_recent_shipment": "26/07/2019",
  "bol_number": "FTNVHKOAHS001319",
  "product_description": "2100Pcs Of Power Adapter ... From China To United States Via Hong Kong By Truck"
}
```

### How it works

1. Fetch `GET /company/<slug>` with a `curl_cffi` (`chrome131`) TLS profile (passes Cloudflare).
2. Parse the `application/ld+json` WebPage block for the summary.
3. Decode the `self.__next_f` RSC flight fragments and lift the company aggregate object with a balanced-brace walker anchored on `avg_teu_per_month` (with fallback anchors).
4. Emit one `COMPANY_PROFILE` per company.

### Known limits & roadmap

- **WAF:** Cloudflare. Plain requests pass in testing; `curl_cffi chrome131` used for safety, residential proxy at scale.
- **Full per-shipment BoL rows are NOT available anonymously.** Recon (2026-06-03) found the backend API `https://data.importyeti.com/v1.0/company/<slug>` returns **HTTP 401** without a token — the SSR page is rendered server-side with that data, and the embedded JSON only exposes the company aggregate + the **top-10 HTS product groups** (each with a shipment count and one sample BoL number), which this actor extracts. A complete BoL feed would require ImportYeti's authenticated/paid API or a primary CBP/FOIA data source.
- **RSC format drift:** the flight chunk shape can change on a Next.js upgrade. The walker tries multiple anchor keys and **fails loud** (`no_data_extracted`) rather than emitting partial garbage — monitor the error rate.
- **ToS / provenance:** this reads ImportYeti's aggregation; the underlying CBP manifest is public record. For durable, high-volume use, evaluate a primary CBP/FOIA bulk feed.
- **Verified live 2026-06-03:** `/company/apple` → 200, 771KB, 90-field aggregate extracted cleanly.

# Actor input Schema

## `companies` (type: `array`):

ImportYeti company slug (e.g. 'apple') or a full /company/<slug> URL.

## `maxConcurrency` (type: `integer`):

Max concurrent companies

## `proxyConfiguration` (type: `object`):

Recommended at scale. Residential proxy keeps success high for large jobs.

## Actor input object example

```json
{
  "companies": [
    "apple",
    "https://www.importyeti.com/company/tesla"
  ],
  "maxConcurrency": 3,
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ]
  }
}
```

# 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 = {
    "companies": [
        "apple",
        "https://www.importyeti.com/company/tesla"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("xtracto/us-customs-bol").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 = { "companies": [
        "apple",
        "https://www.importyeti.com/company/tesla",
    ] }

# Run the Actor and wait for it to finish
run = client.actor("xtracto/us-customs-bol").call(run_input=run_input)

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

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

```

## CLI example

```bash
echo '{
  "companies": [
    "apple",
    "https://www.importyeti.com/company/tesla"
  ]
}' |
apify call xtracto/us-customs-bol --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=xtracto/us-customs-bol",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

```json
{
    "openapi": "3.0.1",
    "info": {
        "title": "US Customs Bill-of-Lading & Import Intelligence (ImportYeti)",
        "description": "Extract US maritime import intelligence per company — supplier relationships, shipment volume, HS codes, TEU, and contacts — from ImportYeti. Underlying data is US CBP vessel-manifest public record.",
        "version": "0.1",
        "x-build-id": "PgeSx6IikUb36HKJn"
    },
    "servers": [
        {
            "url": "https://api.apify.com/v2"
        }
    ],
    "paths": {
        "/acts/xtracto~us-customs-bol/run-sync-get-dataset-items": {
            "post": {
                "operationId": "run-sync-get-dataset-items-xtracto-us-customs-bol",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        },
        "/acts/xtracto~us-customs-bol/runs": {
            "post": {
                "operationId": "runs-sync-xtracto-us-customs-bol",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor and returns information about the initiated run in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/runsResponseSchema"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/acts/xtracto~us-customs-bol/run-sync": {
            "post": {
                "operationId": "run-sync-xtracto-us-customs-bol",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        }
    },
    "components": {
        "schemas": {
            "inputSchema": {
                "type": "object",
                "required": [
                    "companies"
                ],
                "properties": {
                    "companies": {
                        "title": "Companies",
                        "type": "array",
                        "description": "ImportYeti company slug (e.g. 'apple') or a full /company/<slug> URL.",
                        "items": {
                            "type": "string"
                        }
                    },
                    "maxConcurrency": {
                        "title": "Max concurrent companies",
                        "minimum": 1,
                        "maximum": 8,
                        "type": "integer",
                        "description": "Max concurrent companies",
                        "default": 3
                    },
                    "proxyConfiguration": {
                        "title": "Proxy",
                        "type": "object",
                        "description": "Recommended at scale. Residential proxy keeps success high for large jobs.",
                        "default": {
                            "useApifyProxy": true,
                            "apifyProxyGroups": [
                                "RESIDENTIAL"
                            ]
                        }
                    }
                }
            },
            "runsResponseSchema": {
                "type": "object",
                "properties": {
                    "data": {
                        "type": "object",
                        "properties": {
                            "id": {
                                "type": "string"
                            },
                            "actId": {
                                "type": "string"
                            },
                            "userId": {
                                "type": "string"
                            },
                            "startedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "finishedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "status": {
                                "type": "string",
                                "example": "READY"
                            },
                            "meta": {
                                "type": "object",
                                "properties": {
                                    "origin": {
                                        "type": "string",
                                        "example": "API"
                                    },
                                    "userAgent": {
                                        "type": "string"
                                    }
                                }
                            },
                            "stats": {
                                "type": "object",
                                "properties": {
                                    "inputBodyLen": {
                                        "type": "integer",
                                        "example": 2000
                                    },
                                    "rebootCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "restartCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "resurrectCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "computeUnits": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "options": {
                                "type": "object",
                                "properties": {
                                    "build": {
                                        "type": "string",
                                        "example": "latest"
                                    },
                                    "timeoutSecs": {
                                        "type": "integer",
                                        "example": 300
                                    },
                                    "memoryMbytes": {
                                        "type": "integer",
                                        "example": 1024
                                    },
                                    "diskMbytes": {
                                        "type": "integer",
                                        "example": 2048
                                    }
                                }
                            },
                            "buildId": {
                                "type": "string"
                            },
                            "defaultKeyValueStoreId": {
                                "type": "string"
                            },
                            "defaultDatasetId": {
                                "type": "string"
                            },
                            "defaultRequestQueueId": {
                                "type": "string"
                            },
                            "buildNumber": {
                                "type": "string",
                                "example": "1.0.0"
                            },
                            "containerUrl": {
                                "type": "string"
                            },
                            "usage": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "integer",
                                        "example": 1
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "usageTotalUsd": {
                                "type": "number",
                                "example": 0.00005
                            },
                            "usageUsd": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "number",
                                        "example": 0.00005
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
```
