python-amcards 1.6.0__tar.gz → 1.6.2__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {python_amcards-1.6.0 → python_amcards-1.6.2}/PKG-INFO +1 -1
- {python_amcards-1.6.0 → python_amcards-1.6.2}/amcards/models.py +16 -0
- {python_amcards-1.6.0 → python_amcards-1.6.2}/python_amcards.egg-info/PKG-INFO +1 -1
- {python_amcards-1.6.0 → python_amcards-1.6.2}/setup.py +1 -1
- {python_amcards-1.6.0 → python_amcards-1.6.2}/LICENSE +0 -0
- {python_amcards-1.6.0 → python_amcards-1.6.2}/README.rst +0 -0
- {python_amcards-1.6.0 → python_amcards-1.6.2}/amcards/__helpers.py +0 -0
- {python_amcards-1.6.0 → python_amcards-1.6.2}/amcards/__init__.py +0 -0
- {python_amcards-1.6.0 → python_amcards-1.6.2}/amcards/amcards.py +0 -0
- {python_amcards-1.6.0 → python_amcards-1.6.2}/amcards/exceptions.py +0 -0
- {python_amcards-1.6.0 → python_amcards-1.6.2}/python_amcards.egg-info/SOURCES.txt +0 -0
- {python_amcards-1.6.0 → python_amcards-1.6.2}/python_amcards.egg-info/dependency_links.txt +0 -0
- {python_amcards-1.6.0 → python_amcards-1.6.2}/python_amcards.egg-info/requires.txt +0 -0
- {python_amcards-1.6.0 → python_amcards-1.6.2}/python_amcards.egg-info/top_level.txt +0 -0
- {python_amcards-1.6.0 → python_amcards-1.6.2}/setup.cfg +0 -0
|
@@ -279,6 +279,7 @@ class Campaign:
|
|
|
279
279
|
send_if_duplicate: bool,
|
|
280
280
|
has_anniversary_drip: bool = False,
|
|
281
281
|
has_birthday_drip: bool = False,
|
|
282
|
+
total_cost: int = 0,
|
|
282
283
|
) -> None:
|
|
283
284
|
self._id = id
|
|
284
285
|
self._name = name
|
|
@@ -286,6 +287,7 @@ class Campaign:
|
|
|
286
287
|
self._send_if_duplicate = send_if_duplicate
|
|
287
288
|
self._has_anniversary_drip = has_anniversary_drip
|
|
288
289
|
self._has_birthday_drip = has_birthday_drip
|
|
290
|
+
self._total_cost = total_cost
|
|
289
291
|
|
|
290
292
|
__repr__ = helpers.repr
|
|
291
293
|
|
|
@@ -319,6 +321,11 @@ class Campaign:
|
|
|
319
321
|
"""True if one of more drips in this campaign are birthday drips. False otherwise."""
|
|
320
322
|
return self._has_birthday_drip
|
|
321
323
|
|
|
324
|
+
@property
|
|
325
|
+
def total_cost(self) -> int:
|
|
326
|
+
"""Drip campaign's total cost in `cents`."""
|
|
327
|
+
return self._total_cost
|
|
328
|
+
|
|
322
329
|
@classmethod
|
|
323
330
|
def _from_json(cls, json: dict):
|
|
324
331
|
return cls(
|
|
@@ -328,6 +335,7 @@ class Campaign:
|
|
|
328
335
|
send_if_duplicate=json['send_even_if_duplicate'],
|
|
329
336
|
has_anniversary_drip=json['has_anniversary_drip'],
|
|
330
337
|
has_birthday_drip=json['has_birthday_drip'],
|
|
338
|
+
total_cost=json['campaign_cost'],
|
|
331
339
|
)
|
|
332
340
|
|
|
333
341
|
class CardStatus(Enum):
|
|
@@ -875,11 +883,13 @@ class CampaignMultiResponse:
|
|
|
875
883
|
mailing_id: int,
|
|
876
884
|
contacts_scheduled_count: int,
|
|
877
885
|
duplicate_contacts_count: int,
|
|
886
|
+
contacts_scheduled_third_party_contact_ids: List[str],
|
|
878
887
|
message: str,
|
|
879
888
|
) -> None:
|
|
880
889
|
self._mailing_id = mailing_id
|
|
881
890
|
self._contacts_scheduled_count = contacts_scheduled_count
|
|
882
891
|
self._duplicate_contacts_count = duplicate_contacts_count
|
|
892
|
+
self._contacts_scheduled_third_party_contact_ids = contacts_scheduled_third_party_contact_ids
|
|
883
893
|
self._message = message
|
|
884
894
|
|
|
885
895
|
__repr__ = helpers.repr
|
|
@@ -904,6 +914,11 @@ class CampaignMultiResponse:
|
|
|
904
914
|
"""Number of contacts that were duplicates and not scheduled."""
|
|
905
915
|
return self._duplicate_contacts_count
|
|
906
916
|
|
|
917
|
+
@property
|
|
918
|
+
def contacts_scheduled_third_party_contact_ids(self) -> List[str]:
|
|
919
|
+
"""List of third party contact ids that were scheduled for the drip campaign."""
|
|
920
|
+
return self._contacts_scheduled_third_party_contact_ids
|
|
921
|
+
|
|
907
922
|
@property
|
|
908
923
|
def message(self) -> str:
|
|
909
924
|
"""Represents AMcards' response message for sending a drip campaign to multiple contacts."""
|
|
@@ -915,6 +930,7 @@ class CampaignMultiResponse:
|
|
|
915
930
|
mailing_id=json['mailing_id'],
|
|
916
931
|
contacts_scheduled_count=json['contacts_scheduled_count'],
|
|
917
932
|
duplicate_contacts_count=json['duplicate_contacts_count'],
|
|
933
|
+
contacts_scheduled_third_party_contact_ids=json['contacts_scheduled_third_party_contact_ids'],
|
|
918
934
|
message=json['message'],
|
|
919
935
|
)
|
|
920
936
|
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|