Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/api/5.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Php 网站管理员工具api维度_Php_Api_Google Webmaster Tools - Fatal编程技术网

Php 网站管理员工具api维度

Php 网站管理员工具api维度,php,api,google-webmaster-tools,Php,Api,Google Webmaster Tools,我想知道是否有人有一个可用的维度列表,可以与网站管理员工具API一起使用 在官方文档中,我找不到可用的尺寸 这是我的密码: $webmastersService = new Google_Service_Webmasters($client); $searchanalytics = $webmastersService->searchanalytics; $request = new Google_Service_Webmasters_SearchAnalyticsQueryRequest

我想知道是否有人有一个可用的维度列表,可以与网站管理员工具API一起使用

在官方文档中,我找不到可用的尺寸

这是我的密码:

$webmastersService = new Google_Service_Webmasters($client);
$searchanalytics = $webmastersService->searchanalytics;
$request = new Google_Service_Webmasters_SearchAnalyticsQueryRequest;

$request->setStartDate('2013-01-01');
$request->setEndDate('2015-01-01');
$request->setDimensions(array("[query]"));

$qsearch = $searchanalytics->query("http://www.example.com", $request); 
$rows = $qsearch->getRows();
我想知道在这一行进行更改后,可以从网站管理员工具api获得哪些数据

$request->setDimensions(array("[query]"));

我的想法是从谷歌网站管理员工具中获取最大类型的数据,如查询、查询详细信息、页面、爬网统计、外部链接、反向链接等。

有关搜索查询的信息,您可以在搜索分析中找到。下面列出了支持的尺寸

Acceptable values are:
"country": Filter against the specified country, as specified by 3-letter country code (ISO 3166-1 alpha-3).
"device": Filter results against the specified device type. Supported values:
DESKTOP
MOBILE
TABLET
"page": Filter against the specified URI string.
"query": Filter against the specified query string.

您还可以生成爬网错误:


我还有一个问题,您已经在网站管理员工具中获得了查询的详细信息。例如,对于2015年11月20日这样的日期,我们有一个查询列表,如果我们点击一个查询,我们会得到详细信息(其他两个表中的页面)?您是否曾经使用API执行过此操作?@stef chr如果是,您可以通过API执行此操作。只是玩玩。下面是示例查询:或者创建新问题更好,因为我无法在此评论中添加代码和屏幕截图。Yhanks a lot@alex这里是新问题再次感谢,请我有关于此主题的另一个问题,这里是