200 |
TODO |
|
application/json
model |
example
{
"title": "order object in history collection",
"$schema": "http://json-schema.org/draft-04/schema#",
"javaType": "com.sos.joc.model.order.OrderHistoryItemChildren",
"type": "object",
"required": [
"deliveryDate",
"historyId"
],
"properties": {
"deliveryDate": {
"description": "Value is UTC timestamp in ISO 8601 YYYY-MM-DDThh:mm:ss.sZ or empty",
"type": "string",
"format": "date-time"
},
"historyId": {
"type": "number",
"format": "utc-millisec",
"minimum": 0
},
"states": {
"type": "array",
"items": {
"javaType": "com.sos.joc.model.order.OrderHistoryStateItem",
"type": "object",
"required": [
"state",
"stateTime"
],
"properties": {
"state": {
"javaType": "com.sos.joc.model.order.OrderState",
"type": "object",
"required": [
"severity",
"_text"
],
"properties": {
"severity": {
"type": "integer"
},
"_text": {
"javaType": "com.sos.joc.model.order.OrderStateText",
"type": "string",
"enum": [
"PLANNED",
"PENDING",
"SCHEDULED",
"RUNNING",
"INPROGRESS",
"PROMPTING",
"SUSPENDED",
"FAILED",
"WAITING",
"BLOCKED",
"CANCELLED",
"FINISHED",
"BROKEN",
"CALLING",
"UNKNOWN"
]
}
}
},
"stateTime": {
"description": "Value is UTC timestamp in ISO 8601 YYYY-MM-DDThh:mm:ss.sZ or empty",
"type": "string",
"format": "date-time"
},
"stateText": {
"type": "string"
}
}
}
},
"hasTasks": {
"type": "boolean"
},
"hasOrders": {
"type": "boolean"
},
"children": {
"type": "array",
"items": {
"javaType": "com.sos.joc.model.order.OrderHistoryItemChildItem",
"type": "object",
"required": [],
"properties": {
"task": {
"javaType": "com.sos.joc.model.job.TaskHistoryItem",
"type": "object",
"required": [
"surveyDate",
"workflow",
"job",
"startTime",
"position",
"sequence",
"retryCounter",
"state",
"criticality",
"taskId",
"agentUrl"
],
"properties": {
"surveyDate": {
"description": "Value is UTC timestamp in ISO 8601 YYYY-MM-DDThh:mm:ss.sZ or empty",
"type": "string",
"format": "date-time"
},
"controllerId": {
"type": "string"
},
"job": {
"type": "string"
},
"workflow": {
"type": "string"
},
"orderId": {
"type": "string"
},
"startTime": {
"description": "Value is UTC timestamp in ISO 8601 YYYY-MM-DDThh:mm:ss.sZ or empty",
"type": "string",
"format": "date-time"
},
"endTime": {
"description": "Value is UTC timestamp in ISO 8601 YYYY-MM-DDThh:mm:ss.sZ or empty",
"type": "string",
"format": "date-time"
},
"position": {
"type": "string"
},
"sequence": {
"type": "integer",
"minimum": 0
},
"retryCounter": {
"type": "integer",
"minimum": 0
},
"state": {
"javaType": "com.sos.joc.model.common.HistoryState",
"type": "object",
"required": [
"severity",
"_text"
],
"properties": {
"severity": {
"description": "0=successful, 1=incomplete, 2=failed with a green/yellow/red representation",
"type": "integer"
},
"_text": {
"javaType": "com.sos.joc.model.common.HistoryStateText",
"type": "string",
"enum": [
"SUCCESSFUL",
"INCOMPLETE",
"FAILED"
]
}
}
},
"criticality": {
"type": "string"
},
"taskId": {
"type": "number",
"format": "utc-millisec",
"minimum": 0
},
"agentUrl": {
"type": "string"
},
"exitCode": {
"type": "integer",
"minimum": 0
},
"error": {
"javaType": "com.sos.joc.model.common.Err",
"type": "object",
"required": [
"code",
"message"
],
"properties": {
"code": {
"type": "string"
},
"message": {
"type": "string"
}
}
},
"arguments": {
"description": "a map for arbitrary key-value pairs",
"javaType": "com.sos.inventory.model.common.Variables",
"type": "object",
"additionalProperties": true
}
}
},
"order": {
"javaType": "com.sos.joc.model.order.OrderHistoryItem",
"type": "object",
"required": [
"surveyDate",
"orderId",
"workflow",
"startTime",
"plannedTime",
"position",
"sequence",
"state",
"orderState",
"historyId"
],
"properties": {
"surveyDate": {
"description": "Value is UTC timestamp in ISO 8601 YYYY-MM-DDThh:mm:ss.sZ or empty",
"type": "string",
"format": "date-time"
},
"controllerId": {
"type": "string"
},
"orderId": {
"type": "string"
},
"workflow": {
"description": "absolute path of an object.",
"type": "string",
"pattern": "^(/|(/[^/\\\\<>?:\"|*]+)+)$",
"maxLength": 255,
"minLength": 1
},
"startTime": {
"description": "Value is UTC timestamp in ISO 8601 YYYY-MM-DDThh:mm:ss.sZ or empty",
"type": "string",
"format": "date-time"
},
"plannedTime": {
"description": "Value is UTC timestamp in ISO 8601 YYYY-MM-DDThh:mm:ss.sZ or empty",
"type": "string",
"format": "date-time"
},
"endTime": {
"description": "Value is UTC timestamp in ISO 8601 YYYY-MM-DDThh:mm:ss.sZ or empty",
"type": "string",
"format": "date-time"
},
"position": {
"type": "string"
},
"sequence": {
"type": "integer",
"minimum": 0
},
"state": {
"javaType": "com.sos.joc.model.common.HistoryState",
"type": "object",
"required": [
"severity",
"_text"
],
"properties": {
"severity": {
"description": "0=successful, 1=incomplete, 2=failed with a green/yellow/red representation",
"type": "integer"
},
"_text": {
"javaType": "com.sos.joc.model.common.HistoryStateText",
"type": "string",
"enum": [
"SUCCESSFUL",
"INCOMPLETE",
"FAILED"
]
}
}
},
"orderState": {
"javaType": "com.sos.joc.model.order.OrderState",
"type": "object",
"required": [
"severity",
"_text"
],
"properties": {
"severity": {
"type": "integer"
},
"_text": {
"javaType": "com.sos.joc.model.order.OrderStateText",
"type": "string",
"enum": [
"PLANNED",
"PENDING",
"SCHEDULED",
"RUNNING",
"INPROGRESS",
"PROMPTING",
"SUSPENDED",
"FAILED",
"WAITING",
"BLOCKED",
"CANCELLED",
"FINISHED",
"BROKEN",
"CALLING",
"UNKNOWN"
]
}
}
},
"historyId": {
"type": "number",
"format": "utc-millisec",
"minimum": 0
},
"children": {
"type": "array",
"items": {
"description": "orderHistoryItem-schema.json"
}
},
"arguments": {
"description": "a map for arbitrary key-value pairs",
"javaType": "com.sos.inventory.model.common.Variables",
"type": "object",
"additionalProperties": true
}
}
}
}
}
}
}
}
{ "children": [{ "task": { "agentUrl": "http://localhost:4445", "controllerId": "js7.x", "criticality": "normal", "endTime": "2020-12-01T16:45:20Z", "exitCode": 0, "job": "job1", "orderId": "workflow_fork@33", "position": "0", "retryCounter": 0, "sequence": 0, "startTime": "2020-12-01T16:45:20Z", "state": { "_text": "SUCCESSFUL", "severity": 0 }, "surveyDate": "2020-12-01T16:45:21Z", "taskId": 2157857, "workflow": "/workflow_fork", "arguments": { "my_string_var": "my_value", "my_boolean_var": false, "my_numeric_var": 123 } } }, { "order": { "children": [], "controllerId": "js7.x", "endTime": "2020-12-01T16:45:20Z", "historyId": 587032, "orderId": "workflow_fork@33/branch1", "orderState": { "_text": "FINISHED", "severity": 0 }, "plannedTime": "2020-12-01T16:45:20Z", "position": "1", "sequence": 1, "startTime": "2020-12-01T16:45:20Z", "state": { "_text": "SUCCESSFUL", "severity": 0 }, "surveyDate": "2020-12-01T16:45:21Z", "workflow": "/workflow_fork", "arguments": { "my_string_var": "my_value", "my_boolean_var": false, "my_numeric_var": 123 } } }, { "order": { "children": [], "controllerId": "js7.x", "endTime": "2020-12-01T16:45:20Z", "historyId": 587033, "orderId": "workflow_fork@33/branch2", "orderState": { "_text": "FINISHED", "severity": 0 }, "plannedTime": "2020-12-01T16:45:20Z", "position": "1", "sequence": 1, "startTime": "2020-12-01T16:45:20Z", "state": { "_text": "SUCCESSFUL", "severity": 0 }, "surveyDate": "2020-12-01T16:45:21Z", "workflow": "/workflow_fork" } }, { "task": { "agentUrl": "http://localhost:4445", "controllerId": "js7.x", "criticality": "normal", "endTime": "2020-12-01T16:45:21Z", "exitCode": 0, "job": "job3", "orderId": "workflow_fork@33", "position": "2", "retryCounter": 0, "sequence": 2, "startTime": "2020-12-01T16:45:20Z", "state": { "_text": "SUCCESSFUL", "severity": 0 }, "surveyDate": "2020-12-01T16:45:22Z", "taskId": 2157860, "workflow": "/workflow_fork" } }], "deliveryDate": "2020-12-01T16:47:35.08Z", "hasOrders": true, "hasTasks": true, "states": [] }
{
"children": [{
"task": {
"agentUrl": "http://localhost:4445",
"controllerId": "js7.x",
"criticality": "normal",
"endTime": "2020-12-01T16:45:20Z",
"exitCode": 0,
"job": "job1",
"orderId": "workflow_fork@33",
"position": "0",
"retryCounter": 0,
"sequence": 0,
"startTime": "2020-12-01T16:45:20Z",
"state": {
"_text": "SUCCESSFUL",
"severity": 0
},
"surveyDate": "2020-12-01T16:45:21Z",
"taskId": 2157857,
"workflow": "/workflow_fork",
"arguments": {
"my_string_var": "my_value",
"my_boolean_var": false,
"my_numeric_var": 123
}
}
}, {
"order": {
"children": [],
"controllerId": "js7.x",
"endTime": "2020-12-01T16:45:20Z",
"historyId": 587032,
"orderId": "workflow_fork@33/branch1",
"orderState": {
"_text": "FINISHED",
"severity": 0
},
"plannedTime": "2020-12-01T16:45:20Z",
"position": "1",
"sequence": 1,
"startTime": "2020-12-01T16:45:20Z",
"state": {
"_text": "SUCCESSFUL",
"severity": 0
},
"surveyDate": "2020-12-01T16:45:21Z",
"workflow": "/workflow_fork",
"arguments": {
"my_string_var": "my_value",
"my_boolean_var": false,
"my_numeric_var": 123
}
}
}, {
"order": {
"children": [],
"controllerId": "js7.x",
"endTime": "2020-12-01T16:45:20Z",
"historyId": 587033,
"orderId": "workflow_fork@33/branch2",
"orderState": {
"_text": "FINISHED",
"severity": 0
},
"plannedTime": "2020-12-01T16:45:20Z",
"position": "1",
"sequence": 1,
"startTime": "2020-12-01T16:45:20Z",
"state": {
"_text": "SUCCESSFUL",
"severity": 0
},
"surveyDate": "2020-12-01T16:45:21Z",
"workflow": "/workflow_fork"
}
}, {
"task": {
"agentUrl": "http://localhost:4445",
"controllerId": "js7.x",
"criticality": "normal",
"endTime": "2020-12-01T16:45:21Z",
"exitCode": 0,
"job": "job3",
"orderId": "workflow_fork@33",
"position": "2",
"retryCounter": 0,
"sequence": 2,
"startTime": "2020-12-01T16:45:20Z",
"state": {
"_text": "SUCCESSFUL",
"severity": 0
},
"surveyDate": "2020-12-01T16:45:22Z",
"taskId": 2157860,
"workflow": "/workflow_fork"
}
}],
"deliveryDate": "2020-12-01T16:47:35.08Z",
"hasOrders": true,
"hasTasks": true,
"states": []
}
|