Skip to content

Movie collection endpoint returns incorrect pagination details #896

Closed

Description

@damienhaynes

Here are the header details returned when I GET: https://api.trakt.tv/sync/collection/movies?page=1&limit=100

{
"Connection": "keep-alive",
"Access-Control-Allow-Origin": "*",
"Vary": "Origin, accept-encoding",
"Access-Control-Expose-Headers": "X-Pagination-Page,X-Pagination-Page-Count,X-Pagination-Limit,X-Pagination-Item-Count,X-Trending-User-Count,X-Start-Date,X-End-Date,X-Sort-By,X-Sort-How,X-Private-User,X-Ratelimit,Retry-After,X-Upgrade-URL,X-Applied-Sort-By,X-Applied-Sort-How,Cache-Control,Pragma,Expires",
"Cache-Tag": "user,user_collection,movie,owner_id:837,resource:movie:993003,resource:movie:1044784,resource:movie:1040684,resource:movie:1074519,resource:movie:751145,resource:movie:903398,resource:movie:1169847,resource:movie:56580,resource:movie:1027747,resource:movie:1178309,resource:movie:1083999,resource:movie:991429,resource:movie:1033738,resource:movie:297,resource:movie:1052083,resource:movie:1077748,resource:movie:944042,resource:movie:897563,resource:movie:900786,resource:movie:540330",
"Cf-Placement": "remote-ATL",
"X-Content-Type-Options": "nosniff",
"X-Download-Options": "noopen",
"X-Frame-Options": "SAMEORIGIN",
"X-Permitted-Cross-Domain-Policies": "none",
"x-pagination-item-count": "1376",
"x-pagination-limit": "100",
"x-pagination-page": "1",
"x-pagination-page-count": "14",
"Speculation-Rules": ""/cdn-cgi/speculation"",
"CF-RAY": "a23369685e027d6d-SYD",
"Content-Length": "9032",
"Cache-Control": "private, no-cache, no-store, must-revalidate",
"Content-Type": "application/json; charset=utf-8",
"Date": "Thu, 30 Jul 2026 09:42:10 GMT",
"Server": "cloudflare"
}

I do not have 1376 movies. I only have 20!

Is some older value cached as I may have had lot of movies in my collection way back.

Activity

  1. kevincador commented on Jul 31, 2026

    @kevincador
    Contributor

    Do you have episodes in your Library?
    Are you using Plex Sync?

    Trying to figure out if the calculation is wrong or if it's a cache issue.

    Thanks for your feedback!

  2. damienhaynes commented on Jul 31, 2026

    @damienhaynes
    Author

    I don't use plex but I do have lots of episodes. However, these are movies.

  3. damienhaynes commented on Aug 1, 2026

    @damienhaynes
    Author

    fyi, here is my corresponding results for shows collection:

    {
    "Connection": "keep-alive",
    "Access-Control-Allow-Origin": "*",
    "Vary": "Origin, accept-encoding",
    "Access-Control-Expose-Headers": "X-Pagination-Page,X-Pagination-Page-Count,X-Pagination-Limit,X-Pagination-Item-Count,X-Trending-User-Count,X-Start-Date,X-End-Date,X-Sort-By,X-Sort-How,X-Private-User,X-Ratelimit,Retry-After,X-Upgrade-URL,X-Applied-Sort-By,X-Applied-Sort-How,Cache-Control,Pragma,Expires",
    "Cache-Tag": "user,user_collection,episode_metadata,owner_id:837,resource:show:180770,resource:show:162206,resource:show:140133,resource:show:58794,resource:show:280754,resource:show:228089,resource:show:171028,resource:show:195644,resource:show:232884,resource:show:291441,resource:show:191758,resource:show:1611,resource:show:195845,resource:show:37522,resource:show:204141,resource:show:184471,resource:show:174314,resource:show:94686,resource:show:249443,resource:show:4289,resource:show:226029,resource:show:257282,resource:show:138163,resource:show:155534,resource:show:133259,resource:show:69829,resource:show:239158,resource:show:173996,resource:show:205919,resource:show:188204,resource:show:193872,resource:show:202845,resource:show:118833,resource:show:134421,resource:show:196542,resource:show:193922,resource:show:59660,resource:show:154164,resource:show:119142,resource:show:4522,resource:show:189717,resource:show:193143,resource:show:46263,resource:show:4476,resource:show:191187,resource:show:1405,resource:show:46647,resource:show:197056,resource:show:211407,resource:show:199390,resource:show:48703,resource:show:108999,resource:show:156576,resource:show:104578,resource:show:179636,resource:show:170559,resource:show:60169,resource:show:172648,resource:show:94961,resource:show:148560,resource:show:193196,resource:show:140100,resource:show:152252,resource:show:2411,resource:show:170566,resource:show:199293,resource:show:138169,resource:show:193499,resource:show:1400,resource:show:146415,resource:show:142443,resource:show:125479,resource:show:145803,resource:show:127287,resource:show:54306,resource:show:135547,resource:show:148150,resource:show:43973,resource:show:3673,resource:show:129197,resource:show:60278,resource:show:60360,resource:show:112082,resource:show:107766,resource:show:126924,resource:show:47350,resource:show:56212,resource:show:4590,resource:show:31494",
    "Cf-Placement": "remote-EWR",
    "X-Content-Type-Options": "nosniff",
    "X-Download-Options": "noopen",
    "X-Frame-Options": "SAMEORIGIN",
    "X-Permitted-Cross-Domain-Policies": "none",
    "x-pagination-item-count": "89",
    "x-pagination-limit": "100",
    "x-pagination-page": "1",
    "x-pagination-page-count": "1",
    "Speculation-Rules": ""/cdn-cgi/speculation"",
    "CF-RAY": "a24304169c220fe5-SYD",
    "Content-Length": "272694",
    "Cache-Control": "private, no-cache, no-store, must-revalidate",
    "Content-Type": "application/json; charset=utf-8",
    "Date": "Sat, 01 Aug 2026 07:09:12 GMT",
    "Server": "cloudflare"
    }

  4. rectifyer commented on Aug 6, 2026

    @rectifyer
    Contributor

    I've identified the problem and should have a fix out next week.

  5. added theissue type on Aug 6, 2026
  6. rectifyer commented on Aug 26, 2026

    @rectifyer
    Contributor

    @damienhaynes Update is now deployed. A little delayed, but should hopefully be an accurate count now for you.

  7. damienhaynes commented on Aug 27, 2026

    @damienhaynes
    Author

    Thanks @rectifyer, looks to be fixed now:

    {
    "Connection": "keep-alive",
    "Access-Control-Allow-Origin": "*",
    "Vary": "Origin, accept-encoding",
    "Access-Control-Expose-Headers": "X-Pagination-Page,X-Pagination-Page-Count,X-Pagination-Limit,X-Pagination-Item-Count,X-Trending-User-Count,X-Start-Date,X-End-Date,X-Sort-By,X-Sort-How,X-Private-User,X-Ratelimit,Retry-After,X-Upgrade-URL,X-Applied-Sort-By,X-Applied-Sort-How,Cache-Control,Pragma,Expires",
    "Cache-Tag": "user,user_collection,movie,owner_id:837,resource:movie:65760,resource:movie:62544,resource:movie:993003,resource:movie:1044784,resource:movie:1040684,resource:movie:1074519,resource:movie:751145,resource:movie:903398,resource:movie:1169847,resource:movie:56580,resource:movie:1178309,resource:movie:1083999,resource:movie:991429,resource:movie:1033738,resource:movie:297,resource:movie:1052083,resource:movie:1077748,resource:movie:944042,resource:movie:897563,resource:movie:900786,resource:movie:540330",
    "Cf-Placement": "local-",
    "X-Content-Type-Options": "nosniff",
    "X-Download-Options": "noopen",
    "X-Frame-Options": "SAMEORIGIN",
    "X-Permitted-Cross-Domain-Policies": "none",
    "x-pagination-item-count": "21",
    "x-pagination-limit": "100",
    "x-pagination-page": "1",
    "x-pagination-page-count": "1",
    "Speculation-Rules": ""/cdn-cgi/speculation"",
    "CF-RAY": "a31aa993de0a8a71-SYD",
    "Content-Length": "9432",
    "Cache-Control": "private, no-cache, no-store, must-revalidate",
    "Content-Type": "application/json; charset=utf-8",
    "Date": "Thu, 27 Aug 2026 11:16:09 GMT",
    "Server": "cloudflare"
    }

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions