14

I tried to get user detail using https://graph.facebook.com/username . But it throws an error

    "error": {
      "message": "(#803) Cannot query users by their username (ramesh.randika.56)",
      "type": "OAuthException",
      "code": 803
   }

does anybody have a solution for this problem.

ramesh
  • 161
  • 1
  • 1
  • 4
  • possible duplicate of [Facebook Graph API v2.1: getting user id and his posts](http://stackoverflow.com/questions/25258670/facebook-graph-api-v2-1-getting-user-id-and-his-posts) – cygery Jun 16 '15 at 12:58
  • It says it right there already: _Cannot query users by their username_ The field `username` was removed with API v2 – your app is _not supposed_ to get information about arbitrary users any more. – CBroe Jun 16 '15 at 13:00
  • @cygery He can't use the suggested solution anymore, because v1.0 is gone. – Tobi Jun 16 '15 at 13:06
  • @cygery not a duplicate. I just want to try this on my browser https://graph.facebook.com/username/picture?width=800 – ramesh Jun 16 '15 at 14:47
  • @ramesh This doesn't work anymore – Tobi Jun 16 '15 at 14:57

3 Answers3

9

graph.facebook.com/{Username} is not avaiable now but lookup-id.com still can find your facebook ID, facebook group ID and facebook page ID

  • 3
    Any Idea how does this website works as now the API support support has been withdrawn? – coder Jun 17 '15 at 16:34
  • When I try that site I get: "Unable to lookup. Note that the system just response for Open Group". So it seems that they have cached data if you looked it up before but if you look up something new they have no idea what the id is. – WizKid Jun 17 '15 at 17:50
  • @WizKid sometimes i receive it too then i try again it is ok – Trần Văn Thuận Jun 18 '15 at 01:49
7

"View page source" Option in every web browser will help you. Follow this-

  1. Open the timeline of that person/FB account.
  2. Right-click anywhere on the web-page->View page Source-> wait 1 or 2 seconds to load the new page.
  3. Press Ctrl+f (used to find any string,word in the page) then type " profile_id= " (without quotes).
  4. Copy the long number after " = ", .

Conclusion : Using the "username" doesn't work anymore (Updated till Oct 2018),profile_id is the thing u needed instead.

knight
  • 105
  • 2
  • 5
3

The username field was removed with the introduction of the Graph API v2.0.

See

/me/username is no longer available.

Tobi
  • 31,405
  • 8
  • 58
  • 90