testrail icon indicating copy to clipboard operation
testrail copied to clipboard

Handling pagination in TestRail API

Open ohenak opened this issue 3 years ago • 0 comments

The pagination functionality is now in TestRail production API.

For instance, get_plan API used to return in older TestRail:

{
  "plans": [
    {
      "id": 505717,
      ...

Now in TestRail production (on cloud),

{
  "offset": 0,
  "limit": 250,
  "size": 250,
  "_links": {
    "next": "/api/v2/get_plans/4&limit=250&offset=250",
    "prev": null
  },
  "plans": [
    {
      "id": 505717,
      ...

How do you prefer to handle this change? We could introduce a class of ReceivableTestPlans that is similar to SendableTestPlans that the library already has.

ohenak avatar May 11 '23 19:05 ohenak