Failed to delete Line Item start_time


#1

I’ve tried deleting line item’s start_time(because in the https://ads.twitter.com/ UI there’s a trash can to make DELETE action), after I saved the there’s a “You Saved Successfully!”. Then the start_time of line item did disappear from the UI

However, when I refresh and open the campaign and line_item window again, it appear again on the UI window.

Delete and Save

Delete Successfully

Reopen the window again, and … the start_time pop up again :scream:

I’ve tried the Ads Api as well, PUT accounts/:account_id/line_items/:line_item_id,
setting both start_time and end_time as NULL value.

Request

{
      "start_time": "null",
      "end_time": "null"
}

But the PUT NULL action only effective on “end_time” field, while “start_time” remaining the original value(wasn’t been deleted)

Response

{
      "start_time": "2018-06-30T03:00:00Z",
      "end_time": null
}

There’s a related topic here, which explained that if the line_item’s start_time isn’t been specified, it would inherit the start_time value from campaign.
However, I am wondering why the UI(https://ads.twitter.com/) has a little trash can let us DELETE the start_time, but actually ineffective?

Thank you for your patience.


#2

Hi @neplove! This seems to be a problem with the UI - for UI-related problems please use the “Help?” link in the top right corner in the Ads UI.

Thank you! :slight_smile:


#3

@majoritasdev
Thanks for the advise.
But the Ads APIs also failed to delete the “start_time”.
I mean it’s not only a problem of UI.

I’ve tried the Ads Api as well, PUT accounts/:account_id/line_items/:line_item_id,
setting both start_time and end_time as NULL value.

Request

{
“start_time”: “null”,
“end_time”: “null”
}
But the PUT NULL action only effective on “end_time” field, while “start_time” remaining the original value(wasn’t been deleted)

Response

{
“start_time”: “2018-06-30T03:00:00Z”,
“end_time”: null
}


#4

Thanks for the question, @wenping.wang!

To unset (remove) these values, specifying the parameter without a value, like start_time=&end_time=. See the example, below.

The line item with start and end times set.

{
  "data": {
    "bid_type": "MAX",
    "advertiser_user_id": 756201191646691328,
    "name": "Untitled",
    "placements": [
      "ALL_ON_TWITTER"
    ],
    "start_time": "2018-06-10T00:00:00Z",
    "bid_amount_local_micro": 100000,
    "automatically_select_bid": false,
    "advertiser_domain": null,
    "target_cpa_local_micro": null,
    "primary_web_event_tag": null,
    "charge_by": "ENGAGEMENT",
    "product_type": "PROMOTED_TWEETS",
    "end_time": "2018-06-15T00:00:00Z",
    "bid_unit": "ENGAGEMENT",
    "total_budget_amount_local_micro": null,
    "objective": "TWEET_ENGAGEMENTS",
    "id": "buo34",
    "entity_status": "PAUSED",
    "account_id": "18ce54d4x5t",
    "optimization": "DEFAULT",
    "categories": [],
    "currency": "USD",
    "created_at": "2018-06-12T04:28:47Z",
    "tracking_tags": [],
    "updated_at": "2018-06-12T04:28:47Z",
    "include_sentiment": "POSITIVE_ONLY",
    "campaign_id": "aylz6",
    "creative_source": "MANUAL",
    "deleted": false
  },
  "request": {
    "params": {
      "placements": [
        "ALL_ON_TWITTER"
      ],
      "start_time": "2018-06-10T00:00:00Z",
      "bid_amount_local_micro": 100000,
      "product_type": "PROMOTED_TWEETS",
      "end_time": "2018-06-15T00:00:00Z",
      "objective": "TWEET_ENGAGEMENTS",
      "entity_status": "PAUSED",
      "account_id": "18ce54d4x5t",
      "campaign_id": "aylz6"
    }
  }
}

To unset:

$ twurl -H ads-api.twitter.com -X PUT "/3/accounts/18ce54d4x5t/line_items/buo34?start_time=&end_time="
{
  "data": {
    "bid_type": "MAX",
    "advertiser_user_id": 756201191646691328,
    "name": "Untitled",
    "placements": [
      "ALL_ON_TWITTER"
    ],
    "start_time": null,
    "bid_amount_local_micro": 100000,
    "automatically_select_bid": false,
    "advertiser_domain": null,
    "target_cpa_local_micro": null,
    "primary_web_event_tag": null,
    "charge_by": "ENGAGEMENT",
    "product_type": "PROMOTED_TWEETS",
    "end_time": null,
    "bid_unit": "ENGAGEMENT",
    "total_budget_amount_local_micro": null,
    "objective": "TWEET_ENGAGEMENTS",
    "id": "buo34",
    "entity_status": "PAUSED",
    "account_id": "18ce54d4x5t",
    "optimization": "DEFAULT",
    "categories": [],
    "currency": "USD",
    "created_at": "2018-06-12T04:28:47Z",
    "tracking_tags": [],
    "updated_at": "2018-06-12T04:29:33Z",
    "include_sentiment": "POSITIVE_ONLY",
    "campaign_id": "aylz6",
    "creative_source": "MANUAL",
    "deleted": false
  },
  "request": {
    "params": {
      "line_item_id": "buo34",
      "start_time": "",
      "end_time": "",
      "account_id": "18ce54d4x5t"
    }
  }
}

Hope this helps! cc: @neplove.


#5

Hi @juanshishido

Thanks for your solution.
It’s okay to delete start_time now!
:grinning: