mirror of
https://github.com/MODSetter/SurfSense.git
synced 2026-07-16 23:01:06 +02:00
docs(tiktok): native connector page + nav card
This commit is contained in:
parent
ed1c3a1f3d
commit
ea6befdf59
3 changed files with 52 additions and 2 deletions
|
|
@ -1,6 +1,6 @@
|
||||||
---
|
---
|
||||||
title: Native Connectors
|
title: Native Connectors
|
||||||
description: SurfSense's built-in scraper APIs for Reddit, YouTube, Google Maps, Google Search, and the web
|
description: SurfSense's built-in scraper APIs for Reddit, YouTube, TikTok, Google Maps, Google Search, and the web
|
||||||
---
|
---
|
||||||
|
|
||||||
import { Card, Cards } from 'fumadocs-ui/components/card';
|
import { Card, Cards } from 'fumadocs-ui/components/card';
|
||||||
|
|
@ -18,6 +18,11 @@ Native connectors are SurfSense's own scraper APIs — built into the platform,
|
||||||
description="Videos, channels, playlists, subtitles, and comments"
|
description="Videos, channels, playlists, subtitles, and comments"
|
||||||
href="/docs/connectors/native/youtube"
|
href="/docs/connectors/native/youtube"
|
||||||
/>
|
/>
|
||||||
|
<Card
|
||||||
|
title="TikTok"
|
||||||
|
description="Videos by URL, profile, hashtag, or search"
|
||||||
|
href="/docs/connectors/native/tiktok"
|
||||||
|
/>
|
||||||
<Card
|
<Card
|
||||||
title="Google Maps"
|
title="Google Maps"
|
||||||
description="Places with details, ratings, photos, and reviews"
|
description="Places with details, ratings, photos, and reviews"
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
{
|
{
|
||||||
"title": "Native Connectors",
|
"title": "Native Connectors",
|
||||||
"pages": ["reddit", "youtube", "google-maps", "google-search", "web-crawl"],
|
"pages": ["reddit", "youtube", "tiktok", "google-maps", "google-search", "web-crawl"],
|
||||||
"defaultOpen": false
|
"defaultOpen": false
|
||||||
}
|
}
|
||||||
|
|
|
||||||
45
surfsense_web/content/docs/connectors/native/tiktok.mdx
Normal file
45
surfsense_web/content/docs/connectors/native/tiktok.mdx
Normal file
|
|
@ -0,0 +1,45 @@
|
||||||
|
---
|
||||||
|
title: TikTok
|
||||||
|
description: Scrape public TikTok videos by URL, profile, hashtag, or search
|
||||||
|
---
|
||||||
|
|
||||||
|
The TikTok scraper pulls structured public data from TikTok. Give it URLs (a video, a profile, a hashtag, or a search page) and/or profiles, hashtags, or search terms, and it returns videos (caption, author, play/like/comment/share counts, music, hashtags, timestamps, and the web URL).
|
||||||
|
|
||||||
|
## Endpoint
|
||||||
|
|
||||||
|
```bash
|
||||||
|
POST /api/v1/workspaces/{workspace_id}/scrapers/tiktok/scrape
|
||||||
|
```
|
||||||
|
|
||||||
|
## Inputs
|
||||||
|
|
||||||
|
At least one of `urls`, `profiles`, `hashtags`, or `search_queries` is required.
|
||||||
|
|
||||||
|
| Field | Default | Description |
|
||||||
|
|-------|---------|-------------|
|
||||||
|
| `urls` | — | TikTok URLs: a video, a profile (`/@<user>`), a hashtag (`/tag/<name>`), or a search URL (max 20 sources per call) |
|
||||||
|
| `profiles` | — | Profile usernames, with or without a leading `@` |
|
||||||
|
| `hashtags` | — | Hashtag names, without the `#` |
|
||||||
|
| `search_queries` | — | Search terms to run on TikTok |
|
||||||
|
| `results_per_page` | `10` | Max videos per profile/hashtag/search target |
|
||||||
|
| `max_items` | `10` | Max total videos returned across all sources (hard cap 100) |
|
||||||
|
|
||||||
|
## Example
|
||||||
|
|
||||||
|
```bash
|
||||||
|
curl -X POST "$BASE_URL/api/v1/workspaces/1/scrapers/tiktok/scrape" \
|
||||||
|
-H "Authorization: Bearer $SURFSENSE_API_KEY" \
|
||||||
|
-H "Content-Type: application/json" \
|
||||||
|
-d '{
|
||||||
|
"hashtags": ["food"],
|
||||||
|
"max_items": 25
|
||||||
|
}'
|
||||||
|
```
|
||||||
|
|
||||||
|
The response is `{ "items": [...] }` — one item per video. Billing is per returned item.
|
||||||
|
|
||||||
|
<Callout type="info">
|
||||||
|
Video, hashtag, and search targets are the reliable paths. TikTok restricts the profile video endpoint for automated clients, so a `profiles` target can return no items even when the account is public — prefer hashtags, search, or a direct video URL.
|
||||||
|
</Callout>
|
||||||
|
|
||||||
|
For the full input and output JSON schemas and generated code snippets in your language, open **API Playground → TikTok → Scrape** in your workspace.
|
||||||
Loading…
Add table
Add a link
Reference in a new issue