Metadata-Version: 2.0
Name: treq
Version: 15.0.0
Summary: A requests-like API built on top of twisted.web's Agent
Home-page: http://github.com/dreid/treq
Author: David Reid
Author-email: dreid@dreid.org
License: MIT/X
Platform: UNKNOWN
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 2
Classifier: Programming Language :: Python :: 2.6
Classifier: Programming Language :: Python :: 2.7
Classifier: Programming Language :: Python :: Implementation :: CPython
Classifier: Programming Language :: Python :: Implementation :: PyPy
Requires-Dist: Twisted (>=12.1.0)
Requires-Dist: requests
Requires-Dist: service-identity
Requires-Dist: pyOpenSSL (>=0.11)

treq
====

|build|_

``treq`` is an HTTP library inspired by
`requests <http://www.python-requests.org>`_ but written on top of
`Twisted <http://www.twistedmatrix.com>`_'s
`Agents <http://twistedmatrix.com/documents/current/api/twisted.web.client.Agent.html>`_.

It provides a simple, higher level API for making HTTP requests when
using Twisted.

.. code-block:: python

    >>> from treq import get

    >>> def done(response):
    ...     print response.code
    ...     reactor.stop()

    >>> get("http://www.github.com").addCallback(done)

    >>> from twisted.internet import reactor
    >>> reactor.run()
    200

For more info `read the docs <http://treq.readthedocs.org>`_.

Contribute
==========

``treq`` is hosted on `GitHub <http://github.com/dreid/treq>`_.

Feel free to fork and send contributions over.

Developing
==========

Install dependencies:

::

    pip install -r requirements-dev.txt

Optionally install PyOpenSSL:

::

    pip install PyOpenSSL

Run Tests (unit & integration):

::

    trial treq

Lint:

::

    pep8 treq
    pyflakes treq

Build docs:

::

    cd docs; make html

.. |build| image:: https://secure.travis-ci.org/dreid/treq.png?branch=master
.. _build: http://travis-ci.org/dreid/treq


