Skip to main content

Python API for the Genesis platform.

Project description

Genesis PyAPI

Python API for the Genesis platform.

Install

To install, run:

python setup.py install

To install for development, run:

python setup.py develop

Usage

Create an API instance:

from genesis import Genesis
gen = Genesis()

Get all project and select the first one:

projects = gen.projects()
project = list(projects.values())[0]

Get expression objects and select the first one:

expressions = project.data(type__startswith='data:expression:')
expression = expressions[0]

Print annotation:

expression.print_annotation()

Print file fields:

expression.print_downloads()

Download file:

filename = expression.annotation['output.exp']['value']['file']
resp = expression.download('output.exp')
with open(filename, 'w') as fd:
    fd.write(resp.content)

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

Genesis-PyAPI-1.2.1.tar.gz (16.5 kB view hashes)

Uploaded Source

Built Distribution

Genesis_PyAPI-1.2.1-py2.py3-none-any.whl (10.1 kB view hashes)

Uploaded Python 2 Python 3

Supported by

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