@@ 8,8 8,8 @@ log = logging.getLogger(__name__)
class SendyAPI:
- ''' Class used to map to all Sendy API endpoints
- '''
+ """ Class used to map to all Sendy API endpoints
+ """
def __init__(self, host, api_key=None, debug=False):
self.host = host
@@ 24,11 24,6 @@ class SendyAPI:
'list',
'email',
'name',
- 'country',
- 'ipaddress',
- 'referrer',
- 'gdpr',
- 'hp',
],
extra_param={'boolean': 'true'},
success_message='1',
@@ 88,6 83,8 @@ class SendyAPI:
'query_string',
'send_campaign',
],
- success_message=['Campaign created', 'Campaign created and now sending'],
+ success_message=[
+ 'Campaign created', 'Campaign created and now sending'
+ ],
method='POST',
)
@@ 1,17 1,16 @@
from __future__ import unicode_literals
-import json
import logging
import requests
-from .exceptions import SendyError
-
try:
from urlparse import urljoin
except ImportError:
from urllib.parse import urljoin
+from .exceptions import SendyError
+
log = logging.getLogger(__name__)