Search Analytics API 現已支援 Google 探索、Google 新聞和規則運算式
透過集合功能整理內容
你可以依據偏好儲存及分類內容。
2021 年 10 月 25 日,星期一
目前,如果您的網站有來自 Google 搜尋、Google 探索和 Google 新聞等平台的流量,可以在 Google Search Console 的成效報表中看到相關資料。而自從推出探索和 Google 新聞的成效報表後,我們便不斷收到使用者的建議,要求將這些資料也納入 Search Analytics API。我們很高興在此宣布,從今天開始您就能在 Search Analytics API 中看到這些資料。
您原先可以在 searchType
參數中依據 news
、video
、image
以及 web
等條件篩選 API 呼叫,現在我們將這項參數重新命名為 type
,並支援另外兩個新的參數:discover
(適用於 Google 探索) 和
googleNews
(適用於 Google 新聞)。請注意,雖然我們將參數重新命名為 type
,不過系統仍支援舊的名稱 searchType
。
在 Search Console 成效報表中,部分指標和維度僅適用於某幾種資料類型,舉例來說,Google 探索報表就不支援查詢和排名。同樣地,如果您使用不支援的維度提出要求,API 就會傳回錯誤訊息。
此外,我們也在查詢和網頁維度中支援規則運算式,除了現有的比對方式外再加入兩個新的運算子:includingRegex
和 excludingRegex
。
詳情請參閱 Search Analytics API 說明文件。如有任何問題,歡迎透過搜尋中心社群或 Twitter 提問。
發文者:Search Console 團隊的 Ziv Hodak 和 Roman Priborkin
除非另有註明,否則本頁面中的內容是採用創用 CC 姓名標示 4.0 授權,程式碼範例則為阿帕契 2.0 授權。詳情請參閱《Google Developers 網站政策》。Java 是 Oracle 和/或其關聯企業的註冊商標。
[null,null,[],[[["\u003cp\u003eGoogle Search Console's Search Analytics API now includes data for Discover and Google News, alongside existing Search data.\u003c/p\u003e\n"],["\u003cp\u003eThe API's \u003ccode\u003esearchType\u003c/code\u003e parameter is renamed to \u003ccode\u003etype\u003c/code\u003e and supports new values \u003ccode\u003ediscover\u003c/code\u003e and \u003ccode\u003egoogleNews\u003c/code\u003e for filtering data.\u003c/p\u003e\n"],["\u003cp\u003eUnsupported dimensions with certain data types will result in error messages from the API, aligning with the Search Console Performance reports' behavior.\u003c/p\u003e\n"],["\u003cp\u003eRegex support is added to the API's query and page dimensions with new operators \u003ccode\u003eincludingRegex\u003c/code\u003e and \u003ccode\u003eexcludingRegex\u003c/code\u003e for enhanced filtering.\u003c/p\u003e\n"]]],["Google Search Console's API now includes data for Google Discover and Google News, accessible via new `discover` and `googleNews` parameters within the renamed `type` parameter (formerly `searchType`). The API will return an error if unsupported dimensions are requested. Regex support has been added to query and page dimensions, with `includingRegex` and `excludingRegex` operators. Users can learn more through documentation and the Search Central community.\n"],null,["# Search Analytics API now supports Discover, Google News, and Regex\n\nMonday, October 25, 2021\n\n\nThe Google Search Console [Performance reports](https://support.google.com/webmasters/answer/7576553) already show data about Search,\nDiscover, and Google News to site owners that have this type of traffic. Since we launched the [Discover](https://support.google.com/webmasters/answer/9216516)\nand [Google News](https://support.google.com/webmasters/answer/10083653) performance reports, we've been receiving requests from\nusers to also add these stats to the [Search Analytics API](/webmaster-tools/search-console-api-original/v3/searchanalytics).\nWe are happy to announce that this is happening today.\n\n\nThe `searchType` parameter, which previously enabled you to filter API calls by `news`,\n`video`, `image`, and `web`, will be renamed to\n`type` and will support two additional parameters: `discover` (for Google Discover) and\n`googleNews` (for Google News). Please note that while we renamed the parameter to `type`,\nwe're still supporting the old name `searchType`.\n\n\nIn the Search Console Performance reports, some metrics and dimensions are compatible only with some data types; for example, queries and positions are not supported by\nthe Google Discover report. In the same way, if an unsupported dimension is requested, the API will return an error message.\n\n\nIn addition, we are adding [Regex support](/search/blog/2021/06/regex-negative-match) to the query and page dimensions.\nTwo new operators will be added to the existing match operations: `includingRegex` and `excludingRegex`.\n\n\nCheck out the [Search Analytics API documentation](/webmaster-tools/search-console-api-original/v3/searchanalytics/query) to learn more.\nIf you have any questions, you can ask in the [Search Central community](https://support.google.com/webmasters/community) or\n[on Twitter](https://twitter.com/googlesearchc).\n\n\nPosted by [Ziv Hodak](/search/blog/authors/ziv-hodak) and Roman Priborkin, Search Console team"]]