xanzy / go-gitlab

GitLab Go SDK
Apache License 2.0
2.36k stars 935 forks source link

feat(pagination): include id_after for all endpoints #1881

Closed kilianpaquier closed 6 months ago

kilianpaquier commented 6 months ago

Purpose

While using the library, I noticed that only projects endpoint was taking advantage of id_after query parameter on keyset based paginations.

While other endpoints like jobs can also use keyset based paginations, I thought "why not having id_after in global ListOptions struct with the rest of pagination query parameters ?"

As such, here's a minimal PR moving this query parameter, allowing all endpoints (in the limitation of developers using this library be aware that not all endpoints support keyset based pagination) to take advantage of id_after query parameter.