Do you want to validate JSON response of your application REST APIs? For a large JSON, it is easy to use JSON schema for validation. In this post, we will see how to validate JSON response with JSON Schema in Postman using ajv validator. BrijPad – Online tool allows you to generate and validate JSON Schema. We will use it to generate Schema.
Read Also: Inspect JSON Easily with BrijPad
For a web developer, it is common to view & analyze the JSON returned by an API to the browser and generally, Chrome Developer tools is used for this. You can click on Network tab, select the XHR item and can get JSON in Response and Preview tabs in Chrome developer tools. Fortunately, there are quite a few free online JSON viewers that you can use. Now, BrijPad 2.0 also allows you to inspect and analyze JSON quickly. You can paste the JSON code and visualize the data. I saw many online tools but didn’t get any tool which filters JSON by selecting field in TreeView (It is very helpful in case of large JSON) so I decided to implement it and added it in BrijPad 2.0.
Read Also: Chrome Developer Tools: Inspect JSON path and extract data quickly
In this post, we will add JSON data to Sql Server tables using ASP.NET Web API, JSON.NET and SqlBulkCopy. The data is posted using jQuery ajax to web api which accepts JObject type argument, parse data, arrange data in the required table structure and save to database. Here is the structure of JSON and SQL Server tables.