Create a work activity for the specified work order
Creates a new work activity for the specified work order. The work activity type can be either Travel or Repair. Note that custom types may be configured for a subscriber. <br />Before creating a work activity, please consider the following: • You can create work activities only for work orders in the In Progress primary status. • The check-in date and time cannot be greater than the check-out date and time. • The check-in date and time cannot be earlier than the scheduled date and time of the work order. • The time range of the work activity you are creating cannot overlap the time ranges of existing work activities of the work order. • The name will be set to the API caller name if the name value is not provided. <br />Note: Both subscribers and providers can use this method. <br />Note: Only users with extended permissions can specify the technician's name while creating a work activity. The users with extended permissions are: • Subscribers that have the Admin role. • Providers that have the Admin role (with the EditLaborItemsOnWoDetailsProvider feature flag turned on). • Providers that have the Business Owner / Management role (with the EditLaborItemsOnWoDetailsProvider feature flag turned on). <br />Learn more about creating a work activity in ServiceChannel University. <br />Example Request
POST /workorders/{workorderId}/workactivities
{
"WorkTypeId": "1",
"CheckInDate": "2020-11-19T11:10:36.868Z",
"CheckOutDate": "2020-11-19T12:15:36.868Z",
"Name": "John Doe"
}
Request
- Base URLhttps://sb2api.servicechannel.com/v3
- AuthOAuth 2Authorization codehttps://sb2login.servicechannel.com/oauth/authorizeToken URLhttps://sb2login.servicechannel.com/oauth/token
- TypeScriptA function with typed inputs. Its response is checked against the schema.
Path parameters
The unique numeric identifier of the work order for which you want to create a work activity.
Request body
Response
A work activity is created for the specified work order, and a unique work activity ID is returned in the response.
Changes
No recorded changes to this operation across all 1 revision of this API.