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).

Filter by
Sorted by
Tagged with
0
votes
0answers
6 views

codeigniter ajax json validator with form Form Validation

I am trying to make ajax form validation work in codeigniter. if you have the same title don't add The data from the form always reports as successful. Even if the result is negative.Is there a ...
0
votes
0answers
4 views

Sending an image with Dialogflow to Whatsapp user

Since a few days I develop a chatbot for Whatsapp using Dialogflow, Twilio and Heroku to host my NodeJS server. I only use free services. What I want to do is to return a gif to a user. For example, ...
0
votes
0answers
9 views

Access nested items on a dictionary ansible

I have a json file with server information and the applications related. Something like this: { "Apps": [ { "AppOwner": "Me", "AppNm": "Vacations" } ], "Hostnm": "some_server"...
0
votes
0answers
9 views

combining small nested/unnested json files

i am trying to find ways to combine multiple small json files of 1 or 2 kbs or so . the data is in the form of a json file that has multiple records in nested or unnested forms . the s3 bucket which ...
0
votes
0answers
16 views

Generate a new JSON file from an api with a json response and update few keys and few values c#

Hi following is the sample json response from my api, i want similar structure of json but few key names updated and few values updated and removed. and in few cases i need to append it from multiple ...
0
votes
0answers
15 views

JSON Error: Cannot login the android apps

everyone. Current I developed a system that requires the user to login. I use Android Studio (JAVA) to code the apps and PHP to connect from apps to MySQL database. Before the error happened, I use ...
0
votes
0answers
6 views

Recursively Slicing JSON into Dataframe Columns

I have a dataframe with a column containing JSON in the format, where one record looks like - player_feedback {'player': '1b87a117-09ef-41e2-8710-6bc144760a74', 'feedback': [{'answer': [{'id': '1-...
0
votes
1answer
11 views

How to render prettified JSON in C# Razor templates?

I am trying to render formatted JSON as HTML using Razor Templates. I am currently trying to do it like this: <div> <pre> @JsonHelper.SerializeObject(item.AttributeValue, new ...
0
votes
0answers
10 views

Azure Stream Analytics Query Returns 0 rows

I have data coming in from KEPServerEx with nested lists, so I need to CROSS APPLY to send individual values to my blob from the incoming stream. I had the query working for a few minutes utilizing ...
-1
votes
1answer
32 views

Why do I get an md5 hash mismatch when both strings being compared are identical?

I am working on a C# program that uses md5 hashing. A file is created using an older version of the program and the hash is saved in a field in the file. Here is a code snippet showing the saving of ...
0
votes
0answers
5 views

Spark: Handling null values inside JSON Array field

Im loading the below JSON data. Assume this is deserialized string from Kafka. {"message":{"title": {"titleid": "111", "titlename": "AAA", "titledesc": null}, "customer": {"customerDetail": {"...
-3
votes
1answer
26 views

Nested json in vue

I have some api <script> export default { props: ["user"] } </script> and nested json in it user:{game:{kills,matches,deaths}} How can get matches? {{user.game.matches}} doesn'...
0
votes
0answers
7 views

HTTP GET response- Uncaught SyntaxError: Unexpected token o in JSON at position 0

I am making HTTP GET request to a backend server and depending on the status of the response from this request I am mapping the data from another request. When in local, there is no problem running ...
0
votes
0answers
33 views

json_decode returns null and json_last_error returns JSON_ERROR_UTF16 (error 10)

I've seen a lot of "json_decode returns null", and even with emoticons... but none of the hints work. Note that I can run the string through a JSON pretty printer, and see no errors (knowing the PHP ...
-3
votes
0answers
22 views

Parse the JSON data [closed]

{"sensor_info":{"sensor1":"temperature","sensor2":"pressure","sensor3":"humidity","sensor4":"density", "measurement_time":"03"}, "sensor_data":[{"measurement_time":"01","entry_id":1,"sensor1":"28","...
0
votes
4answers
39 views

How do I extract a list item from nested json in Python?

I have a json object and I'm trying to extract a couple of values from a nested list. Then print them in markup. I'm getting and error - AttributeError: 'list' object has no attribute 'get' I ...
0
votes
1answer
15 views

jQuery Object rewrite itself at the second turn of loop

I have an object with 2 rows of 4 inputs like color, size, price and quantity. I want to put it in one array or json object like: {"0":{"color":"black","size":"S","price":"10","quantity":"15"},"1":{"...
0
votes
1answer
19 views

How to slow down the milliseconds between my json calls?

I'm using this script to call a few hundred endpoints at Seatgeek. To avoid having Seatgeek throttle me for over-usage, how do I slow down the milliseconds between each call? I only need the call to ...
0
votes
1answer
9 views

Ansible, can't save stdout as variable

Having following ansible playbook for retrieving ceph pool configuration, number of pages. Output stored at JSON, problem that I can't store/retrieve only stdout values. Idea is to use stdout values ...
0
votes
1answer
19 views

C# query basic BSON knowing only key and values using LINQ

I have MongoDB collection from which i would like to query documents knowing only names of the keys. I cannot use hardcoded base class because ammount on keys will change over time in runtime. But as ...
0
votes
1answer
34 views

Creating nested objects with es6

I'm getting some data back from a local API, and unfortunately I don't have much control of the what's coming to me, what I am hoping is that I can transform the data after my API call using a ...
0
votes
0answers
18 views

C# How to generate json a specific way for jquery data table

i have a .net data table which is populated with sample data but when generating json from datatable then getting json this way [{"ID":1,"Name":"Ajay"},{"ID":2,"Name":"Sanu"}] my C# code as ...
0
votes
0answers
22 views

Need help reading Json file using C#

I am using json file and trying to read using C#. { "Company": { "ABC": {"ADDRESS" : "123 STREET", "DEF" :"ADDRESS 567", }, }, "Country":...
1
vote
1answer
30 views

JSONObject.put(String) adds '\' for each '/'

I'm just recogniced that this code: try { String jsonString =new JSONObject().put("test","Ha/llo").toString(); } catch (JSONException e) { e.printStackTrace(); } ouputs the ...
-3
votes
1answer
29 views

Java opposite of php's json_encode - how to decode? [closed]

I am making an Android app, that communicates with a PHP server. The server side code is as follows: (PHP Code) $result=array(); $result[]['response']=1/1; $result[]['token']=15424535354345; $...
0
votes
4answers
36 views

Normalize json with related keys

I have JSON like this: in_str='''{ "prices": [ [1, 10], [2, 20], [3, 30] ], "total_volumes": [ [1, 100], [2, 200], [3, 300] ] }''' And I am trying to produce ...
1
vote
0answers
14 views

Facebook Graph API Regarding User's Data

I need HELP! How can I get the user's data like User's Device ID, Device Type, Device Version, etc... I am fetching data from GOOGLE sheets using Script editor and I am looking to fetch my ManyChat ...
0
votes
2answers
31 views

Modify json file with powershell

I need to modify the preferences file for Chrome for users. This is the wanted outcome: This is what I have so far, but it's failing: get-childitem -path "$env:systemdrive\Users" | foreach-object {...
0
votes
2answers
26 views

How to send nested raw JSON in URLSession to Vapor API?

I have a Vapor API that has a route to register users. This route recibes a nested object in JSON format like this: { "name": "Test", "email": "[email protected]", "password": "Test1", "...
0
votes
0answers
47 views

Javascript search string for json objects

I'm working on a project which using files containing string of text for input. The text also contains multiple json data. There could be one or several hundred of them in a file. They take the ...
1
vote
0answers
13 views

Axios React Getting error response and sending to UI

I have a React app with a service that makes api requests using Axios. I am trying to get the error.response messages (ValidationResult.Errors) from the registerService and pass the validation result ...
1
vote
1answer
45 views

Swift encode class without nesting super class

Summary: I would like to encode all fields of my super class without nesting them in the json result. Here's what I mean: Let's say we have these structs: struct Toy: Codable { var name: String } ...
0
votes
0answers
16 views

Most efficient way to post multiple forms

I have a project that requires posting of multiple forms linked to the contents of a "parent" form. Forms are not nested, the parent/child relationship describes the server side relationship. ...
0
votes
1answer
58 views

How to append a list in Pandas?

I'm reading a dataframe and trying to insert a list inside another list and then converting it to json file. I'm using python 3 and 0.25.3 version of pandas for it. ============================ ...
0
votes
1answer
16 views

curl command for REST API which takes json input

I want to call REST API by passing json input. I have following details- username apitoken apiurl Jsonfile I have already tried curl -d @Metadata.json -H "Content-Type: application/json" <> --...
0
votes
0answers
10 views

Consequences after fixing an error when creating a page in Wordpress

I've been recommended this website to get help for this issue, hopefully I can post this here. I've been getting the error “The response is not a valid JSON response” whenever I try to create a page ...
0
votes
0answers
5 views

Any way to Export WA conversation and convert .json to a flow diagram (similar to Visio)?

Is there a way to export WA conversations (automatically exporting to .json file) and have converted to a Visio, or similar, type diagram showing actual flows?
0
votes
1answer
28 views

json data is being stored as a single row

import json from pymongo import MongoClient client = MongoClient('localhost', 27017) db = client['zomato_db'] collection_zomato = db['zomatores'] with open('E:\\DAPProject\\Datasets\\ZOMATORES.json'...
0
votes
0answers
29 views

Deserialization array from json field [duplicate]

Can you tell how to deserialize following json's with object mapper without creating wrapper classes? {"orderCodes":["04231556", "0454156"]} or {"categoryIds":[133, 663, 667, 903]} I can create ...
0
votes
0answers
20 views

Native Facebook messages using Watson Assistant (JSON)

I've got a Watson Assistant chatbot showing up on Facebook Messenger and working alright. However, I'm struggling to get Facebook value additions like buttons and media working. From the Watson web ...
0
votes
1answer
20 views

HIGHCHARTS POINTSTART TODAYS DATE

Hi I am using a line chart from HIGHCHARTS, can you please help me get the x-axis to show present month LAST on the x-axis - and the X-axis to automatically populate going back however many numbers of ...
0
votes
2answers
27 views

Pyspark : Convert a CSV to Nested JSON

I am new to pyspark. I have a requirement where I need to convert a big CSV file at hdfs location to multiple Nested JSON files based on distinct primaryId. Sample Input: data.csv **PrimaryId,...
1
vote
1answer
13 views

Sonar “Make transient or serializable” error

I have the following serializable class (implements serializable): public class Test implements Serializable{ private String id; private Map<String,Object> otherProperties; } However , it ...
1
vote
3answers
37 views

How to Subtract 30Days, 3 Months & 1 Year In Epoch time from now using java?

I have an EpochTime for Now and I want to get 30 days, 3 Months, and 1 Year back epoch time How to do that in java code. long todayEpochTime = System.currentTimeMillis()/1000; System.out.println(...
0
votes
1answer
31 views

How to use Flutter http request when the url contain port?

I am trying to send post request to a website with port configured. http://example.com:8080/. When i send the request, it show some error http.post('example.com:8080/apps/api.php', body: {'name': '...
0
votes
0answers
14 views

MariaDB - Return value or default from a JSON array

On a MariaSQL database v10.2.13, I have 2 tables : an "infos" table with a date column and a "data" json column containing an array of objects and a "persons" table, 1 person can have many infos. A ...
0
votes
0answers
37 views

Is it a bad idea to build a complex JSON directly on the database? [closed]

I have a react app that shows data from a PostgreSQL db through PostgREST. I want to structure this data in a nested JSON. Here's a simplified structure: { "key": "value", "children": [ {...
-2
votes
3answers
37 views

How to save an ArrayList, a custom adapter (and its data) in Android using JSON? [closed]

I have an Android project that uses a ListView displaying a custom object's data from an adapter. I want to save this data when it opens the next time, but I don't know how to parse a custom adapter ...
1
vote
0answers
30 views

PHP JSON Count occurence of identical value groups [duplicate]

I've got the following array stored in a JSON-file: "plates": [ { "depth": 0.8, "width": 47.425, "height": 50.7, "color": "#00ff00", "points": ...