post-for-me 0.1.0.pre.alpha.9 → 0.1.0.pre.alpha.11

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 (45) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +44 -0
  3. data/README.md +1 -1
  4. data/lib/post_for_me/client.rb +4 -0
  5. data/lib/post_for_me/internal/transport/base_client.rb +7 -1
  6. data/lib/post_for_me/internal/transport/pooled_net_requester.rb +38 -26
  7. data/lib/post_for_me/internal/util.rb +12 -7
  8. data/lib/post_for_me/models/platform_post.rb +843 -0
  9. data/lib/post_for_me/models/social_account.rb +9 -1
  10. data/lib/post_for_me/models/social_account_create_auth_url_params.rb +245 -9
  11. data/lib/post_for_me/models/social_account_disconnect_response.rb +9 -1
  12. data/lib/post_for_me/models/social_account_feed_list_params.rb +81 -0
  13. data/lib/post_for_me/models/social_account_feed_list_response.rb +58 -0
  14. data/lib/post_for_me/models.rb +4 -0
  15. data/lib/post_for_me/resources/social_account_feeds.rb +51 -0
  16. data/lib/post_for_me/resources/social_accounts.rb +8 -1
  17. data/lib/post_for_me/version.rb +1 -1
  18. data/lib/post_for_me.rb +6 -0
  19. data/manifest.yaml +2 -0
  20. data/rbi/post_for_me/client.rbi +3 -0
  21. data/rbi/post_for_me/internal/transport/base_client.rbi +5 -0
  22. data/rbi/post_for_me/internal/transport/pooled_net_requester.rbi +6 -2
  23. data/rbi/post_for_me/internal/type/base_model.rbi +8 -4
  24. data/rbi/post_for_me/models/platform_post.rbi +1287 -0
  25. data/rbi/post_for_me/models/social_account.rbi +8 -0
  26. data/rbi/post_for_me/models/social_account_create_auth_url_params.rbi +545 -15
  27. data/rbi/post_for_me/models/social_account_disconnect_response.rbi +8 -0
  28. data/rbi/post_for_me/models/social_account_feed_list_params.rbi +157 -0
  29. data/rbi/post_for_me/models/social_account_feed_list_response.rbi +110 -0
  30. data/rbi/post_for_me/models.rbi +4 -0
  31. data/rbi/post_for_me/resources/social_account_feeds.rbi +51 -0
  32. data/rbi/post_for_me/resources/social_accounts.rbi +13 -0
  33. data/sig/post_for_me/client.rbs +2 -0
  34. data/sig/post_for_me/internal/transport/base_client.rbs +2 -0
  35. data/sig/post_for_me/internal/transport/pooled_net_requester.rbs +4 -1
  36. data/sig/post_for_me/models/platform_post.rbs +660 -0
  37. data/sig/post_for_me/models/social_account.rbs +5 -0
  38. data/sig/post_for_me/models/social_account_create_auth_url_params.rbs +193 -10
  39. data/sig/post_for_me/models/social_account_disconnect_response.rbs +5 -0
  40. data/sig/post_for_me/models/social_account_feed_list_params.rbs +75 -0
  41. data/sig/post_for_me/models/social_account_feed_list_response.rbs +54 -0
  42. data/sig/post_for_me/models.rbs +4 -0
  43. data/sig/post_for_me/resources/social_account_feeds.rbs +18 -0
  44. data/sig/post_for_me/resources/social_accounts.rbs +2 -0
  45. metadata +14 -2
@@ -0,0 +1,843 @@
1
+ # frozen_string_literal: true
2
+
3
+ module PostForMe
4
+ module Models
5
+ class PlatformPost < PostForMe::Internal::Type::BaseModel
6
+ # @!attribute caption
7
+ # Caption or text content of the post
8
+ #
9
+ # @return [String]
10
+ required :caption, String
11
+
12
+ # @!attribute media
13
+ # Array of media items attached to the post
14
+ #
15
+ # @return [Array<Array<Object>>]
16
+ required :media,
17
+ PostForMe::Internal::Type::ArrayOf[PostForMe::Internal::Type::ArrayOf[PostForMe::Internal::Type::Unknown]]
18
+
19
+ # @!attribute platform
20
+ # Social media platform name
21
+ #
22
+ # @return [String]
23
+ required :platform, String
24
+
25
+ # @!attribute platform_account_id
26
+ # Platform-specific account ID
27
+ #
28
+ # @return [String]
29
+ required :platform_account_id, String
30
+
31
+ # @!attribute platform_post_id
32
+ # Platform-specific post ID
33
+ #
34
+ # @return [String]
35
+ required :platform_post_id, String
36
+
37
+ # @!attribute platform_url
38
+ # URL to the post on the platform
39
+ #
40
+ # @return [String]
41
+ required :platform_url, String
42
+
43
+ # @!attribute social_account_id
44
+ # ID of the social account
45
+ #
46
+ # @return [String]
47
+ required :social_account_id, String
48
+
49
+ # @!attribute external_account_id
50
+ # External account ID from the platform
51
+ #
52
+ # @return [String, nil]
53
+ optional :external_account_id, String, nil?: true
54
+
55
+ # @!attribute external_post_id
56
+ # External post ID from the platform
57
+ #
58
+ # @return [String, nil]
59
+ optional :external_post_id, String, nil?: true
60
+
61
+ # @!attribute metrics
62
+ # Post metrics and analytics data
63
+ #
64
+ # @return [PostForMe::Models::PlatformPost::Metrics::TikTokBusinessMetricsDto, PostForMe::Models::PlatformPost::Metrics::TikTokPostMetricsDto, PostForMe::Models::PlatformPost::Metrics::InstagramPostMetricsDto, PostForMe::Models::PlatformPost::Metrics::YouTubePostMetricsDto, nil]
65
+ optional :metrics, union: -> { PostForMe::PlatformPost::Metrics }
66
+
67
+ # @!attribute posted_at
68
+ # Date the post was published
69
+ #
70
+ # @return [Time, nil]
71
+ optional :posted_at, Time
72
+
73
+ # @!attribute social_post_id
74
+ # ID of the social post
75
+ #
76
+ # @return [String, nil]
77
+ optional :social_post_id, String, nil?: true
78
+
79
+ # @!attribute social_post_result_id
80
+ # ID of the social post result
81
+ #
82
+ # @return [String, nil]
83
+ optional :social_post_result_id, String, nil?: true
84
+
85
+ # @!method initialize(caption:, media:, platform:, platform_account_id:, platform_post_id:, platform_url:, social_account_id:, external_account_id: nil, external_post_id: nil, metrics: nil, posted_at: nil, social_post_id: nil, social_post_result_id: nil)
86
+ # @param caption [String] Caption or text content of the post
87
+ #
88
+ # @param media [Array<Array<Object>>] Array of media items attached to the post
89
+ #
90
+ # @param platform [String] Social media platform name
91
+ #
92
+ # @param platform_account_id [String] Platform-specific account ID
93
+ #
94
+ # @param platform_post_id [String] Platform-specific post ID
95
+ #
96
+ # @param platform_url [String] URL to the post on the platform
97
+ #
98
+ # @param social_account_id [String] ID of the social account
99
+ #
100
+ # @param external_account_id [String, nil] External account ID from the platform
101
+ #
102
+ # @param external_post_id [String, nil] External post ID from the platform
103
+ #
104
+ # @param metrics [PostForMe::Models::PlatformPost::Metrics::TikTokBusinessMetricsDto, PostForMe::Models::PlatformPost::Metrics::TikTokPostMetricsDto, PostForMe::Models::PlatformPost::Metrics::InstagramPostMetricsDto, PostForMe::Models::PlatformPost::Metrics::YouTubePostMetricsDto] Post metrics and analytics data
105
+ #
106
+ # @param posted_at [Time] Date the post was published
107
+ #
108
+ # @param social_post_id [String, nil] ID of the social post
109
+ #
110
+ # @param social_post_result_id [String, nil] ID of the social post result
111
+
112
+ # Post metrics and analytics data
113
+ #
114
+ # @see PostForMe::Models::PlatformPost#metrics
115
+ module Metrics
116
+ extend PostForMe::Internal::Type::Union
117
+
118
+ variant -> { PostForMe::PlatformPost::Metrics::TikTokBusinessMetricsDto }
119
+
120
+ variant -> { PostForMe::PlatformPost::Metrics::TikTokPostMetricsDto }
121
+
122
+ variant -> { PostForMe::PlatformPost::Metrics::InstagramPostMetricsDto }
123
+
124
+ variant -> { PostForMe::PlatformPost::Metrics::YouTubePostMetricsDto }
125
+
126
+ class TikTokBusinessMetricsDto < PostForMe::Internal::Type::BaseModel
127
+ # @!attribute address_clicks
128
+ # Number of address clicks
129
+ #
130
+ # @return [Float]
131
+ required :address_clicks, Float
132
+
133
+ # @!attribute app_download_clicks
134
+ # Number of app download clicks
135
+ #
136
+ # @return [Float]
137
+ required :app_download_clicks, Float
138
+
139
+ # @!attribute audience_cities
140
+ # Audience cities breakdown
141
+ #
142
+ # @return [Array<PostForMe::Models::PlatformPost::Metrics::TikTokBusinessMetricsDto::AudienceCity>]
143
+ required :audience_cities,
144
+ -> { PostForMe::Internal::Type::ArrayOf[PostForMe::PlatformPost::Metrics::TikTokBusinessMetricsDto::AudienceCity] }
145
+
146
+ # @!attribute audience_countries
147
+ # Audience countries breakdown
148
+ #
149
+ # @return [Array<PostForMe::Models::PlatformPost::Metrics::TikTokBusinessMetricsDto::AudienceCountry>]
150
+ required :audience_countries,
151
+ -> { PostForMe::Internal::Type::ArrayOf[PostForMe::PlatformPost::Metrics::TikTokBusinessMetricsDto::AudienceCountry] }
152
+
153
+ # @!attribute audience_genders
154
+ # Audience genders breakdown
155
+ #
156
+ # @return [Array<PostForMe::Models::PlatformPost::Metrics::TikTokBusinessMetricsDto::AudienceGender>]
157
+ required :audience_genders,
158
+ -> { PostForMe::Internal::Type::ArrayOf[PostForMe::PlatformPost::Metrics::TikTokBusinessMetricsDto::AudienceGender] }
159
+
160
+ # @!attribute audience_types
161
+ # Audience types breakdown
162
+ #
163
+ # @return [Array<PostForMe::Models::PlatformPost::Metrics::TikTokBusinessMetricsDto::AudienceType>]
164
+ required :audience_types,
165
+ -> { PostForMe::Internal::Type::ArrayOf[PostForMe::PlatformPost::Metrics::TikTokBusinessMetricsDto::AudienceType] }
166
+
167
+ # @!attribute average_time_watched
168
+ # Average time watched in seconds
169
+ #
170
+ # @return [Float]
171
+ required :average_time_watched, Float
172
+
173
+ # @!attribute comments
174
+ # Number of comments on the post
175
+ #
176
+ # @return [Float]
177
+ required :comments, Float
178
+
179
+ # @!attribute email_clicks
180
+ # Number of email clicks
181
+ #
182
+ # @return [Float]
183
+ required :email_clicks, Float
184
+
185
+ # @!attribute engagement_likes
186
+ # Engagement likes data by percentage and time
187
+ #
188
+ # @return [Array<PostForMe::Models::PlatformPost::Metrics::TikTokBusinessMetricsDto::EngagementLike>]
189
+ required :engagement_likes,
190
+ -> { PostForMe::Internal::Type::ArrayOf[PostForMe::PlatformPost::Metrics::TikTokBusinessMetricsDto::EngagementLike] }
191
+
192
+ # @!attribute favorites
193
+ # Number of favorites on the post
194
+ #
195
+ # @return [Float]
196
+ required :favorites, Float
197
+
198
+ # @!attribute full_video_watched_rate
199
+ # Rate of full video watches as a percentage
200
+ #
201
+ # @return [Float]
202
+ required :full_video_watched_rate, Float
203
+
204
+ # @!attribute impression_sources
205
+ # Impression sources breakdown
206
+ #
207
+ # @return [Array<PostForMe::Models::PlatformPost::Metrics::TikTokBusinessMetricsDto::ImpressionSource>]
208
+ required :impression_sources,
209
+ -> { PostForMe::Internal::Type::ArrayOf[PostForMe::PlatformPost::Metrics::TikTokBusinessMetricsDto::ImpressionSource] }
210
+
211
+ # @!attribute lead_submissions
212
+ # Number of lead submissions
213
+ #
214
+ # @return [Float]
215
+ required :lead_submissions, Float
216
+
217
+ # @!attribute likes
218
+ # Number of likes on the post
219
+ #
220
+ # @return [Float]
221
+ required :likes, Float
222
+
223
+ # @!attribute new_followers
224
+ # Number of new followers gained from the post
225
+ #
226
+ # @return [Float]
227
+ required :new_followers, Float
228
+
229
+ # @!attribute phone_number_clicks
230
+ # Number of phone number clicks
231
+ #
232
+ # @return [Float]
233
+ required :phone_number_clicks, Float
234
+
235
+ # @!attribute profile_views
236
+ # Number of profile views generated
237
+ #
238
+ # @return [Float]
239
+ required :profile_views, Float
240
+
241
+ # @!attribute reach
242
+ # Total reach of the post
243
+ #
244
+ # @return [Float]
245
+ required :reach, Float
246
+
247
+ # @!attribute shares
248
+ # Number of shares on the post
249
+ #
250
+ # @return [Float]
251
+ required :shares, Float
252
+
253
+ # @!attribute total_time_watched
254
+ # Total time watched in seconds
255
+ #
256
+ # @return [Float]
257
+ required :total_time_watched, Float
258
+
259
+ # @!attribute video_view_retention
260
+ # Video view retention data by percentage and time
261
+ #
262
+ # @return [Array<PostForMe::Models::PlatformPost::Metrics::TikTokBusinessMetricsDto::VideoViewRetention>]
263
+ required :video_view_retention,
264
+ -> { PostForMe::Internal::Type::ArrayOf[PostForMe::PlatformPost::Metrics::TikTokBusinessMetricsDto::VideoViewRetention] }
265
+
266
+ # @!attribute video_views
267
+ # Total number of video views
268
+ #
269
+ # @return [Float]
270
+ required :video_views, Float
271
+
272
+ # @!attribute website_clicks
273
+ # Number of website clicks
274
+ #
275
+ # @return [Float]
276
+ required :website_clicks, Float
277
+
278
+ # @!method initialize(address_clicks:, app_download_clicks:, audience_cities:, audience_countries:, audience_genders:, audience_types:, average_time_watched:, comments:, email_clicks:, engagement_likes:, favorites:, full_video_watched_rate:, impression_sources:, lead_submissions:, likes:, new_followers:, phone_number_clicks:, profile_views:, reach:, shares:, total_time_watched:, video_view_retention:, video_views:, website_clicks:)
279
+ # @param address_clicks [Float] Number of address clicks
280
+ #
281
+ # @param app_download_clicks [Float] Number of app download clicks
282
+ #
283
+ # @param audience_cities [Array<PostForMe::Models::PlatformPost::Metrics::TikTokBusinessMetricsDto::AudienceCity>] Audience cities breakdown
284
+ #
285
+ # @param audience_countries [Array<PostForMe::Models::PlatformPost::Metrics::TikTokBusinessMetricsDto::AudienceCountry>] Audience countries breakdown
286
+ #
287
+ # @param audience_genders [Array<PostForMe::Models::PlatformPost::Metrics::TikTokBusinessMetricsDto::AudienceGender>] Audience genders breakdown
288
+ #
289
+ # @param audience_types [Array<PostForMe::Models::PlatformPost::Metrics::TikTokBusinessMetricsDto::AudienceType>] Audience types breakdown
290
+ #
291
+ # @param average_time_watched [Float] Average time watched in seconds
292
+ #
293
+ # @param comments [Float] Number of comments on the post
294
+ #
295
+ # @param email_clicks [Float] Number of email clicks
296
+ #
297
+ # @param engagement_likes [Array<PostForMe::Models::PlatformPost::Metrics::TikTokBusinessMetricsDto::EngagementLike>] Engagement likes data by percentage and time
298
+ #
299
+ # @param favorites [Float] Number of favorites on the post
300
+ #
301
+ # @param full_video_watched_rate [Float] Rate of full video watches as a percentage
302
+ #
303
+ # @param impression_sources [Array<PostForMe::Models::PlatformPost::Metrics::TikTokBusinessMetricsDto::ImpressionSource>] Impression sources breakdown
304
+ #
305
+ # @param lead_submissions [Float] Number of lead submissions
306
+ #
307
+ # @param likes [Float] Number of likes on the post
308
+ #
309
+ # @param new_followers [Float] Number of new followers gained from the post
310
+ #
311
+ # @param phone_number_clicks [Float] Number of phone number clicks
312
+ #
313
+ # @param profile_views [Float] Number of profile views generated
314
+ #
315
+ # @param reach [Float] Total reach of the post
316
+ #
317
+ # @param shares [Float] Number of shares on the post
318
+ #
319
+ # @param total_time_watched [Float] Total time watched in seconds
320
+ #
321
+ # @param video_view_retention [Array<PostForMe::Models::PlatformPost::Metrics::TikTokBusinessMetricsDto::VideoViewRetention>] Video view retention data by percentage and time
322
+ #
323
+ # @param video_views [Float] Total number of video views
324
+ #
325
+ # @param website_clicks [Float] Number of website clicks
326
+
327
+ class AudienceCity < PostForMe::Internal::Type::BaseModel
328
+ # @!attribute city_name
329
+ # City name
330
+ #
331
+ # @return [String]
332
+ required :city_name, String
333
+
334
+ # @!attribute percentage
335
+ # Percentage of audience from this city
336
+ #
337
+ # @return [Float]
338
+ required :percentage, Float
339
+
340
+ # @!method initialize(city_name:, percentage:)
341
+ # @param city_name [String] City name
342
+ #
343
+ # @param percentage [Float] Percentage of audience from this city
344
+ end
345
+
346
+ class AudienceCountry < PostForMe::Internal::Type::BaseModel
347
+ # @!attribute country
348
+ # Country name
349
+ #
350
+ # @return [String]
351
+ required :country, String
352
+
353
+ # @!attribute percentage
354
+ # Percentage of audience from this country
355
+ #
356
+ # @return [Float]
357
+ required :percentage, Float
358
+
359
+ # @!method initialize(country:, percentage:)
360
+ # @param country [String] Country name
361
+ #
362
+ # @param percentage [Float] Percentage of audience from this country
363
+ end
364
+
365
+ class AudienceGender < PostForMe::Internal::Type::BaseModel
366
+ # @!attribute gender
367
+ # Gender category
368
+ #
369
+ # @return [String]
370
+ required :gender, String
371
+
372
+ # @!attribute percentage
373
+ # Percentage of audience of this gender
374
+ #
375
+ # @return [Float]
376
+ required :percentage, Float
377
+
378
+ # @!method initialize(gender:, percentage:)
379
+ # @param gender [String] Gender category
380
+ #
381
+ # @param percentage [Float] Percentage of audience of this gender
382
+ end
383
+
384
+ class AudienceType < PostForMe::Internal::Type::BaseModel
385
+ # @!attribute percentage
386
+ # Percentage of audience of this type
387
+ #
388
+ # @return [Float]
389
+ required :percentage, Float
390
+
391
+ # @!attribute type
392
+ # Type of audience
393
+ #
394
+ # @return [String]
395
+ required :type, String
396
+
397
+ # @!method initialize(percentage:, type:)
398
+ # @param percentage [Float] Percentage of audience of this type
399
+ #
400
+ # @param type [String] Type of audience
401
+ end
402
+
403
+ class EngagementLike < PostForMe::Internal::Type::BaseModel
404
+ # @!attribute percentage
405
+ # Percentage value for the metric
406
+ #
407
+ # @return [Float]
408
+ required :percentage, Float
409
+
410
+ # @!attribute second
411
+ # Time in seconds for the metric
412
+ #
413
+ # @return [String]
414
+ required :second, String
415
+
416
+ # @!method initialize(percentage:, second:)
417
+ # @param percentage [Float] Percentage value for the metric
418
+ #
419
+ # @param second [String] Time in seconds for the metric
420
+ end
421
+
422
+ class ImpressionSource < PostForMe::Internal::Type::BaseModel
423
+ # @!attribute impression_source
424
+ # Name of the impression source
425
+ #
426
+ # @return [String]
427
+ required :impression_source, String
428
+
429
+ # @!attribute percentage
430
+ # Percentage of impressions from this source
431
+ #
432
+ # @return [Float]
433
+ required :percentage, Float
434
+
435
+ # @!method initialize(impression_source:, percentage:)
436
+ # @param impression_source [String] Name of the impression source
437
+ #
438
+ # @param percentage [Float] Percentage of impressions from this source
439
+ end
440
+
441
+ class VideoViewRetention < PostForMe::Internal::Type::BaseModel
442
+ # @!attribute percentage
443
+ # Percentage value for the metric
444
+ #
445
+ # @return [Float]
446
+ required :percentage, Float
447
+
448
+ # @!attribute second
449
+ # Time in seconds for the metric
450
+ #
451
+ # @return [String]
452
+ required :second, String
453
+
454
+ # @!method initialize(percentage:, second:)
455
+ # @param percentage [Float] Percentage value for the metric
456
+ #
457
+ # @param second [String] Time in seconds for the metric
458
+ end
459
+ end
460
+
461
+ class TikTokPostMetricsDto < PostForMe::Internal::Type::BaseModel
462
+ # @!attribute comment_count
463
+ # Number of comments on the video
464
+ #
465
+ # @return [Float]
466
+ required :comment_count, Float
467
+
468
+ # @!attribute like_count
469
+ # Number of likes on the video
470
+ #
471
+ # @return [Float]
472
+ required :like_count, Float
473
+
474
+ # @!attribute share_count
475
+ # Number of shares of the video
476
+ #
477
+ # @return [Float]
478
+ required :share_count, Float
479
+
480
+ # @!attribute view_count
481
+ # Number of views on the video
482
+ #
483
+ # @return [Float]
484
+ required :view_count, Float
485
+
486
+ # @!method initialize(comment_count:, like_count:, share_count:, view_count:)
487
+ # @param comment_count [Float] Number of comments on the video
488
+ #
489
+ # @param like_count [Float] Number of likes on the video
490
+ #
491
+ # @param share_count [Float] Number of shares of the video
492
+ #
493
+ # @param view_count [Float] Number of views on the video
494
+ end
495
+
496
+ class InstagramPostMetricsDto < PostForMe::Internal::Type::BaseModel
497
+ # @!attribute comments
498
+ # Number of comments on the post
499
+ #
500
+ # @return [Float, nil]
501
+ optional :comments, Float
502
+
503
+ # @!attribute follows
504
+ # Number of new follows from this post
505
+ #
506
+ # @return [Float, nil]
507
+ optional :follows, Float
508
+
509
+ # @!attribute ig_reels_avg_watch_time
510
+ # Average watch time for Reels (in milliseconds)
511
+ #
512
+ # @return [Float, nil]
513
+ optional :ig_reels_avg_watch_time, Float
514
+
515
+ # @!attribute ig_reels_video_view_total_time
516
+ # Total watch time for Reels (in milliseconds)
517
+ #
518
+ # @return [Float, nil]
519
+ optional :ig_reels_video_view_total_time, Float
520
+
521
+ # @!attribute likes
522
+ # Number of likes on the post
523
+ #
524
+ # @return [Float, nil]
525
+ optional :likes, Float
526
+
527
+ # @!attribute navigation
528
+ # Navigation actions taken on the media
529
+ #
530
+ # @return [Float, nil]
531
+ optional :navigation, Float
532
+
533
+ # @!attribute profile_activity
534
+ # Profile activity generated from this post
535
+ #
536
+ # @return [Float, nil]
537
+ optional :profile_activity, Float
538
+
539
+ # @!attribute profile_visits
540
+ # Number of profile visits from this post
541
+ #
542
+ # @return [Float, nil]
543
+ optional :profile_visits, Float
544
+
545
+ # @!attribute reach
546
+ # Total number of unique accounts that have seen the media
547
+ #
548
+ # @return [Float, nil]
549
+ optional :reach, Float
550
+
551
+ # @!attribute replies
552
+ # Number of replies to the story (story media only)
553
+ #
554
+ # @return [Float, nil]
555
+ optional :replies, Float
556
+
557
+ # @!attribute saved
558
+ # Total number of unique accounts that have saved the media
559
+ #
560
+ # @return [Float, nil]
561
+ optional :saved, Float
562
+
563
+ # @!attribute shares
564
+ # Total number of shares of the media
565
+ #
566
+ # @return [Float, nil]
567
+ optional :shares, Float
568
+
569
+ # @!attribute total_interactions
570
+ # Total interactions on the post
571
+ #
572
+ # @return [Float, nil]
573
+ optional :total_interactions, Float
574
+
575
+ # @!attribute views
576
+ # Number of views on the post
577
+ #
578
+ # @return [Float, nil]
579
+ optional :views, Float
580
+
581
+ # @!method initialize(comments: nil, follows: nil, ig_reels_avg_watch_time: nil, ig_reels_video_view_total_time: nil, likes: nil, navigation: nil, profile_activity: nil, profile_visits: nil, reach: nil, replies: nil, saved: nil, shares: nil, total_interactions: nil, views: nil)
582
+ # @param comments [Float] Number of comments on the post
583
+ #
584
+ # @param follows [Float] Number of new follows from this post
585
+ #
586
+ # @param ig_reels_avg_watch_time [Float] Average watch time for Reels (in milliseconds)
587
+ #
588
+ # @param ig_reels_video_view_total_time [Float] Total watch time for Reels (in milliseconds)
589
+ #
590
+ # @param likes [Float] Number of likes on the post
591
+ #
592
+ # @param navigation [Float] Navigation actions taken on the media
593
+ #
594
+ # @param profile_activity [Float] Profile activity generated from this post
595
+ #
596
+ # @param profile_visits [Float] Number of profile visits from this post
597
+ #
598
+ # @param reach [Float] Total number of unique accounts that have seen the media
599
+ #
600
+ # @param replies [Float] Number of replies to the story (story media only)
601
+ #
602
+ # @param saved [Float] Total number of unique accounts that have saved the media
603
+ #
604
+ # @param shares [Float] Total number of shares of the media
605
+ #
606
+ # @param total_interactions [Float] Total interactions on the post
607
+ #
608
+ # @param views [Float] Number of views on the post
609
+ end
610
+
611
+ class YouTubePostMetricsDto < PostForMe::Internal::Type::BaseModel
612
+ # @!attribute comments
613
+ # Number of comments on the video
614
+ #
615
+ # @return [Float]
616
+ required :comments, Float
617
+
618
+ # @!attribute dislikes
619
+ # Number of dislikes on the video
620
+ #
621
+ # @return [Float]
622
+ required :dislikes, Float
623
+
624
+ # @!attribute likes
625
+ # Number of likes on the video
626
+ #
627
+ # @return [Float]
628
+ required :likes, Float
629
+
630
+ # @!attribute views
631
+ # Number of views on the video
632
+ #
633
+ # @return [Float]
634
+ required :views, Float
635
+
636
+ # @!attribute annotation_clickable_impressions
637
+ # Number of clickable annotation impressions
638
+ #
639
+ # @return [Float, nil]
640
+ optional :annotation_clickable_impressions, Float, api_name: :annotationClickableImpressions
641
+
642
+ # @!attribute annotation_clicks
643
+ # Number of annotation clicks
644
+ #
645
+ # @return [Float, nil]
646
+ optional :annotation_clicks, Float, api_name: :annotationClicks
647
+
648
+ # @!attribute annotation_click_through_rate
649
+ # Annotation click-through rate
650
+ #
651
+ # @return [Float, nil]
652
+ optional :annotation_click_through_rate, Float, api_name: :annotationClickThroughRate
653
+
654
+ # @!attribute annotation_closable_impressions
655
+ # Number of closable annotation impressions
656
+ #
657
+ # @return [Float, nil]
658
+ optional :annotation_closable_impressions, Float, api_name: :annotationClosableImpressions
659
+
660
+ # @!attribute annotation_close_rate
661
+ # Annotation close rate
662
+ #
663
+ # @return [Float, nil]
664
+ optional :annotation_close_rate, Float, api_name: :annotationCloseRate
665
+
666
+ # @!attribute annotation_closes
667
+ # Number of annotation closes
668
+ #
669
+ # @return [Float, nil]
670
+ optional :annotation_closes, Float, api_name: :annotationCloses
671
+
672
+ # @!attribute annotation_impressions
673
+ # Number of annotation impressions
674
+ #
675
+ # @return [Float, nil]
676
+ optional :annotation_impressions, Float, api_name: :annotationImpressions
677
+
678
+ # @!attribute average_view_duration
679
+ # Average view duration in seconds
680
+ #
681
+ # @return [Float, nil]
682
+ optional :average_view_duration, Float, api_name: :averageViewDuration
683
+
684
+ # @!attribute average_view_percentage
685
+ # Average percentage of the video watched
686
+ #
687
+ # @return [Float, nil]
688
+ optional :average_view_percentage, Float, api_name: :averageViewPercentage
689
+
690
+ # @!attribute card_click_rate
691
+ # Card click-through rate
692
+ #
693
+ # @return [Float, nil]
694
+ optional :card_click_rate, Float, api_name: :cardClickRate
695
+
696
+ # @!attribute card_clicks
697
+ # Number of card clicks
698
+ #
699
+ # @return [Float, nil]
700
+ optional :card_clicks, Float, api_name: :cardClicks
701
+
702
+ # @!attribute card_impressions
703
+ # Number of card impressions
704
+ #
705
+ # @return [Float, nil]
706
+ optional :card_impressions, Float, api_name: :cardImpressions
707
+
708
+ # @!attribute card_teaser_click_rate
709
+ # Card teaser click-through rate
710
+ #
711
+ # @return [Float, nil]
712
+ optional :card_teaser_click_rate, Float, api_name: :cardTeaserClickRate
713
+
714
+ # @!attribute card_teaser_clicks
715
+ # Number of card teaser clicks
716
+ #
717
+ # @return [Float, nil]
718
+ optional :card_teaser_clicks, Float, api_name: :cardTeaserClicks
719
+
720
+ # @!attribute card_teaser_impressions
721
+ # Number of card teaser impressions
722
+ #
723
+ # @return [Float, nil]
724
+ optional :card_teaser_impressions, Float, api_name: :cardTeaserImpressions
725
+
726
+ # @!attribute engaged_views
727
+ # Number of engaged views
728
+ #
729
+ # @return [Float, nil]
730
+ optional :engaged_views, Float, api_name: :engagedViews
731
+
732
+ # @!attribute estimated_minutes_watched
733
+ # Estimated minutes watched
734
+ #
735
+ # @return [Float, nil]
736
+ optional :estimated_minutes_watched, Float, api_name: :estimatedMinutesWatched
737
+
738
+ # @!attribute estimated_red_minutes_watched
739
+ # Estimated minutes watched by YouTube Premium (Red) members
740
+ #
741
+ # @return [Float, nil]
742
+ optional :estimated_red_minutes_watched, Float, api_name: :estimatedRedMinutesWatched
743
+
744
+ # @!attribute red_views
745
+ # Number of views from YouTube Premium (Red) members
746
+ #
747
+ # @return [Float, nil]
748
+ optional :red_views, Float, api_name: :redViews
749
+
750
+ # @!attribute shares
751
+ # Number of shares
752
+ #
753
+ # @return [Float, nil]
754
+ optional :shares, Float
755
+
756
+ # @!attribute subscribers_gained
757
+ # Subscribers gained
758
+ #
759
+ # @return [Float, nil]
760
+ optional :subscribers_gained, Float, api_name: :subscribersGained
761
+
762
+ # @!attribute subscribers_lost
763
+ # Subscribers lost
764
+ #
765
+ # @return [Float, nil]
766
+ optional :subscribers_lost, Float, api_name: :subscribersLost
767
+
768
+ # @!attribute videos_added_to_playlists
769
+ # Number of times the video was added to playlists
770
+ #
771
+ # @return [Float, nil]
772
+ optional :videos_added_to_playlists, Float, api_name: :videosAddedToPlaylists
773
+
774
+ # @!attribute videos_removed_from_playlists
775
+ # Number of times the video was removed from playlists
776
+ #
777
+ # @return [Float, nil]
778
+ optional :videos_removed_from_playlists, Float, api_name: :videosRemovedFromPlaylists
779
+
780
+ # @!method initialize(comments:, dislikes:, likes:, views:, annotation_clickable_impressions: nil, annotation_clicks: nil, annotation_click_through_rate: nil, annotation_closable_impressions: nil, annotation_close_rate: nil, annotation_closes: nil, annotation_impressions: nil, average_view_duration: nil, average_view_percentage: nil, card_click_rate: nil, card_clicks: nil, card_impressions: nil, card_teaser_click_rate: nil, card_teaser_clicks: nil, card_teaser_impressions: nil, engaged_views: nil, estimated_minutes_watched: nil, estimated_red_minutes_watched: nil, red_views: nil, shares: nil, subscribers_gained: nil, subscribers_lost: nil, videos_added_to_playlists: nil, videos_removed_from_playlists: nil)
781
+ # @param comments [Float] Number of comments on the video
782
+ #
783
+ # @param dislikes [Float] Number of dislikes on the video
784
+ #
785
+ # @param likes [Float] Number of likes on the video
786
+ #
787
+ # @param views [Float] Number of views on the video
788
+ #
789
+ # @param annotation_clickable_impressions [Float] Number of clickable annotation impressions
790
+ #
791
+ # @param annotation_clicks [Float] Number of annotation clicks
792
+ #
793
+ # @param annotation_click_through_rate [Float] Annotation click-through rate
794
+ #
795
+ # @param annotation_closable_impressions [Float] Number of closable annotation impressions
796
+ #
797
+ # @param annotation_close_rate [Float] Annotation close rate
798
+ #
799
+ # @param annotation_closes [Float] Number of annotation closes
800
+ #
801
+ # @param annotation_impressions [Float] Number of annotation impressions
802
+ #
803
+ # @param average_view_duration [Float] Average view duration in seconds
804
+ #
805
+ # @param average_view_percentage [Float] Average percentage of the video watched
806
+ #
807
+ # @param card_click_rate [Float] Card click-through rate
808
+ #
809
+ # @param card_clicks [Float] Number of card clicks
810
+ #
811
+ # @param card_impressions [Float] Number of card impressions
812
+ #
813
+ # @param card_teaser_click_rate [Float] Card teaser click-through rate
814
+ #
815
+ # @param card_teaser_clicks [Float] Number of card teaser clicks
816
+ #
817
+ # @param card_teaser_impressions [Float] Number of card teaser impressions
818
+ #
819
+ # @param engaged_views [Float] Number of engaged views
820
+ #
821
+ # @param estimated_minutes_watched [Float] Estimated minutes watched
822
+ #
823
+ # @param estimated_red_minutes_watched [Float] Estimated minutes watched by YouTube Premium (Red) members
824
+ #
825
+ # @param red_views [Float] Number of views from YouTube Premium (Red) members
826
+ #
827
+ # @param shares [Float] Number of shares
828
+ #
829
+ # @param subscribers_gained [Float] Subscribers gained
830
+ #
831
+ # @param subscribers_lost [Float] Subscribers lost
832
+ #
833
+ # @param videos_added_to_playlists [Float] Number of times the video was added to playlists
834
+ #
835
+ # @param videos_removed_from_playlists [Float] Number of times the video was removed from playlists
836
+ end
837
+
838
+ # @!method self.variants
839
+ # @return [Array(PostForMe::Models::PlatformPost::Metrics::TikTokBusinessMetricsDto, PostForMe::Models::PlatformPost::Metrics::TikTokPostMetricsDto, PostForMe::Models::PlatformPost::Metrics::InstagramPostMetricsDto, PostForMe::Models::PlatformPost::Metrics::YouTubePostMetricsDto)]
840
+ end
841
+ end
842
+ end
843
+ end