@scrapecreators/cli 1.0.23 → 1.0.25
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/api-config/apis.js +66 -1
- package/api-config/tiktok-apis.js +225 -0
- package/package.json +1 -1
package/api-config/apis.js
CHANGED
|
@@ -164,6 +164,14 @@ export const apis = [
|
|
|
164
164
|
"Continuation token to get more videos. Get 'continuationToken' from previous response.",
|
|
165
165
|
placeholder: "4qmFsgKrCBIYVUNkRkpXVWE0M3NtUm00SXBIQnB",
|
|
166
166
|
},
|
|
167
|
+
{
|
|
168
|
+
name: "is_paid_promotions",
|
|
169
|
+
type: "string",
|
|
170
|
+
required: false,
|
|
171
|
+
description:
|
|
172
|
+
"Set to 'true' to search YouTube's public paid product placement / sponsorship / endorsement search surface. This returns normal YouTube videos where the creator declared paid promotion. Cannot be combined with filter, uploadDate, sortBy, type, duration, or includeExtras.",
|
|
173
|
+
placeholder: "false",
|
|
174
|
+
},
|
|
167
175
|
{
|
|
168
176
|
name: "includeExtras",
|
|
169
177
|
type: "string",
|
|
@@ -729,13 +737,70 @@ export const apis = [
|
|
|
729
737
|
language: "English",
|
|
730
738
|
},
|
|
731
739
|
},
|
|
740
|
+
{
|
|
741
|
+
name: "Video Sponsors",
|
|
742
|
+
method: "GET",
|
|
743
|
+
description: "Experimental: Find suspected sponsors/promoted brands for a YouTube video. This is inferred from public evidence, not an official YouTube sponsor field. Feedback welcome: support@scrapecreators.com",
|
|
744
|
+
fullDescription:
|
|
745
|
+
"Experimental endpoint. Checks a YouTube video for the paid-promotion disclosure and infers likely sponsors/promoted brands from the public description, description links, promo-code text, and transcript. YouTube tells us that a video contains paid promotion, but it does not always tell us the sponsor directly, so this endpoint returns suspected sponsors with confidence and evidence. This is inferred, not an official YouTube sponsor field. Feedback welcome: support@scrapecreators.com",
|
|
746
|
+
path: "/v1/youtube/video/sponsors",
|
|
747
|
+
params: [
|
|
748
|
+
{
|
|
749
|
+
name: "url",
|
|
750
|
+
type: "string",
|
|
751
|
+
required: true,
|
|
752
|
+
description: "YouTube video or short URL",
|
|
753
|
+
placeholder: "https://www.youtube.com/watch?v=AVO0ifle-OU",
|
|
754
|
+
},
|
|
755
|
+
{
|
|
756
|
+
name: "language",
|
|
757
|
+
type: "string",
|
|
758
|
+
required: false,
|
|
759
|
+
description: "2 letter language code used for transcript lookup, ie 'en', 'es', 'fr' etc.",
|
|
760
|
+
placeholder: "en",
|
|
761
|
+
},
|
|
762
|
+
],
|
|
763
|
+
sampleResponse: {
|
|
764
|
+
video: {
|
|
765
|
+
id: "AVO0ifle-OU",
|
|
766
|
+
url: "https://www.youtube.com/watch?v=AVO0ifle-OU",
|
|
767
|
+
title: "Why You Should Meal Prep Like A Restaurant",
|
|
768
|
+
channel: {
|
|
769
|
+
id: "UC3vQEjRhwgH2HAOBKwLjxNA",
|
|
770
|
+
url: "https://www.youtube.com/@letsKWOOWK",
|
|
771
|
+
handle: "letsKWOOWK",
|
|
772
|
+
title: "KWOOWK",
|
|
773
|
+
},
|
|
774
|
+
isPaidPromotion: true,
|
|
775
|
+
},
|
|
776
|
+
suspectedSponsors: [
|
|
777
|
+
{
|
|
778
|
+
name: "Betterhelp",
|
|
779
|
+
website: "betterhelp.com",
|
|
780
|
+
confidence: "medium",
|
|
781
|
+
evidence: [
|
|
782
|
+
{
|
|
783
|
+
source: "description_link",
|
|
784
|
+
text: "If you're struggling, consider therapy with our sponsor BetterHelp. Click https://betterhelp.com/KWOOWK for a 10% discount...",
|
|
785
|
+
},
|
|
786
|
+
],
|
|
787
|
+
},
|
|
788
|
+
],
|
|
789
|
+
sponsorDetection: {
|
|
790
|
+
status: "found",
|
|
791
|
+
methods: ["paid promotion badge", "description", "description links", "transcript"],
|
|
792
|
+
transcriptAvailable: true,
|
|
793
|
+
note: "Sponsors are inferred from public description, links, promo-code text, and transcript evidence.",
|
|
794
|
+
},
|
|
795
|
+
},
|
|
796
|
+
},
|
|
732
797
|
{
|
|
733
798
|
name: "Search",
|
|
734
799
|
method: "GET",
|
|
735
800
|
description:
|
|
736
801
|
"Search YouTube and get matching videos, channels, playlists, shorts, lives, etc. Video explaining the response format: https://www.tella.tv/video/explaining-youtube-search-results-payload-353a",
|
|
737
802
|
fullDescription:
|
|
738
|
-
"Searches YouTube by keyword query and returns matching videos, channels, playlists, shorts, shelves, and live streams. Each video result includes title, URL, thumbnail, view count (views), publish date, duration, channel info, and badges. Supports filtering by upload date, sorting by relevance or popularity, and paginating with continuationToken.",
|
|
803
|
+
"Searches YouTube by keyword query and returns matching videos, channels, playlists, shorts, shelves, and live streams. Each video result includes title, URL, thumbnail, view count (views), publish date, duration, channel info, and badges. Supports filtering by upload date, sorting by relevance or popularity, and paginating with continuationToken. Set is_paid_promotions=true to search YouTube videos with the paid product placement / sponsorship disclosure.",
|
|
739
804
|
path: "/v1/youtube/search",
|
|
740
805
|
paginationField: "continuationToken",
|
|
741
806
|
sampleResponse: {
|
|
@@ -115,6 +115,231 @@ export const tiktokBaseApis = {
|
|
|
115
115
|
region: "US",
|
|
116
116
|
},
|
|
117
117
|
},
|
|
118
|
+
{
|
|
119
|
+
name: "Ad Library Search",
|
|
120
|
+
method: "GET",
|
|
121
|
+
description: "Search TikTok Creative Center Top Ads by region, period, and keyword.",
|
|
122
|
+
fullDescription:
|
|
123
|
+
"Searches TikTok Creative Center Top Ads, the ad library page at ads.tiktok.com/business/creativecenter/inspiration/topads. Supports US and other 2-letter regions, period filters, sorting, keyword search, and cursor pagination. Returns TikTok's public top ad material objects, including ad title, metrics, video info, landing page, and pagination.",
|
|
124
|
+
path: "/v1/tiktok/ad-library/search",
|
|
125
|
+
params: [
|
|
126
|
+
{
|
|
127
|
+
name: "region",
|
|
128
|
+
type: "select",
|
|
129
|
+
required: false,
|
|
130
|
+
description: "Country code. Defaults to US.",
|
|
131
|
+
options: ["DZ", "AR", "AU", "AT", "AZ", "BH", "BD", "BY", "BE", "BO", "BR", "BG", "KH", "CA", "CL", "CO", "CR", "HR", "CY", "CZ", "DK", "DO", "EC", "EG", "EE", "FI", "FR", "DE", "GR", "GT", "JO", "HU", "ID", "IQ", "IE", "IL", "IT", "JP", "KZ", "KE", "KW", "LV", "LB", "MY", "MX", "MA", "NL", "NZ", "NG", "NO", "OM", "PK", "PA", "PY", "PE", "PH", "PL", "PT", "PR", "QA", "LT", "RO", "SA", "RS", "SG", "SK", "SI", "ZA", "KR", "ES", "LK", "SE", "CH", "TW", "TH", "TR", "AE", "GB", "US", "UY", "VN"],
|
|
132
|
+
placeholder: "US",
|
|
133
|
+
},
|
|
134
|
+
{
|
|
135
|
+
name: "period",
|
|
136
|
+
type: "select",
|
|
137
|
+
required: false,
|
|
138
|
+
description: "Time window for Top Ads.",
|
|
139
|
+
options: ["7", "30", "180"],
|
|
140
|
+
placeholder: "30",
|
|
141
|
+
},
|
|
142
|
+
{
|
|
143
|
+
name: "query",
|
|
144
|
+
type: "string",
|
|
145
|
+
required: false,
|
|
146
|
+
description: "Optional keyword to search ad titles/content.",
|
|
147
|
+
placeholder: "spotify",
|
|
148
|
+
},
|
|
149
|
+
{
|
|
150
|
+
name: "order_by",
|
|
151
|
+
type: "select",
|
|
152
|
+
required: false,
|
|
153
|
+
description: "Sort metric. Defaults to for_you.",
|
|
154
|
+
options: ["for_you", "impression", "play_2s_rate", "play_6s_rate", "cvr", "ctr", "like"],
|
|
155
|
+
placeholder: "for_you",
|
|
156
|
+
},
|
|
157
|
+
{
|
|
158
|
+
name: "industry",
|
|
159
|
+
type: "select",
|
|
160
|
+
required: false,
|
|
161
|
+
description: "Industry filter.",
|
|
162
|
+
options: ["apparel_accessories", "appliances", "apps", "baby_kids_maternity", "beauty_personal_care", "business_services", "ecommerce_non_app", "education", "financial_services", "food_beverage", "games", "health", "home_improvement", "household_products", "life_services", "news_entertainment", "pets", "sports_outdoor", "tech_electronics", "travel", "vehicle_transportation"],
|
|
163
|
+
placeholder: "beauty_personal_care",
|
|
164
|
+
},
|
|
165
|
+
{
|
|
166
|
+
name: "objective",
|
|
167
|
+
type: "select",
|
|
168
|
+
required: false,
|
|
169
|
+
description: "Campaign objective filter.",
|
|
170
|
+
options: ["app_installs", "conversions", "lead_generation", "product_sales", "reach", "traffic", "video_views"],
|
|
171
|
+
placeholder: "traffic",
|
|
172
|
+
},
|
|
173
|
+
{
|
|
174
|
+
name: "duration",
|
|
175
|
+
type: "select",
|
|
176
|
+
required: false,
|
|
177
|
+
description: "Video duration filter.",
|
|
178
|
+
options: ["under_10s", "10_20s", "20_30s", "30_40s", "40_50s", "over_50s"],
|
|
179
|
+
placeholder: "under_10s",
|
|
180
|
+
},
|
|
181
|
+
{
|
|
182
|
+
name: "likes",
|
|
183
|
+
type: "select",
|
|
184
|
+
required: false,
|
|
185
|
+
description: "Likes percentile filter.",
|
|
186
|
+
options: ["top_1_20", "top_21_40", "top_41_60", "top_61_80", "top_81_100"],
|
|
187
|
+
placeholder: "top_1_20",
|
|
188
|
+
},
|
|
189
|
+
{
|
|
190
|
+
name: "ad_format",
|
|
191
|
+
type: "select",
|
|
192
|
+
required: false,
|
|
193
|
+
description: "Ad format filter.",
|
|
194
|
+
options: ["spark_ads", "non_spark_ads"],
|
|
195
|
+
placeholder: "spark_ads",
|
|
196
|
+
},
|
|
197
|
+
{
|
|
198
|
+
name: "ad_language",
|
|
199
|
+
type: "select",
|
|
200
|
+
required: false,
|
|
201
|
+
description: "Ad language filter.",
|
|
202
|
+
options: ["en", "es", "ar", "vi", "th", "de", "id", "pt", "fr", "ms", "nl", "ja", "it", "ro", "zh-Hant", "ko"],
|
|
203
|
+
placeholder: "en",
|
|
204
|
+
},
|
|
205
|
+
{
|
|
206
|
+
name: "cursor",
|
|
207
|
+
type: "number",
|
|
208
|
+
required: false,
|
|
209
|
+
description: "Page number to fetch. Use the cursor returned from the previous response, like 3 for page 3.",
|
|
210
|
+
placeholder: "3",
|
|
211
|
+
},
|
|
212
|
+
{
|
|
213
|
+
name: "limit",
|
|
214
|
+
type: "number",
|
|
215
|
+
required: false,
|
|
216
|
+
description: "Number of ads to return, max 50. Defaults to 20.",
|
|
217
|
+
placeholder: "20",
|
|
218
|
+
},
|
|
219
|
+
],
|
|
220
|
+
sampleResponse: {
|
|
221
|
+
success: true,
|
|
222
|
+
credits_remaining: 100,
|
|
223
|
+
data: {
|
|
224
|
+
query: "spotify",
|
|
225
|
+
region: "US",
|
|
226
|
+
period: 30,
|
|
227
|
+
ads: [
|
|
228
|
+
{
|
|
229
|
+
id: "7642386438915309575",
|
|
230
|
+
ad_title: "Example TikTok top ad title",
|
|
231
|
+
brand_name: "Example Brand",
|
|
232
|
+
ctr: 0.24,
|
|
233
|
+
like: 80546,
|
|
234
|
+
video_info: {
|
|
235
|
+
duration: 20.054,
|
|
236
|
+
cover: "https://p16-common-sign.tiktokcdn.com/...",
|
|
237
|
+
video_url: {
|
|
238
|
+
"720p": "https://v16m-default.tiktokcdn.com/...",
|
|
239
|
+
},
|
|
240
|
+
},
|
|
241
|
+
},
|
|
242
|
+
],
|
|
243
|
+
pagination: {
|
|
244
|
+
page: 1,
|
|
245
|
+
limit: 20,
|
|
246
|
+
total_count: 326,
|
|
247
|
+
},
|
|
248
|
+
total: 326,
|
|
249
|
+
has_more: true,
|
|
250
|
+
cursor: "eyJwYWdlIjoyfQ",
|
|
251
|
+
},
|
|
252
|
+
},
|
|
253
|
+
},
|
|
254
|
+
{
|
|
255
|
+
name: "Ad Library Ad",
|
|
256
|
+
method: "GET",
|
|
257
|
+
description: "Gets details for a TikTok Creative Center Top Ad.",
|
|
258
|
+
fullDescription:
|
|
259
|
+
"Fetches one TikTok Creative Center Top Ad by material/ad ID or URL. Uses the same Creative Center data behind pages like ads.tiktok.com/business/creativecenter/topads/{id}/pc/en, including title, metrics, video info, landing page, country codes, objective, industry, source, the Creative Center URL, summary/analysis, interactive time analysis graph data, and recommended-for-you ads when TikTok provides them.",
|
|
260
|
+
path: "/v1/tiktok/ad-library/ad",
|
|
261
|
+
params: [
|
|
262
|
+
{
|
|
263
|
+
name: "ad_id",
|
|
264
|
+
type: "string",
|
|
265
|
+
required: true,
|
|
266
|
+
description: "TikTok Top Ads material/ad ID, or a Top Ads detail URL.",
|
|
267
|
+
placeholder: "7642386438915309575",
|
|
268
|
+
},
|
|
269
|
+
],
|
|
270
|
+
sampleResponse: {
|
|
271
|
+
success: true,
|
|
272
|
+
credits_remaining: 100,
|
|
273
|
+
data: {
|
|
274
|
+
id: "7642386438915309575",
|
|
275
|
+
ad_title: "Example TikTok top ad title",
|
|
276
|
+
brand_name: "Example Brand",
|
|
277
|
+
ctr: 0.24,
|
|
278
|
+
like: 80546,
|
|
279
|
+
country_code: ["US"],
|
|
280
|
+
landing_page: "https://example.com",
|
|
281
|
+
creative_center_url:
|
|
282
|
+
"https://ads.tiktok.com/business/creativecenter/topads/7642386438915309575/pc/en",
|
|
283
|
+
video_info: {
|
|
284
|
+
duration: 20.054,
|
|
285
|
+
cover: "https://p16-common-sign.tiktokcdn.com/...",
|
|
286
|
+
video_url: {
|
|
287
|
+
"720p": "https://v16m-default.tiktokcdn.com/...",
|
|
288
|
+
},
|
|
289
|
+
},
|
|
290
|
+
detail_analysis: {
|
|
291
|
+
hints: [],
|
|
292
|
+
paragraphs: [],
|
|
293
|
+
},
|
|
294
|
+
interactive_time_analysis: {
|
|
295
|
+
ctr: {
|
|
296
|
+
metric: "retain_ctr",
|
|
297
|
+
analysis: [{ second: 0, value: 0.0174 }],
|
|
298
|
+
duration: 14,
|
|
299
|
+
highlight: [1, 9],
|
|
300
|
+
percentile: 0.99,
|
|
301
|
+
},
|
|
302
|
+
cvr: {
|
|
303
|
+
metric: "retain_cvr",
|
|
304
|
+
analysis: [],
|
|
305
|
+
duration: 14,
|
|
306
|
+
highlight: [],
|
|
307
|
+
percentile: 0.99,
|
|
308
|
+
},
|
|
309
|
+
clicks: {
|
|
310
|
+
metric: "click_cnt",
|
|
311
|
+
analysis: [],
|
|
312
|
+
duration: 14,
|
|
313
|
+
highlight: [],
|
|
314
|
+
percentile: 0.99,
|
|
315
|
+
},
|
|
316
|
+
conversion: {
|
|
317
|
+
metric: "convert_cnt",
|
|
318
|
+
analysis: [],
|
|
319
|
+
duration: 14,
|
|
320
|
+
highlight: [],
|
|
321
|
+
percentile: 0.99,
|
|
322
|
+
},
|
|
323
|
+
remain: {
|
|
324
|
+
metric: "play_retain_cnt",
|
|
325
|
+
analysis: [],
|
|
326
|
+
duration: 14,
|
|
327
|
+
highlight: [],
|
|
328
|
+
percentile: 0.99,
|
|
329
|
+
},
|
|
330
|
+
},
|
|
331
|
+
recommended_for_you: [
|
|
332
|
+
{
|
|
333
|
+
id: "7639864582744702996",
|
|
334
|
+
ad_title: "Example recommended ad",
|
|
335
|
+
video_info: {
|
|
336
|
+
cover: "https://p16-common-sign.tiktokcdn.com/...",
|
|
337
|
+
},
|
|
338
|
+
},
|
|
339
|
+
],
|
|
340
|
+
},
|
|
341
|
+
},
|
|
342
|
+
},
|
|
118
343
|
{
|
|
119
344
|
name: "User's Audience Demographics",
|
|
120
345
|
method: "GET",
|