Documentation

Specifics of the List and Batch methods

REST provides several methods that return lists of elements. Such lists contain data on deals, users and task comments. Because the number of elements, returned by REST-methods, depends on the specific conditions and parameters, Bitrix24 returns elements via "batches" of several elements (presently, not more than 50 elements in a batch).

Example:

https://my.bitrix24.com/rest/methods.xml?auth=d161f25928c3184678924ec127edd29a

//gets a list of available methods in XML format.

https://my.bitrix24.com/rest/entity.item.get.json?ENTITY=menu&auth=d161f25928c3184678924ec127edd29a
//gets a list of all elements in JSON format for 'menu' entity.

When calling a REST list method, it returns additional values in a response:

To get the next batch of elements, it is necessary to make the same request and specify an additional parameter - 'start' - with the value, received in 'next' parameter of the response.

Example:

{
	"result":result of executed method,
	"error":error of method execution,
	"total":general number of records in the list method response,
	"next":value, which should be sent to receive the next page of list method data
}

Exception from this - is the batch method for batch request execution. It returns the following response:

{
	"result":array of batch request results,
	"result_error":array of batch request errors,
	"result_total":array of number of records in the list methods responses,
	"result_next":array of values, returned in fields of 'next' requests
}
© «Bitrix24», 2001-2024
Up