We have a soql query which we run against the api that works on User object
Select Id,Name from User;
we are trying to enhance the query to retrieve the profile.name and role.name using the same query
Select profile.name,role.name,Id,Name from User;
we are getting invalid_grant: authentication failure
when we run the query was wondering do we need special access to access these objects ? if someone could please point us in the right direction it would be of great help