Skip to main content
This is a pre-production deployment of Warehouse. Changes made here affect the production instance of PyPI (pypi.python.org).
Help us improve Python packaging - Donate today!

Some toolkit for RESTful API development in Pyramid.

Project Description
=========================
pyramid_restful_toolkit
=========================


A toolkit for RESTful API development in Pyramid.

That includes:

1. JSON renderer
2. HTTP Auth Policy (Basic, Digest)
3. Some utilities to work with SQLAlchemy, CQLEngine

-----
API
-----

To use it, just

.. code-block::python

config.include('pyramid_restful_toolkit')

This will do those jobs:

1. Add JSON as default renderer with some default adapters. You can access
it through `pyramid_restful_toolkit.default_renderer`
2. Add some error handlers for common validators library such as: formencode,
colander, schema.

If you want all uncaught exception has return as JSON text. Just include tween
`pyramid_restful_toolkit.jsonize_uncaught_exception_tween_factory`. This is
normally used in production.ini.


HTTP Auth Policy
################

To use this package, in the app function, just include it.

config.include("pyramid_restful_toolkit.auth")

In you *development.ini*

pyramid_restful_toolkit.auth.get_user_callback = 'path to get user function'

You can use built-in model:

**For SQLAlchemy**

config.include("pyramid_restful_toolkit.auth.models.sqlalchemy")

with *development.ini*

pyramid_restful_toolkit.auth.dbsession = app.models.DBSession

Use *pyramid_restful_toolkit.auth.models.sqlalchemy.RESTfulUser* to manage your users. Its table
name is *rest_user*.


-----------
CHANGES LOG
-----------

1.1.1
=====

* Add default renderer for datetime.date

1.1.0
=====

* Add python 3 support
* Remove auth, move to `pyramid_httpauth (https://github.com/tarzanjw/pyramid_httpauth)`_

1.0.3
=====

* Add default JSON renderer for cqlengine.columns.ValueQuoter, cqlengine.model.Model

1.0.2
=====

* Add default error handler support for deform.ValidationFailure
Release History

Release History

This version
History Node

1.1.1

History Node

1.1.0

History Node

1.0.3.1

History Node

1.0.3

History Node

1.0.2

History Node

1.0.1

History Node

1.0

Download Files

Download Files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

File Name & Checksum SHA256 Checksum Help Version File Type Upload Date
pyramid_restful_toolkit-1.1.1.tar.gz (16.2 kB) Copy SHA256 Checksum SHA256 Source Apr 7, 2015

Supported By

WebFaction WebFaction Technical Writing Elastic Elastic Search Pingdom Pingdom Monitoring Dyn Dyn DNS Sentry Sentry Error Logging CloudAMQP CloudAMQP RabbitMQ Heroku Heroku PaaS Kabu Creative Kabu Creative UX & Design Fastly Fastly CDN DigiCert DigiCert EV Certificate Rackspace Rackspace Cloud Servers DreamHost DreamHost Log Hosting