.. transloadit documentation master file, created by sphinx-quickstart on Sat Jul 15 15:25:58 2017. You can adapt this file completely to your liking, but it should at least contain the root `toctree` directive. Welcome to transloadit's Python SDK documentation! ================================================== |Build Status| .. |Build Status| image:: https://travis-ci.org/transloadit/python-sdk.svg?branch=master :target: https://travis-ci.org/transloadit/python-sdk `Transloadit`_ is a service that helps you handle file uploads, resize, crop and watermark your images, make GIFs, transcode your videos, extract thumbnails, generate audio waveforms, and so much more. In short, `Transloadit`_ is the Swiss Army Knife for your files. This is a **Python** SDK to make it easy to talk to the `Transloadit`_ REST API. .. _Transloadit: https://transloadit.com .. toctree:: :maxdepth: 4 :caption: Contents: transloadit Indices and tables ================== * :ref:`genindex` * :ref:`modindex` * :ref:`search` Quickstart ========== Install ------- .. code:: bash pip install pytransloadit Usage ----- .. code:: python from transloadit import client tl = client.Transloadit('TRANSLOADIT_KEY', 'TRANSLOADIT_SECRET') assembly = tl.new_assembly() assembly.add_file(open('PATH/TO/FILE.jpg', 'rb')) assembly.add_step('resize', '/image/resize', {'width': 70, 'height': 70}) assembly_response = assembly.create(retries=5, wait=True) print assembly_response.data.get('assembly_id') # or print assembly_response.data['assembly_id'] Example ------- For fully working examples, take a look at `examples/`_. .. _examples/: https://github.com/transloadit/python-sdk/tree/master/examples