> Searlo API Docs — Video Search
> Source: https://searlo.tech/docs#search-videos
> Full docs: https://searlo.tech/docs/full.md

# Video Search

Search for videos across the web.

### Endpoint

```
GET /search/videos
```

**Credits:** 1 per request

### Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `q` | string | Yes | Search query (1–500 chars) |
| `limit` | number | No | Results per page (1–10, default: 10) |
| `page` | number | No | Page number (default: 1) |
| `safe` | string | No | Safe search: `active` or `off` |
| `gl` | string | No | Country code, max 5 chars (e.g. `us`) |
| `hl` | string | No | Interface language code, max 5 chars (e.g. `en`) |
### Response

The same envelope as Web Search, with the results in `videos[]`. Fields a video does not have come back as `null`.

```json
{
  "searchParameters": { "q": "react tutorial", "type": "videos", "gl": "us", "num": 10, "page": 1 },
  "page": 1,
  "nextPage": null,
  "previousPage": null,
  "totalResults": 20,
  "searchTime": 1.1,
  "videos": [
    {
      "position": 1,
      "title": "React Tutorial for Beginners",
      "link": "https://video.example.com/watch?v=abc",
      "thumbnailUrl": "https://video.example.com/abc.jpg",
      "duration": "1:02:15",
      "durationSeconds": 3735,
      "source": "Example Channel",
      "sourceUrl": "https://video.example.com/@example",
      "publishedDate": "1 year ago",
      "views": "2.1M views",
      "viewCount": 2100000,
      "snippet": "Learn React in 1 hour...",
      "videoId": "abc"
    }
  ],
  "credits": 1
}
```

## Code Examples

### cURL

```bash
curl "https://api.searlo.tech/api/v1/search/videos?q=react+tutorial&limit=10" \
  -H "x-api-key: sk_your_api_key"
```

### JavaScript

```javascript
const res = await fetch(
  "https://api.searlo.tech/api/v1/search/videos?q=react+tutorial&limit=10",
  { headers: { "x-api-key": process.env.SEARLO_API_KEY } }
);
const data = await res.json();
console.log(data.videos);
```

### Python

```python
import os
import requests

res = requests.get(
    "https://api.searlo.tech/api/v1/search/videos",
    params={"q": "react tutorial", "limit": 10},
    headers={"x-api-key": os.environ["SEARLO_API_KEY"]}
)
print(res.json()["videos"])
```


---
*From https://searlo.tech/docs — see full docs at https://searlo.tech/docs/full.md*