Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
95 lines (65 sloc) 2.39 KB

Welcome to simplegist's documentation!

Helps in carrying out easy workflow for maintaining gists


  • Creating gists returning the url, script and clone link for copy-paste purpose
  • Checkout one's gists - Name(s), Description and Content
  • Edit and Delete a gist
  • Search GitHub user's gist - fork, star and unstar them
  • List comments of any gist, make/edit a comment on a gist, delete a comment


$ pip install simplegist

Or download it from here and then,

$ cd /to/this/directory/
$ python install

Generating Github API Access Token

Go to Github's Account settings > Applications Create a new token and use it for making API requests instead of password.

Creating an Instance

# if USERNAME and API_TOKEN are not provided in
GHgist = Simplegist(username='USERNAME',api_token='API_TOKEN')

# else
GHgist = Simplegist()

Example Usage

Below is an example to getting started with using GistAPI and its useful functionalities.

from simplegist import SimpleGist

# provide USERNAME and API_TOKEN in file, so just, GHgist = Gist(), OR,
GHgist = Simplegist(username='USERNAME',api_token='API_TOKEN')

# creating gist and returning url, script, clone link
GHgist.create(name='_GISTNAME', description='_ANY_DESCRIPTION', public=1, content='_CONTENT_GOES_HERE')

# Lists all the names of authenticated user's gists

# Lists only the names of recent two gists of user '_USERNAME''_USERNAME').list(2)

# Lists all the comments on gist named '_GISTNAME' of user '_USERNAME'

# ...and many more...


.. toctree::
   :maxdepth: 2


Related Docs