Skip to main content

UNKNOWN

Project description

GlobeLabs API Python Client
===========================

Installation
------------

```
$ pip install globelabs
```

Usage
-----

Sample usage with flask.

```
from globelabs import Globe


app_id = "BGyKAhGbyoGhRdiA8kTyMXhR9yGEhzoa"
app_secret = "8ed742b6c27e38db323ab24e19460a38eb0bf52804fc08f4df897db206b7b690"
shortcode = "1027"
globe = Globe(app_id=self.app_id,
app_secret=self.app_secret,
shortcode=self.shortcode)


@app.route('/login')
def login():
return redirect(globe.get_auth_url())


@app.route('/redirect_callback')
def redirect_callback():
r = globe.get_access_token(request.args.get('code'))
ac = r['access_token']
subscriber_number = r['subscriber_number']
return redirect(url_for('.home'))


@app.route('/charge')
def charge():
globe.charge(0, "2158%s0000099" % self.shortcode)

```

TODO
----

* Need help with documentation! :D

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

globelabs-0.0.2.tar.gz (2.1 kB view details)

Uploaded Source

File details

Details for the file globelabs-0.0.2.tar.gz.

File metadata

  • Download URL: globelabs-0.0.2.tar.gz
  • Upload date:
  • Size: 2.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for globelabs-0.0.2.tar.gz
Algorithm Hash digest
SHA256 e323563707f6ccc74b4f2e0999d4e91298ff8118e442a49a620d684593fd22b8
MD5 3d3cdfb9d42c9e274552d867551b905f
BLAKE2b-256 e824ea4bd639d0dabff78cabf4e0d9a918f7c6100ba581ceff78ffb096b8a2f8

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page