How do I get the first name (or full name) of the phone user?

advertisements

Is there a way to get the user's first name or entire name? I mean the user of the phone

does it require special manifest permissions?


What exactly do you mean? You may be able to access the name in certain ways:

  1. You can try to access their information stored in a Google account, requiring the GET_ACCOUNTS permission
  2. You could, as Vinayak.B suggested, try to glean the info from the contacts, requiring the READ_CONTACTS and the READ_PHONE_STATE permission, although I think this is a hit-or-miss option.
  3. There is also a READ_PROFILE permission, which I think is an interesting way to go, but I don't have any experience with that, so I can't tell you whether or not it's a fruitful venture.

I would try the GET_ACCOUNTS option first, since they must have a Google account to download your app. It also seems a little less invasive to me

I really hope this answers your question, but if it doesn't, you really need to provide more information.