ingestr 0.14.3__py3-none-any.whl → 0.14.5__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.

Potentially problematic release.


This version of ingestr might be problematic. Click here for more details.

@@ -0,0 +1,252 @@
1
+ """PlusVibeAI source settings and constants"""
2
+
3
+ # Default start date for PlusVibeAI API requests
4
+ DEFAULT_START_DATE = "2020-01-01"
5
+
6
+ # PlusVibeAI API request timeout in seconds
7
+ REQUEST_TIMEOUT = 300
8
+
9
+ # Default page size for paginated requests
10
+ DEFAULT_PAGE_SIZE = 100
11
+
12
+ # Maximum page size (adjust based on API limits)
13
+ MAX_PAGE_SIZE = 1000
14
+
15
+ # Base API path for PlusVibeAI
16
+ API_BASE_PATH = "/api/v1"
17
+
18
+ # Campaign fields to retrieve from PlusVibeAI API
19
+ CAMPAIGN_FIELDS = (
20
+ # Basic Information
21
+ "id",
22
+ "camp_name",
23
+ "parent_camp_id",
24
+ "campaign_type",
25
+ "organization_id",
26
+ "workspace_id",
27
+ "status",
28
+ # Timestamps
29
+ "created_at",
30
+ "modified_at",
31
+ "last_lead_sent",
32
+ "last_paused_at_bounced",
33
+ # Campaign Configuration
34
+ "tags",
35
+ "template_id",
36
+ "email_accounts",
37
+ "daily_limit",
38
+ "interval_limit_in_min",
39
+ "send_priority",
40
+ "send_as_txt",
41
+ # Tracking & Settings
42
+ "is_emailopened_tracking",
43
+ "is_unsubscribed_link",
44
+ "exclude_ooo",
45
+ "is_acc_based_sending",
46
+ "send_risky_email",
47
+ "unsub_blocklist",
48
+ "other_email_acc",
49
+ "is_esp_match",
50
+ "stop_on_lead_replied",
51
+ # Bounce Settings
52
+ "is_pause_on_bouncerate",
53
+ "bounce_rate_limit",
54
+ "is_paused_at_bounced",
55
+ # Schedule
56
+ "schedule",
57
+ "first_wait_time",
58
+ "camp_st_date",
59
+ "camp_end_date",
60
+ # Events & Sequences
61
+ "events",
62
+ "sequences",
63
+ "sequence_steps",
64
+ "camp_emails",
65
+ # Lead Statistics
66
+ "lead_count",
67
+ "completed_lead_count",
68
+ "lead_contacted_count",
69
+ # Email Performance Metrics
70
+ "sent_count",
71
+ "opened_count",
72
+ "unique_opened_count",
73
+ "replied_count",
74
+ "bounced_count",
75
+ "unsubscribed_count",
76
+ # Reply Classification
77
+ "positive_reply_count",
78
+ "negative_reply_count",
79
+ "neutral_reply_count",
80
+ # Daily & Business Metrics
81
+ "email_sent_today",
82
+ "opportunity_val",
83
+ "open_rate",
84
+ "replied_rate",
85
+ # Custom Data
86
+ "custom_fields",
87
+ )
88
+
89
+ # Lead fields to retrieve from PlusVibeAI API
90
+ LEAD_FIELDS = (
91
+ # Basic Information
92
+ "_id",
93
+ "organization_id",
94
+ "campaign_id",
95
+ "workspace_id",
96
+ # Lead Status & Progress
97
+ "is_completed",
98
+ "current_step",
99
+ "status",
100
+ "label",
101
+ # Email Account Info
102
+ "email_account_id",
103
+ "email_acc_name",
104
+ # Campaign Info
105
+ "camp_name",
106
+ # Timestamps
107
+ "created_at",
108
+ "modified_at",
109
+ "last_sent_at",
110
+ # Email Engagement Metrics
111
+ "sent_step",
112
+ "replied_count",
113
+ "opened_count",
114
+ # Email Verification
115
+ "is_mx",
116
+ "mx",
117
+ # Contact Information
118
+ "email",
119
+ "first_name",
120
+ "last_name",
121
+ "phone_number",
122
+ # Address Information
123
+ "address_line",
124
+ "city",
125
+ "state",
126
+ "country",
127
+ "country_code",
128
+ # Professional Information
129
+ "job_title",
130
+ "department",
131
+ "company_name",
132
+ "company_website",
133
+ "industry",
134
+ # Social Media
135
+ "linkedin_person_url",
136
+ "linkedin_company_url",
137
+ # Workflow
138
+ "total_steps",
139
+ # Bounce Information
140
+ "bounce_msg",
141
+ )
142
+
143
+ # Email Account fields to retrieve from PlusVibeAI API
144
+ EMAIL_ACCOUNT_FIELDS = (
145
+ # Basic Information
146
+ "_id",
147
+ "email",
148
+ "status",
149
+ "warmup_status",
150
+ # Timestamps
151
+ "timestamp_created",
152
+ "timestamp_updated",
153
+ # Payload - nested object containing all configuration
154
+ "payload",
155
+ # Payload sub-fields (for reference, stored in payload object):
156
+ # - name (first_name, last_name)
157
+ # - warmup (limit, warmup_custom_words, warmup_signature, advanced, increment, reply_rate)
158
+ # - imap_host, imap_port
159
+ # - smtp_host, smtp_port
160
+ # - daily_limit, sending_gap
161
+ # - reply_to, custom_domain, signature
162
+ # - tags, cmps
163
+ # - analytics (health_scores, reply_rates, daily_counters)
164
+ )
165
+
166
+ # Email fields to retrieve from PlusVibeAI API
167
+ EMAIL_FIELDS = (
168
+ # Basic Information
169
+ "id",
170
+ "message_id",
171
+ "is_unread",
172
+ # Lead Information
173
+ "lead",
174
+ "lead_id",
175
+ "campaign_id",
176
+ # From Address
177
+ "from_address_email",
178
+ "from_address_json",
179
+ # Subject & Content
180
+ "subject",
181
+ "content_preview",
182
+ "body",
183
+ # Headers & Metadata
184
+ "headers",
185
+ "label",
186
+ "thread_id",
187
+ "eaccount",
188
+ # To/CC/BCC Addresses
189
+ "to_address_email_list",
190
+ "to_address_json",
191
+ "cc_address_email_list",
192
+ "cc_address_json",
193
+ "bcc_address_email_list",
194
+ # Timestamps
195
+ "timestamp_created",
196
+ "source_modified_at",
197
+ )
198
+
199
+ # Blocklist fields to retrieve from PlusVibeAI API
200
+ BLOCKLIST_FIELDS = (
201
+ # Basic Information
202
+ "_id",
203
+ "workspace_id",
204
+ "value",
205
+ "created_by_label",
206
+ # Timestamps
207
+ "created_at",
208
+ )
209
+
210
+ # Webhook fields to retrieve from PlusVibeAI API
211
+ WEBHOOK_FIELDS = (
212
+ # Basic Information
213
+ "_id",
214
+ "workspace_id",
215
+ "org_id",
216
+ "url",
217
+ "name",
218
+ "secret",
219
+ # Configuration
220
+ "camp_ids",
221
+ "evt_types",
222
+ "status",
223
+ "integration_type",
224
+ # Settings
225
+ "ignore_ooo",
226
+ "ignore_automatic",
227
+ # Timestamps
228
+ "created_at",
229
+ "modified_at",
230
+ "last_run",
231
+ # Response Data
232
+ "last_resp",
233
+ "last_recv_resp",
234
+ # User Information
235
+ "created_by",
236
+ "modified_by",
237
+ )
238
+
239
+ # Tag fields to retrieve from PlusVibeAI API
240
+ TAG_FIELDS = (
241
+ # Basic Information
242
+ "_id",
243
+ "workspace_id",
244
+ "org_id",
245
+ "name",
246
+ "color",
247
+ "description",
248
+ "status",
249
+ # Timestamps
250
+ "created_at",
251
+ "modified_at",
252
+ )
ingestr/src/sources.py CHANGED
@@ -1829,6 +1829,7 @@ class JiraSource:
1829
1829
  "resolutions",
1830
1830
  "project_versions",
1831
1831
  "project_components",
1832
+ "events",
1832
1833
  ]
1833
1834
 
1834
1835
  def handles_incrementality(self) -> bool:
@@ -2878,6 +2879,10 @@ class FreshdeskSource:
2878
2879
  else:
2879
2880
  end_date = None
2880
2881
 
2882
+ custom_query: Optional[str] = None
2883
+ if ":" in table:
2884
+ table, custom_query = table.split(":", 1)
2885
+
2881
2886
  if table not in [
2882
2887
  "agents",
2883
2888
  "companies",
@@ -2888,6 +2893,9 @@ class FreshdeskSource:
2888
2893
  ]:
2889
2894
  raise UnsupportedResourceError(table, "Freshdesk")
2890
2895
 
2896
+ if custom_query and table != "tickets":
2897
+ raise ValueError(f"Custom query is not supported for {table}")
2898
+
2891
2899
  from ingestr.src.freshdesk import freshdesk_source
2892
2900
 
2893
2901
  return freshdesk_source(
@@ -2895,6 +2903,7 @@ class FreshdeskSource:
2895
2903
  domain=domain,
2896
2904
  start_date=start_date,
2897
2905
  end_date=end_date,
2906
+ query=custom_query,
2898
2907
  ).with_resources(table)
2899
2908
 
2900
2909
 
@@ -3752,6 +3761,52 @@ class AnthropicSource:
3752
3761
  ).with_resources(table)
3753
3762
 
3754
3763
 
3764
+ class PlusVibeAISource:
3765
+ resources = [
3766
+ "campaigns",
3767
+ "leads",
3768
+ "email_accounts",
3769
+ "emails",
3770
+ "blocklist",
3771
+ "webhooks",
3772
+ "tags",
3773
+ ]
3774
+
3775
+ def handles_incrementality(self) -> bool:
3776
+ return True
3777
+
3778
+ def dlt_source(self, uri: str, table: str, **kwargs):
3779
+ # plusvibeai://?api_key=<key>&workspace_id=<id>
3780
+ parsed_uri = urlparse(uri)
3781
+ params = parse_qs(parsed_uri.query)
3782
+
3783
+ api_key = params.get("api_key")
3784
+ workspace_id = params.get("workspace_id")
3785
+
3786
+ if not api_key:
3787
+ raise MissingValueError("api_key", "PlusVibeAI")
3788
+
3789
+ if not workspace_id:
3790
+ raise MissingValueError("workspace_id", "PlusVibeAI")
3791
+
3792
+ if table not in self.resources:
3793
+ raise UnsupportedResourceError(table, "PlusVibeAI")
3794
+
3795
+ import dlt
3796
+
3797
+ from ingestr.src.plusvibeai import plusvibeai_source
3798
+
3799
+ dlt.secrets["sources.plusvibeai.api_key"] = api_key[0]
3800
+ dlt.secrets["sources.plusvibeai.workspace_id"] = workspace_id[0]
3801
+
3802
+ # Handle custom base URL if provided
3803
+ base_url = params.get("base_url", ["https://api.plusvibe.ai"])[0]
3804
+ dlt.secrets["sources.plusvibeai.base_url"] = base_url
3805
+
3806
+ src = plusvibeai_source()
3807
+ return src.with_resources(table)
3808
+
3809
+
3755
3810
  class IntercomSource:
3756
3811
  def handles_incrementality(self) -> bool:
3757
3812
  return True
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: ingestr
3
- Version: 0.14.3
3
+ Version: 0.14.5
4
4
  Summary: ingestr is a command-line application that ingests data from various sources and stores them in any database.
5
5
  Project-URL: Homepage, https://github.com/bruin-data/ingestr
6
6
  Project-URL: Issues, https://github.com/bruin-data/ingestr/issues
@@ -2,17 +2,17 @@ ingestr/conftest.py,sha256=OE2yxeTCosS9CUFVuqNypm-2ftYvVBeeq7egm3878cI,1981
2
2
  ingestr/main.py,sha256=qo0g3wCFl8a_1jUwXagX8L1Q8PKKQlTF7md9pfnzW0Y,27155
3
3
  ingestr/src/.gitignore,sha256=8cX1AZTSI0TcdZFGTmS_oyBjpfCzhOEt0DdAo2dFIY8,203
4
4
  ingestr/src/blob.py,sha256=UUWMjHUuoR9xP1XZQ6UANQmnMVyDx3d0X4-2FQC271I,2138
5
- ingestr/src/buildinfo.py,sha256=lj41sOUyeqEVFBwxqKuI9w8Lpm2R3Hk2Mo4eesobpsw,20
5
+ ingestr/src/buildinfo.py,sha256=8EpHAODYK-dLsm_OMa9EmwMw0Qxn4aTYbjDN-PvxxBQ,20
6
6
  ingestr/src/destinations.py,sha256=QtjE0AGs0WkPHaI2snWPHJ8HHi4lwXUBYLJPklz8Mvk,27772
7
7
  ingestr/src/errors.py,sha256=Ufs4_DfE77_E3vnA1fOQdi6cmuLVNm7_SbFLkL1XPGk,686
8
- ingestr/src/factory.py,sha256=7hOPrQSQowCvrVYBLTXE7BJl2pI7Eo5jdLkdpKSbkaw,7476
8
+ ingestr/src/factory.py,sha256=NNUwks5V66iaWfOblF9MtIpclBasFjYZsMXOKpXUKq4,7538
9
9
  ingestr/src/filters.py,sha256=0n0sNAVG_f-B_1r7lW5iNtw9z_G1bxWzPaiL1i6tnbU,1665
10
10
  ingestr/src/http_client.py,sha256=bxqsk6nJNXCo-79gW04B53DQO-yr25vaSsqP0AKtjx4,732
11
11
  ingestr/src/loader.py,sha256=9NaWAyfkXdqAZSS-N72Iwo36Lbx4PyqIfaaH1dNdkFs,1712
12
12
  ingestr/src/masking.py,sha256=VN0LdfvExhQ1bZMRylGtaBUIoH-vjuIUmRnYKwo3yiY,11358
13
13
  ingestr/src/partition.py,sha256=BrIP6wFJvyR7Nus_3ElnfxknUXeCipK_E_bB8kZowfc,969
14
14
  ingestr/src/resource.py,sha256=ZqmZxFQVGlF8rFPhBiUB08HES0yoTj8sZ--jKfaaVps,1164
15
- ingestr/src/sources.py,sha256=eVnOiV9W2-9wobLC3Pux3gKgtcv90gwTSxQH7a8THoY,134045
15
+ ingestr/src/sources.py,sha256=MuMD7r8_ojCAMVix5p5BD461biZdT5AKE4YZspikrHw,135647
16
16
  ingestr/src/table_definition.py,sha256=REbAbqdlmUMUuRh8nEQRreWjPVOQ5ZcfqGkScKdCrmk,390
17
17
  ingestr/src/time.py,sha256=H_Fk2J4ShXyUM-EMY7MqCLZQhlnZMZvO952bmZPc4yE,254
18
18
  ingestr/src/version.py,sha256=J_2xgZ0mKlvuHcjdKCx2nlioneLH0I47JiU_Slr_Nwc,189
@@ -60,8 +60,8 @@ ingestr/src/fluxx/__init__.py,sha256=ILpfk-5U5NPqVTuMuEOfzmkbojttHDLBL-NYmItRlAM
60
60
  ingestr/src/fluxx/helpers.py,sha256=zJmlQWwiv9snnLqTygiWVZy7-0rGi_K427hRUuZeHEM,6352
61
61
  ingestr/src/frankfurter/__init__.py,sha256=gOdL8ZqgHHYZByjtfE3WX3BTRHdYqyn9FpQwzDHSAx0,5089
62
62
  ingestr/src/frankfurter/helpers.py,sha256=SpRr992OcSf7IDI5y-ToUdO6m6sGpqFz59LTY0ojchI,1502
63
- ingestr/src/freshdesk/__init__.py,sha256=ukyorgCNsW_snzsYBDsr3Q0WB8f-to9Fk0enqHHFQlk,3087
64
- ingestr/src/freshdesk/freshdesk_client.py,sha256=1nFf0K4MQ0KZbWwk4xSbYHaykVqmPLfN39miOFDpWVc,4385
63
+ ingestr/src/freshdesk/__init__.py,sha256=OIP3GikA6BMh9sruU3jih-swdFNSposr48oQhy1WGNk,3145
64
+ ingestr/src/freshdesk/freshdesk_client.py,sha256=BzGCf_z9zUjqdSjU-0IzMt_C7uCIT9pU5qlcO9eu98Q,4829
65
65
  ingestr/src/freshdesk/settings.py,sha256=0Wr_OMnUZcTlry7BmALssLxD2yh686JW4moLNv12Jnw,409
66
66
  ingestr/src/fundraiseup/__init__.py,sha256=q3TQeP1HdbWNeXFMq-0-BdSo82Fq4Io1OEYOY1cAYcU,1743
67
67
  ingestr/src/fundraiseup/client.py,sha256=klU57l8iJ5NAS1nTb_4UyVAerbPWpTa8PMHlpp9Riz0,2453
@@ -92,8 +92,8 @@ ingestr/src/intercom/__init__.py,sha256=rqorWFwcfcTYrCrpSsPPM2sGOc7qq5XbYZRCDVJX
92
92
  ingestr/src/intercom/helpers.py,sha256=IljM0x4K70nuahidZaP7mtIlsHkPIcZq56j9mmuSck4,21074
93
93
  ingestr/src/intercom/settings.py,sha256=u_4P2tZiYsnlGjMTN4Ttr4bLHh1b272Pu5Q9YFq3ZCE,7053
94
94
  ingestr/src/isoc_pulse/__init__.py,sha256=9b4eN4faatpiwTuRNPuYcEt1hEFDEjua9XhfakUigBk,4648
95
- ingestr/src/jira_source/__init__.py,sha256=fy0lYAFVA9Skmdbx_gAI2iF8CXpgBEKSBsuNOQLaNo8,9178
96
- ingestr/src/jira_source/helpers.py,sha256=obkFnVH45rDFTzen0L9y8UVxo3gdm2LFs21m_oB5ow0,15209
95
+ ingestr/src/jira_source/__init__.py,sha256=Hy-JUdo9Nu1Goti6zqWjG1GNnCzfv9cY85MFb-sqo-I,9814
96
+ ingestr/src/jira_source/helpers.py,sha256=vJ7fTGSQnLHKiwLQUPEpGNsHBRUyBZswL8R1A3Tz0GY,14636
97
97
  ingestr/src/jira_source/settings.py,sha256=Ufb-sGS-x_STtWJ-y6k69hP1CVtat_J5MtFPn51TUGE,2861
98
98
  ingestr/src/kafka/__init__.py,sha256=QUHsGmdv5_E-3z0GDHXvbk39puwuGDBsyYSDhvbA89E,3595
99
99
  ingestr/src/kafka/helpers.py,sha256=V9WcVn3PKnEpggArHda4vnAcaV8VDuh__dSmRviJb5Y,7502
@@ -127,6 +127,9 @@ ingestr/src/pipedrive/typing.py,sha256=lEMXu4hhAA3XkhVSlBUa-juqyupisd3c-qSQKxFvz
127
127
  ingestr/src/pipedrive/helpers/__init__.py,sha256=UX1K_qnGXB0ShtnBOfp2XuVbK8RRoCK8TdEmIjRckgg,710
128
128
  ingestr/src/pipedrive/helpers/custom_fields_munger.py,sha256=rZ4AjdITHfJE2NNomCR7vMBS1KnWpEGVF6fADwsIHUE,4488
129
129
  ingestr/src/pipedrive/helpers/pages.py,sha256=Klpjw2OnMuhzit3PpiHKsfzGcJ3rQPSQBl3HhE3-6eA,3358
130
+ ingestr/src/plusvibeai/__init__.py,sha256=Uo-N2-1kbq5RJw8ym5tm8rqVchVbJJ2hOd6bwsg1zdM,10125
131
+ ingestr/src/plusvibeai/helpers.py,sha256=5hxxA2-XUtkZA1xrstZ39ilzUh4EouNDOiiL-NzGu9w,17939
132
+ ingestr/src/plusvibeai/settings.py,sha256=3Hb7jcUNshSlGO4E27yUe_8n3f0VArX9XTmkTkN-Tvo,5366
130
133
  ingestr/src/quickbooks/__init__.py,sha256=cZUuVCOTGPHTscRj6i0DytO63_fWF-4ieMxoU4PcyTg,3727
131
134
  ingestr/src/revenuecat/__init__.py,sha256=5HbyZuEOekkbeeT72sM_bnGygSyYdmd_vczfAUz7xoM,4029
132
135
  ingestr/src/revenuecat/helpers.py,sha256=CYU6l79kplnfL87GfdxyGeEBrBSWEZfGP0GyjPHuVDk,9619
@@ -172,8 +175,8 @@ ingestr/testdata/merge_expected.csv,sha256=DReHqWGnQMsf2PBv_Q2pfjsgvikYFnf1zYcQZ
172
175
  ingestr/testdata/merge_part1.csv,sha256=Pw8Z9IDKcNU0qQHx1z6BUf4rF_-SxKGFOvymCt4OY9I,185
173
176
  ingestr/testdata/merge_part2.csv,sha256=T_GiWxA81SN63_tMOIuemcvboEFeAmbKc7xRXvL9esw,287
174
177
  ingestr/tests/unit/test_smartsheets.py,sha256=zf3DXT29Y4TH2lNPBFphdjlaelUUyPJcsW2UO68RzDs,4862
175
- ingestr-0.14.3.dist-info/METADATA,sha256=rZ95VgGDRpyp8xiaDCqjAlAaXrxy8B1eWFY_lQY15sg,15265
176
- ingestr-0.14.3.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
177
- ingestr-0.14.3.dist-info/entry_points.txt,sha256=oPJy0KBnPWYjDtP1k8qwAihcTLHSZokSQvRAw_wtfJM,46
178
- ingestr-0.14.3.dist-info/licenses/LICENSE.md,sha256=cW8wIhn8HFE-KLStDF9jHQ1O_ARWP3kTpk_-eOccL24,1075
179
- ingestr-0.14.3.dist-info/RECORD,,
178
+ ingestr-0.14.5.dist-info/METADATA,sha256=YSfv9AqmjLd5qjotu6cNcKxFQT8FMQu32EsY60B07Tw,15265
179
+ ingestr-0.14.5.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
180
+ ingestr-0.14.5.dist-info/entry_points.txt,sha256=oPJy0KBnPWYjDtP1k8qwAihcTLHSZokSQvRAw_wtfJM,46
181
+ ingestr-0.14.5.dist-info/licenses/LICENSE.md,sha256=cW8wIhn8HFE-KLStDF9jHQ1O_ARWP3kTpk_-eOccL24,1075
182
+ ingestr-0.14.5.dist-info/RECORD,,