My Products
Help
adrianm
PARTNER

Paging in SalesOrderApi

by adrianm (Updated ‎12-01-2023 11:54 by adrianm PARTNER )

How does the paging work in SalesOrderApi?

I have request for 928 items. With a page size of 500 I expect

Page 0: 500

Page 1: 428

Page 2: 0

 

But I get

Page 0: 500

Page 1: 500

Page 2: 500

 

 

Page 0

GET: https://salesorder.visma.net/api/v3/Inventory?modifiedSince=2023-01-11T10:59:18%2B01:00&pageSize=500...

 

 

{
    "value": [<500 records>],
    "nextPage":"https://salesorder.visma.net/api/v3/Inventory?modifiedSince=2023-01-11T10%3a59%3a18%2b01%3a00&pageSize=500&pageIndex=1",
    "totalCount":928
}

 

Page 1

GET: https://salesorder.visma.net/api/v3/Inventory?modifiedSince=2023-01-11T10:59:22%2B01:00&pageSize=500...

 

{
    "value": [<500 records>],
    "totalCount":928
}

 

Page 2

GET: https://salesorder.visma.net/api/v3/Inventory?modifiedSince=2023-01-11T10:59:23%2B01:00&pageSize=500...

 

{
    "value": [<500 records>],
    "totalCount":928
}

 

 

I didn't investigate closer what items are returned but it looks like it is

Page 0: item 1-500

Page 1: item 2-501

Page 2: item 3-502

 

So it looks like pageIndex works like skip

1 REPLY 1
Yıldırım
VISMA

by Yıldırım

Hello, this has been reported as an error, and it is currently under review by the team.