Agent SkillsNeverSight/learn-skills.dev › webflow-browser-api

webflow-browser-api

GitHub

提供Webflow Browser API的JavaScript接口说明,涵盖跟踪同意管理、CMP集成、实验变体追踪及自定义访客属性设置,用于优化用户体验和数据采集。

data/skills-md/224-industries/webflow-skills/webflow-browser-api/SKILL.md NeverSight/learn-skills.dev

触发场景

需要管理Webflow网站的跟踪同意状态 集成OneTrust或TrustArc等CMP平台 追踪A/B测试实验变体结果 设置自定义访客属性以进行受众定位

安装

npx skills add NeverSight/learn-skills.dev --skill webflow-browser-api -g -y
更多选项

非标准路径

npx skills add https://github.com/NeverSight/learn-skills.dev/tree/main/data/skills-md/224-industries/webflow-skills/webflow-browser-api -g -y

不安装直接使用

npx skills use NeverSight/learn-skills.dev@webflow-browser-api

指定 Agent (Claude Code)

npx skills add NeverSight/learn-skills.dev --skill webflow-browser-api -a claude-code -g -y

安装 repo 全部 skill

npx skills add NeverSight/learn-skills.dev --all -g -y

预览 repo 内 skill

npx skills add NeverSight/learn-skills.dev --list

SKILL.md

Frontmatter
{
    "name": "webflow-browser-api",
    "license": "MIT",
    "metadata": {
        "url": "https:\/\/skills.224ai.au\/webflow-browser-api.skill",
        "author": "Ben Sabic",
        "version": "1.0.0",
        "keywords": "ai, agent, skill, analyze, browser, api, webflow, optimize, cookie consent, tracking, performance, user experience, consent management, web analytics, automation",
        "repository": "https:\/\/github.com\/224-industries\/webflow-skills"
    },
    "description": "Control Webflow Analyze and Optimize from JavaScript via the Browser API. Use when managing tracking consent, integrating CMPs (OneTrust, TrustArc), tracking experiment variations, setting custom visitor attributes, or personalizing user experiences."
}

Webflow Browser API

The Browser API is a JavaScript interface exposed via the global wf object on all Webflow sites with Analyze and Optimize enabled. It requires no manual installation. Use it to manage consent, track experiments, and personalize user experiences.

Key Concepts

  • Global wf object — Automatically available on all sites with Analyze or Optimize enabled
  • wf.ready() — All Browser API calls must be wrapped in this readiness callback. See references/wf-ready.md
  • Consent management — Three methods to manage tracking consent: getUserTrackingChoice(), allowUserTracking(), denyUserTracking()
  • Variations — Track experiment results via onVariationRecorded() and forward to analytics tools
  • Custom attributes — Set visitor attributes via setAttributes() for audience targeting and result filtering (Enterprise only)

API Methods

Method Description
wf.ready(callback) Execute code after the Browser API loads
wf.getUserTrackingChoice() Returns "allow", "deny", or "none"
wf.allowUserTracking(options?) Opt user into tracking
wf.denyUserTracking(options?) Opt user out of tracking
wf.onVariationRecorded(callback) Register a callback for variation events
wf.setAttributes(scope, attributes) Set custom visitor attributes

Important Notes

  • The Browser API is only available on sites with Webflow Analyze or Optimize enabled
  • Custom JavaScript attributes (setAttributes) are only available on Enterprise sites
  • Always wrap all API calls inside wf.ready() to prevent calls before initialization
  • Place scripts in <head> custom code for earliest possible execution

Reference Documentation

Each reference file includes YAML frontmatter with name, description, and tags for searchability. Use the search script in scripts/search_references.py to find relevant references.

Getting Started

Consent Management

Optimize

Searching References

# List all references with metadata
python scripts/search_references.py --list

# Search by tag (exact match)
python scripts/search_references.py --tag <tag>

# Search by keyword (across name, description, tags, and content)
python scripts/search_references.py --search <query>

Scripts

  • scripts/search_references.py: Search reference files by tag, keyword, or list all with metadata

版本历史

  • e0220ca 当前 2026-07-05 21:07

同 Skill 集合

data/skills-md/00prabalk00/claude-skills/knowledge-base-gap-finder/SKILL.md
data/skills-md/01000001-01001110/agent-jira-skills/jira-agile/SKILL.md
data/skills-md/01000001-01001110/agent-jira-skills/jira-auth/SKILL.md
data/skills-md/01000001-01001110/agent-jira-skills/jira-issues/SKILL.md
data/skills-md/01000001-01001110/agent-jira-skills/jira-project-management/SKILL.md
data/skills-md/01000001-01001110/agent-jira-skills/jira-projects/SKILL.md
data/skills-md/01000001-01001110/agent-jira-skills/jira-safe/SKILL.md
data/skills-md/01000001-01001110/agent-jira-skills/jira-search/SKILL.md
data/skills-md/01000001-01001110/agent-jira-skills/jira-spaces/SKILL.md
data/skills-md/01000001-01001110/agent-jira-skills/jira-transitions/SKILL.md
data/skills-md/0731coderlee-sudo/wechat-publisher/wechat-publisher/SKILL.md
data/skills-md/0froq/skills/conventionalcommits/SKILL.md
data/skills-md/0froq/skills/nuxt/SKILL.md
data/skills-md/0froq/skills/oq/SKILL.md
data/skills-md/0froq/skills/pinia/SKILL.md
data/skills-md/0froq/skills/pnpm/SKILL.md
data/skills-md/0froq/skills/slidev/SKILL.md
data/skills-md/0froq/skills/tsdown/SKILL.md
data/skills-md/0froq/skills/turborepo/SKILL.md
data/skills-md/0froq/skills/unocss/SKILL.md
data/skills-md/0froq/skills/vitepress/SKILL.md
data/skills-md/0froq/skills/vitest/SKILL.md
data/skills-md/0froq/skills/vue-best-practices/SKILL.md
data/skills-md/0froq/skills/vue-router-best-practices/SKILL.md
data/skills-md/0froq/skills/vue-testing-best-practices/SKILL.md
data/skills-md/0froq/skills/vue/SKILL.md
data/skills-md/0froq/skills/vueuse-functions/SKILL.md
data/skills-md/0froq/skills/web-design-guidelines/SKILL.md
data/skills-md/0juano/agent-skills/bondterminal-x402/SKILL.md
data/skills-md/0juano/agent-skills/edgeone-pages-deploy/SKILL.md
data/skills-md/0juano/agent-skills/ley-ar/SKILL.md
data/skills-md/0juano/agent-skills/ticktick/SKILL.md
data/skills-md/0juano/agent-skills/x-image-cards/SKILL.md
data/skills-md/0juano/x-image-cards/x-image-cards/SKILL.md
data/skills-md/0x0funky/agent-sprite-forge/generate2dsprite/SKILL.md
data/skills-md/0x0funky/agent-sprite-forge/video2dsprite/SKILL.md
data/skills-md/0x2e/superpowers/brainstorming/SKILL.md
data/skills-md/0x2e/superpowers/dispatching-parallel-agents/SKILL.md
data/skills-md/0x2e/superpowers/executing-plans/SKILL.md
data/skills-md/0x2e/superpowers/finishing-a-development-branch/SKILL.md
data/skills-md/0x2e/superpowers/receiving-code-review/SKILL.md
data/skills-md/0x2e/superpowers/requesting-code-review/SKILL.md
data/skills-md/0x2e/superpowers/subagent-driven-development/SKILL.md
data/skills-md/0x2e/superpowers/systematic-debugging/SKILL.md
data/skills-md/0x2e/superpowers/test-driven-development/SKILL.md
data/skills-md/0x2e/superpowers/using-git-worktrees/SKILL.md
data/skills-md/0x2e/superpowers/using-superpowers/SKILL.md
data/skills-md/0x2e/superpowers/verification-before-completion/SKILL.md
data/skills-md/0x2e/superpowers/writing-plans/SKILL.md
data/skills-md/0x2e/superpowers/writing-skills/SKILL.md

元信息

文件数
0
版本
e4a0f95
Hash
898e455b
收录时间
2026-07-05 21:07

首页 - Wiki
Copyright © 2011-2026 iteam. Current version is 2.155.2. UTC+08:00, 2026-08-04 08:36
浙ICP备14020137号-1 $访客地图$