Skip to content
HALOWERK

Bürowerk

roster shift swap feasibility

Return pool-shift swap violations.

POST https://buero.halowerk.com/v1/roster-shift-swap-feasibility

Inputs

Fields of the published input schema
FieldTypeRequiredDescription
shiftsarrayYes
poolsarrayYes
swaparrayYes
rest_hnumberYes
Show full input schema
{
  "type": "object",
  "properties": {
    "shifts": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "$ref": "#/$defs/s0"
          },
          "team": {
            "type": "string",
            "pattern": "^pool_[A-Z0-9_]{1,24}$"
          },
          "start": {
            "type": "number",
            "minimum": 0,
            "maximum": 744
          },
          "end": {
            "type": "number",
            "minimum": 0,
            "maximum": 744
          },
          "skill": {
            "$ref": "#/$defs/s0"
          }
        },
        "required": [
          "id",
          "team",
          "start",
          "end",
          "skill"
        ],
        "additionalProperties": false
      },
      "maxItems": 50,
      "minItems": 2
    },
    "pools": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "team": {
            "type": "string",
            "pattern": "^pool_[A-Z0-9_]{1,24}$"
          },
          "skills": {
            "type": "array",
            "items": {
              "$ref": "#/$defs/s0"
            },
            "maxItems": 20,
            "minItems": 0
          }
        },
        "required": [
          "team",
          "skills"
        ],
        "additionalProperties": false
      },
      "maxItems": 50,
      "minItems": 1
    },
    "swap": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/s0"
      },
      "maxItems": 2,
      "minItems": 2
    },
    "rest_h": {
      "type": "number",
      "minimum": 0,
      "maximum": 168
    }
  },
  "required": [
    "shifts",
    "pools",
    "swap",
    "rest_h"
  ],
  "additionalProperties": false,
  "$id": "urn:h:w4:I7:input",
  "$defs": {
    "s0": {
      "type": "string",
      "maxLength": 32,
      "minLength": 1
    }
  }
}

Open original schema

Published input example

{
  "shifts": [
    {
      "id": "S1",
      "team": "pool_A",
      "start": 0,
      "end": 8,
      "skill": "D"
    },
    {
      "id": "S2",
      "team": "pool_B",
      "start": 8,
      "end": 16,
      "skill": "R"
    }
  ],
  "pools": [
    {
      "team": "pool_A",
      "skills": [
        "D"
      ]
    },
    {
      "team": "pool_B",
      "skills": [
        "R"
      ]
    }
  ],
  "swap": [
    "S1",
    "S2"
  ],
  "rest_h": 0
}

Result & documentation

Machine-readable documentation of this hub

Source of this page: the published HALOWERK catalog. Updated: 2026-11-18 UTC.

More endpoints in this hub

All endpoints in this hub →