RSS feeds list
Returns the list of RSS feeds for a domain.
Request format
GET https://api.webmaster.yandex.net/v4/user/{user-id}/hosts/{host-id}/content-feeds/list/
|
Type: |
|
Type: |
Response format
The API returns HTTP status code 200 OK for successful requests.
Example
{
"feeds": [
{
"domain": "example.com",
"url": "https://www.example.com/main.xml",
"feed_status": "OK",
"state": "ACTIVE",
"validation_errors": null
},
{
"domain": "example.com",
"url": "https://www.example.com/regions/town.xml",
"feed_status": "OK",
"state": "ACTIVE",
"validation_errors": null
}
]
}
<?xml version="1.0" encoding="UTF-8"?>
<response>
<feeds>
<feed>
<domain>example.com</domain>
<url>https://www.example.com/main.xml</url>
<feed_status>OK</feed_status>
<state>ACTIVE</state>
<validation_errors></validation_errors>
</feed>
<feed>
<domain>example.com</domain>
<url>https://www.example.com/regions/town.xml</url>
<feed_status>OK</feed_status>
<state>ACTIVE</state>
<validation_errors></validation_errors>
</feed>
</feeds>
</response>
Response structure
The response contains a single field feeds, which is an array of feed objects.
Each feed object includes:
Field | Type | Description |
---|---|---|
domain |
string |
The user's domain. |
url |
string |
The feed URL including login and password if provided. |
feed_status |
string |
Feed status: REJECTED (failed technical validation), IN_PROGRESS (validation in progress), or OK (validation passed). |
state |
string |
Feed activation status controlled by the user: INACTIVE or ACTIVE . |
validation_errors |
object null |
Technical errors found during feed validation (null if there are no errors). |
Validation errors structure
If validation_errors
is not null
, it contains a code field with one of error values.
Depending on the code value, one of the following fields will be available:
fetch_error
parse_error
content_error
Error value |
Description |
|
Indicates that the feed data could not be downloaded.
|
|
Indicates that the feed could not be parsed.
Parse errors description
|
|
Indicates that the RSS feed content is invalid.
Content errors description
|
Errors examples
Fetch error
{
"feeds": [
{
"domain": "example.com",
"url": "https://www.example.com/rss.xml",
"feed_status": "REJECTED",
"state": "ACTIVE",
"validation_errors": {
"code": "FETCH_ERROR",
"fetch_error": {
"error_code": "STATUS_IS_NOT_200"
},
"parse_error": null,
"content_error": null
}
}
]
}
<?xml version="1.0" encoding="UTF-8"?>
<response>
<feeds>
<feed>
<domain>example.com</domain>
<url>https://www.example.com/rss.xml</url>
<feed_status>REJECTED</feed_status>
<state>ACTIVE</state>
<validation_errors>
<code>FETCH_ERROR</code>
<fetch_error>
<error_code>STATUS_IS_NOT_200</error_code>
</fetch_error>
</validation_errors>
</feed>
</feeds>
</response>
Content error
{
"feeds": [
{
"domain": "example.com",
"url": "https://www.example.com/rss.xml",
"feed_status": "REJECTED",
"state": "ACTIVE",
"validation_errors": {
"code": "CONTENT_ERROR",
"fetch_error": null,
"parse_error": null,
"content_error": {
"items": [
{
"url": "https://www.example.com/news/2023-02-20/305913-classes-for-morning-shift-canceled-in-seattle-schools-today",
"title": "Classes for morning shift canceled in Seattle schools today",
"publicationDate": "2023-02-20T11:21:15+07:00",
"orderId": 1,
"errors": [
{
"errorCode": "PUBLICATION_TIME_IN_FUTURE",
"context": "Publication time is in the future (time delta = 0.008 days)"
}
]
}
]
}
}
}
]
}
<?xml version="1.0" encoding="UTF-8"?>
<response>
<feeds>
<feed>
<domain>"example.com"</domain>
<url>https://www.example.com/rss.xml</url>
<feed_status>REJECTED</feed_status>
<state>ACTIVE</state>
<validation_errors>
<code>CONTENT_ERROR</code>
<content_error>
<items>
<item>
<url>"https://www.example.com/news/2023-02-20/305913-classes-for-morning-shift-canceled-in-seattle-schools-today"</url>
<title>Classes for morning shift canceled in Seattle schools today</title>
<publicationDate>2023-02-20T11:21:15+07:00</publicationDate>
<orderId>1</orderId>
<errors>
<error>
<errorCode>PUBLICATION_TIME_IN_FUTURE</errorCode>
<context>Publication time is in the future (time delta = 0.008 days)</context>
</error>
</errors>
</item>
</items>
</content_error>
</validation_errors>
</feed>
</feeds>
</response>