Metadata-Version: 1.1
Name: shoogle
Version: 0.1.3
Summary: Google API from the command line
Home-page: https://github.com/tokland/shoogle
Author: Arnau Sanchez
Author-email: pyarnau@gmail.com
License: ISCL
Description: Shoogle
        =======
        
        Use the Google API from the shell. Requires Python 3.x.
        
        Features
        --------
        
        -  Exposes agnostically all the services in the API.
        -  Provides infrastructure for the Oauth2 authentication (console or
           QT/GTK browser).
        -  Shows info so you can build the JSON requests.
        -  Credentials for scopes (separated by profiles) are stored for later
           use.
        
        Install
        -------
        
        From PyPi
        ~~~~~~~~~
        
        ::
        
            $ sudo pip install shoogle
        
        From sources
        ~~~~~~~~~~~~
        
        ::
        
            $ wget https://github.com/tokland/shoogle/archive/master.zip
            $ unzip master.zip
            $ cd shoogle-master
            $ sudo python setup.py install
        
        Notes
        -----
        
        -  Python 3.x is required.
        -  You must enable the APIs you want to use and create the required keys
           or secret in the `API
           Manager <https://console.developers.google.com/apis/>`_. Each service
           has its own policies, check the Google documentation for more
           details.
        
        Examples
        --------
        
        -  Incrementally show details of services/resources/methods:
        
        ::
        
            $ shoogle show url
            urlshortener:v1 - URL Shortener API
        
        ::
        
            $ shoogle show urlshortener:v1
            urlshortener:v1.url
        
        ::
        
            $ shoogle show urlshortener:v1.url
            urlshortener:v1.url.get - Expands a short URL or gets creation time and analytics.
            urlshortener:v1.url.insert - Creates a new short URL.
            urlshortener:v1.url.list - Retrieves a list of URLs shortened by a user.
        
        ::
        
            $ shoogle show urlshortener:v1.url.get
            [INFO] Response (level=0, --debug-response-level=N to change):
            {
              "$ref": "Url"
            }
            [INFO] Request (level=1, --debug-request-level=N to change):
            {
              "shortUrl": "(string) The short URL, including the protocol - required"
            }
        
        -  Expand a short URL:
        
        ::
        
            $ cat get-longurl.json 
            {
              "key": "MY_SECRET_KEY", // You can use JS comments!
              "shortUrl": "http://goo.gl/Du5PSN"
            }
        
            $ shoogle execute -c your_client_id.json urlshortener:v1.url.get get-longurl.json
            {
              "status": "OK",
              "id": "http://goo.gl/Du5PSN",
              "longUrl": "http://1.bp.blogspot.com/-R0HSXDqlJI8/Tr67i-kr7hI/AAAAAAABMko/gaId6iYuhjA/s1600/12_%252520Cross%252520that%252520bridge%252520when%252520we%252520come%252520to%252520it.jpg",
              "kind": "urlshortener#url"
            }
        
        -  `jq <https://stedolan.github.io/jq/>`_ is a JSON processor the comes
           in handy. This example uploads a video building the JSON from a
           template and extracting the video ID from the response:
        
        ::
        
            $ cat upload-video.template.json
            {
              "part": "snippet",
              "body": {
                "snippet": {
                  "title": $title
                }
              }
            }
        
        ::
        
            $ jq -n -f upload-video.template.json --arg title "My title" |
                shoogle execute -c your_client_id.json youtube:v3.videos.insert - -f video.mp4 |
                jq -r '.id'
            wUArz2nPGqA
        
        More
        ----
        
        -  License: `GNU/GPLv3 <http://www.gnu.org/licenses/gpl.html>`_.
        
        Feedback
        --------
        
        -  Issues: Please open issues only to report bugs of the package. If you
           have problems regarding how to use the API (what authentication files
           to use, how to create them, how to build the parameters, manage
           quotas, etc), use the `Google
           Forums <https://developers.google.com/>`_ or
           `StackOverflow <http://stackoverflow.com/questions/tagged/google-api>`_
           instead.
        
        -  `Want to
           donate? <https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=pyarnau%40gmail%2ecom&lc=US&item_name=youtube%2dupload&no_note=0&currency_code=EUR&bn=PP%2dDonationsBF%3abtn_donateCC_LG%2egif%3aNonHostedGuest>`_
        
        
        
        
        ChangeLog
        =========
        
        [0.1.0]
        -------
        
        -  Provides infrastructure for Oauth2 authentication (console and
           browser).
        -  Exposes all services supported by the Python Gooogle API.
        
        
Keywords: shoogle
Platform: UNKNOWN
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: End Users/Desktop
Classifier: License :: OSI Approved :: GNU General Public License (GPL)
Classifier: Natural Language :: English
Classifier: Operating System :: POSIX
Classifier: Operating System :: Microsoft :: Windows
Classifier: Topic :: Internet :: WWW/HTTP
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.3
Classifier: Programming Language :: Python :: 3.4
Classifier: Programming Language :: Python :: 3.5
