Update asset group by ID

post

/assetMonitoring/clientapi/v2/groups/{asset-group-id}

This operation updates the asset group details using the asset group definition that is provided for the given asset group ID.

Request

Supported Media Types
Path Parameters
Header Parameters
Body ()
Root Schema : AssetGroupImpl_update
Type: object
Show Source
Nested Schema : children
Type: array
Property description was not set
Show Source
Nested Schema : path
Type: array
Property description was not set
Show Source
Nested Schema : AssetGroup_update
Type: object
Show Source
Nested Schema : children
Type: array
Property description was not set
Show Source
Nested Schema : path
Type: array
Property description was not set
Show Source
Nested Schema : PathToOrgEntityType_update
Type: object
Show Source
Back to Top

Response

Supported Media Types

200 Response

Successfully processed.
Body ()
Root Schema : AssetGroupImpl_receive
Type: object
Show Source
Nested Schema : assets
Type: object
Property description was not set
Show Source
Nested Schema : children
Type: array
Property description was not set
Show Source
Nested Schema : path
Type: array
Property description was not set
Show Source
Nested Schema : AssetGroup_receive
Type: object
Show Source
Nested Schema : assets
Type: object
Property description was not set
Show Source
Nested Schema : children
Type: array
Property description was not set
Show Source
Nested Schema : path
Type: array
Property description was not set
Show Source
Nested Schema : PathToOrgEntityType_receive
Type: object
Show Source
  • Property description was not set
  • Property description was not set
  • One of [TRIP, TRIP_TEMPLATE, SHIPMENT, VEHICLE, DRIVER, ASSET, GROUP, FACILITY, LOAD, ORG, TRANSACTION_LOG, SHIP_UNIT, SHIP_ITEM, EQUIPMENT].

400 Response

Bad Request. The request could not be understood by the server due to malformed syntax. The client SHOULD NOT repeat the request without modifications.

401 Response

Unauthorized. The request requires user authentication.

404 Response

Not Found. The server has not found anything matching the Request-URI. No indication is given of whether the condition is temporary or permanent.

405 Response

Method Not Allowed. The method specified in the Request-Line is not allowed for the resource identified by the Request-URI.

406 Response

Request 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.

415 Response

Unsupported Media Type. The request entity has a media type which the server or resource does not support.
Back to Top

Examples

curl -X POST 
   -u <username>:<password>
   -H 'Accept: application/json'
   -H 'Content-Type: application/json'
   --header "X-HTTP-Method-Override: PATCH"
   https://iotserver/assetMonitoring/clientapi/v2/groups/{asset-group-id}

Example of Request Body

The following example shows the content of the request body in JSON format:


{
"children":[
{
"description":"Property description was not set",
"name":"Property description was not set",
"organizationId":"569f6e373ad1-7ce9",
"parentId":"2c78692b3ff3-1bfe",
"path":[
{
"id":"7e5c6de87ab4-749",
"name":"Property description was not set",
"type":"One of [TRIP, TRIP_TEMPLATE, SHIPMENT, VEHICLE, DRIVER, ASSET, GROUP, FACILITY, LOAD, ORG, TRANSACTION_LOG, SHIP_UNIT, SHIP_ITEM, EQUIPMENT]."
}
],
"placeId":"5c605684235c-6361",
"query":"Property description was not set",
"restricted":false,
"type":"One of [STATIC, QUERY]."
}
],
"description":"Property description was not set",
"name":"Property description was not set",
"organizationId":"6fcc22c779f-1588",
"parentId":"6a5a2b0658c-3bee",
"path":[
{
"id":"422b19f3a5b-737c",
"name":"Property description was not set",
"type":"One of [TRIP, TRIP_TEMPLATE, SHIPMENT, VEHICLE, DRIVER, ASSET, GROUP, FACILITY, LOAD, ORG, TRANSACTION_LOG, SHIP_UNIT, SHIP_ITEM, EQUIPMENT]."
}
],
"placeId":"499d355333cb-249",
"query":"Property description was not set",
"restricted":false,
"type":"One of [STATIC, QUERY]."
}

Example of Response Body

The following example shows the content of the response body in JSON format:


{
"assets":{
"links":[
{
"href":"https://iotserver/assetMonitoring/clientapi/version/resource/path",
"rel":"self"
},
{
"href":"https://iotserver/assetMonitoring/clientapi/version/resource/path",
"rel":"canonical"
}
]
},
"assetsCount":12345,
"children":[
{
"assets":{
"links":[
{
"href":"https://iotserver/assetMonitoring/clientapi/version/resource/path",
"rel":"self"
},
{
"href":"https://iotserver/assetMonitoring/clientapi/version/resource/path",
"rel":"canonical"
}
]
},
"assetsCount":12345,
"description":"Property description was not set",
"id":"1cdb6341372e-463e",
"name":"Property description was not set",
"organizationId":"6e066158722b-49f6",
"parentId":"f70224f142f-41b4",
"path":[
{
"id":"1a84330d3a9b-6227",
"name":"Property description was not set",
"type":"One of [TRIP, TRIP_TEMPLATE, SHIPMENT, VEHICLE, DRIVER, ASSET, GROUP, FACILITY, LOAD, ORG, TRANSACTION_LOG, SHIP_UNIT, SHIP_ITEM, EQUIPMENT]."
}
],
"placeId":"2fa72388622d-3361",
"query":"Property description was not set",
"restricted":false,
"type":"One of [STATIC, QUERY]."
}
],
"description":"Property description was not set",
"id":"561c347d6c17-3e7d",
"name":"Property description was not set",
"organizationId":"1fda6fe3a85-5fae",
"parentId":"6c7b6a271aff-7114",
"path":[
{
"id":"1524fd133c8-450c",
"name":"Property description was not set",
"type":"One of [TRIP, TRIP_TEMPLATE, SHIPMENT, VEHICLE, DRIVER, ASSET, GROUP, FACILITY, LOAD, ORG, TRANSACTION_LOG, SHIP_UNIT, SHIP_ITEM, EQUIPMENT]."
}
],
"placeId":"711479946261-1816",
"query":"Property description was not set",
"restricted":false,
"type":"One of [STATIC, QUERY]."
}



Complete cURL Example

The following example shows a complete cURL command that you can use to perform the described operation:

curl -X POST 
   -u <username>:<password>
   -H 'Accept: application/json'
   -H 'Content-Type: application/json'
   --header "X-HTTP-Method-Override: PATCH"
   -d '{"children":[{"description":"Property description was not set","name":"Property description was not set","organizationId":"569f6e373ad1-7ce9","parentId":"2c78692b3ff3-1bfe","path":[{"id":"7e5c6de87ab4-749","name":"Property description was not set","type":"One of [TRIP, TRIP_TEMPLATE, SHIPMENT, VEHICLE, DRIVER, ASSET, GROUP, FACILITY, LOAD, ORG, TRANSACTION_LOG, SHIP_UNIT, SHIP_ITEM, EQUIPMENT]."}],"placeId":"5c605684235c-6361","query":"Property description was not set","restricted":false,"type":"One of [STATIC, QUERY]."}],"description":"Property description was not set","name":"Property description was not set","organizationId":"6fcc22c779f-1588","parentId":"6a5a2b0658c-3bee","path":[{"id":"422b19f3a5b-737c","name":"Property description was not set","type":"One of [TRIP, TRIP_TEMPLATE, SHIPMENT, VEHICLE, DRIVER, ASSET, GROUP, FACILITY, LOAD, ORG, TRANSACTION_LOG, SHIP_UNIT, SHIP_ITEM, EQUIPMENT]."}],"placeId":"499d355333cb-249","query":"Property description was not set","restricted":false,"type":"One of [STATIC, QUERY]."}'
   https://iotserver/assetMonitoring/clientapi/v2/groups/{asset-group-id}



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.
Back to Top