# Comments on videos feeds

`GET /feeds/video-comments.{format}`

Authentication: no security requirement declared for this operation.

Parameters:

- `format` (path, string, required) - format expected (we focus on making `rss` the most feature-rich ; it serves [Media RSS](https://www.rssboard.org/media-rss))
  Type: string
  
  enum: ["xml","rss","rss2","atom","atom1","json","json1"]

- `videoId` (query, string, optional) - limit listing comments to a specific video
  Type: string

- `accountId` (query, string, optional) - limit listing comments to videos of a specific account
  Type: string

- `accountName` (query, string, optional) - limit listing comments to videos of a specific account
  Type: string

- `videoChannelId` (query, string, optional) - limit listing comments to videos of a specific video channel
  Type: string

- `videoChannelName` (query, string, optional) - limit listing comments to videos of a specific video channel
  Type: string

- `isLocal` (query, boolean, optional) - **PeerTube >= 9.0** Display only comments of local or remote accounts
  Type: boolean

- `onLocalVideo` (query, boolean, optional) - **PeerTube >= 9.0** Display only comments of local or remote videos
  Type: boolean

Responses:

- 200: successful operation

Content type: application/xml

Type: Array<object>

Schema: [VideoCommentsForXML](https://sourcey-peertube.pages.dev/api-rest-reference/models/videocommentsforxml.md)

Items:
  Type: object
  
  - `link` (optional)
    Type: string, url
  
  - `guid` (optional)
    Type: string
  
  - `pubDate` (optional)
    Type: string, date-time
  
  - `content:encoded` (optional)
    Type: string
  
  - `dc:creator` (optional)
    Type: string

Content type: application/rss+xml

Type: Array<object>

Schema: [VideoCommentsForXML](https://sourcey-peertube.pages.dev/api-rest-reference/models/videocommentsforxml.md)

Items:
  Type: object
  
  - `link` (optional)
    Type: string, url
  
  - `guid` (optional)
    Type: string
  
  - `pubDate` (optional)
    Type: string, date-time
  
  - `content:encoded` (optional)
    Type: string
  
  - `dc:creator` (optional)
    Type: string

Content type: text/xml

Type: Array<object>

Schema: [VideoCommentsForXML](https://sourcey-peertube.pages.dev/api-rest-reference/models/videocommentsforxml.md)

Items:
  Type: object
  
  - `link` (optional)
    Type: string, url
  
  - `guid` (optional)
    Type: string
  
  - `pubDate` (optional)
    Type: string, date-time
  
  - `content:encoded` (optional)
    Type: string
  
  - `dc:creator` (optional)
    Type: string

Content type: application/atom+xml

Type: Array<object>

Schema: [VideoCommentsForXML](https://sourcey-peertube.pages.dev/api-rest-reference/models/videocommentsforxml.md)

Items:
  Type: object
  
  - `link` (optional)
    Type: string, url
  
  - `guid` (optional)
    Type: string
  
  - `pubDate` (optional)
    Type: string, date-time
  
  - `content:encoded` (optional)
    Type: string
  
  - `dc:creator` (optional)
    Type: string

Content type: application/json

Type: object

- 400: Arises when:
  - videoId filter is mixed with a channel filter


- 404: video, video channel or account not found

- 406: accept header unsupported

## Examples

### cURL

```bash
curl -X GET 'https://peertube2.cpy.re/feeds/video-comments.xml'
```

### JavaScript

```javascript
const response = await fetch('https://peertube2.cpy.re/feeds/video-comments.xml', {
  method: 'GET',
});

const data = await response.text();
```

### Python

```python
import requests

response = requests.get('https://peertube2.cpy.re/feeds/video-comments.xml')
print(response.text)
```
