Метод document:getSections
Возвращает таблицу объектов типа DocumentAPI.Sections.
Пример
local sections = document:getSections()
for section in sections:enumerate() do
local properties = section:getPageProperties()
print(properties.width)
print(properties.height)
end