0

I use xmpp(asmack) to login and get contact from google talk. I look document about xmpp but not show about how to get birthday, gender, mobile phone... in xmpp in android. How can i get birthday, gender, mobile phone in xmpp? or have any other way can do that?

Flow
  • 22,048
  • 13
  • 91
  • 147
Chandara Sam
  • 323
  • 3
  • 7
  • 19

1 Answers1

1

XEP-54 describes the most common way to do this today. XEP-292 is the new version, which is starting to get some traction. Implement both for forward/backward compatibility.

Note that Google's servers don't support this protocol, so you'll have to ask your contact's client directly using an IQ to the full JID:

<iq id='v3'
    to='jer@example.org/work'
    type='get'>
  <vCard xmlns='vcard-temp'/>
</iq>

Please do NOT do this every time you log in. Please do NOT do this if the client you are connecting to supports XEP-115 and doesn't say that it supports vcard-temp. The responses that come back can be really large (due to embedded avatars), and cause a strain on the server infrastructure if you do too many of them.

Joe Hildebrand
  • 9,616
  • 1
  • 32
  • 45