aboutsummaryrefslogtreecommitdiff
path: root/.venv/lib/python3.12/site-packages/sendgrid/helpers/mail/groups_to_display.py
diff options
context:
space:
mode:
Diffstat (limited to '.venv/lib/python3.12/site-packages/sendgrid/helpers/mail/groups_to_display.py')
-rw-r--r--.venv/lib/python3.12/site-packages/sendgrid/helpers/mail/groups_to_display.py48
1 files changed, 48 insertions, 0 deletions
diff --git a/.venv/lib/python3.12/site-packages/sendgrid/helpers/mail/groups_to_display.py b/.venv/lib/python3.12/site-packages/sendgrid/helpers/mail/groups_to_display.py
new file mode 100644
index 00000000..2e3fca77
--- /dev/null
+++ b/.venv/lib/python3.12/site-packages/sendgrid/helpers/mail/groups_to_display.py
@@ -0,0 +1,48 @@
+class GroupsToDisplay(object):
+ """The unsubscribe groups that you would like to be displayed on the
+ unsubscribe preferences page.."""
+
+ def __init__(self, groups_to_display=None):
+ """Create a GroupsToDisplay object
+
+ :param groups_to_display: An array containing the unsubscribe groups
+ that you would like to be displayed on the
+ unsubscribe preferences page.
+ :type groups_to_display: array of integers, optional
+ """
+ self._groups_to_display = None
+
+ if groups_to_display is not None:
+ self.groups_to_display = groups_to_display
+
+ @property
+ def groups_to_display(self):
+ """An array containing the unsubscribe groups that you would like to be
+ displayed on the unsubscribe preferences page.
+
+ :rtype: array(int)
+ """
+ return self._groups_to_display
+
+ @groups_to_display.setter
+ def groups_to_display(self, value):
+ """An array containing the unsubscribe groups that you would like to be
+ displayed on the unsubscribe preferences page.
+
+ :param value: An array containing the unsubscribe groups that you
+ would like to be displayed on the unsubscribe
+ preferences page.
+ :type value: array(int)
+ """
+ if value is not None and len(value) > 25:
+ raise ValueError("New groups_to_display exceeds max length of 25.")
+ self._groups_to_display = value
+
+ def get(self):
+ """
+ Get a JSON-ready representation of this GroupsToDisplay.
+
+ :returns: This GroupsToDisplay, ready for use in a request body.
+ :rtype: array of integers
+ """
+ return self.groups_to_display