# Path: openprovider/api.py
# def api_factory(account=''):
#     username = _get_env('username', account)
#     try:
#         password_hash = _get_env('password_hash', account)
#         password = None
#     except KeyError:
#         password_hash = None
#         password = _get_env('password', account)
#     url = os.environ.get('OPENPROVIDER_URL', 'https://api.openprovider.eu')
# 
#     return OpenProvider(username=username, password=password, password_hash=password_hash, url=url)


from openprovider.api import api_factory
    from IPython import embed
import openprovider  # NOQA
import textwrap
import os
    import code
# coding=utf-8

"""
This is a simple REPL for experimenting with the openprovider.py API. An
instance of the OpenProvider class is available as 'op'. The openprovider module
has been imported for you.

Use the environment variables OPENPROVIDER_USERNAME, OPENPROVIDER_PASSWORD and OPENPROVIDER_URL to
change the username and password.
"""


os.environ.setdefault('OPENPROVIDER_USERNAME', 'test')
os.environ.setdefault('OPENPROVIDER_PASSWORD', 'test')


try:
    # Try to use IPython...

    def repl():
        embed(banner1="")
except ImportError:
    # But if that fails, fall back to normal Python.

    def repl():
        code.interact(banner="", local=globals())


# Path: openprovider/api.py
# def api_factory(account=''):
#     username = _get_env('username', account)
#     try:
#         password_hash = _get_env('password_hash', account)
#         password = None
#     except KeyError:
#         password_hash = None
#         password = _get_env('password', account)
#     url = os.environ.get('OPENPROVIDER_URL', 'https://api.openprovider.eu')
# 
#     return OpenProvider(username=username, password=password, password_hash=password_hash, url=url)


# Path: openprovider/__main__.py
from openprovider.api import api_factory
    from IPython import embed
import openprovider  # NOQA
import textwrap
import os
    import code

# coding=utf-8

"""
This is a simple REPL for experimenting with the openprovider.py API. An
instance of the OpenProvider class is available as 'op'. The openprovider module
has been imported for you.

Use the environment variables OPENPROVIDER_USERNAME, OPENPROVIDER_PASSWORD and OPENPROVIDER_URL to
change the username and password.
"""


os.environ.setdefault('OPENPROVIDER_USERNAME', 'test')
os.environ.setdefault('OPENPROVIDER_PASSWORD', 'test')


try:
    # Try to use IPython...

    def repl():
        embed(banner1="")
except ImportError:
    # But if that fails, fall back to normal Python.

    def repl():
        code.interact(banner="", local=globals())


op = api_factory()