POST api/Assets/Update
Updates an asset.
Request Information
URI Parameters
None.
Body Parameters
The asset to update.
AssetChanged| Name | Description | Type | Additional information |
|---|---|---|---|
| Id |
The ID of the asset. |
integer |
Required |
| Name |
The name of the asset. |
string |
Required String length: inclusive between 0 and 100 |
| Identifier |
A name for the asset that must be unique for all assets within a project. |
string |
Required String length: inclusive between 0 and 100 |
| Latitude |
The latitude of the location of the asset. |
decimal number |
Required |
| Longitude |
The longitude of the location of the asset. |
decimal number |
Required |
| ForecastPoint |
A reference to the forecast point assigned to the asset. |
Reference |
Required |
Request Formats
application/json, text/json
Sample:
{
"Id": 1,
"Name": "Port",
"Identifier": "Asset 1",
"Latitude": 0.0,
"Longitude": 1.0,
"ForecastPoint": {
"Id": 10
}
}
application/xml, text/xml
Sample:
<AssetChanged xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/ForeCoastMarine.Core.OAndM">
<ForecastPoint xmlns:d2p1="http://schemas.datacontract.org/2004/07/ForeCoastMarine.Core.Models" i:nil="true" />
<ForecastPointReference xmlns:d2p1="http://schemas.datacontract.org/2004/07/ForeCoastMarine.Core">
<d2p1:Id>10</d2p1:Id>
</ForecastPointReference>
<Id>1</Id>
<Identifier>Asset 1</Identifier>
<Latitude>0</Latitude>
<Longitude>1</Longitude>
<Name>Port</Name>
<ProjectId>0</ProjectId>
</AssetChanged>
application/x-www-form-urlencoded
Sample:
Sample not available.
Response Information
Resource Description
IHttpActionResultNone.
Response Formats
application/json, text/json, application/xml, text/xml
Sample:
Sample not available.