PK YY/B¡þÛð( ð( pymongolab-1.0rc1/examples.html
PyMongoLab is a Python client library that contains tools for accessing to MongoLab databases via MongoLab REST API using a similar sintax to PyMongo.
This package is a HTTP requests implementation for MongoLab REST API.
>>> from mongolabclient import MongoLabClient
>>> client = MongoLabClient("MongoLabAPIKey")
>>> client.list_documents("database", "collection")
[{u'_id': ObjectId('50243d38e4b00c3b3e75fc94'), u'foo': u'bar', u'tld': u'com'},
{u'_id': ObjectId('50004d646cf431171ed53846'), u'foo': u'bar', u'tld': u'org'}]
PyMongo-flavored package for accessing to MongoLab databases via MongoLabClient.
>>> from pymongolab import Connection
>>> connection = Connection("MongoLabAPIKey")
>>> db = connection.database
>>> col = db.collection.find()
>>> list(col)
[{u'_id': ObjectId('50243d38e4b00c3b3e75fc94'), u'foo': u'bar', u'tld': u'com'},
{u'_id': ObjectId('50004d646cf431171ed53846'), u'foo': u'bar', u'tld': u'org'}]
View more usage examples here.
You can to use pip to install PyMongoLab:
$ pip install git+git://github.com/puentesarrin/pymongolab.git
Or:
$ git clone git://github.com/puentesarrin/pymongolab.git
$ cd pymongolab
$ python setup.py install
Please, help us to report issues on GitHub issues page.
Sphinx must be installed to generate the documentation. Documentation can be generated by running python setup.py doc.
Please activate JavaScript to enable the search functionality.
From here you can search these documents. Enter your search words into the box below and click "search". Note that the search function will automatically search for all of the words. Pages containing fewer words won't appear in the result list.