We're currently developing a service for fetching realtime currency from a online broker.
The result is a JSON, like this:
My datastore is like this:
When i run ln_rest.retrieve(ln_ds,ls_url), I get error -16 - "The JSON is not a plain JSON with two-level structure".
However, the respons looks exactly like one of the examples in the documentation (The section called "Plain JSON"), and is indeed a two-level JSON.
Brackets and curly braces indicates an array of two objects as far as I know.
So what's the reason why my restclient.retrieve fails?
Note: I works just fine if I collect the responsebody and parse it using the JSONParser object.
Update: it seems that restclient.retrieve() does not support other than string, integer, boolean or null:
"A plain JSON can only contain elements of the following 4 data types: integer, string, boolean, and null."
So I guess the decimal is causing the error message?
If so, that's a really big limit which has to be sorted.
Using PB 2019R3.
Maritech Systems AS
But I will try to modify the response to make the DWO option work as well.
Do you think it's the decimal number causing problems?
Otherwise the JSON looks to be as it should.