cancel
Showing results for 
Search instead for 
Did you mean: 

Any way to get usernames from outside of the Oculus Platform SDK?

tjpeebles
Honored Guest
I'm building a game that is going to be on multiple platforms (Steam, Oculus, PSVR, etc) so I didn't want to use the Oculus Platform SDK for leaderboards. Instead I set up my own database and store entries from any platform into it and display them as well. For Steam, I've been using the Steam Web API to get the Steam usernames based on the Steam ID in the entry if the player is playing outside of Steam. For Oculus, is there a similar way to get the username based on the user ID that I'm storing in the database if the player is playing outside of the Oculus platform? I'm using Unity as my game engine.


5 REPLIES 5

juanoldinho
Heroic Explorer
Hi,

Have a look at the documentation here regarding making REST requests:
https://developer3.oculus.com/documentation/platform/latest/concepts/dg-development/#dg-rest
Please tag me, @juanoldinho, in your forum post/response if you need immediate assistance or want additional support or context on an issue you are having with our software or integrations.

Having an issue with our platform, services, or integrations?

Try using our new bug tool to report this and receive emailed updates as we proceed to address it internally.

tjpeebles
Honored Guest
Thanks for the direction. I'm trying to get a username with a user id that I got from making a call inside my app. This is the call I'm doing but I'm getting an error.

https://graph.oculus.com/$app_id/use_getr?access_token=OC|$app_id|$app_secret&user_id=$user_id

I replaced the variables with the stuff like $app_id so I didn't post that information publicly, but the values I'm using are all correct I think.

This is the error I got.

{
"error": {
"message": "Tried accessing nonexisting field (user_get) on node type (Application)",
"type": "OCApiException",
"code": 100,
"fbtrace_id": "H8Tzi41jK+4"
}
}

tjpeebles
Honored Guest
Can anyone help me with a link to the documentation? I haven't been able to find it anywhere. The closest I have been able to find is the facebook graph api which was helpful but I need to know what kind of REST requests I can make for Oculus specifically.

Anonymous
Not applicable
RestAPI.pdf attached.

tjpeebles
Honored Guest
Is that the entire API? And if so does that mean the answer juanoldinho gave me was incorrect and that you can't actually use the REST API to get a username from a user id from outside of the application or am I missing something in that document?