List incidents
get
/fleetMonitoring/clientapi/v2/incidents/
This operation returns the list of incidents that exist for the current application instance.
Request
Query Parameters
-
expand(optional): string
List of fields to be expanded in the result. Use 'all' to expand all expandable fields in result.
-
fields(optional): string
The comma-separated list of fields to be shown in response. By default all response object fields will be present.
-
limit(optional): integer
Maximum number of entries to return to end-user.
-
offset(optional): integer
The number that the first record of results is starting from.
-
orderBy(optional): string
Ordering criteria for the returned Incidents list.
-
q(optional): string
Query to filter Incidents on the server. (For more information on mongoDB query parameters refer to Using mongoDB Query Syntax)
-
since(optional): integer
Starting point of interested time interval in milliseconds, default 0.
-
totalResults(optional): boolean
Total number of results which suites particular end-user request.
-
until(optional): integer
Finishing point of interested time interval in milliseconds, default 0.
Response
Supported Media Types
- application/json
- application/vnd.oracle.resource+json;type=collection
200 Response
Successfully processed.
Root Schema : FleetIncident_receive_list
Type:
Show Source
object
-
count:
integer(int32)
-
hasMore:
boolean
-
items:
array items
-
limit:
integer(int32)
-
links:
array links
The set of API navigation links.
-
offset:
integer(int32)
Nested Schema : items
Type:
Show Source
object
-
comments:
array comments
Comments
-
createdBy:
string
User ID or a special ID reserved for Oracle IoT Cloud Service
-
createdTime:
integer
Creation time
-
createdTimeAsString:
string
Creation time as String
-
description:
string
Detailed description
-
geoLocation:
string
incident geoLocation
-
id:
string
Unique ID for each incident
-
incidentTime:
integer
incident time
-
incidentTimeAsString:
string
incident time as string
-
lastModifiedBy:
string
last modified by
-
lastModifiedTime:
integer
lastModified time
-
lastModifiedTimeAsString:
string
lastModified time as string
-
links:
array links
The set of API navigation links.
-
priority:
string
Incident priority, Priority one of [LOW, MEDIUM, HIGH]
-
rule:
string
ID of rule the incident was created for. May be null if the incident was created manually
-
state:
string
Incident stateState one of [NEW, OPEN, WORK_IN_PROGRESS, RESOLVED, WITHDRAWN]
-
summary:
string
Short high-level description
-
tags:
array tags
Tags assigned to the incident
-
type:
string
Type of Incident
Nested Schema : Comment_receive
Type:
Show Source
object
-
createdBy:
string
Author of Incident comment
-
createdTime:
integer
Date of Incident comment
-
links:
array links
The set of API navigation links.
-
state:
string
State of Incident comment
-
text:
string
Text of Incident comment
-
type:
string
Type of Incident comment, Type one of [USER_DEFINED, LIFECYCLE_STATE_TRANSITION]
Nested Schema : items
Type:
Show Source
object
-
href:
string
The target resource URIExample:
https://iotserver/iot/api/vX/some/API/path
-
rel:
string
Relation typeExample:
canonical
Nested Schema : items
Type:
Show Source
object
-
href:
string
The target resource URIExample:
https://iotserver/iot/api/vX/some/API/path
-
rel:
string
Relation typeExample:
canonical
Nested Schema : items
Type:
Show Source
object
-
href:
string
The target resource URIExample:
https://iotserver/iot/api/vX/some/API/path
-
rel:
string
Relation typeExample:
canonical
401 Response
Unauthorized. The request requires user authentication.
406 Response
Not Acceptable. The resource identified by the request is only capable of generating response entities which have content characteristics not acceptable according to the accept headers sent in the request.
Examples
curl -X GET
-u <username>:<password>
-H 'Accept: application/json'
https://iotserver/fleetMonitoring/clientapi/v2/incidents/
Example of Response Body
The following example shows the content of the response body in JSON format:
{
"offset":0,
"count":2,
"limit":10,
"hasMore":false,
"links":[
{
"rel":"self",
"href":"https://iotserver/fleetMonitoring/clientapi/version/resource/path"
},
{
"rel":"canonical",
"href":"https://iotserver/fleetMonitoring/clientapi/version/resource/path"
}
],
"items":[
{
"summary":"Short high-level description",
"comments":[
{
"createdBy":"Author of Incident comment",
"createdTime":1469184297746,
"links":[
{
"rel":"self",
"href":"https://iotserver/fleetMonitoring/clientapi/version/resource/path"
},
{
"rel":"canonical",
"href":"https://iotserver/fleetMonitoring/clientapi/version/resource/path"
}
],
"text":"Text of Incident comment",
"state":"State of Incident comment",
"type":"USER_DEFINED"
}
],
"lastModifiedTime":1469184297746,
"lastModifiedBy":"last modified by",
"lastModifiedTimeAsString":"2016-07-22T10:44:57.746Z",
"description":"Detailed description",
"rule":"Id of rule the incident was created for. May be null if the incident was created manually",
"priority":"LOW",
"type":"Type of Incident",
"tags":[
"tags_1",
"tags_2",
"tags_3"
],
"createdBy":"User ID or a special ID reserved for Oracle IoT Cloud Service",
"geoLocation":"incident geoLocation",
"incidentTimeAsString":"2016-07-22T10:44:57.746Z",
"createdTimeAsString":"2016-07-22T10:44:57.746Z",
"createdTime":1469184297746,
"links":[
{
"rel":"self",
"href":"https://iotserver/fleetMonitoring/clientapi/version/resource/path"
},
{
"rel":"canonical",
"href":"https://iotserver/fleetMonitoring/clientapi/version/resource/path"
}
],
"incidentTime":1469184297746,
"id":"7c19313c4eac-565e",
"state":"NEW"
},
{
"summary":"Short high-level description",
"comments":[
{
"createdBy":"Author of Incident comment",
"createdTime":1469184297746,
"links":[
{
"rel":"self",
"href":"https://iotserver/fleetMonitoring/clientapi/version/resource/path"
},
{
"rel":"canonical",
"href":"https://iotserver/fleetMonitoring/clientapi/version/resource/path"
}
],
"text":"Text of Incident comment",
"state":"State of Incident comment",
"type":"USER_DEFINED"
}
],
"lastModifiedTime":1469184297746,
"lastModifiedBy":"last modified by",
"lastModifiedTimeAsString":"2016-07-22T10:44:57.746Z",
"description":"Detailed description",
"rule":"Id of rule the incident was created for. May be null if the incident was created manually",
"priority":"LOW",
"type":"Type of Incident",
"tags":[
"tags_1",
"tags_2",
"tags_3"
],
"createdBy":"User ID or a special ID reserved for Oracle IoT Cloud Service",
"geoLocation":"incident geoLocation",
"incidentTimeAsString":"2016-07-22T10:44:57.746Z",
"createdTimeAsString":"2016-07-22T10:44:57.746Z",
"createdTime":1469184297746,
"links":[
{
"rel":"self",
"href":"https://iotserver/fleetMonitoring/clientapi/version/resource/path"
},
{
"rel":"canonical",
"href":"https://iotserver/fleetMonitoring/clientapi/version/resource/path"
}
],
"incidentTime":1469184297746,
"id":"352154de59ba-33dd",
"state":"NEW"
}
]
}
Complete cURL Example
The following example shows the complete cURL command that can be used to perform the described operation:
curl -X GET
-u <username>:<password>
-H 'Accept: application/json'
https://iotserver/fleetMonitoring/clientapi/v2/incidents/
Note that in the request,
https://iotserver
will be replaced by the name and port of your assigned IoT Cloud Service instance. The format of the Cloud Service instance is
https://myinstance-myidentitydomain.iot.us.oraclecloud.com
and the default port is
443
.