Hi Stacie, You can only *add* attributes to a Feed. You won't be able to modify existing attributes of a Feed, e.g., you won't be able to change their types.
I would recommend against relying on specific attribute IDs always being of a specific type. In particular, feeds created by the AdWords system offer no guarantees about which attribute ID will be used for each placeholder field. A better solution would be to use the FeedMapping.attributeFieldMappings <https://developers.google.com/adwords/api/docs/reference/v201502/FeedMappingService.FeedMapping#attributeFieldMappings> to look up the feedAttributeId <https://developers.google.com/adwords/api/docs/reference/v201502/FeedMappingService.AttributeFieldMapping#feedAttributeId> that corresponds to each placeholder fieldId <https://developers.google.com/adwords/api/docs/reference/v201502/FeedMappingService.AttributeFieldMapping#fieldId> . Regarding migrating to extension settings, please check out our Migration Guide <https://developers.google.com/adwords/api/docs/guides/migrate-to-extension-settings>, which includes links to code examples in each language. Thanks, Josh, AdWords API Team On Friday, May 22, 2015 at 9:12:34 PM UTC-7, Stacie Waleyko wrote: > > Hello, > > We are working on migrating our sitelinks to use upgraded URLs. We are > using feed services to create sitelinks with link text going in attribute > #1 and the URL in attribute #2. New sitelinks are created with upgraded > URLs that are stored with attribute #2 (attribute #2 is of type URL_LIST). > For old sitelinks that have destination URLs attribute #2 is of type URL. > Ideally we would like to maintain consistency across the system and have > attribute #2 always correspond to an upgraded URL for *both* new and > migrated sitelinks. To migrate old sitelinks I tried to change attribute #2 > from URL to URL_LIST but I got an error. Is there any way to edit a > FeedAttribute? The only other way we could maintain consistency in our > system would be to create an additional attribute. Attribute #2 would have > to always be of type URL for the old destination URLs and then there would > be a new attribute #3 of type URL_LIST. This could work but I'm worried the > URL type might one day sunset since destination URLs are no longer being > supported. What is the best way to approach this? Also, I was not able to > find a guide for migrating sitelinks with feed services. Any documentation > on this would be greatly appreciated. > > Thanks, > > Stacie > > > > *The feed I'm trying to edit:* > > 2015-05-22 20:33:24,698 [P2T1] INFO c.g.a.a.a.l.c.A.soapXmlLogger - SOAP > Response: > <?xml version="1.0" encoding="UTF-8"?> > <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"> > <soap:Header> > <ResponseHeader xmlns=" > https://adwords.google.com/api/adwords/cm/v201502"> > <requestId>000516b770aedad90ab64ea1d40034a7</requestId> > <serviceName>FeedService</serviceName> > <methodName>get</methodName> > <operations>0</operations> > <responseTime>214</responseTime> > </ResponseHeader> > </soap:Header> > <soap:Body> > <getResponse xmlns=" > https://adwords.google.com/api/adwords/cm/v201502"> > <rval> > <totalNumEntries>1</totalNumEntries> > <Page.Type>FeedPage</Page.Type> > <entries> > <id>26292527</id> > <name>SiteLinkExtension</name> > <attributes> > <id>1</id> > <name>linkText</name> > <type>STRING</type> > <isPartOfKey>false</isPartOfKey> > </attributes> > <attributes> > <id>2</id> > <name>siteLinkUrl</name> > <type>URL</type> > <isPartOfKey>false</isPartOfKey> > </attributes> > <status>ENABLED</status> > <origin>USER</origin> > </entries> > </rval> > </getResponse> > </soap:Body> > </soap:Envelope> > > > > *SOAP request/response for trying to update attribute #2:* > > > > <?xml version="1.0" encoding="UTF-8"?> > <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" > xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi=" > http://www.w3.org/2001/XMLSchema-instance"> > <soapenv:Header> > <ns1:RequestHeader xmlns:ns1=" > https://adwords.google.com/api/adwords/cm/v201502" > soapenv:mustUnderstand="0"> > <ns1:clientCustomerId>redacted</ns1:clientCustomerId> > <ns1:developerToken>redacted</ns1:developerToken> > <ns1:userAgent>redacted</ns1:userAgent> > <ns1:validateOnly>false</ns1:validateOnly> > <ns1:partialFailure>false</ns1:partialFailure> > </ns1:RequestHeader> > </soapenv:Header> > <soapenv:Body> > <mutate xmlns="https://adwords.google.com/api/adwords/cm/v201502"> > <operations> > <operator>SET</operator> > <operand> > <id>26292527</id> > <name>SiteLinkExtension</name> > <attributes> > <id>1</id> > <name>linkText</name> > <type>STRING</type> > <isPartOfKey>false</isPartOfKey> > </attributes> > <attributes> > <id>2</id> > <name>siteLinkUrl</name> > <type>URL_LIST</type> > <isPartOfKey>false</isPartOfKey> > </attributes> > <status>ENABLED</status> > <origin>USER</origin> > </operand> > </operations> > </mutate> > </soapenv:Body> > </soapenv:Envelope> > > 2015-05-22 20:34:58,293 [P2T1] WARN c.g.a.a.a.l.c.A.soapXmlLogger - SOAP > Response: > <?xml version="1.0" encoding="UTF-8"?> > <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"> > <soap:Header> > <ResponseHeader xmlns=" > https://adwords.google.com/api/adwords/cm/v201502"> > <requestId>000516b776477cc00abfb9c2160046b0</requestId> > <serviceName>FeedService</serviceName> > <methodName>mutate</methodName> > <operations>0</operations> > <responseTime>89</responseTime> > </ResponseHeader> > </soap:Header> > <soap:Body> > <soap:Fault> > <faultcode>soap:Server</faultcode> > > <faultstring>[FeedError.ATTRIBUTES_DO_NOT_MATCH_EXISTING_ATTRIBUTES > @ operations[0].operand.attributes]</faultstring> > <detail> > <ApiExceptionFault xmlns=" > https://adwords.google.com/api/adwords/cm/v201502"> > > <message>[FeedError.ATTRIBUTES_DO_NOT_MATCH_EXISTING_ATTRIBUTES @ > operations[0].operand.attributes]</message> > > <ApplicationException.Type>ApiException</ApplicationException.Type> > <errors xmlns:xsi=" > http://www.w3.org/2001/XMLSchema-instance" xsi:type="FeedError"> > > <fieldPath>operations[0].operand.attributes</fieldPath> > <trigger/> > > <errorString>FeedError.ATTRIBUTES_DO_NOT_MATCH_EXISTING_ATTRIBUTES</errorString> > <ApiError.Type>FeedError</ApiError.Type> > > <reason>ATTRIBUTES_DO_NOT_MATCH_EXISTING_ATTRIBUTES</reason> > </errors> > </ApiExceptionFault> > </detail> > </soap:Fault> > </soap:Body> > </soap:Envelope> > > > > > -- -- =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ Also find us on our blog and Google+: https://googleadsdeveloper.blogspot.com/ https://plus.google.com/+GoogleAdsDevelopers/posts =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ You received this message because you are subscribed to the Google Groups "AdWords API Forum" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/adwords-api?hl=en --- You received this message because you are subscribed to the Google Groups "AdWords API Forum" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. Visit this group at http://groups.google.com/group/adwords-api. To view this discussion on the web visit https://groups.google.com/d/msgid/adwords-api/c61dc6e1-05a4-40b6-be97-492fa4cf2e41%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
