Description
Praxis is a framework for both designing and implementing APIs.
An important part of the framework is geared towards the design aspect of building an API. This functionality empowers architects with tools to design every last aspect of their API, resulting in a complete, web-browsable documentation, which includes automatic generation of examples for resources, parameters, headers, etc...as well as requests and responses for the supported encodings. The design process is iterative, and flows from defining new resources, parameters, etc...to reviewing the resulting docs (usually with some of the potential clients of the API), back to updating the design based on feedback, or expanding it with more resources. The design language (i.e. DSL) of Praxis follows a clean 'ruby-type-syntax' and its final outcome is to generates an output that is both a set of schema documents as well as a web-based API browser (driven by those schemas). This allows Praxis to design APIs that can potentially be implemented in any language.
Another important part of the framework is geared towards helping in the implementation of the API service. In particular, Praxis provides help to Ruby developers for building a service conforming to the designed API. Aside from Ruby there is also sister-project called Goa that assists in implementing Praxis-like design API using Golang. Since the API design generates schema files very similar in nature to other API document formats like (Swagger, Google Discovery, RAML, etc...) supporting other implementation languages could be easily accomplished in the future by building converters to/from them.
The part of the framework that helps with the ruby service implementation takes an approach that is different from other existing ruby (micro)frameworks such as Grape, Sinatra, Scorched, Lotus or even RailsAPI (now part of Rails). Instead of being developer-centric, it takes an integrated approach treating both designers and implementors as first class citizens throughout the complete API building process. With Praxis you create an API by iterating through the design, review and implementation phases. While Praxis can help Ruby developers in a lot of aspects involved in building a service, the framework is completely componentized as to allow developers to pick and choose which parts to use, which ones not to use, and which other technologies to integrate with. The framework provides help in many areas, for example: all aspects of request and response validation, automatic type-coercion, consistent error-responses, routing and url generation, advanced template/media-type definition and rendering, domain-modeling, optional database ORM (for high-perfomance large datasets), DB integration (with an efficient identityMap), a plugin and extensible framework to easily hook into, available integrations such as newrelic, statsd, etc...
There is a long list of benefits that come from using Praxis. From those, here are a couple of the salient themes:
Praxis alternatives and similar gems
Based on the "API Builder" category.
Alternatively, view Praxis alternatives based on common mentions on social networks and blogs.
-
ActiveModel::Serializers
ActiveModel::Serializer implementation and Rails hooks -
Fast JSON API
No Longer Maintained - A lightning fast JSON:API serializer for Ruby Objects. -
rabl
General ruby templating with json, bson, xml, plist and msgpack support -
JSONAPI::Resources
A resource-focused Rails library for developing JSON:API compliant servers. -
Her
Her is an ORM (Object Relational Mapper) that maps REST resources to Ruby objects. It is designed to build applications that are powered by a RESTful API instead of a database. -
Blueprinter
Simple, Fast, and Declarative Serialization Library for Ruby -
Version Cake
:cake: Version Cake is an unobtrusive way to version APIs in your Rails or Rack apps -
Pragma
An expressive, opinionated ecosystem for building beautiful RESTful APIs with Ruby. -
YASL
Yet Another Serialization Library - A pure Ruby serialization library that works across different Ruby implementations like Opal and JRuby as an alternative to YAML/Marshal.
Less time debugging, more time building
* Code Quality Rankings and insights are calculated and provided by Lumnify.
They vary from L1 to L5 with "L5" being the highest.
Do you think we are missing an alternative of Praxis or a related project?
Popular Comparisons
README
Praxis

Praxis is a framework for both designing and implementing APIs.
An important part of the framework is geared towards the design aspect of building an API. This functionality empowers architects with tools to design every last aspect of their API, resulting in a complete, web-browsable documentation, which includes automatic generation of examples for resources, parameters, headers, etc...as well as requests and responses for the supported encodings. The design process is iterative, and flows from defining new resources, parameters, etc...to reviewing the resulting docs (usually with some of the potential clients of the API), back to updating the design based on feedback, or expanding it with more resources. The design language (i.e. DSL) of Praxis follows a clean 'ruby-type-syntax' and its final outcome is to generates an output that is both a set of schema documents as well as a web-based API browser (driven by those schemas). This allows Praxis to design APIs that can potentially be implemented in any language.
Another important part of the framework is geared towards helping in the implementation of the API service. In particular, Praxis provides help to Ruby developers for building a service conforming to the designed API. Aside from Ruby there is also sister-project called Goa that assists in implementing Praxis-like design API using Golang. Since the API design generates schema files very similar in nature to other API document formats like (Swagger, Google Discovery, RAML, etc...) supporting other implementation languages could be easily accomplished in the future by building converters to/from them.
The part of the framework that helps with the ruby service implementation takes an approach that is different from other existing ruby (micro)frameworks such as Grape, Sinatra, Scorched, Lotus or even RailsAPI (now part of Rails). Instead of being developer-centric, it takes an integrated approach treating both designers and implementors as first class citizens throughout the complete API building process. With Praxis you create an API by iterating through the design, review and implementation phases. While Praxis can help Ruby developers in a lot of aspects involved in building a service, the framework is completely componentized as to allow developers to pick and choose which parts to use, which ones not to use, and which other technologies to integrate with. The framework provides help in many areas, for example: all aspects of request and response validation, automatic type-coercion, consistent error-responses, routing and url generation, advanced template/media-type definition and rendering, domain-modeling, optional database ORM (for high-perfomance large datasets), DB integration (with an efficient identityMap), a plugin and extensible framework to easily hook into, available integrations such as newrelic, statsd, etc...
There is a long list of benefits that come from using Praxis. From those, here are a couple of the salient themes:
- Designing APIs with Praxis result in a very precise, consistent and beautiful API documentation that it is apt for both human (web browsable) or machine consumption (JSON spec files).
- Building Ruby APIs with Praxis will result in much faster developer times, and more importantly with a resulting service that will ensure that its implementation is always consistent with its design, and it is enforced at all times.
Quickstart
# Install the praxis gem
gem install praxis
# Generate a praxis application named my-app in ./my-app
praxis example my-app
# Run it!
cd my-app
bundle
rackup
Or better yet, checkout a simple, but functional blog example app which showcases a few of the main design and implementation aspects that Praxis has to offer.
Mailing List
Join our Google Groups for discussion, support and announcements.
- praxis-support (support for people using Praxis)
- praxis-announce (announcements)
- praxis-development (discussion about the development of Praxis itself)
Join our slack support and general announcements channel for on-the-spot answers to your questions:
- To join our slack chat please go to: http://praxis-framework.herokuapp.com and sign in for an account.
- Once you have an account, hop onto the chat at http://praxis-framework.slack.com
And follow us on twitter: @praxisapi
Contributions
Contributions to make Praxis better are welcome. Please refer to CONTRIBUTING for further details on what contributions are accepted and how to go about contributing.
Requirements
Praxis requires Ruby 2.1.0 or greater.
License
This software is released under the MIT License. Please see [LICENSE](LICENSE) for further details.
Copyright (c) 2014 RightScale
*Note that all licence references and agreements mentioned in the Praxis README section above
are relevant to that project's source code only.