taboola-backstage-sdk 0.3.0 → 0.6.0
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/README.md +15 -50
- package/dist/index.cjs +102 -672
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +443 -902
- package/dist/index.d.ts +443 -902
- package/dist/index.js +102 -672
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -156,14 +156,11 @@ const { results } = await client.items.list('account-id', 'campaign-id');
|
|
|
156
156
|
// Get single item
|
|
157
157
|
const item = await client.items.get('account-id', 'campaign-id', 'item-id');
|
|
158
158
|
|
|
159
|
-
// Create item
|
|
159
|
+
// Create item (static ad - only url accepted, starts in CRAWLING state)
|
|
160
160
|
const item = await client.items.create('account-id', 'campaign-id', {
|
|
161
161
|
url: 'https://example.com/landing',
|
|
162
|
-
title: 'Amazing Product - Learn More',
|
|
163
|
-
thumbnail_url: 'https://example.com/image.jpg',
|
|
164
|
-
description: 'Discover our latest offering',
|
|
165
|
-
cta: { cta_type: 'LEARN_MORE' },
|
|
166
162
|
});
|
|
163
|
+
// Poll until item.status changes from CRAWLING to RUNNING, then update fields
|
|
167
164
|
|
|
168
165
|
// Update item (static or motion ad - partial updates supported)
|
|
169
166
|
await client.items.update('account-id', 'campaign-id', 'item-id', {
|
|
@@ -187,7 +184,7 @@ await client.items.unpause('account-id', 'campaign-id', 'item-id');
|
|
|
187
184
|
// Delete
|
|
188
185
|
await client.items.delete('account-id', 'campaign-id', 'item-id');
|
|
189
186
|
|
|
190
|
-
// Bulk create
|
|
187
|
+
// Bulk create (supports both static and motion ads with full field set)
|
|
191
188
|
const { results } = await client.items.bulkCreate('account-id', 'campaign-id', {
|
|
192
189
|
items: [
|
|
193
190
|
{ url: 'https://example.com/1', title: 'Title 1', thumbnail_url: '...' },
|
|
@@ -251,20 +248,20 @@ const rules = await client.pixel.listConversionRules('account-id');
|
|
|
251
248
|
// Get single conversion rule
|
|
252
249
|
const rule = await client.pixel.getConversionRule('account-id', 'rule-id');
|
|
253
250
|
|
|
254
|
-
// Create conversion rule
|
|
251
|
+
// Create conversion rule (URL-based)
|
|
255
252
|
const rule = await client.pixel.createConversionRule('account-id', {
|
|
256
253
|
display_name: 'Purchase Completed',
|
|
257
|
-
type: '
|
|
258
|
-
category: '
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
value_parameter: 'order_total',
|
|
254
|
+
type: 'BASIC',
|
|
255
|
+
category: 'MAKE_PURCHASE',
|
|
256
|
+
condition: {
|
|
257
|
+
property: 'URL',
|
|
258
|
+
predicate: 'CONTAINS',
|
|
259
|
+
value: '/thank-you',
|
|
260
|
+
children: [],
|
|
265
261
|
},
|
|
266
|
-
|
|
267
|
-
|
|
262
|
+
effects: [{ type: 'REVENUE', data: '15' }],
|
|
263
|
+
look_back_window: 30,
|
|
264
|
+
view_through_look_back_window: 1,
|
|
268
265
|
});
|
|
269
266
|
|
|
270
267
|
// Archive / Unarchive
|
|
@@ -491,6 +488,7 @@ import type {
|
|
|
491
488
|
CreateCampaignRequest,
|
|
492
489
|
UpdateCampaignRequest,
|
|
493
490
|
CreateItemRequest,
|
|
491
|
+
BulkCreateItemData,
|
|
494
492
|
CreateSharedBudgetRequest,
|
|
495
493
|
|
|
496
494
|
// Report types
|
|
@@ -536,39 +534,6 @@ const client = new TaboolaClient({
|
|
|
536
534
|
|
|
537
535
|
For detailed API documentation, see the [Taboola Backstage API Reference](https://developers.taboola.com/backstage-api/reference).
|
|
538
536
|
|
|
539
|
-
## Changelog
|
|
540
|
-
|
|
541
|
-
### v0.3.0 (2024)
|
|
542
|
-
|
|
543
|
-
**Enhanced Update Support** - Comprehensive updates for campaigns and items
|
|
544
|
-
|
|
545
|
-
- **Campaign Updates**: Expanded `UpdateCampaignRequest` to support all updatable fields including:
|
|
546
|
-
- Geographic targeting (DMA, region, city, postal code, sub-country)
|
|
547
|
-
- Advanced targeting (contextual, browser, connection type, auto publisher)
|
|
548
|
-
- Bid modifiers (publisher bid modifiers and bid strategy modifiers)
|
|
549
|
-
- Audience targeting (marketplace, custom, lookalike, marking labels, contextual segments)
|
|
550
|
-
- Additional fields (pricing model, campaign profile, traffic allocation, external brand safety, verification pixels, viewability tags)
|
|
551
|
-
|
|
552
|
-
- **Item Updates**: Expanded `UpdateItemRequest` to support both static items and motion ads:
|
|
553
|
-
- Static items: `url`, `thumbnail_url`, `verification_pixel`, `viewability_tag`, `creative_focus`
|
|
554
|
-
- Motion ads: New `PerformanceVideoData` type with `video_url` and `fallback_url`
|
|
555
|
-
- Enhanced documentation with examples for both item types
|
|
556
|
-
|
|
557
|
-
- **Partial Updates**: Both endpoints properly support partial updates where only specified fields are modified
|
|
558
|
-
- **Improved Documentation**: Added comprehensive JSDoc examples and better API alignment
|
|
559
|
-
|
|
560
|
-
### v0.2.1 (2024)
|
|
561
|
-
|
|
562
|
-
Minor bug fixes and documentation improvements.
|
|
563
|
-
|
|
564
|
-
### v0.2.0 (2024)
|
|
565
|
-
|
|
566
|
-
Added support for shared budgets, marking labels, and realtime report signatures.
|
|
567
|
-
|
|
568
|
-
### v0.1.0 (2024)
|
|
569
|
-
|
|
570
|
-
Initial release with core API support.
|
|
571
|
-
|
|
572
537
|
## License
|
|
573
538
|
|
|
574
539
|
MIT
|