At Google, we always want to be transparent with you about changes to our API. We recently announced v201405 of the DFP API, and, in v201405, we consolidated a line item's goal fields into its own Goal object and added the field LineItem.primaryGoal. During this refactor, the LineItem.duration (previous versions) field was removed from LineItem, but didn't make it into the Goal object due to an implementation error. This means that, in v201405, you cannot set the duration field when creating or updating line items. Instead, the server will set it to the default value.

Fortunately, this is only an issue for some LineItemType constants; many line item types only allow for one duration type, which is also its default, so setting it is not necessary. If you use the following line item types, v201405 will throw an error to prevent you from accidentally resetting the duration type if you update those line items:
If you need to create or update line items of these types, we recommend that you use v201403 or earlier to do so. In the next version of the API, we’ll add the duration field back as “goalType” to the Goal object. We are waiting until the next version so that we do not change the existing v201405 WSDLs, which would break early v201405 adopters' code.

As always, if you have any suggestions or questions, feel free to drop us a line on our API forums or Ads Developer Google+ page.