Must use a PUT method to run the creative API. The maximum number of creative’s allowed to be created is 1000. Remove any fields that are not being used or that will be blank. The XML tags are case sensitive. Any values that require a true or false are case sensitive.
*Note: For any content that is HTML, the xml requires that it is encoded. Below is an example and a link to an HTML encoder tool that can help you encode the HTML.
Example: <div><a sku="testsku8" productName="mytestsku8" href="http://google.com">google</a></div>
http://www.opinionatedgeek.com/DotNet/Tools/HTMLEncode/encode.aspx
Base URL
https://api.linktrust.com/v2/Campaigns/Creative
XML Parameters
CampaignId - The Campaign ID is required in order to create a new creative. The Campaign ID must be a valid id in your account. Example: 123456
Enabled - The enabled field allows you to control whether or not the creative will be displayed in the affiliate center. This is an optional field and allows true or false values.
EnableForAllAffiliates - This field allows you to enable the creative for all affiliates or none. Allowed values are true or false. Use the AffiliateGroupName field to specify a particular affiliate group to be able to view the creative. This field is ignored if a value for AffiliateGroupName is provided.
AffiliateId - This field is used if you want the response from the API to contain a tracking and impression link with a specific affiliate ID. Must be a valid AFID and must be assigned to the campaign and have rights to view this creative. Example: 12345
CreativeId - This is the id of an existing creative and is required to update/delete a creative.
AffiliateGroupName - The affiliate group name is an optional value. If a valid affiliate group name is submitted, the creative will only be visible for affiliates that are in that group. If it is not submitted, the default is set to none. The affiliate group name must be a valid affiliate group name that exists within your account
Name - This is required to create a new creative. This is the name of the creative. Alphanumeric values only and limited to 100 characters.
Type - Required if creating a new creative. Values allowed: HTML, Text, Custom_Banner, PopUp, Flash, Simple_Banner,QR_Code, File
SizeId - This is the creative size. Required ONLY for new Custom Banner, Flash and Simple Banner type creative’s. This is not required to update an existing creative. Allowed values are as follows:
Creative Sizes
FileOrImageUrl - Required ONLY for File or Simple Banner type creatives. This is the Url of the file or image that will be used for the creative. Must be a valid URL and encoded: http://www.google.com?id=123&pid=34.
AddImpressionTrackingCode - This field will allow you to add the impression tracking token or URL to the creative and response code. Allowed values for this field are true or false. If you submit an affiliate ID and this field is set to true, the response will display the impression URL for the specific affiliate ID, (http://www.cnn.com/impression.track?CID=123456&AFID=123456&ADID=123456&SID= ). If this field is set to true and an affiliate ID is not submitted, the response will display the impression URL with the [=AFID=] token,http://www.cnn.com/impression.track?CID=123456&AFID=[=AFID=]&ADID=123456&SID=. This is only for Custom Banner, Flash, HTML and Popup type creative's.
ReplaceAllLinksWithTrackingLink - This field allows you to replace all href links with the tracking URL in your creative and response code. Values allowed are true or false and the default is false. If an affiliate ID is submitted, the href links in the API response will be replaced with the tracking link for the specific affiliate ID,(http://www.trackingurl.com/click.track?CID=123456&AFID=123456&ADID=123456&SID=). If an affiliate ID is not submitted, the href links in the API response will be replaced with the tracking URL with the [=AFID=] token, http://www.trackingurl.com/click.track?CID=123456&AFID=[=AFID=]&ADID=123456&SID=. This field is only for Custom Banner, Flash, HTML and Popup type creative’s.
DoNotReplaceLastXLinks - Use this to prevent your unsubscribe links, which are usually located at the bottom of the creative code, from being replaced by the tracking URL token or tracking URL. This is only for Custom Banner, HTML or Popup type creatives. Only whole numbers are allowed. Example values: 1,2,3,4,5. This may be used in place of the ReplaceAllLinksWithTrackingLink if you wish to not replace some of your href links in a creative.
ShowTrackingLinkInListing - This field will allow you to hide or show the tracking link of the creative in the creative list in the affiliate center. Allowed values are true or false and the default is false.
CustomLandingPageUrl - This is used if you want the creative to redirect to a different landing page than you have setup for the main campaign. The custom landing page URL is an optional value and must be a valid URL and encoded. http is not required, however, if the URL is secure you must submit the URL with https. Examples: http://www.google.com?id=123&pid=34 or www.google.com?id=123&pid=34, https://www.google.com?id=123&pid=34.
PropagateAdditionalData - Optional, true or false, default is false. This will enable you to pass along any data that is appended to the affiliate’s tracking URL to the custom landing page URL.
OverrideAffiliatePayout - true or false, default is false. This will allow you to set a custom affiliate payout for the creative. This will override the main campaign affiliate payout.
AffiliatePayout - Default is the same as the campaign settings payout. This is required if OverrideAffiliatePayout is true. Remove if OverrideAffiliatePayout is false. Whole numbers with up to 4 decimals allowed. Example: 1.2555
AffiliatePayoutType - This field allows you to change the affiliate payout type to Flat or Percent. This is required if OverrideAffiliatePayout is set to true. The default value is the same as the campaign settings payout. Remove if OverrideAffiliatePayout is false. If the advertiser revenue is set to Flat, the value must be Flat. If the advertiser revenue is set to Percent, the value may be either Flat or Percent.
OverrideAdvertiserRevenue - This field allows you to set a custom advertiser revenue for a creative. This will override the main campaign advertiser revenue if it is set to true. Values allowed are true or false and the default value is false. Do not include this field in your call if the value will be blank.
AdvertiserRevenue - This field allows you to set a custom advertiser revenue. The default is the same as the campaign advertiser revenue. It is required if OverrideAdvertiserRevenue is true. Remove it from your call if OverrideAdvertiserRevenue is set to false. Only whole numbers with up to 4 decimals allowed. Example: 1.2555
Content - Required Only for Custom Banner, Flash, HTML, Popup and Text creatives. This is where the HTML code for the creative is placed. HTML MUST BE ENCODED.
OverrideTrackingDomain -This is an optional value and is used to override the default tracking and impression domain returned in the API response. The ReplaceAllLinksWithTrackingLink field must be set to true for this field to work. If you submit a valid URL for this field and an affiliate ID, the tracking link will be displayed with the specific affiliate ID, (http://www.cnn.com/click.track?CID=123456&AFID=123456&ADID=123456&SID= ). If you submit a valid URL without an affiliate ID, the response will display the tracking link with the affiliate ID represented as a token, http://www.cnn.com/click.track?CID=123456&AFID=[=AFID=]&ADID=123456&SID=. The domain must be a valid URL and may be submitted with or without http://.(www.mytrackingdomain.com)
*Note: If your tracking domain points to an RTA, when the final response from the API will contain a click.track file name/extension. Therefore, you must ensure that your RTA file hosted at the domain submitted is named click.track. Also,ensure that your tracking link format is set to ‘Standard’ for the campaign.
Adding Products via the Creative Links to the Product Data Feeds
The field requirements to add products via creative links to the product data feed follow the same requirements for the product data feed API.
Adding products to the product data feed via creative links is easy with this API. In order for the product data feed in LinkTrust to recognize the creative link tag names (name value pair) in your creative links, you will need to map your tag names with the field names in the product data feed. For example, the product data feed requires a SKU value in order for a product to be added to your data feed. The tag name for the SKU in your creative link may not be named SKU. That’s okay, the API will allow you to specify which variable you would like to use as the SKU. Whatever value you assign to the SkuTagName will be associated to the SKU value in the product data feed. For example, if you assign the SkuTagName to be “dog” in your href link, and the value for “dog” is 123, that value will be recorded as the SKU value in the product data feed.
Example Link: <a dog="123" productname="air jordans" href="http://www.google.com"><img border="0" src="http://www.linkimg.com/auto/720x400animatedtest.gif" alt="" /></a>
The following product data feed fields are available for mapping. Only three values are required to add a product to the product data feed; AddProductDataForEachLink, SkuTagName and ProductNameTagName.
*AddProductDataForEachLink - This field is required in order to add the links in your creative to the product data feed. This field allows true or false values and is ONLY for HTML, Custom Banner, Pop Up or Flash type creatives.
*SkuTagName – Required. This is your unique SKU tag name that you would like LinkTrust to map to the SKU value in your data feed for this campaign.
*ProductNameTagName – Required. This is your unique tag name for the product name that you would like LinkTrust to map to the product name in your data feed for this campaign.
AutoCreateSkuForLinks – true or false, this is optional and the default value is false. This will automatically create a unique SKU for each link in the following format: ADID-LinkNumber. Example: SKU for link #1: 12345-1, link #2: 12345-2
DescriptionTagName - This is your unique tag name for the product description that you would like LinkTrust to map to the product description in your data feed for this campaign.
RetailPriceTagName - This is your unique tag name for the retail price that you would like LinkTrust to map to the retail price in your data feed for this campaign.
SalePriceTagName - This is your unique tag name for the sale price that you would like LinkTrust to map to the sale price in your data feed for this campaign.
DiscountTagName - This is your unique tag name for the product discount that you would like LinkTrust to map to the product discount in your data feed for this campaign.
ImageUrlTagName - This is your unique tag name for the product image URL that you would like LinkTrust to map to the product image URL in your data feed for this campaign.
RevenueTypeTagName - Flat or Percent, default is Flat. This is your unique tag name for the revenue type that you would like LinkTrust to map to the revenue type in your data feed for this campaign. This API follows the same requirements as the product data feed API. If the campaign default revenue is Flat, the revenue type must be Flat.
RevenueTagName - This is your unique tag name for the revenue that you would like LinkTrust to map to the revenue in your data feed for this campaign.
PayoutTypeTagName - Flat or Percent, default is Flat. This is your unique tag name for the payout type that you would like LinkTrust to map to the payout type in your data feed for this campaign. This follows the same requirements as the product data feed. If the campaign default revenue is Flat, the payout type must be Flat.
PayoutTagName - This is your unique tag name for the payout that you would like LinkTrust to map to the payout in your data feed for this campaign.
CategoryTagName - This is your unique tag name for the category that you would like LinkTrust to map to the category in your data feed for this campaign.
BrandTagName - This is your unique tag name for the brand that you would like LinkTrust to map to the brand in your data feed for this campaign.
AlternateDestinationURL – This is created from the original URL within each href link in the creative code.
AdditionalData1TagName - This is your unique tag name for the additional data 1 field that you would like LinkTrust to map to the additional data 1 field in your data feed for this campaign.
AdditionalData2TagName - This is your unique tag name for the additional data 2 field that you would like LinkTrust to map to the additional data 2 field in your data feed for this campaign.
AdditionalData3TagName - This is your unique tag name for the additional data 3 field that you would like LinkTrust to map to the additional data 3 field in your data feed for this campaign.
Example XML
<CampaignCreative>
<Creative>
<CampaignId>100183</CampaignId>
<Enabled>true</Enabled>
<AffiliateId>100000</AffiliateId>
<Name>Test8</Name>
<Type>HTML</Type>
<AddImpressionTrackingCode>true</AddImpressionTrackingCode>
<ReplaceAllLinksWithTrackingLink>false</ReplaceAllLinksWithTrackingLink>
<ShowInAffiliateCenter>true</ShowInAffiliateCenter>
<ShowTrackingLinkInListing>true</ShowTrackingLinkInListing>
<CustomLandingPageUrl>http://www.google.com?id=123&pid=234</CustomLandingPageUrl>
<PropagateAditionalData>true</PropagateAditionalData>
<OverrideAffiliatePayout>true</OverrideAffiliatePayout>
<AffiliatePayout>1.23</AffiliatePayout>
<AffiliatePayoutType>Flat</AffiliatePayoutType>
<OverrideAdvertiserRevenue>true</OverrideAdvertiserRevenue>
<AdvertiserRevenue>2.3</AdvertiserRevenue>
<Content><table cellspacing="0" cellpadding="0" border="0" align="center">
<tbody>
<tr>
<td align="center">
<table cellspacing="0" cellpadding="0" border="0">
<tbody>
<tr>
<td><a dog="54" description="awesome fit" category="clothing" brand="nike" data3="new shoes" data2="help me" data1="go away" revenue="15" imageUrl="http://www.na.com/images/lt_testing/cheese.jpg" retailPrice="90" payout="10" discount="10%" salePrice="50" sugar="airjordans" href="http://www.google.com"><img border="0"
src="http://www.na.com/auto/720x400animatedtest.gif" alt="" /></a></td>
</tr>
</tbody>
</table>
</td>
</tr>
<tr>
<td align="center">
<table width="450" border="0">
<tbody>
<tr>
<td align="center"><font size="1" face="Arial"
color="#000000">To Contact Advertiser by Postal Mail:<br />Na sales, 123Test St., San Diego,CA 12345<br /><a dog="55" description="snug" category="footwear" brand="adidas" data3="shoes" data2="eat chicken" data1="go away" revenue="150" imageUrl="http://www.na.com/images/lt_testing/cheese.jpg" retailPrice="190" payout="100" discount="10%" salePrice="150" sugar="jordans" href="http://www.na.com/suppression.html">Unsubscribe Here</a></font></td>
</tr>
</tbody>
</table>
<img height="&rdquo;1&rdquo;" width="&rdquo;1&rdquo;"
src="&rdquo;http://www.na.com/imp.aspx?
a=239&amp;b=2172&amp;c=1&amp;DID=1804&rdquo;" alt="" /></td>
</tr>
</tbody>
</table></Content>
</Creative>
<CreativeProductProperties>
<AddProductDataForEachLink>true</AddProductDataForEachLink>
<AutoCreateSkuForLinks>false</AutoCreateSkuForLinks>
<SkuTagName>dog</SkuTagName>
<PayoutTagName>payout</PayoutTagName>
<RevenueTagName>revenue</RevenueTagName>
<ProductNameTagName>productName</ProductNameTagName>
<SalePriceTagName>salePrice</SalePriceTagName>
<RetailPriceTagName>retailPrice</RetailPriceTagName>
<DiscountTagName>discount</DiscountTagName>
<CategoryTagName>category</CategoryTagName>
<BrandTagName>brand</BrandTagName>
<DescriptionTagName>description</DescriptionTagName>
<ImageUrlTagName>imageUrl</ImageUrlTagName>
<AdditionalData1TagName>data1</AdditionalData1TagName>
<AdditionalData2TagName>data2</AdditionalData2TagName>
<AdditionalData3TagName>data3</AdditionalData3TagName>
</CreativeProductProperties>
</CampaignCreative>
You can request a demo to see LinkTrust up close and experience how it can help you, or start your free 14-day trial now.
Need help with this feature or have questions? You can contact our support team at support@linktrust.com