Thank you! My mistake was in ProfileEntry, I was using ProfileFeed.
On Aug 17, 6:29 am, "Julian (Google)" <[email protected]> wrote:
> Hi,
>
> How are you retrieving the Profile?
>
> Here is an example:
>
> URL entryUrl = new URL("http://www.google.com/m8/feeds/profiles/domain/
> domain.com/full/user");
> ProfileEntry entry = contactsService.getEntry(entryUrl,
> ProfileEntry.class);
>
> System.out.println("\n" + entry.getTitle().getPlainText());
>
> Cheers,
> Julian.
>
> On Aug 14, 11:45 pm, NMAGOCIO <[email protected]> wrote:
>
> > Being that Profiles API is in the contacts java library I hope this
> > group can help.
> > I am trying to query out by user.
>
> > URL metafeedUrl = new URL("http://www.google.com/m8/feeds/profiles/
> > domain/domain.com/full/");
> > Works fine returning 60 entries
>
> > From Google Docs for Profiles:
> > Retrieving a single profile
>
> > Each profile entry in a profiles feed has a self link. To retrieve a
> > specific profile, send an HTTP GET request to the profile's self link.
> > The server returns a profile entry. For example, to get a profile for
> > [email protected], send the following HTTP request:
>
> > GEThttp://www.google.com/m8/feeds/profiles/domain/example.com/full/liz
>
> > Does not work:
> > URL metafeedUrl = new URL("http://www.google.com/m8/feeds/profiles/
> > domain/domain.com/full/MyProfileName");
>
> > com.google.gdata.util.ParseException: [Line 1, Column 273] Invalid
> > root element, expected (namespace uri:local name) of
> > (http://www.w3.org/2005/Atom:feed), found (http://www.w3.org/2005/Atom:entry
> > at
> > com.google.gdata.util.XmlParser.throwParseException(XmlParser.java:
> > 722)
> > at com.google.gdata.util.XmlParser.parse(XmlParser.java:685)
> > at com.google.gdata.util.XmlParser.parse(XmlParser.java:568)
> > at com.google.gdata.data.BaseFeed.parseAtom(BaseFeed.java:793)
> > at com.google.gdata.wireformats.input.AtomDataParser.parse
> > (AtomDataParser.java:68)
> > at com.google.gdata.wireformats.input.AtomDataParser.parse
> > (AtomDataParser.java:39)
> > at com.google.gdata.wireformats.input.CharacterParser.parse
> > (CharacterParser.java:100)
> > at com.google.gdata.wireformats.input.XmlInputParser.parse
> > (XmlInputParser.java:52)
> > at com.google.gdata.wireformats.input.AtomDualParser.parse
> > (AtomDualParser.java:66)
> > at com.google.gdata.wireformats.input.AtomDualParser.parse
> > (AtomDualParser.java:34)
> > at com.google.gdata.client.Service.parseResponseData(Service.java:
> > 1896)
> > at com.google.gdata.client.Service.getFeed(Service.java:1054)
> > at com.google.gdata.client.Service.getFeed(Service.java:916)
> > at com.google.gdata.client.GoogleService.getFeed(GoogleService.java:
> > 631)
> > at com.google.gdata.client.Service.getFeed(Service.java:935)
> > at ProfilesApi.main(ProfilesApi.java:34)
> > Caused by: com.google.gdata.util.ParseException: Invalid root element,
> > expected (namespace uri:local name) of (http://www.w3.org/2005/
> > Atom:feed), found (http://www.w3.org/2005/Atom:entry
> > at com.google.gdata.util.XmlParser.startElement(XmlParser.java:794)
> > at
> > org.xml.sax.helpers.ParserAdapter.startElement(ParserAdapter.java:
> > 597)
> > at
> > com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.startElement
> > (AbstractSAXParser.java:491)
> > at
> > com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.scanStartElement
> > (XMLNSDocumentScannerImpl.java:330)
> > at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl
> > $NSContentDispatcher.scanRootElementHook(XMLNSDocumentScannerImpl.java:
> > 779)
> > at
> > com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl
> > $FragmentContentDispatcher.dispatch
> > (XMLDocumentFragmentScannerImpl.java:1794)
> > at
> > com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument
> > (XMLDocumentFragmentScannerImpl.java:368)
> > at
> > com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse
> > (XML11Configuration.java:834)
> > at
> > com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse
> > (XML11Configuration.java:764)
> > at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse
> > (XMLParser.java:148)
> > at
> > com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse
> > (AbstractSAXParser.java:1242)
> > at org.xml.sax.helpers.ParserAdapter.parse(ParserAdapter.java:405)
> > at com.google.gdata.util.XmlParser.parse(XmlParser.java:677)
> > ... 14 more
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Google Contacts API" 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/google-contacts-api?hl=en
-~----------~----~----~----~------~----~------~--~---