Details

    • Type: Sub-Task
    • Status: Closed
    • Priority: Minor
    • Resolution: Completed
    • Affects Version/s: None
    • Fix Version/s: GoogleMerchant
    • Component/s: None
    • Labels:
      None

      Description

      Generate XML for feed and entries (products) in Atom 1.0

      Map only the following attributes that are not affected by Options and Specifications. Values for each attribute are retrieved as specified:

      • id: cpSku.getSku()
      • title: cpCatalogEntry.getName() + list of option names and values. Example: "T-shirt Size: M Color: Blue"
      • description: cpCatalogEntry.getDescription()
      • link: PortalUtil.getPortalURL() + cpCatalogEntry.getUrl()
      • image_link: PortalUtil.getPortalURL() + _commerceMediaResolver.getUrl(
        cpAttachmentFileEntryId)
      • additional_image_link: PortalUtil.getPortalURL() + _commerceMediaResolver.getUrl(cpAttachmentFileEntryId)
      • availability: commerceInventoryEngine.getStockQuantity() and cpDefinitionInventoryEngine.isBackOrderAllowed()
      • cost_of_goods_sold: cpInstance.getCost()
      • expiration_date: cpInstance.getExpirationDate()
      • price: _commerceProductPriceCalculation.getUnitPrice()
      • sale_price: _commerceProductPriceCalculation.getPromoPrice()
      • gtin: cpSku.getGtin()
      • mpn: cpSku.getManufacturerPartNumber()
      • is_bundle: true if GroupedCPTypeConstants.NAME.equals(cpCatalogEntry.getProductTypeName())
      • shipping_weight: cpInstance.getWeight()
      • shipping_length: cpInstance.getDepth()
      • shipping_width: cpInstance.getWidth()
      • shipping_height: cpInstance.getHeight()
      • tax: if(cpDefinition.isTaxExempt()) {rate = 0.00}
      • tax_category: cpDefinition.getCPTaxCategory().getName(languageId)

      See https://docs.google.com/document/d/12b02fb2gS8Wrf_qFxkQdXv3_fd_W7GJg0qsQyqF1_nU/edit#heading=h.5glixbplbudc for more details.

      Sample Atom 1.0 XML file: https://support.google.com/merchants/answer/160593?hl=en&ref_topic=2473799

      <?xml version="1.0"?>
      <feed xmlns="http://www.w3.org/2005/Atom" xmlns:g="http://base.google.com/ns/1.0">
      	<title>Example - Online Store</title>
      	<link rel="self" href="http://www.example.com"/>
      	<updated>20011-07-11T12:00:00Z</updated> 
      		
      	<!-- First example shows what attributes are required and recommended for items that are not in the apparel category -->
      	<entry>
      		<!-- The following attributes are always required -->
      		<g:id>TV_123456</g:id>
      		<g:title>LG 22LB4510 - 22" LED TV - 1080p (FullHD)</g:title>
      		<g:description>Attractively styled and boasting stunning picture quality, the LG 22LB4510 - 22&quot; LED TV - 1080p (FullHD) is an excellent television/monitor. The LG 22LB4510 - 22&quot; LED TV - 1080p (FullHD) sports a widescreen 1080p panel, perfect for watching movies in their original format, whilst also providing plenty of working space for your other applications.</g:description>
      		<g:link>http://www.example.com/electronics/tv/22LB4510.html</g:link>
      		<g:image_link>http://images.example.com/TV_123456.png</g:image_link>
      		<g:condition>used</g:condition>
      		<g:availability>in stock</g:availability>
      		<g:price>159.00 USD</g:price>
      		<g:shipping>
      			<g:country>US</g:country>
      			<g:service>Standard</g:service>
      			<g:price>14.95 USD</g:price>
      		</g:shipping>
      			
      		<!-- 2 of the following 3 attributes are required fot this item according to the Unique Product Identifier Rules -->
      		<g:gtin>71919219405200</g:gtin>
      		<g:brand>LG</g:brand>
      		<g:mpn>22LB4510/US</g:mpn>
      			
      		<!-- The following attributes are not required for this item, but supplying them is recommended -->
      		<g:google_product_category>Electronics > Video > Televisions > Flat Panel Televisions</g:google_product_category>
      		<g:product_type>Consumer Electronics &gt; TVs &gt; Flat Panel TVs</g:product_type>
      	</entry>
      		
      	<!-- Second example demonstrates the use of CDATA sections instead of entities to deal with special characters. Note that CDATA sections can be used for any attribute -->
      	<entry>
      		<!-- The following attributes are always required -->
      		<g:id>DVD-0564738</g:id>
      		<g:title><![CDATA[Merlin: Series 3 - Volume 2 - 3 DVD Box set]]></g:title>
      		<g:description><![CDATA[Episodes 7-13 from the third series of the BBC fantasy drama set in the mythical city of Camelot, telling the tale of the relationship between the young King Arthur (Bradley James) & Merlin (Colin Morgan), the wise sorcerer who guides him to power and beyond. Episodes are: 'The Castle of Fyrien', 'The Eye of the Phoenix', 'Love in the Time of Dragons', 'Queen of Hearts', 'The Sorcerer's Shadow', 'The Coming of Arthur: Part 1' & 'The Coming of Arthur: Part 2']]></g:description>
      		<g:link><![CDATA[http://www.example.com/media/dvd/?sku=384616&src=gshopping&lang=en]]></g:link>
      		<g:image_link><![CDATA[http://images.example.com/DVD-0564738?size=large&format=PNG]]></g:image_link>
      		<g:condition>new</g:condition>
      		<g:availability>in stock</g:availability>
      		<g:price>11.99 USD</g:price>
      		<g:shipping>
      			<g:country>US</g:country>
      			<g:service>Express Mail</g:service>
      			<g:price>3.80 USD</g:price>
      		</g:shipping>
      			
      		<!-- 2 out of the 3 unique product identifer attributes are required for this item -->
      		<g:gtin>88392916560500</g:gtin>
      		<g:brand>BBC</g:brand>
      			
      		<!-- The following attribute is required because this item is in the 'Media' category -->
      		<g:google_product_category><![CDATA[Media > DVDs & Videos]]></g:google_product_category>
      			
      		<!-- The following attributes are not required for this item, but supplying them is recommended if applicable -->
      		<g:product_type><![CDATA[DVDs & Movies > TV Series > Fantasy Drama]]></g:product_type>
      	</entry>
      </feed>
       

       

        Attachments

          Activity

            People

            Assignee:
            kayleen.lim Kayleen Lim
            Reporter:
            kayleen.lim Kayleen Lim
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:

                Packages

                Version Package
                GoogleMerchant