copy_ad_mapping_to_feed
Copy the attribute mapping of an ad channel integration (ad_id) onto a feed of the same project. Use this to make a feed (e.g. a Custom Channel Layout feed) export what the integration sends, without mapping column by column. Each mapped attribute of get_ad_attributes is copied exactly (source attribute, constant, fallbacks, rule; empty fields are cleared) onto the feed column with the same code; with customColumnsAllowed a missing column is created (create_missing_columns, default true), named by the attribute code or, column_names:'label', its label. Skipped with a reason: not_mapped, wizard_step_value, no_matching_column, invalid_label, too_many_columns, duplicate_target (a second attribute for the same column) and the map_feed_attribute rejections; a copied item with a reason got its sources but not its rule. codes limits the copy. OVERWRITES the copied columns' mapping and detaches a rule the integration does not have. SAVE-ONLY: call export_feed afterwards. Returns {feedId, integrationId, status, copied:[{sourceCode, targetCode, changed, reason}], skipped:[{sourceCode, reason}], createdColumns, revisionBefore, revisionAfter}. ad_id from list_ads; project_id OPTIONAL.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"ad_id": "<ad_id>",
"feed_id": "<feed_id>"
},
"name": "copy_ad_mapping_to_feed"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ad_id | Yes | integrationId of the ad channel (from list_ads). | |
| codes | No | Only these attribute codes (from get_ad_attributes); omit to copy every mapped attribute. | |
| feed_id | Yes | The feed to copy onto (from list_feeds / create_feed). | |
| project_id | No | ||
| column_names | No | Header of a created column: the attribute code (default) or its label. | |
| create_missing_columns | No | Create a custom column for an attribute the feed lacks (default true; only on feeds that allow custom columns). |