ikitommi / muuntaja

Ring middleware for parsing parameters and emitting responses in JSON or other formats

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Muuntaja

muuntaja Continuous Integration status Dependencies Status

Snappy Clojure library for managing (http) api-formats. Provides adapters for both ring, async-ring and pedestal.

Design goals:

  • explicit configuration, no shared mutable state
  • pragmatic & fast over 100% compliancy with HTTP spec
  • extendable & pluggable: new formats, behavior
  • standalone + adapters for both ring (middleware) and pedestal (interceptors)
  • replacement for ring-middleware-defaults

Latest version

Clojars Project

Features

TODO

  • Ring compatible middleware, works with any web framework build on top of Ring
  • Automatically parses requests and encodes responses according to Content-Type and Accept headers
  • Automatically handles charset detection of requests bodies, even if the charset given by the MIME type is absent or wrong (using ICU)
  • Automatically selects and uses the right charset for the response according to the request header
  • Varied formats handled out of the box (JSON, MessagePack, YAML, EDN, Transit over JSON or Msgpack)
  • Pluggable system makes it easy to add to the standards encoders and decoders custom ones (proprietary format, Protobuf, specific xml, csv, etc.)

API Documentation

Full API documentation is available.

License

Original Code (ring-middleware-format)

Copyright © 2011, 2012, 2013, 2014 Nils Grunwald
Copyright © 2015, 2016 Juho Teperi

This library

Copyright © 2016 Metosin

Distributed under the Eclipse Public License, the same as Clojure.

About

Ring middleware for parsing parameters and emitting responses in JSON or other formats


Languages

Language:Clojure 99.0%Language:Shell 1.0%