Data from mapping for parameter "Test" did not pass validation

Hi, I’m trying to learn how to get data from RESTful endpoint using the Bussiness connector and Web services module. So the endpoint used is and I have also created a chart in the Bussiness connector. In windows, I have created a button component and written a script so that the chart executes and data from the endpoint is displayed on the table.
The Problem faced is, while running the button “Data from mapping for parameter “Test” did not pass validation” error is found. Please help me to solve this.
Here is my Script:

chartPath = ‘Personnel-RESTful’
numPerPage = event.source.parent.getComponent(‘Records_Per_Page’).data
inputChartParams = numPerPage
complex_param = system.mes.bc.executeChartSynchronous(chartPath,inputChartParams,‘Test’)
mat = complex_param[‘Test’][‘TestRoot’]
if len(mat) > 0:
records = mat[‘MyPeople’]
header = records[0].keys()
rows = []
for i in records:
header = [‘NO RECORDS’]
rows =[]

DataToTable = system.dataset.toDataSet(header,rows)
event.source.parent.getComponent(‘Table’).data = DataToTable