calvin peters 3/13/2023 1:22:38 PM >> Whats the difference between the XML, Json, Text Currencies?
Those are just the way data is packaged for retrieval. XML loks alot like HTML coding...data values inside tags read like an information tree <basic_data> <oem_body_style>Cargo Van</oem_body_style> <doors>3</doors> <oem_doors>3</oem_doors> <model_number>VF2L13</model_number> <drive_type>FWD</drive_type> <brake_system>Hydraulic</brake_system> <glider/> <chassis_type/> </basic_data>
Tags are open <...> and then closed</...> Everything between the two tags is referenced using the id inside the tag.. using Response() function in ASSIGNMENTS section like:
FROM: If(Response("drive_type")="4X4","4WD",Response("drive_type")="4X2","2WD",Response("drive_type")) TO: [your column name] So this looks in the tag <drive_type> shown above and the formula If(...) conditionally rolls over the conditions inside to either put "4WD", "2WD" or in this case "FWD" into [your column name]. If I wanted data for "doors" stored in my column then Response("drive_type") would become Response("doors") and the surrounding formula would do the rest for 'normalizing' it for my use case.
JSON is a different way of storing and referencing data with key:value pairs. So in simple terms a 'key' is the reference for the 'value' you want to reference. [ { "Id": "XXXCVBG", "Code": null, "Digit": "35DJG", "Year": "2016" } ] So in the top line key:value pair, the 'key' is "id" and it's 'value' is "XXXCVBG"
But the response is still handled in the ASSIGNMENTS section.
TEXT is just another data type to be dealt with.
Use Response() function inside your CallURL to map the reponse data to your column in your db. <%=...%> are used to allow reference to various functions and formulas to help manipulate your reponse using TD.
The data type you get returned is determined by the API for your source data...so different Google open source API's for example.
It appears that the db that example is aimed at has been depricated but the setup should help you understand this better.
Your db should have an "Integration API" link in your DATABASE tab in SETUP mode where you can use the builtin REST API Playground to experiment with some of this stuff to better understand it.
Also, the TeamDesk support is an absolutly invaluable resurce for assistance. Can't say enough about the team there. They have performed wonders in assisting me and they have never left me wanting when called upon. Simply the best support team I've encountered.
Tell them where you're stuck and they will lean in hard (in my experience anyway). They want you to succeed and they're there to help you do that.
Best of luck
|