@@ -85,6 +85,9 @@ class SiteItem:
8585 state: str
8686 Shows the current state of the site (Active or Suspended).
8787
88+ attribute_capture_enabled: Optional[str]
89+ Enables user attributes for all Tableau Server embedding workflows.
90+
8891 """
8992
9093 _user_quota : Optional [int ] = None
@@ -164,6 +167,7 @@ def __init__(
164167 time_zone = None ,
165168 auto_suspend_refresh_enabled : bool = True ,
166169 auto_suspend_refresh_inactivity_window : int = 30 ,
170+ attribute_capture_enabled : Optional [bool ] = None ,
167171 ):
168172 self ._admin_mode = None
169173 self ._id : Optional [str ] = None
@@ -217,6 +221,7 @@ def __init__(
217221 self .time_zone = time_zone
218222 self .auto_suspend_refresh_enabled = auto_suspend_refresh_enabled
219223 self .auto_suspend_refresh_inactivity_window = auto_suspend_refresh_inactivity_window
224+ self .attribute_capture_enabled = attribute_capture_enabled
220225
221226 @property
222227 def admin_mode (self ) -> Optional [str ]:
@@ -720,6 +725,7 @@ def _parse_common_tags(self, site_xml, ns):
720725 time_zone ,
721726 auto_suspend_refresh_enabled ,
722727 auto_suspend_refresh_inactivity_window ,
728+ attribute_capture_enabled ,
723729 ) = self ._parse_element (site_xml , ns )
724730
725731 self ._set_values (
@@ -774,6 +780,7 @@ def _parse_common_tags(self, site_xml, ns):
774780 time_zone ,
775781 auto_suspend_refresh_enabled ,
776782 auto_suspend_refresh_inactivity_window ,
783+ attribute_capture_enabled ,
777784 )
778785 return self
779786
@@ -830,6 +837,7 @@ def _set_values(
830837 time_zone ,
831838 auto_suspend_refresh_enabled ,
832839 auto_suspend_refresh_inactivity_window ,
840+ attribute_capture_enabled ,
833841 ):
834842 if id is not None :
835843 self ._id = id
@@ -937,6 +945,7 @@ def _set_values(
937945 self .auto_suspend_refresh_enabled = auto_suspend_refresh_enabled
938946 if auto_suspend_refresh_inactivity_window is not None :
939947 self .auto_suspend_refresh_inactivity_window = auto_suspend_refresh_inactivity_window
948+ self .attribute_capture_enabled = attribute_capture_enabled
940949
941950 @classmethod
942951 def from_response (cls , resp , ns ) -> list ["SiteItem" ]:
@@ -996,6 +1005,7 @@ def from_response(cls, resp, ns) -> list["SiteItem"]:
9961005 time_zone ,
9971006 auto_suspend_refresh_enabled ,
9981007 auto_suspend_refresh_inactivity_window ,
1008+ attribute_capture_enabled ,
9991009 ) = cls ._parse_element (site_xml , ns )
10001010
10011011 site_item = cls (name , content_url )
@@ -1051,6 +1061,7 @@ def from_response(cls, resp, ns) -> list["SiteItem"]:
10511061 time_zone ,
10521062 auto_suspend_refresh_enabled ,
10531063 auto_suspend_refresh_inactivity_window ,
1064+ attribute_capture_enabled ,
10541065 )
10551066 all_site_items .append (site_item )
10561067 return all_site_items
@@ -1132,6 +1143,9 @@ def _parse_element(site_xml, ns):
11321143
11331144 flows_enabled = string_to_bool (site_xml .get ("flowsEnabled" , "" ))
11341145 cataloging_enabled = string_to_bool (site_xml .get ("catalogingEnabled" , "" ))
1146+ attribute_capture_enabled = (
1147+ string_to_bool (ace ) if (ace := site_xml .get ("attributeCaptureEnabled" )) is not None else None
1148+ )
11351149
11361150 return (
11371151 id ,
@@ -1185,6 +1199,7 @@ def _parse_element(site_xml, ns):
11851199 time_zone ,
11861200 auto_suspend_refresh_enabled ,
11871201 auto_suspend_refresh_inactivity_window ,
1202+ attribute_capture_enabled ,
11881203 )
11891204
11901205
0 commit comments