Questions tagged [xml-to-json]
82 questions
8
votes
1 answer
Alternative to deprecated XmlJsonDataFormat in Apache Camel
In Apache Camel, I was trying to use XmlJsonDataFormat to do a quick conversion from XML to JSON. However the XMLJSON (http://camel.apache.org/xmljson.html) has deprecated so I am not sure what is the best way to do that conversion aside from…

namp10010
- 123
- 1
- 10
6
votes
0 answers
Swift Convert XML to JSON
Is it possible to get a JSON var from XML on swift?
I already get xml values with alamofire and SWXMLHash with the below code, but requirements said I must convert it to JSON, is there a way to achieve this?
Alamofire.request(strURL, parameters:…

kary22
- 61
- 2
- 2
3
votes
3 answers
XML to Json without array name c#
I have following xml file
cynthia48@example.com
Louis Hebert
South Dakota
item1
…

Ayan Ahmed
- 31
- 2
3
votes
1 answer
How to convert XML to AVRO based on the Avro Schema?
I have a structured XML data. I want to convert this XML to AVRO(or JSON) using AVRO schema. I've defined the AVRO schema for this XML. But how can I convert it in java?
Actually, I want to convert received xml data from the server to the JSON/AVRO…

ago
- 59
- 2
- 8
2
votes
1 answer
JSON to XML in go lang
Hi I am trying the below code in go lang, where i have to change a json data to xml and pass it to another service. Below is the function that i tried for json to xml conversion
package main
import (
"encoding/json"
"encoding/xml"
…

Sindhu1990
- 85
- 6
2
votes
1 answer
MarklLogic json:transform-to-json throws 'null' when element name is 'name'
When using json:transform-to-json with "custom" config, the value of my element is transformed as "null". Instead, I expect the text of the element to be displayed.
import module namespace json="http://marklogic.com/xdmp/json" at…

maifosz
- 55
- 6
2
votes
2 answers
How to convert the http get response from html to json format (from kaggle.com)
I tried below code to get a http response from kaggle.com.
Kaggle response is in html format and I wanted to convert it to json format for the ease of further processing.
import requests
import json
username = 'vgtgayan'
base_url =…

V.G.T. Gayan
- 25
- 1
- 6
2
votes
0 answers
Python3 : How to handle xml contain binary string when convert to Dictionary
I'm in a scenario that get XML data from the file and parse it into Dictionary but inside the XML data is contain some value like binary
"%¢a÷ó<·RxgТ'gÎ&"
then I got the error :
parser.Parse(xml_input, True) xml.parsers.expat.ExpatError:…

Sidara KEO
- 1,693
- 1
- 14
- 34
2
votes
1 answer
How to convert XML to JSON in reactjs?
How to convert XML document to JSON using reactjs? I got response shown down below. I tried a lot of things and still nothing.
import React, { useEffect } from 'react'
function Api() {
useEffect(() => {
…

Marina
- 187
- 1
- 3
- 19
1
vote
0 answers
JAXBContext not working in Java 17.0.3 (It was working in java 11)
JAXBContext jaxbContext = JAXBContext.newInstance(Instances.class);
Unmarshaller unmarshaller = jaxbContext.createUnmarshaller();
Instances instances = (Instances) unmarshaller.unmarshal(new File("test.xml"));
…

Utsavi
- 11
- 2
1
vote
1 answer
Data Fusion for xml-to-json transformation: "+ExitOnOutOfMemoryError" and "exited with a non-zero exit code 3. Error file: prelaunch.err"
When transforming an xml file to json, the Data Fusion pipeline, configured in Autoscaling mode up to 84 cores, stops indicating an error.
Can anybody help me to make it work?
The 100-pages Raw log file seems indicating that possible errors…

Mauro Di Pasquale
- 13
- 2
1
vote
0 answers
XML to JSON Array Conversion using XSLT
I have a scenario where in I am trying to convert the following XML:
1023
1542
30
Mr
…

megrao1811
- 21
- 2
1
vote
0 answers
Liquid Mapping for conversion from xml to json
I have this xml part of Data:

F22
- 11
- 3
1
vote
1 answer
Massaging XML to JSON output for front-end parsing
Using the xmltodict (v0.12.0) on python, I have an xml that will get parsed and converted into a json format. For example:
XML:
This is a test
Will get converted to the following json:
"test": {
"@temp":…

Sean Mullarkey
- 11
- 2
1
vote
1 answer
Policy XML to JSON in Azure APIM not converting to proper JSON format
i am consuming wcf service which returns XML response, in Azure APIM i am transforming those into Json response by using the below APIM policy
It works fine until i get xml…

Ranjith Marutharaj
- 11
- 2