PUT v1/account/metric
Update a specified account Metric
Request Information
URI Parameters
None.
Body Parameters
Information about a new account Metric
UpdateMetricModelName | Description | Type | Additional Information |
---|---|---|---|
AccountID |
KAPTA internal account ID |
string |
Required. |
MetricName |
The name of the Metric you are trying to update |
string |
Required. |
Value |
The new Metric Value |
decimal number |
Required. |
Target |
The Target of this metric (optional) Target will not be updated if null/ommitted |
decimal number |
None. |
ValueDate |
For updating historical values or values for specific dates. If null or not included the current day is used. This should not include time only the Date as these values can only be stored 1 value per day. |
date |
None. |
ResetToDate |
WARNING USE WITH CAUTION! If this value is set to true, then all of the metric data beyond the specified Value Date will be erased. |
boolean |
None. |
Request Formats
application/json, text/json, text/html
Sample:
{ "AccountID": "sample string 1", "MetricName": "sample string 2", "Value": 3.1, "Target": 1.1, "ValueDate": "2025-07-10T05:24:44.6001854+00:00", "ResetToDate": true }
application/xml, text/xml
Sample:
<UpdateMetricModel xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/KAPTA.Domain.ViewModel.v1"> <AccountID>sample string 1</AccountID> <MetricName>sample string 2</MetricName> <ResetToDate>true</ResetToDate> <Target>1.1</Target> <Value>3.1</Value> <ValueDate>2025-07-10T05:24:44.6001854+00:00</ValueDate> </UpdateMetricModel>
Response Information
Resource Description
IHttpActionResultNone.
Response Formats
application/json, text/json, text/html
Sample:
{ "MetricName": "sample string 1", "Value": 2.1, "Date": "2025-07-10T05:24:44.6001854+00:00", "DisplayValue": "sample string 4", "Target": 5.1 }
application/xml, text/xml
Sample:
<MetricModel xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/KAPTA.Domain.ViewModel.v1"> <Date>2025-07-10T05:24:44.6001854+00:00</Date> <DisplayValue>sample string 4</DisplayValue> <MetricName>sample string 1</MetricName> <Target>5.1</Target> <Value>2.1</Value> </MetricModel>