airbyte-agent-klaviyo 0.1.0__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.
Files changed (57) hide show
  1. airbyte_agent_klaviyo/__init__.py +225 -0
  2. airbyte_agent_klaviyo/_vendored/__init__.py +1 -0
  3. airbyte_agent_klaviyo/_vendored/connector_sdk/__init__.py +82 -0
  4. airbyte_agent_klaviyo/_vendored/connector_sdk/auth_strategies.py +1171 -0
  5. airbyte_agent_klaviyo/_vendored/connector_sdk/auth_template.py +135 -0
  6. airbyte_agent_klaviyo/_vendored/connector_sdk/cloud_utils/__init__.py +5 -0
  7. airbyte_agent_klaviyo/_vendored/connector_sdk/cloud_utils/client.py +213 -0
  8. airbyte_agent_klaviyo/_vendored/connector_sdk/connector_model_loader.py +1120 -0
  9. airbyte_agent_klaviyo/_vendored/connector_sdk/constants.py +78 -0
  10. airbyte_agent_klaviyo/_vendored/connector_sdk/exceptions.py +23 -0
  11. airbyte_agent_klaviyo/_vendored/connector_sdk/executor/__init__.py +31 -0
  12. airbyte_agent_klaviyo/_vendored/connector_sdk/executor/hosted_executor.py +201 -0
  13. airbyte_agent_klaviyo/_vendored/connector_sdk/executor/local_executor.py +1854 -0
  14. airbyte_agent_klaviyo/_vendored/connector_sdk/executor/models.py +202 -0
  15. airbyte_agent_klaviyo/_vendored/connector_sdk/extensions.py +693 -0
  16. airbyte_agent_klaviyo/_vendored/connector_sdk/http/__init__.py +37 -0
  17. airbyte_agent_klaviyo/_vendored/connector_sdk/http/adapters/__init__.py +9 -0
  18. airbyte_agent_klaviyo/_vendored/connector_sdk/http/adapters/httpx_adapter.py +251 -0
  19. airbyte_agent_klaviyo/_vendored/connector_sdk/http/config.py +98 -0
  20. airbyte_agent_klaviyo/_vendored/connector_sdk/http/exceptions.py +119 -0
  21. airbyte_agent_klaviyo/_vendored/connector_sdk/http/protocols.py +114 -0
  22. airbyte_agent_klaviyo/_vendored/connector_sdk/http/response.py +104 -0
  23. airbyte_agent_klaviyo/_vendored/connector_sdk/http_client.py +693 -0
  24. airbyte_agent_klaviyo/_vendored/connector_sdk/introspection.py +481 -0
  25. airbyte_agent_klaviyo/_vendored/connector_sdk/logging/__init__.py +11 -0
  26. airbyte_agent_klaviyo/_vendored/connector_sdk/logging/logger.py +273 -0
  27. airbyte_agent_klaviyo/_vendored/connector_sdk/logging/types.py +93 -0
  28. airbyte_agent_klaviyo/_vendored/connector_sdk/observability/__init__.py +11 -0
  29. airbyte_agent_klaviyo/_vendored/connector_sdk/observability/config.py +179 -0
  30. airbyte_agent_klaviyo/_vendored/connector_sdk/observability/models.py +19 -0
  31. airbyte_agent_klaviyo/_vendored/connector_sdk/observability/redactor.py +81 -0
  32. airbyte_agent_klaviyo/_vendored/connector_sdk/observability/session.py +103 -0
  33. airbyte_agent_klaviyo/_vendored/connector_sdk/performance/__init__.py +6 -0
  34. airbyte_agent_klaviyo/_vendored/connector_sdk/performance/instrumentation.py +57 -0
  35. airbyte_agent_klaviyo/_vendored/connector_sdk/performance/metrics.py +93 -0
  36. airbyte_agent_klaviyo/_vendored/connector_sdk/schema/__init__.py +75 -0
  37. airbyte_agent_klaviyo/_vendored/connector_sdk/schema/base.py +201 -0
  38. airbyte_agent_klaviyo/_vendored/connector_sdk/schema/components.py +244 -0
  39. airbyte_agent_klaviyo/_vendored/connector_sdk/schema/connector.py +120 -0
  40. airbyte_agent_klaviyo/_vendored/connector_sdk/schema/extensions.py +301 -0
  41. airbyte_agent_klaviyo/_vendored/connector_sdk/schema/operations.py +156 -0
  42. airbyte_agent_klaviyo/_vendored/connector_sdk/schema/security.py +236 -0
  43. airbyte_agent_klaviyo/_vendored/connector_sdk/secrets.py +182 -0
  44. airbyte_agent_klaviyo/_vendored/connector_sdk/telemetry/__init__.py +10 -0
  45. airbyte_agent_klaviyo/_vendored/connector_sdk/telemetry/config.py +32 -0
  46. airbyte_agent_klaviyo/_vendored/connector_sdk/telemetry/events.py +59 -0
  47. airbyte_agent_klaviyo/_vendored/connector_sdk/telemetry/tracker.py +155 -0
  48. airbyte_agent_klaviyo/_vendored/connector_sdk/types.py +270 -0
  49. airbyte_agent_klaviyo/_vendored/connector_sdk/utils.py +60 -0
  50. airbyte_agent_klaviyo/_vendored/connector_sdk/validation.py +848 -0
  51. airbyte_agent_klaviyo/connector.py +1431 -0
  52. airbyte_agent_klaviyo/connector_model.py +2230 -0
  53. airbyte_agent_klaviyo/models.py +676 -0
  54. airbyte_agent_klaviyo/types.py +1319 -0
  55. airbyte_agent_klaviyo-0.1.0.dist-info/METADATA +151 -0
  56. airbyte_agent_klaviyo-0.1.0.dist-info/RECORD +57 -0
  57. airbyte_agent_klaviyo-0.1.0.dist-info/WHEEL +4 -0
@@ -0,0 +1,2230 @@
1
+ """
2
+ Connector model for klaviyo.
3
+
4
+ This file is auto-generated from the connector definition at build time.
5
+ DO NOT EDIT MANUALLY - changes will be overwritten on next generation.
6
+ """
7
+
8
+ from __future__ import annotations
9
+
10
+ from ._vendored.connector_sdk.types import (
11
+ Action,
12
+ AuthConfig,
13
+ AuthType,
14
+ ConnectorModel,
15
+ EndpointDefinition,
16
+ EntityDefinition,
17
+ )
18
+ from ._vendored.connector_sdk.schema.security import (
19
+ AirbyteAuthConfig,
20
+ AuthConfigFieldSpec,
21
+ )
22
+ from uuid import (
23
+ UUID,
24
+ )
25
+
26
+ KlaviyoConnectorModel: ConnectorModel = ConnectorModel(
27
+ id=UUID('95e8cffd-b8c4-4039-968e-d32fb4a69bde'),
28
+ name='klaviyo',
29
+ base_url='https://a.klaviyo.com/api',
30
+ auth=AuthConfig(
31
+ type=AuthType.API_KEY,
32
+ config={'header': 'Authorization', 'in': 'header'},
33
+ user_config_spec=AirbyteAuthConfig(
34
+ type='object',
35
+ required=['api_key'],
36
+ properties={
37
+ 'api_key': AuthConfigFieldSpec(
38
+ title='API Key',
39
+ description='Your Klaviyo private API key',
40
+ ),
41
+ },
42
+ auth_mapping={'api_key': 'Klaviyo-API-Key ${api_key}'},
43
+ replication_auth_key_mapping={'api_key': 'api_key'},
44
+ ),
45
+ ),
46
+ entities=[
47
+ EntityDefinition(
48
+ name='profiles',
49
+ stream_name='profiles',
50
+ actions=[Action.LIST, Action.GET],
51
+ endpoints={
52
+ Action.LIST: EndpointDefinition(
53
+ method='GET',
54
+ path='/profiles',
55
+ action=Action.LIST,
56
+ description='Returns a paginated list of profiles (contacts) in your Klaviyo account',
57
+ query_params=['page[size]', 'page[cursor]'],
58
+ query_params_schema={
59
+ 'page[size]': {
60
+ 'type': 'integer',
61
+ 'required': False,
62
+ 'default': 20,
63
+ },
64
+ 'page[cursor]': {'type': 'string', 'required': False},
65
+ },
66
+ header_params=['revision'],
67
+ header_params_schema={
68
+ 'revision': {
69
+ 'type': 'string',
70
+ 'required': True,
71
+ 'default': '2024-10-15',
72
+ },
73
+ },
74
+ response_schema={
75
+ 'type': 'object',
76
+ 'description': 'Paginated list of profiles',
77
+ 'properties': {
78
+ 'data': {
79
+ 'type': 'array',
80
+ 'items': {
81
+ 'type': 'object',
82
+ 'description': 'A Klaviyo profile representing a contact',
83
+ 'properties': {
84
+ 'id': {'type': 'string', 'description': 'Unique profile identifier'},
85
+ 'type': {
86
+ 'type': ['string', 'null'],
87
+ 'description': 'Object type (always "profile")',
88
+ },
89
+ 'attributes': {
90
+ 'type': ['object', 'null'],
91
+ 'description': 'Profile attributes',
92
+ 'properties': {
93
+ 'email': {
94
+ 'type': ['string', 'null'],
95
+ 'description': 'Email address',
96
+ },
97
+ 'phone_number': {
98
+ 'type': ['string', 'null'],
99
+ 'description': 'Phone number',
100
+ },
101
+ 'external_id': {
102
+ 'type': ['string', 'null'],
103
+ 'description': 'External identifier',
104
+ },
105
+ 'first_name': {
106
+ 'type': ['string', 'null'],
107
+ 'description': 'First name',
108
+ },
109
+ 'last_name': {
110
+ 'type': ['string', 'null'],
111
+ 'description': 'Last name',
112
+ },
113
+ 'organization': {
114
+ 'type': ['string', 'null'],
115
+ 'description': 'Organization name',
116
+ },
117
+ 'title': {
118
+ 'type': ['string', 'null'],
119
+ 'description': 'Job title',
120
+ },
121
+ 'image': {
122
+ 'type': ['string', 'null'],
123
+ 'description': 'Profile image URL',
124
+ },
125
+ 'created': {
126
+ 'type': ['string', 'null'],
127
+ 'format': 'date-time',
128
+ 'description': 'Creation timestamp',
129
+ },
130
+ 'updated': {
131
+ 'type': ['string', 'null'],
132
+ 'format': 'date-time',
133
+ 'description': 'Last update timestamp',
134
+ },
135
+ 'location': {
136
+ 'type': ['object', 'null'],
137
+ 'description': 'Location information',
138
+ 'properties': {
139
+ 'address1': {
140
+ 'type': ['string', 'null'],
141
+ },
142
+ 'address2': {
143
+ 'type': ['string', 'null'],
144
+ },
145
+ 'city': {
146
+ 'type': ['string', 'null'],
147
+ },
148
+ 'country': {
149
+ 'type': ['string', 'null'],
150
+ },
151
+ 'region': {
152
+ 'type': ['string', 'null'],
153
+ },
154
+ 'zip': {
155
+ 'type': ['string', 'null'],
156
+ },
157
+ 'timezone': {
158
+ 'type': ['string', 'null'],
159
+ },
160
+ 'latitude': {
161
+ 'type': ['number', 'null'],
162
+ },
163
+ 'longitude': {
164
+ 'type': ['number', 'null'],
165
+ },
166
+ },
167
+ },
168
+ 'properties': {
169
+ 'type': ['object', 'null'],
170
+ 'description': 'Custom properties',
171
+ },
172
+ },
173
+ },
174
+ 'links': {
175
+ 'type': ['object', 'null'],
176
+ 'description': 'Related links',
177
+ 'properties': {
178
+ 'self': {
179
+ 'type': ['string', 'null'],
180
+ },
181
+ },
182
+ },
183
+ },
184
+ 'required': ['id'],
185
+ 'x-airbyte-entity-name': 'profiles',
186
+ 'x-airbyte-stream-name': 'profiles',
187
+ },
188
+ },
189
+ 'links': {
190
+ 'type': ['object', 'null'],
191
+ 'properties': {
192
+ 'self': {
193
+ 'type': ['string', 'null'],
194
+ },
195
+ 'next': {
196
+ 'type': ['string', 'null'],
197
+ },
198
+ 'prev': {
199
+ 'type': ['string', 'null'],
200
+ },
201
+ },
202
+ },
203
+ },
204
+ },
205
+ record_extractor='$.data',
206
+ ),
207
+ Action.GET: EndpointDefinition(
208
+ method='GET',
209
+ path='/profiles/{id}',
210
+ action=Action.GET,
211
+ description='Get a single profile by ID',
212
+ path_params=['id'],
213
+ path_params_schema={
214
+ 'id': {'type': 'string', 'required': True},
215
+ },
216
+ header_params=['revision'],
217
+ header_params_schema={
218
+ 'revision': {
219
+ 'type': 'string',
220
+ 'required': True,
221
+ 'default': '2024-10-15',
222
+ },
223
+ },
224
+ response_schema={
225
+ 'type': 'object',
226
+ 'properties': {
227
+ 'data': {
228
+ 'type': 'object',
229
+ 'description': 'A Klaviyo profile representing a contact',
230
+ 'properties': {
231
+ 'id': {'type': 'string', 'description': 'Unique profile identifier'},
232
+ 'type': {
233
+ 'type': ['string', 'null'],
234
+ 'description': 'Object type (always "profile")',
235
+ },
236
+ 'attributes': {
237
+ 'type': ['object', 'null'],
238
+ 'description': 'Profile attributes',
239
+ 'properties': {
240
+ 'email': {
241
+ 'type': ['string', 'null'],
242
+ 'description': 'Email address',
243
+ },
244
+ 'phone_number': {
245
+ 'type': ['string', 'null'],
246
+ 'description': 'Phone number',
247
+ },
248
+ 'external_id': {
249
+ 'type': ['string', 'null'],
250
+ 'description': 'External identifier',
251
+ },
252
+ 'first_name': {
253
+ 'type': ['string', 'null'],
254
+ 'description': 'First name',
255
+ },
256
+ 'last_name': {
257
+ 'type': ['string', 'null'],
258
+ 'description': 'Last name',
259
+ },
260
+ 'organization': {
261
+ 'type': ['string', 'null'],
262
+ 'description': 'Organization name',
263
+ },
264
+ 'title': {
265
+ 'type': ['string', 'null'],
266
+ 'description': 'Job title',
267
+ },
268
+ 'image': {
269
+ 'type': ['string', 'null'],
270
+ 'description': 'Profile image URL',
271
+ },
272
+ 'created': {
273
+ 'type': ['string', 'null'],
274
+ 'format': 'date-time',
275
+ 'description': 'Creation timestamp',
276
+ },
277
+ 'updated': {
278
+ 'type': ['string', 'null'],
279
+ 'format': 'date-time',
280
+ 'description': 'Last update timestamp',
281
+ },
282
+ 'location': {
283
+ 'type': ['object', 'null'],
284
+ 'description': 'Location information',
285
+ 'properties': {
286
+ 'address1': {
287
+ 'type': ['string', 'null'],
288
+ },
289
+ 'address2': {
290
+ 'type': ['string', 'null'],
291
+ },
292
+ 'city': {
293
+ 'type': ['string', 'null'],
294
+ },
295
+ 'country': {
296
+ 'type': ['string', 'null'],
297
+ },
298
+ 'region': {
299
+ 'type': ['string', 'null'],
300
+ },
301
+ 'zip': {
302
+ 'type': ['string', 'null'],
303
+ },
304
+ 'timezone': {
305
+ 'type': ['string', 'null'],
306
+ },
307
+ 'latitude': {
308
+ 'type': ['number', 'null'],
309
+ },
310
+ 'longitude': {
311
+ 'type': ['number', 'null'],
312
+ },
313
+ },
314
+ },
315
+ 'properties': {
316
+ 'type': ['object', 'null'],
317
+ 'description': 'Custom properties',
318
+ },
319
+ },
320
+ },
321
+ 'links': {
322
+ 'type': ['object', 'null'],
323
+ 'description': 'Related links',
324
+ 'properties': {
325
+ 'self': {
326
+ 'type': ['string', 'null'],
327
+ },
328
+ },
329
+ },
330
+ },
331
+ 'required': ['id'],
332
+ 'x-airbyte-entity-name': 'profiles',
333
+ 'x-airbyte-stream-name': 'profiles',
334
+ },
335
+ },
336
+ },
337
+ record_extractor='$.data',
338
+ ),
339
+ },
340
+ entity_schema={
341
+ 'type': 'object',
342
+ 'description': 'A Klaviyo profile representing a contact',
343
+ 'properties': {
344
+ 'id': {'type': 'string', 'description': 'Unique profile identifier'},
345
+ 'type': {
346
+ 'type': ['string', 'null'],
347
+ 'description': 'Object type (always "profile")',
348
+ },
349
+ 'attributes': {
350
+ 'type': ['object', 'null'],
351
+ 'description': 'Profile attributes',
352
+ 'properties': {
353
+ 'email': {
354
+ 'type': ['string', 'null'],
355
+ 'description': 'Email address',
356
+ },
357
+ 'phone_number': {
358
+ 'type': ['string', 'null'],
359
+ 'description': 'Phone number',
360
+ },
361
+ 'external_id': {
362
+ 'type': ['string', 'null'],
363
+ 'description': 'External identifier',
364
+ },
365
+ 'first_name': {
366
+ 'type': ['string', 'null'],
367
+ 'description': 'First name',
368
+ },
369
+ 'last_name': {
370
+ 'type': ['string', 'null'],
371
+ 'description': 'Last name',
372
+ },
373
+ 'organization': {
374
+ 'type': ['string', 'null'],
375
+ 'description': 'Organization name',
376
+ },
377
+ 'title': {
378
+ 'type': ['string', 'null'],
379
+ 'description': 'Job title',
380
+ },
381
+ 'image': {
382
+ 'type': ['string', 'null'],
383
+ 'description': 'Profile image URL',
384
+ },
385
+ 'created': {
386
+ 'type': ['string', 'null'],
387
+ 'format': 'date-time',
388
+ 'description': 'Creation timestamp',
389
+ },
390
+ 'updated': {
391
+ 'type': ['string', 'null'],
392
+ 'format': 'date-time',
393
+ 'description': 'Last update timestamp',
394
+ },
395
+ 'location': {
396
+ 'type': ['object', 'null'],
397
+ 'description': 'Location information',
398
+ 'properties': {
399
+ 'address1': {
400
+ 'type': ['string', 'null'],
401
+ },
402
+ 'address2': {
403
+ 'type': ['string', 'null'],
404
+ },
405
+ 'city': {
406
+ 'type': ['string', 'null'],
407
+ },
408
+ 'country': {
409
+ 'type': ['string', 'null'],
410
+ },
411
+ 'region': {
412
+ 'type': ['string', 'null'],
413
+ },
414
+ 'zip': {
415
+ 'type': ['string', 'null'],
416
+ },
417
+ 'timezone': {
418
+ 'type': ['string', 'null'],
419
+ },
420
+ 'latitude': {
421
+ 'type': ['number', 'null'],
422
+ },
423
+ 'longitude': {
424
+ 'type': ['number', 'null'],
425
+ },
426
+ },
427
+ },
428
+ 'properties': {
429
+ 'type': ['object', 'null'],
430
+ 'description': 'Custom properties',
431
+ },
432
+ },
433
+ },
434
+ 'links': {
435
+ 'type': ['object', 'null'],
436
+ 'description': 'Related links',
437
+ 'properties': {
438
+ 'self': {
439
+ 'type': ['string', 'null'],
440
+ },
441
+ },
442
+ },
443
+ },
444
+ 'required': ['id'],
445
+ 'x-airbyte-entity-name': 'profiles',
446
+ 'x-airbyte-stream-name': 'profiles',
447
+ },
448
+ ),
449
+ EntityDefinition(
450
+ name='lists',
451
+ stream_name='lists',
452
+ actions=[Action.LIST, Action.GET],
453
+ endpoints={
454
+ Action.LIST: EndpointDefinition(
455
+ method='GET',
456
+ path='/lists',
457
+ action=Action.LIST,
458
+ description='Returns a paginated list of all lists in your Klaviyo account',
459
+ query_params=['page[size]', 'page[cursor]'],
460
+ query_params_schema={
461
+ 'page[size]': {
462
+ 'type': 'integer',
463
+ 'required': False,
464
+ 'default': 20,
465
+ },
466
+ 'page[cursor]': {'type': 'string', 'required': False},
467
+ },
468
+ header_params=['revision'],
469
+ header_params_schema={
470
+ 'revision': {
471
+ 'type': 'string',
472
+ 'required': True,
473
+ 'default': '2024-10-15',
474
+ },
475
+ },
476
+ response_schema={
477
+ 'type': 'object',
478
+ 'description': 'Paginated list of lists',
479
+ 'properties': {
480
+ 'data': {
481
+ 'type': 'array',
482
+ 'items': {
483
+ 'type': 'object',
484
+ 'description': 'A Klaviyo list for organizing profiles',
485
+ 'properties': {
486
+ 'id': {'type': 'string', 'description': 'Unique list identifier'},
487
+ 'type': {
488
+ 'type': ['string', 'null'],
489
+ 'description': 'Object type (always "list")',
490
+ },
491
+ 'attributes': {
492
+ 'type': ['object', 'null'],
493
+ 'description': 'List attributes',
494
+ 'properties': {
495
+ 'name': {
496
+ 'type': ['string', 'null'],
497
+ 'description': 'List name',
498
+ },
499
+ 'created': {
500
+ 'type': ['string', 'null'],
501
+ 'format': 'date-time',
502
+ 'description': 'Creation timestamp',
503
+ },
504
+ 'updated': {
505
+ 'type': ['string', 'null'],
506
+ 'format': 'date-time',
507
+ 'description': 'Last update timestamp',
508
+ },
509
+ 'opt_in_process': {
510
+ 'type': ['string', 'null'],
511
+ 'description': 'Opt-in process type',
512
+ },
513
+ },
514
+ },
515
+ 'links': {
516
+ 'type': ['object', 'null'],
517
+ 'description': 'Related links',
518
+ 'properties': {
519
+ 'self': {
520
+ 'type': ['string', 'null'],
521
+ },
522
+ },
523
+ },
524
+ },
525
+ 'required': ['id'],
526
+ 'x-airbyte-entity-name': 'lists',
527
+ 'x-airbyte-stream-name': 'lists',
528
+ },
529
+ },
530
+ 'links': {
531
+ 'type': ['object', 'null'],
532
+ 'properties': {
533
+ 'self': {
534
+ 'type': ['string', 'null'],
535
+ },
536
+ 'next': {
537
+ 'type': ['string', 'null'],
538
+ },
539
+ 'prev': {
540
+ 'type': ['string', 'null'],
541
+ },
542
+ },
543
+ },
544
+ },
545
+ },
546
+ record_extractor='$.data',
547
+ ),
548
+ Action.GET: EndpointDefinition(
549
+ method='GET',
550
+ path='/lists/{id}',
551
+ action=Action.GET,
552
+ description='Get a single list by ID',
553
+ path_params=['id'],
554
+ path_params_schema={
555
+ 'id': {'type': 'string', 'required': True},
556
+ },
557
+ header_params=['revision'],
558
+ header_params_schema={
559
+ 'revision': {
560
+ 'type': 'string',
561
+ 'required': True,
562
+ 'default': '2024-10-15',
563
+ },
564
+ },
565
+ response_schema={
566
+ 'type': 'object',
567
+ 'properties': {
568
+ 'data': {
569
+ 'type': 'object',
570
+ 'description': 'A Klaviyo list for organizing profiles',
571
+ 'properties': {
572
+ 'id': {'type': 'string', 'description': 'Unique list identifier'},
573
+ 'type': {
574
+ 'type': ['string', 'null'],
575
+ 'description': 'Object type (always "list")',
576
+ },
577
+ 'attributes': {
578
+ 'type': ['object', 'null'],
579
+ 'description': 'List attributes',
580
+ 'properties': {
581
+ 'name': {
582
+ 'type': ['string', 'null'],
583
+ 'description': 'List name',
584
+ },
585
+ 'created': {
586
+ 'type': ['string', 'null'],
587
+ 'format': 'date-time',
588
+ 'description': 'Creation timestamp',
589
+ },
590
+ 'updated': {
591
+ 'type': ['string', 'null'],
592
+ 'format': 'date-time',
593
+ 'description': 'Last update timestamp',
594
+ },
595
+ 'opt_in_process': {
596
+ 'type': ['string', 'null'],
597
+ 'description': 'Opt-in process type',
598
+ },
599
+ },
600
+ },
601
+ 'links': {
602
+ 'type': ['object', 'null'],
603
+ 'description': 'Related links',
604
+ 'properties': {
605
+ 'self': {
606
+ 'type': ['string', 'null'],
607
+ },
608
+ },
609
+ },
610
+ },
611
+ 'required': ['id'],
612
+ 'x-airbyte-entity-name': 'lists',
613
+ 'x-airbyte-stream-name': 'lists',
614
+ },
615
+ },
616
+ },
617
+ record_extractor='$.data',
618
+ ),
619
+ },
620
+ entity_schema={
621
+ 'type': 'object',
622
+ 'description': 'A Klaviyo list for organizing profiles',
623
+ 'properties': {
624
+ 'id': {'type': 'string', 'description': 'Unique list identifier'},
625
+ 'type': {
626
+ 'type': ['string', 'null'],
627
+ 'description': 'Object type (always "list")',
628
+ },
629
+ 'attributes': {
630
+ 'type': ['object', 'null'],
631
+ 'description': 'List attributes',
632
+ 'properties': {
633
+ 'name': {
634
+ 'type': ['string', 'null'],
635
+ 'description': 'List name',
636
+ },
637
+ 'created': {
638
+ 'type': ['string', 'null'],
639
+ 'format': 'date-time',
640
+ 'description': 'Creation timestamp',
641
+ },
642
+ 'updated': {
643
+ 'type': ['string', 'null'],
644
+ 'format': 'date-time',
645
+ 'description': 'Last update timestamp',
646
+ },
647
+ 'opt_in_process': {
648
+ 'type': ['string', 'null'],
649
+ 'description': 'Opt-in process type',
650
+ },
651
+ },
652
+ },
653
+ 'links': {
654
+ 'type': ['object', 'null'],
655
+ 'description': 'Related links',
656
+ 'properties': {
657
+ 'self': {
658
+ 'type': ['string', 'null'],
659
+ },
660
+ },
661
+ },
662
+ },
663
+ 'required': ['id'],
664
+ 'x-airbyte-entity-name': 'lists',
665
+ 'x-airbyte-stream-name': 'lists',
666
+ },
667
+ ),
668
+ EntityDefinition(
669
+ name='campaigns',
670
+ stream_name='campaigns',
671
+ actions=[Action.LIST, Action.GET],
672
+ endpoints={
673
+ Action.LIST: EndpointDefinition(
674
+ method='GET',
675
+ path='/campaigns',
676
+ action=Action.LIST,
677
+ description='Returns a paginated list of campaigns. A channel filter is required.',
678
+ query_params=['filter', 'page[size]', 'page[cursor]'],
679
+ query_params_schema={
680
+ 'filter': {
681
+ 'type': 'string',
682
+ 'required': True,
683
+ 'default': "equals(messages.channel,'email')",
684
+ },
685
+ 'page[size]': {
686
+ 'type': 'integer',
687
+ 'required': False,
688
+ 'default': 20,
689
+ },
690
+ 'page[cursor]': {'type': 'string', 'required': False},
691
+ },
692
+ header_params=['revision'],
693
+ header_params_schema={
694
+ 'revision': {
695
+ 'type': 'string',
696
+ 'required': True,
697
+ 'default': '2024-10-15',
698
+ },
699
+ },
700
+ response_schema={
701
+ 'type': 'object',
702
+ 'description': 'Paginated list of campaigns',
703
+ 'properties': {
704
+ 'data': {
705
+ 'type': 'array',
706
+ 'items': {
707
+ 'type': 'object',
708
+ 'description': 'A Klaviyo campaign',
709
+ 'properties': {
710
+ 'id': {'type': 'string', 'description': 'Unique campaign identifier'},
711
+ 'type': {
712
+ 'type': ['string', 'null'],
713
+ 'description': 'Object type (always "campaign")',
714
+ },
715
+ 'attributes': {
716
+ 'type': ['object', 'null'],
717
+ 'description': 'Campaign attributes',
718
+ 'properties': {
719
+ 'name': {
720
+ 'type': ['string', 'null'],
721
+ 'description': 'Campaign name',
722
+ },
723
+ 'status': {
724
+ 'type': ['string', 'null'],
725
+ 'description': 'Campaign status',
726
+ },
727
+ 'archived': {
728
+ 'type': ['boolean', 'null'],
729
+ 'description': 'Whether campaign is archived',
730
+ },
731
+ 'audiences': {
732
+ 'type': ['object', 'null'],
733
+ 'description': 'Target audiences',
734
+ },
735
+ 'send_options': {
736
+ 'type': ['object', 'null'],
737
+ 'description': 'Send options',
738
+ },
739
+ 'tracking_options': {
740
+ 'type': ['object', 'null'],
741
+ 'description': 'Tracking options',
742
+ },
743
+ 'send_strategy': {
744
+ 'type': ['object', 'null'],
745
+ 'description': 'Send strategy',
746
+ },
747
+ 'created_at': {
748
+ 'type': ['string', 'null'],
749
+ 'format': 'date-time',
750
+ 'description': 'Creation timestamp',
751
+ },
752
+ 'scheduled_at': {
753
+ 'type': ['string', 'null'],
754
+ 'format': 'date-time',
755
+ 'description': 'Scheduled send time',
756
+ },
757
+ 'updated_at': {
758
+ 'type': ['string', 'null'],
759
+ 'format': 'date-time',
760
+ 'description': 'Last update timestamp',
761
+ },
762
+ 'send_time': {
763
+ 'type': ['string', 'null'],
764
+ 'format': 'date-time',
765
+ 'description': 'Actual send time',
766
+ },
767
+ },
768
+ },
769
+ 'links': {
770
+ 'type': ['object', 'null'],
771
+ 'description': 'Related links',
772
+ 'properties': {
773
+ 'self': {
774
+ 'type': ['string', 'null'],
775
+ },
776
+ },
777
+ },
778
+ },
779
+ 'required': ['id'],
780
+ 'x-airbyte-entity-name': 'campaigns',
781
+ 'x-airbyte-stream-name': 'campaigns',
782
+ },
783
+ },
784
+ 'links': {
785
+ 'type': ['object', 'null'],
786
+ 'properties': {
787
+ 'self': {
788
+ 'type': ['string', 'null'],
789
+ },
790
+ 'next': {
791
+ 'type': ['string', 'null'],
792
+ },
793
+ 'prev': {
794
+ 'type': ['string', 'null'],
795
+ },
796
+ },
797
+ },
798
+ },
799
+ },
800
+ record_extractor='$.data',
801
+ ),
802
+ Action.GET: EndpointDefinition(
803
+ method='GET',
804
+ path='/campaigns/{id}',
805
+ action=Action.GET,
806
+ description='Get a single campaign by ID',
807
+ path_params=['id'],
808
+ path_params_schema={
809
+ 'id': {'type': 'string', 'required': True},
810
+ },
811
+ header_params=['revision'],
812
+ header_params_schema={
813
+ 'revision': {
814
+ 'type': 'string',
815
+ 'required': True,
816
+ 'default': '2024-10-15',
817
+ },
818
+ },
819
+ response_schema={
820
+ 'type': 'object',
821
+ 'properties': {
822
+ 'data': {
823
+ 'type': 'object',
824
+ 'description': 'A Klaviyo campaign',
825
+ 'properties': {
826
+ 'id': {'type': 'string', 'description': 'Unique campaign identifier'},
827
+ 'type': {
828
+ 'type': ['string', 'null'],
829
+ 'description': 'Object type (always "campaign")',
830
+ },
831
+ 'attributes': {
832
+ 'type': ['object', 'null'],
833
+ 'description': 'Campaign attributes',
834
+ 'properties': {
835
+ 'name': {
836
+ 'type': ['string', 'null'],
837
+ 'description': 'Campaign name',
838
+ },
839
+ 'status': {
840
+ 'type': ['string', 'null'],
841
+ 'description': 'Campaign status',
842
+ },
843
+ 'archived': {
844
+ 'type': ['boolean', 'null'],
845
+ 'description': 'Whether campaign is archived',
846
+ },
847
+ 'audiences': {
848
+ 'type': ['object', 'null'],
849
+ 'description': 'Target audiences',
850
+ },
851
+ 'send_options': {
852
+ 'type': ['object', 'null'],
853
+ 'description': 'Send options',
854
+ },
855
+ 'tracking_options': {
856
+ 'type': ['object', 'null'],
857
+ 'description': 'Tracking options',
858
+ },
859
+ 'send_strategy': {
860
+ 'type': ['object', 'null'],
861
+ 'description': 'Send strategy',
862
+ },
863
+ 'created_at': {
864
+ 'type': ['string', 'null'],
865
+ 'format': 'date-time',
866
+ 'description': 'Creation timestamp',
867
+ },
868
+ 'scheduled_at': {
869
+ 'type': ['string', 'null'],
870
+ 'format': 'date-time',
871
+ 'description': 'Scheduled send time',
872
+ },
873
+ 'updated_at': {
874
+ 'type': ['string', 'null'],
875
+ 'format': 'date-time',
876
+ 'description': 'Last update timestamp',
877
+ },
878
+ 'send_time': {
879
+ 'type': ['string', 'null'],
880
+ 'format': 'date-time',
881
+ 'description': 'Actual send time',
882
+ },
883
+ },
884
+ },
885
+ 'links': {
886
+ 'type': ['object', 'null'],
887
+ 'description': 'Related links',
888
+ 'properties': {
889
+ 'self': {
890
+ 'type': ['string', 'null'],
891
+ },
892
+ },
893
+ },
894
+ },
895
+ 'required': ['id'],
896
+ 'x-airbyte-entity-name': 'campaigns',
897
+ 'x-airbyte-stream-name': 'campaigns',
898
+ },
899
+ },
900
+ },
901
+ record_extractor='$.data',
902
+ ),
903
+ },
904
+ entity_schema={
905
+ 'type': 'object',
906
+ 'description': 'A Klaviyo campaign',
907
+ 'properties': {
908
+ 'id': {'type': 'string', 'description': 'Unique campaign identifier'},
909
+ 'type': {
910
+ 'type': ['string', 'null'],
911
+ 'description': 'Object type (always "campaign")',
912
+ },
913
+ 'attributes': {
914
+ 'type': ['object', 'null'],
915
+ 'description': 'Campaign attributes',
916
+ 'properties': {
917
+ 'name': {
918
+ 'type': ['string', 'null'],
919
+ 'description': 'Campaign name',
920
+ },
921
+ 'status': {
922
+ 'type': ['string', 'null'],
923
+ 'description': 'Campaign status',
924
+ },
925
+ 'archived': {
926
+ 'type': ['boolean', 'null'],
927
+ 'description': 'Whether campaign is archived',
928
+ },
929
+ 'audiences': {
930
+ 'type': ['object', 'null'],
931
+ 'description': 'Target audiences',
932
+ },
933
+ 'send_options': {
934
+ 'type': ['object', 'null'],
935
+ 'description': 'Send options',
936
+ },
937
+ 'tracking_options': {
938
+ 'type': ['object', 'null'],
939
+ 'description': 'Tracking options',
940
+ },
941
+ 'send_strategy': {
942
+ 'type': ['object', 'null'],
943
+ 'description': 'Send strategy',
944
+ },
945
+ 'created_at': {
946
+ 'type': ['string', 'null'],
947
+ 'format': 'date-time',
948
+ 'description': 'Creation timestamp',
949
+ },
950
+ 'scheduled_at': {
951
+ 'type': ['string', 'null'],
952
+ 'format': 'date-time',
953
+ 'description': 'Scheduled send time',
954
+ },
955
+ 'updated_at': {
956
+ 'type': ['string', 'null'],
957
+ 'format': 'date-time',
958
+ 'description': 'Last update timestamp',
959
+ },
960
+ 'send_time': {
961
+ 'type': ['string', 'null'],
962
+ 'format': 'date-time',
963
+ 'description': 'Actual send time',
964
+ },
965
+ },
966
+ },
967
+ 'links': {
968
+ 'type': ['object', 'null'],
969
+ 'description': 'Related links',
970
+ 'properties': {
971
+ 'self': {
972
+ 'type': ['string', 'null'],
973
+ },
974
+ },
975
+ },
976
+ },
977
+ 'required': ['id'],
978
+ 'x-airbyte-entity-name': 'campaigns',
979
+ 'x-airbyte-stream-name': 'campaigns',
980
+ },
981
+ ),
982
+ EntityDefinition(
983
+ name='events',
984
+ stream_name='events',
985
+ actions=[Action.LIST],
986
+ endpoints={
987
+ Action.LIST: EndpointDefinition(
988
+ method='GET',
989
+ path='/events',
990
+ action=Action.LIST,
991
+ description='Returns a paginated list of events (actions taken by profiles)',
992
+ query_params=['page[size]', 'page[cursor]', 'sort'],
993
+ query_params_schema={
994
+ 'page[size]': {
995
+ 'type': 'integer',
996
+ 'required': False,
997
+ 'default': 20,
998
+ },
999
+ 'page[cursor]': {'type': 'string', 'required': False},
1000
+ 'sort': {
1001
+ 'type': 'string',
1002
+ 'required': False,
1003
+ 'default': '-datetime',
1004
+ },
1005
+ },
1006
+ header_params=['revision'],
1007
+ header_params_schema={
1008
+ 'revision': {
1009
+ 'type': 'string',
1010
+ 'required': True,
1011
+ 'default': '2024-10-15',
1012
+ },
1013
+ },
1014
+ response_schema={
1015
+ 'type': 'object',
1016
+ 'description': 'Paginated list of events',
1017
+ 'properties': {
1018
+ 'data': {
1019
+ 'type': 'array',
1020
+ 'items': {
1021
+ 'type': 'object',
1022
+ 'description': 'A Klaviyo event representing an action taken by a profile',
1023
+ 'properties': {
1024
+ 'id': {'type': 'string', 'description': 'Unique event identifier'},
1025
+ 'type': {
1026
+ 'type': ['string', 'null'],
1027
+ 'description': 'Object type (always "event")',
1028
+ },
1029
+ 'attributes': {
1030
+ 'type': ['object', 'null'],
1031
+ 'description': 'Event attributes',
1032
+ 'properties': {
1033
+ 'timestamp': {
1034
+ 'oneOf': [
1035
+ {'type': 'string', 'format': 'date-time'},
1036
+ {'type': 'integer'},
1037
+ {'type': 'null'},
1038
+ ],
1039
+ 'description': 'Event timestamp (can be ISO string or Unix timestamp)',
1040
+ },
1041
+ 'datetime': {
1042
+ 'type': ['string', 'null'],
1043
+ 'format': 'date-time',
1044
+ 'description': 'Event datetime',
1045
+ },
1046
+ 'uuid': {
1047
+ 'type': ['string', 'null'],
1048
+ 'description': 'Event UUID',
1049
+ },
1050
+ 'event_properties': {
1051
+ 'type': ['object', 'null'],
1052
+ 'description': 'Custom event properties',
1053
+ },
1054
+ },
1055
+ },
1056
+ 'relationships': {
1057
+ 'type': ['object', 'null'],
1058
+ 'description': 'Related resources',
1059
+ 'properties': {
1060
+ 'profile': {
1061
+ 'type': ['object', 'null'],
1062
+ 'properties': {
1063
+ 'data': {
1064
+ 'type': ['object', 'null'],
1065
+ 'properties': {
1066
+ 'type': {
1067
+ 'type': ['string', 'null'],
1068
+ },
1069
+ 'id': {
1070
+ 'type': ['string', 'null'],
1071
+ },
1072
+ },
1073
+ },
1074
+ },
1075
+ },
1076
+ 'metric': {
1077
+ 'type': ['object', 'null'],
1078
+ 'properties': {
1079
+ 'data': {
1080
+ 'type': ['object', 'null'],
1081
+ 'properties': {
1082
+ 'type': {
1083
+ 'type': ['string', 'null'],
1084
+ },
1085
+ 'id': {
1086
+ 'type': ['string', 'null'],
1087
+ },
1088
+ },
1089
+ },
1090
+ },
1091
+ },
1092
+ },
1093
+ },
1094
+ 'links': {
1095
+ 'type': ['object', 'null'],
1096
+ 'description': 'Related links',
1097
+ 'properties': {
1098
+ 'self': {
1099
+ 'type': ['string', 'null'],
1100
+ },
1101
+ },
1102
+ },
1103
+ },
1104
+ 'required': ['id'],
1105
+ 'x-airbyte-entity-name': 'events',
1106
+ 'x-airbyte-stream-name': 'events',
1107
+ },
1108
+ },
1109
+ 'links': {
1110
+ 'type': ['object', 'null'],
1111
+ 'properties': {
1112
+ 'self': {
1113
+ 'type': ['string', 'null'],
1114
+ },
1115
+ 'next': {
1116
+ 'type': ['string', 'null'],
1117
+ },
1118
+ 'prev': {
1119
+ 'type': ['string', 'null'],
1120
+ },
1121
+ },
1122
+ },
1123
+ },
1124
+ },
1125
+ record_extractor='$.data',
1126
+ ),
1127
+ },
1128
+ entity_schema={
1129
+ 'type': 'object',
1130
+ 'description': 'A Klaviyo event representing an action taken by a profile',
1131
+ 'properties': {
1132
+ 'id': {'type': 'string', 'description': 'Unique event identifier'},
1133
+ 'type': {
1134
+ 'type': ['string', 'null'],
1135
+ 'description': 'Object type (always "event")',
1136
+ },
1137
+ 'attributes': {
1138
+ 'type': ['object', 'null'],
1139
+ 'description': 'Event attributes',
1140
+ 'properties': {
1141
+ 'timestamp': {
1142
+ 'oneOf': [
1143
+ {'type': 'string', 'format': 'date-time'},
1144
+ {'type': 'integer'},
1145
+ {'type': 'null'},
1146
+ ],
1147
+ 'description': 'Event timestamp (can be ISO string or Unix timestamp)',
1148
+ },
1149
+ 'datetime': {
1150
+ 'type': ['string', 'null'],
1151
+ 'format': 'date-time',
1152
+ 'description': 'Event datetime',
1153
+ },
1154
+ 'uuid': {
1155
+ 'type': ['string', 'null'],
1156
+ 'description': 'Event UUID',
1157
+ },
1158
+ 'event_properties': {
1159
+ 'type': ['object', 'null'],
1160
+ 'description': 'Custom event properties',
1161
+ },
1162
+ },
1163
+ },
1164
+ 'relationships': {
1165
+ 'type': ['object', 'null'],
1166
+ 'description': 'Related resources',
1167
+ 'properties': {
1168
+ 'profile': {
1169
+ 'type': ['object', 'null'],
1170
+ 'properties': {
1171
+ 'data': {
1172
+ 'type': ['object', 'null'],
1173
+ 'properties': {
1174
+ 'type': {
1175
+ 'type': ['string', 'null'],
1176
+ },
1177
+ 'id': {
1178
+ 'type': ['string', 'null'],
1179
+ },
1180
+ },
1181
+ },
1182
+ },
1183
+ },
1184
+ 'metric': {
1185
+ 'type': ['object', 'null'],
1186
+ 'properties': {
1187
+ 'data': {
1188
+ 'type': ['object', 'null'],
1189
+ 'properties': {
1190
+ 'type': {
1191
+ 'type': ['string', 'null'],
1192
+ },
1193
+ 'id': {
1194
+ 'type': ['string', 'null'],
1195
+ },
1196
+ },
1197
+ },
1198
+ },
1199
+ },
1200
+ },
1201
+ },
1202
+ 'links': {
1203
+ 'type': ['object', 'null'],
1204
+ 'description': 'Related links',
1205
+ 'properties': {
1206
+ 'self': {
1207
+ 'type': ['string', 'null'],
1208
+ },
1209
+ },
1210
+ },
1211
+ },
1212
+ 'required': ['id'],
1213
+ 'x-airbyte-entity-name': 'events',
1214
+ 'x-airbyte-stream-name': 'events',
1215
+ },
1216
+ ),
1217
+ EntityDefinition(
1218
+ name='metrics',
1219
+ stream_name='metrics',
1220
+ actions=[Action.LIST, Action.GET],
1221
+ endpoints={
1222
+ Action.LIST: EndpointDefinition(
1223
+ method='GET',
1224
+ path='/metrics',
1225
+ action=Action.LIST,
1226
+ description='Returns a paginated list of metrics (event types)',
1227
+ query_params=['page[size]', 'page[cursor]'],
1228
+ query_params_schema={
1229
+ 'page[size]': {
1230
+ 'type': 'integer',
1231
+ 'required': False,
1232
+ 'default': 20,
1233
+ },
1234
+ 'page[cursor]': {'type': 'string', 'required': False},
1235
+ },
1236
+ header_params=['revision'],
1237
+ header_params_schema={
1238
+ 'revision': {
1239
+ 'type': 'string',
1240
+ 'required': True,
1241
+ 'default': '2024-10-15',
1242
+ },
1243
+ },
1244
+ response_schema={
1245
+ 'type': 'object',
1246
+ 'description': 'Paginated list of metrics',
1247
+ 'properties': {
1248
+ 'data': {
1249
+ 'type': 'array',
1250
+ 'items': {
1251
+ 'type': 'object',
1252
+ 'description': 'A Klaviyo metric (event type)',
1253
+ 'properties': {
1254
+ 'id': {'type': 'string', 'description': 'Unique metric identifier'},
1255
+ 'type': {
1256
+ 'type': ['string', 'null'],
1257
+ 'description': 'Object type (always "metric")',
1258
+ },
1259
+ 'attributes': {
1260
+ 'type': ['object', 'null'],
1261
+ 'description': 'Metric attributes',
1262
+ 'properties': {
1263
+ 'name': {
1264
+ 'type': ['string', 'null'],
1265
+ 'description': 'Metric name',
1266
+ },
1267
+ 'created': {
1268
+ 'type': ['string', 'null'],
1269
+ 'format': 'date-time',
1270
+ 'description': 'Creation timestamp',
1271
+ },
1272
+ 'updated': {
1273
+ 'type': ['string', 'null'],
1274
+ 'format': 'date-time',
1275
+ 'description': 'Last update timestamp',
1276
+ },
1277
+ 'integration': {
1278
+ 'type': ['object', 'null'],
1279
+ 'description': 'Integration information',
1280
+ 'properties': {
1281
+ 'id': {
1282
+ 'type': ['string', 'null'],
1283
+ },
1284
+ 'name': {
1285
+ 'type': ['string', 'null'],
1286
+ },
1287
+ 'category': {
1288
+ 'type': ['string', 'null'],
1289
+ },
1290
+ },
1291
+ },
1292
+ },
1293
+ },
1294
+ 'links': {
1295
+ 'type': ['object', 'null'],
1296
+ 'description': 'Related links',
1297
+ 'properties': {
1298
+ 'self': {
1299
+ 'type': ['string', 'null'],
1300
+ },
1301
+ },
1302
+ },
1303
+ },
1304
+ 'required': ['id'],
1305
+ 'x-airbyte-entity-name': 'metrics',
1306
+ 'x-airbyte-stream-name': 'metrics',
1307
+ },
1308
+ },
1309
+ 'links': {
1310
+ 'type': ['object', 'null'],
1311
+ 'properties': {
1312
+ 'self': {
1313
+ 'type': ['string', 'null'],
1314
+ },
1315
+ 'next': {
1316
+ 'type': ['string', 'null'],
1317
+ },
1318
+ 'prev': {
1319
+ 'type': ['string', 'null'],
1320
+ },
1321
+ },
1322
+ },
1323
+ },
1324
+ },
1325
+ record_extractor='$.data',
1326
+ ),
1327
+ Action.GET: EndpointDefinition(
1328
+ method='GET',
1329
+ path='/metrics/{id}',
1330
+ action=Action.GET,
1331
+ description='Get a single metric by ID',
1332
+ path_params=['id'],
1333
+ path_params_schema={
1334
+ 'id': {'type': 'string', 'required': True},
1335
+ },
1336
+ header_params=['revision'],
1337
+ header_params_schema={
1338
+ 'revision': {
1339
+ 'type': 'string',
1340
+ 'required': True,
1341
+ 'default': '2024-10-15',
1342
+ },
1343
+ },
1344
+ response_schema={
1345
+ 'type': 'object',
1346
+ 'properties': {
1347
+ 'data': {
1348
+ 'type': 'object',
1349
+ 'description': 'A Klaviyo metric (event type)',
1350
+ 'properties': {
1351
+ 'id': {'type': 'string', 'description': 'Unique metric identifier'},
1352
+ 'type': {
1353
+ 'type': ['string', 'null'],
1354
+ 'description': 'Object type (always "metric")',
1355
+ },
1356
+ 'attributes': {
1357
+ 'type': ['object', 'null'],
1358
+ 'description': 'Metric attributes',
1359
+ 'properties': {
1360
+ 'name': {
1361
+ 'type': ['string', 'null'],
1362
+ 'description': 'Metric name',
1363
+ },
1364
+ 'created': {
1365
+ 'type': ['string', 'null'],
1366
+ 'format': 'date-time',
1367
+ 'description': 'Creation timestamp',
1368
+ },
1369
+ 'updated': {
1370
+ 'type': ['string', 'null'],
1371
+ 'format': 'date-time',
1372
+ 'description': 'Last update timestamp',
1373
+ },
1374
+ 'integration': {
1375
+ 'type': ['object', 'null'],
1376
+ 'description': 'Integration information',
1377
+ 'properties': {
1378
+ 'id': {
1379
+ 'type': ['string', 'null'],
1380
+ },
1381
+ 'name': {
1382
+ 'type': ['string', 'null'],
1383
+ },
1384
+ 'category': {
1385
+ 'type': ['string', 'null'],
1386
+ },
1387
+ },
1388
+ },
1389
+ },
1390
+ },
1391
+ 'links': {
1392
+ 'type': ['object', 'null'],
1393
+ 'description': 'Related links',
1394
+ 'properties': {
1395
+ 'self': {
1396
+ 'type': ['string', 'null'],
1397
+ },
1398
+ },
1399
+ },
1400
+ },
1401
+ 'required': ['id'],
1402
+ 'x-airbyte-entity-name': 'metrics',
1403
+ 'x-airbyte-stream-name': 'metrics',
1404
+ },
1405
+ },
1406
+ },
1407
+ record_extractor='$.data',
1408
+ ),
1409
+ },
1410
+ entity_schema={
1411
+ 'type': 'object',
1412
+ 'description': 'A Klaviyo metric (event type)',
1413
+ 'properties': {
1414
+ 'id': {'type': 'string', 'description': 'Unique metric identifier'},
1415
+ 'type': {
1416
+ 'type': ['string', 'null'],
1417
+ 'description': 'Object type (always "metric")',
1418
+ },
1419
+ 'attributes': {
1420
+ 'type': ['object', 'null'],
1421
+ 'description': 'Metric attributes',
1422
+ 'properties': {
1423
+ 'name': {
1424
+ 'type': ['string', 'null'],
1425
+ 'description': 'Metric name',
1426
+ },
1427
+ 'created': {
1428
+ 'type': ['string', 'null'],
1429
+ 'format': 'date-time',
1430
+ 'description': 'Creation timestamp',
1431
+ },
1432
+ 'updated': {
1433
+ 'type': ['string', 'null'],
1434
+ 'format': 'date-time',
1435
+ 'description': 'Last update timestamp',
1436
+ },
1437
+ 'integration': {
1438
+ 'type': ['object', 'null'],
1439
+ 'description': 'Integration information',
1440
+ 'properties': {
1441
+ 'id': {
1442
+ 'type': ['string', 'null'],
1443
+ },
1444
+ 'name': {
1445
+ 'type': ['string', 'null'],
1446
+ },
1447
+ 'category': {
1448
+ 'type': ['string', 'null'],
1449
+ },
1450
+ },
1451
+ },
1452
+ },
1453
+ },
1454
+ 'links': {
1455
+ 'type': ['object', 'null'],
1456
+ 'description': 'Related links',
1457
+ 'properties': {
1458
+ 'self': {
1459
+ 'type': ['string', 'null'],
1460
+ },
1461
+ },
1462
+ },
1463
+ },
1464
+ 'required': ['id'],
1465
+ 'x-airbyte-entity-name': 'metrics',
1466
+ 'x-airbyte-stream-name': 'metrics',
1467
+ },
1468
+ ),
1469
+ EntityDefinition(
1470
+ name='flows',
1471
+ stream_name='flows',
1472
+ actions=[Action.LIST, Action.GET],
1473
+ endpoints={
1474
+ Action.LIST: EndpointDefinition(
1475
+ method='GET',
1476
+ path='/flows',
1477
+ action=Action.LIST,
1478
+ description='Returns a paginated list of flows (automated sequences)',
1479
+ query_params=['page[size]', 'page[cursor]'],
1480
+ query_params_schema={
1481
+ 'page[size]': {
1482
+ 'type': 'integer',
1483
+ 'required': False,
1484
+ 'default': 20,
1485
+ },
1486
+ 'page[cursor]': {'type': 'string', 'required': False},
1487
+ },
1488
+ header_params=['revision'],
1489
+ header_params_schema={
1490
+ 'revision': {
1491
+ 'type': 'string',
1492
+ 'required': True,
1493
+ 'default': '2024-10-15',
1494
+ },
1495
+ },
1496
+ response_schema={
1497
+ 'type': 'object',
1498
+ 'description': 'Paginated list of flows',
1499
+ 'properties': {
1500
+ 'data': {
1501
+ 'type': 'array',
1502
+ 'items': {
1503
+ 'type': 'object',
1504
+ 'description': 'A Klaviyo flow (automated sequence)',
1505
+ 'properties': {
1506
+ 'id': {'type': 'string', 'description': 'Unique flow identifier'},
1507
+ 'type': {
1508
+ 'type': ['string', 'null'],
1509
+ 'description': 'Object type (always "flow")',
1510
+ },
1511
+ 'attributes': {
1512
+ 'type': ['object', 'null'],
1513
+ 'description': 'Flow attributes',
1514
+ 'properties': {
1515
+ 'name': {
1516
+ 'type': ['string', 'null'],
1517
+ 'description': 'Flow name',
1518
+ },
1519
+ 'status': {
1520
+ 'type': ['string', 'null'],
1521
+ 'description': 'Flow status (draft, manual, live)',
1522
+ },
1523
+ 'archived': {
1524
+ 'type': ['boolean', 'null'],
1525
+ 'description': 'Whether flow is archived',
1526
+ },
1527
+ 'created': {
1528
+ 'type': ['string', 'null'],
1529
+ 'format': 'date-time',
1530
+ 'description': 'Creation timestamp',
1531
+ },
1532
+ 'updated': {
1533
+ 'type': ['string', 'null'],
1534
+ 'format': 'date-time',
1535
+ 'description': 'Last update timestamp',
1536
+ },
1537
+ 'trigger_type': {
1538
+ 'type': ['string', 'null'],
1539
+ 'description': 'Type of trigger for the flow',
1540
+ },
1541
+ },
1542
+ },
1543
+ 'links': {
1544
+ 'type': ['object', 'null'],
1545
+ 'description': 'Related links',
1546
+ 'properties': {
1547
+ 'self': {
1548
+ 'type': ['string', 'null'],
1549
+ },
1550
+ },
1551
+ },
1552
+ },
1553
+ 'required': ['id'],
1554
+ 'x-airbyte-entity-name': 'flows',
1555
+ 'x-airbyte-stream-name': 'flows',
1556
+ },
1557
+ },
1558
+ 'links': {
1559
+ 'type': ['object', 'null'],
1560
+ 'properties': {
1561
+ 'self': {
1562
+ 'type': ['string', 'null'],
1563
+ },
1564
+ 'next': {
1565
+ 'type': ['string', 'null'],
1566
+ },
1567
+ 'prev': {
1568
+ 'type': ['string', 'null'],
1569
+ },
1570
+ },
1571
+ },
1572
+ },
1573
+ },
1574
+ record_extractor='$.data',
1575
+ ),
1576
+ Action.GET: EndpointDefinition(
1577
+ method='GET',
1578
+ path='/flows/{id}',
1579
+ action=Action.GET,
1580
+ description='Get a single flow by ID',
1581
+ path_params=['id'],
1582
+ path_params_schema={
1583
+ 'id': {'type': 'string', 'required': True},
1584
+ },
1585
+ header_params=['revision'],
1586
+ header_params_schema={
1587
+ 'revision': {
1588
+ 'type': 'string',
1589
+ 'required': True,
1590
+ 'default': '2024-10-15',
1591
+ },
1592
+ },
1593
+ response_schema={
1594
+ 'type': 'object',
1595
+ 'properties': {
1596
+ 'data': {
1597
+ 'type': 'object',
1598
+ 'description': 'A Klaviyo flow (automated sequence)',
1599
+ 'properties': {
1600
+ 'id': {'type': 'string', 'description': 'Unique flow identifier'},
1601
+ 'type': {
1602
+ 'type': ['string', 'null'],
1603
+ 'description': 'Object type (always "flow")',
1604
+ },
1605
+ 'attributes': {
1606
+ 'type': ['object', 'null'],
1607
+ 'description': 'Flow attributes',
1608
+ 'properties': {
1609
+ 'name': {
1610
+ 'type': ['string', 'null'],
1611
+ 'description': 'Flow name',
1612
+ },
1613
+ 'status': {
1614
+ 'type': ['string', 'null'],
1615
+ 'description': 'Flow status (draft, manual, live)',
1616
+ },
1617
+ 'archived': {
1618
+ 'type': ['boolean', 'null'],
1619
+ 'description': 'Whether flow is archived',
1620
+ },
1621
+ 'created': {
1622
+ 'type': ['string', 'null'],
1623
+ 'format': 'date-time',
1624
+ 'description': 'Creation timestamp',
1625
+ },
1626
+ 'updated': {
1627
+ 'type': ['string', 'null'],
1628
+ 'format': 'date-time',
1629
+ 'description': 'Last update timestamp',
1630
+ },
1631
+ 'trigger_type': {
1632
+ 'type': ['string', 'null'],
1633
+ 'description': 'Type of trigger for the flow',
1634
+ },
1635
+ },
1636
+ },
1637
+ 'links': {
1638
+ 'type': ['object', 'null'],
1639
+ 'description': 'Related links',
1640
+ 'properties': {
1641
+ 'self': {
1642
+ 'type': ['string', 'null'],
1643
+ },
1644
+ },
1645
+ },
1646
+ },
1647
+ 'required': ['id'],
1648
+ 'x-airbyte-entity-name': 'flows',
1649
+ 'x-airbyte-stream-name': 'flows',
1650
+ },
1651
+ },
1652
+ },
1653
+ record_extractor='$.data',
1654
+ ),
1655
+ },
1656
+ entity_schema={
1657
+ 'type': 'object',
1658
+ 'description': 'A Klaviyo flow (automated sequence)',
1659
+ 'properties': {
1660
+ 'id': {'type': 'string', 'description': 'Unique flow identifier'},
1661
+ 'type': {
1662
+ 'type': ['string', 'null'],
1663
+ 'description': 'Object type (always "flow")',
1664
+ },
1665
+ 'attributes': {
1666
+ 'type': ['object', 'null'],
1667
+ 'description': 'Flow attributes',
1668
+ 'properties': {
1669
+ 'name': {
1670
+ 'type': ['string', 'null'],
1671
+ 'description': 'Flow name',
1672
+ },
1673
+ 'status': {
1674
+ 'type': ['string', 'null'],
1675
+ 'description': 'Flow status (draft, manual, live)',
1676
+ },
1677
+ 'archived': {
1678
+ 'type': ['boolean', 'null'],
1679
+ 'description': 'Whether flow is archived',
1680
+ },
1681
+ 'created': {
1682
+ 'type': ['string', 'null'],
1683
+ 'format': 'date-time',
1684
+ 'description': 'Creation timestamp',
1685
+ },
1686
+ 'updated': {
1687
+ 'type': ['string', 'null'],
1688
+ 'format': 'date-time',
1689
+ 'description': 'Last update timestamp',
1690
+ },
1691
+ 'trigger_type': {
1692
+ 'type': ['string', 'null'],
1693
+ 'description': 'Type of trigger for the flow',
1694
+ },
1695
+ },
1696
+ },
1697
+ 'links': {
1698
+ 'type': ['object', 'null'],
1699
+ 'description': 'Related links',
1700
+ 'properties': {
1701
+ 'self': {
1702
+ 'type': ['string', 'null'],
1703
+ },
1704
+ },
1705
+ },
1706
+ },
1707
+ 'required': ['id'],
1708
+ 'x-airbyte-entity-name': 'flows',
1709
+ 'x-airbyte-stream-name': 'flows',
1710
+ },
1711
+ ),
1712
+ EntityDefinition(
1713
+ name='email_templates',
1714
+ stream_name='email_templates',
1715
+ actions=[Action.LIST, Action.GET],
1716
+ endpoints={
1717
+ Action.LIST: EndpointDefinition(
1718
+ method='GET',
1719
+ path='/templates',
1720
+ action=Action.LIST,
1721
+ description='Returns a paginated list of email templates',
1722
+ query_params=['page[size]', 'page[cursor]'],
1723
+ query_params_schema={
1724
+ 'page[size]': {
1725
+ 'type': 'integer',
1726
+ 'required': False,
1727
+ 'default': 20,
1728
+ },
1729
+ 'page[cursor]': {'type': 'string', 'required': False},
1730
+ },
1731
+ header_params=['revision'],
1732
+ header_params_schema={
1733
+ 'revision': {
1734
+ 'type': 'string',
1735
+ 'required': True,
1736
+ 'default': '2024-10-15',
1737
+ },
1738
+ },
1739
+ response_schema={
1740
+ 'type': 'object',
1741
+ 'description': 'Paginated list of templates',
1742
+ 'properties': {
1743
+ 'data': {
1744
+ 'type': 'array',
1745
+ 'items': {
1746
+ 'type': 'object',
1747
+ 'description': 'A Klaviyo email template',
1748
+ 'properties': {
1749
+ 'id': {'type': 'string', 'description': 'Unique template identifier'},
1750
+ 'type': {
1751
+ 'type': ['string', 'null'],
1752
+ 'description': 'Object type (always "template")',
1753
+ },
1754
+ 'attributes': {
1755
+ 'type': ['object', 'null'],
1756
+ 'description': 'Template attributes',
1757
+ 'properties': {
1758
+ 'name': {
1759
+ 'type': ['string', 'null'],
1760
+ 'description': 'Template name',
1761
+ },
1762
+ 'editor_type': {
1763
+ 'type': ['string', 'null'],
1764
+ 'description': 'Editor type used to create template',
1765
+ },
1766
+ 'html': {
1767
+ 'type': ['string', 'null'],
1768
+ 'description': 'HTML content',
1769
+ },
1770
+ 'text': {
1771
+ 'type': ['string', 'null'],
1772
+ 'description': 'Plain text content',
1773
+ },
1774
+ 'created': {
1775
+ 'type': ['string', 'null'],
1776
+ 'format': 'date-time',
1777
+ 'description': 'Creation timestamp',
1778
+ },
1779
+ 'updated': {
1780
+ 'type': ['string', 'null'],
1781
+ 'format': 'date-time',
1782
+ 'description': 'Last update timestamp',
1783
+ },
1784
+ },
1785
+ },
1786
+ 'links': {
1787
+ 'type': ['object', 'null'],
1788
+ 'description': 'Related links',
1789
+ 'properties': {
1790
+ 'self': {
1791
+ 'type': ['string', 'null'],
1792
+ },
1793
+ },
1794
+ },
1795
+ },
1796
+ 'required': ['id'],
1797
+ 'x-airbyte-entity-name': 'email_templates',
1798
+ 'x-airbyte-stream-name': 'email_templates',
1799
+ },
1800
+ },
1801
+ 'links': {
1802
+ 'type': ['object', 'null'],
1803
+ 'properties': {
1804
+ 'self': {
1805
+ 'type': ['string', 'null'],
1806
+ },
1807
+ 'next': {
1808
+ 'type': ['string', 'null'],
1809
+ },
1810
+ 'prev': {
1811
+ 'type': ['string', 'null'],
1812
+ },
1813
+ },
1814
+ },
1815
+ },
1816
+ },
1817
+ record_extractor='$.data',
1818
+ ),
1819
+ Action.GET: EndpointDefinition(
1820
+ method='GET',
1821
+ path='/templates/{id}',
1822
+ action=Action.GET,
1823
+ description='Get a single email template by ID',
1824
+ path_params=['id'],
1825
+ path_params_schema={
1826
+ 'id': {'type': 'string', 'required': True},
1827
+ },
1828
+ header_params=['revision'],
1829
+ header_params_schema={
1830
+ 'revision': {
1831
+ 'type': 'string',
1832
+ 'required': True,
1833
+ 'default': '2024-10-15',
1834
+ },
1835
+ },
1836
+ response_schema={
1837
+ 'type': 'object',
1838
+ 'properties': {
1839
+ 'data': {
1840
+ 'type': 'object',
1841
+ 'description': 'A Klaviyo email template',
1842
+ 'properties': {
1843
+ 'id': {'type': 'string', 'description': 'Unique template identifier'},
1844
+ 'type': {
1845
+ 'type': ['string', 'null'],
1846
+ 'description': 'Object type (always "template")',
1847
+ },
1848
+ 'attributes': {
1849
+ 'type': ['object', 'null'],
1850
+ 'description': 'Template attributes',
1851
+ 'properties': {
1852
+ 'name': {
1853
+ 'type': ['string', 'null'],
1854
+ 'description': 'Template name',
1855
+ },
1856
+ 'editor_type': {
1857
+ 'type': ['string', 'null'],
1858
+ 'description': 'Editor type used to create template',
1859
+ },
1860
+ 'html': {
1861
+ 'type': ['string', 'null'],
1862
+ 'description': 'HTML content',
1863
+ },
1864
+ 'text': {
1865
+ 'type': ['string', 'null'],
1866
+ 'description': 'Plain text content',
1867
+ },
1868
+ 'created': {
1869
+ 'type': ['string', 'null'],
1870
+ 'format': 'date-time',
1871
+ 'description': 'Creation timestamp',
1872
+ },
1873
+ 'updated': {
1874
+ 'type': ['string', 'null'],
1875
+ 'format': 'date-time',
1876
+ 'description': 'Last update timestamp',
1877
+ },
1878
+ },
1879
+ },
1880
+ 'links': {
1881
+ 'type': ['object', 'null'],
1882
+ 'description': 'Related links',
1883
+ 'properties': {
1884
+ 'self': {
1885
+ 'type': ['string', 'null'],
1886
+ },
1887
+ },
1888
+ },
1889
+ },
1890
+ 'required': ['id'],
1891
+ 'x-airbyte-entity-name': 'email_templates',
1892
+ 'x-airbyte-stream-name': 'email_templates',
1893
+ },
1894
+ },
1895
+ },
1896
+ record_extractor='$.data',
1897
+ ),
1898
+ },
1899
+ entity_schema={
1900
+ 'type': 'object',
1901
+ 'description': 'A Klaviyo email template',
1902
+ 'properties': {
1903
+ 'id': {'type': 'string', 'description': 'Unique template identifier'},
1904
+ 'type': {
1905
+ 'type': ['string', 'null'],
1906
+ 'description': 'Object type (always "template")',
1907
+ },
1908
+ 'attributes': {
1909
+ 'type': ['object', 'null'],
1910
+ 'description': 'Template attributes',
1911
+ 'properties': {
1912
+ 'name': {
1913
+ 'type': ['string', 'null'],
1914
+ 'description': 'Template name',
1915
+ },
1916
+ 'editor_type': {
1917
+ 'type': ['string', 'null'],
1918
+ 'description': 'Editor type used to create template',
1919
+ },
1920
+ 'html': {
1921
+ 'type': ['string', 'null'],
1922
+ 'description': 'HTML content',
1923
+ },
1924
+ 'text': {
1925
+ 'type': ['string', 'null'],
1926
+ 'description': 'Plain text content',
1927
+ },
1928
+ 'created': {
1929
+ 'type': ['string', 'null'],
1930
+ 'format': 'date-time',
1931
+ 'description': 'Creation timestamp',
1932
+ },
1933
+ 'updated': {
1934
+ 'type': ['string', 'null'],
1935
+ 'format': 'date-time',
1936
+ 'description': 'Last update timestamp',
1937
+ },
1938
+ },
1939
+ },
1940
+ 'links': {
1941
+ 'type': ['object', 'null'],
1942
+ 'description': 'Related links',
1943
+ 'properties': {
1944
+ 'self': {
1945
+ 'type': ['string', 'null'],
1946
+ },
1947
+ },
1948
+ },
1949
+ },
1950
+ 'required': ['id'],
1951
+ 'x-airbyte-entity-name': 'email_templates',
1952
+ 'x-airbyte-stream-name': 'email_templates',
1953
+ },
1954
+ ),
1955
+ ],
1956
+ search_field_paths={
1957
+ 'profiles': [
1958
+ 'attributes',
1959
+ 'attributes.anonymous_id',
1960
+ 'attributes.created',
1961
+ 'attributes.email',
1962
+ 'attributes.external_id',
1963
+ 'attributes.first_name',
1964
+ 'attributes.image',
1965
+ 'attributes.last_event_date',
1966
+ 'attributes.last_name',
1967
+ 'attributes.locale',
1968
+ 'attributes.location',
1969
+ 'attributes.location.address1',
1970
+ 'attributes.location.address2',
1971
+ 'attributes.location.city',
1972
+ 'attributes.location.country',
1973
+ 'attributes.location.ip',
1974
+ 'attributes.location.latitude',
1975
+ 'attributes.location.longitude',
1976
+ 'attributes.location.region',
1977
+ 'attributes.location.timezone',
1978
+ 'attributes.location.zip',
1979
+ 'attributes.organization',
1980
+ 'attributes.phone_number',
1981
+ 'attributes.predictive_analytics',
1982
+ 'attributes.predictive_analytics.average_days_between_orders',
1983
+ 'attributes.predictive_analytics.average_order_value',
1984
+ 'attributes.predictive_analytics.churn_probability',
1985
+ 'attributes.predictive_analytics.expected_date_of_next_order',
1986
+ 'attributes.predictive_analytics.historic_clv',
1987
+ 'attributes.predictive_analytics.historic_number_of_orders',
1988
+ 'attributes.predictive_analytics.predicted_clv',
1989
+ 'attributes.predictive_analytics.predicted_number_of_orders',
1990
+ 'attributes.predictive_analytics.total_clv',
1991
+ 'attributes.properties',
1992
+ 'attributes.subscriptions',
1993
+ 'attributes.subscriptions.email',
1994
+ 'attributes.subscriptions.email.marketing',
1995
+ 'attributes.subscriptions.email.marketing.can_receive_email_marketing',
1996
+ 'attributes.subscriptions.email.marketing.consent',
1997
+ 'attributes.subscriptions.email.marketing.consent_timestamp',
1998
+ 'attributes.subscriptions.email.marketing.custom_method_detail',
1999
+ 'attributes.subscriptions.email.marketing.double_optin',
2000
+ 'attributes.subscriptions.email.marketing.last_updated',
2001
+ 'attributes.subscriptions.email.marketing.list_suppressions',
2002
+ 'attributes.subscriptions.email.marketing.list_suppressions[]',
2003
+ 'attributes.subscriptions.email.marketing.method',
2004
+ 'attributes.subscriptions.email.marketing.method_detail',
2005
+ 'attributes.subscriptions.email.marketing.suppressions',
2006
+ 'attributes.subscriptions.email.marketing.suppressions[]',
2007
+ 'attributes.subscriptions.email.marketing.timestamp',
2008
+ 'attributes.subscriptions.mobile_push',
2009
+ 'attributes.subscriptions.mobile_push.marketing',
2010
+ 'attributes.subscriptions.mobile_push.marketing.can_receive_sms_marketing',
2011
+ 'attributes.subscriptions.mobile_push.marketing.consent',
2012
+ 'attributes.subscriptions.mobile_push.marketing.consent_timestamp',
2013
+ 'attributes.subscriptions.sms',
2014
+ 'attributes.subscriptions.sms.marketing',
2015
+ 'attributes.subscriptions.sms.marketing.can_receive_sms_marketing',
2016
+ 'attributes.subscriptions.sms.marketing.consent',
2017
+ 'attributes.subscriptions.sms.marketing.consent_timestamp',
2018
+ 'attributes.subscriptions.sms.marketing.last_updated',
2019
+ 'attributes.subscriptions.sms.marketing.method',
2020
+ 'attributes.subscriptions.sms.marketing.method_detail',
2021
+ 'attributes.subscriptions.sms.marketing.timestamp',
2022
+ 'attributes.subscriptions.sms.transactional',
2023
+ 'attributes.subscriptions.sms.transactional.can_receive_sms_marketing',
2024
+ 'attributes.subscriptions.sms.transactional.consent',
2025
+ 'attributes.subscriptions.sms.transactional.consent_timestamp',
2026
+ 'attributes.subscriptions.sms.transactional.last_updated',
2027
+ 'attributes.subscriptions.sms.transactional.method',
2028
+ 'attributes.subscriptions.sms.transactional.method_detail',
2029
+ 'attributes.subscriptions.sms.transactional.timestamp',
2030
+ 'attributes.title',
2031
+ 'attributes.updated',
2032
+ 'id',
2033
+ 'links',
2034
+ 'links.self',
2035
+ 'relationships',
2036
+ 'relationships.lists',
2037
+ 'relationships.lists.links',
2038
+ 'relationships.lists.links.related',
2039
+ 'relationships.lists.links.self',
2040
+ 'relationships.segments',
2041
+ 'relationships.segments.links',
2042
+ 'relationships.segments.links.related',
2043
+ 'relationships.segments.links.self',
2044
+ 'segments',
2045
+ 'type',
2046
+ 'updated',
2047
+ ],
2048
+ 'events': [
2049
+ 'attributes',
2050
+ 'attributes.datetime',
2051
+ 'attributes.event_properties',
2052
+ 'attributes.timestamp',
2053
+ 'attributes.uuid',
2054
+ 'datetime',
2055
+ 'id',
2056
+ 'links',
2057
+ 'links.self',
2058
+ 'relationships',
2059
+ 'relationships.attributions',
2060
+ 'relationships.attributions.data',
2061
+ 'relationships.attributions.data[]',
2062
+ 'relationships.attributions.links',
2063
+ 'relationships.attributions.links.related',
2064
+ 'relationships.attributions.links.self',
2065
+ 'relationships.metric',
2066
+ 'relationships.metric.data',
2067
+ 'relationships.metric.data.type',
2068
+ 'relationships.metric.data.id',
2069
+ 'relationships.metric.links',
2070
+ 'relationships.metric.links.related',
2071
+ 'relationships.metric.links.self',
2072
+ 'relationships.profile',
2073
+ 'relationships.profile.data',
2074
+ 'relationships.profile.data.type',
2075
+ 'relationships.profile.data.id',
2076
+ 'relationships.profile.links',
2077
+ 'relationships.profile.links.related',
2078
+ 'relationships.profile.links.self',
2079
+ 'type',
2080
+ ],
2081
+ 'email_templates': [
2082
+ 'attributes',
2083
+ 'attributes.company_id',
2084
+ 'attributes.created',
2085
+ 'attributes.editor_type',
2086
+ 'attributes.html',
2087
+ 'attributes.name',
2088
+ 'attributes.text',
2089
+ 'attributes.updated',
2090
+ 'id',
2091
+ 'links',
2092
+ 'links.self',
2093
+ 'type',
2094
+ 'updated',
2095
+ ],
2096
+ 'campaigns': [
2097
+ 'attributes',
2098
+ 'attributes.archived',
2099
+ 'attributes.audiences',
2100
+ 'attributes.audiences.excluded',
2101
+ 'attributes.audiences.excluded[]',
2102
+ 'attributes.audiences.included',
2103
+ 'attributes.audiences.included[]',
2104
+ 'attributes.channel',
2105
+ 'attributes.created_at',
2106
+ 'attributes.message',
2107
+ 'attributes.name',
2108
+ 'attributes.scheduled_at',
2109
+ 'attributes.send_options',
2110
+ 'attributes.send_options.ignore_unsubscribes',
2111
+ 'attributes.send_options.use_smart_sending',
2112
+ 'attributes.send_strategy',
2113
+ 'attributes.send_strategy.method',
2114
+ 'attributes.send_strategy.options_static',
2115
+ 'attributes.send_strategy.options_static.datetime',
2116
+ 'attributes.send_strategy.options_static.is_local',
2117
+ 'attributes.send_strategy.options_static.send_past_recipients_immediately',
2118
+ 'attributes.send_strategy.options_sto',
2119
+ 'attributes.send_strategy.options_sto.date',
2120
+ 'attributes.send_strategy.options_throttled',
2121
+ 'attributes.send_strategy.options_throttled.datetime',
2122
+ 'attributes.send_strategy.options_throttled.throttle_percentage',
2123
+ 'attributes.send_time',
2124
+ 'attributes.status',
2125
+ 'attributes.tracking_options',
2126
+ 'attributes.tracking_options.add_tracking_params',
2127
+ 'attributes.tracking_options.is_add_utm',
2128
+ 'attributes.tracking_options.is_tracking_clicks',
2129
+ 'attributes.tracking_options.is_tracking_opens',
2130
+ 'attributes.tracking_options.utm_params',
2131
+ 'attributes.tracking_options.utm_params[]',
2132
+ 'attributes.updated_at',
2133
+ 'id',
2134
+ 'links',
2135
+ 'links.self',
2136
+ 'relationships',
2137
+ 'relationships.campaign-messages',
2138
+ 'relationships.campaign-messages.data',
2139
+ 'relationships.campaign-messages.data[]',
2140
+ 'relationships.campaign-messages.links',
2141
+ 'relationships.campaign-messages.links.related',
2142
+ 'relationships.campaign-messages.links.self',
2143
+ 'relationships.tags',
2144
+ 'relationships.tags.data',
2145
+ 'relationships.tags.data[]',
2146
+ 'relationships.tags.links',
2147
+ 'relationships.tags.links.related',
2148
+ 'relationships.tags.links.self',
2149
+ 'type',
2150
+ 'updated_at',
2151
+ ],
2152
+ 'flows': [
2153
+ 'attributes',
2154
+ 'attributes.archived',
2155
+ 'attributes.created',
2156
+ 'attributes.name',
2157
+ 'attributes.status',
2158
+ 'attributes.trigger_type',
2159
+ 'attributes.updated',
2160
+ 'id',
2161
+ 'links',
2162
+ 'links.self',
2163
+ 'relationships',
2164
+ 'relationships.flow-actions',
2165
+ 'relationships.flow-actions.data',
2166
+ 'relationships.flow-actions.data[]',
2167
+ 'relationships.flow-actions.links',
2168
+ 'relationships.flow-actions.links.related',
2169
+ 'relationships.flow-actions.links.self',
2170
+ 'relationships.tags',
2171
+ 'relationships.tags.data',
2172
+ 'relationships.tags.data[]',
2173
+ 'relationships.tags.links',
2174
+ 'relationships.tags.links.related',
2175
+ 'relationships.tags.links.self',
2176
+ 'type',
2177
+ 'updated',
2178
+ ],
2179
+ 'metrics': [
2180
+ 'attributes',
2181
+ 'attributes.created',
2182
+ 'attributes.integration',
2183
+ 'attributes.name',
2184
+ 'attributes.updated',
2185
+ 'id',
2186
+ 'links',
2187
+ 'links.self',
2188
+ 'relationships',
2189
+ 'relationships.flow-triggers',
2190
+ 'relationships.flow-triggers.data',
2191
+ 'relationships.flow-triggers.data.type',
2192
+ 'relationships.flow-triggers.data.id',
2193
+ 'relationships.flow-triggers.links',
2194
+ 'relationships.flow-triggers.links.related',
2195
+ 'relationships.flow-triggers.links.self',
2196
+ 'type',
2197
+ 'updated',
2198
+ ],
2199
+ 'lists': [
2200
+ 'attributes',
2201
+ 'attributes.created',
2202
+ 'attributes.name',
2203
+ 'attributes.opt_in_process',
2204
+ 'attributes.updated',
2205
+ 'id',
2206
+ 'links',
2207
+ 'links.self',
2208
+ 'relationships',
2209
+ 'relationships.flow-triggers',
2210
+ 'relationships.flow-triggers.data',
2211
+ 'relationships.flow-triggers.data.type',
2212
+ 'relationships.flow-triggers.data.id',
2213
+ 'relationships.flow-triggers.links',
2214
+ 'relationships.flow-triggers.links.related',
2215
+ 'relationships.flow-triggers.links.self',
2216
+ 'relationships.profiles',
2217
+ 'relationships.profiles.links',
2218
+ 'relationships.profiles.links.related',
2219
+ 'relationships.profiles.links.self',
2220
+ 'relationships.tags',
2221
+ 'relationships.tags.data',
2222
+ 'relationships.tags.data[]',
2223
+ 'relationships.tags.links',
2224
+ 'relationships.tags.links.related',
2225
+ 'relationships.tags.links.self',
2226
+ 'type',
2227
+ 'updated',
2228
+ ],
2229
+ },
2230
+ )