Skip to content

docs: a bad timestamp or datapoint value is a 422 - #84

Open
JosteinGj wants to merge 1 commit into
masterfrom
docs/timestamp-and-value-422
Open

JosteinGj wants to merge 1 commit into
masterfrom
docs/timestamp-and-value-422

Conversation

@JosteinGj

Copy link
Copy Markdown
Contributor

What changed on the platform

IntelliStream-DataHub/datahub-platform#125 (errors/14-unusable-values-are-422) gives two kinds of unusable value one answer each:

  • A bad timestamp on the REST API is a 422 of type: ".../errors/invalid-timestamp", retry: change-request, wherever it was sent. It used to be a 400 unreadable-request-body with pointer, line and column (JSON fields such as eventTime and filter bounds), a 400 with fields (datapoint delete window) or a 500 (datapoint timestamp on insert). The acceptance rules are unchanged.
  • A datapoint value that does not parse against its series' value type on POST /timeseries/data is a 422 of type: ".../errors/invalid-datapoint". It used to be a 500.

What this PR changes

  • reference/client.md §Timestamps: the 400 claims and the "same problem document as an unknown field" paragraph are replaced by the 422 and a table of how each place locates the offender (pointer with no line/column, or fields). Scoped to the REST endpoints it applies to; the /analysis window, MCP parameters and file metadata headers are not claimed. The retry table gains a row for both 422 types.
  • reference/events.md §Create: epoch seconds is refused with a 422, not a 400.
  • reference/timeseries.md §Write datapoints: a short table of what POST /timeseries/data refuses (400 malformed body, 422 invalid-timestamp, 422 invalid-datapoint). The bigint note under Value types links to it.

Merge after IntelliStream-DataHub/datahub-platform#125 ships; until then these pages would describe answers the API does not send yet.

🤖 Generated with Claude Code

datahub-platform#125 (errors/14-unusable-values-are-422) answers a bad timestamp
on the REST API with 422 invalid-timestamp (was 400 unreadable-request-body, a 400
with fields, or a 500) and an unparseable datapoint value with 422
invalid-datapoint (was 500). Fixes the 400 claims in client#timestamps and events
Create, and lists both types for POST /timeseries/data and in the retry table.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Signed-off-by: jgjesdal <jostein@intellistream.ai>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant