Skip to content

Get Shift Categories

Operation
wsdlGetShiftCategories
SOAP Action
uri:FlexForce/wsdlGetShiftCategories
Service
FlexForce
Port
FlexForcePort
Style
rpc

Return all shift categories (shift types) for the unit identified by the API key.


Request

Message: wsdlGetShiftCategoriesRequest

apiKeystring

API key of the unit.

lastModifiedstring

Pass an empty string ("") to ignore this filter, or a date to return only categories modified after that date. **Must** be set when includeTags is true.

FormatYYYY-MM-DD hh:mm:ss
includeTagsboolean

When true, include the tags connected to the shift type.

includeSkillsboolean

When true, include the skills connected to the shift type.

curl -X POST 'https://api.quinyx.com/FlexForceWebServices.php' \
  -H 'Content-Type: text/xml; charset=utf-8' \
  -H 'SOAPAction: "uri:FlexForce/wsdlGetShiftCategories"' \
  --data @- <<'EOF'
<?xml version="1.0" encoding="UTF-8"?>
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:tns="https://api.quinyx.com/soap/FlexForce">
  <soap:Body>
    <tns:wsdlGetShiftCategories>
    <apiKey xsi:type="xsd:string">string</apiKey>
    <lastModified xsi:type="xsd:string">string</lastModified>
    <includeTags xsi:type="xsd:boolean">true</includeTags>
    <includeSkills xsi:type="xsd:boolean">true</includeSkills>
    </tns:wsdlGetShiftCategories>
  </soap:Body>
</soap:Envelope>
EOF

Response

Message: wsdlGetShiftCategoriesResponse

returnArray<ShiftCategory>

Array of ShiftCategory records.

itemShiftCategory

A shift category (shift type) configured on a unit.

idintrequired

Primary key.

shiftTypeExtIdstring

External id of the shift type, when set.

namestringrequired

Display name of the shift category.

restIdintrequired

Unit (restaurant) id the category belongs to.

begTimetimerequired

Default start time. Range 00:00:0023:59:59.

Formathh:mm:ss
endTimetimerequired

Default end time.

Formathh:mm:ss
breakTypeintrequired

0 hides breaks on the scheduling screen; 1 shows them.

begBreaktimerequired

First break start.

Formathh:mm:ss
endBreaktimerequired

First break end.

Formathh:mm:ss
begBreak2timerequired

Second break start.

Formathh:mm:ss
endBreak2timerequired

Second break end.

Formathh:mm:ss
begBreak3timerequired

Third break start.

Formathh:mm:ss
endBreak3timerequired

Third break end.

Formathh:mm:ss
begBreak4timerequired

Fourth break start.

Formathh:mm:ss
endBreak4timerequired

Fourth break end.

Formathh:mm:ss
sectionintrequired

Section id. Returns 1 when no section is assigned.

costCentreintrequired

Cost centre id.

salaryTypeintrequired

Salary type id.

accountNointrequired

Account id.

projectNointrequired

Project id.

accountNoExtCodestringrequired

External id of the account. Empty string when not set.

costCentreExtCodestringrequired

External id of the cost centre. Empty string when not set.

projectNoExtCodestringrequired

External id of the project. Empty string when not set.

salaryTypeExtCodestringrequired

External id of the salary type. Empty string when not set.

onCallintrequired
Values
0false
1true
isActivebooleanrequired

Whether the shift category is active.

isFreeDaybooleanrequired

Whether the shift category represents a free day.

countPunchHoursbooleanrequired

Whether punched hours count towards this shift category.

countScheduleHoursbooleanrequired

Whether scheduled hours count towards this shift category.

sharedToAllUnitsbooleanrequired

Whether the shift type is shared to all units. Can only be set via wsdlUpdateShiftTypes on create/update; categories created in the GUI default to true.

scheduleCategoryUnitsArray<scheduleCategoryUnit>

Per-unit visibility list. Can only be set via wsdlUpdateShiftTypes.

tsdateTimerequired

Timestamp of the last update, ISO 8601.

shiftTypeCategoryNamestring

Display name of the shift type category, when set.

tagsArray<PayrollTag>

Tags connected to the shift type (when includeTags = true).

skillsArray<ScheduleCategorySkill>

Skills connected to the shift type (when includeSkills = true).

<?xml version="1.0" encoding="UTF-8"?>
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:tns="https://api.quinyx.com/soap/FlexForce">
  <soap:Body>
    <tns:wsdlGetShiftCategoriesResponse>
    <return xsi:type="SOAP-ENC:Array" SOAP-ENC:arrayType="tns:ShiftCategory[1]">
      <item xsi:type="tns:ShiftCategory">
        <id xsi:type="xsd:int">0</id>
        <shiftTypeExtId xsi:type="xsd:string">string</shiftTypeExtId>
        <name xsi:type="xsd:string">string</name>
        <restId xsi:type="xsd:int">0</restId>
        <begTime xsi:type="xsd:time">00:00:00</begTime>
        <endTime xsi:type="xsd:time">00:00:00</endTime>
        <breakType xsi:type="xsd:int">0</breakType>
        <begBreak xsi:type="xsd:time">00:00:00</begBreak>
        <endBreak xsi:type="xsd:time">00:00:00</endBreak>
        <begBreak2 xsi:type="xsd:time">00:00:00</begBreak2>
        <endBreak2 xsi:type="xsd:time">00:00:00</endBreak2>
        <begBreak3 xsi:type="xsd:time">00:00:00</begBreak3>
        <endBreak3 xsi:type="xsd:time">00:00:00</endBreak3>
        <begBreak4 xsi:type="xsd:time">00:00:00</begBreak4>
        <endBreak4 xsi:type="xsd:time">00:00:00</endBreak4>
        <section xsi:type="xsd:int">0</section>
        <costCentre xsi:type="xsd:int">0</costCentre>
        <salaryType xsi:type="xsd:int">0</salaryType>
        <accountNo xsi:type="xsd:int">0</accountNo>
        <projectNo xsi:type="xsd:int">0</projectNo>
        <accountNoExtCode xsi:type="xsd:string">string</accountNoExtCode>
        <costCentreExtCode xsi:type="xsd:string">string</costCentreExtCode>
        <projectNoExtCode xsi:type="xsd:string">string</projectNoExtCode>
        <salaryTypeExtCode xsi:type="xsd:string">string</salaryTypeExtCode>
        <onCall xsi:type="xsd:int">0</onCall>
        <isActive xsi:type="xsd:boolean">true</isActive>
        <isFreeDay xsi:type="xsd:boolean">true</isFreeDay>
        <countPunchHours xsi:type="xsd:boolean">true</countPunchHours>
        <countScheduleHours xsi:type="xsd:boolean">true</countScheduleHours>
        <sharedToAllUnits xsi:type="xsd:boolean">true</sharedToAllUnits>
        <scheduleCategoryUnits xsi:type="SOAP-ENC:Array" SOAP-ENC:arrayType="tns:scheduleCategoryUnit[1]">
          <item xsi:type="tns:scheduleCategoryUnit">
            <externalUnitId xsi:type="xsd:string">string</externalUnitId>
            <unitId xsi:type="xsd:int">0</unitId>
            <visibleInWebpunch xsi:type="xsd:boolean">true</visibleInWebpunch>
          </item>
        </scheduleCategoryUnits>
        <ts xsi:type="xsd:dateTime">2024-01-01T00:00:00Z</ts>
        <shiftTypeCategoryName xsi:type="xsd:string">string</shiftTypeCategoryName>
        <tags xsi:type="SOAP-ENC:Array" SOAP-ENC:arrayType="tns:PayrollTag[1]">
          <item xsi:type="tns:PayrollTag">
            <tagCategoryName xsi:type="xsd:string">string</tagCategoryName>
            <tagCategoryExternalId xsi:type="xsd:string">string</tagCategoryExternalId>
            <tagName xsi:type="xsd:string">string</tagName>
            <tagCode xsi:type="xsd:string">string</tagCode>
            <tagExternalId xsi:type="xsd:string">string</tagExternalId>
            <customFields xsi:type="SOAP-ENC:Array" SOAP-ENC:arrayType="tns:TagCustomField[1]">
              <item xsi:type="tns:TagCustomField">
                <label xsi:type="xsd:string">string</label>
                <value xsi:type="xsd:string">string</value>
              </item>
            </customFields>
          </item>
        </tags>
        <skills xsi:type="SOAP-ENC:Array" SOAP-ENC:arrayType="tns:ScheduleCategorySkill[1]">
          <item xsi:type="tns:ScheduleCategorySkill">
            <scatName xsi:type="xsd:string">string</scatName>
            <skillDescription xsi:type="xsd:string">string</skillDescription>
          </item>
        </skills>
      </item>
    </return>
    </tns:wsdlGetShiftCategoriesResponse>
  </soap:Body>
</soap:Envelope>

Change log

Date Description
2019-12-02 Added includeTags
2020-02-14 Added includeSkills
2020-07-29 Added isFreeDay, countPunchHours, countScheduleHours