{ "info": { "author": "Miguel Ferrer", "author_email": "ingferrermiguel@gmail.com", "bugtrack_url": null, "classifiers": [], "description": "# getresponse\n\ngetresponse is an API wrapper for GetResponse written in Python.\n\n## Installing\n\n```\npip install getresponse-python\n```\n\n## Usage\n\n```\nfrom getresponse.client import GetResponse\nfrom getresponse.excs import UniquePropertyError\n\ngetresponse = GetResponse('YOUR_API_KEY_HERE')\n```\nFor GetResponse Enterprise platform:\n```\nfrom getresponse.client import GetResponseEnterprise\n\ngetresponse = GetResponseEnterprise('YOUR_API_KEY_HERE', 'YOUR_DOMAIN_NAME', 'YOUR_API_ENDPOINT')\n```\nGet account info:\n```\naccount = getresponse.accounts()\n\nprint('Account:', account.id, account.name)\n```\nGet all campaigns:\n```\ncampaigns = getresponse.get_campaigns({'sort': {'name', 'desc'}})\n\nfor campaign in campaigns:\n print('Campaign:' campaign.id, campaign.name)\n```\nGet a campaign:\n```\ncampaign = getresponse.get_campaign('CAMPAIGN_ID_HERE')\n\nprint('Campaign:', campaign.id, campaign.name)\n```\nCreate a campaign:\n```\ncampaign = {\n \"name\": 'UNIQUE_ID_HERE',\n}\n\ntry:\n campaign = getresponse.create_campaign(campaign)\n print('Campaign:', campaign.id, campaign.name)\nexcept UniquePropertyError:\n print(\"Cannot create: campaign's name already exists.\")\n```\nGet all contacts:\n```\ncontacts = getresponse.get_contacts({'sort': {'name', 'desc'})\nfor contact in contacts:\n print('Contact:', contact.id, contact.name)\n```\nGet a contact:\n```\ncontact = getresponse.get_contact('CONTACT_ID_HERE')\nif contact:\n print('Contact:', contact.id, contact.name)\n```\nCreate a contact:\n```\nvalues = {\n \"email\": \"CONTACT_EMAIL_HERE\",\n \"campaign\": {\n 'campaignId': 'CAMPAIGN_ID_HERE',\n },\n}\n\ntry:\n contact = getresponse.create_contact(values)\n print('Contact in queue to be created.')\nexcept UniquePropertyError:\n print(\"Cannot created: contact's email already exists.\")\n```\nDelete a contact:\n```\ncontact = getresponse.delete_contact('CONTACT_ID_HERE')\n```\nGet all custom fields:\n```\ncustom_fields = getresponse.get_custom_fields({'sort': {'name', 'desc'})\nfor custom_field in custom_fields:\n print('Custom Field:', custom_field.id, custom_field.name)\n```\nGet a custom field:\n```\ncustom_field = getresponse.get_custom_field('CUSTOM_FIELD_ID_HERE')\nif custom_field:\n print('Custom Field:', custom_field.id, custom_field.name)\n```\n## Requirements\n- requests\n\n## Contributing\nWe are always grateful for any kind of contribution including but not limited to bug reports, code enhancements, bug fixes, and even functionality suggestions.\n#### You can report any bug you find or suggest new functionality with a new [issue](https://github.com/GearPlug/getresponse-python/issues).\n#### If you want to add yourself some functionality to the wrapper:\n1. Fork it ( https://github.com/GearPlug/getresponse-python )\n2. Create your feature branch (git checkout -b my-new-feature)\n3. Commit your changes (git commit -am 'Adds my new feature')\n4. Push to the branch (git push origin my-new-feature)\n5. Create a new Pull Request", "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/GearPlug/getresponse-python", "keywords": "", "license": "GPL", "maintainer": "", "maintainer_email": "", "name": "getresponse-python", "package_url": "https://pypi.org/project/getresponse-python/", "platform": "", "project_url": "https://pypi.org/project/getresponse-python/", "project_urls": { "Homepage": "https://github.com/GearPlug/getresponse-python" }, "release_url": "https://pypi.org/project/getresponse-python/0.1.2/", "requires_dist": null, "requires_python": "", "summary": "Email Marketing Software", "version": "0.1.2" }, "last_serial": 5705655, "releases": { "0.1": [ { "comment_text": "", "digests": { "md5": "20274688e4fade2c219072b211d1b098", "sha256": "b760d2b81323e50a634e6439da6a1551b51b25fb2f105d01fdb3cc0e6cb2d96a" }, "downloads": -1, "filename": "getresponse-python-0.1.tar.gz", "has_sig": false, "md5_digest": "20274688e4fade2c219072b211d1b098", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 5397, "upload_time": "2018-02-16T21:02:18", "url": "https://files.pythonhosted.org/packages/ec/e6/fca7c459304708ebf73a099a683ee617cf7cc91421aef6a15b2345408a20/getresponse-python-0.1.tar.gz" } ], "0.1.1": [ { "comment_text": "", "digests": { "md5": "d041a6f4b2ac0cdf044b49a85241f1de", "sha256": "f5c735521b7563460ba5d6159c7ba724e9ebb6d6a50571bae47908689c54a4f0" }, "downloads": -1, "filename": "getresponse-python-0.1.1.tar.gz", "has_sig": false, "md5_digest": "d041a6f4b2ac0cdf044b49a85241f1de", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 6005, "upload_time": "2018-02-26T13:58:35", "url": "https://files.pythonhosted.org/packages/9b/9e/f0ecc47485442a790a81f175711f3f4bdefaaf4bdb4049882ea78816942f/getresponse-python-0.1.1.tar.gz" } ], "0.1.2": [ { "comment_text": "", "digests": { "md5": "8b0ce40c02cb741b7852f5d56f8b0b9a", "sha256": "aba2177744e5a735440c5951e7dc51cd3910f4e586f8de2e161c05ec4527ed11" }, "downloads": -1, "filename": "getresponse-python-0.1.2.tar.gz", "has_sig": false, "md5_digest": "8b0ce40c02cb741b7852f5d56f8b0b9a", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 6306, "upload_time": "2019-08-20T21:05:49", "url": "https://files.pythonhosted.org/packages/ed/f6/a1906f85ccb405ce4b47ba84d9559791807f41f90c7e1489ede8bb81004e/getresponse-python-0.1.2.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "8b0ce40c02cb741b7852f5d56f8b0b9a", "sha256": "aba2177744e5a735440c5951e7dc51cd3910f4e586f8de2e161c05ec4527ed11" }, "downloads": -1, "filename": "getresponse-python-0.1.2.tar.gz", "has_sig": false, "md5_digest": "8b0ce40c02cb741b7852f5d56f8b0b9a", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 6306, "upload_time": "2019-08-20T21:05:49", "url": "https://files.pythonhosted.org/packages/ed/f6/a1906f85ccb405ce4b47ba84d9559791807f41f90c7e1489ede8bb81004e/getresponse-python-0.1.2.tar.gz" } ] }