# Newsletter Sponsor Tracker (`mambalabs/newsletter-sponsor-tracker`) Actor

Find who sponsors a newsletter, or which newsletters a brand sponsors. Reads public Substack, beehiiv, and other newsletter archives for sponsor placements and returns one row per sponsor with domain, placements, first and last issue seen, and issue links. For ad sales and sponsor research.

- **URL**: https://apify.com/mambalabs/newsletter-sponsor-tracker.md
- **Developed by:** [Mamba Labs](https://apify.com/mambalabs) (community)
- **Categories:** Lead generation, Automation, Social media
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $3.40 / 1,000 sponsor rows

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

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

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
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.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## 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.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## Newsletter Sponsor Tracker

Find who sponsors a newsletter, or which newsletters a brand sponsors. In newsletter mode, paste newsletter links and get one row per sponsor found in their recent issues: the sponsor name and domain, how many issues carried it, the first and last issue seen, and links to those issues, plus one summary row per newsletter. In brand mode, enter a brand and get the newsletters whose recent issues carry a sponsor placement for it. Rows are flat, so they export to CSV or drop into a Clay table.

### Features

- **Newsletter mode.** Sponsors per newsletter from its newest issues, with placements, share of issues, first and last seen, and issue links. A summary row per newsletter lists every sponsor found.
- **Brand mode.** Google result pages for the brand's sponsor lines ("presented by", "brought to you by", "sponsored by", "together with") name the candidate newsletters; each candidate's own issues are then read, and only a placement found in an issue is returned.
- **Substack, beehiiv, and more.** Substack archives through their public archive JSON, beehiiv and other hosted newsletters through their sitemap issue pages, and anything else through its RSS feed.
- **Fixed rules.** A placement is a short block with a sponsor label, and the sponsor is the first outside link beside it. The same issue always gives the same rows.
- **Clean sponsor links.** Tracking parameters are removed. A placement sold through an ad network keeps the sponsor name and no domain, rather than the network's domain.

### How it reads its sources

Public newsletter archive pages, sitemaps, and feeds, fetched directly, and in brand mode Google result pages through the Apify proxy. robots.txt is read once per host and checked before every request. A host that refuses a direct request is read through the Apify proxy. No API key, no login, no paywalled content (a paid Substack post is read from its free preview), and no other developer's actor.

### Input

| Field | Type | Default | What it does |
|---|---|---|---|
| `mode` | string | `newsletter` | `newsletter` or `brand` |
| `newsletter_urls` | array | | Newsletter mode. Home page links or domains, up to 100 |
| `brand_name` | string | | Brand mode. The sponsor name as newsletters print it |
| `brand_domain` | string | | Brand mode. The sponsor's domain |
| `newsletters_to_check` | string | `10` | Brand mode. Candidate newsletters to confirm, 1 to 10 |
| `issues_to_scan` | string | `20` | Newest issues read per newsletter, 1 to 200; at most 20 in brand mode |
| `since_days` | string | `365` | Stop at issues older than this. `0`: no limit |
| `max_charge_usd` | string | | Stop before a row would pass this amount |

Every field also accepts text, as Clay sends it: `"20"` or a comma separated list.

### Output

One row layout for every row type. Key fields:

| Field | Rows | Example |
|---|---|---|
| `row_type` | all | `sponsor`, `newsletter_summary`, `brand_summary`, `no_results` |
| `newsletter_name`, `newsletter_url`, `platform` | sponsor, newsletter summary | `Not Boring by Packy McCormick`, `https://www.notboring.co`, `substack` |
| `sponsor_name`, `sponsor_domain`, `sponsor_url` | sponsor | `Reducto`, `reducto.ai`, `https://reducto.ai` |
| `placements`, `issues_scanned`, `share_of_issues_pct` | sponsor | `5`, `10`, `50` |
| `first_seen_at`, `last_seen_at`, `issue_urls`, `issue_titles`, `placement_labels` | sponsor | |
| `sponsored_issues`, `sponsor_count`, `sponsors_list` | newsletter summary | `9`, `5`, `["Reducto","Guru"]` |
| `brand_name`, `brand_domain`, `found_via`, `newsletters_checked`, `newsletters_found` | brand mode | |
| `row_status`, `error_reason`, `billable_events_json` | all | `ok`, `null`, `{"sponsor-row":1}` |

The run summary (key-value store record `RUN_SUMMARY`) lists each newsletter's platform, issues read, and sponsors, the Google queries answered in brand mode, the requests made, and robots.txt as read per host.

### Pricing

Pay per event. You pay only these events; the Apify platform and proxy costs of your run are paid by Mamba Labs.

| Event | Free plan | Bronze | Silver | Gold |
|---|---|---|---|---|
| Sponsor row (`sponsor-row`): one sponsor of one newsletter | $0.004 | $0.0038 | $0.0036 | $0.0034 |
| Brand search (`brand-search`): brand mode only, once per run | $0.065 | $0.06175 | $0.0585 | $0.05525 |
| Actor start (`apify-actor-start`), once per run | $0.0005 | $0.0005 | $0.0005 | $0.0005 |

Free rows: newsletter summary rows, no results rows, and error rows. In brand mode the brand summary row carries the brand search event: it pays for three Google searches and for reading up to 20 recent issues of up to 10 candidate newsletters, and it is charged when at least one candidate newsletter was read, even when no placement is confirmed. A brand search that found no candidate newsletter, or could not read Google results, is free. On the Apify free plan the actor stops at 1.50 USD of evaluation a month (about 375 sponsor rows); any paid Apify plan removes that cap.

Example: one newsletter with 20 issues and 8 sponsors costs about 0.033 USD. A brand search that confirms 3 newsletters costs about 0.077 USD.

### Usage examples

#### Apify Console or API

```json
{ "mode": "newsletter", "newsletter_urls": ["https://www.notboring.co", "https://www.superhuman.ai"], "issues_to_scan": "30" }
```

```json
{ "mode": "brand", "brand_name": "Attio", "brand_domain": "attio.com", "newsletters_to_check": "10" }
```

#### Clay

Add an Apify column, send a newsletter domain from your table, and read the sponsor rows: `sponsor_name`, `sponsor_domain`, `placements`, and `last_seen_at`. A sponsor that bought several placements in your niche is a warm lead for your own ad inventory.

#### MCP

The MCP server `@mambalabsdev/mcp-newsletter-sponsor-tracker` exposes this actor as a tool for Claude and other MCP clients.

### Error handling

| Situation | What you get |
|---|---|
| No archive, sitemap, or feed is found | One free summary row with `row_status` `no_results` and the reason |
| No sponsor label in the issues scanned | The free summary row says so; no sponsor rows |
| robots.txt disallows an archive path | Those issues are skipped and the summary counts only what was read |
| Brand mode: Google result pages cannot be read | One free `blocked` brand summary row |
| Brand mode: no confirmed placement | One free `no_results` brand summary row naming how many newsletters were checked |
| Max charge reached | The run stops before the next billable row and says why in the status message |

### Limitations

- A placement needs a sponsor label in a short block. A sponsor shown only as an image with no label, or a native mention inside an article, is not found.
- A paid Substack post is read from its free preview; a sponsor placed below the paywall is not seen.
- Brand mode finds candidates through Google results, so newsletters whose issues are not indexed by Google are missed.
- Sponsor names keep the casing the placement printed, except all capital labels, which are matched to the brand's own casing in the placement text when it appears there.

### More from Mamba Labs

| Actor | Actor ID |
|---|---|
| [Account Hiring Watch](https://apify.com/mambalabs/account-hiring-watch?fpr=mamba) | `gRAZA5WBi1r6L0gy7` |
| [Agent Accessibility Auditor](https://apify.com/mambalabs/agent-accessibility-auditor?fpr=mamba) | `anxbRv0lKrpQ1pnua` |
| [Agent to Brokerage Resolver](https://apify.com/mambalabs/agent-brokerage-resolver?fpr=mamba) | `ePRRGLxOGyaVHO4dI` |
| [AI Tooling Detector](https://apify.com/mambalabs/ai-tooling-detector?fpr=mamba) | `EwkHhmqiuJgRoVEbE` |
| [B2B Reddit Conversation Monitor](https://apify.com/mambalabs/b2b-reddit-conversation-monitor?fpr=mamba) | `SoDryzzsjmY3SsiyG` |
| [Bluesky Brand Presence Mapper](https://apify.com/mambalabs/bluesky-brand-presence-mapper?fpr=mamba) | `eLpxzP4IuXznlFVND` |
| [Career Change Signal Engine](https://apify.com/mambalabs/career-change-signal-engine?fpr=mamba) | `vX2Yga1a6wGaXaP14` |
| [Company Change Event Feed](https://apify.com/mambalabs/company-change-event-feed?fpr=mamba) | `oX44rS0fkEJ3rXLWe` |
| [Company Contact Details Extractor](https://apify.com/mambalabs/company-contact-details-extractor?fpr=mamba) | `4mMncKaJykiq94grz` |
| [Company Discovery List Builder](https://apify.com/mambalabs/company-discovery-list-builder?fpr=mamba) | `jch0HdaZnpbMqlcGS` |
| [Company Firmographic Enricher](https://apify.com/mambalabs/company-firmographic-enricher?fpr=mamba) | `YlUtLWjfPpqykmB8g` |
| [Company Funding Record](https://apify.com/mambalabs/funding-investor-record?fpr=mamba) | `OFS4Mt1gyYNtGfUbE` |
| [Company Identity Resolver](https://apify.com/mambalabs/company-identity-resolver?fpr=mamba) | `lr8fTRAmZCBZmuwwh` |
| [Company Social Presence Mapper](https://apify.com/mambalabs/company-social-presence-mapper?fpr=mamba) | `4k6CCemkgBDz18m2h` |
| [Contact Classifier](https://apify.com/mambalabs/contact-classifier?fpr=mamba) | `0lGSeYJmniXhGANnO` |
| [Cookie Consent Audit](https://apify.com/mambalabs/cookie-consent-audit?fpr=mamba) | `TrKyOS0KBoGC35nbr` |
| [Domain Deliverability Checker](https://apify.com/mambalabs/domain-deliverability-checker?fpr=mamba) | `0tVgxI7A6o9jMlxmc` |
| [Domain to LinkedIn URL Resolver](https://apify.com/mambalabs/domain-to-linkedin-url-resolver?fpr=mamba) | `3HtnSaqPHOg1Qg5gx` |
| [Ecommerce Platform Profiler](https://apify.com/mambalabs/ecommerce-platform-profiler?fpr=mamba) | `5G2NeYjBbQTjaTn9L` |
| [Event Presence Index](https://apify.com/mambalabs/event-presence-index?fpr=mamba) | `WLhMy8fMDgsxdYxv5` |
| [Expert Witness Directory](https://apify.com/mambalabs/expert-witness-directory?fpr=mamba) | `LIpwlgfE3LaQBaXd4` |
| [Funding and Press Signal Scanner](https://apify.com/mambalabs/funding-press-signal-scanner?fpr=mamba) | `FS13X6dhQVgX3XOM6` |
| [GitHub Organization Signal Scanner](https://apify.com/mambalabs/github-organization-signal-scanner?fpr=mamba) | `ahF8RRpv5mzPao5CN` |
| [Google Ads Transparency Monitor](https://apify.com/mambalabs/google-ads-transparency-monitor?fpr=mamba) | `1eOwxhBVxzvOXAm4s` |
| [Government Contract Award Monitor](https://apify.com/mambalabs/public-award-monitor?fpr=mamba) | `zhEtllASykOcx9hJ8` |
| [GTM Hiring Signal Scraper](https://apify.com/mambalabs/gtm-hiring-signal-scraper?fpr=mamba) | `D7O1SA2EqwHGsGr1P` |
| [GTM Signals Aggregator](https://apify.com/mambalabs/b2b-buying-signals-hiring-tech-stack-intent-for-clay?fpr=mamba) | `xKdRfnfFNkdMpFuNs` |
| [ICP Fit Scorer](https://apify.com/mambalabs/icp-account-lead-scoring-fit-scorer-0-100-for-clay?fpr=mamba) | `W161DT8W4kW55dMFh` |
| [Influencer Change Monitor](https://apify.com/mambalabs/creator-change-monitor?fpr=mamba) | `d2VVgahNL6UmcLkhg` |
| [Influencer Finder](https://apify.com/mambalabs/creator-finder?fpr=mamba) | `tpkedmloIIWtXx6sg` |
| [Influencer Lead List Builder](https://apify.com/mambalabs/creator-lead-list-all-in-one?fpr=mamba) | `KnmByszcv135yM30G` |
| [Influencer Profile Scraper](https://apify.com/mambalabs/creator-profile-reader?fpr=mamba) | `EqEnklDVMIcB1V499` |
| [Influencer Talent Agency Lookup](https://apify.com/mambalabs/talent-agency-lookup?fpr=mamba) | `zCuX4Mgyg6JvXgGzd` |
| [Instagram Facebook Brand Presence Mapper](https://apify.com/mambalabs/meta-brand-presence-mapper?fpr=mamba) | `HXh65I0JBjPsunbY8` |
| [Integration and Marketplace Presence Mapper](https://apify.com/mambalabs/integration-marketplace-presence-mapper?fpr=mamba) | `V0guNuvM85Q61f2gj` |
| [Job Board Keyword Signal Scanner](https://apify.com/mambalabs/job-board-keyword-signal-scanner?fpr=mamba) | `4DvqpvhMR74NLcDDY` |
| [Job Change Tracker](https://apify.com/mambalabs/job-change-tracker?fpr=mamba) | `L8UbEmMJC1XYPSZOb` |
| [Job Posting Monitor](https://apify.com/mambalabs/gtm-job-discovery?fpr=mamba) | `QCfICD9kOPiOdj5iI` |
| [Legal Entity Resolver](https://apify.com/mambalabs/legal-entity-resolver?fpr=mamba) | `KHFyPCDIx7CyqULYm` |
| [Link in Bio Scraper and Newsletter Detector](https://apify.com/mambalabs/link-in-bio-newsletter-checker?fpr=mamba) | `OorucdheTIgu7RFzK` |
| [LinkedIn Company Page Mapper](https://apify.com/mambalabs/linkedin-company-presence-mapper?fpr=mamba) | `zOPm6A9JEhUGcIdFW` |
| [LinkedIn Post Tracker](https://apify.com/mambalabs/linkedin-post-engager-capture?fpr=mamba) | `oiGLNPuaf5BRaz9K5` |
| [Meta Ad Library Monitor](https://apify.com/mambalabs/meta-ad-library-monitor?fpr=mamba) | `J1GWlSXfSGU3u8Wng` |
| [Mobile Phone Waterfall](https://apify.com/mambalabs/mobile-phone-waterfall-orchestrator?fpr=mamba) | `6OOgPktf7RIa5XCOP` |
| [New Hire Finder](https://apify.com/mambalabs/new-hire-finder?fpr=mamba) | `cKuc38p4nYHNF3IW8` |
| [Outbound Stack Detector](https://apify.com/mambalabs/outbound-infrastructure-fingerprint?fpr=mamba) | `v43UJC8r7qW7cBSTG` |
| [Page Finder and Extractor](https://apify.com/mambalabs/page-finder-extractor?fpr=mamba) | `TpurgcOZbVnknlaiC` |
| [People Finder & Email Verifier](https://apify.com/mambalabs/people-finder?fpr=mamba) | `LEgloG7tWgQl4o6TD` |
| [Person Social Footprint Mapper](https://apify.com/mambalabs/person-social-footprint-mapper?fpr=mamba) | `jfQXa2zW9FHCJot9K` |
| [Pinterest Brand Presence Mapper](https://apify.com/mambalabs/pinterest-brand-presence-mapper?fpr=mamba) | `d1HvjZfKhgvWsoEwn` |
| [Prospect Engine](https://apify.com/mambalabs/b2b-prospect-engine?fpr=mamba) | `q9rT6v64nUJdPexOQ` |
| [Publishing Frequency Tracker](https://apify.com/mambalabs/blog-publishing-frequency?fpr=mamba) | `TbLwaUUATdYb6wp4N` |
| [Reddit Brand Presence Mapper](https://apify.com/mambalabs/reddit-brand-presence-mapper?fpr=mamba) | `pKQZmDaT70SEb54bZ` |
| [Reporting Window Finder](https://apify.com/mambalabs/public-company-reporting-window-finder?fpr=mamba) | `uINxR7a1IW8qUTRUX` |
| [Sequencer Lead Push](https://apify.com/mambalabs/clay-to-instantly-smartlead-push?fpr=mamba) | `0Jv27VeWM5tSZQs9x` |
| [Team Page People Extractor](https://apify.com/mambalabs/team-page-people-extractor?fpr=mamba) | `j8a9zX0k4mNbvDbWK` |
| [Tech Stack Signal Detector](https://apify.com/mambalabs/gtm-tech-stack-signal-scraper?fpr=mamba) | `qyd7nNyqFPelQViBx` |
| [TikTok Brand Presence Mapper](https://apify.com/mambalabs/tiktok-brand-presence-mapper?fpr=mamba) | `fco8FvoJcSafbeyd1` |
| [Trustpilot Reputation Enricher](https://apify.com/mambalabs/review-platform-reputation-enricher?fpr=mamba) | `3lIqfCt61j4hqE1xz` |
| [WCAG Accessibility Audit](https://apify.com/mambalabs/wcag-accessibility-audit?fpr=mamba) | `P3jBj3FRghKEhX52z` |
| [Website Traffic Rank Estimator](https://apify.com/mambalabs/website-traffic-rank-estimator?fpr=mamba) | `GnOFUzlNVIoXgeJjH` |
| [Work Email Waterfall](https://apify.com/mambalabs/email-waterfall-orchestrator?fpr=mamba) | `OT6xqTFThC0Rjf7Zj` |
| [Workplace Program Detector](https://apify.com/mambalabs/workplace-program-detector?fpr=mamba) | `Li6pPDhqbdzFz3h7G` |
| [X Brand Presence Mapper](https://apify.com/mambalabs/x-brand-presence-mapper?fpr=mamba) | `oLOgadhHUkNAyDA3w` |
| [YouTube Channel Stats Extractor](https://apify.com/mambalabs/youtube-channel-transcript-extractor?fpr=mamba) | `6hSpD3kd2s2IQ4VSs` |
| [Website Phrase and Business Model Classifier](https://apify.com/mambalabs/website-phrase-business-model-classifier?fpr=mamba) | `CBuZ9k7sRwBeiKiCS` |
| [Competitor Price, Stock, and Changelog Monitor](https://apify.com/mambalabs/competitor-price-stock-changelog-monitor?fpr=mamba) | `yxdgCbUQ4PYQWwRNU` |
| [Open Tender and RFP Finder](https://apify.com/mambalabs/open-tender-rfp-finder?fpr=mamba) | `kPTGz6t6TFoUUyfaO` |
| [New Company Registrations Feed](https://apify.com/mambalabs/new-company-registrations-feed?fpr=mamba) | `g2WfZhWvCtc57g2Jo` |
| [Manufacturer and Supplier Finder](https://apify.com/mambalabs/manufacturer-supplier-finder?fpr=mamba) | `Qcsdmd0lUfPzVkonh` |
| [Local Rank and Map Pack Tracker](https://apify.com/mambalabs/local-rank-map-pack-tracker?fpr=mamba) | `gv0kyHGDIg8XscclB` |
| [Company Headcount Estimator](https://apify.com/mambalabs/company-headcount-estimator?fpr=mamba) | `aHC4GROnNt6kfZe5r` |
| [Person LinkedIn URL Resolver](https://apify.com/mambalabs/person-linkedin-url-resolver?fpr=mamba) | `ssuyPV8LnEsL8qbnb` |
| [Personal Email to Company Resolver](https://apify.com/mambalabs/personal-email-to-company-resolver?fpr=mamba) | `AefT5Ye6YNPFQwJBf` |
| [Partner and Member Directory Extractor](https://apify.com/mambalabs/partner-member-directory-extractor?fpr=mamba) | `ZX0XJPPUvnFJxeC1a` |
| [Local Business Lead Builder](https://apify.com/mambalabs/local-business-lead-builder?fpr=mamba) | `qMN97aoHhsAS5bznV` |
| [Ecommerce Store Discovery](https://apify.com/mambalabs/ecommerce-store-discovery?fpr=mamba) | `PeHu4sLyFvQHXUUrX` |
| [Contractor License Lookup](https://apify.com/mambalabs/contractor-license-lookup?fpr=mamba) | `WBYK3CPI2kdeq4bP1` |
| [Sequencer Event Poller](https://apify.com/mambalabs/sequencer-event-poller?fpr=mamba) | `S6s8Rjd61tGdrMRk4` |
| [Lookalike Company Finder](https://apify.com/mambalabs/lookalike-company-finder?fpr=mamba) | `e2O426WBAbLLQL4Z2` |
| [Public Feature Board and Roadmap Monitor](https://apify.com/mambalabs/public-feature-board-roadmap-monitor?fpr=mamba) | `rcHF5gj5r2Vqnry35` |
| [VC and Accelerator Portfolio List Builder](https://apify.com/mambalabs/vc-accelerator-portfolio-list-builder?fpr=mamba) | `chH8hrfuoqqolW06m` |
| [Podcast Guest and Host Finder](https://apify.com/mambalabs/podcast-guest-host-finder?fpr=mamba) | `o2MGSvgbSLeeXOsIo` |

Built by [Mamba Labs](https://apify.com/mambalabs?fpr=mamba).

# Actor input Schema

## `mode` (type: `string`):

newsletter: newsletter links in, sponsors out. brand: a brand in, the newsletters that ran its sponsor placements out.

## `newsletter_urls` (type: `array`):

Newsletter mode. Home page links or domains of Substack, beehiiv, or other hosted newsletters, up to 100, for example notboring.co or newsletter.pragmaticengineer.com.

## `brand_name` (type: `string`):

Brand mode. The sponsor name as newsletters print it, for example Attio.

## `brand_domain` (type: `string`):

Brand mode. The sponsor's domain, for example attio.com. A placement counts when its link goes to this domain or its name equals the brand name.

## `newsletters_to_check` (type: `string`):

Brand mode. Candidate newsletters found in Google results whose issues are read to confirm the placement, 1 to 10.

## `issues_to_scan` (type: `string`):

Newest issues read per newsletter, 1 to 200 in newsletter mode and at most 20 in brand mode.

## `since_days` (type: `string`):

Stop at issues older than this many days. 0: no date limit.

## `max_charge_usd` (type: `string`):

Stop before a row would push this run past this amount. Empty: no limit beyond the one you set in Apify.

## `source_tag` (type: `string`):

Internal attribution tag for published tasks. Leave empty.

## Actor input object example

```json
{
  "mode": "newsletter",
  "newsletter_urls": [
    "https://www.notboring.co"
  ],
  "newsletters_to_check": "10",
  "issues_to_scan": "10",
  "since_days": "365"
}
```

# Actor output Schema

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

No description

## `run_summary` (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 = {
    "mode": "newsletter",
    "newsletter_urls": [
        "https://www.notboring.co"
    ],
    "issues_to_scan": "10"
};

// Run the Actor and wait for it to finish
const run = await client.actor("mambalabs/newsletter-sponsor-tracker").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 = {
    "mode": "newsletter",
    "newsletter_urls": ["https://www.notboring.co"],
    "issues_to_scan": "10",
}

# Run the Actor and wait for it to finish
run = client.actor("mambalabs/newsletter-sponsor-tracker").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 '{
  "mode": "newsletter",
  "newsletter_urls": [
    "https://www.notboring.co"
  ],
  "issues_to_scan": "10"
}' |
apify call mambalabs/newsletter-sponsor-tracker --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,mambalabs/newsletter-sponsor-tracker"
        }
    }
}
```

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/qSwpqxD1TiPZpLQHv/builds/9mAvO2jiX1PBoClrz/openapi.json
