Skip to content

Commit c0ad186

Browse files
pnilankatmarkham
andauthored
[source-zendesk-support] - Update cursor_field for TicketMetrics stream to be generated_timestamp (#43446)
Co-authored-by: katmarkham <[email protected]>
1 parent 34c76fb commit c0ad186

28 files changed

+739
-192
lines changed

airbyte-integrations/connectors/source-zendesk-support/integration_tests/abnormal_state.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@
5858
{
5959
"type": "STREAM",
6060
"stream": {
61-
"stream_state": { "updated_at": "2222-07-19T22:21:26Z" },
61+
"stream_state": { "generated_timestamp": 8001820514 },
6262
"stream_descriptor": { "name": "ticket_metrics" }
6363
}
6464
},

airbyte-integrations/connectors/source-zendesk-support/integration_tests/configured_catalog.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,7 @@
182182
"json_schema": {},
183183
"supported_sync_modes": ["full_refresh", "incremental"],
184184
"source_defined_cursor": true,
185-
"default_cursor_field": ["updated_at"],
185+
"default_cursor_field": ["generated_timestamp"],
186186
"source_defined_primary_key": [["id"]]
187187
},
188188
"sync_mode": "full_refresh",

airbyte-integrations/connectors/source-zendesk-support/integration_tests/expected_records.jsonl

+3-3
Original file line numberDiff line numberDiff line change
@@ -62,9 +62,9 @@
6262
{"stream": "tickets", "data": {"url": "https://d3v-airbyte.zendesk.com/api/v2/tickets/145.json", "id": 145, "external_id": null, "via": {"channel": "voice", "source": {"rel": "voicemail", "from": {"formatted_phone": "+1 (234) 601-8567", "phone": "+12346018567", "name": "Caller +1 (234) 601-8567"}, "to": {"formatted_phone": "+1 (205) 953-1462", "phone": "+12059531462", "name": "Airbyte", "brand_id": 360000358316}}}, "created_at": "2022-09-19T14:53:49Z", "updated_at": "2023-04-12T14:04:56Z", "generated_timestamp": 1681308296, "type": "question", "subject": "Voicemail from: Caller +1 (234) 601-8567", "raw_subject": "Voicemail from: Caller +1 (234) 601-8567", "description": "Call from: +1 (234) 601-8567\\nTime of call: September 19, 2022 at 2:52:39 PM", "priority": "low", "status": "new", "recipient": null, "requester_id": 5527111815439, "submitter_id": 5527111815439, "assignee_id": null, "organization_id": null, "group_id": null, "collaborator_ids": [], "follower_ids": [], "email_cc_ids": [], "forum_topic_id": null, "problem_id": null, "has_incidents": false, "is_public": false, "due_at": null, "tags": ["tag1204", "test"], "custom_fields": [], "satisfaction_rating": {"score": "offered"}, "sharing_agreement_ids": [], "custom_status_id": 4044356, "fields": [], "followup_ids": [], "ticket_form_id": 360000084116, "brand_id": 360000358316, "allow_channelback": false, "allow_attachments": true, "from_messaging_channel": false}, "emitted_at": 1720179640459}
6363
{"stream": "tickets", "data": {"url": "https://d3v-airbyte.zendesk.com/api/v2/tickets/1.json", "id": 1, "external_id": null, "via": {"channel": "sample_ticket", "source": {"from": {}, "to": {}, "rel": null}}, "created_at": "2020-12-11T18:34:09Z", "updated_at": "2023-05-26T23:02:01Z", "generated_timestamp": 1685142121, "type": "incident", "subject": "6X/BPh9kL+8K2NGI", "raw_subject": "6X/BPh9kL+8K2NGI", "description": "Hi Team,\n\nThis is your first ticket. Ta-da! Any customer request sent to your supported channels (email, chat, voicemail, web form, and tweet) will become a Support ticket, just like this one. Respond to this ticket by typing a message above and clicking Submit. You can also see how an email becomes a ticket by emailing your new account, [email protected]. Your ticket will appear in ticket views.\n\nThat's the ticket on tickets. If you want to learn more, check out: \nhttps://support.zendesk.com/hc/en-us/articles/203691476\n", "priority": "normal", "status": "closed", "recipient": null, "requester_id": 360839922496, "submitter_id": 360786799676, "assignee_id": 360786799676, "organization_id": null, "group_id": 360003074836, "collaborator_ids": [], "follower_ids": [], "email_cc_ids": [], "forum_topic_id": null, "problem_id": null, "has_incidents": false, "is_public": true, "due_at": null, "tags": ["sample", "support", "zendesk"], "custom_fields": [], "satisfaction_rating": {"score": "unoffered"}, "sharing_agreement_ids": [], "custom_status_id": 4044436, "fields": [], "followup_ids": [], "ticket_form_id": 360000084116, "brand_id": 360000358316, "allow_channelback": false, "allow_attachments": true, "from_messaging_channel": false}, "emitted_at": 1720179640460}
6464
{"stream": "tickets", "data": {"url": "https://d3v-airbyte.zendesk.com/api/v2/tickets/146.json", "id": 146, "external_id": null, "via": {"channel": "web", "source": {"from": {}, "to": {}, "rel": null}}, "created_at": "2023-06-19T16:28:23Z", "updated_at": "2023-06-26T10:10:06Z", "generated_timestamp": 1687774207, "type": null, "subject": "hhhhhhh", "raw_subject": "hhhhhhh", "description": "nnnnn", "priority": "low", "status": "open", "recipient": null, "requester_id": 361089721035, "submitter_id": 360786799676, "assignee_id": null, "organization_id": null, "group_id": null, "collaborator_ids": [], "follower_ids": [], "email_cc_ids": [], "forum_topic_id": null, "problem_id": null, "has_incidents": false, "is_public": true, "due_at": null, "tags": [], "custom_fields": [], "satisfaction_rating": {"score": "offered"}, "sharing_agreement_ids": [], "custom_status_id": 4044376, "fields": [], "followup_ids": [], "ticket_form_id": 360000084116, "brand_id": 360000358316, "allow_channelback": false, "allow_attachments": true, "from_messaging_channel": false}, "emitted_at": 1720179640461}
65-
{"stream": "ticket_metrics", "data": {"url": "https://d3v-airbyte.zendesk.com/api/v2/ticket_metrics/361110475196.json", "id": 361110475196, "ticket_id": 1, "created_at": "2020-12-11T18:34:09Z", "updated_at": "2023-05-06T22:04:16Z", "group_stations": 1, "assignee_stations": 1, "reopens": 0, "replies": 8, "assignee_updated_at": "2023-05-06T22:04:16Z", "requester_updated_at": "2020-12-11T18:34:09Z", "status_updated_at": "2023-05-26T23:02:01Z", "initially_assigned_at": "2020-12-11T18:34:09Z", "assigned_at": "2020-12-11T18:34:09Z", "solved_at": "2023-05-06T22:04:16Z", "latest_comment_added_at": "2022-03-17T15:33:41Z", "reply_time_in_minutes": {"calendar": 280172, "business": 280172}, "first_resolution_time_in_minutes": {"calendar": 1261650, "business": 300000}, "full_resolution_time_in_minutes": {"calendar": 1261650, "business": 300000}, "agent_wait_time_in_minutes": {"calendar": 0, "business": 0}, "requester_wait_time_in_minutes": {"calendar": 1261650, "business": 300000}, "on_hold_time_in_minutes": {"calendar": 0, "business": 0}, "custom_status_updated_at": "2023-05-06T22:04:16Z"}, "emitted_at": 1720179642913}
66-
{"stream": "ticket_metrics", "data": {"url": "https://d3v-airbyte.zendesk.com/api/v2/ticket_metrics/7235378171407.json", "id": 7235378171407, "ticket_id": 146, "created_at": "2023-06-19T16:28:23Z", "updated_at": "2023-06-26T10:10:06Z", "group_stations": 0, "assignee_stations": 0, "reopens": 0, "replies": 1, "assignee_updated_at": null, "requester_updated_at": "2023-06-19T16:28:23Z", "status_updated_at": "2023-06-26T10:10:06Z", "initially_assigned_at": null, "assigned_at": null, "solved_at": null, "latest_comment_added_at": "2023-06-26T10:10:06Z", "reply_time_in_minutes": {"calendar": 9702, "business": 2400}, "first_resolution_time_in_minutes": {"calendar": null, "business": null}, "full_resolution_time_in_minutes": {"calendar": null, "business": null}, "agent_wait_time_in_minutes": {"calendar": null, "business": null}, "requester_wait_time_in_minutes": {"calendar": 9702, "business": 2400}, "on_hold_time_in_minutes": {"calendar": 0, "business": 0}, "custom_status_updated_at": "2023-06-26T10:10:06Z"}, "emitted_at": 1720179643326}
67-
{"stream": "ticket_metrics", "data": {"url": "https://d3v-airbyte.zendesk.com/api/v2/ticket_metrics/7282901696015.json", "id": 7282901696015, "ticket_id": 151, "created_at": "2023-06-26T11:09:33Z", "updated_at": "2023-06-26T12:03:38Z", "group_stations": 1, "assignee_stations": 1, "reopens": 0, "replies": 1, "assignee_updated_at": "2023-06-26T12:03:37Z", "requester_updated_at": "2023-06-26T11:09:33Z", "status_updated_at": "2023-06-26T11:09:33Z", "initially_assigned_at": "2023-06-26T11:09:33Z", "assigned_at": "2023-06-26T11:09:33Z", "solved_at": null, "latest_comment_added_at": "2023-06-26T12:03:37Z", "reply_time_in_minutes": {"calendar": 54, "business": 0}, "first_resolution_time_in_minutes": {"calendar": null, "business": null}, "full_resolution_time_in_minutes": {"calendar": null, "business": null}, "agent_wait_time_in_minutes": {"calendar": null, "business": null}, "requester_wait_time_in_minutes": {"calendar": null, "business": null}, "on_hold_time_in_minutes": {"calendar": 0, "business": 0}, "custom_status_updated_at": "2023-06-26T11:09:33Z"}, "emitted_at": 1720179643725}
65+
{"stream":"ticket_metrics","data":{"url":"https://d3v-airbyte.zendesk.com/api/v2/ticket_metrics/5527084754447.json","id":5527084754447,"ticket_id":145,"created_at":"2022-09-19T14:53:49Z","updated_at":"2022-09-19T14:53:49Z","group_stations":0,"assignee_stations":0,"reopens":0,"replies":0,"assignee_updated_at":null,"requester_updated_at":"2022-09-19T14:53:49Z","status_updated_at":"2022-09-19T14:53:49Z","initially_assigned_at":null,"assigned_at":null,"solved_at":null,"latest_comment_added_at":"2022-09-19T14:53:49Z","reply_time_in_minutes":{"calendar":null,"business":null},"first_resolution_time_in_minutes":{"calendar":null,"business":null},"full_resolution_time_in_minutes":{"calendar":null,"business":null},"agent_wait_time_in_minutes":{"calendar":null,"business":null},"requester_wait_time_in_minutes":{"calendar":null,"business":null},"on_hold_time_in_minutes":{"calendar":0,"business":0},"custom_status_updated_at":"2022-09-19T14:53:49Z","generated_timestamp":1681308296},"emitted_at":1723477820009}
66+
{"stream":"ticket_metrics","data":{"url":"https://d3v-airbyte.zendesk.com/api/v2/ticket_metrics/361110475196.json","id":361110475196,"ticket_id":1,"created_at":"2020-12-11T18:34:09Z","updated_at":"2023-05-06T22:04:16Z","group_stations":1,"assignee_stations":1,"reopens":0,"replies":8,"assignee_updated_at":"2023-05-06T22:04:16Z","requester_updated_at":"2020-12-11T18:34:09Z","status_updated_at":"2023-05-26T23:02:01Z","initially_assigned_at":"2020-12-11T18:34:09Z","assigned_at":"2020-12-11T18:34:09Z","solved_at":"2023-05-06T22:04:16Z","latest_comment_added_at":"2022-03-17T15:33:41Z","reply_time_in_minutes":{"calendar":280172,"business":280172},"first_resolution_time_in_minutes":{"calendar":1261650,"business":300000},"full_resolution_time_in_minutes":{"calendar":1261650,"business":300000},"agent_wait_time_in_minutes":{"calendar":0,"business":0},"requester_wait_time_in_minutes":{"calendar":1261650,"business":300000},"on_hold_time_in_minutes":{"calendar":0,"business":0},"custom_status_updated_at":"2023-05-06T22:04:16Z","generated_timestamp":1685142121},"emitted_at":1723477820325}
67+
{"stream":"ticket_metrics","data":{"url":"https://d3v-airbyte.zendesk.com/api/v2/ticket_metrics/7235378171407.json","id":7235378171407,"ticket_id":146,"created_at":"2023-06-19T16:28:23Z","updated_at":"2023-06-26T10:10:06Z","group_stations":0,"assignee_stations":0,"reopens":0,"replies":1,"assignee_updated_at":null,"requester_updated_at":"2023-06-19T16:28:23Z","status_updated_at":"2023-06-26T10:10:06Z","initially_assigned_at":null,"assigned_at":null,"solved_at":null,"latest_comment_added_at":"2023-06-26T10:10:06Z","reply_time_in_minutes":{"calendar":9702,"business":2400},"first_resolution_time_in_minutes":{"calendar":null,"business":null},"full_resolution_time_in_minutes":{"calendar":null,"business":null},"agent_wait_time_in_minutes":{"calendar":null,"business":null},"requester_wait_time_in_minutes":{"calendar":9702,"business":2400},"on_hold_time_in_minutes":{"calendar":0,"business":0},"custom_status_updated_at":"2023-06-26T10:10:06Z","generated_timestamp":1687774207},"emitted_at":1723477820604}
6868
{"stream": "account_attributes", "data": {"url": "https://d3v-airbyte.zendesk.com/api/v2/routing/attributes/ac43b460-0ebd-11ee-85a3-4750db6aa722.json", "id": "ac43b460-0ebd-11ee-85a3-4750db6aa722", "name": "Language", "created_at": "2023-06-19T16:23:49Z", "updated_at": "2023-06-19T16:23:49Z"}, "emitted_at": 1720179651758}
6969
{"stream": "account_attributes", "data": {"url": "https://d3v-airbyte.zendesk.com/api/v2/routing/attributes/c15cdb76-0ebd-11ee-a37f-f315f48c0150.json", "id": "c15cdb76-0ebd-11ee-a37f-f315f48c0150", "name": "Quality", "created_at": "2023-06-19T16:24:25Z", "updated_at": "2023-06-19T16:24:25Z"}, "emitted_at": 1720179651762}
7070
{"stream": "attribute_definitions", "data": {"title": "Number of incidents", "subject": "number_of_incidents", "type": "text", "group": "ticket", "nullable": false, "repeatable": false, "operators": [{"value": "less_than", "title": "Less than", "terminal": false}, {"value": "greater_than", "title": "Greater than", "terminal": false}, {"value": "is", "title": "Is", "terminal": false}, {"value": "less_than_equal", "title": "Less than or equal to", "terminal": false}, {"value": "greater_than_equal", "title": "Greater than or equal to", "terminal": false}], "condition": "all"}, "emitted_at": 1720179652463}

airbyte-integrations/connectors/source-zendesk-support/integration_tests/incremental_catalog.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,7 @@
150150
"json_schema": {},
151151
"supported_sync_modes": ["full_refresh", "incremental"],
152152
"source_defined_cursor": true,
153-
"default_cursor_field": ["updated_at"],
153+
"default_cursor_field": ["generated_timestamp"],
154154
"source_defined_primary_key": [["id"]]
155155
},
156156
"sync_mode": "incremental",

airbyte-integrations/connectors/source-zendesk-support/metadata.yaml

+8-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ data:
1111
connectorSubtype: api
1212
connectorType: source
1313
definitionId: 79c1aa37-dae3-42ae-b333-d1c105477715
14-
dockerImageTag: 2.7.3
14+
dockerImageTag: 3.0.0
1515
dockerRepository: airbyte/source-zendesk-support
1616
documentationUrl: https://docs.airbyte.com/integrations/sources/zendesk-support
1717
githubIssueLabel: source-zendesk-support
@@ -37,6 +37,13 @@ data:
3737
2.0.0:
3838
message: The `Deleted Tickets` stream was removed. Deleted tickets are still available from the Tickets stream.
3939
upgradeDeadline: "2023-10-04"
40+
3.0.0:
41+
message: "This version includes breaking changes to the `TicketsMetric` stream. The cursor field has been updated to `generated_timestamp`. It is necessary to refresh the data and schema for the affected stream. Please see the migration guide for additional details."
42+
upgradeDeadline: "2024-09-09"
43+
scopedImpact:
44+
- scopeType: stream
45+
impactedScopes:
46+
- "ticket_metrics"
4047
suggestedStreams:
4148
streams:
4249
- brands

0 commit comments

Comments
 (0)