{ "info": { "author": "OpenX API Team", "author_email": "api@openx.com", "bugtrack_url": null, "classifiers": [ "Environment :: Console", "Environment :: Web Environment", "Intended Audience :: Developers", "License :: OSI Approved :: BSD License", "Operating System :: OS Independent", "Programming Language :: Python", "Programming Language :: Python :: 2.6", "Programming Language :: Python :: 2.7", "Programming Language :: Python :: 3", "Programming Language :: Python :: Implementation :: CPython", "Topic :: Internet :: WWW/HTTP :: Dynamic Content", "Topic :: Software Development :: Libraries", "Topic :: Software Development :: Libraries :: Python Modules" ], "description": "# ox3apiclient\n\nA small class to help connect to the OpenX Enterprise API. As of version 0.5.0 it uses\n[requests_oauthlib](https://github.com/requests/requests-oauthlib) instead of oauth2.\n\nIt currently supports Python 2.6 - 3.5.\n\nAs of version 0.4.0, ox3apiclient supports API v2. If your instance is v2,\nset the api_path option to \"/ox/4.0\".\n\nAs of version 0.5.0 the client.request method returns a requests.Response object instead of\nurllib2.Response and throws a requests.exceptions.HTTPError instead of urllib2.HTTPError.\nIn addition debugging is now available via the standard python logging facility.\n\nSee the [requests documentation](http://docs.python-requests.org/en/latest/) for details.\n\nBasic usage:\n\n````python\nimport ox3apiclient\nimport logging\n\nox = ox3apiclient.client_from_file().logon()\n\nox.logger.setLevel(logging.DEBUG)\nch = logging.StreamHandler()\nch.setLevel(logging.DEBUG)\nox.logger.addHandler(ch)\n\naccounts = ox.get('/account')\n\norder = {\n 'status': 'Active',\n 'name': 'OX3APIClient Object Creation Test',\n 'account_uid': accounts['objects'][0]['account_uid'],\n 'start_date': '2016-06-01 00:00:00'}\n\nnew_order = ox.post('/order', data=order)\n\nox.delete('/order/%s' % new_order['uid'])\n\nox.logoff()\n````\n\n\n## Installation\n\nFrom Pypi\n\nThe last released version (from the master branch) is available at [PyPi](http://pypi.python.org/pypi)\n````\n$ pip install ox3apiclient\n````\n\n\nFrom Github:\n\nJust clone our git repo:\n\n````\n$ git clone https://github.com/openx/OX3-Python-API-Client.git\n````\n\nInstall the downloaded library:\n````\npython setup.py install\n````\nthis will install the current dependencies.\n\n## Authentication\n\nThe recommended method of authentication is to use `ox3apiclient.client_from_file`.\nBy default this will look for a file named `.ox3rc` in the current current\ndirectory, but this can be overwritten by specifying a `file_path` parameter. The\nfile should be in the following format:\n\n````\n[ox3apiclient]\nenvs=\n dev\n prod\n\n[dev]\nemail: you@example.com\npassword: password123\ndomain: dev.uidomain.com\nrealm: dev.uidomain_realm\nconsumer_key: 1fc5c9ae...\nconsumer_secret: 7c664d68...\nauthorization_url: http://custom_sso.uidomain.com/api/index/initiate\n\n[prod]\nemail: you@example.com\npassword: password123\ndomain: uidomain.com\nrealm: uidomain_realm\nconsumer_key: 1fc5c9ae...\nconsumer_secret: 7c664d68...\n````\n\n`ox3apiclient.client_from_file` will use the first `env` by default but this can\nbe overwritten by setting the `env` parameter. If your email and password are set\nin `.ox3rc` you can simply chain a call to `logon()`.\n\nAlternatively you can set everything in your code.\n````python\nemail = 'you@example.com'\npassword = 'password123'\ndomain = 'uidomain.com'\nrealm = 'uidomain_realm'\nconsumer_key = '1fc5c9ae...'\nconsumer_secret = '7c664d68...'\n\nox = ox3apiclient.Client(\n email=email,\n password=password,\n domain=domain,\n realm=realm,\n consumer_key=consumer_key,\n consumer_secret=consumer_secret)\n\nox.logon(email, password)\n````\n\n # To run these tests. Install nose (pip install nose)\n # and run nosetests -sxv tests/ from the root dir\n\n## Tests\n\nInstall nose\n\n````bash\npip install nose\n```` \n \n and run the following command line from the root:\n\n````bash\nnosetests -sxv tests/\n````", "description_content_type": "text/markdown", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/openx/OX3-Python-API-Client", "keywords": "", "license": "BSD", "maintainer": "", "maintainer_email": "", "name": "ox3apiclient", "package_url": "https://pypi.org/project/ox3apiclient/", "platform": "POSIX", "project_url": "https://pypi.org/project/ox3apiclient/", "project_urls": { "Homepage": "https://github.com/openx/OX3-Python-API-Client" }, "release_url": "https://pypi.org/project/ox3apiclient/0.6.1/", "requires_dist": null, "requires_python": "", "summary": "Client to connect to the OpenX Enterprise API.", "version": "0.6.1" }, "last_serial": 5818759, "releases": { "0.5.1": [ { "comment_text": "", "digests": { "md5": "6cfaaec0ca74cf738415d71dccbe5595", "sha256": "9264c46877d848310bbbb5864377f81719d4a4215d2b23837ac5a775f7b339ca" }, "downloads": -1, "filename": "ox3apiclient-0.5.1.tar.gz", "has_sig": false, "md5_digest": "6cfaaec0ca74cf738415d71dccbe5595", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 5837, "upload_time": "2017-02-08T22:41:18", "url": "https://files.pythonhosted.org/packages/d9/13/c283b5eb84fe17781bf4fefcd07147bfb87f007653b49f6e9db5b219b8c5/ox3apiclient-0.5.1.tar.gz" } ], "0.5.2": [ { "comment_text": "", "digests": { "md5": "cc4c6fa42dfc009a4a110ac0f22eea44", "sha256": "df3a5db1305442ccc56cc9e8149cb1ea60d4587dd731aadeb84a127b55bb54c5" }, "downloads": -1, "filename": "ox3apiclient-0.5.2.tar.gz", "has_sig": false, "md5_digest": "cc4c6fa42dfc009a4a110ac0f22eea44", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7577, "upload_time": "2017-02-08T22:54:19", "url": "https://files.pythonhosted.org/packages/43/f7/ef9d20e0f4f85bd4a00a835d62e3e3c91bc253906919579f8ae9940291e5/ox3apiclient-0.5.2.tar.gz" } ], "0.6.0": [ { "comment_text": "", "digests": { "md5": "511950cd5e20ecbfbfcc7f8091afb9d5", "sha256": "d331f7889d00a1ac0b6cf495e3e39c95f38068bae140053d996087a5198a3fb4" }, "downloads": -1, "filename": "ox3apiclient-0.6.0.tar.gz", "has_sig": false, "md5_digest": "511950cd5e20ecbfbfcc7f8091afb9d5", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 5893, "upload_time": "2017-06-29T22:54:06", "url": "https://files.pythonhosted.org/packages/da/e3/872be5a2d7582bbd8be6d90731f899aa8457cf4083ac368c5441aff351fe/ox3apiclient-0.6.0.tar.gz" } ], "0.6.1": [ { "comment_text": "", "digests": { "md5": "3e480045998699c5c3181528292913e7", "sha256": "88fef607c34c9d599e42c57fcc8b380d13c2b9c80cbab0e7d4b4659a4fd97bbb" }, "downloads": -1, "filename": "ox3apiclient-0.6.1.tar.gz", "has_sig": false, "md5_digest": "3e480045998699c5c3181528292913e7", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 11566, "upload_time": "2019-09-12T07:51:03", "url": "https://files.pythonhosted.org/packages/95/93/714dd3a9ab2cffbc4352e4c382ddda24a7b3915012bf124910034e5e2353/ox3apiclient-0.6.1.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "3e480045998699c5c3181528292913e7", "sha256": "88fef607c34c9d599e42c57fcc8b380d13c2b9c80cbab0e7d4b4659a4fd97bbb" }, "downloads": -1, "filename": "ox3apiclient-0.6.1.tar.gz", "has_sig": false, "md5_digest": "3e480045998699c5c3181528292913e7", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 11566, "upload_time": "2019-09-12T07:51:03", "url": "https://files.pythonhosted.org/packages/95/93/714dd3a9ab2cffbc4352e4c382ddda24a7b3915012bf124910034e5e2353/ox3apiclient-0.6.1.tar.gz" } ] }