Use of int64, uint64, float64 in the HTTP API #8319
Labels
kind/bug
A bug in existing code (including security flaws)
need/triage
Needs initial labeling and prioritization
Checklist
Installation method
built from source
Version
No response
Config
No response
Description
The HTTP API docs for
/api/v0/stats/bw
sayRateIn
andRateOut
arefloat64
andTotalIn
andTotalOut
areint64
.They are returned as numbers from the API:
If we need this amount of precision, these should be returned as stringified numbers instead, otherwise some implementations (eg.
JSON.parse
in js) will not be able to parse them, since their native number type does not have enough precision to do so:If they are returned as strings they can be converted into
BigInt
s by client libraries and the correct values will be retained.This applies to the following endpoints:
The text was updated successfully, but these errors were encountered: