Title: Unable to run an example · Issue #21 · infusionsoft/Official-API-Python-Library · GitHub
Open Graph Title: Unable to run an example · Issue #21 · infusionsoft/Official-API-Python-Library
X Title: Unable to run an example · Issue #21 · infusionsoft/Official-API-Python-Library
Description: I've copy-pasted an example from here https://github.com/infusionsoft/Official-API-Python-Library/blob/master/example.py from infusionsoft.library import Infusionsoft infusionsoft = Infusionsoft( 'APPNAME', 'APIKEY' ) # Example 1: Add Co...
Open Graph Description: I've copy-pasted an example from here https://github.com/infusionsoft/Official-API-Python-Library/blob/master/example.py from infusionsoft.library import Infusionsoft infusionsoft = Infusionsoft( '...
X Description: I've copy-pasted an example from here https://github.com/infusionsoft/Official-API-Python-Library/blob/master/example.py from infusionsoft.library import Infusionsoft infusionsoft = Infusionsof...
Opengraph URL: https://github.com/infusionsoft/Official-API-Python-Library/issues/21
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Unable to run an example","articleBody":"I've copy-pasted an example from here https://github.com/infusionsoft/Official-API-Python-Library/blob/master/example.py\r\n\r\n```\r\nfrom infusionsoft.library import Infusionsoft\r\n\r\ninfusionsoft = Infusionsoft( 'APPNAME', 'APIKEY' )\r\n\r\n# Example 1: Add Contact\r\n#----------------------------------------------------------------------------------------\r\ncontact = {'FirstName' : 'John', 'LastName' : 'Doe', 'Email' : 'johndoe@email.com'}\r\nprint(infusionsoft.ContactService('add', contact))\r\n```\r\n\r\nGot app name and the key from here:\r\nhttps://keys.developer.infusionsoft.com\r\n\r\n```\r\nCredentials\r\nApplication APPNAME\r\nclient_id APIKEY \r\nclient_secret serret23sdffd \r\nStatus: active \r\nCreated: 2 hours ago\r\n\r\n```\r\n\r\nWhen I run the code I get an error:\r\n```\r\nTraceback (most recent call last):\r\n File \"inf.py\", line 8, in \u003cmodule\u003e\r\n print(infusionsoft.ContactService('add', contact))\r\n File \"/root/miniconda/lib/python3.6/site-packages/infusionsoft/library.py\", line 21, in function\r\n return call(self.key, *args)\r\n File \"/root/miniconda/lib/python3.6/xmlrpc/client.py\", line 1112, in __call__\r\n return self.__send(self.__name, args)\r\n File \"/root/miniconda/lib/python3.6/xmlrpc/client.py\", line 1452, in __request\r\n verbose=self.__verbose\r\n File \"/root/miniconda/lib/python3.6/xmlrpc/client.py\", line 1154, in request\r\n return self.single_request(host, handler, request_body, verbose)\r\n File \"/root/miniconda/lib/python3.6/xmlrpc/client.py\", line 1166, in single_request\r\n http_conn = self.send_request(host, handler, request_body, verbose)\r\n File \"/root/miniconda/lib/python3.6/xmlrpc/client.py\", line 1279, in send_request\r\n self.send_content(connection, request_body)\r\n File \"/root/miniconda/lib/python3.6/xmlrpc/client.py\", line 1309, in send_content\r\n connection.endheaders(request_body)\r\n File \"/root/miniconda/lib/python3.6/http/client.py\", line 1234, in endheaders\r\n self._send_output(message_body, encode_chunked=encode_chunked)\r\n File \"/root/miniconda/lib/python3.6/http/client.py\", line 1026, in _send_output\r\n self.send(msg)\r\n File \"/root/miniconda/lib/python3.6/http/client.py\", line 964, in send\r\n self.connect()\r\n File \"/root/miniconda/lib/python3.6/http/client.py\", line 1392, in connect\r\n super().connect()\r\n File \"/root/miniconda/lib/python3.6/http/client.py\", line 936, in connect\r\n (self.host,self.port), self.timeout, self.source_address)\r\n File \"/root/miniconda/lib/python3.6/socket.py\", line 704, in create_connection\r\n for res in getaddrinfo(host, port, 0, SOCK_STREAM):\r\n File \"/root/miniconda/lib/python3.6/socket.py\", line 745, in getaddrinfo\r\n for res in _socket.getaddrinfo(host, port, family, type, proto, flags):\r\nsocket.gaierror: [Errno -2] Name or service not known\r\n\r\n```\r\n","author":{"url":"https://github.com/sr9yar","@type":"Person","name":"sr9yar"},"datePublished":"2018-12-24T14:51:20.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":1},"url":"https://github.com/21/Official-API-Python-Library/issues/21"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:247713cb-6394-fff1-3197-ad09020b1e6b |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | 9C36:DFAF2:CE416A:11929E1:6A51F85B |
| html-safe-nonce | 84484705ed6d790c938880cbb6a2ff8c0be73465771d195fe61c893ecd32cd3f |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI5QzM2OkRGQUYyOkNFNDE2QToxMTkyOUUxOjZBNTFGODVCIiwidmlzaXRvcl9pZCI6IjE5Mzc2NjI1NDAxODUyMDQ4MjciLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | 12abe5f768a2f598055a2ca9dd93e94057622eeee9b4cbdcf1c57673c5885a3a |
| hovercard-subject-tag | issue:393894199 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/infusionsoft/Official-API-Python-Library/21/issue_layout |
| twitter:image | https://opengraph.githubassets.com/2d7a433431e6e37b010c4b9ac3aaafd4699999c1fe788838ad3604b4b5af6394/infusionsoft/Official-API-Python-Library/issues/21 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/2d7a433431e6e37b010c4b9ac3aaafd4699999c1fe788838ad3604b4b5af6394/infusionsoft/Official-API-Python-Library/issues/21 |
| og:image:alt | I've copy-pasted an example from here https://github.com/infusionsoft/Official-API-Python-Library/blob/master/example.py from infusionsoft.library import Infusionsoft infusionsoft = Infusionsoft( '... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | sr9yar |
| hostname | github.com |
| expected-hostname | github.com |
| None | b9a586c06a05a7a86fc7e3f4dbd03e42f6869085879aa184aa6369456dbd50fb |
| turbo-cache-control | no-preview |
| go-import | github.com/infusionsoft/Official-API-Python-Library git https://github.com/infusionsoft/Official-API-Python-Library.git |
| octolytics-dimension-user_id | 208525 |
| octolytics-dimension-user_login | infusionsoft |
| octolytics-dimension-repository_id | 6872987 |
| octolytics-dimension-repository_nwo | infusionsoft/Official-API-Python-Library |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 6872987 |
| octolytics-dimension-repository_network_root_nwo | infusionsoft/Official-API-Python-Library |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 7aed05249554b889eb33d002851a973eebcc7e91 |
| ui-target | canary-2 |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width