xml2js to take my xml result so that i can access the values. I am having some problems trying to access GetProvidersResponse and iterate through GetProvidersResult and Providers. How can I access these items?
{ 'xmlns:s': 'http://schemas.xmlsoap.org/soap/envelope/' }
{ GetProvidersResponse:
{ '@': { xmlns: 'http://www.kareo.com/api/schemas/' },
GetProvidersResult:
{ '@': [Object],
ErrorResponse: [Object],
SecurityResponse: [Object],
Providers: [Object] } } }
when i try console.log(resultObject.GetProvidersResponse) i get undefined.
I used the fallowing console.log(result['s:Body'].GetProvidersResponse.GetProvidersResult.Providers.ProviderData[0]);
and was able to see the data.