Scenario: - I'm using the Volley library to retrieve some data from the Business Central API in Kotlin, but there's a problem: the JSON response has about 20000 values or records, and the size of JSON is about 12MBs. This means that it takes an excessive amount of time and resources to retrieve and manipulate that much data.
Question: - Is there a way to restrict the number of items, values, rows, records, or whatever you want to call them? similar to most likely Business Central.
Explanation: There are roughly 20000 records like that, and I only want a certain number of them.
I probably don't need to mention the library I used to retrieve the data because I believe Business central will take care of it, but I'll mention it anyway in case.
"value": [
{
"id": "00000000-0000-0000-0000-000000000000",
"number": "",
"displayName": "",
"type": "",
"itemCategoryId": "00000000-0000-0000-0000-000000000000",
"itemCategoryCode": "",
"blocked": false,
"gtin": "",
"inventory": 0,
"unitPrice": 0,
"priceIncludesTax": false,
"unitCost": 0,
"taxGroupId": "00000000-0000-0000-0000-000000000000",
"taxGroupCode": "",
"baseUnitOfMeasureId": "",
"baseUnitOfMeasureCode": "",
"lastModifiedDateTime": ""
},
{},
{},
{},
{},
{},
{},
............. upto to so on.
This link may help you.
https://learn.microsoft.com/en-us/dynamics365/business-central/dev-itpro/webservices/server-driven-paging-in-odata-web-services#overriding-server-driven-paging