Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/albincorreya/freesound-oauth2-python-flask

A simple web app based on flask and python to download original sound files from freesound.org using oauth2 authorizsation
https://github.com/albincorreya/freesound-oauth2-python-flask

flask freesound-api oauth2-server python

Last synced: 22 days ago
JSON representation

A simple web app based on flask and python to download original sound files from freesound.org using oauth2 authorizsation

Awesome Lists containing this project

README

        

# freesound-oauth2-python-flask
A simple web app based on flask and python to download original sound files from freesound.org using oauth2 authorization. T

NOTE : If you want much more sophiscated and scalable search, filtering and effective downloads, use the [freesound-python client library](https://github.com/MTG/freesound-python), you can also find some simple cases in the repo. An oauth2 example can be found [here](https://github.com/albincorreya/smc_masterthesis2017/blob/master/fs_text_search_oauth2downloader.py).

Code optimised from [kemitche's repository](https://gist.github.com/kemitche/9749639).

## Setup

1. Install dependencies from requirements.txt. Ideally create a [virtualenv](http://python-guide-pt-br.readthedocs.io/en/latest/dev/virtualenvs/) and install the requirements

2. Apply for your freesound API key from [here](http://freesound.org/apiv2/apply/) and update it in the code

3. [IMPORTANT] Set your "callback_url" as http://localhost:5000/freesound_callback

4. Open terminal and navigate to your working directory and run the code.

In Mac

$ export FLASK_APP=freesound_oauth2.py
$ flask run

In Windows

$ export FLASK_APP=freesound_oauth2.py
$ python -m flask run

5. Open your web browser with url http://localhost:5000 and authorise your app.

_________________________

Find flask documentation [here](http://flask.pocoo.org/docs/0.12/quickstart/#a-minimal-application)