Function: getModelData()
getModelData(
page,path,options?):Promise<unknown>
Ai
Retrieves data from a UI5 OData model at the given path.
Parameters
page
ODataPage
Playwright Page (or compatible subset).
path
string
OData model path (must start with '/').
options?
OData options (timeout, modelName).
Returns
Promise<unknown>
The data at the given path (array, object, or primitive).
Capability
ui5.odata.getModelData
Intent
Read data from the UI5 OData model at a specific binding path.
Guarantee
On success, returns the data at the path (array, object, or primitive) from the model.
Ai Context
Accesses the component's OData model via getData() or getProperty(). Path must start with '/'. Use modelName option for named models.
Sap Module
sap.ui.model.odata.v2.ODataModel, sap.ui.model.odata.v4.ODataModel
Business Context
Read OData entity data from the UI5 model layer for data-level assertions.
Throws
ODataError if path is invalid or model/data not found.
Example
const products = await getModelData(page, '/Products');
const single = await getModelData(page, '/Products(1)', { modelName: 'catalog' });