Import Trends
Imports trend data into a project, allowing it to be appended, prepended, or merged to overwrite existing records.
POST /v1/import/trends
curl https://api.novant.io/v1/import/trends?mode=append \
-u ak_sample_123: \
-H "Content-Type: text/csv" \
--data-binary @trends.csv
Parameters
mode
-
Configure how data will be imported:
merge
: Compare incoming records against existing timestamps. If a timestamp does not exist, it is added; if it already exists, its value is overwritten with the incoming value.append
: Add new records only if their timestamps are later than the latest existing trend data.prepend
: Add new records only if their timestamps are earlier than the earliest existing trend data.
If not specified, defaults to merge
.
Note: The mode parameter must be provided as a URL query parameter.
Content
The CSV data to import for this request.
Requirements:
- Must set content type header
Content-Type: text/csv
- Must have at least two columns
- The first column must be
ts
- Each additional column must be a point ID to update
- All timestamps must be in ISO 8601 format
- Maximum 50 columns per request
- Maximum 10,000 rows per request
Example:
ts, s.2.5, s.2.6
2025-08-12T04:00:00-04:00, 10, 0.25
2025-08-12T04:15:00-04:00, 15, 0.50
2025-08-12T04:30:00-04:00, 20, 0.75
Returns
Returns ok
if import was successful.
{ "status": "ok" }