airbyte-agent-zendesk-support 0.18.46__py3-none-any.whl → 0.18.48__py3-none-any.whl

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.
@@ -53,6 +53,31 @@ from .types import (
53
53
  UsersListParams,
54
54
  ViewsGetParams,
55
55
  ViewsListParams,
56
+ SearchParams,
57
+ BrandsSearchFilter,
58
+ BrandsSearchQuery,
59
+ GroupsSearchFilter,
60
+ GroupsSearchQuery,
61
+ OrganizationsSearchFilter,
62
+ OrganizationsSearchQuery,
63
+ SatisfactionRatingsSearchFilter,
64
+ SatisfactionRatingsSearchQuery,
65
+ TagsSearchFilter,
66
+ TagsSearchQuery,
67
+ TicketAuditsSearchFilter,
68
+ TicketAuditsSearchQuery,
69
+ TicketCommentsSearchFilter,
70
+ TicketCommentsSearchQuery,
71
+ TicketFieldsSearchFilter,
72
+ TicketFieldsSearchQuery,
73
+ TicketFormsSearchFilter,
74
+ TicketFormsSearchQuery,
75
+ TicketMetricsSearchFilter,
76
+ TicketMetricsSearchQuery,
77
+ TicketsSearchFilter,
78
+ TicketsSearchQuery,
79
+ UsersSearchFilter,
80
+ UsersSearchQuery,
56
81
  )
57
82
  if TYPE_CHECKING:
58
83
  from .models import ZendeskSupportAuthConfig
@@ -106,6 +131,32 @@ from .models import (
106
131
  Trigger,
107
132
  User,
108
133
  View,
134
+ SearchHit,
135
+ SearchResult,
136
+ BrandsSearchData,
137
+ BrandsSearchResult,
138
+ GroupsSearchData,
139
+ GroupsSearchResult,
140
+ OrganizationsSearchData,
141
+ OrganizationsSearchResult,
142
+ SatisfactionRatingsSearchData,
143
+ SatisfactionRatingsSearchResult,
144
+ TagsSearchData,
145
+ TagsSearchResult,
146
+ TicketAuditsSearchData,
147
+ TicketAuditsSearchResult,
148
+ TicketCommentsSearchData,
149
+ TicketCommentsSearchResult,
150
+ TicketFieldsSearchData,
151
+ TicketFieldsSearchResult,
152
+ TicketFormsSearchData,
153
+ TicketFormsSearchResult,
154
+ TicketMetricsSearchData,
155
+ TicketMetricsSearchResult,
156
+ TicketsSearchData,
157
+ TicketsSearchResult,
158
+ UsersSearchData,
159
+ UsersSearchResult,
109
160
  )
110
161
 
111
162
  # TypeVar for decorator type preservation
@@ -121,7 +172,7 @@ class ZendeskSupportConnector:
121
172
  """
122
173
 
123
174
  connector_name = "zendesk-support"
124
- connector_version = "0.1.5"
175
+ connector_version = "0.1.6"
125
176
  vendored_sdk_version = "0.1.0" # Version of vendored connector-sdk
126
177
 
127
178
  # Map of (entity, action) -> needs_envelope for envelope wrapping decision
@@ -875,6 +926,99 @@ class TicketsQuery:
875
926
 
876
927
 
877
928
 
929
+ async def search(
930
+ self,
931
+ query: TicketsSearchQuery,
932
+ limit: int | None = None,
933
+ cursor: str | None = None,
934
+ fields: list[list[str]] | None = None,
935
+ ) -> TicketsSearchResult:
936
+ """
937
+ Search tickets records from Airbyte cache.
938
+
939
+ This operation searches cached data from Airbyte syncs.
940
+ Only available in hosted execution mode.
941
+
942
+ Available filter fields (TicketsSearchFilter):
943
+ - allow_attachments: Boolean indicating whether attachments are allowed on the ticket
944
+ - allow_channelback: Boolean indicating whether agents can reply to the ticket through the original channel
945
+ - assignee_id: Unique identifier of the agent currently assigned to the ticket
946
+ - brand_id: Unique identifier of the brand associated with the ticket in multi-brand accounts
947
+ - collaborator_ids: Array of user identifiers who are collaborating on the ticket
948
+ - created_at: Timestamp indicating when the ticket was created
949
+ - custom_fields: Array of custom field values specific to the account's ticket configuration
950
+ - custom_status_id: Unique identifier of the custom status applied to the ticket
951
+ - deleted_ticket_form_id: Unique identifier of the ticket form if it was deleted after the ticket was created
952
+ - description: Initial description or content of the ticket when it was created
953
+ - due_at: Timestamp indicating when the ticket is due for completion or resolution
954
+ - email_cc_ids: Array of user identifiers who are CC'd on ticket email notifications
955
+ - external_id: External identifier for the ticket, used for integrations with other systems
956
+ - fields: Array of ticket field values including both system and custom fields
957
+ - follower_ids: Array of user identifiers who are following the ticket for updates
958
+ - followup_ids: Array of identifiers for follow-up tickets related to this ticket
959
+ - forum_topic_id: Unique identifier linking the ticket to a forum topic if applicable
960
+ - from_messaging_channel: Boolean indicating whether the ticket originated from a messaging channel
961
+ - generated_timestamp: Timestamp updated for all ticket updates including system changes, used for incremental export co...
962
+ - group_id: Unique identifier of the agent group assigned to handle the ticket
963
+ - has_incidents: Boolean indicating whether this problem ticket has related incident tickets
964
+ - id: Unique identifier for the ticket
965
+ - is_public: Boolean indicating whether the ticket is publicly visible
966
+ - organization_id: Unique identifier of the organization associated with the ticket
967
+ - priority: Priority level assigned to the ticket (e.g., urgent, high, normal, low)
968
+ - problem_id: Unique identifier of the problem ticket if this is an incident ticket
969
+ - raw_subject: Original unprocessed subject line before any system modifications
970
+ - recipient: Email address or identifier of the ticket recipient
971
+ - requester_id: Unique identifier of the user who requested or created the ticket
972
+ - satisfaction_rating: Object containing customer satisfaction rating data for the ticket
973
+ - sharing_agreement_ids: Array of sharing agreement identifiers if the ticket is shared across Zendesk instances
974
+ - status: Current status of the ticket (e.g., new, open, pending, solved, closed)
975
+ - subject: Subject line of the ticket describing the issue or request
976
+ - submitter_id: Unique identifier of the user who submitted the ticket on behalf of the requester
977
+ - tags: Array of tags applied to the ticket for categorization and filtering
978
+ - ticket_form_id: Unique identifier of the ticket form used when creating the ticket
979
+ - type: Type of ticket (e.g., problem, incident, question, task)
980
+ - updated_at: Timestamp indicating when the ticket was last updated with a ticket event
981
+ - url: API URL to access the full ticket resource
982
+ - via: Object describing the channel and method through which the ticket was created
983
+
984
+ Args:
985
+ query: Filter and sort conditions. Supports operators like eq, neq, gt, gte, lt, lte,
986
+ in, like, fuzzy, keyword, not, and, or. Example: {"filter": {"eq": {"status": "active"}}}
987
+ limit: Maximum results to return (default 1000)
988
+ cursor: Pagination cursor from previous response's next_cursor
989
+ fields: Field paths to include in results. Each path is a list of keys for nested access.
990
+ Example: [["id"], ["user", "name"]] returns id and user.name fields.
991
+
992
+ Returns:
993
+ TicketsSearchResult with hits (list of SearchHit[TicketsSearchData]) and pagination info
994
+
995
+ Raises:
996
+ NotImplementedError: If called in local execution mode
997
+ """
998
+ params: dict[str, Any] = {"query": query}
999
+ if limit is not None:
1000
+ params["limit"] = limit
1001
+ if cursor is not None:
1002
+ params["cursor"] = cursor
1003
+ if fields is not None:
1004
+ params["fields"] = fields
1005
+
1006
+ result = await self._connector.execute("tickets", "search", params)
1007
+
1008
+ # Parse response into typed result
1009
+ return TicketsSearchResult(
1010
+ hits=[
1011
+ SearchHit[TicketsSearchData](
1012
+ id=hit.get("id"),
1013
+ score=hit.get("score"),
1014
+ data=TicketsSearchData(**hit.get("data", {}))
1015
+ )
1016
+ for hit in result.get("hits", [])
1017
+ ],
1018
+ next_cursor=result.get("next_cursor"),
1019
+ took_ms=result.get("took_ms")
1020
+ )
1021
+
878
1022
  class UsersQuery:
879
1023
  """
880
1024
  Query class for Users entity operations.
@@ -944,6 +1088,98 @@ class UsersQuery:
944
1088
 
945
1089
 
946
1090
 
1091
+ async def search(
1092
+ self,
1093
+ query: UsersSearchQuery,
1094
+ limit: int | None = None,
1095
+ cursor: str | None = None,
1096
+ fields: list[list[str]] | None = None,
1097
+ ) -> UsersSearchResult:
1098
+ """
1099
+ Search users records from Airbyte cache.
1100
+
1101
+ This operation searches cached data from Airbyte syncs.
1102
+ Only available in hosted execution mode.
1103
+
1104
+ Available filter fields (UsersSearchFilter):
1105
+ - active: Indicates if the user account is currently active
1106
+ - alias: Alternative name or nickname for the user
1107
+ - chat_only: Indicates if the user can only interact via chat
1108
+ - created_at: Timestamp indicating when the user was created
1109
+ - custom_role_id: Identifier for a custom role assigned to the user
1110
+ - default_group_id: Identifier of the default group assigned to the user
1111
+ - details: Additional descriptive information about the user
1112
+ - email: Email address of the user
1113
+ - external_id: External system identifier for the user, used for integrations
1114
+ - iana_time_zone: IANA standard time zone identifier for the user
1115
+ - id: Unique identifier for the user
1116
+ - last_login_at: Timestamp of the user's most recent login
1117
+ - locale: Locale setting determining language and regional format preferences
1118
+ - locale_id: Identifier for the user's locale preference
1119
+ - moderator: Indicates if the user has moderator privileges
1120
+ - name: Display name of the user
1121
+ - notes: Internal notes about the user, visible only to agents
1122
+ - only_private_comments: Indicates if the user can only make private comments on tickets
1123
+ - organization_id: Identifier of the organization the user belongs to
1124
+ - permanently_deleted: Indicates if the user has been permanently deleted from the system
1125
+ - phone: Phone number of the user
1126
+ - photo: Profile photo or avatar of the user
1127
+ - report_csv: Indicates if the user receives reports in CSV format
1128
+ - restricted_agent: Indicates if the agent has restricted access permissions
1129
+ - role: Role assigned to the user defining their permissions level
1130
+ - role_type: Type classification of the user's role
1131
+ - shared: Indicates if the user is shared across multiple accounts
1132
+ - shared_agent: Indicates if the user is a shared agent across multiple brands or accounts
1133
+ - shared_phone_number: Indicates if the phone number is shared with other users
1134
+ - signature: Email signature text for the user
1135
+ - suspended: Indicates if the user account is suspended
1136
+ - tags: Labels or tags associated with the user for categorization
1137
+ - ticket_restriction: Defines which tickets the user can access based on restrictions
1138
+ - time_zone: Time zone setting for the user
1139
+ - two_factor_auth_enabled: Indicates if two-factor authentication is enabled for the user
1140
+ - updated_at: Timestamp indicating when the user was last updated
1141
+ - url: API endpoint URL for accessing the user's detailed information
1142
+ - user_fields: Custom field values specific to the user, stored as key-value pairs
1143
+ - verified: Indicates if the user's identity has been verified
1144
+
1145
+ Args:
1146
+ query: Filter and sort conditions. Supports operators like eq, neq, gt, gte, lt, lte,
1147
+ in, like, fuzzy, keyword, not, and, or. Example: {"filter": {"eq": {"status": "active"}}}
1148
+ limit: Maximum results to return (default 1000)
1149
+ cursor: Pagination cursor from previous response's next_cursor
1150
+ fields: Field paths to include in results. Each path is a list of keys for nested access.
1151
+ Example: [["id"], ["user", "name"]] returns id and user.name fields.
1152
+
1153
+ Returns:
1154
+ UsersSearchResult with hits (list of SearchHit[UsersSearchData]) and pagination info
1155
+
1156
+ Raises:
1157
+ NotImplementedError: If called in local execution mode
1158
+ """
1159
+ params: dict[str, Any] = {"query": query}
1160
+ if limit is not None:
1161
+ params["limit"] = limit
1162
+ if cursor is not None:
1163
+ params["cursor"] = cursor
1164
+ if fields is not None:
1165
+ params["fields"] = fields
1166
+
1167
+ result = await self._connector.execute("users", "search", params)
1168
+
1169
+ # Parse response into typed result
1170
+ return UsersSearchResult(
1171
+ hits=[
1172
+ SearchHit[UsersSearchData](
1173
+ id=hit.get("id"),
1174
+ score=hit.get("score"),
1175
+ data=UsersSearchData(**hit.get("data", {}))
1176
+ )
1177
+ for hit in result.get("hits", [])
1178
+ ],
1179
+ next_cursor=result.get("next_cursor"),
1180
+ took_ms=result.get("took_ms")
1181
+ )
1182
+
947
1183
  class OrganizationsQuery:
948
1184
  """
949
1185
  Query class for Organizations entity operations.
@@ -1007,6 +1243,74 @@ class OrganizationsQuery:
1007
1243
 
1008
1244
 
1009
1245
 
1246
+ async def search(
1247
+ self,
1248
+ query: OrganizationsSearchQuery,
1249
+ limit: int | None = None,
1250
+ cursor: str | None = None,
1251
+ fields: list[list[str]] | None = None,
1252
+ ) -> OrganizationsSearchResult:
1253
+ """
1254
+ Search organizations records from Airbyte cache.
1255
+
1256
+ This operation searches cached data from Airbyte syncs.
1257
+ Only available in hosted execution mode.
1258
+
1259
+ Available filter fields (OrganizationsSearchFilter):
1260
+ - created_at: Timestamp when the organization was created
1261
+ - deleted_at: Timestamp when the organization was deleted
1262
+ - details: Details about the organization, such as the address
1263
+ - domain_names: Array of domain names associated with this organization for automatic user assignment
1264
+ - external_id: Unique external identifier to associate the organization to an external record (case-insensitive)
1265
+ - group_id: ID of the group where new tickets from users in this organization are automatically assigned
1266
+ - id: Unique identifier automatically assigned when the organization is created
1267
+ - name: Unique name for the organization (mandatory field)
1268
+ - notes: Notes about the organization
1269
+ - organization_fields: Key-value object for custom organization fields
1270
+ - shared_comments: Boolean indicating whether end users in this organization can comment on each other's tickets
1271
+ - shared_tickets: Boolean indicating whether end users in this organization can see each other's tickets
1272
+ - tags: Array of tags associated with the organization
1273
+ - updated_at: Timestamp of the last update to the organization
1274
+ - url: The API URL of this organization
1275
+
1276
+ Args:
1277
+ query: Filter and sort conditions. Supports operators like eq, neq, gt, gte, lt, lte,
1278
+ in, like, fuzzy, keyword, not, and, or. Example: {"filter": {"eq": {"status": "active"}}}
1279
+ limit: Maximum results to return (default 1000)
1280
+ cursor: Pagination cursor from previous response's next_cursor
1281
+ fields: Field paths to include in results. Each path is a list of keys for nested access.
1282
+ Example: [["id"], ["user", "name"]] returns id and user.name fields.
1283
+
1284
+ Returns:
1285
+ OrganizationsSearchResult with hits (list of SearchHit[OrganizationsSearchData]) and pagination info
1286
+
1287
+ Raises:
1288
+ NotImplementedError: If called in local execution mode
1289
+ """
1290
+ params: dict[str, Any] = {"query": query}
1291
+ if limit is not None:
1292
+ params["limit"] = limit
1293
+ if cursor is not None:
1294
+ params["cursor"] = cursor
1295
+ if fields is not None:
1296
+ params["fields"] = fields
1297
+
1298
+ result = await self._connector.execute("organizations", "search", params)
1299
+
1300
+ # Parse response into typed result
1301
+ return OrganizationsSearchResult(
1302
+ hits=[
1303
+ SearchHit[OrganizationsSearchData](
1304
+ id=hit.get("id"),
1305
+ score=hit.get("score"),
1306
+ data=OrganizationsSearchData(**hit.get("data", {}))
1307
+ )
1308
+ for hit in result.get("hits", [])
1309
+ ],
1310
+ next_cursor=result.get("next_cursor"),
1311
+ took_ms=result.get("took_ms")
1312
+ )
1313
+
1010
1314
  class GroupsQuery:
1011
1315
  """
1012
1316
  Query class for Groups entity operations.
@@ -1073,6 +1377,68 @@ class GroupsQuery:
1073
1377
 
1074
1378
 
1075
1379
 
1380
+ async def search(
1381
+ self,
1382
+ query: GroupsSearchQuery,
1383
+ limit: int | None = None,
1384
+ cursor: str | None = None,
1385
+ fields: list[list[str]] | None = None,
1386
+ ) -> GroupsSearchResult:
1387
+ """
1388
+ Search groups records from Airbyte cache.
1389
+
1390
+ This operation searches cached data from Airbyte syncs.
1391
+ Only available in hosted execution mode.
1392
+
1393
+ Available filter fields (GroupsSearchFilter):
1394
+ - created_at: Timestamp indicating when the group was created
1395
+ - default: Indicates if the group is the default one for the account
1396
+ - deleted: Indicates whether the group has been deleted
1397
+ - description: The description of the group
1398
+ - id: Unique identifier automatically assigned when creating groups
1399
+ - is_public: Indicates if the group is public (true) or private (false)
1400
+ - name: The name of the group
1401
+ - updated_at: Timestamp indicating when the group was last updated
1402
+ - url: The API URL of the group
1403
+
1404
+ Args:
1405
+ query: Filter and sort conditions. Supports operators like eq, neq, gt, gte, lt, lte,
1406
+ in, like, fuzzy, keyword, not, and, or. Example: {"filter": {"eq": {"status": "active"}}}
1407
+ limit: Maximum results to return (default 1000)
1408
+ cursor: Pagination cursor from previous response's next_cursor
1409
+ fields: Field paths to include in results. Each path is a list of keys for nested access.
1410
+ Example: [["id"], ["user", "name"]] returns id and user.name fields.
1411
+
1412
+ Returns:
1413
+ GroupsSearchResult with hits (list of SearchHit[GroupsSearchData]) and pagination info
1414
+
1415
+ Raises:
1416
+ NotImplementedError: If called in local execution mode
1417
+ """
1418
+ params: dict[str, Any] = {"query": query}
1419
+ if limit is not None:
1420
+ params["limit"] = limit
1421
+ if cursor is not None:
1422
+ params["cursor"] = cursor
1423
+ if fields is not None:
1424
+ params["fields"] = fields
1425
+
1426
+ result = await self._connector.execute("groups", "search", params)
1427
+
1428
+ # Parse response into typed result
1429
+ return GroupsSearchResult(
1430
+ hits=[
1431
+ SearchHit[GroupsSearchData](
1432
+ id=hit.get("id"),
1433
+ score=hit.get("score"),
1434
+ data=GroupsSearchData(**hit.get("data", {}))
1435
+ )
1436
+ for hit in result.get("hits", [])
1437
+ ],
1438
+ next_cursor=result.get("next_cursor"),
1439
+ took_ms=result.get("took_ms")
1440
+ )
1441
+
1076
1442
  class TicketCommentsQuery:
1077
1443
  """
1078
1444
  Query class for TicketComments entity operations.
@@ -1120,6 +1486,76 @@ class TicketCommentsQuery:
1120
1486
 
1121
1487
 
1122
1488
 
1489
+ async def search(
1490
+ self,
1491
+ query: TicketCommentsSearchQuery,
1492
+ limit: int | None = None,
1493
+ cursor: str | None = None,
1494
+ fields: list[list[str]] | None = None,
1495
+ ) -> TicketCommentsSearchResult:
1496
+ """
1497
+ Search ticket_comments records from Airbyte cache.
1498
+
1499
+ This operation searches cached data from Airbyte syncs.
1500
+ Only available in hosted execution mode.
1501
+
1502
+ Available filter fields (TicketCommentsSearchFilter):
1503
+ - attachments: List of files or media attached to the comment
1504
+ - audit_id: Identifier of the audit record associated with this comment event
1505
+ - author_id: Identifier of the user who created the comment
1506
+ - body: Content of the comment in its original format
1507
+ - created_at: Timestamp when the comment was created
1508
+ - event_type: Specific classification of the event within the ticket event stream
1509
+ - html_body: HTML-formatted content of the comment
1510
+ - id: Unique identifier for the comment event
1511
+ - metadata: Additional structured information about the comment not covered by standard fields
1512
+ - plain_body: Plain text content of the comment without formatting
1513
+ - public: Boolean indicating whether the comment is visible to end users or is an internal note
1514
+ - ticket_id: Identifier of the ticket to which this comment belongs
1515
+ - timestamp: Timestamp of when the event occurred in the incremental export stream
1516
+ - type: Type of event, typically indicating this is a comment event
1517
+ - uploads: Array of upload tokens or identifiers for files being attached to the comment
1518
+ - via: Channel or method through which the comment was submitted
1519
+ - via_reference_id: Reference identifier for the channel through which the comment was created
1520
+
1521
+ Args:
1522
+ query: Filter and sort conditions. Supports operators like eq, neq, gt, gte, lt, lte,
1523
+ in, like, fuzzy, keyword, not, and, or. Example: {"filter": {"eq": {"status": "active"}}}
1524
+ limit: Maximum results to return (default 1000)
1525
+ cursor: Pagination cursor from previous response's next_cursor
1526
+ fields: Field paths to include in results. Each path is a list of keys for nested access.
1527
+ Example: [["id"], ["user", "name"]] returns id and user.name fields.
1528
+
1529
+ Returns:
1530
+ TicketCommentsSearchResult with hits (list of SearchHit[TicketCommentsSearchData]) and pagination info
1531
+
1532
+ Raises:
1533
+ NotImplementedError: If called in local execution mode
1534
+ """
1535
+ params: dict[str, Any] = {"query": query}
1536
+ if limit is not None:
1537
+ params["limit"] = limit
1538
+ if cursor is not None:
1539
+ params["cursor"] = cursor
1540
+ if fields is not None:
1541
+ params["fields"] = fields
1542
+
1543
+ result = await self._connector.execute("ticket_comments", "search", params)
1544
+
1545
+ # Parse response into typed result
1546
+ return TicketCommentsSearchResult(
1547
+ hits=[
1548
+ SearchHit[TicketCommentsSearchData](
1549
+ id=hit.get("id"),
1550
+ score=hit.get("score"),
1551
+ data=TicketCommentsSearchData(**hit.get("data", {}))
1552
+ )
1553
+ for hit in result.get("hits", [])
1554
+ ],
1555
+ next_cursor=result.get("next_cursor"),
1556
+ took_ms=result.get("took_ms")
1557
+ )
1558
+
1123
1559
  class AttachmentsQuery:
1124
1560
  """
1125
1561
  Query class for Attachments entity operations.
@@ -1282,6 +1718,67 @@ class TicketAuditsQuery:
1282
1718
 
1283
1719
 
1284
1720
 
1721
+ async def search(
1722
+ self,
1723
+ query: TicketAuditsSearchQuery,
1724
+ limit: int | None = None,
1725
+ cursor: str | None = None,
1726
+ fields: list[list[str]] | None = None,
1727
+ ) -> TicketAuditsSearchResult:
1728
+ """
1729
+ Search ticket_audits records from Airbyte cache.
1730
+
1731
+ This operation searches cached data from Airbyte syncs.
1732
+ Only available in hosted execution mode.
1733
+
1734
+ Available filter fields (TicketAuditsSearchFilter):
1735
+ - attachments: Files or documents attached to the audit
1736
+ - author_id: The unique identifier of the user who created the audit
1737
+ - created_at: Timestamp indicating when the audit was created
1738
+ - events: Array of events that occurred in this audit, such as field changes, comments, or tag updates
1739
+ - id: Unique identifier for the audit record, automatically assigned when the audit is created
1740
+ - metadata: Custom and system data associated with the audit
1741
+ - ticket_id: The unique identifier of the ticket associated with this audit
1742
+ - via: Describes how the audit was created, providing context about the creation source
1743
+
1744
+ Args:
1745
+ query: Filter and sort conditions. Supports operators like eq, neq, gt, gte, lt, lte,
1746
+ in, like, fuzzy, keyword, not, and, or. Example: {"filter": {"eq": {"status": "active"}}}
1747
+ limit: Maximum results to return (default 1000)
1748
+ cursor: Pagination cursor from previous response's next_cursor
1749
+ fields: Field paths to include in results. Each path is a list of keys for nested access.
1750
+ Example: [["id"], ["user", "name"]] returns id and user.name fields.
1751
+
1752
+ Returns:
1753
+ TicketAuditsSearchResult with hits (list of SearchHit[TicketAuditsSearchData]) and pagination info
1754
+
1755
+ Raises:
1756
+ NotImplementedError: If called in local execution mode
1757
+ """
1758
+ params: dict[str, Any] = {"query": query}
1759
+ if limit is not None:
1760
+ params["limit"] = limit
1761
+ if cursor is not None:
1762
+ params["cursor"] = cursor
1763
+ if fields is not None:
1764
+ params["fields"] = fields
1765
+
1766
+ result = await self._connector.execute("ticket_audits", "search", params)
1767
+
1768
+ # Parse response into typed result
1769
+ return TicketAuditsSearchResult(
1770
+ hits=[
1771
+ SearchHit[TicketAuditsSearchData](
1772
+ id=hit.get("id"),
1773
+ score=hit.get("score"),
1774
+ data=TicketAuditsSearchData(**hit.get("data", {}))
1775
+ )
1776
+ for hit in result.get("hits", [])
1777
+ ],
1778
+ next_cursor=result.get("next_cursor"),
1779
+ took_ms=result.get("took_ms")
1780
+ )
1781
+
1285
1782
  class TicketMetricsQuery:
1286
1783
  """
1287
1784
  Query class for TicketMetrics entity operations.
@@ -1320,6 +1817,89 @@ class TicketMetricsQuery:
1320
1817
 
1321
1818
 
1322
1819
 
1820
+ async def search(
1821
+ self,
1822
+ query: TicketMetricsSearchQuery,
1823
+ limit: int | None = None,
1824
+ cursor: str | None = None,
1825
+ fields: list[list[str]] | None = None,
1826
+ ) -> TicketMetricsSearchResult:
1827
+ """
1828
+ Search ticket_metrics records from Airbyte cache.
1829
+
1830
+ This operation searches cached data from Airbyte syncs.
1831
+ Only available in hosted execution mode.
1832
+
1833
+ Available filter fields (TicketMetricsSearchFilter):
1834
+ - agent_wait_time_in_minutes: Number of minutes the agent spent waiting during calendar and business hours
1835
+ - assigned_at: Timestamp when the ticket was assigned
1836
+ - assignee_stations: Number of assignees the ticket had
1837
+ - assignee_updated_at: Timestamp when the assignee last updated the ticket
1838
+ - created_at: Timestamp when the metric record was created
1839
+ - custom_status_updated_at: Timestamp when the ticket's custom status was last updated
1840
+ - first_resolution_time_in_minutes: Number of minutes to the first resolution time during calendar and business hours
1841
+ - full_resolution_time_in_minutes: Number of minutes to the full resolution during calendar and business hours
1842
+ - generated_timestamp: Timestamp of when record was last updated
1843
+ - group_stations: Number of groups the ticket passed through
1844
+ - id: Unique identifier for the ticket metric record
1845
+ - initially_assigned_at: Timestamp when the ticket was initially assigned
1846
+ - instance_id: ID of the Zendesk instance associated with the ticket
1847
+ - latest_comment_added_at: Timestamp when the latest comment was added
1848
+ - metric: Ticket metrics data
1849
+ - on_hold_time_in_minutes: Number of minutes on hold
1850
+ - reopens: Total number of times the ticket was reopened
1851
+ - replies: The number of public replies added to a ticket by an agent
1852
+ - reply_time_in_minutes: Number of minutes to the first reply during calendar and business hours
1853
+ - reply_time_in_seconds: Number of seconds to the first reply during calendar hours, only available for Messaging tickets
1854
+ - requester_updated_at: Timestamp when the requester last updated the ticket
1855
+ - requester_wait_time_in_minutes: Number of minutes the requester spent waiting during calendar and business hours
1856
+ - solved_at: Timestamp when the ticket was solved
1857
+ - status: The current status of the ticket (open, pending, solved, etc.).
1858
+ - status_updated_at: Timestamp when the status of the ticket was last updated
1859
+ - ticket_id: Identifier of the associated ticket
1860
+ - time: Time related to the ticket
1861
+ - type: Type of ticket
1862
+ - updated_at: Timestamp when the metric record was last updated
1863
+ - url: The API url of the ticket metric
1864
+
1865
+ Args:
1866
+ query: Filter and sort conditions. Supports operators like eq, neq, gt, gte, lt, lte,
1867
+ in, like, fuzzy, keyword, not, and, or. Example: {"filter": {"eq": {"status": "active"}}}
1868
+ limit: Maximum results to return (default 1000)
1869
+ cursor: Pagination cursor from previous response's next_cursor
1870
+ fields: Field paths to include in results. Each path is a list of keys for nested access.
1871
+ Example: [["id"], ["user", "name"]] returns id and user.name fields.
1872
+
1873
+ Returns:
1874
+ TicketMetricsSearchResult with hits (list of SearchHit[TicketMetricsSearchData]) and pagination info
1875
+
1876
+ Raises:
1877
+ NotImplementedError: If called in local execution mode
1878
+ """
1879
+ params: dict[str, Any] = {"query": query}
1880
+ if limit is not None:
1881
+ params["limit"] = limit
1882
+ if cursor is not None:
1883
+ params["cursor"] = cursor
1884
+ if fields is not None:
1885
+ params["fields"] = fields
1886
+
1887
+ result = await self._connector.execute("ticket_metrics", "search", params)
1888
+
1889
+ # Parse response into typed result
1890
+ return TicketMetricsSearchResult(
1891
+ hits=[
1892
+ SearchHit[TicketMetricsSearchData](
1893
+ id=hit.get("id"),
1894
+ score=hit.get("score"),
1895
+ data=TicketMetricsSearchData(**hit.get("data", {}))
1896
+ )
1897
+ for hit in result.get("hits", [])
1898
+ ],
1899
+ next_cursor=result.get("next_cursor"),
1900
+ took_ms=result.get("took_ms")
1901
+ )
1902
+
1323
1903
  class TicketFieldsQuery:
1324
1904
  """
1325
1905
  Query class for TicketFields entity operations.
@@ -1386,6 +1966,86 @@ class TicketFieldsQuery:
1386
1966
 
1387
1967
 
1388
1968
 
1969
+ async def search(
1970
+ self,
1971
+ query: TicketFieldsSearchQuery,
1972
+ limit: int | None = None,
1973
+ cursor: str | None = None,
1974
+ fields: list[list[str]] | None = None,
1975
+ ) -> TicketFieldsSearchResult:
1976
+ """
1977
+ Search ticket_fields records from Airbyte cache.
1978
+
1979
+ This operation searches cached data from Airbyte syncs.
1980
+ Only available in hosted execution mode.
1981
+
1982
+ Available filter fields (TicketFieldsSearchFilter):
1983
+ - active: Whether this field is currently available for use
1984
+ - agent_description: A description of the ticket field that only agents can see
1985
+ - collapsed_for_agents: If true, the field is shown to agents by default; if false, it is hidden alongside infrequently u...
1986
+ - created_at: Timestamp when the custom ticket field was created
1987
+ - custom_field_options: Array of option objects for custom ticket fields of type multiselect or tagger, containing name a...
1988
+ - custom_statuses: List of customized ticket statuses, only present for system ticket fields of type custom_status
1989
+ - description: Text describing the purpose of the ticket field to users
1990
+ - editable_in_portal: Whether this field is editable by end users in Help Center
1991
+ - id: Unique identifier for the ticket field, automatically assigned when created
1992
+ - key: Internal identifier or reference key for the field
1993
+ - position: The relative position of the ticket field on a ticket, controlling display order
1994
+ - raw_description: The dynamic content placeholder if present, or the description value if not
1995
+ - raw_title: The dynamic content placeholder if present, or the title value if not
1996
+ - raw_title_in_portal: The dynamic content placeholder if present, or the title_in_portal value if not
1997
+ - regexp_for_validation: For regexp fields only, the validation pattern for a field value to be deemed valid
1998
+ - removable: If false, this field is a system field that must be present on all tickets
1999
+ - required: If true, agents must enter a value in the field to change the ticket status to solved
2000
+ - required_in_portal: If true, end users must enter a value in the field to create a request
2001
+ - sub_type_id: For system ticket fields of type priority and status, controlling available options
2002
+ - system_field_options: Array of options for system ticket fields of type tickettype, priority, or status
2003
+ - tag: For checkbox fields only, a tag added to tickets when the checkbox field is selected
2004
+ - title: The title of the ticket field displayed to agents
2005
+ - title_in_portal: The title of the ticket field displayed to end users in Help Center
2006
+ - type: Field type such as text, textarea, checkbox, date, integer, decimal, regexp, multiselect, tagger,...
2007
+ - updated_at: Timestamp when the custom ticket field was last updated
2008
+ - url: The API URL for this ticket field resource
2009
+ - visible_in_portal: Whether this field is visible to end users in Help Center
2010
+
2011
+ Args:
2012
+ query: Filter and sort conditions. Supports operators like eq, neq, gt, gte, lt, lte,
2013
+ in, like, fuzzy, keyword, not, and, or. Example: {"filter": {"eq": {"status": "active"}}}
2014
+ limit: Maximum results to return (default 1000)
2015
+ cursor: Pagination cursor from previous response's next_cursor
2016
+ fields: Field paths to include in results. Each path is a list of keys for nested access.
2017
+ Example: [["id"], ["user", "name"]] returns id and user.name fields.
2018
+
2019
+ Returns:
2020
+ TicketFieldsSearchResult with hits (list of SearchHit[TicketFieldsSearchData]) and pagination info
2021
+
2022
+ Raises:
2023
+ NotImplementedError: If called in local execution mode
2024
+ """
2025
+ params: dict[str, Any] = {"query": query}
2026
+ if limit is not None:
2027
+ params["limit"] = limit
2028
+ if cursor is not None:
2029
+ params["cursor"] = cursor
2030
+ if fields is not None:
2031
+ params["fields"] = fields
2032
+
2033
+ result = await self._connector.execute("ticket_fields", "search", params)
2034
+
2035
+ # Parse response into typed result
2036
+ return TicketFieldsSearchResult(
2037
+ hits=[
2038
+ SearchHit[TicketFieldsSearchData](
2039
+ id=hit.get("id"),
2040
+ score=hit.get("score"),
2041
+ data=TicketFieldsSearchData(**hit.get("data", {}))
2042
+ )
2043
+ for hit in result.get("hits", [])
2044
+ ],
2045
+ next_cursor=result.get("next_cursor"),
2046
+ took_ms=result.get("took_ms")
2047
+ )
2048
+
1389
2049
  class BrandsQuery:
1390
2050
  """
1391
2051
  Query class for Brands entity operations.
@@ -1449,6 +2109,75 @@ class BrandsQuery:
1449
2109
 
1450
2110
 
1451
2111
 
2112
+ async def search(
2113
+ self,
2114
+ query: BrandsSearchQuery,
2115
+ limit: int | None = None,
2116
+ cursor: str | None = None,
2117
+ fields: list[list[str]] | None = None,
2118
+ ) -> BrandsSearchResult:
2119
+ """
2120
+ Search brands records from Airbyte cache.
2121
+
2122
+ This operation searches cached data from Airbyte syncs.
2123
+ Only available in hosted execution mode.
2124
+
2125
+ Available filter fields (BrandsSearchFilter):
2126
+ - active: Indicates whether the brand is set as active
2127
+ - brand_url: The public URL of the brand
2128
+ - created_at: Timestamp when the brand was created
2129
+ - default: Indicates whether the brand is the default brand for tickets generated from non-branded channels
2130
+ - has_help_center: Indicates whether the brand has a Help Center enabled
2131
+ - help_center_state: The state of the Help Center, with allowed values of enabled, disabled, or restricted
2132
+ - host_mapping: The host mapping configuration for the brand, visible only to administrators
2133
+ - id: Unique identifier automatically assigned when the brand is created
2134
+ - is_deleted: Indicates whether the brand has been deleted
2135
+ - logo: Brand logo image file represented as an Attachment object
2136
+ - name: The name of the brand
2137
+ - signature_template: The signature template used for the brand
2138
+ - subdomain: The subdomain associated with the brand
2139
+ - ticket_form_ids: Array of ticket form IDs that are available for use by this brand
2140
+ - updated_at: Timestamp when the brand was last updated
2141
+ - url: The API URL for accessing this brand resource
2142
+
2143
+ Args:
2144
+ query: Filter and sort conditions. Supports operators like eq, neq, gt, gte, lt, lte,
2145
+ in, like, fuzzy, keyword, not, and, or. Example: {"filter": {"eq": {"status": "active"}}}
2146
+ limit: Maximum results to return (default 1000)
2147
+ cursor: Pagination cursor from previous response's next_cursor
2148
+ fields: Field paths to include in results. Each path is a list of keys for nested access.
2149
+ Example: [["id"], ["user", "name"]] returns id and user.name fields.
2150
+
2151
+ Returns:
2152
+ BrandsSearchResult with hits (list of SearchHit[BrandsSearchData]) and pagination info
2153
+
2154
+ Raises:
2155
+ NotImplementedError: If called in local execution mode
2156
+ """
2157
+ params: dict[str, Any] = {"query": query}
2158
+ if limit is not None:
2159
+ params["limit"] = limit
2160
+ if cursor is not None:
2161
+ params["cursor"] = cursor
2162
+ if fields is not None:
2163
+ params["fields"] = fields
2164
+
2165
+ result = await self._connector.execute("brands", "search", params)
2166
+
2167
+ # Parse response into typed result
2168
+ return BrandsSearchResult(
2169
+ hits=[
2170
+ SearchHit[BrandsSearchData](
2171
+ id=hit.get("id"),
2172
+ score=hit.get("score"),
2173
+ data=BrandsSearchData(**hit.get("data", {}))
2174
+ )
2175
+ for hit in result.get("hits", [])
2176
+ ],
2177
+ next_cursor=result.get("next_cursor"),
2178
+ took_ms=result.get("took_ms")
2179
+ )
2180
+
1452
2181
  class ViewsQuery:
1453
2182
  """
1454
2183
  Query class for Views entity operations.
@@ -1790,6 +2519,61 @@ class TagsQuery:
1790
2519
 
1791
2520
 
1792
2521
 
2522
+ async def search(
2523
+ self,
2524
+ query: TagsSearchQuery,
2525
+ limit: int | None = None,
2526
+ cursor: str | None = None,
2527
+ fields: list[list[str]] | None = None,
2528
+ ) -> TagsSearchResult:
2529
+ """
2530
+ Search tags records from Airbyte cache.
2531
+
2532
+ This operation searches cached data from Airbyte syncs.
2533
+ Only available in hosted execution mode.
2534
+
2535
+ Available filter fields (TagsSearchFilter):
2536
+ - count: The number of times this tag has been used across resources
2537
+ - name: The tag name string used to label and categorize resources
2538
+
2539
+ Args:
2540
+ query: Filter and sort conditions. Supports operators like eq, neq, gt, gte, lt, lte,
2541
+ in, like, fuzzy, keyword, not, and, or. Example: {"filter": {"eq": {"status": "active"}}}
2542
+ limit: Maximum results to return (default 1000)
2543
+ cursor: Pagination cursor from previous response's next_cursor
2544
+ fields: Field paths to include in results. Each path is a list of keys for nested access.
2545
+ Example: [["id"], ["user", "name"]] returns id and user.name fields.
2546
+
2547
+ Returns:
2548
+ TagsSearchResult with hits (list of SearchHit[TagsSearchData]) and pagination info
2549
+
2550
+ Raises:
2551
+ NotImplementedError: If called in local execution mode
2552
+ """
2553
+ params: dict[str, Any] = {"query": query}
2554
+ if limit is not None:
2555
+ params["limit"] = limit
2556
+ if cursor is not None:
2557
+ params["cursor"] = cursor
2558
+ if fields is not None:
2559
+ params["fields"] = fields
2560
+
2561
+ result = await self._connector.execute("tags", "search", params)
2562
+
2563
+ # Parse response into typed result
2564
+ return TagsSearchResult(
2565
+ hits=[
2566
+ SearchHit[TagsSearchData](
2567
+ id=hit.get("id"),
2568
+ score=hit.get("score"),
2569
+ data=TagsSearchData(**hit.get("data", {}))
2570
+ )
2571
+ for hit in result.get("hits", [])
2572
+ ],
2573
+ next_cursor=result.get("next_cursor"),
2574
+ took_ms=result.get("took_ms")
2575
+ )
2576
+
1793
2577
  class SatisfactionRatingsQuery:
1794
2578
  """
1795
2579
  Query class for SatisfactionRatings entity operations.
@@ -1862,6 +2646,71 @@ class SatisfactionRatingsQuery:
1862
2646
 
1863
2647
 
1864
2648
 
2649
+ async def search(
2650
+ self,
2651
+ query: SatisfactionRatingsSearchQuery,
2652
+ limit: int | None = None,
2653
+ cursor: str | None = None,
2654
+ fields: list[list[str]] | None = None,
2655
+ ) -> SatisfactionRatingsSearchResult:
2656
+ """
2657
+ Search satisfaction_ratings records from Airbyte cache.
2658
+
2659
+ This operation searches cached data from Airbyte syncs.
2660
+ Only available in hosted execution mode.
2661
+
2662
+ Available filter fields (SatisfactionRatingsSearchFilter):
2663
+ - assignee_id: The identifier of the agent assigned to the ticket at the time the rating was submitted
2664
+ - comment: Optional comment provided by the requester with the rating
2665
+ - created_at: Timestamp indicating when the satisfaction rating was created
2666
+ - group_id: The identifier of the group assigned to the ticket at the time the rating was submitted
2667
+ - id: Unique identifier for the satisfaction rating, automatically assigned upon creation
2668
+ - reason: Free-text reason for a bad rating provided by the requester in a follow-up question
2669
+ - reason_id: Identifier for the predefined reason given for a negative rating, only applicable when score is '...
2670
+ - requester_id: The identifier of the ticket requester who submitted the satisfaction rating
2671
+ - score: The satisfaction rating value: 'offered', 'unoffered', 'good', or 'bad'
2672
+ - ticket_id: The identifier of the ticket being rated
2673
+ - updated_at: Timestamp indicating when the satisfaction rating was last updated
2674
+ - url: The API URL of this satisfaction rating resource
2675
+
2676
+ Args:
2677
+ query: Filter and sort conditions. Supports operators like eq, neq, gt, gte, lt, lte,
2678
+ in, like, fuzzy, keyword, not, and, or. Example: {"filter": {"eq": {"status": "active"}}}
2679
+ limit: Maximum results to return (default 1000)
2680
+ cursor: Pagination cursor from previous response's next_cursor
2681
+ fields: Field paths to include in results. Each path is a list of keys for nested access.
2682
+ Example: [["id"], ["user", "name"]] returns id and user.name fields.
2683
+
2684
+ Returns:
2685
+ SatisfactionRatingsSearchResult with hits (list of SearchHit[SatisfactionRatingsSearchData]) and pagination info
2686
+
2687
+ Raises:
2688
+ NotImplementedError: If called in local execution mode
2689
+ """
2690
+ params: dict[str, Any] = {"query": query}
2691
+ if limit is not None:
2692
+ params["limit"] = limit
2693
+ if cursor is not None:
2694
+ params["cursor"] = cursor
2695
+ if fields is not None:
2696
+ params["fields"] = fields
2697
+
2698
+ result = await self._connector.execute("satisfaction_ratings", "search", params)
2699
+
2700
+ # Parse response into typed result
2701
+ return SatisfactionRatingsSearchResult(
2702
+ hits=[
2703
+ SearchHit[SatisfactionRatingsSearchData](
2704
+ id=hit.get("id"),
2705
+ score=hit.get("score"),
2706
+ data=SatisfactionRatingsSearchData(**hit.get("data", {}))
2707
+ )
2708
+ for hit in result.get("hits", [])
2709
+ ],
2710
+ next_cursor=result.get("next_cursor"),
2711
+ took_ms=result.get("took_ms")
2712
+ )
2713
+
1865
2714
  class GroupMembershipsQuery:
1866
2715
  """
1867
2716
  Query class for GroupMemberships entity operations.
@@ -2070,6 +2919,76 @@ class TicketFormsQuery:
2070
2919
 
2071
2920
 
2072
2921
 
2922
+ async def search(
2923
+ self,
2924
+ query: TicketFormsSearchQuery,
2925
+ limit: int | None = None,
2926
+ cursor: str | None = None,
2927
+ fields: list[list[str]] | None = None,
2928
+ ) -> TicketFormsSearchResult:
2929
+ """
2930
+ Search ticket_forms records from Airbyte cache.
2931
+
2932
+ This operation searches cached data from Airbyte syncs.
2933
+ Only available in hosted execution mode.
2934
+
2935
+ Available filter fields (TicketFormsSearchFilter):
2936
+ - active: Indicates if the form is set as active
2937
+ - agent_conditions: Array of condition sets for agent workspaces
2938
+ - created_at: Timestamp when the ticket form was created
2939
+ - default: Indicates if the form is the default form for this account
2940
+ - display_name: The name of the form that is displayed to an end user
2941
+ - end_user_conditions: Array of condition sets for end user products
2942
+ - end_user_visible: Indicates if the form is visible to the end user
2943
+ - id: Unique identifier for the ticket form, automatically assigned when creating the form
2944
+ - in_all_brands: Indicates if the form is available for use in all brands on this account
2945
+ - name: The name of the ticket form
2946
+ - position: The position of this form among other forms in the account, such as in a dropdown
2947
+ - raw_display_name: The dynamic content placeholder if present, or the display_name value if not
2948
+ - raw_name: The dynamic content placeholder if present, or the name value if not
2949
+ - restricted_brand_ids: IDs of all brands that this ticket form is restricted to
2950
+ - ticket_field_ids: IDs of all ticket fields included in this ticket form, ordered to determine field display sequenc...
2951
+ - updated_at: Timestamp of the last update to the ticket form
2952
+ - url: URL of the ticket form
2953
+
2954
+ Args:
2955
+ query: Filter and sort conditions. Supports operators like eq, neq, gt, gte, lt, lte,
2956
+ in, like, fuzzy, keyword, not, and, or. Example: {"filter": {"eq": {"status": "active"}}}
2957
+ limit: Maximum results to return (default 1000)
2958
+ cursor: Pagination cursor from previous response's next_cursor
2959
+ fields: Field paths to include in results. Each path is a list of keys for nested access.
2960
+ Example: [["id"], ["user", "name"]] returns id and user.name fields.
2961
+
2962
+ Returns:
2963
+ TicketFormsSearchResult with hits (list of SearchHit[TicketFormsSearchData]) and pagination info
2964
+
2965
+ Raises:
2966
+ NotImplementedError: If called in local execution mode
2967
+ """
2968
+ params: dict[str, Any] = {"query": query}
2969
+ if limit is not None:
2970
+ params["limit"] = limit
2971
+ if cursor is not None:
2972
+ params["cursor"] = cursor
2973
+ if fields is not None:
2974
+ params["fields"] = fields
2975
+
2976
+ result = await self._connector.execute("ticket_forms", "search", params)
2977
+
2978
+ # Parse response into typed result
2979
+ return TicketFormsSearchResult(
2980
+ hits=[
2981
+ SearchHit[TicketFormsSearchData](
2982
+ id=hit.get("id"),
2983
+ score=hit.get("score"),
2984
+ data=TicketFormsSearchData(**hit.get("data", {}))
2985
+ )
2986
+ for hit in result.get("hits", [])
2987
+ ],
2988
+ next_cursor=result.get("next_cursor"),
2989
+ took_ms=result.get("took_ms")
2990
+ )
2991
+
2073
2992
  class ArticlesQuery:
2074
2993
  """
2075
2994
  Query class for Articles entity operations.