Developer Help Documentation — Complete RESTful HTTPS programmatic integration and JSON data interchange reference.
The WorkSchedule.Net API enables programmatic functionality and the interchange of data with third-party software applications.
To get started, you need the following:
Once these prerequisites are in place, you can start making HTTPS calls using the specifications below.
| Specification | Value |
|---|---|
| Base URL (Endpoint) | https://api.workschedule.app/ |
| Supported Formats | JSON (input and output) |
| Supported Methods | REST-standard HTTP methods: GET, POST, PUT, DELETE |
| Required Version Header | X-Api-Version: 1.1 (required in HTTP headers for the latest API version) |
To access the API methods, you must first obtain a session API key and password. Call the StartAPISession method by appending StartAPISession to the base URL (https://api.workschedule.app/) followed by a ? and the following query string parameters separated by &:
CompanyID= Your WorkSchedule.Net CompanyIDUserName= The username of the API-designated user accountPasscode= The password of the API-designated user account (URL-encoded){
"SessionError": "0",
"SessionInformation": {
"SessionID": 11093,
"SessionPassword": "2109769271"
}
}
Include the returned SessionID and SessionPassword (abbreviated as SP) in the query parameters for every subsequent HTTP API request:
Standard HTTP request headers are passed as key-value pairs to specify API versioning, target calendar routing, and unique entity lookup keys.
X-Api-Version: 1.1 in your HTTP request headers.
| Header Key | Example Value | Required | Description |
|---|---|---|---|
X-Api-Version |
1.1 |
Yes (v1.1) | Specifies the API version. Must be set to 1.1 to access the latest version. |
Lookup-Key |
TimeBlockID |
Conditional | Identifies the entity property used as the unique lookup key on single-entity requests. |
Calendar-Key |
CalendarName |
Conditional | Specifies whether Timeblock endpoints use CalendarName or CalendarID. |
All API calls begin with the base endpoint URL: https://api.workschedule.app/
Append the target entity name directly after the base URL: https://api.workschedule.app/User
Append any entity lookup value(s) after the entity: https://api.workschedule.app/User/1
Use a ? after the base URL, entity, and entity parameters to designate the authentication query string. Pass the SessionID and SessionPassword received from StartAPISession using SessionID= and SP=, separated by &.
# as %23).*) next to a property or parameter indicates that it is required.Select an entity below to jump directly to its endpoint methods, parameters, and sample payloads:
Retrieve, add, modify, and delete user accounts within a WorkSchedule.Net company account.
The User entity methods provide programmatic access to retrieving, adding, modifying, and deleting user accounts within the company account.
| Header Key | Allowed / Expected Value | Default / Behavior |
|---|---|---|
X-Api-Version |
1.1 |
Required in HTTP headers to target the latest API version (v1.1). |
Lookup-Key |
ExternalID or UserID |
Applies to GET, PUT, and DELETE when accessing a single user. If omitted or unrecognized, defaults to ExternalID. |
| URL Segment | Required | Description |
|---|---|---|
UserID or ExternalID |
Conditional (Required for PUT & DELETE) |
The lookup value matching the property chosen in the Lookup-Key header. If excluded on GET, all users in the company account are retrieved. |
{
"ErrorCode": 0,
"ErrorMessage": "Success",
"ItemResponses": "[]",
"Items": [
{
"EMail": "bob.smith@programworks.com",
"ExternalID": "",
"FirstName": "Bob",
"LastName": "Smith",
"WorkPhone": "",
"UserID": "1",
"UserName": "bsmith",
"UserNotes": "",
"RoleInfo": {
"RoleID": 4,
"RoleDescription": "Administrator"
}
},
{
"ExternalID": "",
"FirstName": "Sally",
"LastName": "MacKay",
"WorkPhone": "4075551234",
"UserID": "2",
"UserName": "SallyMacKay",
"UserNotes": "",
"RoleInfo": {
"RoleID": 1,
"RoleDescription": "Employee"
}
},
{
"EMail": "mary.carney@programworks.com",
"ExternalID": "",
"FirstName": "API",
"LastName": "User",
"WorkPhone": "",
"UserID": "6",
"UserName": "APIUser",
"UserNotes": "",
"RoleInfo": {
"RoleID": 4,
"RoleDescription": "API Role"
}
}
]
}
{
"ErrorCode": 0,
"ErrorMessage": "Success",
"ItemResponses": "[]",
"Items": {
"ExternalID": "32",
"FirstName": "Bob",
"LastName": "Smith",
"WorkPhone": "",
"UserID": "5",
"UserNotes": "",
"RoleInfo": {
"RoleID": 1,
"RoleDescription": "Employee"
}
}
}
| Parameter | Required | Notes / Validation Rules |
|---|---|---|
UserName* | Yes | Must be unique, greater than 6 characters, and alphanumeric. |
FirstName* | Yes | User's first name. |
LastName* | Yes | User's last name. |
Email* | Yes | User's email address. |
RoleID* | Yes | Internal ID of the security role assigned to the user. |
MainDepartment* | Yes | Category Item ID of the user's primary department. |
HomePhone | No | User's home phone number. |
WorkPhone | No | User's work phone number. |
MobilePhone | No | User's mobile phone number. |
{
"UserName": "RyanS",
"FirstName": "Ryan",
"LastName": "Swift",
"Email": "ryan.swift@programworks.com",
"RoleID": "1",
"MainDepartment": "1",
"HomePhone": "3055555928"
}
{
"ErrorCode": 0,
"ErrorMessage": "Success",
"ItemResponses": null,
"Items": "[]"
}
| Parameter | Required | Notes / Validation Rules |
|---|---|---|
UserName | No | Must be unique, greater than 6 characters, and alphanumeric. |
FirstName | No | Updated first name. |
LastName | No | Updated last name. |
Email | No | Updated email address. |
RoleID | No | Updated security RoleID. |
MainDepartment | No | Updated primary department Category Item ID. |
HomePhone | No | Updated home phone number. |
WorkPhone | No | Updated work phone number. |
MobilePhone | No | Updated mobile phone number. |
{
"HomePhone": "9545555928"
}
{
"ErrorCode": 0,
"ErrorMessage": "Success",
"ItemResponses": null,
"Items": "[]"
}
{
"ErrorCode": 0,
"ErrorMessage": "Success",
"ItemResponses": null,
"Items": "[]"
}
Retrieve, add, modify, and delete shifts and time-off blocks across Schedule and Attendance calendars.
The Timeblock entity methods give access to retrieving, adding, modifying, and deleting time blocks (shifts and time-off blocks) within the company account in both the Schedule and Attendance areas. Access to templates is not currently supported.
| Header Key | Allowed / Expected Value | Default / Behavior |
|---|---|---|
X-Api-Version |
1.1 |
Required in HTTP headers to target the latest API version (v1.1). |
Lookup-Key |
ExternalID or TimeBlockID |
Applies to GET, PUT, and DELETE when accessing a single entity. If omitted or unrecognized, defaults to ExternalID. |
Calendar-Key |
CalendarID or CalendarName |
Specifies how the target calendar (Schedule vs. Attendance) is referenced in the URL. If omitted or unrecognized, defaults to CalendarName. |
| URL Segment | Required | Description |
|---|---|---|
CalendarName or CalendarID* |
Yes (All verbs) | Target calendar area. If using CalendarName, pass "Schedule" or "Attendance". If using CalendarID, pass 1 (Schedule) or 7 (Attendance). |
TimeBlockID or ExternalID |
Conditional (Required for PUT & DELETE) |
Lookup value matching the property chosen in Lookup-Key. If excluded on GET, all time blocks for the calendar within the StartTime/EndTime range in the HTTPS body are retrieved. |
| JSON Body Parameter | Required | Description |
|---|---|---|
StartTime* |
Yes (when no lookup ID is specified) | Start of the query date/time range in ISO-8601 format. |
EndTime* |
Yes (when no lookup ID is specified) | End of the query date/time range in ISO-8601 format. |
{
"ErrorCode": 0,
"ErrorMessage": "Success",
"ItemResponses": "[]",
"Items": [
{
"Color": "FFCC99",
"UserID": "1",
"EndTime": "2023-12-27T17:01:00.0000000",
"Notes": "",
"TimeBlockID": "49168",
"StartTime": "2023-12-27T09:00:00.0000000",
"CategoryItems": [
{
"Color": "",
"Name": "Main",
"CatNo": "1",
"CatItemID": "1",
"CategoryName": "Location"
}
],
"EmployeeName": "Mya Collins",
"TimeOnOff": "On"
},
{
"Color": "FFCC99",
"EndTime": "2023-12-27T17:00:00.0000000",
"Notes": "",
"TimeBlockID": "49175",
"StartTime": "2023-12-27T09:00:00.0000000",
"CategoryItems": [
{
"Color": "E0E0E0",
"Name": "Main",
"CatNo": "1",
"CatItemID": "1",
"CategoryName": "Location"
}
],
"EmployeeName": "OPEN",
"TimeOnOff": "On"
},
{
"UserID": "1",
"EndTime": "2023-12-28T17:00:00.0000000",
"Notes": "",
"TimeBlockID": "49176",
"StartTime": "2023-12-28T09:00:00.0000000",
"CategoryItems": [
{
"Color": "",
"Name": "Main",
"CatNo": "1",
"CatItemID": "1",
"CategoryName": "Location"
}
],
"EmployeeName": "Mya Collins",
"TimeOnOff": "On"
}
]
}
{
"ErrorCode": 0,
"ErrorMessage": "Success",
"ItemResponses": "[]",
"Items": [
{
"UserID": "1",
"EndTime": "2023-12-28T17:00:00.0000000",
"Notes": "",
"TimeBlockID": "49176",
"StartTime": "2023-12-28T09:00:00.0000000",
"CategoryItems": [
{
"Color": "",
"Name": "Main",
"CatNo": "1",
"CatItemID": "1",
"CategoryName": "Location"
}
],
"EmployeeName": "Mya Collins",
"TimeOnOff": "On"
}
]
}
| Parameter | Required | Notes / Applicability |
|---|---|---|
UserID* | Yes | Assigned user's internal ID. A UserID of "0" indicates an open time block. |
ExternalID | No | Optional external system identifier. |
StartTime* | Yes | Start date and time in ISO-8601 format. |
EndTime* | Yes | End date and time in ISO-8601 format. |
Notes | No | Optional text notes attached to the time block. |
Color | No | 6-character hex color code. |
CategoryItems | No | JSON object mapping each Category name (key) to its Category Item ID (value), e.g., {"Location": "1", "Area": "11"}. |
{
"UserID": "0",
"EndTime": "2023-12-28T22:32:00.0000000",
"StartTime": "2023-12-28T22:32:00.0000000",
"CategoryItems": {
"Location": "1",
"Area": "11"
}
}
{
"ErrorCode": 0,
"ErrorMessage": "Success",
"ItemResponses": null,
"Items": []
}
| Parameter | Required | Notes / Applicability |
|---|---|---|
UserID | No | Assigned user's internal ID. A UserID of "0" indicates an open time block. |
ExternalID | No | Updated external system identifier. |
StartTime | No | Updated start date and time in ISO-8601 format. |
EndTime | No | Updated end date and time in ISO-8601 format. |
StartDayNo | No | Optional start day offset number. |
Notes | No | Updated text notes. |
Color | No | Updated 6-character hex color code. |
CategoryItems | No | JSON object mapping each Category name (key) to its Category Item ID (value). |
{
"UserID": "3",
"Notes": "Updated Notes"
}
{
"ErrorCode": 0,
"ErrorMessage": "Success",
"ItemResponses": null,
"Items": []
}
{
"ErrorCode": 0,
"ErrorMessage": "Success",
"ItemResponses": null,
"Items": []
}
Retrieve, add, modify, and delete category items within a WorkSchedule.Net company account.
The Category Item entity methods provide programmatic access to retrieving, adding, modifying, and deleting category items of a specified category (such as “Departments”, “Locations”, “Areas”, “Tasks”, “Times of Day”, and other user-defined categories) within the company account.
| Header Key | Allowed / Expected Value | Default / Behavior |
|---|---|---|
X-Api-Version |
1.1 |
Required in HTTP headers to target the latest API version (v1.1). |
Lookup-Key |
ExternalID or CatItemID |
Applies to GET, PUT, and DELETE for single-entity requests. If omitted or unrecognized, the API defaults to ExternalID. |
| URL Segment | Required | Description |
|---|---|---|
CatName* |
Yes (All verbs) | The name of the category (e.g., Area, Location, Department). |
CatItemID or ExternalID |
Conditional (Required for PUT & DELETE) |
The lookup value matching the property chosen in the Lookup-Key header. If omitted on GET, all Category Items for the specified CatName are returned. |
{
"ErrorCode": 0,
"ErrorMessage": "Success",
"ItemResponses": "[]",
"Items": [
{
"Color": "",
"Name": "Area A",
"CatNo": "2",
"CatItemID": "10",
"SortValue": "0000000001"
},
{
"Color": "000000",
"Name": "Area B",
"ExternalID": "BArea",
"CatNo": "2",
"CatItemID": "11",
"SortValue": "0000000002"
},
{
"Color": "",
"Name": "Area C",
"CatNo": "2",
"CatItemID": "17",
"SortValue": "0000000003"
}
]
}
{
"ErrorCode": 0,
"ErrorMessage": "Success",
"ItemResponses": "[]",
"Items": [
{
"Active": "False",
"Color": "",
"Name": "Main",
"EndTime": "T17:00:00.0000000",
"CatNo": "1",
"CatItemID": "1",
"ShowToEmployee": "False",
"SortValue": "0000000001",
"StartTime": "T09:00:00.0000000"
}
]
}
| Parameter | Required | Notes / Applicability |
|---|---|---|
Name* | Yes | Display name of the new category item. |
ExternalID | No | Optional external system identifier. |
Color | No | 6-character hex color code (e.g., 00FF00). |
Active | No | Time Off Account category items only. |
ShowToEmployee | No | Time Off Account category items only. |
StartTime | No | Time Of Day category items only. |
EndTime | No | Time Of Day category items only. |
{
"Name": "Location X",
"CatNo": "1",
"Color": "00FF00"
}
{
"ErrorCode": 0,
"ErrorMessage": "Success",
"ItemResponses": null,
"Items": "[]"
}
| Parameter | Required | Notes / Applicability |
|---|---|---|
Name | No | Updated display name of the category item. |
ExternalID | No | Updated external identifier. |
Color | No | Updated 6-character hex color code (e.g., 0E0E0E). |
Active | No | Time Off Account category items only. |
ShowToEmployee | No | Time Off Account category items only. |
StartTime | No | Time Of Day category items only. |
EndTime | No | Time Of Day category items only. |
{
"Color": "0E0E0E"
}
{
"ErrorCode": 0,
"ErrorMessage": "Success",
"ItemResponses": null,
"Items": "[]"
}
{
"ErrorCode": 0,
"ErrorMessage": "Success",
"ItemResponses": null,
"Items": "[]"
}