When I Work Shifts API

Shifts provide the basis for scheduling. Many other objects, including Schedules (aka Locations), Positions, Sites, Users, Tasks, and Tags all link through Shifts. For more information about how to use Shifts, visit the [Help Center](https://help.wheniwork.com/article-categories/scheduling-your-team/).

GitHub OpenAPI
Business capability
Human Capital Management BC-300

Operations 17

Each operation below carries the questions people ask an LLM about it and the instructions they give an agent to run it. Generated by API Evangelist overlay

GET /2/shifts List shifts · List Shifts #
Ask an LLM
“Which shifts are scheduled for a given employee?”
“Can I include open shifts and unpublished shifts in a shift list?”
Tell an agent
List shifts for user {user_id} from {start} to {end}.
Show all shifts at location {location_id} including open shifts.
POST /2/shifts Create a shift · Create Shift #
Ask an LLM
“How do I add a new shift to the schedule?”
“Can I create several shifts in one request?”
Tell an agent
Create a new shift.
Add a batch of new shifts to the schedule.
DELETE /2/shifts Bulk delete shifts · Bulk Delete Shifts #
Ask an LLM
“How do I delete several shifts in one bulk call?”
“Can I delete shifts by user, position or date range?”
Tell an agent destructive · confirm first
Delete shifts {ids}.
Delete shifts assigned to {user_id}.
GET /2/shifts/{id} Get a shift · Get Shift #
Ask an LLM
“What are the details of one shift?”
“Can I see a shift's details including repeating shifts?”
Tell an agent
Get shift {id}.
Show shift {id} with repeating shifts up to {include_repeating_shifts_to}.
PUT /2/shifts/{id} Update a shift · Update Shift #
Ask an LLM
“How do I change the time or assignee of an existing shift?”
“Can I edit a single shift by its ID?”
Tell an agent
Update shift {id}.
Change the details of shift {id} and include repeating shifts to {include_repeating_shifts_to}.
DELETE /2/shifts/{id} Delete a shift · Delete Shift #
Ask an LLM
“How do I delete one shift that is no longer needed?”
“Can I notify the employee when a single shift is deleted?”
Tell an agent destructive · confirm first
Delete shift {id}.
Remove shift {id} and notify the assignee with {message}.
POST /2/shifts/unassign Release shifts to open · Unassign/Release Shifts #
Ask an LLM
“How do I turn assigned shifts back into OpenShifts?”
“Can employees release their own shifts when the setting is enabled?”
Tell an agent
Release shifts {shift_ids} back to OpenShifts.
Move the assigned shifts {shift_ids} to OpenShift status.
POST /2/shifts/{id}/assign Assign users to an OpenShift · Assign multiple users to an OpenShift #
Ask an LLM
“How do I assign several employees to an OpenShift?”
“Can I approve multiple users for an OpenShift that needs approval?”
Tell an agent
Assign users {user_ids} to OpenShift {id}.
Approve {user_ids} for OpenShift {id}.
GET /2/shifts/eligible List users eligible for an OpenShift · List eligible users for OpenShift #
Ask an LLM
“Which employees are eligible to take a given OpenShift?”
“Can I check OpenShift eligibility by position and location?”
Tell an agent
List eligible users for an OpenShift from {start} to {end} at location {location_id}.
Show who can take OpenShift {id} with position {position_id}.
GET /2/shifts/{id}/history View a shift's change history · Fetch shift history #
Ask an LLM
“Who changed a shift and why?”
“How far back does shift change history go?”
Tell an agent
Show the change history of shift {id}.
Show shift {id} history including deleted shifts.
POST /2/shifts/publish Publish a group of shifts · Publish Shifts #
Ask an LLM
“How do I publish a batch of shifts that are ready?”
“Can I notify users when I publish many shifts at once?”
Tell an agent
Publish these shifts {ids}.
Mark the shifts {ids} as published.
POST /2/shifts/unpublish Unpublish a group of shifts · Unpublish Shifts #
Ask an LLM
“How do I make some published shifts inactive again?”
“Can I unpublish a list of shifts by ID?”
Tell an agent
Unpublish these shifts {ids}.
Hide the shifts {ids} so they're no longer published.
POST /2/shifts/notify Notify employees of shifts · Notify shifts #
Ask an LLM
“How do I send notifications about a published schedule?”
“Can I notify only new or changed shifts since the last notification?”
Tell an agent
Notify employees of shifts from {start} to {end}.
Send shift notifications to users {user_ids} at location {location_id}.
POST /2/shifts/notify/{id} Notify employees of one shift · Notify single shift #
Ask an LLM
“How do I notify an employee about a single shift?”
“Can I send a custom message with a shift notification?”
Tell an agent
Notify about shift {id}.
Send a notification about shift {id} with message {message}.
PUT /2/shifts/bulk Update many shifts at once · Bulk Update Shifts #
Ask an LLM
“How do I change several shifts in one request?”
“Can I assign OpenShift instances to only one instance of a multi-instance OpenShift?”
Tell an agent
Bulk update these shifts.
Update many shifts and assign OpenShift instances one at a time.
GET /2/shifts/{id}/swapusers List users who can take a dropped shift · List swap users #
Ask an LLM
“Which employees can cover a shift that was dropped?”
“Can I get only the IDs of people eligible to take a dropped shift?”
Tell an agent
List users eligible to take dropped shift {id}.
Show only the IDs of people who can cover shift {id}.
GET /v3/auto-assign Auto-schedule OpenShifts · List Auto Scheduled shifts #
Ask an LLM
“How do I auto-schedule OpenShifts for a team?”
“Can the auto-scheduler avoid employees' unavailability?”
Tell an agent
Auto-schedule OpenShifts {ids} at location {location} from {start} to {end}.
Auto-schedule OpenShifts {ids} at location {location} with a maximum of {autoScheduleMaxHours} hours per week.

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/when-i-work:when-i-work-shifts-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

when-i-work-shifts-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  version: 1.0.0
  title: When I Work API Documentation Shifts API
  description: The When I Work API is thorough, flexible, and restful.
servers:
- url: https://api.wheniwork.com
  description: Production
security:
- W-Token: []
tags:


# --- truncated at 32 KB (65 KB total) ---
# Full source: https://artifacts.apis.io/when-i-work/openapi/when-i-work-shifts-api-openapi.yml