JSON (JavaScript Object Notation) aka the Fat Free Alternative to XML is a lightweight data exchange format inspired by JavaScript object literals. It is often used with JavaScript, Ajax, and RESTful web services but is completely language independent.

learn more… | top users | synonyms

5
votes
2answers
57 views

Adding an item to database + JSON

Is this code good? Or is it the noobiest PHP you've ever seen? ...
1
vote
0answers
17 views

Send Google Cloud Messages

I wrote code which is doing query and insert inside while loop. ...
0
votes
0answers
5 views

Is it a bad practice to use JSON strings as keys of objects? [migrated]

On languages such as Haskell, most datatypes have instances which allow their values to be used as keys of structures such as ...
3
votes
1answer
624 views

Wrapper for a transfer transaction API

I'm looking for any kind of advice, like when or where to do exception handling, the overall library structure/layout, usage of classes/partial classes, code efficiency, naming conventions, and so on ...
2
votes
2answers
56 views

Generated serialization code

CGbR project I am currently working on a project that generates code from classes. The idea is to achieve maximum performance by replacing reflection use cases with fast, generated code. Current ...
0
votes
1answer
49 views

Submitting a form via JSON

I have a feedback.js that I would like to improve. ...
4
votes
1answer
24 views

Invoking API calls with parameters specified using JSON

I have an instance of a Java class that I need to call some functions on, using the API exposed by another party. For each call, I need to both check for thrown exceptions, and check the value of the ...
1
vote
0answers
44 views

Transforming a parts catalog into a different data structure

The entire purpose of this code is to arrange the data that was dumped into CommRef_ into the required structure of ResObj. The ...
-1
votes
1answer
36 views

merging json object

Hi I am trying to merging json objects which has common value. This is original JSON ...
0
votes
1answer
57 views

Wikipedia search using the JSON API

I ask to you. What I could do better in my code or logic? This my example on Codepen -> Wikipedia Search ...
2
votes
1answer
36 views

Regrouping JSON object

I wrote a JavaScript source which regrouping by new key i.e. following JSON to the other: ...
1
vote
1answer
21 views

Twitch client that notifies me when a followed streamer comes online

I've been writing code for a little while but I'm a little slapdash. I'd like to get better so I've been having a glance at best practices, other peoples code and reading a whole lot. I'd appreciate ...
7
votes
3answers
46 views

From Q to compiler in less than 30 seconds

As an adjunct to From new Q to compiler in 30 seconds, I've created a Python script to automatically download the markdown from any question on Code Review and save it to a local file using Unix-style ...
1
vote
1answer
42 views

Nested loop to transform MongoDB results

I have the following structure returned from MongoDB: ...
0
votes
1answer
28 views

Collect several API call results

Want to brush up my rusty web dev skills. I want to call the twitch API for several channels and eventually call a callback function when all results are in without using a sync call. I didn't work ...
1
vote
0answers
73 views

Submitting a JSON [closed]

I have service to which I have to submit a JSON but I have to send the JSON multiple times and the code is slow. How can I improve the performance? ...
0
votes
0answers
64 views

Loading autocomplete text view adapter dynamically using async task in Android

I am working on an app in which I need to get destination list from server and set it in autocomplete text view. I am using text watcher and on its onTextChanged event I am fetching destinations data ...
5
votes
1answer
53 views

Serializing (and deserializing) basic mesh using JSON.net

In order to improve my c# (which is fairly basic at best) I decided to try to serialize a simple mesh to a file using the JSON.net library. Simple mesh in this case means an array of vertices and a ...
4
votes
1answer
62 views

Parsing JSON using jsoncpp

I left questions in the comments strategically, since I think it's easier to answer questions this way. Basically what my small class does is abstracts away functionality that was originally in a ...
0
votes
1answer
119 views

Parsing JSON in one go using state machine solution

I need to parse a simple JSON string (flat JSON, no hierarchy) for keys and values, and there is a system constraint that I cannot use any built-in JSON library and can only read a string once due to ...
1
vote
0answers
29 views

Excel-to-JSON parser 2

After first code review I have fixed the found issues. Could you please review my new refactored application? Main class (entry point) ...
0
votes
1answer
46 views

Excel-to-JSON parser

I just wanted to build a simple converter from an XLS Excel file to JSON. I have predefined JSON format. All fields except of two - are just simple mapping from Excel to JSON. The two fields have a ...
3
votes
1answer
150 views

Newtonsoft Json helper class

I've written the following helper class to help serializing objects to and from Json. I would appreciate some feed back on the style of the class. ...
3
votes
1answer
48 views

Angular JSON weather app

I'm pretty new to Angular. I wrote a weather app and need my code reviewed. I especially need help on best practices for handling edge cases on the response from the JSON endpoint. Here's the HTML: ...
5
votes
2answers
69 views

Tracking Containers in a Train Station

This is a time line for control over the events of some containers in a train station. It gets all the data to build the time line by getting a JSON from a database via REST service. The app resets ...
2
votes
2answers
203 views

Parsing JSON in one go

I need to parse a simple JSON string (flat JSON, no hierarchy) for keys and values, and there is a system constraint that I cannot use any built-in JSON library and can only read a string once due to ...
-1
votes
2answers
87 views

JSON string parsing

I need to parse a simple JSON string (flat JSON, no hierarchy) for keys and values, and there is a system constraint that I cannot use any built-in JSON library and can only read a string once due to ...
0
votes
1answer
19 views

Converting height map bitmap to json

This is my first F# program. It's a command line utility that takes a parameter containing a path to an height map bitmap and prints out this height map converted to JSON format. ...
3
votes
1answer
55 views

GPSD socket connection and decoding JSON into Python dictionaries

GPS3 is a python 2.7-3.5 interface to GPSD. I've stripped back everything to two classes. ...
2
votes
1answer
45 views

Basic JSON Representation in Rust

This week I started reading "The Rust Programming Language". As I reached the chapters on enumerations and pattern matching I felt I had enough material to put together a simple representation of JSON ...
1
vote
0answers
80 views

making dynamic tables with JSON - angular2

Okay, so simple enough task - I'm using Ionic/Angular2 to develop an auditing app. Using angular I can map Objects into the DOM rather easily, so what I need to do is create an object - but I would ...
2
votes
2answers
47 views

RSS to JSON for insertion into MongoDB

In my code, there is a chain of functions call where the deepest function may throw an exception. I catch and handle it according to the business logic. The problem is that all other functions in the ...
1
vote
1answer
48 views

Filters for a JSON collection

I am trying to create a class that parses a JSON and selects all labels, or just a particular label that you prefer to later do a calculation with the value pair extracted off that label. This is ...
4
votes
1answer
42 views

Converts the JSON object to another structure of JSON

I want a JSON object of the following structure to plot a chart ...
6
votes
1answer
64 views

Parse JSON data of upcoming fixtures of Chelsea FC

This program makes a call to an API (http://api.football-data.org/) and obtains data for fixtures of Chelsea FC for the next 100 days in JSON format. The JSON is parsed into a Java object and then ...
2
votes
0answers
33 views

Extracting data for a tag cloud using Lazy.js

I've just started using Lazy.js, which is my first exposure to a "functional style" javascript library. I'm still utterly lost as to which of the hundred different functional javascript libraries to ...
2
votes
2answers
115 views

Minimal CORS mail PHP

I have an PHP endpoint used to mail me feedback or error logs from my sites here: https://github.com/kaihendry/vanilla-php-feedback-form/blob/master/feedback/feedback.php ...
4
votes
2answers
172 views

Tic-Tac-Toe machine learning

I recently started getting into machine learning and I wanted to write a "beginner program" which would learn to play Tic Tac Toe. This code was inspired by a different program I saw, meaning some ...
1
vote
1answer
60 views

Testing a Rails API controller

I'm building a JSON API. I'm writing my controller tests so that they compare the response body to actual JSON I'm generating in my tests using ActiveRecord. I wrote two helper methods that make the ...
1
vote
0answers
25 views

Script to migrate event, artist, and venue information from MongoDB to Drupal

At first I brute forced the migration to just get it finished. However, the procedural program mixed the events with the venues so I rewrote it, this time using classes which I'm just beginning to ...
1
vote
0answers
26 views

Flask json rpc2.0 extension

I created a simple extension to handle JSON RPC 2.0 requests on flask I would like some feedback regarding usage here is an usage example: ...
1
vote
2answers
142 views

Fetching data from nested JSON using jQuery and displaying in table

I'm displaying JSON data in a tabular format on a html page using jQuery. In the function I'm looping the resp.DATA once to get the key names so it can be ...
6
votes
1answer
81 views

C# Regex to extract bug ID from Bugzilla JSON response

I have written a series of Regex.Replace() lines to take an input like {"id":36} and convert it to ...
1
vote
1answer
52 views

Google Maps coordinations JSON to object

I am trying to write a parser from JSON data which I get from Google requesting coordinates of a city, which will create my specified object structure. For parsing, I've written a custom ...
0
votes
2answers
33 views

Building categories block based on JSON

I'm not even sure if this is how you're supposed to do it, but this is what I have so far: ...
3
votes
0answers
82 views

Streaming Json Serialization Using C++

I've written a C++ library for serializing objects to a stream as Json with the following goals in mind: Minimal run-time overhead (write the contents of an existing object/array to the stream ...
4
votes
1answer
72 views

GitHub API client

Here is my Haskell program designed to list all of my GitHub repos along with their descriptions and languages via the GitHub JSON APIs: ...
7
votes
1answer
62 views

React & ES6 news app

I have written a small app that fetches news items from an endpoint and displays them in a grid. I used React to create components and use them throughout the app. This is the first thing I have ...
-1
votes
1answer
46 views

Proper Use of Keep Alive For Loop

I'm working to make a thread that monitors a web API to get the latest announcement via JSON. I cannot test this currently, so I'm unsure if anything needs to be changed with this. I've read through ...
2
votes
1answer
77 views

Read decibel level from a USB meter, display it as a live visualization, and send it via FTP

This question was posed to me by someone in my university's athletics department who had a USB sound level meter and a simple Python script which printed the current sound level (he was provided with ...