I had problems with paging too. Due to lack of documentation, I think
API is inconsistent or incomplete for paging and sorting.

The command that I am using is:

var command = "{ 'method' : 'activities.get', 'params':{'userId':['" +
userId + "'], 'groupId':'@friends', 'fields' : ['@all'],
'count':'100', 'startIndex':'0', 'coalesce':true, 'itemsPerPage':'20'}
}";

If you want to get a page greater than 0, I think you should use
updateBefore parameter, but I can't put the command to work properly
with this parameter. This is the reason that I list 100 items on 1
single step.



Best.



On Wed, Apr 13, 2011 at 5:25 AM, Matthew Young <[email protected]> wrote:
> When I use orkuct-os-client to retrieve activities, only can get old
> activities, the newer activities cannot be retrieved. The post data shows as
> below:
> [{"params":{"groupId":"@self","userId":"@me","count":10,"coalesce":true,"startIndex":0},"id":"0-activities.get","method":"activities.get"}]
> Getting activities...
> ...done
> Page: 1
> ProfileUpdateActivity
> Activity Type    : PROFILE_UPDATE
> ID               : 0
> Owner ID         : 11116434431620433651
> Posted time      : 1302509861
> Relevant users   : 1
> Relevant profiles: no
>
> Get next page [y/n]?
> y
> [{"params":{"updatedBefore":"2011-04-11T08:17:41Z","groupId":"@self","userId":"@me","count":10,"coalesce":true,"startIndex":0},"id":"1-activities.get","method":"activities.get"}]
> Page: 2
> PhotoShareActivity
> Activity Type    : PHOTO
> ID               : 0
> Owner ID         : 11116434431620433651
> Posted time      : 1301722978
> Relevant users   : 1
> Relevant profiles: no
>
> the first post , I want to get 10 activities , but return one, and the 2
> page return one activity.
>
>
> --
> You received this message because you are subscribed to the Google Groups
> "orkut Developer Forum" group.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to
> [email protected].
> For more options, visit this group at
> http://groups.google.com/group/opensocial-orkut?hl=en.
>



-- 
--
Allann Jones

"I received the fundamentals of my education in school, but that was
not enough. My real education, the superstructure, the details, the
true architecture, I got out of the public library. For an
impoverished child whose family could not afford to buy books, the
library was the open door to wonder and achievement, and I can never
be sufficiently grateful that I had the wit to charge through that
door and make the most of it." (from I. Asimov, 1994)

-- 
You received this message because you are subscribed to the Google Groups 
"orkut Developer Forum" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/opensocial-orkut?hl=en.

Reply via email to