Getting the upload information
Returns the information about the RSS feed upload in Yandex.Webmaster.
Request format
GET https://api.webmaster.yandex.net/v4/user/{user-id}/hosts/{host-id}/turbo/tasks/{task-id}
user-id | User ID. To get the value, use the GET /v4/user operation. |
host-id | Site ID. Has the scheme:host:port format, where
For example: You can also get the site ID using the operation GET /user/{user-id}/hosts. |
task-id | The ID for the RSS feed upload task. You can get it when you create the RSS feed upload task or receive the list of previously created tasks. |
user-id | User ID. To get the value, use the GET /v4/user operation. |
host-id | Site ID. Has the scheme:host:port format, where
For example: You can also get the site ID using the operation GET /user/{user-id}/hosts. |
task-id | The ID for the RSS feed upload task. You can get it when you create the RSS feed upload task or receive the list of previously created tasks. |
Response format
The service returns data in either JSON (default) or XML format. To get the XML response, pass the HTTP header Accept: application/xml
in the request.
{
"mode": "string",
"load_status": "string",
"turbo_pages": [
{
"link": "string",
"preview": "string",
"title": "string"
}
],
"errors": [
{
"error_code": "string",
"help_link": "string",
"line": int32,
"column": int32,
"text": "string",
"context": {
"text": "string",
"position": int32
},
"tag": "string"
}
],
"stats": {
"pages_count": int32,
"errors_count": int32,
"warnings_count": int32
}
}
<Data>
<mode>string</mode>
<load_status>string</load_status>
<turbo_page>
<link>string</link>
<preview>string</preview>
<title>string</title>
</turbo_page>
<error>
<error_code>string</error_code>
<help_link>string</help_link>
<line>int32</line>
<column>int32</column>
<text>string</text>
<context>
<text>string</text>
<position>int32</position>
</context>
<tag>string</tag>
</error>
<stats>
<pages_count>int32</pages_count>
<errors_count>int32</errors_count>
<warnings_count>int32</warnings_count>
</stats>
</Data>
mode
Turbo page loading mode.
load_status
Turbo page loading status. Possible values:
- PROCESSING — The file is validated for errors.
- OK —The file is uploaded and doesn't contain errors.
- WARNING — XML elements in the file aren't supported by Yandex or are specified incorrectly.
- ERROR — The file contains errors (for example, duplicate XML elements).
turbo_page
Page block.
link
The URL of the source page for which the Turbo page is generated.
preview
The link to view the Turbo page.
title
Page heading.
error
The error block
error_code
Error code.
help_link
Link to the error description.
line
Number of line in the RSS feed line where the error was found.
column
Number of column in the RSS feed where the error was found.
text
The row in which the error was found.
context
The error context.
text
The Turbo page source code fragment.
position
The error position within the code fragment.
tag
The element in which the error was detected.
stats
Contains an array of information.
pages_count
Total number of pages loaded.
errors_count
Number of critical errors.
warnings_count
Number of errors.
Response codes
Code | Description |
---|---|
200 OK | The request is successfully completed. |
403 Forbidden |
|
404 Not Found |
|
Code | Description |
---|---|
200 OK | The request is successfully completed. |
403 Forbidden |
|
404 Not Found |
|
Example
Request:
curl -X GET \ 'https://api.webmaster.yandex.net/v4/user/12345678/hosts/https:example.com:443/turbo/tasks/12345e0-678f-9e' \ -H 'Authorization: OAuth oauth_token'
Copied to clipboard
Response:
{
"mode": "DEBUG",
"load_status": "OK",
"turbo_pages": [
{
"link": "https://example.com",
"preview": "https://yandex.ru/turbo?text=https%3A%2F%2Fexample.com%2F&from=webmaster&ncrnd=6249270910336449448",
"title": "The Healthy Breakfast restaurant"
}
],
"errors": [],
"stats": {
"pages_count": 1,
"errors_count": 0,
"warnings_count": 0
}
}