Token导航 LogoToken导航TokenDH.com
研究检索敏感数据clawhub未标认证来源可访问clear审计提醒

meta-ads-collector-adarsh元广告收集器 adarsh

Agent Skill

meta-ads-collector-adarsh 用于查找、检索和筛选相关信息,适合在 OpenClaw 中需要根据关键词、任务场景或来源线索快速定位候选结果时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

总安装

8,508

周安装

351

GitHub Stars

公开资料未说明

下载量

2,780
OpenClaw

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

2

许可证

MIT-0

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:meta-ads-collector-adarsh(元广告收集器 adarsh)
来源仓库:https://github.com/adarshvmore/meta-ads-collector-adarsh
安装命令:
openclaw skills install meta-ads-collector-adarsh
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 OpenClaw 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

ClawHubOpenClaw
openclaw skills install meta-ads-collector-adarsh

简介

收集品牌的活跃元广告,报告广告总数、格式、广告类型、最长的广告持续时间以及预计支出(如果有)。

SKILL.md

Meta Ads Collector Skill

Purpose

Scans the Meta Ad Library API to find active advertisements for a given brand. Extracts the number of active ads, ad formats used, ad types, and the longest-running ad duration. This collector feeds into the Marketing Audit Pipeline to populate the Paid Ads Strategy section of the final report.

Input Schema

// Function signature
collectMetaAds(brandName: string, domain?: string): Promise<MetaAdsData>

// brandName: The brand name to search for in the Ad Library (e.g. "Gymshark")
// domain: Optional domain to refine search (e.g. "gymshark.com"). Used to filter
// results and improve relevance when the brand name is ambiguous.

Output Schema

interface MetaAdsData {
 activeAds: number; // Total count of currently active ads
 formatsUsed: string[]; // e.g. ["image", "video", "carousel"]
 longestRunningAdDays: number; // Days the longest-running active ad has been live
 adTypes: string[]; // e.g. ["POLITICAL_AND_ISSUE_ADS", "HOUSING_ADS", "OTHER"]
 estimatedSpend?: string; // e.g. "$10,000 - $50,000" (if available from API)
 error?: string; // Present only when collector fails
}

API Dependencies

  • API Name: Meta Ad Library API
  • Endpoint: https://graph.facebook.com/v19.0/ads_archive
  • Auth: META_ACCESS_TOKEN environment variable (requires a Facebook App with Ad Library API access)
  • Additional env vars: META_APP_ID, META_APP_SECRET (used for token generation if needed)
  • Cost estimate: Free (no per-request charge)
  • Rate limits: Subject to Meta's standard Graph API rate limits (~200 calls/hour)

Implementation Pattern

Data Flow

  1. Receive brandName and optional domain from the pipeline
  2. Call metaAdsService.getMetaAds(brandName, domain) which queries the Ad Library API
  3. Process the returned ads array to extract metrics
  4. Map processed data to the MetaAdsData interface

API Query Parameters

{
 access_token: process.env.META_ACCESS_TOKEN,
 search_terms: brandName,
 ad_reached_countries: "['US']", // Default to US; can be expanded
 ad_active_status: "ACTIVE", // Only fetch currently active ads
 ad_type: "ALL", // Include all ad types
 fields: "id,ad_creation_time,ad_creative_bodies,ad_creative_link_captions,ad_creative_link_titles,ad_delivery_start_time,ad_snapshot_url,page_name",
 limit: 100 // Max results per page
}

Metrics Calculation

Active Ads Count:

  • Count the total number of ads returned from the API response

Formats Detection:

  • Analyze ad_snapshot_url or creative fields to classify format
  • Categories: "image", "video", "carousel", "dynamic", "collection"
  • Deduplicate into a unique list

Longest Running Ad:

const now = new Date();
const longestRunningAdDays = Math.max(
 ...ads.map(ad => {
 const startDate = new Date(ad.ad_delivery_start_time);
 return Math.floor((now.getTime() - startDate.getTime()) / (1000 * 60 * 60 * 24));
 })
);

Ad Types:

  • Extract unique ad_type values from the response
  • Common types: "POLITICAL_AND_ISSUE_ADS", "HOUSING_ADS", "CREDIT_ADS", "EMPLOYMENT_ADS", general/uncategorized

Estimated Spend:

  • Only available for political/issue ads (Meta requirement)
  • For other ad types, this field will be undefined
  • If available, format as a range string: "$10,000 - $50,000"

Domain Filtering

When domain is provided:

  • Filter results to only include ads where the creative body, link caption, or link title references the domain
  • This improves accuracy for brands with common names

Error Handling

  • Entire function wrapped in try/catch
  • On failure, return EMPTY_META_ADS_DATA with error field set:
 return { ...EMPTY_META_ADS_DATA, error: 'Meta Ads data unavailable: <reason>' };
  • Never throw -- always return a valid MetaAdsData object
  • Log errors with Winston logger including brandName and error details:
 logger.error('Meta Ads collector failed', { brandName, domain, err });
  • Common failure scenarios:

- Access token invalid, expired, or lacking Ad Library permissions - Brand name returns zero results (not necessarily an error -- return zeroed data without error flag) - Rate limit exceeded (Meta Graph API throttling) - Network timeout

Example Usage

import { collectMetaAds } from '../collectors/metaAdsCollector';

// Successful collection
const data = await collectMetaAds('Gymshark', 'gymshark.com');
// Returns:
// {
// activeAds: 47,
// formatsUsed: ["image", "video", "carousel"],
// longestRunningAdDays: 182,
// adTypes: ["OTHER"],
// estimatedSpend: undefined,
// }

// No ads found (not an error)
const noAds = await collectMetaAds('TinyLocalShop');
// Returns:
// {
// activeAds: 0,
// formatsUsed: [],
// longestRunningAdDays: 0,
// adTypes: [],
// }

// Failed collection (graceful degradation)
const failedData = await collectMetaAds('Gymshark');
// Returns:
// {
// activeAds: 0,
// formatsUsed: [],
// longestRunningAdDays: 0,
// adTypes: [],
// error: "Meta Ads data unavailable: Access token expired"
// }

Notes

  • The collector depends on metaAdsService.ts for the actual API communication. The collector handles only data aggregation and metric calculation.
  • Meta Ad Library API requires a Facebook App registered with Ad Library access. The app must be reviewed and approved by Meta for production use.
  • The API only returns publicly available ad data. Spend data is only available for political/issue ads as mandated by Meta's transparency policies.
  • Zero active ads is a valid result (small or new brands may not run Meta ads) and should be returned without an error flag.
  • The EMPTY_META_ADS_DATA constant is defined in src/types/audit.types.ts and should be imported for fallback returns.
  • This collector must never block the pipeline. Even a complete failure returns valid typed data with an error flag.
  • Pagination: the Meta API returns a maximum of 100 results per page. For brands with many ads, pagination via the after cursor may be needed. For audit purposes, the first page (100 ads) is sufficient.

适合场景

01

OpenClaw 用户查找和安装 Skill 时

02

用户想查找某类 Agent Skill 时

03

需要根据任务场景推荐可安装能力包时

04

需要对比不同来源的安装命令和来源信息时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

补充不同宿主或平台的使用分布数据

能力 5

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

OpenClaw

98.12%
按下载量换算2,728

安全审计

VirusTotal

通过

ClawScan

可疑

Static analysis

通过

权限和风险

敏感数据

该 Skill 可能接触密钥、Token、环境变量或敏感配置,应进入高风险复核队列,默认不自动发布。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。来源安全扫描存在 warning/failed 结果,不能写成本站确认安全。当前只有一个来源,正式发布前建议补源仓库或其他目录站核验。

来源信息

继续浏览同类 Skills