FFFF all: make pip installable by odeke-em · Pull Request #10 · geminipy/geminipy · GitHub
[go: up one dir, main page]

Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions MANIFEST.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
include README.md
include LICENSE
49 changes: 25 additions & 24 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,42 +5,43 @@ Easily communicate with the Gemini Bitcoin exchange API without
having to deal with HTTP requests.


Requirements
============
Please get an API key from [https://exchange.gemini.com/settings/api](https://exchange.gemini.com/settings/api)


Installation
============

Just download geminipy.py
```shell
pip install geminipy
```

Example
=======

from geminipy import Geminipy
```python
from geminipy import Geminipy

con = Geminipy(api_key='your API key', secret_key='your secret key')
con = Geminipy(api_key='your API key', secret_key='your secret key')

# public request
symbols = con.symbols()
# public request
symbols = con.symbols()

# a Requests response is returned.
# So we can access the HTTP reponse code,
# the raw response content, or a json object
print symbols.status_code
print symbols.content
print symbols.json()
# a Requests response is returned.
# So we can access the HTTP reponse code,
# the raw response content, or a json object
print symbols.status_code
print symbols.content
print symbols.json()

# authenticated request
order = con.new_order(amount='1', price='200',side='buy')
# authenticated request
order = con.new_order(amount='1', price='200',side='buy')

print order.json()
print order.json()

#send a heartbeat
con.heartbeat()
#send a heartbeat
con.heartbeat()
```

The required nonce is the current millisecond timestamp.

Dependencies
============

requests >=2.9.1

sudo pip install requests --upgrade

File renamed without changes.
1 change: 1 addition & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
requests>=2.9.1
23 changes: 23 additions & 0 deletions setup.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
from setuptools import setup

with open('README.md') as f:
readme = f.read()

setup(
name='geminipy',
version='0.0.1',
packages=['geminipy'],
url='https://github.com/geminipy/geminipy',
license='GNU GPL',
author='Mike Marzigliano',
zip_safe=False,
long_description=readme,
description='API client for Gemini',
classifiers=[
'Gemin exchange',
'Cryptocurrency',
'Cryptoexchange',
'Topic :: Cryptocurrency',
'Topic :: Cryptocurrency:: Digital Assets Management',
],
)
0