GetLaborSchedule
Retrieve a LaborSchedule object for the location.
Request Parameters
- StartDate
DateTime— Specify the start date of the range you would like to see the Labor Schedule from. - EndDate
DateTime— Specify the end date of the range you would like to see the Labor Schedule to.
Response Parameters
-
Message
string— Returns a PAR POS Error message if the request did not go through. Otherwise, this field will be null. -
ResultCode
int— Returns one of the following:- 0 — Success
- 1 — Unknown Error
- 2 — Invalid Request
- 3 — Server Unavailable
- 4 — Access Denied
-
LaborSchedule
LaborSchedule— Labor schedule for this business dateLaborSchedule Properties
-
Days
Array of LaborScheduleDay— Labor schedule for a date rangeLaborScheduleDay Properties
-
BusinessDate
DateTime— Business date for this LaborScheduleDay (the time component will always return as 00:00:00) -
Shifts
Array of ScheduledShift— Scheduled shifts for this LaborScheduleDayScheduledShift Properties
- EmployeeId
int— Maps to the Id of the Employee for this ScheduledShift - EndTime
TimeSpan— End time of this ScheduledShift - JobId
int— Maps to the Id of the Job for this ScheduledShift - StartTime
TimeSpan— Start time of this ScheduledShift
- EmployeeId
-
-
Headers
- Type: stringS
O A P Action required
Body
required
application/json
SOAP envelope containing the GetLaborSchedule request with StartDate and EndDate.
Responses
- text/xml; charset=utf-8
Request Example for post/GetLaborSchedule
cURL
curl --request POST \
--url 'https://{server_name_goes_here}.parpos.com/Labor2.svc?GetLaborSchedule' \
--header 'Content-Type: text/xml; charset=utf-8' \
--header 'AccessToken: your-access-token' \
--header 'LocationToken: your-location-token' \
--header 'SOAPAction: "http://www.brinksoftware.com/webservices/labor/v2/ILaborWebService2/GetLaborSchedule"' \
--data '<soapenv:Envelope
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:v2="http://www.brinksoftware.com/webservices/labor/v2">
<soapenv:Header/>
<soapenv:Body>
<v2:GetLaborSchedule>
<v2:request>
<v2:EndDate>2024-01-21</v2:EndDate>
<v2:StartDate>2024-01-15</v2:StartDate>
</v2:request>
</v2:GetLaborSchedule>
</soapenv:Body>
</soapenv:Envelope>'
<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/">
<s:Body>
<GetLaborScheduleResponse xmlns="http://www.brinksoftware.com/webservices/labor/v2">
<GetLaborScheduleResult>
<Message>Success</Message>
<ResultCode>0</ResultCode>
<LaborSchedule>
<Days>
<LaborScheduleDay>
<BusinessDate>2024-01-15T00:00:00</BusinessDate>
<Shifts>
<ScheduledShift>
<EmployeeId>123</EmployeeId>
<JobId>456</JobId>
<StartTime>PT9H</StartTime>
<EndTime>PT17H</EndTime>
</ScheduledShift>
</Shifts>
</LaborScheduleDay>
</Days>
</LaborSchedule>
</GetLaborScheduleResult>
</GetLaborScheduleResponse>
</s:Body>
</s:Envelope>