Question Emil Odobasic · Mar 5 Is it possible to receive an HTTP/REST request into a production, and send the request as it is in another request? If yes, what would be the best way to do this? Hello everyone!So, I am supposed to receive a REST-request into my production, and I need to send it, exactly as I received it, to another server.I am struggling to find any good info on this, and have a hard time coming up with a good approach.What would be the easiest way to do this?- I have so far thought about possibly doing it with an EnsLib.REST.GenericService and then sending it with an EnsLib.REST.GenericOperation. #Business Operation #REST API #Ensemble 1 4 0 210
Question Emil Odobasic · Feb 15 How can I transform a String, which is a numerical value, to an Integer? Hello everyone!I need to transform a String, which is a numerical value, to an Integer.The value gets returned in my Rest service as "testingID": "1234567", but I need it to be "testingID": 1234567 Thanks beforehand! Appreciate all the help I can get! :) #Code Snippet #ObjectScript #Caché #Ensemble #HealthShare #InterSystems IRIS 0 5 0 287
Question Emil Odobasic · Jan 8 How can I read multipart/form-data from a HTTP Post request in my rest service? Hello everyone!I am receiving a HTTP multipart/form-data request into my rest service.How can I read the values for each Key in the form?The key "Profile" is sent to my service as a String data type.The code I have below does not seem to work, where I try to read the Key profile in the form. I appreciate all the help I can get! :) #ObjectScript #REST API #InterSystems IRIS 0 26 0 590
Question Emil Odobasic · Dec 20, 2023 How do I retrieve Data from Form-Data from a REST HTTP-request in a REST-service? Hello everyone!I am wondering how I can retrieve multipart form-data from a request that is coming into my REST-service.I am supposed to retrieve a string and a file. The file is being retrieved without issues, but the "testprofile" string is not being retrieved at all.It just logs a an empty entry. The request that is sent to my REST-service has the Content-Type: multipart/form-dataThanks beforehand for the help! :) Down below is the code I use right now to retrieve the string and file from Form-data Rest HTTP-request to my service. #ObjectScript #REST API #InterSystems IRIS 0 5 0 535
Question Emil Odobasic · Dec 14, 2023 How can I send a file through Form Data in a REST HTTP Request? Hello everyone!I have to build a REST service that receives a POST HTTP-request, collect a file from that request in the Form data and then send it in another HTTP Post request through Form Data. However I can't really seem to send the file, and I do not know where it has gone wrong. All I am getting told is that no file is being received from my HTTP Post request. I am reaching the REST Service I am supposed to send the request to, but nothing is being sent. #JSON #ObjectScript #REST API #InterSystems IRIS 0 6 0 600
Question Emil Odobasic · Nov 29, 2023 What would be the best way to import a very large XML-file into a production, modifying it depending on certain conditions, and creating a new XML file? Hello everyone!Sorry for the vague title! But I wonder what would be the best way to easily import a large XML-file into a production, modifying it by deleting elements and nodes depending on what values are in those nodes/elements and later creating whole new XML-file from that? I have gone through this: Using Caché XML Tools | Caché & Ensemble 2018.1.4 – 2018.1.8 (intersystems.com) #ObjectScript #XML #InterSystems IRIS 0 5 0 358
Question Emil Odobasic · Nov 27, 2023 How do I access value in a specific node/element in an XML-file? Hello!I am trying access each "name" tag in the xml-file down below and want to display them through the trace in the production: <?xml version="1.0"?><staff> <doc type="consultant"> <name first="David" last="Marston">Mr. Marston</name> <name first="David" last="Bertoni">Mr. Bertoni</name> <name first="Donald" last="Leslie">Mr. Leslie</name> <name first="Emily" last="Farmer">Ms. Farmer</name> </doc> </staff> #ObjectScript #XML #InterSystems IRIS 0 2 0 311
Question Emil Odobasic · Oct 10, 2023 Question how to get JSON-response back to web-service/client Hello everyone!I have manually created a REST-service that receives incoming HTTP-GET calls together with an URL-map. As shown below: #ObjectScript #REST API #InterSystems IRIS 0 6 0 320
Question Emil Odobasic · Sep 6, 2023 Question if it is possible to receive a REST call to an EnsLib.HTTP.InboundAdapter Hello everyone!I need to build something that will receive a REST request. As of now I have tried my luck with using an EnsLib.HTTP.InboundAdapter. But i am not so sure how I am supposed to configure it to be able to receive the REST request together with the JSON body.I have specified the OnProcessInput in the adapter so that it receives a GlobalCharacterStream. However, I have not had any good luck finding out to actually make the request to the EnsLib.HTTP.InboundAdapter. #REST API #Ensemble #HealthShare 0 8 0 296