Description Usage Arguments Value Note Examples
This function returns a data.frame listing items in Xaxis for Publishers. Only the most important details are returned. Certain search criteria may be added to the request to narrow the results returned.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 | oas_list(credentials,
request_type=c('Advertiser', 'AdvertiserCategory', 'Affiliate',
'Agency', 'CampaignGroup', 'CompanionPosition',
'CompetitiveCategory', 'ConversionProcess',
'CreativeType',
'Event', 'InsertionOrder', 'Notification',
'Page', 'Product', 'RichMediaTemplate',
'SalesPerson', 'Section', 'Site',
'SiteGroup', 'Transaction', 'Position',
'Keyword', 'Keyname', 'Publisher',
'Campaign',
'CreativeTarget', 'Creative'),
campaign_id = NULL,
parentcampaign_id = NULL,
search_criteria_attributes = c(pageIndex="-1", pageSize="1000"),
search_criteria = NULL, verbose = FALSE)
|
credentials |
a character string as returned by oas_build_credentials |
request_type |
a character string in one of the supported object types for the API database list action |
campaign_id |
a character string exactly matching the ID of a campaign. This parameter is only utilized for request type "Notification" because Campaign Notifications cannot be listed/searched across Campaigns. The Campaign Id must be specified exactly with no wildcard characters. Thus, CampaignId is not part of the SearchCriteria element and there is a specialized AdXML structure required for LIST Notification. |
parentcampaign_id |
a character string exactly matching the ID of a campaign. This parameter is only utilized for a request type "CreativeTarget" because Creative Targets cannot be listed/searched across Campaigns. The ParentCampaignId must be used and exact attribute has to be set to "true" . |
search_criteria_attributes |
a named character vector of attributes to add to the SearchCriteria node. Acceptable parameters are pageSize and pageIndex to support paginated requests. Default pageSize for request types Campaign, CampaignGroup, and Creatives is: 30,000, while all others have a default pageSize of 1000. |
search_criteria |
an XML document specifying the children to be added to the SearchCriteria Node in the request |
verbose |
a boolean indicating whether to print the request XML as a message |
A data.frame
listing all objects of the specified type that
also met the supplied search criteria
Most objects have a unique list of searchable criteria. Please consult the API documentation for a complete coverage. Here are the options for Campaigns:
Type: 'RM' for regular campaign, 'CLT' for CLT Campaign, 'ALL' for whole campaign
Status: Search by Campaign Status. See Codes to Use in Single Character Fields
Id: Search by Campaign ID. If "exact" attribute is "true", API returns exact campaign having defined value. Otherwise, API returns all campaigns containing defined value in campaign ID.
Url: Search by Scheduled Page URL
SectionId: Search by Scheduled Section ID
AdvertiserId: Search by Scheduled Advertiser ID
AgencyId: Search by associated Agency ID
CampaignGroupId: Search by associated Campaign Group ID
StartDate: Search by Start Date. Date value with YYYY-MM-DD format is required. "condition" attribute can be defined among EQ, GE,LE,GT and LT. Multiple StartDate can be used.
EndDate: Search by End Date. Date value with YYYY-MM-DD format is required. "condition" attribute can be defined among EQ, GE,LE,GT and LT. Multiple StartDate can be used.
WhenCreated: Search by When the campaign was created. Date value with YYYY-MM-DD hh:mm:ss format is required( Time part is optional). "condition" attribute can be defined among EQ, GE,LE,GT and LT. Multiple WhenCreated can be used.
WhenModified: Search by When the campaign was modified. Date value with YYYY-MM-DD hh:mm:ss format is required( Time part is optional). "condition" attribute can be defined among EQ, GE,LE,GT and LT. Multiple WhenCreated can be used.
PriorityLevel: Search by Campaign Priority Level. Available value is 1 to 20. "condition" attribute can be defined among EQ, GE,LE,GT and LT. Multiple PriorityLevel can be used.
Completion: Search by Completion Type. See Codes to Use in Single Character Fields for available abbreviation code.
Reach: Search by Reach Type. See Codes to Use in Single Character Fields for available abbreviation code.
PurchaseOrder: Search by Purchase Order #. "condition" attribute can be defined among EQ, GE,LE,GT,LT and also LK
InsertionOrderId: Search by associated Insertion Order ID
CampaignManager: Search by associated CampaignManager
The condition attribute values of "EQ, GE, LE, GT, LT" stand for equality operators
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 | ## Not run:
my_credentials <- build_credentials('myaccount',
'myusername',
'mypassword')
list_of_sites <- oas_list(credentials=my_credentials, request_type='Site')
list_of_100_pages <- oas_list(credentials=my_credentials, request_type='Page',
search_criteria_attributes = c(pageSize="100"))
list_campaigns <- oas_list(credentials=my_credentials, request_type='Campaign',
search_criteria_attributes = c(pageSize="100"),
search_criteria=list(newXMLNode("EndDate",
attrs = c(condition = "GT"),
'2014-12-31')))
list_by_criteria <- oas_list(credentials=my_credentials,
request_type='Page',
search_criteria_attributes = c(pageSize="100"),
search_criteria=list(newXMLNode("Domain", "mySite"),
newXMLNode("Url", "001"),
newXMLNode("SectionId", "Ar%ves"),
newXMLNode("SiteId", "ApiSite"),
newXMLNode("Description", "My Page"),
newXMLNode("LocationKey", "7"),
newXMLNode("WhenCreated",
attrs = c(condition = "GT"),
'2014-12-31'),
newXMLNode("WhenModified",
attrs = c(condition = "GT"),
'2013-12-31')))
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.