Questions tagged [json]

JSON (JavaScript Object Notation) is a textual data interchange format and language-independent. Use this tag when this text format is involved. DO NOT USE THIS TAG FOR NATIVE JAVASCRIPT OBJECTS OR JAVASCRIPT OBJECT LITERALS. Before you ask a question, validate your JSON using a JSON validator such as JSONLint (https://jsonlint.com).

0
votes
0answers
2 views

Data dump Import multiple json links that have multiple rows

So i have a list of items that i want to get the information off, those items return a table with multiple rows, overlapping the next row of importJSON(). How should i go about getting all the ...
0
votes
0answers
5 views

Chrome extensions do not respect browser_specific_settings

The W3C Browser Extensions Community Groups has been working for a while on compatibility between browser extensions on different platforms (Chrome/Firefox/Edge/Opera/Etc.). They have a list of keys ...
-1
votes
0answers
16 views

Can u help me with sending a json error 400?

My problem is that i need send a Json to server but all time when i call the method say me error 400. I dont know what to do. I used postman and the json is correctly created. I use the library ...
1
vote
1answer
19 views

Get a specific value of JSON data

I'm getting a JSON data from RESTCONF HTTPS request, using the following code. https_request ='https://' + host + '/restconf/data/' + operation headers = {'Content-type': 'application/yang-data+json'...
1
vote
2answers
16 views

API working only in one condition - using laravel

I am creating API my controller code: public function isUserGroup(Request $request) { $id = $request->input('id'); $isGroup = $request->input('isGroup'); if($isGroup == false) {...
0
votes
0answers
11 views

How to readrecords from Json Array

I try to use Javascript Ext libraries and call a rest service which returns a json response. Its an array with one element and it doesnt work when i use DataReader(Ext.data.DataReader) "readRecords" ...
0
votes
0answers
12 views

Issue converting KeyPoints to and from JSON and then using FlannBasedMatcher

I'm saving my KeyPoints and Descriptors in a JSON file. Later when I retrieve them, I am trying to use them in a FlannBasedMatcher. However, I think something is going wrong in the conversion because ...
0
votes
0answers
6 views

How i can query in mongoose to get the “answers” array where 'objective' inside the 'answers' array is “Awareness”

this is my mongoDb strucure I'm trying to get the list of 'answers' from "Response" mongoDB using mongoose in nodeJS where the 'objectives' array contain 'Awareness' and specific 'projectId' also. But ...
0
votes
0answers
7 views

How to solve json unclosed string error in UN comtrade

When I was using UN comtrade api offered online: https://comtrade.un.org/Data/Doc/api/ex/r, I encountered an error. I was sending multiple requests to get the data - it all worked fine but the for a ...
0
votes
1answer
44 views

How do I format a one line JSON string

I'm creating a GUI in Visual Studio which is going to fetch JSON data from an API to display in a text box, and I want it to be displayed formatted so it's readable. I have tried to use the ...
0
votes
0answers
22 views

Why does JSON.parse empty the filed? [duplicate]

After I use JSON.parse some field gets empty string value. I get the data using localStorage.getItem("letter_" + i); Then we have: {"id":2,"body":"heyyy","attachfilephoto":"","...
-4
votes
0answers
36 views

Send JSON request using Java [on hold]

I have an existing jar file where a SOAP webservice call is made to third party system by using the below code HttpURLConnection localHttpURLConnection = (HttpURLConnection)localURL.openConnection();...
1
vote
1answer
45 views

Removing JSON children by key in PHP

My goal is to have a function that can remove a specified json child, which could also be nested inside deeper. My function looks like this: private function removeJsonChild(String $jsonKey, String $...
0
votes
1answer
6 views

ServiceNow REST POST create WorkNote format text

Setting my Request Body request.setRequestBody("{\"work_notes\":\"After the Comma,\\\\nNew line\"}"); I try to create a work note while creating an Incident. So far this works but I have problems ...
0
votes
0answers
14 views

How to compute the final result from Json Array using “and” operation is applied on it

I have a json file containing array , AND operation is applied on array . I need to compute the final result from a array based upon the operation . Json Array { "op": "and", "tok": [ ...
0
votes
0answers
25 views

How do I extract each bit from json frame?

I'm a beginner and don't know much about java script and PHP. I need to extract data i.e single bit from JSON frame received and accordingly update that each bit in my HTML webpage table.What function ...
0
votes
0answers
12 views

Serializing Doctrine's collection with custom key

I'm using JMSSerializer to serialize a Doctrine's entity collection into json. As expected, the result is something like this: data: [ { "id":1, "title":"Entity 1" }, ...
-1
votes
0answers
35 views

How to Expand JSONObject Size?

I am working with web services in Android. This web services return JSON data and I am parsing them. But, I have a problem. Now, I had 4810 object in JSON. When I am parsing this JSON, i just take 211 ...
-1
votes
2answers
24 views

Serialize Json file with separate list and object

I have a JSON file with 2 object-array of strings,and a string. and I need to serialize it, so I will have the ability to have 2 different object, that each contains 1 object from the JSON file, or ...
-1
votes
1answer
25 views

How to pull data from JIRA using JS?

I want to pull the Data from my JIRA account using JS, as I want to automate a thing i.e. Time Tracking. It will track the time whether the existing resources have sufficient time/bandwidth to ...
-1
votes
0answers
19 views

apostrophes or ampersand causing error in MySQL

When I try to enter the following data into the database, these characters create problems: & (\u0026) and ' (\u0027) { "Id":5507542,"Name":"Port \u0026 Company® - Youth 50/50 Cotton/Poly ...
0
votes
1answer
30 views

How do I get retrieve a specific value inside an array? [duplicate]

I have the following array from a json response: { "countList": [{ "count": 6, "paramToGroup": [{ "name": "severity", "value": "HIGH" }] }, { "count": 1, "...
1
vote
0answers
16 views

convert the following json to csv

there's 3gb JSON data which I want to convert it into CSV format using python. But the piece of code which I have written converts the data to CSV but stores it in a single cell. I don't want the "...
0
votes
0answers
13 views

Ignore empty lists in jaguar serializer in Flitter

Currently there is a way to ignore json keys that have null values from Jaguar Serializer https://github.com/Jaguar-dart/jaguar_serializer. However, I could not find a way to ignore empty lists. Is ...
0
votes
0answers
30 views

How to create a struct with json format in golang

I am trying to create a dynamic loop from this json format, which i can filter out like waypoint in index 0,1,2 and other info such as land, yaw and speed. I have been trying to do this this struct ...
-2
votes
0answers
35 views

Tree structure using recursion in angular 6

I have this type of json and I want tree structure using recursion in angular 6. I can't change the json format I have to create another component for recursion. I have tried using for loop and also ...
0
votes
1answer
26 views

Using the JSON response from 3rd party api with geodjango

I am try to create a way to narrow down posts on a django app by location & radius. The way I am trying to do this is: Use 3rd party (OpenCage) API to convert location to lat / lng Gather the ...
0
votes
2answers
40 views

parsing json list

I have this json object, am I am trying to parse to get the location from location_info there is an ID, and a written name. { "data": [ { "id": 419, "language": 1, "size": "25.8 MB", "title": "...
0
votes
0answers
12 views

nested Json validation with jsonAssert using regular expression

I need to validate the rest assured response that has nested json against regular expression { "user": { "id": "\\d+", "name": "^((?:[A-Za-z]+ ?){1,3})$", "requires2fa": "true|false" }...
0
votes
0answers
18 views

How to import JSON data into a bulk cell in SQL from a REST API URL

I want to download JSON data from a REST API URL directly into SQL Server. I currently open the URL in a browser and copy the JSON data into a .json file which I save locally, then import using the ...
0
votes
0answers
16 views

Load json data from URL to apexcharts [duplicate]

I'm creating simple apexchart fro my application. for display data using apexcharts, I used category paired values. I tested the charts by hardcoding my JSON values on my HTML file and it works below ...
0
votes
1answer
25 views

Extract nested dict value with conditions from JSON using JINJA2 in Ansible

I'm trying to extract the CDN domain name for a specific Alias from Ansible's cloudfront_facts, with the following (summarized) output: { "cdn_facts": { "ansible_facts": { "cloudfront": { ...
5
votes
3answers
42 views

Json value in Null hot to catch Javascript exception

I get data json throw ajax from action-struts 2 for my view. some data set of data. Example {"home":"1234","room": null}. I can read data.home, and I get 1234 value, but when I try read data.room, ...
0
votes
0answers
9 views

Dart/Flutter: build_value vs json_serializable

Wondering what is the different between the dart libraries build_value vs json_serializable ? both appears to be doing the same thing.
0
votes
0answers
16 views

How can I perform a certain action if and only if a specific CheckBox is checked, from a separate class, at runtime?

I'm writing a program that takes a JsonFile as input and parses/sorts it before printing the result. The result is an array of JsonObjects, each JsonObject with its list of KEY_NAME's and their ...
0
votes
1answer
25 views

java.net.SocketException: socket failed: EPERM (Operation not permitted)

I am working on an Android Studio project with several activities. I am currently trying to read the output from a Java Servlet on localhost but it seems to be crashing due to a socket permission. I'...
0
votes
1answer
11 views

Difference between JSON line and Document Type

can Someone help me to understand what is the difference between JSON Line and JSON Document Type? Can someone Provide me an example of the same? I am trying to build a JSON parser. I have tried to do ...
0
votes
0answers
14 views

After deployment, can I update the Angular website content by editing the .json file in the assets folder?

I am building a website for my lab with Angular 7. For the easier update, I put the data of a list of news in assets/data/news.json and bind the data to the webpage. It works well when running with ng ...
0
votes
0answers
12 views

i want to access contact_id in a json decode data [duplicate]

please someone should help me on json and php i want to access contact_id in a json decode when you run the above code it show CONTACT REGISTERED - OK - REGISTERED .. { "result": "CONTACT ...
1
vote
1answer
19 views

Backend only accepts plain text, no JSON and only a name not an id

So I want to send data to the backend in JSON format. The user has to select an option from the datalist and a id and name will be sent to the REST server. When I send the id and name of the selected ...
0
votes
1answer
17 views

Fixing “TypeError: '_io.TextIOWrapper' object is not subscriptable” in python script

I'm trying to store some data in a config.json for a bot that I'm working on, but I keep getting the same error every time I attempt to run it. I'm running Python 3.7.3, latest version of the rewrite....
-1
votes
0answers
33 views

How to handle quoted parts for JSON values in Python

I have a Key Value Pair in JSON Format like this: {"companyName":"WBG "Glück Auf" Gera eG"} Since I crawled the data I can't even provide an exmaple, because Python doens't accept file = {"...
1
vote
2answers
14 views

Get particular values from a string in hive

I have a hive table with two columns both are strings name details "john" , {"addr":"NY","phone":"1234"} "john" , {"addr":"CA", "phone":"7145"} "mary" , {"addr":"BOS","phone":"1234"} Is ...
0
votes
1answer
14 views

Pass data (JSON) from class C # to JS- ASPX

I have a webforms in which I am passing data and I convert it to JSON in the following way: protected void enviarDatos_Click(object sender, EventArgs e) { string nombre = ...
0
votes
1answer
11 views

php file returning error converting to JSON for android GET request

I've successfully setup retrofit 2 in android studio. The app displays the following error when doing a GET request to the mysql database via the php file. expected begin_array but was string at line ...
-3
votes
0answers
30 views

How to create PDF file from JSON data using PHP

I am using PHP and FPDF library as shown below: <?php require('fpdf.php'); require('JsonPDF.php'); $document = array('body' => array(array('type' => 'text', 'width' => 40, 'height' => ...
0
votes
1answer
9 views

VS Crashes when using T-SQL OPENJSON and SELECT *

When using the below code the VS 2019 crashed without fail. Though it was originally working, possibly prior to a recent update (or upgrade to VS 2019 from VS 2017) The error message implied a too ...
0
votes
1answer
10 views

how to get the JSON out of the jackson ObjectMapper

We need to bulid up a json payload to send to a rest endpoint. Our org uses Jackson. The only way to build up the json (without creating dozens of nested empty pojos) is as follows: ObjectMapper ...
0
votes
0answers
10 views

Random number generation in mongodb within a range

I have a collection in which I want to add a new field and in that field i want to randomly assign values between 1 and 44 in mongo db. I have already tried math.random() which is not working. { $...
1
vote
1answer
22 views

“TypeError: Object of type bytes is not JSON serializable”

Trying to dump a dictionary in a JSON file gives me the error "TypeError: a bytes-like object is required, not 'str'" I already tried to remove the bytes conversion part of the "encrypt_string" ...

http://mssss.yulina-kosm.ru