All Projects → CleverCloud → Json2caseclass

CleverCloud / Json2caseclass

Kickstart your scala API client by turning JSON into case classes.

Programming Languages

javascript
184084 projects - #8 most used programming language
scala
5932 projects

Labels

Projects that are alternatives of or similar to Json2caseclass

Finch
Scala combinator library for building Finagle HTTP services
Stars: ✭ 1,552 (+1161.79%)
Mutual labels:  json
Jwt
Jwt.Net, a JWT (JSON Web Token) implementation for .NET
Stars: ✭ 1,694 (+1277.24%)
Mutual labels:  json
Coc Json
Json language extension for coc.nvim
Stars: ✭ 123 (+0%)
Mutual labels:  json
Typedload
Python library to load dynamically typed data into statically typed data structures
Stars: ✭ 120 (-2.44%)
Mutual labels:  json
Data Store
Easily get, set and persist config data. Fast. Supports dot-notation in keys. No dependencies.
Stars: ✭ 120 (-2.44%)
Mutual labels:  json
Snodge
Randomly mutate JSON, XML, HTML forms, text and binary data for fuzz testing
Stars: ✭ 121 (-1.63%)
Mutual labels:  json
Jeayeson
A very sane (header only) C++14 JSON library
Stars: ✭ 119 (-3.25%)
Mutual labels:  json
Plug logger json
Elixir Plug that formats http request logs as json
Stars: ✭ 125 (+1.63%)
Mutual labels:  json
Crudapi
Go implementation of a RESTful JSON API exposing CRUD functionality relying on a custom storage.
Stars: ✭ 121 (-1.63%)
Mutual labels:  json
Jqr
R interface to jq
Stars: ✭ 123 (+0%)
Mutual labels:  json
Json Voorhees
A killer modern C++ library for interacting with JSON.
Stars: ✭ 120 (-2.44%)
Mutual labels:  json
Jwalk
Streaming JSON parser for Unix
Stars: ✭ 121 (-1.63%)
Mutual labels:  json
Yyjson
The fastest JSON library in C
Stars: ✭ 1,894 (+1439.84%)
Mutual labels:  json
Dataclass factory
Modern way to convert python dataclasses or other objects to and from more common types like dicts or json-like structures
Stars: ✭ 116 (-5.69%)
Mutual labels:  json
Django Jsoneditor
Django JSONEditor input widget to provide javascript online JSON Editor
Stars: ✭ 124 (+0.81%)
Mutual labels:  json
Snapshooter
Snapshooter is a snapshot testing tool for .NET Core and .NET Framework
Stars: ✭ 118 (-4.07%)
Mutual labels:  json
Structomap
Easily and dynamically generate maps from Go static structures
Stars: ✭ 122 (-0.81%)
Mutual labels:  json
Fx
Command-line tool and terminal JSON viewer 🔥
Stars: ✭ 11,295 (+9082.93%)
Mutual labels:  json
Codability
Useful helpers for working with Codable types in Swift
Stars: ✭ 125 (+1.63%)
Mutual labels:  json
Api Response
Simple and ready to use API response wrapper for Laravel.
Stars: ✭ 123 (+0%)
Mutual labels:  json

json 2 case class

Kickstart your scala API client by turning JSON into case classes.

Try it at http://json2caseclass.cleverapps.io

Use cases

When interacting with 3rd party json-based APIs from scala, modelling the API's responses with case classes can come in handy. If the JSON exhibits some properties (homogenous lists, for instance), it's easy to create a case class with the same structure. With some deserialization magic it's easier to deal with the API's responses.

case class Foo(a: Bar, b: Bar, c: Double)
case class Bar(a: Option[String], b: String)

{
   "a": {
     "a": "fubar",
     "b": "fubar"
   },
   "b": {
     "b": "baz"
   },
   "c": 42.0
}

However it's tedious to manually copy the json structure into case classes.

json 2 case class automatically generates case classes from JSON (if possible).

Features

json 2 case class can generate

  • nested case classes from JSON objects
  • lists from JSON arrays
  • scala base types from JSON primitives
  • Option[T] for optional values

ToDo

Due to the arity limitation of 22 values, some JSON objects can't be encoded with case classes. A Map[String,T] fallback is on the works.

The code is on the project but not activated : need a UI support to choose between map and object

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].