Fetching User Profile
Make a network call to fetch the userInfo using access token from step 14. The response would be corresponding to the scopes granted by the user.
GET https://oauth-account-noneu.truecaller.com/v1/userinfo
Headers
Authorization*
"Bearer <ACCESS_TOKEN>"
Insert access token from the previous step - fetching user token
{
“sub”: “13627101294235520", “given_name”: “abc”, “family_name”: “xyz”, “gender”: “male/female”, “birthdate”: “YYYY-MM-DD”, “picture”: “https://www.truecaller.com/xyz”, “email”: “pqr@gmail.com”, “phone_number”: “91xxxxxxxxxx", “phone_number_verified”: true, “phone_number_country_code”: “IN”, “address”: { “locality”: “Bangalore”, “postal_code”: “5xxxxx" }
}
{ "status": 40409, "message": "Profile not found" }
{ "status": 50010, "message": "Auth service error" }
{ "error": 42201, "error_description": "Missing profile data" }
{ "error": 50001, "error_description": <reason> }
Sample cURL request :
curl --location --request GET 'https://oauth-account-noneu.truecaller.com/v1/userinfo' \
--header 'Authorization: Bearer testtoken'
Last updated
Was this helpful?