Migrate from Entity Read Files

Entity Read Files (ERFs) are JSON representations of a partner's campaign objects made available through Google Cloud Storage.

ERFs were deprecated in June 2021 and sunset on October 31, 2024. ERFs are no longer generated. Use the Display & Video 360 API to retrieve Display & Video 360 resources.

This guide discusses how to migrate from Entity Read Files to the Display & Video 360 API by:

  • Giving an overview of the differences between the two interfaces
  • Comparing ERF tables to API services
  • Providing guidance on entity retrieval through the API
  • Acknowledging existing data gaps
  • Presenting a mapping of all ERF fields to comparable API resource fields

Overview

When migrating from ERFs to the Display & Video 360 API, there are a number of key differences to consider, including:

  • Data freshness. ERFs are generated daily and in bulk while the API retrieves the most up-to-date version of a resource.
  • Resource structure. The API uses different JSON structures than ERF to represent the same resource types. Some resources, such as public targeting settings, may use a different ID space.
  • Retrieval method. The Display & Video 360 API only enables the retrieval of resources individually, in paginated lists, or through BigQuery data transfers, in contrast to the raw JSON files provided by ERF.
  • Scope. As opposed to ERFs, which are scoped by partner ID, most API resources are scoped by advertiser ID. Resources included in responses are limited to resources within that scope.

ERF data representation in the API

Entity Read Files are separated into "Public" and "Private" tables. Public tables provide information that is available and applicable to all users, such as targeting values. Private tables provide data that is specific to a partner, such as creative or line item resources.

The Display & Video 360 API does not use this dichotomy, instead making all of this information retrievable through various services and using different JSON structures. This section compares the information provided through public and private ERF tables to that made available through Display & Video 360 API resources and services.

Public information

ERF public tables provide reference materials for users to use when interpreting the targeting settings of their retrieved private resources and assigning targeting through a subset of Structured Data Files (SDFs) versions uploaded through the UI. These reference materials are the same for all users and consist of a numeric ID, used for mapping, and more descriptive details, such as a display name.

When using the Display & Video 360 API, targeting reference information can be retrieved through the targetingTypes.targetingOptions service. Similar to the public tables, this service provides the IDs and details of targeting options for a specific targeting type. Refer to our existing Set Targeting page for a code example demonstrating targeting option ID retrieval.

Public tables and SDFs

Before SDF v7, Entity Read Files and Structured Data Files use the same ID space for targeting settings. If you are an SDF user using ERF public tables for interpreting or assigning targeting settings using SDF, you can instead download this reference material in CSV format through the Display & Video 360 UI.

Starting with v7, the ID spaces used by a subset of Structured Data Files columns have been updated to decouple SDF from the ERFs and further align with Display & Video 360 API. See the v7 migration guide and reference documentation for more information.

Private resources

ERF private tables provide a daily snapshot of the current settings of private resources owned by a partner. Due to the sheer volume of resources that can be created under a single partner, these files can grow to be very large and difficult to download and process.

In the API, each private table has a corresponding service that provides endpoints for retrieval and management of that resource type. Resources can be retrieved in bulk using each service's respective list method. The JSON structure for each resource is different in the API compared to ERF, utilizing different field names and shared resources.

Certain information available in the ERF representation of a resource, such as a resource's assigned targeting settings or a channel's sites, are represented in the API as children of the original resource and must be retrieved through additional API requests.

Entity retrieval in the API

Display & Video 360 resources can either be retrieved through direct API requests or automatic imports into BigQuery.

Direct API requests

Each resource type is retrievable through a different API service. Resources can be retrieved individually or in bulk using the appropriate service's get or list method, respectively. Important properties of Display & Video 360 API list methods include:

  • Required scope. Unlike ERFs, which are scoped by partner, most resources in the API are scoped by advertiser. Retrieving all of a resource type, such as line items, under a partner may require an individual list request for each child advertiser of that partner. Exceptions include direct children of a partner, such as advertisers and partner-owned channels.
  • Pagination. API list methods employ pagination to ensure that responses are within a reasonable size, limiting most individual request responses, or pages, to 100 resources. If the number of relevant resources is larger than the page size, consecutive list calls are required to retrieve subsequent pages of the full list response. A code example paging a list response is provided in a section of our Targeting guide page regarding retrieving available targeting options .
  • Additional requests required for targeting retrieval. A resource's targeting settings are not included in its API JSON object, but are instead child resources known as assigned targeting options. These child resources must be retrieved through a separate request. For example, for each line item retrieved through an advertisers.lineItems.list request, a separate advertisers.lineItems.bulkListAssignedTargetingOptions request must be made to retrieve all targeting information.

Optimize resource retrieval

The Display & Video 360 API may require multiple requests to retrieve the same amount of information that is available in a single Entity Read File. Optimizing how you retrieve resources can help retrieve the data you need more efficiently:

  • Make concurrent requests to the API. The Display & Video 360 API protects infrastructure using requests per project and requests per advertiser per project rate limits. This quota structure lets you implement a multithreaded solution across multiple advertisers that will reduce the total time it takes to retrieve all necessary resources. Although pagination requires that all resources of a type within a certain scope are retrieved through consecutive calls, retrieval of resources within another scope or of another type can be done concurrently.
  • Utilize filters and order by parameters in your list calls to retrieve only relevant resources. For example, if you are only interested in line items that have been updated in the last day, you can use the filter parameter of the advertisers.lineItems.list method to only return line items with an updateTime greater than a given timestamp. This can significantly reduce the number of requests that need to be made.
  • Cache regularly used IDs to avoid unnecessary API requests. Certain reference information, such as targeting options IDs and Google Audience IDs, are relatively stable and can be safely stored to avoid the need for retrieval upon every use. However, cached values should be checked on a weekly basis to account for infrequent changes or deprecations.

See our Quota Optimization guide for more information on how to access the Display & Video 360 API efficiently.

Import into BigQuery

The Display & Video 360 API BigQuery Connector lets you automatically import Display & Video 360 resource configurations directly into BigQuery on a daily basis. The configurations are stored in BigQuery using Display & Video 360 API resource design. A subset of API resources are supported.

See the following cloud documentation for more information about using the Display & Video 360 API BigQuery Connector:

Known API data gaps

There are notable data gaps you might encounter when migrating from ERF to Display & Video 360 API, such as:

  • Story insertion orders. Story insertion orders are not retrievable through the API and must be retrieved through the Display & Video 360 UI.
  • A subset of resource fields. A small number of resource fields present in ERF objects are not available in the corresponding resources retrieved through the Display & Video 360 API.

Appendix: Mapping ERF Fields to API

Public table mapping

The tables below map the fields of ERF public tables to existing targeting types and targeting option fields in the Display & Video 360 API. Although the value of one field might map to another, that does not guarantee that they utilize the same data type, enum values, or ID space.

App Collection

Retrievable under targeting type TARGETING_TYPE_APP_CATEGORY.

ERF Field NameDV360 API Availability
idTargetingOption.targetingOptionId field.
nameTargetingOption.appCategoryDetails.displayName field.

Browser

Retrievable under targeting type TARGETING_TYPE_BROWSER.

ERF Field NameDV360 API Availability
idTargetingOption.targetingOptionId field.
is_mobileNot available.
nameTargetingOption.browserDetails.displayName field.

DataPartner

There is no equivalent resource or fields available in Display & Video 360 API.

DeviceCriteria

Retrievable under targeting types TARGETING_TYPE_OPERATING_SYSTEM, TARGETING_TYPE_DEVICE_MAKE_MODEL, and TARGETING_TYPE_DEVICE_TYPE.

ERF Field NameDV360 API Availability
idTargetingOption.targetingOptionId field or DeviceType enum.
is_mobileNot available.
nameTargetingOption.operatingSystemDetails.displayName field, TargetingOption.deviceMakeModelDetails.displayName field, or DeviceType enum, depending on targeting type.
criteria_typeTargetingOption.targetingType field.
operating_system_idNot available.
mobile_brand_nameNot available.
mobile_model_nameNot available.
mobile_make_model_idNot available.
device_typeDeviceType enum.

GeoLocation

Retrievable under targeting type TARGETING_TYPE_GEO_REGION.

ERF Field NameDV360 API Availability
idTargetingOption.targetingOptionId field.
canonical_nameTargetingOption.geoRegionDetails.displayName field.
geo_nameNot available.
country_codeNot available.
region_codeNot available.
city_nameNot available.
postal_nameNot available.
dma_codeNot available.

Isp

Retrievable under targeting type TARGETING_TYPE_CARRIER_AND_ISP.

ERF Field NameDV360 API Availability
idTargetingOption.targetingOptionId field.
is_mobileNot available.
nameTargetingOption.carrierAndIspDetails.displayName field.
secondary_criteria_idTargetingOption.targetingOptionId field.

Language

Retrievable under targeting type TARGETING_TYPE_LANGUAGE.

ERF Field NameDV360 API Availability
idTargetingOption.targetingOptionId field.
nameNot available. Full display name for a language is available at TargetingOption.languageDetails.displayName field.

SiteToPlacementId

There is no equivalent resource or fields available in Display & Video 360 API.

SupportedExchange

Retrievable under targeting type TARGETING_TYPE_EXCHANGE.

ERF Field NameDV360 API Availability
idExchange enum.
nameExchange enum.

UniversalSite

There is no equivalent resource or fields available in Display & Video 360 API. Individual sites and apps can be targeted directly under targeting types TARGETING_TYPE_URL and TARGETING_TYPE_APP, respectively. In Display & Video 360, any app or URL can be targeted, but not every app or URL can be reported on. If you would like to remove non-reportable apps and URLs from spending, follow the instructions on the DV360 Help Center.

Private table field mapping

The tables below map the fields of ERF private tables to existing fields or services in the Display & Video 360 API. Although the value of one field may map to another, that does not guarantee that they utilize the same data type, enum values or ID space.

Advertiser

ERF Field NameDV360 API Availability
common_data.idAdvertiser.advertiserId field.
common_data.nameAdvertiser.displayName field.
common_data.activeAdvertiser.entityStatus field.
common_data.integration_codeAdvertiser.integrationDetails.integrationCode field.
partner_idAdvertiser.partnerId field.
currency_codeAdvertiser.generalConfig.currencyCode field.
timezone_codeAdvertiser.generalConfig.timeZone field.
landing_page_urlAdvertiser.generalConfig.domainUrl field.
available_channel_idsRetrievable through advertisers.channels.list method.
blacklist_channel_idRetrievable through advertisers.targetingTypes.assignedtargetingOptions.list method under targeting type TARGETING_TYPE_CHANNEL . If AssignedTargetingOption.channelDetails.negative is true, the channel is negatively-targeted.
dcm_configurationNot available.
dcm_network_idAdvertiser.adServerConfig.cmHybridConfig.cmAccountId field.
dcm_advertiser_idThe Advertiser.adServerConfig.cmHybridConfig.cmAdvertiserIds field lists the CM360 Advertiser IDs that share the CM360 Floodlight configuration.
dcm_floodlight_group_idAdvertiser.adServerConfig.cmHybridConfig.cmFloodlightConfigId field.
dcm_syncable_site_idsAdvertiser.adServerConfig.cmHybridConfig.cmSyncableSiteIds field.
enable_oba_tagsNot available.

Campaign

ERF Field NameDV360 API Availability
common_data.idCampaign.campaignId field.
common_data.nameCampaign.displayName field.
common_data.activeCampaign.entityStatus field.
common_data.integration_codeNot available.
advertiser_idCampaign.advertiserId field.
budgetCampaign.campaignFlight and Campaign.campaignBudgets fields.
frequency_capCampaign.frequencyCap field.
default_target_listNot available
uses_video_creativesNot available.
uses_display_creativesNot available.
uses_audio_creativesNot available.
objectiveCampaign.campaignGoal.campaignGoalType field.
metricCampaign.campaignGoal.performanceGoal.performanceGoalType field.
objective_descriptionCampaign.campaignGoal.performanceGoal.performanceGoalString field.
metric_amount_microsCampaign.campaignGoal.performanceGoal.performanceGoalAmountMicros field.

Creative

ERF Field NameDV360 API Availability
common_data.idCreative.creativeId field.
common_data.nameCreative.displayName field.
common_data.activeCreative.entityStatus field.
common_data.integration_codeCreative.integrationCode field.
advertiser_idCreative.advertiserId field.
dcm_placement_idCreative.cmPlacementId field.
width_pixelsCreative.dimensions.widthPixels field.
height_pixelsCreative.dimensions.heightPixels field.
approval_statusCreative.reviewStatus field.
expanding_directionCreative.expandingDirection field.
creative_typeCreative.creativeType field.

CustomAffinity

ERF Field NameDV360 API Availability
idCustomList.customListId field.
nameCustomList.displayName field.
descriptionNot available.
advertiser_idNot available.

FloodlightActivity

ERF Field NameDV360 API Availability
common_data.idFloodlightActivity.floodlightActivityId field.
common_data.nameFloodlightActivity.displayName field.
common_data.activeFloodlightActivity.servingStatus field.
common_data.integration_codeNot available.
advertiser_idThe FloodlightActivity.advertiserIds field lists all advertisers with access to the floodlight activity under the given partner.
partner_idProvided by the user when making a request to the floodlightGroups.floodlightActivities service.
remarketing_enabledThe FloodlightActivity.remarketingConfigs field lists this configuration for each advertiser with access to the floodlight activity under the given partner.
ssl_requiredFloodlightActivity.sslRequired field.

InsertionOrder

ERF Field NameDV360 API Availability
common_data.idInsertionOrder.insertionOrderId field.
common_data.nameInsertionOrder.displayName field.
common_data.activeInsertionOrder.entityStatus field.
common_data.integration_codeInsertionOrder.integrationDetails.integrationCode field.
advertiser_idInsertionOrder.advertiserId field.
campaign_idInsertionOrder.campaignId field.
overall_budgetNot available. Can be calculated using contents of the InsertionOrder.budget.budgetSegments field.
scheduled_segmentsInsertionOrder.budget.budgetSegments field.
frequency_capInsertionOrder.frequencyCap field.
default_partner_costsInsertionOrder.partnerCosts field.
default_target_listNot available.

InventorySource

ERF Field NameDV360 API Availability
idInventorySource.inventorySourceId field.
unclassifiedNot available.
inventory_nameInventorySource.displayName field.
exchange_idInventorySource.exchange field.
accessing_advertisersInventorySource.readWriteAccessors and InventorySource.readAdvertiserIds fields.
external_idInventorySource.dealId field.
min_cpm_microsInventorySource.rateDetails.rate.nanos field, depending on the value of the InventorySource.rateDetails.inventorySourceRateType field.
min_cpm_currency_codeInventorySource.rateDetails.rate.currencyCode field.

LineItem

ERF Field NameDV360 API Availability
common_data.idLineItem.lineItemId field.
common_data.nameLineItem.displayName field.
common_data.activeLineItem.entityStatus field.
common_data.integration_codeLineItem.integrationDetails.integrationCode field.
line_item_typeLineItem.lineItemType field.
insertion_order_idLineItem.insertionOrderId field.
creative_idsLineItem.creativeIds field.
max_cpm_advertiser_microsLineItem.bidStrategy.maximizeSpendAutoBid.maxAverageCpmBidAmountMicros or LineItem.bidStrategy.performanceGoalAutoBid.maxAverageCpmBidAmountMicros fields, depending on the strategy scheme used.
performance_goalLineItem.bidStrategy.maximizeSpendAutoBid.performanceGoalType or LineItem.bidStrategy.performanceGoalAutoBid.performanceGoalType fields, depending on the strategy scheme used.
goal_advertiser_microsLineItem.bidStrategy.performanceGoalAutoBid.performanceGoalAmountMicros field.
partner_revenue_modelLineItem.partnerRevenueModel field.
cost_tracking_pixelsLineItem.conversionCounting.floodlightActivityConfigs field.
budget.start_time_usecLineItem.flight.dateRange.startDate field.
budget.end_time_usecLineItem.flight.dateRange.endDate field.
budget.max_impressionsLineItem.budget.maxAmount field if LineItem.budget.budgetUnit is BUDGET_UNIT_IMPRESSIONS .
budget.max_spend_advertiser_microsLineItem.budget.maxAmount field if LineItem.budget.budgetUnit is BUDGET_UNIT_CURRENCY .
budget.pacing_typeLineItem.pacing.pacingPeriod field.
budget.pacing_max_impressionsLineItem.pacing.dailyMaxImpressions field.
budget.pacing_max_spend_advertiser_microsLineItem.pacing.dailyMaxMicros field.
budget.pacing_distributionLineItem.pacing.pacingType field.
frequency_capLineItem.frequencyCap field.
partner_costsLineItem.partnerCosts field.
target_listRetrievable through advertisers.lineItems.bulkListAssignedTargetingOptions method.

NegativeKeywordList

ERF Field NameDV360 API Availability
idNegativeKeywordList.negativeKeywordListId field.
nameNegativeKeywordList.displayName field.
advertiser_idNegativeKeywordList.advertiserId field.

Partner

ERF Field NameDV360 API Availability
common_data.idPartner.partnerId field.
common_data.namePartner.displayName field.
common_data.activePartner.entityStatus field.
common_data.integration_codeNot available.
currency_codePartner.generalConfig.currencyCode field.
exchange_settingsPartner.exchangeConfig.enabledExchanges field.
default_partner_costsNot available.
default_partner_revenueNot available.
default_target_listNot available.

Pixel

There is no equivalent resource or fields available in Display & Video 360 API.

UniversalChannel

ERF Field NameDV360 API Availability
idChannel.channelId field.
nameChannel.displayName field.
site_idsRetrievable through advertisers.channels.sites.list and partners.channels.sites.list methods, depending on the type of owner .
accessing_advertisersNot available.
is_deletedNot available.
is_brand_safe_channelNot available.

UserList

ERF Field NameDV360 API Availability
idFirstPartyAndPartnerAudience.firstPartyAndPartnerAudienceId field.
nameFirstPartyAndPartnerAudience.displayName field.
data_partner_idNot available.
accessing_advertisersNot available.
partner_pricingNot available.
advertiser_pricingsNot available.