Mistake in advertiser_domain example in POST accounts/:account_id/line_items


The example value for this paramter is invalid and causes the api to return ‘Invalid advertiser domain format’. It seems like the valid format for this field is just something like ‘twitter.com


Interesting! So this only works without http://?


Yessir! As far as I could tell. I kept getting the error above for everything I tried, including any url with a subdomain prefixed (i.e. www.twitter.com). The only format that the API accepts is a simple domain name like ‘twitter.com


Uh oh. Well, that looks like a bug :sweat_smile:

Could you possibly provide us with a twurl request that would reproduce this behavior?


Having trouble getting twurl working on my machine, but I guess it’d look something like this:

twurl ads-api.twitter.com “/0/accounts/xxxx/line_items” -d ‘campaign_id=xxxx&account_id=xxxx&placements=PUBLISHER_NETWORK&product_type=PROMOTED_TWEETS&bid_amount_local_micro=5000000&bid_type=MAX&objective=TWEET_ENGAGEMENTS&name=liname&categories=IAB1-7,IAB1-6&advertiser_domain=http://www.twitter.com’

Switching advertiser_domain to just ‘twitter.com’ gets past this exception