@@ -25,64 +25,78 @@ public function getList(string $id): TwitterList
2525 return new TwitterList ($ response ->getData ());
2626 }
2727
28- public function getUserOwnedLists (string $ id ): TwitterLists
28+ public function getUserOwnedLists (string $ id, ? int $ maxResults = 100 , ? string $ paginationToken = null ): TwitterLists
2929 {
3030 $ response = $ this ->get ('users/ ' . $ id . '/owned_lists ' , [
3131 'list.fields ' => $ this ->listFields ,
32+ 'max_results ' => $ maxResults ,
33+ 'pagination_token ' => $ paginationToken ,
3234 ]);
3335
3436 return new TwitterLists ($ response ->getData ());
3537 }
3638
37- public function getListTweets (string $ id ): Tweets
39+ public function getListTweets (string $ id, ? int $ maxResults = 100 , ? string $ paginationToken = null ): Tweets
3840 {
3941 $ response = $ this ->get ('lists/ ' . $ id . '/tweets ' , [
4042 'tweet.fields ' => $ this ->tweetFields ,
43+ 'max_results ' => $ maxResults ,
44+ 'pagination_token ' => $ paginationToken ,
4145 ]);
4246
4347 return new Tweets ($ response ->getData ());
4448 }
4549
46- public function getListMembers (string $ id ): Users
50+ public function getListMembers (string $ id, ? int $ maxResults = 100 , ? string $ paginationToken = null ): Users
4751 {
4852 $ response = $ this ->get ('lists/ ' . $ id . '/members ' , [
4953 'user.fields ' => $ this ->userFields ,
54+ 'max_results ' => $ maxResults ,
55+ 'pagination_token ' => $ paginationToken ,
5056 ]);
5157
5258 return new Users ($ response ->getData ());
5359 }
5460
55- public function getUserMemberships (string $ id ): TwitterLists
61+ public function getUserMemberships (string $ id, ? int $ maxResults = 100 , ? string $ paginationToken = null ): TwitterLists
5662 {
5763 $ response = $ this ->get ('users/ ' . $ id . '/list_memberships ' , [
5864 'list.fields ' => $ this ->listFields ,
65+ 'max_results ' => $ maxResults ,
66+ 'pagination_token ' => $ paginationToken ,
5967 ]);
6068
6169 return new TwitterLists ($ response ->getData ());
6270 }
6371
64- public function getListFollowers (string $ id ): Users
72+ public function getListFollowers (string $ id, ? int $ maxResults = 100 , ? string $ paginationToken = null ): Users
6573 {
6674 $ response = $ this ->get ('lists/ ' . $ id . '/followers ' , [
6775 'user.fields ' => $ this ->userFields ,
76+ 'max_results ' => $ maxResults ,
77+ 'pagination_token ' => $ paginationToken ,
6878 ]);
6979
7080 return new Users ($ response ->getData ());
7181 }
7282
73- public function getUserFollowedLists (string $ id ): TwitterLists
83+ public function getUserFollowedLists (string $ id, ? int $ maxResults = 100 , ? string $ paginationToken = null ): TwitterLists
7484 {
7585 $ response = $ this ->get ('users/ ' . $ id . '/followed_lists ' , [
7686 'list.fields ' => $ this ->listFields ,
87+ 'max_results ' => $ maxResults ,
88+ 'pagination_token ' => $ paginationToken ,
7789 ]);
7890
7991 return new TwitterLists ($ response ->getData ());
8092 }
8193
82- public function getUserPinnedLists (string $ id ): TwitterLists
94+ public function getUserPinnedLists (string $ id, ? int $ maxResults = 100 , ? string $ paginationToken = null ): TwitterLists
8395 {
8496 $ response = $ this ->get ('users/ ' . $ id . '/pinned_lists ' , [
8597 'list.fields ' => $ this ->listFields ,
98+ 'max_results ' => $ maxResults ,
99+ 'pagination_token ' => $ paginationToken ,
86100 ]);
87101
88102 return new TwitterLists ($ response ->getData ());
0 commit comments