cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
392
Views
0
Helpful
3
Replies

How do i generate XML using Excel attendee & Meeting files ?

moses.yesunathan
Beginner
Beginner

Hi all,

I have an application which only reads XML files sample resonse file format is given below, but now am unable to generate the XML file as the WebEx site is inactive and terminated, but i have the attendee and meeting reports generated in CSV which has all the information needed

to generate the below XMLs.

The two API calls used below are

Attendees: history:lstmeetingattendeeHistoryResponse

Meetings : history:lstmeetingusageHistoryResponse

how do i generate an XML from the excel files in the below format ? help please

ns3:message xmlns:history="http://www.webex.com/schemas/2002/06/service/history" xmlns="http://www.webex.com/schemas/2002/06/common"xmlns:ns3="http://www.webex.com/schemas/2002/06/service" xmlns:user="http://www.webex.com/schemas/2002/06/service/user">

<ns3:header>

<ns3:response>

<ns3:result>SUCCESS</ns3:result>

<ns3:gsbStatus>PRIMARY</ns3:gsbStatus>

</ns3:response>

</ns3:header>

<ns3:body>

<ns3:bodyContent xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="history:lstmeetingattendeeHistoryResponse">

<history:meetingAttendeeHistory>

<history:meetingKey>593091386</history:meetingKey>

<history:confName>MRO Integrator Program- Management review</history:confName>

<history:ipAddress>206.48.240.167</history:ipAddress>

<history:clientAgent>WINDOWS,IE</history:clientAgent>

<history:name>Chan</history:name>

<history:email>chan.@.com</history:email>

<history:joinTime>07/02/2012 19:58:46</history:joinTime>

<history:leaveTime>07/02/2012 20:02:46</history:leaveTime>

<history:duration>4</history:duration>

<history:participantType>ATTENDEE</history:participantType>

<history:voipDuration>0</history:voipDuration>

<history:confID>100967****</history:confID>

</history:meetingAttendeeHistory>

<history:meetingAttendeeHistory>

and the next file is

<ns3:message xmlns:history="http://www.webex.com/schemas/2002/06/service/history" xmlns="http://www.webex.com/schemas/2002/06/common"xmlns:ns3="http://www.webex.com/schemas/2002/06/service" xmlns:user="http://www.webex.com/schemas/2002/06/service/user">

<ns3:header>

<ns3:response>

<ns3:result>SUCCESS</ns3:result>

<ns3:gsbStatus>PRIMARY</ns3:gsbStatus>

</ns3:response>

</ns3:header>

<ns3:body>

<ns3:bodyContent xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="history:lstmeetingusageHistoryResponse">

<history:meetingUsageHistory>

<history:sessionKey>5958266**</history:sessionKey>

<history:confName>- RAPID CHANGE</history:confName>

<history:meetingStartTime>07/02/2012 05:51:18</history:meetingStartTime>

<history:meetingEndTime>07/02/2012 06:23:37</history:meetingEndTime>

<history:duration>33</history:duration>

<history:timezone>GMT+10:00, Australia Eastern (Brisbane)</history:timezone>

<history:trackingCode>

<trackingCode1>Rio Alcan</trackingCode1>

<trackingCode2>76127**</trackingCode2>

<trackingCode3>320 57**</trackingCode3>

<trackingCode4>7081**</trackingCode4>

</history:trackingCode>



3 Replies 3

mifierro
Enthusiast
Enthusiast

Greetings, Moses! If I understand your question correctly, you are trying to take the output from the WebEx API requests and parse out the responses into an XML document you can then import into another application? Or convert to a .csv file?

If this is the case, then you would need to do this in whatever programming language you are using - i.e. this isn't something you can do directly from the API. You would basically be creating a filter that would take a returned record and parse out the values, dumping them into variables. In psuedocode, this would be:

  1. Get first return record from the WebEx API response
  2. Search for <history:confName>
  3. Put value into local variable strConfName
  4. Loop back to get the next record

You would then use your programming language to write that data out in whatever format you need. Most programming languages have libraries available to help write in XML or CSV formats.

I am not certain what you mean by "the WebEx site is inactive and terminated". If my answer above did not provide the information you need, then let me know what you meant with that statement.

--

Michael Fierro   ●  .:|:.:|:.

Customer Support Engineer

Cisco - API Developer Services

Hi Michael,

Thanks for your response, I have two Excel reports from a site that was terminated/contract ended site,

The two excel files contain Meeting info and the Attendee , i need them in the XML format to load into my application,

my application is built to read XML files in the format for meeting :"history:lstmeetingusageHistoryResponse" and for

Attendees: history:lstmeetingattendeeHistoryResponse

My concern is here is there a way i can put these 2 excel files ie Meeting and Attendee and get the XML files in the format of API Response : lstmeetingusageHistoryResponse & lstmeetingattendeeHistoryResponse

In this case, you would basically do the same thing that I mentioned above, but in reverse. The algorithm would be:

  1. Create a string constant that you can use as a template. It might look something like:
      "<history:meetingKey>$intMeetingKey</history:meetingKey>\n<history:confName>$strConfName</history:confName>"
  2. Read a line in from your csv/input file
  3. Break the fields up into appropriate variables ($intMeetingKey, $strConfName, etc)
  4. Construct a string with the variables added in the correct locations in your template string
  5. Write this string out to an XML library or directly to a file

As long as you are certain to add in the fields that your other application requires, this should be feasible.

Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community:

Recognize Your Peers