From fc1c638f1da4f1d66cbedd8b0383d0b4846318c9 Mon Sep 17 00:00:00 2001 From: Arsen Losenko <20901439+arsenlosenko@users.noreply.github.com> Date: Wed, 5 Jul 2023 12:52:09 +0300 Subject: [PATCH 1/2] Source Pipedrive: update expected records --- .../integration_tests/expected_records.jsonl | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/airbyte-integrations/connectors/source-pipedrive/integration_tests/expected_records.jsonl b/airbyte-integrations/connectors/source-pipedrive/integration_tests/expected_records.jsonl index 32b8b8b83296..237655862c67 100644 --- a/airbyte-integrations/connectors/source-pipedrive/integration_tests/expected_records.jsonl +++ b/airbyte-integrations/connectors/source-pipedrive/integration_tests/expected_records.jsonl @@ -32,9 +32,9 @@ {"stream": "organizations", "data": {"id": 12, "company_id": 7780468, "owner_id": 11884360, "name": "Test Organization 7", "open_deals_count": 0, "related_open_deals_count": 0, "closed_deals_count": 0, "related_closed_deals_count": 0, "email_messages_count": 0, "people_count": 0, "activities_count": 0, "done_activities_count": 0, "undone_activities_count": 0, "files_count": 0, "notes_count": 0, "followers_count": 1, "won_deals_count": 0, "related_won_deals_count": 0, "lost_deals_count": 0, "related_lost_deals_count": 0, "active_flag": true, "category_id": null, "picture_id": null, "country_code": null, "first_char": "t", "update_time": "2023-02-22 08:21:58", "delete_time": null, "add_time": "2023-02-22 08:18:16", "visible_to": "3", "next_activity_date": null, "next_activity_time": null, "next_activity_id": null, "last_activity_id": null, "last_activity_date": null, "label": 5, "address": "DY Patil College, Sant Tukaram Nagar, Pimpri Colony, Pimpri-Chinchwad, Maharashtra, India", "address_subpremise": "", "address_street_number": "", "address_route": "", "address_sublocality": "Pimpri Colony", "address_locality": "Pimpri-Chinchwad", "address_admin_area_level_1": "Maharashtra", "address_admin_area_level_2": "Pune Division", "address_country": "India", "address_postal_code": "411018", "address_formatted_address": "DY Patil College, DR. D Y PATIL MEDICAL COLLEGE, Sant Tukaram Nagar, Pimpri Colony, Pimpri-Chinchwad, Maharashtra 411018, India", "cc_email": "airbyte-sandbox@pipedrivemail.com", "owner_name": "Team Airbyte"}, "emitted_at": 1683115311467} {"stream": "organizations", "data": {"id": 13, "company_id": 7780468, "owner_id": 11884360, "name": "Test Organization 6", "open_deals_count": 0, "related_open_deals_count": 0, "closed_deals_count": 0, "related_closed_deals_count": 0, "email_messages_count": 0, "people_count": 0, "activities_count": 0, "done_activities_count": 0, "undone_activities_count": 0, "files_count": 0, "notes_count": 0, "followers_count": 1, "won_deals_count": 0, "related_won_deals_count": 0, "lost_deals_count": 0, "related_lost_deals_count": 0, "active_flag": true, "category_id": null, "picture_id": null, "country_code": null, "first_char": "t", "update_time": "2023-02-22 08:23:17", "delete_time": null, "add_time": "2023-02-22 08:18:33", "visible_to": "3", "next_activity_date": null, "next_activity_time": null, "next_activity_id": null, "last_activity_id": null, "last_activity_date": null, "label": 5, "address": "Anand Vihar Railway Station, Block D, Anand Vihar, Delhi, Uttar Pradesh, India", "address_subpremise": "", "address_street_number": "", "address_route": "", "address_sublocality": "Anand Vihar", "address_locality": "Delhi", "address_admin_area_level_1": "Uttar Pradesh", "address_admin_area_level_2": "Delhi Division", "address_country": "India", "address_postal_code": "261205", "address_formatted_address": "J8X8+F33, Block D, Anand Vihar, Delhi, Uttar Pradesh 261205, India", "cc_email": "airbyte-sandbox@pipedrivemail.com", "owner_name": "Team Airbyte"}, "emitted_at": 1683115311468} {"stream": "organizations", "data": {"id": 3, "company_id": 7780468, "owner_id": 11884360, "name": "Test Organization 3", "open_deals_count": 1, "related_open_deals_count": 0, "closed_deals_count": 0, "related_closed_deals_count": 0, "email_messages_count": 0, "people_count": 0, "activities_count": 2, "done_activities_count": 0, "undone_activities_count": 2, "files_count": 0, "notes_count": 0, "followers_count": 1, "won_deals_count": 0, "related_won_deals_count": 0, "lost_deals_count": 0, "related_lost_deals_count": 0, "active_flag": true, "category_id": null, "picture_id": null, "country_code": null, "first_char": "t", "update_time": "2023-02-22 08:56:24", "delete_time": null, "add_time": "2023-02-22 08:07:28", "visible_to": "3", "next_activity_date": "2023-02-22", "next_activity_time": "12:30:00", "next_activity_id": 7, "last_activity_id": null, "last_activity_date": null, "label": 6, "address": "Strasbourg, France", "address_subpremise": "", "address_street_number": "", "address_route": "", "address_sublocality": "", "address_locality": "Strasbourg", "address_admin_area_level_1": "Grand Est", "address_admin_area_level_2": "Bas-Rhin", "address_country": "France", "address_postal_code": "", "address_formatted_address": "Strasbourg, France", "cc_email": "airbyte-sandbox@pipedrivemail.com", "owner_name": "Team Airbyte"}, "emitted_at": 1683115311468} -{"stream": "organization_fields", "data": {"id": 4002, "key": "name", "name": "Name", "order_nr": 1, "field_type": "varchar", "json_column_flag": false, "add_time": "2020-12-10 07:23:48", "update_time": "2020-12-10 07:23:48", "last_updated_by_user_id": null, "edit_flag": false, "details_visible_flag": false, "add_visible_flag": true, "important_flag": false, "bulk_edit_allowed": true, "filtering_allowed": true, "sortable_flag": true, "mandatory_flag": true, "link": "/organization/", "use_field": "id", "active_flag": true, "index_visible_flag": true, "searchable_flag": false}, "emitted_at": 1683115312756} -{"stream": "organization_fields", "data": {"id": 4003, "key": "label", "name": "Label", "order_nr": 2, "field_type": "enum", "json_column_flag": false, "add_time": "2020-12-10 07:23:48", "update_time": "2020-12-10 07:23:48", "last_updated_by_user_id": null, "edit_flag": false, "details_visible_flag": true, "add_visible_flag": true, "important_flag": false, "bulk_edit_allowed": true, "filtering_allowed": true, "sortable_flag": true, "mandatory_flag": false, "options": [{"color": "green", "label": "Customer", "id": 5}, {"color": "red", "label": "Hot lead", "id": 6}, {"color": "yellow", "label": "Warm lead", "id": 7}, {"color": "blue", "label": "Cold lead", "id": 8}], "active_flag": true, "index_visible_flag": true, "searchable_flag": false}, "emitted_at": 1683115312757} -{"stream": "organization_fields", "data": {"id": 4004, "key": "owner_id", "name": "Owner", "order_nr": 3, "field_type": "user", "json_column_flag": false, "add_time": "2020-12-10 07:23:48", "update_time": "2020-12-10 07:23:48", "last_updated_by_user_id": null, "edit_flag": false, "details_visible_flag": true, "add_visible_flag": true, "important_flag": false, "bulk_edit_allowed": true, "filtering_allowed": true, "sortable_flag": true, "mandatory_flag": true, "use_field": "owner_id", "active_flag": true, "index_visible_flag": true, "searchable_flag": false}, "emitted_at": 1683115312758} +{"stream": "organization_fields", "data": {"id": 4002, "key": "name", "name": "Name", "order_nr": 0, "field_type": "varchar", "json_column_flag": false, "add_time": "2020-12-10 07:23:48", "update_time": "2020-12-10 07:23:48", "last_updated_by_user_id": null, "edit_flag": false, "details_visible_flag": false, "add_visible_flag": true, "important_flag": false, "bulk_edit_allowed": true, "filtering_allowed": true, "sortable_flag": true, "searchable_flag": false, "active_flag": true, "use_field": "id", "link": "/organization/", "mandatory_flag": true}, "emitted_at": 1688549134011} +{"stream": "organization_fields", "data": {"id": 4003, "key": "label", "name": "Label", "order_nr": 0, "field_type": "enum", "json_column_flag": false, "add_time": "2020-12-10 07:23:48", "update_time": "2020-12-10 07:23:48", "last_updated_by_user_id": null, "edit_flag": false, "details_visible_flag": true, "add_visible_flag": true, "important_flag": false, "bulk_edit_allowed": true, "filtering_allowed": true, "sortable_flag": true, "searchable_flag": false, "active_flag": true, "options": [{"id": 5, "label": "Customer", "color": "green"}, {"id": 6, "label": "Hot lead", "color": "red"}, {"id": 7, "label": "Warm lead", "color": "yellow"}, {"id": 8, "label": "Cold lead", "color": "blue"}], "mandatory_flag": false}, "emitted_at": 1688549134011} +{"stream": "organization_fields", "data": {"id": 4004, "key": "owner_id", "name": "Owner", "order_nr": 0, "field_type": "user", "json_column_flag": false, "add_time": "2020-12-10 07:23:48", "update_time": "2020-12-10 07:23:48", "last_updated_by_user_id": null, "edit_flag": false, "details_visible_flag": true, "add_visible_flag": true, "important_flag": false, "bulk_edit_allowed": true, "filtering_allowed": true, "sortable_flag": true, "searchable_flag": false, "active_flag": true, "use_field": "owner_id", "display_field": "owner_name", "mandatory_flag": true}, "emitted_at": 1688549134012} {"stream": "permission_sets", "data": {"id": "79b42bf0-fb6d-11eb-a18f-a7e2db4435cf", "name": "Deals admin", "assignment_count": 1, "app": "sales", "type": "admin"}, "emitted_at": 1683115313946} {"stream": "permission_sets", "data": {"id": "79b42bf1-fb6d-11eb-a18f-a7e2db4435cf", "name": "Deals regular user", "assignment_count": 4, "app": "sales", "type": "regular"}, "emitted_at": 1683115313947} {"stream": "permission_sets", "data": {"id": "fa17fff0-db56-11ec-93f1-e9cfc58fcd59", "name": "Global admin", "assignment_count": 1, "app": "global", "type": "admin"}, "emitted_at": 1683115313947} @@ -47,12 +47,12 @@ {"stream": "pipelines", "data": {"id": 2, "name": "New pipeline", "url_title": "New-pipeline", "order_nr": 2, "active": true, "deal_probability": true, "add_time": "2021-07-06 15:24:11", "update_time": "2021-07-06 15:24:11"}, "emitted_at": 1683115317258} {"stream": "pipelines", "data": {"id": 3, "name": "New pipeline 2", "url_title": "New-pipeline-2", "order_nr": 3, "active": true, "deal_probability": true, "add_time": "2023-02-22 10:42:31", "update_time": "2023-02-22 10:42:31"}, "emitted_at": 1683115317259} {"stream": "pipelines", "data": {"id": 4, "name": "New pipeline 3", "url_title": "New-pipeline-3", "order_nr": 4, "active": true, "deal_probability": true, "add_time": "2023-02-22 10:43:12", "update_time": "2023-02-22 10:43:12"}, "emitted_at": 1683115317260} -{"stream": "product_fields", "data": {"id": 17, "key": "name", "name": "Name", "order_nr": 1, "field_type": "varchar", "json_column_flag": false, "add_time": "2020-12-10 07:23:48", "update_time": "2020-12-10 07:23:48", "last_updated_by_user_id": null, "edit_flag": false, "details_visible_flag": false, "add_visible_flag": true, "important_flag": false, "bulk_edit_allowed": true, "filtering_allowed": true, "sortable_flag": true, "mandatory_flag": true, "link": "/api/v1/products/", "use_field": "id", "active_flag": true, "index_visible_flag": true, "searchable_flag": false}, "emitted_at": 1683115318345} -{"stream": "product_fields", "data": {"id": 18, "key": "owner_id", "name": "Owner", "order_nr": 2, "field_type": "user", "json_column_flag": false, "add_time": "2020-12-10 07:23:48", "update_time": "2020-12-10 07:23:48", "last_updated_by_user_id": null, "edit_flag": false, "details_visible_flag": true, "add_visible_flag": false, "important_flag": false, "bulk_edit_allowed": true, "filtering_allowed": true, "sortable_flag": true, "mandatory_flag": true, "use_field": "owner_id", "active_flag": true, "index_visible_flag": true, "searchable_flag": false}, "emitted_at": 1683115318346} -{"stream": "product_fields", "data": {"id": 19, "key": "code", "name": "Product code", "order_nr": 3, "field_type": "varchar", "json_column_flag": false, "add_time": "2020-12-10 07:23:48", "update_time": "2020-12-10 07:23:48", "last_updated_by_user_id": null, "edit_flag": false, "details_visible_flag": true, "add_visible_flag": true, "important_flag": false, "bulk_edit_allowed": true, "filtering_allowed": true, "sortable_flag": true, "mandatory_flag": false, "active_flag": true, "index_visible_flag": true, "searchable_flag": false}, "emitted_at": 1683115318346} -{"stream": "products", "data": {"id": 1, "name": "Test Product", "code": "12345", "description": null, "unit": "Kg", "tax": 5, "category": "12", "active_flag": true, "selectable": true, "first_char": "t", "visible_to": "3", "owner_id": 11884360, "files_count": null, "followers_count": 0, "add_time": "2021-11-09 11:32:16", "update_time": "2021-11-09 11:32:31", "prices": [{"id": 1, "product_id": 1, "price": 10, "currency": "USD", "cost": 0, "overhead_cost": null}], "product_variations": [], "owner_name": "Team Airbyte"}, "emitted_at": 1683115319454} -{"stream": "products", "data": {"id": 2, "name": "Item 1", "code": null, "description": null, "unit": null, "tax": 0, "category": null, "active_flag": true, "selectable": true, "first_char": "i", "visible_to": "3", "owner_id": 11884360, "files_count": null, "followers_count": 0, "add_time": "2023-02-22 08:31:13", "update_time": "2023-02-22 08:31:13", "prices": [{"id": 2, "product_id": 2, "price": 0, "currency": "USD", "cost": 0, "overhead_cost": null}], "product_variations": [], "owner_name": "Team Airbyte"}, "emitted_at": 1683115319455} -{"stream": "products", "data": {"id": 3, "name": "Item 2", "code": null, "description": null, "unit": null, "tax": 0, "category": null, "active_flag": true, "selectable": true, "first_char": "i", "visible_to": "3", "owner_id": 11884360, "files_count": null, "followers_count": 0, "add_time": "2023-02-22 08:31:14", "update_time": "2023-02-22 08:31:14", "prices": [{"id": 3, "product_id": 3, "price": 0, "currency": "USD", "cost": 0, "overhead_cost": null}], "product_variations": [], "owner_name": "Team Airbyte"}, "emitted_at": 1683115319456} +{"stream": "product_fields", "data": {"id": 17, "key": "name", "name": "Name", "order_nr": 0, "field_type": "varchar", "json_column_flag": false, "add_time": "2020-12-10 07:23:48", "update_time": "2020-12-10 07:23:48", "last_updated_by_user_id": null, "edit_flag": false, "details_visible_flag": false, "add_visible_flag": true, "important_flag": false, "bulk_edit_allowed": true, "filtering_allowed": true, "sortable_flag": true, "searchable_flag": false, "active_flag": true, "use_field": "id", "link": "/api/v1/products/", "mandatory_flag": true}, "emitted_at": 1688549129671} +{"stream": "product_fields", "data": {"id": 18, "key": "owner_id", "name": "Owner", "order_nr": 0, "field_type": "user", "json_column_flag": false, "add_time": "2020-12-10 07:23:48", "update_time": "2020-12-10 07:23:48", "last_updated_by_user_id": null, "edit_flag": false, "details_visible_flag": true, "add_visible_flag": false, "important_flag": false, "bulk_edit_allowed": true, "filtering_allowed": true, "sortable_flag": true, "searchable_flag": false, "active_flag": true, "use_field": "owner_id", "display_field": "owner_name", "mandatory_flag": true}, "emitted_at": 1688549129672} +{"stream": "product_fields", "data": {"id": 19, "key": "code", "name": "Product code", "order_nr": 0, "field_type": "varchar", "json_column_flag": false, "add_time": "2020-12-10 07:23:48", "update_time": "2020-12-10 07:23:48", "last_updated_by_user_id": null, "edit_flag": false, "details_visible_flag": true, "add_visible_flag": true, "important_flag": false, "bulk_edit_allowed": true, "filtering_allowed": true, "sortable_flag": true, "searchable_flag": false, "active_flag": true, "mandatory_flag": false}, "emitted_at": 1688549129672} +{"stream": "products", "data": {"id": 1, "name": "Test Product", "code": "12345", "description": null, "unit": "Kg", "tax": 5, "category": "12", "active_flag": true, "selectable": true, "first_char": "t", "visible_to": "3", "owner_id": 11884360, "files_count": null, "add_time": "2021-11-09 11:32:16", "update_time": "2021-11-09 11:32:31", "prices": [{"id": 1, "product_id": 1, "price": 10, "currency": "USD", "cost": 0, "overhead_cost": null}], "product_variations": [], "owner_name": "Team Airbyte"}, "emitted_at": 1688549130307} +{"stream": "products", "data": {"id": 2, "name": "Item 1", "code": null, "description": null, "unit": null, "tax": 0, "category": null, "active_flag": true, "selectable": true, "first_char": "i", "visible_to": "3", "owner_id": 11884360, "files_count": null, "add_time": "2023-02-22 08:31:13", "update_time": "2023-02-22 08:31:13", "prices": [{"id": 2, "product_id": 2, "price": 0, "currency": "USD", "cost": 0, "overhead_cost": null}], "product_variations": [], "owner_name": "Team Airbyte"}, "emitted_at": 1688549130309} +{"stream": "products", "data": {"id": 3, "name": "Item 2", "code": null, "description": null, "unit": null, "tax": 0, "category": null, "active_flag": true, "selectable": true, "first_char": "i", "visible_to": "3", "owner_id": 11884360, "files_count": null, "add_time": "2023-02-22 08:31:14", "update_time": "2023-02-22 08:31:14", "prices": [{"id": 3, "product_id": 3, "price": 0, "currency": "USD", "cost": 0, "overhead_cost": null}], "product_variations": [], "owner_name": "Team Airbyte"}, "emitted_at": 1688549130309} {"stream": "roles", "data": {"id": 1, "parent_role_id": null, "name": "(Unassigned users)", "active_flag": true, "assignment_count": "5", "sub_role_count": "0", "level": 1, "description": "This is the default group for managing your visibility settings. New users are added automatically unless you change their group when you invite them."}, "emitted_at": 1683115320947} {"stream": "stages", "data": {"id": 11, "order_nr": 5, "name": "Negotiations Started", "active_flag": true, "deal_probability": 100, "pipeline_id": 2, "rotten_flag": false, "rotten_days": null, "add_time": "2021-07-06 15:24:11", "update_time": "2023-02-22 10:38:51", "pipeline_name": "New pipeline", "pipeline_deal_probability": true}, "emitted_at": 1683115322062} {"stream": "stages", "data": {"id": 10, "order_nr": 4, "name": "Proposal Made", "active_flag": true, "deal_probability": 100, "pipeline_id": 2, "rotten_flag": false, "rotten_days": null, "add_time": "2021-07-06 15:24:11", "update_time": "2023-02-22 10:38:51", "pipeline_name": "New pipeline", "pipeline_deal_probability": true}, "emitted_at": 1683115322063} From 6bee4f5d2f0b28385bf7d8f51e1e2a0cbec750be Mon Sep 17 00:00:00 2001 From: Arsen Losenko <20901439+arsenlosenko@users.noreply.github.com> Date: Wed, 5 Jul 2023 15:00:03 +0300 Subject: [PATCH 2/2] Add display_name field to organization_fields and product_fields schemas --- airbyte-integrations/connectors/source-pipedrive/Dockerfile | 2 +- airbyte-integrations/connectors/source-pipedrive/metadata.yaml | 2 +- .../source_pipedrive/schemas/organization_fields.json | 3 +++ .../source_pipedrive/schemas/product_fields.json | 3 +++ docs/integrations/sources/pipedrive.md | 1 + 5 files changed, 9 insertions(+), 2 deletions(-) diff --git a/airbyte-integrations/connectors/source-pipedrive/Dockerfile b/airbyte-integrations/connectors/source-pipedrive/Dockerfile index f15258ee4f2e..7de6c42adf4a 100644 --- a/airbyte-integrations/connectors/source-pipedrive/Dockerfile +++ b/airbyte-integrations/connectors/source-pipedrive/Dockerfile @@ -12,5 +12,5 @@ RUN pip install . ENV AIRBYTE_ENTRYPOINT "python /airbyte/integration_code/main.py" ENTRYPOINT ["python", "/airbyte/integration_code/main.py"] -LABEL io.airbyte.version=0.1.18 +LABEL io.airbyte.version=0.1.19 LABEL io.airbyte.name=airbyte/source-pipedrive diff --git a/airbyte-integrations/connectors/source-pipedrive/metadata.yaml b/airbyte-integrations/connectors/source-pipedrive/metadata.yaml index a8a565f83d16..11dd638975c0 100644 --- a/airbyte-integrations/connectors/source-pipedrive/metadata.yaml +++ b/airbyte-integrations/connectors/source-pipedrive/metadata.yaml @@ -5,7 +5,7 @@ data: connectorSubtype: api connectorType: source definitionId: d8286229-c680-4063-8c59-23b9b391c700 - dockerImageTag: 0.1.18 + dockerImageTag: 0.1.19 dockerRepository: airbyte/source-pipedrive githubIssueLabel: source-pipedrive icon: pipedrive.svg diff --git a/airbyte-integrations/connectors/source-pipedrive/source_pipedrive/schemas/organization_fields.json b/airbyte-integrations/connectors/source-pipedrive/source_pipedrive/schemas/organization_fields.json index 7926e50d1019..257c0b7c54c7 100644 --- a/airbyte-integrations/connectors/source-pipedrive/source_pipedrive/schemas/organization_fields.json +++ b/airbyte-integrations/connectors/source-pipedrive/source_pipedrive/schemas/organization_fields.json @@ -74,6 +74,9 @@ }, "mandatory_flag": { "type": ["null", "boolean"] + }, + "display_name": { + "type": ["null", "string"] } } } diff --git a/airbyte-integrations/connectors/source-pipedrive/source_pipedrive/schemas/product_fields.json b/airbyte-integrations/connectors/source-pipedrive/source_pipedrive/schemas/product_fields.json index f80223c46f2f..811da2f9dcc9 100644 --- a/airbyte-integrations/connectors/source-pipedrive/source_pipedrive/schemas/product_fields.json +++ b/airbyte-integrations/connectors/source-pipedrive/source_pipedrive/schemas/product_fields.json @@ -59,6 +59,9 @@ "use_field": { "type": ["null", "string"] }, + "display_field": { + "type": ["null", "string"] + }, "active_flag": { "type": ["null", "boolean"] }, diff --git a/docs/integrations/sources/pipedrive.md b/docs/integrations/sources/pipedrive.md index c021f2e635e0..d6b5cc353363 100644 --- a/docs/integrations/sources/pipedrive.md +++ b/docs/integrations/sources/pipedrive.md @@ -112,6 +112,7 @@ The Pipedrive connector will gracefully handle rate limits. For more information | Version | Date | Pull Request | Subject | | :------ | :--------- | :------------------------------------------------------- | :------------------------------------------------------------- | +| 0.1.19 | 2023-07-05 | [27967](https://github.com/airbytehq/airbyte/pull/27967) | Update `OrganizationFields` and `ProductFields` with `display_field` field | | 0.1.18 | 2023-06-02 | [26892](https://github.com/airbytehq/airbyte/pull/26892) | Update `DialFields` schema with `pipeline_ids` property | | 0.1.17 | 2023-03-21 | [24282](https://github.com/airbytehq/airbyte/pull/24282) | Bugfix handle missed `cursor_field` | | 0.1.16 | 2023-03-08 | [23789](https://github.com/airbytehq/airbyte/pull/23789) | Add 11 new streams |