I would like to know which API has the information that will return the updated user properties to include the user’s last login data.
Hello, Roy!
In order to retrieve users last login date Backendless Data API can be used. Just make request to retrieve users and the response would contain lastLogin value in timestamp format.
Here is documentation for REST API: https://backendless.com/documentation/data/rest/data_basic_search.htm
For your case just use “Users” as <table-name>.
best regards,
Alex
The call to get the user properties is what I am using to return the data for a user. The ACL, lastLogin, userStatus, aren’t returned. Is this functionality in this updated version of Backendless?
Sure, it’s presented in the new version.
Can you please show the request you’re using?
The call is using the GET HTTP method with the URL of https://api.backendless.com/v1/users/users/<user_objectId>?props=name,lastLogin
Roy, I’ve reproduced this issue and we shall fix it. Thank you for reporting!
For now you can use requests without “props” - this way lastLogin and userStatus would be returned in response. Field “ACL” is not a table property - it’s just a link to ACL settings for a particular object. So, ACL is not expected to return in response.
Thanks for looking into this.
I tried using the request without the props and the lastLogin came back with null. The URL I used was
https://api.backendless.com/v1/users/users/<user_objectId>
Also, the objectId is of a user that isn’t currently logged in with my application.
Are you sure that this user has ever been logged in? If he has not - lastLogin value would really be null.
Hi, Roy!
These are valid requests, please use them.
Without properties:
curl -X GET -H ‘application-id : xxx’ -H ‘secret-key : xxx’ http://api.backendless.com/v1/users/03E1A642-8BAB-A9F5-FF6F-3C11C7CDF500
Including properties:
curl -X GET -H ‘application-id : xxx’ -H ‘secret-key : xxx’ http://api.backendless.com/v1/users/03E1A642-8BAB-A9F5-FF6F-3C11C7CDF500?props=name,lastLogin
Thanks for all the information. Using the API with or without properties works.