# List videos of a playlist

`GET /api/v1/video-playlists/{playlistId}/videos`

Authentication: no security requirement declared for this operation.

Parameters:

- `playlistId` (path, id, required) - Playlist id
  Type: id
  
  Schema: [id](https://sourcey-peertube.pages.dev/api-rest-reference/models/id.md)
  
  minimum: 1
  
  Example:
  
  ```json
  42
  ```

- `start` (query, integer, optional) - Offset used to paginate results
  Type: integer
  
  minimum: 0

- `count` (query, integer, optional) - Number of items to return
  Type: integer
  
  default: 15
  
  minimum: 1
  
  maximum: 100

Responses:

- 200: successful operation

Content type: application/json

Type: any

- `total` (optional)
  Type: integer
  
  Example:
  
  ```json
  1
  ```

- `data` (optional)
  Type: Array<object>
  
  maxItems: 100
  
  Items:
    Type: object
    
    - `id` (optional)
      Type: id
      
      Playlist element id
      
      allOf:
        Reference: [id](https://sourcey-peertube.pages.dev/api-rest-reference/models/id.md); Type: id
        
        minimum: 1
        
        Example:
        
        ```json
        42
        ```
    
    - `position` (optional)
      Type: integer
      
      Example:
      
      ```json
      2
      ```
    
    - `startTimestamp` (optional)
      Type: integer, seconds; nullable
      
      Example:
      
      ```json
      10
      ```
    
    - `stopTimestamp` (optional)
      Type: integer, seconds; nullable
      
      Example:
      
      ```json
      41
      ```
    
    - `video` (optional)
      Reference: [Video](https://sourcey-peertube.pages.dev/api-rest-reference/models/video.md); Type: Video

## Examples

### cURL

```bash
curl -X GET 'https://peertube2.cpy.re/api/v1/video-playlists/42/videos?count=15'
```

### JavaScript

```javascript
const response = await fetch('https://peertube2.cpy.re/api/v1/video-playlists/42/videos?count=15', {
  method: 'GET',
});

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

### Python

```python
import requests

response = requests.get('https://peertube2.cpy.re/api/v1/video-playlists/42/videos?count=15')
print(response.text)
```
