Extracting 'last visit' info by using the API

Is there currently a way to extract the ‘last visit’ marker location (as in, which is the newest post after the last visit) via the API? I have had a look at what I get from hitting the ‘latest.json’ endpoint, and was assuming there might be a way to derive the location of the last visit from there, but I don’t think that info is in there. Or is it? Any help is greatly appreciated on this. Thanks!

PS: In case you’re wondering about the use case, we’re just trying to integrate discourse better into our community page, and want to alert users if there is new content available for them.

You need both latest.json and user.json:

https://meta.discourse.org/latest.json

Every topic where bumped_at is more recent that the user last_seen_at is above the line.

4 Likes

Wow, thanks for the fast answer. Sounds good, that’s how I’ll do it then.

2 Likes

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.