Work | Work Order State
Service to manage entities of type 'WorkOrderState'.
This service extends VKSchemaEntityStates.
Overview
URL | api/{tenantKey}/{orgKey}/maintenanceCore/workOrderStates |
Methods Supported | GET, POST, PUT, DELETE |
All Operations
This service includes the following operations:
-
GET:
- GET WorkOrderStates (odata)
- GET WorkOrderState by identifier
- GET WorkOrderState by key
- GET WorkOrderStates (with VKSchemaEntityState)
- GET WorkOrderStates (with VKSchemaEntityState) (paged)
- GET WorkOrderState (with VKSchemaEntityState) by identifier
- GET WorkOrderState (with VKSchemaEntityState) by key
- GET Get All Work Order States
- POST:
-
PUT:
- PUT Set Custom Attribute WorkOrderState
- PUT Set IsActive WorkOrderState
- PUT Set MustValidateTasks WorkOrderState
- PUT Set AllowWorkReport WorkOrderState
- PUT Set AllowCostReport WorkOrderState
- PUT Set AllowAssignments WorkOrderState
- PUT Set StartSLA WorkOrderState
- PUT Set EndSLA WorkOrderState
- PUT Set ChangeRequestStateTo WorkOrderState
- PUT Set AllowChangeRemarks WorkOrderState
- PUT Set IsCanceledState WorkOrderState
- PUT Set StartDownTime WorkOrderState
- PUT Set EndDownTime WorkOrderState
- PUT Set DownTimeInfo WorkOrderState
- PUT Set SLAInfo WorkOrderState
- PUT Set CanCreateFromEvent WorkOrderState
- PUT Set CopyJustification WorkOrderState
- DELETE:
All Resources
This service uses the following resources:
GET WorkOrderStates (odata)
Returns a page of the list of all the entity records available.
The following elements are optional:
opts | (ODataQueryOptions) OData query option. |
Response:
When successful, the response body contains the list of records available. See WorkOrderStateResource. |
Response status codes:
200 | OK. The operation was completed successfully. |
400 | BadRequest. The request parameters are invalid. |
Resource URL:
GET WorkOrderState by identifier
Returns the entity record that matches the specified identifier.
The following elements are required:
id | (string) The record identifier. |
Response:
When successful, the response body contains the entity record. See WorkOrderStateResource. |
Response status codes:
200 | OK. The operation was completed successfully. |
400 | BadRequest. The request parameters are invalid. |
404 | NotFound. The specified record does not exist. |
Resource URL:
GET WorkOrderState by key
Returns the entity record that matches the specified key.
The following elements are required:
stateKey | (string) State. |
Response:
When successful, the response body contains the entity record. See WorkOrderStateResource. |
Response status codes:
200 | OK. The operation was completed successfully. |
400 | BadRequest. The request parameters are invalid. |
404 | NotFound. The specified record does not exist. |
Resource URL:
GET WorkOrderStates (with VKSchemaEntityState)
Returns the list of all the entity records available. Each record contains both data from the entity and the base entity.
Response:
When successful, the response body contains the list of records available. See BaseWorkOrderStateResource. |
Response status codes:
200 | OK. The operation was completed successfully. |
400 | BadRequest. The request parameters are invalid. |
Resource URL:
GET WorkOrderStates (with VKSchemaEntityState) (paged)
Returns a page of the list of all the entity records available. Each record contains both data from the entity and the base entity.
The following elements are optional:
page | (int) The index of the page of the list that should be returned. This is a query string parameter. |
pageSize | (int) The number of page elements that should be returned (max. is 1000). This is a query string parameter. |
Response:
When successful, the response body contains the list of records available. See BaseWorkOrderStateResource. |
Response status codes:
200 | OK. The operation was completed successfully. |
400 | BadRequest. The request parameters are invalid. |
Resource URL:
GET WorkOrderState (with VKSchemaEntityState) by identifier
Returns the entity record that matches the specified identifier. The record contains both data from the entity and the base entity.
The following elements are required:
id | (string) The record identifier. |
Response:
When successful, the response body contains the entity record. See BaseWorkOrderStateResource. |
Response status codes:
200 | OK. The operation was completed successfully. |
400 | BadRequest. The request parameters are invalid. |
404 | NotFound. The specified record does not exist. |
Resource URL:
GET WorkOrderState (with VKSchemaEntityState) by key
Returns the entity record that matches the specified key. The record contains both data from the entity and the base entity.
The following elements are required:
stateKey | (string) State. |
Response:
When successful, the response body contains the entity record. See BaseWorkOrderStateResource. |
Response status codes:
200 | OK. The operation was completed successfully. |
400 | BadRequest. The request parameters are invalid. |
404 | NotFound. The specified record does not exist. |
Resource URL:
GET Get All Work Order States
Get all work order states.
The following elements are required:
onlyAllowAssignments | (bool) OnlyAllowAssignments. |
Response:
When successful, the response body contains a list of resources of type 'WorkOrderStateResource'. See WorkOrderStateResource. |
Response status codes:
200 | OK. The operation was completed successfully. |
400 | BadRequest. The request parameters are invalid. |
Resource URL:
POST WorkOrderStates
Creates a new entity record.
The following elements are required:
workOrderStateResource | (ApiWorkOrderStateResource) The request body should contain the entity record that should be created. See ApiWorkOrderStateResource. |
The following elements are optional:
customAttributes | (JSON Document) A key-value pair in JSON format that represents the extensibility custom attributes for this entity. The key should be the custom attribute name prefixed with "custom_", e.g. "custom_attributeName". While the "customAttributes" element is optional, please notice that specific custom attributes might be marked as required. |
Response:
When successful, the response body contains the new entity record identifier. The resource header location property contains the URL for the new entity record. See ApiWorkOrderStateResource. |
Response status codes:
201 | Created. The operation was completed successfully. |
400 | BadRequest. The request parameters are invalid. |
Resource URL:
POST WorkOrderStates (with ApiBaseWorkOrderState)
Creates a new entity record. The record shoud contain both data from the entity and the base entity.
The following elements are required:
workOrderStateResource | (ApiWorkOrderStateResource) The request body should contain the entity record that should be created. See ApiWorkOrderStateResource. |
The following elements are optional:
customAttributes | (JSON Document) A key-value pair in JSON format that represents the extensibility custom attributes for this entity. The key should be the custom attribute name prefixed with "custom_", e.g. "custom_attributeName". While the "customAttributes" element is optional, please notice that specific custom attributes might be marked as required. |
Response:
When successful, the response body contains the new entity record identifier. The resource header location property contains the URL for the new entity record. See ApiBaseWorkOrderStateResource. |
Response status codes:
201 | Created. The operation was completed successfully. |
400 | BadRequest. The request parameters are invalid. |
Resource URL:
POST Get State Configuration
Custom operation 'GetStateConfiguration'.
The following elements are required:
stateId | (Guid) StateId. |
The following elements are optional:
customAttributes | (JSON Document) A key-value pair in JSON format that represents the extensibility custom attributes for this entity. The key should be the custom attribute name prefixed with "custom_", e.g. "custom_attributeName". While the "customAttributes" element is optional, please notice that specific custom attributes might be marked as required. |
Response:
When successful, the response body contains a resource of type 'WorkOrderStateResource'. See WorkOrderStateResource. |
Resource URL:
POST Validate Date
Custom operation 'ValidateDate'.
The following elements are required:
workOrderKey | (string) WorkOrderKey. |
workReport | (bool) WorkReport. |
costReport | (bool) CostReport. |
schemaEntityId | (Guid) SchemaEntityId. |
currentStateId | (Guid) CurrentStateId. |
date | (DateTimeOffset) Date. |
The following elements are optional:
customAttributes | (JSON Document) A key-value pair in JSON format that represents the extensibility custom attributes for this entity. The key should be the custom attribute name prefixed with "custom_", e.g. "custom_attributeName". While the "customAttributes" element is optional, please notice that specific custom attributes might be marked as required. |
Response:
When successful, the response body contains an item of type 'boolean'. |
Resource URL:
PUT Set AllowAssignments WorkOrderState
Updates the value of attribute 'AllowAssignments' in the specified entity record.
The following elements are required:
stateKey | (string) State. |
value | (bool) The request body should contain the new value for the attribute. |
Response:
When successful, the response body is empty. |
Response status codes:
200 | OK. The operation was completed successfully. |
400 | BadRequest. The request parameters are invalid. |
Resource URL:
PUT Set AllowChangeRemarks WorkOrderState
Updates the value of attribute 'AllowChangeRemarks' in the specified entity record.
The following elements are required:
stateKey | (string) State. |
value | (bool) The request body should contain the new value for the attribute. |
Response:
When successful, the response body is empty. |
Response status codes:
200 | OK. The operation was completed successfully. |
400 | BadRequest. The request parameters are invalid. |
Resource URL:
PUT Set AllowCostReport WorkOrderState
Updates the value of attribute 'AllowCostReport' in the specified entity record.
The following elements are required:
stateKey | (string) State. |
value | (bool) The request body should contain the new value for the attribute. |
Response:
When successful, the response body is empty. |
Response status codes:
200 | OK. The operation was completed successfully. |
400 | BadRequest. The request parameters are invalid. |
Resource URL:
PUT Set AllowWorkReport WorkOrderState
Updates the value of attribute 'AllowWorkReport' in the specified entity record.
The following elements are required:
stateKey | (string) State. |
value | (bool) The request body should contain the new value for the attribute. |
Response:
When successful, the response body is empty. |
Response status codes:
200 | OK. The operation was completed successfully. |
400 | BadRequest. The request parameters are invalid. |
Resource URL:
PUT Set CanCreateFromEvent WorkOrderState
Updates the value of attribute 'CanCreateFromEvent' in the specified entity record.
The following elements are required:
stateKey | (string) State. |
value | (bool) The request body should contain the new value for the attribute. |
Response:
When successful, the response body is empty. |
Response status codes:
200 | OK. The operation was completed successfully. |
400 | BadRequest. The request parameters are invalid. |
Resource URL:
PUT Set ChangeRequestStateTo WorkOrderState
Updates the value of attribute 'ChangeRequestStateTo' in the specified entity record.
The following elements are required:
stateKey | (string) State. |
value | (string) The request body should contain the new value for the attribute. |
Response:
When successful, the response body is empty. |
Response status codes:
200 | OK. The operation was completed successfully. |
400 | BadRequest. The request parameters are invalid. |
Resource URL:
PUT Set CopyJustification WorkOrderState
Updates the value of attribute 'CopyJustification' in the specified entity record.
The following elements are required:
stateKey | (string) State. |
value | (bool) The request body should contain the new value for the attribute. |
Response:
When successful, the response body is empty. |
Response status codes:
200 | OK. The operation was completed successfully. |
400 | BadRequest. The request parameters are invalid. |
Resource URL:
PUT Set DownTimeInfo WorkOrderState
Updates the value of attribute 'DownTimeInfo' in the specified entity record.
The following elements are required:
stateKey | (string) State. |
value | (string) The request body should contain the new value for the attribute. |
Response:
When successful, the response body is empty. |
Response status codes:
200 | OK. The operation was completed successfully. |
400 | BadRequest. The request parameters are invalid. |
Resource URL:
PUT Set EndDownTime WorkOrderState
Updates the value of attribute 'EndDownTime' in the specified entity record.
The following elements are required:
stateKey | (string) State. |
value | (bool) The request body should contain the new value for the attribute. |
Response:
When successful, the response body is empty. |
Response status codes:
200 | OK. The operation was completed successfully. |
400 | BadRequest. The request parameters are invalid. |
Resource URL:
PUT Set EndSLA WorkOrderState
Updates the value of attribute 'EndSLA' in the specified entity record.
The following elements are required:
stateKey | (string) State. |
value | (bool) The request body should contain the new value for the attribute. |
Response:
When successful, the response body is empty. |
Response status codes:
200 | OK. The operation was completed successfully. |
400 | BadRequest. The request parameters are invalid. |
Resource URL:
PUT Set IsActive WorkOrderState
Updates the value of attribute 'IsActive' in the specified entity record.
The following elements are required:
stateKey | (string) State. |
value | (bool) The request body should contain the new value for the attribute. |
Response:
When successful, the response body is empty. |
Response status codes:
200 | OK. The operation was completed successfully. |
400 | BadRequest. The request parameters are invalid. |
404 | NotFound. The specified record does not exist. |
Resource URL:
PUT Set IsCanceledState WorkOrderState
Updates the value of attribute 'IsCanceledState' in the specified entity record.
The following elements are required:
stateKey | (string) State. |
value | (bool) The request body should contain the new value for the attribute. |
Response:
When successful, the response body is empty. |
Response status codes:
200 | OK. The operation was completed successfully. |
400 | BadRequest. The request parameters are invalid. |
Resource URL:
PUT Set MustValidateTasks WorkOrderState
Updates the value of attribute 'MustValidateTasks' in the specified entity record.
The following elements are required:
stateKey | (string) State. |
value | (bool) The request body should contain the new value for the attribute. |
Response:
When successful, the response body is empty. |
Response status codes:
200 | OK. The operation was completed successfully. |
400 | BadRequest. The request parameters are invalid. |
Resource URL:
PUT Set SLAInfo WorkOrderState
Updates the value of attribute 'SLAInfo' in the specified entity record.
The following elements are required:
stateKey | (string) State. |
value | (string) The request body should contain the new value for the attribute. |
Response:
When successful, the response body is empty. |
Response status codes:
200 | OK. The operation was completed successfully. |
400 | BadRequest. The request parameters are invalid. |
Resource URL:
PUT Set StartDownTime WorkOrderState
Updates the value of attribute 'StartDownTime' in the specified entity record.
The following elements are required:
stateKey | (string) State. |
value | (bool) The request body should contain the new value for the attribute. |
Response:
When successful, the response body is empty. |
Response status codes:
200 | OK. The operation was completed successfully. |
400 | BadRequest. The request parameters are invalid. |
Resource URL:
PUT Set StartSLA WorkOrderState
Updates the value of attribute 'StartSLA' in the specified entity record.
The following elements are required:
stateKey | (string) State. |
value | (bool) The request body should contain the new value for the attribute. |
Response:
When successful, the response body is empty. |
Response status codes:
200 | OK. The operation was completed successfully. |
400 | BadRequest. The request parameters are invalid. |
Resource URL:
PUT Set Custom Attribute WorkOrderState
Updates the value of 'CustomAttribute' in the specified entity record.
The following elements are required:
stateKey | (string) State |
customAttributeName | (string) The custom attribute name. |
value | (ExtensibilityCustomAttributeValueResource) The request body should contain the new value for the custom attribute. See ExtensibilityCustomAttributeValueResource. |
Response:
When successful, the response body is empty. |
Response status codes:
200 | OK. The operation was completed successfully. |
400 | BadRequest. The request parameters are invalid. |
404 | NotFound. The specified record does not exist. |
Resource URL:
DELETE WorkOrderState by identifier
Deletes the entity record that matches the specified identifier.
The following elements are required:
id | (string) The record identifier. |
Response:
When successful, the response body is empty. |
Response status codes:
204 | Deleted. The operation was completed successfully. |
400 | BadRequest. The request parameters are invalid. |
404 | NotFound. The specified record does not exist. |
Resource URL:
DELETE WorkOrderState by key
Deletes the entity record that matches the specified key.
The following elements are required:
stateKey | (string) State. |
Response:
When successful, the response body is empty. |
Response status codes:
204 | Deleted. The operation was completed successfully. |
400 | BadRequest. The request parameters are invalid. |
404 | NotFound. The specified record does not exist. |
Resource URL:
Resources
ApiBaseWorkOrderStateResource
The following elements are required:
startSLA | (bool) Start SLA. |
endSLA | (bool) End SLA. |
allowChangeRemarks | (bool) Allow change remarks. |
startDownTime | (bool) Start Down Time. |
endDownTime | (bool) End Down Time. |
canCreateFromEvent | (bool) Can Create From Event. |
copyJustification | (bool) Copy Justification. |
stateKey | (string) State. |
description | (string) Description. |
isInitialState | (bool) Is Initial State. |
isFinalState | (bool) Is Final State. |
schemaEntity | (string) Entity. |
The following elements are optional:
mustValidateTasks | (bool) Must Validate Tasks. |
allowWorkReport | (bool) Allow Work Report. |
allowCostReport | (bool) Allow Cost Report. |
allowAssignments | (bool) Allow Assignments. |
changeRequestStateTo | (string) State. |
isCanceledState | (bool) Canceled. |
downTimeInfo | (string) Down Time Info. |
sLAInfo | (string) Information. |
isLockedForChanges | (bool) Is Locked For Changes. |
localizedDescription | (string) Localized Description. |
notificationId | (Guid) Initial Notification. |
ApiWorkOrderStateResource
The following elements are required:
startSLA | (bool) Start SLA. |
endSLA | (bool) End SLA. |
allowChangeRemarks | (bool) Allow change remarks. |
startDownTime | (bool) Start Down Time. |
endDownTime | (bool) End Down Time. |
canCreateFromEvent | (bool) Can Create From Event. |
copyJustification | (bool) Copy Justification. |
stateKey | (string) State. |
The following elements are optional:
mustValidateTasks | (bool) Must Validate Tasks. |
allowWorkReport | (bool) Allow Work Report. |
allowCostReport | (bool) Allow Cost Report. |
allowAssignments | (bool) Allow Assignments. |
changeRequestStateTo | (string) State. |
isCanceledState | (bool) Canceled. |
downTimeInfo | (string) Down Time Info. |
sLAInfo | (string) Information. |
BaseWorkOrderStateResource
The following elements are required:
startSLA | (bool) Start SLA. |
endSLA | (bool) End SLA. |
allowChangeRemarks | (bool) Allow change remarks. |
startDownTime | (bool) Start Down Time. |
endDownTime | (bool) End Down Time. |
canCreateFromEvent | (bool) Can Create From Event. |
copyJustification | (bool) Copy Justification. |
stateKey | (string) State. |
description | (string) Description. |
isInitialState | (bool) Is Initial State. |
isFinalState | (bool) Is Final State. |
schemaEntity | (string) Entity. |
The following elements are optional:
mustValidateTasks | (bool) Must Validate Tasks. |
allowWorkReport | (bool) Allow Work Report. |
allowCostReport | (bool) Allow Cost Report. |
allowAssignments | (bool) Allow Assignments. |
changeRequestStateTo | (string) State. |
isCanceledState | (bool) Canceled. |
downTimeInfo | (string) Down Time Info. |
sLAInfo | (string) Information. |
isLockedForChanges | (bool) Is Locked For Changes. |
localizedDescription | (string) Localized Description. |
notificationId | (Guid) Initial Notification. |
WorkOrderStateResource
The following elements are required:
startSLA | (bool) Start SLA. |
endSLA | (bool) End SLA. |
allowChangeRemarks | (bool) Allow change remarks. |
startDownTime | (bool) Start Down Time. |
endDownTime | (bool) End Down Time. |
canCreateFromEvent | (bool) Can Create From Event. |
copyJustification | (bool) Copy Justification. |
stateKey | (string) State. |
The following elements are optional:
mustValidateTasks | (bool) Must Validate Tasks. |
allowWorkReport | (bool) Allow Work Report. |
allowCostReport | (bool) Allow Cost Report. |
allowAssignments | (bool) Allow Assignments. |
changeRequestStateTo | (string) State. |
isCanceledState | (bool) Canceled. |
downTimeInfo | (string) Down Time Info. |
sLAInfo | (string) Information. |
ExtensibilityCustomAttributeValueResource
The following elements are required:
value | (object) The custom attribute value. |