Correct a time series
update_time_seriesCorrect an existing time series by patching only the fields you provide, so wrong data is fixed without replacing the whole record; new rows are validated before saving.
Instructions
Correct a time series you created (PATCH; only the fields you pass change).
Use it to fix a series instead of leaving a wrong one behind. The same
rules as create_time_series apply to new rows (units match the type, a
hydrograph or hyetograph ends at 0 unless hold_last_value, at least 2
rows, no negative rain or flow, not all zero) and Hydrata refuses with the
reason in plain words. A series already used by a built scenario changes the
scenario: it needs a rebuild and the user reviews it again. Returns a compact
record, not the rows.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| data | No | Replacement rows: {"rowData": [{"timestamp": "<ISO 8601>", "value": <number>}, ...]}. Validated here before anything is sent; Hydrata refuses fewer than 2 rows, negative rain or flow values and an all-zero rain or flow series. | |
| name | No | New name (a rainfall polygon binds to its gauge by this exact name) | |
| units | No | New units (must match the series_type, as in create_time_series) | |
| method | No | One short phrase saying how you got the new numbers. Replaces the earlier account. | |
| series_id | Yes | The time series id (from list_time_series or create_time_series) | |
| project_id | Yes | The project ID | |
| description | No | New description | |
| series_type | No | New series_type: hyetograph, hydrograph, stage or generic | |
| hold_last_value | No | Set true only when the last value is meant to be held |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||