Yammer REST API : GET /messages.json retrieving only top 20 messages with limit set as 10000

Occasional Visitor



How can I retrieve all the messages? When I execute GET on /messages.json, I get only the top 20 messages.


Note: I have verified admin access token.

2 Replies

From what I understood you will only retrieve 20 messages by request, and you have to play with the "newer_than" and "older_than" params to retrieve the messages you want.

I guess that if you want to retrieve all the messages, you can use the data export api (https://developer.yammer.com/docs/data-export-api). You can specify an interval of dates between which you want to retrieve messages. You have to do a little of parsing because it send you back a zip containing some csv files, one of these file contains all the messages.