skip to Main Content

How to parse JSON response from rest request without name of root element in java

I got a response to my request: [ { "data":{ "channel":{ "id":"708087644", "__typename":"User" } }, "extensions":{ "durationMilliseconds":112, "operationName":"ViewerCardModLogsMessagesBySender", "requestID":"01GWVKPD13BQGBZS64TY4824B9" } } ] I am trying to create a Java class where I can parse this response: ResponseEntity<RestResponse> result = restTemplate.postForEntity(uri,…

VIEW QUESTION

read html as string and encode in json format – PHP

I have this function to read html contents function patient_file(){ $html= ''; $html .= '<table style="width:100%; padding:0; margin:0; color:rgb(50,50,50); "> <tr><td style="width:17%"><b style="color:rgb(150,150,150)"> Fullname</b> </td><td> salum said juma</td></tr> <tr><td><b style="color:rgb(150,150,150)"> Age / sex</b> </td><td> 12 male </td></tr> <tr><td><b style="color:rgb(150,150,150)"> Address</b>…

VIEW QUESTION

Json – C# Not able to post data using HttpRequestMessage and getting 400 status

I tried a few different ways I can't get pipelineId to post (receive 400), see code below: { client.BaseAddress = new Uri(_serviceConfig.DataGapsBaseUrl); var request = new HttpRequestMessage(HttpMethod.Post, "/piper/jobs"); var jsonContent = new StringContent(JsonConvert.SerializeObject(new { pipelineId = _serviceConfig.DataPipelineId }), Encoding.UTF8, "application/json");…

VIEW QUESTION
Back To Top
Search