Hi there,
My first implementation of Keypay and I’m a bit stuck. I’m trying to do a bulk timesheet but getting a 400 “request.timesheets.xxxxxxx.employeeId”: [ “An error has occurred.” ] with the end message “request.Timesheets”: [ “‘Timesheets’ should not be empty.” ]
Here’s the json I’m sending via cURL (with the appropriate content-type), any guidance would be much appreciated…
{
"fromDate":"2019-03-18T00:00:00",
"toDate":"2019-03-31T23:59:59",
"approved":"false",
"employeeIdType":"standard",
"locationIdType":"standard",
"replaceExisting":"false",
"workTypeIdType":"standard",
"timesheets":{
"1379566":{
"employeeId":"1379566",
"startTime":"2019-03-23T16:30:00",
"endTime":"2019-03-23T00:00:00",
"locationId":"340461",
"units":7.5,
"attachmentId":null,
"classification":null,
"classificationId":null,
"comments":null,
"externalId":null,
"rate":null,
"workTypeId":null,
"payCategoryId":null,
"leaveCategoryId":null
},
"1379397":{
"employeeId":"1379397",
"startTime":"2019-03-23T14:30:00",
"endTime":"2019-03-24T00:30:00",
"locationId":"340461",
"units":10,
"attachmentId":null,
"classification":null,
"classificationId":null,
"comments":null,
"externalId":null,
"rate":null,
"workTypeId":null,
"payCategoryId":null,
"leaveCategoryId":null
},
"1379368":{
"employeeId":"1379368",
"startTime":"2019-03-23T18:15:00",
"endTime":"2019-03-23T00:00:00",
"locationId":"340461",
"units":5.75,
"attachmentId":null,
"classification":null,
"classificationId":null,
"comments":null,
"externalId":null,
"rate":null,
"workTypeId":null,
"payCategoryId":null,
"leaveCategoryId":null
},
"1730255":{
"employeeId":"1730255",
"startTime":"2019-03-23T17:00:00",
"endTime":"2019-03-23T00:00:00",
"locationId":"340461",
"units":7,
"attachmentId":null,
"classification":null,
"classificationId":null,
"comments":null,
"externalId":null,
"rate":null,
"workTypeId":null,
"payCategoryId":null,
"leaveCategoryId":null
},
"1379352":{
"employeeId":"1379352",
"startTime":"2019-03-23T16:45:00",
"endTime":"2019-03-23T00:00:00",
"locationId":"340461",
"units":7.25,
"attachmentId":null,
"classification":null,
"classificationId":null,
"comments":null,
"externalId":null,
"rate":null,
"workTypeId":null,
"payCategoryId":null,
"leaveCategoryId":null
},
"1379591":{
"employeeId":"1379591",
"startTime":"2019-03-23T16:00:00",
"endTime":"2019-03-23T00:00:00",
"locationId":"340461",
"units":8,
"attachmentId":null,
"classification":null,
"classificationId":null,
"comments":null,
"externalId":null,
"rate":null,
"workTypeId":null,
"payCategoryId":null,
"leaveCategoryId":null
},
"1379576":{
"employeeId":"1379576",
"startTime":"2019-03-23T14:00:00",
"endTime":"2019-03-23T00:00:00",
"locationId":"340461",
"units":10,
"attachmentId":null,
"classification":null,
"classificationId":null,
"comments":null,
"externalId":null,
"rate":null,
"workTypeId":null,
"payCategoryId":null,
"leaveCategoryId":null
},
"1379593":{
"employeeId":"1379593",
"startTime":"2019-03-23T13:00:00",
"endTime":"2019-03-23T00:00:00",
"locationId":"340461",
"units":11,
"attachmentId":null,
"classification":null,
"classificationId":null,
"comments":null,
"externalId":null,
"rate":null,
"workTypeId":null,
"payCategoryId":null,
"leaveCategoryId":null
},
"1379383":{
"employeeId":"1379383",
"startTime":"2019-03-23T17:00:00",
"endTime":"2019-03-23T00:00:00",
"locationId":"340461",
"units":7,
"attachmentId":null,
"classification":null,
"classificationId":null,
"comments":null,
"externalId":null,
"rate":null,
"workTypeId":null,
"payCategoryId":null,
"leaveCategoryId":null
},
"1379602":{
"employeeId":"1379602",
"startTime":"2019-03-23T16:30:00",
"endTime":"2019-03-23T00:00:00",
"locationId":"340461",
"units":7.5,
"attachmentId":null,
"classification":null,
"classificationId":null,
"comments":null,
"externalId":null,
"rate":null,
"workTypeId":null,
"payCategoryId":null,
"leaveCategoryId":null
},
"1379595":{
"employeeId":"1379595",
"startTime":"2019-03-23T17:00:00",
"endTime":"2019-03-23T00:00:00",
"locationId":"340461",
"units":7,
"attachmentId":null,
"classification":null,
"classificationId":null,
"comments":null,
"externalId":null,
"rate":null,
"workTypeId":null,
"payCategoryId":null,
"leaveCategoryId":null
},
"1379418":{
"employeeId":"1379418",
"startTime":"2019-03-23T19:15:00",
"endTime":"2019-03-23T00:00:00",
"locationId":"340461",
"units":4.75,
"attachmentId":null,
"classification":null,
"classificationId":null,
"comments":null,
"externalId":null,
"rate":null,
"workTypeId":null,
"payCategoryId":null,
"leaveCategoryId":null
}
}
}