JS object literals are not JSON
JavaScript allows trailing commas, single quotes, unquoted keys, comments, and undefined. JSON does not. Copying an object from source into an API body is the usual way people get stuck.
Trailing comma
{
"id": 12,
"name": "order",
}
Drop the last comma. Same for arrays: [1, 2, 3,] is illegal in standard JSON.
Quotes and comments
{'name': 'test'} and {name: "test"} both fail. Keys and strings use double quotes. // comments belong to JSONC, not JSON.
NaN, Infinity, undefined
JSON.stringify turns NaN / Infinity into null and drops undefined keys. Some servers still emit literal NaN, which will not parse.
Several objects in a row
That is JSON Lines, not one document. See JSONL logs.