Skip to content
Get MCP AdsGet MCP Ads, home

x_ads_create_line_item

Create a line item (ad group) under a campaign. A write tool that previews before it changes anything, one of 26 X Ads tools on the Get MCP Ads MCP gateway.

Create a line item (ad group) under a campaign. The line item is ALWAYS created with entity_status PAUSED ; it cannot serve or spend until explicitly activated with activate_line_item. For website conversion campaigns, set goal=WEBSITE_CONVERSIONS and primary_web_event_tag to a web event tag (pixel) id from list_web_event_tags. Preview by default. Ask the user to approve the exact account, target and parameters before confirm:true.

Source
X Ads
Kind
Write
Discovery
Reachable through search_tools and run_tool
Account parameter
account_id
Endpoint
https://mcp.getmcpads.com/x-ads/mcp

ParametersLink to this section

NameTypeRequiredNotes
account_idstringRequiredX Ads account ID selected in Sources.
advertiser_domainstringOptionalWebsite domain of the advertiser (no protocol), e.g. x.com; required when placements includes PUB...
android_app_store_identifierstringOptionalGoogle Play package name of the promoted app, e.g. com.example.app; for APP_INSTALLS / APP_ENGAGE...
audience_expansionstringOptionalAudience expansion level. EXPANDED is what Ads Manager calls Optimized Targeting: serving may ext... One of: BROAD, DEFINED, EXPANDED.
bid_amount_local_microintegerOptionalBid in micros of the account currency; only with bid_strategy MAX or TARGET.
bid_strategystringOptionalBidding strategy. AUTO (default) needs no bid amount; MAX/TARGET require bid_amount_local_micro. One of: AUTO, MAX, TARGET.
campaign_idstringRequiredCampaign to create the line item under.
categoriesstringOptionalComma-separated IAB content category IDs for the advertiser, e.g. IAB3-1,IAB19 (see list_iab_cate...
daily_budget_amount_local_microintegerRequiredDaily budget for this line item (ad group) in micros of the account currency (e.g. 50000000 = $50...
duration_in_daysintegerOptionalWindow over which frequency_cap applies (1, 7 or 30 days); set together with frequency_cap.
end_timestringOptionalLine item end time (ISO 8601). Omit for no end.
frequency_capintegerOptionalMaximum times an ad can be delivered to a user within duration_in_days; only for REACH, ENGAGEMEN...
goalstringOptionalOptimization goal (e.g. ENGAGEMENT, LINK_CLICKS, SITE_VISITS, WEBSITE_CONVERSIONS, FOLLOWERS, APP...
ios_app_store_identifierstringOptionalNumeric Apple App Store ID of the promoted app, e.g. 333903271; for APP_INSTALLS / APP_ENGAGEMENT...
namestringOptionalLine item name (1-255 characters).
objectivestringRequiredCampaign objective for this line item. One of: APP_ENGAGEMENTS, APP_INSTALLS, ENGAGEMENTS, FOLLOWERS, PREROLL_VIEWS, REACH, VIDEO_VIEWS, WEBSITE_CLICKS.
pay_bystringOptionalUnit to pay by. Only settable for APP_INSTALLS (APP_CLICK or APP_INSTALL) and REACH (IMPRESSION) ... One of: APP_CLICK, APP_INSTALL, ENGAGEMENT, FOLLOW, IMPRESSION, LINK_CLICK, VIEW, VIEW_3S_100PCT, VIEW_6S, VIDEO_START.
placementsstringRequiredComma-separated placements, e.g. ALL_ON_TWITTER or TWITTER_TIMELINE,TWITTER_PROFILE. Valid values...
primary_web_event_tagstringOptionalWebsite conversion tag (pixel) id, required when goal=WEBSITE_CONVERSIONS; see list_web_event_tags.
product_typestringOptionalPromoted product type. ads-api requires it on every new line item; sent as PROMOTED_TWEETS (post-... One of: PROMOTED_TWEETS, PROMOTED_ACCOUNT, MEDIA.
standard_deliverybooleanOptionaltrue (default) paces spend evenly through the day; false spends as fast as possible (accelerated ...
start_timestringRequiredLine item start time (ISO 8601, e.g. 2026-08-01T00:00:00Z). ads-api requires it on every new line...
total_budget_amount_local_microintegerOptionalLine item total budget in micros of the account currency.
confirmbooleanOptionalFalse previews only; true applies this exact change after explicit human confirmation. Default: false.

Calling itLink to this section

jsonThrough run_tool, since it is not announced
{
  "name": "run_tool",
  "arguments": {
    "name": "x_ads_create_line_item",
    "args": {
      "account_id": "<string>",
      "campaign_id": "<string>",
      "daily_budget_amount_local_micro": "<integer>",
      "objective": "APP_ENGAGEMENTS",
      "placements": "<string>",
      "start_time": "<string>"
    }
  }
}
Esc

Type to search