Hi Billy... Here is an example: https://github.com/IBM/zOS-Client-Web-Enablement-Toolkit/tree/master/Example-Cobol-AirportService
It doesn't invoke curl... rather it invokes the Client Web Enablement Toolkit part of z/OS: https://www.ibm.com/support/knowledgecenter/en/SSLTBW_2.3.0/com.ibm.zos.v2r3.ieac100/ieac1-client-web-enablement.htm The example parses JSON, but you could just as easily invoke the COBOL XML Parser instead. Here is a link to various COBOL XML Parser examples: https://www.ibm.com/support/knowledgecenter/SS6SG3_5.2.0/com.ibm.cobol52.ent.doc/PGandLR/ref/rpxml27.html Regards, Steve Bohn z Client Architect IBM US, Financial Services Market From: Billy Ashton <[email protected]> To: [email protected] Date: 12/06/2019 08:19 AM Subject: [EXTERNAL] COBOL call to Curl function and XML handler Sent by: IBM Mainframe Discussion List <[email protected]> Hello friends, I have a new project to handle, and I am way out of my league. There are two questions here: 1. Does anyone have a COBOL program that makes a call to the Curl function to pass in a website URL, and receive back the html data? If so, would you be good enough to share the particulars of doing this? 2. Once I have the html data back, I need to process it. This data is an XML document, and can be between 300 and 1500 lines. Does anyone have a COBOL program that will allow me to query this XML document to get specific tag data, or to process the XML document in general? I read through the IBM doc, but I think my brain is full of egg nog this morning, as I did not really understand how to code and compile this functionality. I am grateful for your direction and your code samples to help me take a bold step into the 20th century! :) Thank you lots! Billy ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to [email protected] with the message: INFO IBM-MAIN ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to [email protected] with the message: INFO IBM-MAIN
