作者:我叫李剑飞
链接:https://zhuanlan.zhihu.com/p/7297693595
来源:知乎
著作权归作者所有。商业转载请联系作者获得授权,非商业转载请注明出处。

在出海鼓励师哥飞的群里看到有人分享了similarweb的一个免费接口,可以利用这个接口查询一个网站的seo数据(全球)。比如查询github网站的数据,以下是结果(数据太长,删减部分):

{
    "Version": 1,
    "SiteName": "github.com",
    "Description": "github is where people build software. more than 100 million people use github to discover, fork, and contribute to over 420 million projects.",
    "TopCountryShares": [
        {
            "Country": 840,
            "CountryCode": "US",
            "Value": 0.19023123986962243
        },
        {
            "Country": 156,
            "CountryCode": "CN",
            "Value": 0.11990945120398212
        },
        {
            "Country": 356,
            "CountryCode": "IN",
            "Value": 0.09201218977053877
        },
        {
            "Country": 643,
            "CountryCode": "RU",
            "Value": 0.05248148163858942
        },
        {
            "Country": 276,
            "CountryCode": "DE",
            "Value": 0.036331988009448195
        }
    ],
    "Title": "github · build and ship software on a single, collaborative platform · github",
    "Engagments": {
        "BounceRate": "0.37204507113135843",
        "Month": "10",
        "Year": "2024",
        "PagePerVisit": "5.811610887707274",
        "Visits": "515580771",
        "TimeOnSite": "402.64037327214356"
    },
    "EstimatedMonthlyVisits": {
        "2024-08-01": 503747431,
        "2024-09-01": 488643166,
        "2024-10-01": 515580771
    },
    "GlobalRank": {
        "Rank": 68
    },
    "CountryRank": {
        "Country": 840,
        "CountryCode": "US",
        "Rank": 92
    },
    "CategoryRank": {
        "Rank": "6",
        "Category": "Computers_Electronics_and_Technology/Programming_and_Developer_Software"
    },
    "GlobalCategoryRank": null,
    "IsSmall": false,
    "Policy": 0,
    "TrafficSources": {
        "Social": 0.021492119879503738,
        "Paid Referrals": 0.0009630006734158815,
        "Mail": 0.0004514546433376369,
        "Referrals": 0.1252090728955286,
        "Search": 0.329193510513485,
        "Direct": 0.522690841388969
    },
    "Category": "computers_electronics_and_technology/programming_and_developer_software",
    "LargeScreenshot": "https://site-images.similarcdn.com/image?url=github.com&t=1&s=1&h=6525c30f1af9ea5ee8912788b611744e1debcba39a2d0dd3d410b2916169883b",
    "IsDataFromGa": false,
    "Countries": [
        {
            "Code": "AF",
            "UrlCode": "afghanistan",
            "Name": "Afghanistan"
        },
        {
            "Code": "AX",
            "UrlCode": "land-islands",
            "Name": "Åland Islands"
        }
    ],
    "Competitors": {
        "TopSimilarityCompetitors": []
    },
    "Notification": {
        "Content": null
    },
    "TopKeywords": [
        {
            "Name": "github",
            "EstimatedValue": 2293297,
            "Volume": 4035850,
            "Cpc": 0.9864851875
        },
        {
            "Name": "goodbyedpi",
            "EstimatedValue": 545927,
            "Volume": 336790,
            "Cpc": 0.83548
        },
        {
            "Name": "bloxstrap",
            "EstimatedValue": 167654,
            "Volume": 333740,
            "Cpc": 0.27406840625
        },
        {
            "Name": "github copilot",
            "EstimatedValue": 159003,
            "Volume": 429620,
            "Cpc": 1.53533375
        },
        {
            "Name": "c",
            "EstimatedValue": 119199,
            "Volume": 20793850,
            "Cpc": 0.399434
        }
    ],
    "SnapshotDate": "2024-10-01T00:00:00+00:00"
}

这份接口数据包含了啥呢,我用ChatGPT帮我解读了一下:

### **1. 网站概况**
– **站点名称 (SiteName)**: `github.com`
– **描述 (Description)**: GitHub 是一个协作开发平台,全球有超过 1 亿用户在这里开发、分叉和贡献超过 4.2 亿个项目。
– **标题 (Title)**: “Build and ship software on a single, collaborative platform”.

### **2. 全球排名与类别**
– **全球排名 (GlobalRank)**: 68
– **美国排名 (CountryRank)**: 美国排名第 92 位(主要流量来源国)。
– **类别排名 (CategoryRank)**: 位于编程和开发软件领域中排名第 6。
– **类别 (Category)**: “Computers, Electronics, and Technology > Programming and Developer Software”。

### **3. 流量与参与度**
– **每月访问量 (EstimatedMonthlyVisits)**: 最近三个月的访问量趋势:
– **2024-08**: 503,747,431 次
– **2024-09**: 488,643,166 次
– **2024-10**: 515,580,771 次(10月访问量增长)。
– **网站参与度 (Engagements)**:
– **跳出率 (BounceRate)**: 37.20%(用户访问后直接离开率,较低)。
– **每次访问页数 (PagePerVisit)**: 5.81 页
– **平均访问时长 (TimeOnSite)**: 402.64 秒(大约 6 分钟)。
– **月访问量 (Visits)**: 515,580,771 次

### **4. 流量来源**
– **直接访问 (Direct)**: 52.27%(通过输入网址等方式直接访问)。
– **搜索引擎 (Search)**: 32.92%(通过搜索引擎访问)。
– **推荐 (Referrals)**: 12.52%(通过外部链接)。
– **社交媒体 (Social)**: 2.15%(通过社交媒体访问)。
– **邮件 (Mail)**: 0.045%。
– **付费推广 (Paid Referrals)**: 0.096%。

### **5. 国家分布**
– **主要流量来源国家 (TopCountryShares)**:
– **美国 (US)**: 19.02%
– **中国 (CN)**: 11.99%
– **印度 (IN)**: 9.20%
– **俄罗斯 (RU)**: 5.25%
– **德国 (DE)**: 3.63%

### **6. 搜索关键词**
– **关键字列表 (TopKeywords)**:
– **github**: 流量最高,搜索量 4,035,850,CPC(每次点击成本)$0.99。
– **goodbyedpi**: 搜索量 336,790,CPC $0.84。
– **bloxstrap**: 搜索量 333,740,CPC $0.27。
– **github copilot**: 搜索量 429,620,CPC $1.54。
– **c**: 搜索量极高(20,793,850),CPC $0.40,但相关性较低。

### **7. 竞争分析**
– **竞争对手 (Competitors)**: 数据中未列出任何竞争对手。

### **8. 其他信息**
– **截图链接**: 网站的大尺寸截图可通过 [此链接](site-images.similarcdn.com) 查看。
– **数据来源 (IsDataFromGa)**: 数据并非来源于 Google Analytics。
– **快照时间 (SnapshotDate)**: 2024年10月1日。

### **总结**
GitHub 是一个全球领先的编程协作平台,访问量极高,直接访问和搜索是其主要流量来源。其用户群体集中在美国、中国和印度,但也覆盖全球多个国家。其在编程与开发软件领域的排名和全球排名都非常突出,用户访问时间长且跳出率低,说明网站粘性较强。

这样就清晰的展示了一个网站的seo数据以及其热门关键词。

既然是通过接口获取,那么可以使用coze工作流来将整个流程自动化,以后你只要丢一个关键词给AI,AI就能帮你进行井井有条的分析,而且是完全免费的,算是多一个称手的工具。

说干就干,打开coze(海外版)新建一条工作流,名字就取similarweb:

进入工作流界面,把开始节点里的用户手动输入参数删除:

然后拖入一个大模型节点,这个节点用来将用户输入的域名规范化,以防用户输入不规范导致接口调用失败:

在User Prompt处输入提示词:

提取{{input}}里的域名,并直接输出根域名,确保输出是规范化的根域名。例如,如果用户输入“https://www.github.com/”,则输出“github.com”。

为了让节点直接输出域名,将节点的输出格式设置为文本。

在后面拖入一个代码节点,节点接收的就是上个节点输出的域名:

节点里的代码如下:

async function main({ params }: Args): Promise<Output> {
    const url = `接口地址`;
   
    try {
        const response = await fetch(url);
        if (!response.ok) {
            throw new Error(`HTTP error! status: ${response.status}`);
        }
       
        const data = await response.json();
       
        const ret = {
            "key0":data
        }

        return ret;
    } catch (error) {
        console.error('Error fetching data:', error);
        throw error;
    }
}

这段代码的作用就是将接收的域名作为接口的参数,请求接口并拿到返回的json数据然后输出,这里不需要对返回的json数据做任何处理,我们将在下一个大模型节点进行处理。

然后拖入一个大模型节点,用于解读json数据:

这个节点的系统提示词如下:

# Role
You are a website data analyst who uses similarweb's free API to interpret website data in a clear and structured manner.


## Skills
### Skill 1: Interpret Website Overview
- When a user provides similarweb JSON data, extract and present the website's name, description, and title.
- Example response:
=====
1. 网站概况
站点名称 (SiteName): <SiteName>
描述 (Description): <Description>
标题 (Title): <Title>
=====


### Skill 2: Global and Category Rankings
- Extract and present the website's global rank, country rank, category rank, and category.
- Example response:
=====
2. 全球排名与类别
全球排名 (GlobalRank): <GlobalRank>
美国排名 (CountryRank): <CountryRank>
类别排名 (CategoryRank): <CategoryRank>
类别 (Category): <Category>
=====


### Skill 3: Traffic and Engagement
- Extract and present the website's estimated monthly visits for the last three months, engagement metrics such as bounce rate, pages per visit, average visit duration, and monthly visits.
- Example response:
=====
3. 流量与参与度
每月访问量 (EstimatedMonthlyVisits): 最近三个月的访问量趋势:
<Month-Year>: <Visits> 次
<Month-Year>: <Visits> 次
<Month-Year>: <Visits> 次(<Trend>)。
网站参与度 (Engagements):
跳出率 (BounceRate): <BounceRate>(用户访问后直接离开率)。
每次访问页数 (PagePerVisit): <PagePerVisit> 页
平均访问时长 (TimeOnSite): <TimeOnSite> 秒
月访问量 (Visits): <Visits> 次
=====


### Skill 4: Traffic Sources
- Extract and present the website's traffic sources including direct, search, referrals, social, mail, and paid referrals.
- Example response:
=====
4. 流量来源
直接访问 (Direct): <Direct>(通过输入网址等方式直接访问)。
搜索引擎 (Search): <Search>(通过搜索引擎访问)。
推荐 (Referrals): <Referrals>(通过外部链接)。
社交媒体 (Social): <Social>(通过社交媒体访问)。
邮件 (Mail): <Mail>。
付费推广 (Paid Referrals): <PaidReferrals>。
=====


### Skill 5: Country Distribution
- Extract and present the top countries contributing to the website's traffic.
- Example response:
=====
5. 国家分布
主要流量来源国家 (TopCountryShares):
<Country1>: <Share1>%
<Country2>: <Share2>%
<Country3>: <Share3>%
<Country4>: <Share4>%
<Country5>: <Share5>%
=====


### Skill 6: Search Keywords
- Extract and present the top search keywords driving traffic to the website, including search volume and CPC.
- Example response:
=====
6. 搜索关键词
关键字列表 (TopKeywords):
<Keyword1>: 流量最高,搜索量 <Volume1>,CPC(每次点击成本)$<CPC1>。
<Keyword2>: 搜索量 <Volume2>,CPC $<CPC2>。
<Keyword3>: 搜索量 <Volume3>,CPC $<CPC3>。
<Keyword4>: 搜索量 <Volume4>,CPC $<CPC4>。
<Keyword5>: 搜索量极高(<Volume5>),CPC $<CPC5>,但相关性较低。
=====


### Skill 7: Competitor Analysis
- Extract and present the website's competitors if available.
- Example response:
=====
7. 竞争分析
竞争对手 (Competitors): <Competitors>
=====


### Skill 8: Additional Information
- Extract and present additional information such as screenshot link, data source, and snapshot date.
- Example response:
=====
8. 其他信息
截图链接: 网站的大尺寸截图可通过 <ScreenshotLink> 查看。
数据来源 (IsDataFromGa): <IsDataFromGa>
快照时间 (SnapshotDate): <SnapshotDate>
=====


## Constraints
- The output content must be organized according to the given format and should not deviate from the framework requirements.
- Only output content that exists in the JSON data provided by similarweb.
- output in Chinese.

用户提示词如下:

对{{input}}进行解读

节点输出格式为文本。

然后连接结束节点,整条工作流完成,测试一下:

测试结果如下,和ChatGPT解读的差不多:

=====
1. 网站概况
站点名称 (SiteName): github.com
描述 (Description): github is where people build software. more than 100 million people use github to discover, fork, and contribute to over 420 million projects.
标题 (Title): github · build and ship software on a single, collaborative platform · github
=====

=====
2. 全球排名与类别
全球排名 (GlobalRank): 68
美国排名 (CountryRank): 92
类别排名 (CategoryRank): 6
类别 (Category): Computers_Electronics_and_Technology/Programming_and_Developer_Software
=====

=====
3. 流量与参与度
每月访问量 (EstimatedMonthlyVisits): 最近三个月的访问量趋势:2024-08: 503747431 次
2024-09: 488643166 次
2024-10: 515580771 次(上升)。网站参与度 (Engagements):
跳出率 (BounceRate): 37.20%(用户访问后直接离开率)。每次访问页数 (PagePerVisit): 5.81 页
平均访问时长 (TimeOnSite): 402.64 秒
月访问量 (Visits): 515580771 次
=====

=====
4. 流量来源
直接访问 (Direct): 52.27%(通过输入网址等方式直接访问)。搜索引擎 (Search): 32.92%(通过搜索引擎访问)。推荐 (Referrals): 12.52%(通过外部链接)。社交媒体 (Social): 2.15%(通过社交媒体访问)。邮件 (Mail): 0.05%。付费推广 (Paid Referrals): 0.10%。=====

=====
5. 国家分布
主要流量来源国家 (TopCountryShares):
美国 (US): 19.02%
中国 (CN): 11.99%
印度 (IN): 9.20%
俄罗斯 (RU): 5.25%
德国 (DE): 3.63%
=====

=====
6. 搜索关键词
关键字列表 (TopKeywords):
github: 流量最高,搜索量 4035850,CPC(每次点击成本)$0.99。goodbyedpi: 搜索量 336790,CPC $0.84。bloxstrap: 搜索量 333740,CPC $0.27。github copilot: 搜索量 429620,CPC $1.54。c: 搜索量极高(20793850),CPC $0.40,但相关性较低。=====

=====
7. 竞争分析
竞争对手 (Competitors): 无
=====

=====
8. 其他信息
截图链接: 网站的大尺寸截图可通过 [这里](site-images.similarcdn.com) 查看。数据来源 (IsDataFromGa): false
快照时间 (SnapshotDate): 2024-10-01
=====

我会将工作流做出智能体发布到coze商店供大家使用,有需要的请关注我。