Dynamic Adset Creation¶
Create ads that automatically find or create the right adset for you. Perfect for batch creative testing, A/B testing workflows, and building multiple ads into organized adsets without manual setup.
What Is Dynamic Adset Creation?¶
Instead of manually creating adsets in Meta Ads Manager before building your ads, you can specify an adset name and let Pablo handle the rest. Pablo will:
- Search for an existing adset with that name
- Reuse it if found
- Create a new one from a template if not found
This is especially powerful when building multiple ads that should be grouped together - the first ad creates the adset, and subsequent ads automatically find and use it.
Quick Setup¶
Instead of providing destination_adset_id, use these two fields:
| Field | Value | Required |
|---|---|---|
destination_adset_name |
Name of the adset to find/create | Yes |
destination_template_adset_id |
Adset ID to copy settings from | Yes |
Example:
{
"ad_name": "Hero Image A - Testing",
"ad_headline": "50% Off Everything",
"ad_body": "Limited time offer...",
"destination_ad_account_id": "123456789",
"destination_adset_name": "Testing Batch 2025-W08",
"destination_template_adset_id": "987654321",
"destination_template_ad_id": "555666777",
"..."
}
See Field Schema for full field details.
How It Works¶
First Ad in the Batch¶
When Pablo processes your first ad:
- Searches Meta for an adset named "Testing Batch 2025-W08" in account
123456789 - Finds nothing (adset doesn't exist yet)
- Since the adset doesn't exist, Pablo creates it:
- Fetches properties from template adset
987654321:- Campaign ID
- Targeting settings (audience, locations, demographics)
- Budget (daily or lifetime)
- Optimization goal and billing event
- Status (usually PAUSED)
- Creates a new adset with name "Testing Batch 2025-W08" and the copied properties
- Builds your ad into the newly created adset
- Fetches properties from template adset
Subsequent Ads in the Batch¶
When Pablo processes additional ads with the same destination_adset_name:
- Searches Meta for "Testing Batch 2025-W08"
- Finds the adset created by the first ad
- Builds the ad directly into the existing adset
- No duplicate adsets created
This works even if multiple ads are submitted simultaneously - Pablo uses workflow-level locking to ensure only one adset is created.
Creative Testing¶
Build multiple ads organized into batches for testing different variations:
- Separate batches across weeks or testing periods
- Different angles or hooks for the same product or message
- Different creators or partnership collaborations
- Different geographies or language variants
Example:
| ad_name | destination_adset_name | destination_template_adset_id |
|---|---|---|
| Founder Story - Variant 1 | Founder Story | 987654321 |
| Founder Story - Variant 2 | Founder Story | 987654321 |
| Founder Story - Variant 3 | Founder Story | 987654321 |
| Founder Story - Variant 4 | Founder Story | 987654321 |
| Founder Story - Variant 5 | Founder Story | 987654321 |
| Ugly Ads - Variant 1 | Ugly Ads | 987654321 |
| Ugly Ads - Variant 2 | Ugly Ads | 987654321 |
| Ugly Ads - Variant 3 | Ugly Ads | 987654321 |
| Ugly Ads - Variant 4 | Ugly Ads | 987654321 |
| Ugly Ads - Variant 5 | Ugly Ads | 987654321 |
Result: 2 adsets created - "Founder Story" with 5 ads - "Ugly Ads" with 5 ads
Template Adset Requirements¶
The template adset must:
- Exist in the same ad account
- Be accessible to your Meta connection
- Have the settings you want (targeting, budget, optimization goal)
Choose Your Template Carefully
The template adset's settings are copied to every new adset created. Make sure the template has the right:
- Campaign (new adsets stay in the same campaign)
- Targeting (audience, locations, demographics, interests)
- Budget (daily or lifetime budget amount)
- Optimization goal (e.g., link clicks, conversions, reach)
Not copied: Start/end dates (avoids "end time in the past" errors)
Properties Copied from Template¶
When creating a new adset, Pablo copies these properties:
| Property | Description |
|---|---|
campaign_id |
Keeps the adset in the same campaign |
optimization_goal |
What Meta optimizes for (clicks, conversions, etc.) |
billing_event |
What you're charged for (impressions, clicks, etc.) |
bid_strategy |
Lowest cost, cost cap, bid cap, etc. |
bid_amount |
Bid amount if using bid cap/cost cap |
daily_budget |
Daily budget (if template uses daily) |
lifetime_budget |
Lifetime budget (if template uses lifetime) |
targeting |
Complete targeting spec (audiences, locations, interests, etc.) |
promoted_object |
Pixel ID, app ID, or other promoted object |
attribution_spec |
Attribution window settings |
destination_type |
Website, app, messenger, etc. |
status |
Adset status (usually PAUSED) |
Intentionally excluded:
start_time/end_time- Avoids "end time in the past" errorsname- Uses your specifieddestination_adset_nameinstead
Fallback to Direct ID¶
If you provide both destination_adset_id AND destination_adset_name, the ID takes precedence and the name is ignored.
This lets you use the same Notion database/template for both workflows:
- Leave ID empty → Uses dynamic creation with name + template
- Fill in ID → Uses direct ID, ignores name + template
Concurrent Builds¶
Dynamic adset creation is concurrency-safe. If you submit 100 ads simultaneously with the same destination_adset_name, Pablo guarantees:
- Only 1 adset is created (no duplicates)
- All 100 ads end up in the same adset
- No race conditions or conflicts
This is handled automatically using Temporal workflow-level locking - you don't need to do anything special.
Troubleshooting¶
"Adset not found" error after multiple retries¶
Cause: The template adset ID doesn't exist or you don't have access to it.
Fix: Verify the template adset ID exists in the specified ad account and is accessible to your Meta connection.
Multiple adsets created with the same name¶
Cause: This should never happen with dynamic adset creation. If you see duplicates, they were likely created outside of Pablo (e.g., manually in Ads Manager).
Fix: Use direct destination_adset_id for ads targeting existing manually-created adsets, or delete the duplicates and let Pablo recreate from scratch.
Ads going into wrong campaign¶
Cause: The template adset is in a different campaign than you expected. New adsets inherit the template's campaign.
Fix: Use a template adset from the campaign you want, or manually move the adset after creation.
Related Documentation¶
- Field Schema - Complete field reference
- Ad Formats - Supported ad types
- Placement Assets - Multi-placement creative optimization