chunkify-analytics-sdk 0.9.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.
- chunkify_analytics/__init__.py +102 -0
- chunkify_analytics/_base_client.py +2153 -0
- chunkify_analytics/_client.py +1262 -0
- chunkify_analytics/_compat.py +226 -0
- chunkify_analytics/_constants.py +14 -0
- chunkify_analytics/_exceptions.py +108 -0
- chunkify_analytics/_files.py +173 -0
- chunkify_analytics/_models.py +964 -0
- chunkify_analytics/_qs.py +149 -0
- chunkify_analytics/_resource.py +43 -0
- chunkify_analytics/_response.py +835 -0
- chunkify_analytics/_streaming.py +338 -0
- chunkify_analytics/_types.py +274 -0
- chunkify_analytics/_utils/__init__.py +64 -0
- chunkify_analytics/_utils/_compat.py +45 -0
- chunkify_analytics/_utils/_datetime_parse.py +136 -0
- chunkify_analytics/_utils/_json.py +35 -0
- chunkify_analytics/_utils/_logs.py +25 -0
- chunkify_analytics/_utils/_path.py +127 -0
- chunkify_analytics/_utils/_proxy.py +65 -0
- chunkify_analytics/_utils/_reflection.py +42 -0
- chunkify_analytics/_utils/_resources_proxy.py +24 -0
- chunkify_analytics/_utils/_streams.py +12 -0
- chunkify_analytics/_utils/_sync.py +58 -0
- chunkify_analytics/_utils/_transform.py +457 -0
- chunkify_analytics/_utils/_typing.py +156 -0
- chunkify_analytics/_utils/_utils.py +433 -0
- chunkify_analytics/_version.py +4 -0
- chunkify_analytics/lib/.keep +4 -0
- chunkify_analytics/pagination.py +221 -0
- chunkify_analytics/py.typed +0 -0
- chunkify_analytics/resources/__init__.py +243 -0
- chunkify_analytics/resources/admin/__init__.py +33 -0
- chunkify_analytics/resources/admin/admin.py +253 -0
- chunkify_analytics/resources/admin/keys.py +283 -0
- chunkify_analytics/resources/dimensions.py +436 -0
- chunkify_analytics/resources/engagement.py +479 -0
- chunkify_analytics/resources/errors.py +400 -0
- chunkify_analytics/resources/events.py +562 -0
- chunkify_analytics/resources/exports.py +584 -0
- chunkify_analytics/resources/health.py +159 -0
- chunkify_analytics/resources/playback_rates.py +391 -0
- chunkify_analytics/resources/project/__init__.py +33 -0
- chunkify_analytics/resources/project/keys.py +379 -0
- chunkify_analytics/resources/project/project.py +322 -0
- chunkify_analytics/resources/quality.py +471 -0
- chunkify_analytics/resources/renditions.py +391 -0
- chunkify_analytics/resources/retention.py +377 -0
- chunkify_analytics/resources/subtitles.py +389 -0
- chunkify_analytics/resources/summary.py +469 -0
- chunkify_analytics/resources/timeseries.py +399 -0
- chunkify_analytics/resources/videos.py +424 -0
- chunkify_analytics/resources/views.py +579 -0
- chunkify_analytics/types/__init__.py +145 -0
- chunkify_analytics/types/admin/__init__.py +3 -0
- chunkify_analytics/types/admin_create_project_params.py +25 -0
- chunkify_analytics/types/analytics_event.py +32 -0
- chunkify_analytics/types/analytics_event_param.py +30 -0
- chunkify_analytics/types/created_project.py +37 -0
- chunkify_analytics/types/created_project_key.py +34 -0
- chunkify_analytics/types/deleted_project.py +18 -0
- chunkify_analytics/types/dimension_list_values_params.py +124 -0
- chunkify_analytics/types/dimension_values.py +42 -0
- chunkify_analytics/types/engagement.py +60 -0
- chunkify_analytics/types/engagement_breakdown_page.py +44 -0
- chunkify_analytics/types/engagement_response.py +11 -0
- chunkify_analytics/types/engagement_retrieve_params.py +158 -0
- chunkify_analytics/types/engagement_timeseries.py +28 -0
- chunkify_analytics/types/engagement_timeseries_bucket.py +63 -0
- chunkify_analytics/types/error_group.py +17 -0
- chunkify_analytics/types/error_list_params.py +124 -0
- chunkify_analytics/types/error_page.py +14 -0
- chunkify_analytics/types/event_ingest_params.py +19 -0
- chunkify_analytics/types/event_ingest_response.py +11 -0
- chunkify_analytics/types/event_list_params.py +146 -0
- chunkify_analytics/types/event_page.py +18 -0
- chunkify_analytics/types/export.py +18 -0
- chunkify_analytics/types/export_columns.py +12 -0
- chunkify_analytics/types/export_create_params.py +40 -0
- chunkify_analytics/types/export_download_response.py +7 -0
- chunkify_analytics/types/export_list_columns_params.py +69 -0
- chunkify_analytics/types/export_query_param.py +141 -0
- chunkify_analytics/types/health.py +11 -0
- chunkify_analytics/types/metrics.py +13 -0
- chunkify_analytics/types/metrics_breakdown_page.py +40 -0
- chunkify_analytics/types/metrics_response.py +11 -0
- chunkify_analytics/types/native_created.py +13 -0
- chunkify_analytics/types/native_duplicate.py +13 -0
- chunkify_analytics/types/playback_error.py +180 -0
- chunkify_analytics/types/playback_error_param.py +182 -0
- chunkify_analytics/types/playback_rate_changed.py +150 -0
- chunkify_analytics/types/playback_rate_changed_param.py +152 -0
- chunkify_analytics/types/playback_rate_metric.py +21 -0
- chunkify_analytics/types/playback_rate_report.py +31 -0
- chunkify_analytics/types/playback_rate_retrieve_params.py +117 -0
- chunkify_analytics/types/playback_state_changed.py +150 -0
- chunkify_analytics/types/playback_state_changed_param.py +156 -0
- chunkify_analytics/types/project/__init__.py +6 -0
- chunkify_analytics/types/project/key_create_params.py +21 -0
- chunkify_analytics/types/project/project.py +35 -0
- chunkify_analytics/types/project_key.py +21 -0
- chunkify_analytics/types/project_keys.py +14 -0
- chunkify_analytics/types/project_update_params.py +25 -0
- chunkify_analytics/types/quality.py +117 -0
- chunkify_analytics/types/quality_breakdown_page.py +44 -0
- chunkify_analytics/types/quality_response.py +11 -0
- chunkify_analytics/types/quality_retrieve_params.py +158 -0
- chunkify_analytics/types/quality_timeseries.py +28 -0
- chunkify_analytics/types/quality_timeseries_bucket.py +120 -0
- chunkify_analytics/types/rendition_changed.py +156 -0
- chunkify_analytics/types/rendition_changed_param.py +158 -0
- chunkify_analytics/types/rendition_metric.py +40 -0
- chunkify_analytics/types/rendition_report.py +43 -0
- chunkify_analytics/types/rendition_retrieve_params.py +117 -0
- chunkify_analytics/types/retention_bucket.py +22 -0
- chunkify_analytics/types/retention_report.py +33 -0
- chunkify_analytics/types/retention_retrieve_params.py +110 -0
- chunkify_analytics/types/rotated_project_key.py +29 -0
- chunkify_analytics/types/seek_completed.py +166 -0
- chunkify_analytics/types/seek_completed_param.py +168 -0
- chunkify_analytics/types/shared/__init__.py +24 -0
- chunkify_analytics/types/shared/browser_context.py +62 -0
- chunkify_analytics/types/shared/custom_dimensions.py +8 -0
- chunkify_analytics/types/shared/event_context.py +161 -0
- chunkify_analytics/types/shared/event_envelope.py +152 -0
- chunkify_analytics/types/shared/metric_count_ratio.py +18 -0
- chunkify_analytics/types/shared/otlp_any_value.py +56 -0
- chunkify_analytics/types/shared/otlp_attribute.py +24 -0
- chunkify_analytics/types/shared/otlp_attribute_value.py +136 -0
- chunkify_analytics/types/shared/otlp_context_attribute.py +22 -0
- chunkify_analytics/types/shared/otlp_log_record.py +48 -0
- chunkify_analytics/types/shared/otlp_resource.py +20 -0
- chunkify_analytics/types/shared/otlp_scope.py +24 -0
- chunkify_analytics/types/shared/playback_rate_playing_time.py +12 -0
- chunkify_analytics/types/shared/playback_score.py +28 -0
- chunkify_analytics/types/shared/played_range.py +13 -0
- chunkify_analytics/types/shared/progress_reached.py +39 -0
- chunkify_analytics/types/shared/rendition_playing_time.py +21 -0
- chunkify_analytics/types/shared/startup_outcomes.py +39 -0
- chunkify_analytics/types/shared/stored_otlp_context.py +50 -0
- chunkify_analytics/types/shared/subtitle_playing_time.py +14 -0
- chunkify_analytics/types/shared/view_metrics.py +100 -0
- chunkify_analytics/types/shared/watch_time_distribution.py +41 -0
- chunkify_analytics/types/shared_params/__init__.py +8 -0
- chunkify_analytics/types/shared_params/browser_context.py +62 -0
- chunkify_analytics/types/shared_params/custom_dimensions.py +10 -0
- chunkify_analytics/types/shared_params/playback_rate_playing_time.py +14 -0
- chunkify_analytics/types/shared_params/played_range.py +15 -0
- chunkify_analytics/types/shared_params/rendition_playing_time.py +22 -0
- chunkify_analytics/types/shared_params/subtitle_playing_time.py +15 -0
- chunkify_analytics/types/stored_event.py +44 -0
- chunkify_analytics/types/subtitle_changed.py +150 -0
- chunkify_analytics/types/subtitle_changed_param.py +152 -0
- chunkify_analytics/types/subtitle_metric.py +26 -0
- chunkify_analytics/types/subtitle_report.py +31 -0
- chunkify_analytics/types/subtitle_retrieve_params.py +117 -0
- chunkify_analytics/types/summary_retrieve_params.py +158 -0
- chunkify_analytics/types/time_bucket.py +22 -0
- chunkify_analytics/types/timeseries.py +28 -0
- chunkify_analytics/types/timeseries_response.py +12 -0
- chunkify_analytics/types/timesery_retrieve_params.py +115 -0
- chunkify_analytics/types/video_list_params.py +140 -0
- chunkify_analytics/types/video_metrics.py +23 -0
- chunkify_analytics/types/video_page.py +14 -0
- chunkify_analytics/types/view.py +43 -0
- chunkify_analytics/types/view_detail.py +21 -0
- chunkify_analytics/types/view_ended.py +180 -0
- chunkify_analytics/types/view_ended_param.py +182 -0
- chunkify_analytics/types/view_list_params.py +152 -0
- chunkify_analytics/types/view_page.py +14 -0
- chunkify_analytics/types/view_retrieve_params.py +23 -0
- chunkify_analytics/types/view_snapshot.py +180 -0
- chunkify_analytics/types/view_snapshot_param.py +182 -0
- chunkify_analytics/types/view_started.py +192 -0
- chunkify_analytics/types/view_started_param.py +194 -0
- chunkify_analytics_sdk-0.9.0.dist-info/METADATA +487 -0
- chunkify_analytics_sdk-0.9.0.dist-info/RECORD +179 -0
- chunkify_analytics_sdk-0.9.0.dist-info/WHEEL +4 -0
- chunkify_analytics_sdk-0.9.0.dist-info/licenses/LICENSE +201 -0
|
@@ -0,0 +1,158 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
|
|
5
|
+
from typing import Union
|
|
6
|
+
from datetime import datetime
|
|
7
|
+
from typing_extensions import Literal, Annotated, TypedDict
|
|
8
|
+
|
|
9
|
+
from .._utils import PropertyInfo
|
|
10
|
+
|
|
11
|
+
__all__ = ["EngagementRetrieveParams"]
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
class EngagementRetrieveParams(TypedDict, total=False):
|
|
15
|
+
browser_name: str
|
|
16
|
+
"""Exact browser name, such as Chrome. Missing values do not match."""
|
|
17
|
+
|
|
18
|
+
city: str
|
|
19
|
+
"""
|
|
20
|
+
Exact, case-sensitive city name from the local lookup, with 1 to 256 Unicode
|
|
21
|
+
characters. Use country alongside city to distinguish places with the same name.
|
|
22
|
+
Missing locations do not match.
|
|
23
|
+
"""
|
|
24
|
+
|
|
25
|
+
continent: Literal["AF", "AN", "AS", "EU", "NA", "OC", "SA"]
|
|
26
|
+
"""Exact continent code from the local lookup. Missing locations do not match."""
|
|
27
|
+
|
|
28
|
+
country: str
|
|
29
|
+
"""Exact uppercase ISO 3166-1 alpha-2 country code, such as GB.
|
|
30
|
+
|
|
31
|
+
Missing locations do not match.
|
|
32
|
+
"""
|
|
33
|
+
|
|
34
|
+
cursor: str
|
|
35
|
+
"""Use next_cursor from the previous page.
|
|
36
|
+
|
|
37
|
+
Keep the same filters, sort_by and order. Video cursors from earlier versions
|
|
38
|
+
are invalid; start a new pagination sequence after upgrading.
|
|
39
|
+
"""
|
|
40
|
+
|
|
41
|
+
device_type: Literal["desktop", "mobile", "tablet", "unknown"]
|
|
42
|
+
"""Exact device class. unknown matches an explicit unknown value."""
|
|
43
|
+
|
|
44
|
+
from_: Annotated[Union[str, datetime], PropertyInfo(alias="from", format="iso8601")]
|
|
45
|
+
"""Inclusive RFC3339 occurrence-time lower bound, with timezone.
|
|
46
|
+
|
|
47
|
+
Summary/video queries apply it to the selected view_started event. Must be
|
|
48
|
+
before to.
|
|
49
|
+
"""
|
|
50
|
+
|
|
51
|
+
group_by: Union[
|
|
52
|
+
Literal[
|
|
53
|
+
"browser_name",
|
|
54
|
+
"os_name",
|
|
55
|
+
"device_type",
|
|
56
|
+
"continent",
|
|
57
|
+
"country",
|
|
58
|
+
"city",
|
|
59
|
+
"page_origin",
|
|
60
|
+
"page_path",
|
|
61
|
+
"subtitle_language",
|
|
62
|
+
"playback_rate",
|
|
63
|
+
"video_title",
|
|
64
|
+
"user_id",
|
|
65
|
+
],
|
|
66
|
+
str,
|
|
67
|
+
]
|
|
68
|
+
"""Optional on summary, quality and engagement.
|
|
69
|
+
|
|
70
|
+
Group views by this field on their first retained start. Missing, null and
|
|
71
|
+
nonstring context forms a null group; the literal device type unknown stays
|
|
72
|
+
separate. Groups sort by views descending, then value ascending with null first
|
|
73
|
+
for ties. Pagination is available only with group_by. Location uses the first
|
|
74
|
+
retained start too. City groups use the stored name; filter by country to avoid
|
|
75
|
+
combining names shared by different countries. Page groups use the first
|
|
76
|
+
retained start even if playback continues after navigation. Filter by
|
|
77
|
+
page_origin when grouping page_path to distinguish identical paths on different
|
|
78
|
+
sites. video_title groups by the title on each view's first retained start, so a
|
|
79
|
+
renamed video counts each view under the title it started with. user_id groups
|
|
80
|
+
by the user ID on each view's first retained start. Use custom.<key>, such as
|
|
81
|
+
custom.plan, to group by a custom dimension; views without the key form the null
|
|
82
|
+
group.
|
|
83
|
+
"""
|
|
84
|
+
|
|
85
|
+
limit: int
|
|
86
|
+
"""Maximum rows on this page.
|
|
87
|
+
|
|
88
|
+
Events and videos always support pagination; summary, quality and engagement
|
|
89
|
+
support it only with group_by.
|
|
90
|
+
"""
|
|
91
|
+
|
|
92
|
+
os_name: str
|
|
93
|
+
"""Exact operating-system name, such as macOS. Missing values do not match."""
|
|
94
|
+
|
|
95
|
+
page_origin: str
|
|
96
|
+
"""
|
|
97
|
+
Exact, case-sensitive page origin captured by the player, such as
|
|
98
|
+
https://example.com. Metrics use the first retained view start; raw events use
|
|
99
|
+
each event context. Missing values do not match.
|
|
100
|
+
"""
|
|
101
|
+
|
|
102
|
+
page_path: str
|
|
103
|
+
"""Exact, case-sensitive page path captured by the player, such as /watch/video.
|
|
104
|
+
|
|
105
|
+
Filter by page_origin as well to distinguish identical paths on different sites.
|
|
106
|
+
Metrics use the first retained view start; raw events use each event context.
|
|
107
|
+
Missing values do not match.
|
|
108
|
+
"""
|
|
109
|
+
|
|
110
|
+
playback_rate: str
|
|
111
|
+
"""
|
|
112
|
+
Playback rate from 0.01 to 16 with at most two decimals, such as 1, 1.5 or 2;
|
|
113
|
+
2.0 and 2 are the same rate. Metrics use the rate on the first retained view
|
|
114
|
+
start; raw events use each event's value.
|
|
115
|
+
"""
|
|
116
|
+
|
|
117
|
+
subtitle_language: str
|
|
118
|
+
"""
|
|
119
|
+
Exact, case-sensitive, non-blank subtitle language tag, such as fr or en-US; und
|
|
120
|
+
for a subtitles track without a language. Metrics use the language showing on
|
|
121
|
+
the first retained view start; raw events use each event's value. Views without
|
|
122
|
+
subtitles at start do not match.
|
|
123
|
+
"""
|
|
124
|
+
|
|
125
|
+
to: Annotated[Union[str, datetime], PropertyInfo(format="iso8601")]
|
|
126
|
+
"""Exclusive RFC3339 occurrence-time upper bound, with timezone.
|
|
127
|
+
|
|
128
|
+
Summary/video queries apply it to the selected view_started event.
|
|
129
|
+
"""
|
|
130
|
+
|
|
131
|
+
user_id: str
|
|
132
|
+
"""Exact integrator-supplied user ID.
|
|
133
|
+
|
|
134
|
+
Selects views by their start event; event lists match each event's own value.
|
|
135
|
+
Missing/null user IDs do not match. Reports with this filter read one stored row
|
|
136
|
+
per view.
|
|
137
|
+
"""
|
|
138
|
+
|
|
139
|
+
video_id: str
|
|
140
|
+
"""Exact video ID; must not be blank. Combined with all other filters using AND."""
|
|
141
|
+
|
|
142
|
+
video_title: str
|
|
143
|
+
"""Exact, case-sensitive video title.
|
|
144
|
+
|
|
145
|
+
Selects views by the title on their first retained start; event lists match each
|
|
146
|
+
event's own value. Views without a title do not match. Reports with this filter
|
|
147
|
+
read one stored row per view.
|
|
148
|
+
"""
|
|
149
|
+
|
|
150
|
+
view_id: str
|
|
151
|
+
"""Filter one playback attempt by view ID. Metrics use its first retained start."""
|
|
152
|
+
|
|
153
|
+
viewer_id: str
|
|
154
|
+
"""Exact viewer ID.
|
|
155
|
+
|
|
156
|
+
The Chunkify player SDK generates one per browser; missing/null viewer IDs do
|
|
157
|
+
not match.
|
|
158
|
+
"""
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from typing import List
|
|
4
|
+
from datetime import datetime
|
|
5
|
+
from typing_extensions import Literal
|
|
6
|
+
|
|
7
|
+
from pydantic import Field as FieldInfo
|
|
8
|
+
|
|
9
|
+
from .._models import BaseModel
|
|
10
|
+
from .engagement_timeseries_bucket import EngagementTimeseriesBucket
|
|
11
|
+
|
|
12
|
+
__all__ = ["EngagementTimeseries"]
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
class EngagementTimeseries(BaseModel):
|
|
16
|
+
buckets: List[EngagementTimeseriesBucket]
|
|
17
|
+
|
|
18
|
+
from_: datetime = FieldInfo(alias="from")
|
|
19
|
+
"""Inclusive query bound normalized to UTC milliseconds."""
|
|
20
|
+
|
|
21
|
+
interval: Literal["hour", "day"]
|
|
22
|
+
|
|
23
|
+
kind: Literal["engagement"]
|
|
24
|
+
|
|
25
|
+
timezone: Literal["UTC"]
|
|
26
|
+
|
|
27
|
+
to: datetime
|
|
28
|
+
"""Exclusive query bound normalized to UTC milliseconds."""
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from typing import Optional
|
|
4
|
+
from datetime import datetime
|
|
5
|
+
|
|
6
|
+
from .._models import BaseModel
|
|
7
|
+
from .shared.progress_reached import ProgressReached
|
|
8
|
+
from .shared.watch_time_distribution import WatchTimeDistribution
|
|
9
|
+
|
|
10
|
+
__all__ = ["EngagementTimeseriesBucket"]
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
class EngagementTimeseriesBucket(BaseModel):
|
|
14
|
+
"""Observed watch time and end-of-media for the same start cohort as summary.
|
|
15
|
+
|
|
16
|
+
Missing delivery can undercount both.
|
|
17
|
+
"""
|
|
18
|
+
|
|
19
|
+
average_playing_time_ms: Optional[float] = None
|
|
20
|
+
"""Total playing time divided by all selected attempts.
|
|
21
|
+
|
|
22
|
+
Null with no views; zero when views exist with no measured time.
|
|
23
|
+
"""
|
|
24
|
+
|
|
25
|
+
bucket_start: datetime
|
|
26
|
+
|
|
27
|
+
progress_reached: ProgressReached
|
|
28
|
+
"""Furthest progress on the selected final event or latest snapshot.
|
|
29
|
+
|
|
30
|
+
Only views with a positive known media duration and a progress ratio in [0,1]
|
|
31
|
+
are samples. Each milestone ratio uses sample_views. Seeking can count; this is
|
|
32
|
+
not watched coverage or audience retention.
|
|
33
|
+
"""
|
|
34
|
+
|
|
35
|
+
reached_end_ratio: Optional[float] = None
|
|
36
|
+
"""Reached-end views divided by all selected attempts.
|
|
37
|
+
|
|
38
|
+
Null without views. Multiply by 100 for percent. Does not imply the whole video
|
|
39
|
+
was watched.
|
|
40
|
+
"""
|
|
41
|
+
|
|
42
|
+
reached_end_views: int
|
|
43
|
+
"""Views whose winning final event has reason=ended.
|
|
44
|
+
|
|
45
|
+
Counts each selected view at most once.
|
|
46
|
+
"""
|
|
47
|
+
|
|
48
|
+
total_playing_time_ms: float
|
|
49
|
+
"""Cumulative playing time summed once per selected view, as in summary."""
|
|
50
|
+
|
|
51
|
+
views: int
|
|
52
|
+
"""
|
|
53
|
+
Selected playback attempts with a retained start, including failed, ongoing and
|
|
54
|
+
start-only attempts.
|
|
55
|
+
"""
|
|
56
|
+
|
|
57
|
+
watch_time_ms: WatchTimeDistribution
|
|
58
|
+
"""
|
|
59
|
+
Playing time in milliseconds from one selected final event or latest snapshot
|
|
60
|
+
per view. Measured zero is included; missing measurements are excluded.
|
|
61
|
+
Percentiles use linear interpolation and are null without samples. This sample
|
|
62
|
+
denominator differs from average_playing_time_ms, which uses all attempts.
|
|
63
|
+
"""
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from typing import Union, Optional
|
|
4
|
+
|
|
5
|
+
from .._models import BaseModel
|
|
6
|
+
|
|
7
|
+
__all__ = ["ErrorGroup"]
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
class ErrorGroup(BaseModel):
|
|
11
|
+
affected_views: int
|
|
12
|
+
|
|
13
|
+
error_code: Union[str, float, None] = None
|
|
14
|
+
|
|
15
|
+
error_events: int
|
|
16
|
+
|
|
17
|
+
fatal: Optional[bool] = None
|
|
@@ -0,0 +1,124 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
|
|
5
|
+
from typing import Union
|
|
6
|
+
from datetime import datetime
|
|
7
|
+
from typing_extensions import Literal, Annotated, TypedDict
|
|
8
|
+
|
|
9
|
+
from .._utils import PropertyInfo
|
|
10
|
+
|
|
11
|
+
__all__ = ["ErrorListParams"]
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
class ErrorListParams(TypedDict, total=False):
|
|
15
|
+
browser_name: str
|
|
16
|
+
"""Exact browser name, such as Chrome. Missing values do not match."""
|
|
17
|
+
|
|
18
|
+
city: str
|
|
19
|
+
"""
|
|
20
|
+
Exact, case-sensitive city name from the local lookup, with 1 to 256 Unicode
|
|
21
|
+
characters. Use country alongside city to distinguish places with the same name.
|
|
22
|
+
Missing locations do not match.
|
|
23
|
+
"""
|
|
24
|
+
|
|
25
|
+
continent: Literal["AF", "AN", "AS", "EU", "NA", "OC", "SA"]
|
|
26
|
+
"""Exact continent code from the local lookup. Missing locations do not match."""
|
|
27
|
+
|
|
28
|
+
country: str
|
|
29
|
+
"""Exact uppercase ISO 3166-1 alpha-2 country code, such as GB.
|
|
30
|
+
|
|
31
|
+
Missing locations do not match.
|
|
32
|
+
"""
|
|
33
|
+
|
|
34
|
+
cursor: str
|
|
35
|
+
"""Use next_cursor from the previous page.
|
|
36
|
+
|
|
37
|
+
Keep the same filters, sort_by and order. Video cursors from earlier versions
|
|
38
|
+
are invalid; start a new pagination sequence after upgrading.
|
|
39
|
+
"""
|
|
40
|
+
|
|
41
|
+
device_type: Literal["desktop", "mobile", "tablet", "unknown"]
|
|
42
|
+
"""Exact device class. unknown matches an explicit unknown value."""
|
|
43
|
+
|
|
44
|
+
from_: Annotated[Union[str, datetime], PropertyInfo(alias="from", format="iso8601")]
|
|
45
|
+
"""Inclusive RFC3339 occurrence-time lower bound, with timezone.
|
|
46
|
+
|
|
47
|
+
Summary/video queries apply it to the selected view_started event. Must be
|
|
48
|
+
before to.
|
|
49
|
+
"""
|
|
50
|
+
|
|
51
|
+
limit: int
|
|
52
|
+
"""Maximum rows on this page.
|
|
53
|
+
|
|
54
|
+
Events and videos always support pagination; summary, quality and engagement
|
|
55
|
+
support it only with group_by.
|
|
56
|
+
"""
|
|
57
|
+
|
|
58
|
+
os_name: str
|
|
59
|
+
"""Exact operating-system name, such as macOS. Missing values do not match."""
|
|
60
|
+
|
|
61
|
+
page_origin: str
|
|
62
|
+
"""
|
|
63
|
+
Exact, case-sensitive page origin captured by the player, such as
|
|
64
|
+
https://example.com. Metrics use the first retained view start; raw events use
|
|
65
|
+
each event context. Missing values do not match.
|
|
66
|
+
"""
|
|
67
|
+
|
|
68
|
+
page_path: str
|
|
69
|
+
"""Exact, case-sensitive page path captured by the player, such as /watch/video.
|
|
70
|
+
|
|
71
|
+
Filter by page_origin as well to distinguish identical paths on different sites.
|
|
72
|
+
Metrics use the first retained view start; raw events use each event context.
|
|
73
|
+
Missing values do not match.
|
|
74
|
+
"""
|
|
75
|
+
|
|
76
|
+
playback_rate: str
|
|
77
|
+
"""
|
|
78
|
+
Playback rate from 0.01 to 16 with at most two decimals, such as 1, 1.5 or 2;
|
|
79
|
+
2.0 and 2 are the same rate. Metrics use the rate on the first retained view
|
|
80
|
+
start; raw events use each event's value.
|
|
81
|
+
"""
|
|
82
|
+
|
|
83
|
+
subtitle_language: str
|
|
84
|
+
"""
|
|
85
|
+
Exact, case-sensitive, non-blank subtitle language tag, such as fr or en-US; und
|
|
86
|
+
for a subtitles track without a language. Metrics use the language showing on
|
|
87
|
+
the first retained view start; raw events use each event's value. Views without
|
|
88
|
+
subtitles at start do not match.
|
|
89
|
+
"""
|
|
90
|
+
|
|
91
|
+
to: Annotated[Union[str, datetime], PropertyInfo(format="iso8601")]
|
|
92
|
+
"""Exclusive RFC3339 occurrence-time upper bound, with timezone.
|
|
93
|
+
|
|
94
|
+
Summary/video queries apply it to the selected view_started event.
|
|
95
|
+
"""
|
|
96
|
+
|
|
97
|
+
user_id: str
|
|
98
|
+
"""Exact integrator-supplied user ID.
|
|
99
|
+
|
|
100
|
+
Selects views by their start event; event lists match each event's own value.
|
|
101
|
+
Missing/null user IDs do not match. Reports with this filter read one stored row
|
|
102
|
+
per view.
|
|
103
|
+
"""
|
|
104
|
+
|
|
105
|
+
video_id: str
|
|
106
|
+
"""Exact video ID; must not be blank. Combined with all other filters using AND."""
|
|
107
|
+
|
|
108
|
+
video_title: str
|
|
109
|
+
"""Exact, case-sensitive video title.
|
|
110
|
+
|
|
111
|
+
Selects views by the title on their first retained start; event lists match each
|
|
112
|
+
event's own value. Views without a title do not match. Reports with this filter
|
|
113
|
+
read one stored row per view.
|
|
114
|
+
"""
|
|
115
|
+
|
|
116
|
+
view_id: str
|
|
117
|
+
"""Filter one playback attempt by view ID. Metrics use its first retained start."""
|
|
118
|
+
|
|
119
|
+
viewer_id: str
|
|
120
|
+
"""Exact viewer ID.
|
|
121
|
+
|
|
122
|
+
The Chunkify player SDK generates one per browser; missing/null viewer IDs do
|
|
123
|
+
not match.
|
|
124
|
+
"""
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from typing import List, Optional
|
|
4
|
+
|
|
5
|
+
from .._models import BaseModel
|
|
6
|
+
from .error_group import ErrorGroup
|
|
7
|
+
|
|
8
|
+
__all__ = ["ErrorPage"]
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
class ErrorPage(BaseModel):
|
|
12
|
+
errors: List[ErrorGroup]
|
|
13
|
+
|
|
14
|
+
next_cursor: Optional[str] = None
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
|
|
5
|
+
from typing_extensions import Literal, Required, Annotated, TypedDict
|
|
6
|
+
|
|
7
|
+
from .._utils import PropertyInfo
|
|
8
|
+
from .analytics_event_param import AnalyticsEventParam
|
|
9
|
+
|
|
10
|
+
__all__ = ["EventIngestParams"]
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
class EventIngestParams(TypedDict, total=False):
|
|
14
|
+
event: Required[AnalyticsEventParam]
|
|
15
|
+
"""A schema version 1 playback event. Extra properties are preserved."""
|
|
16
|
+
|
|
17
|
+
content_encoding: Annotated[Literal["identity"], PropertyInfo(alias="Content-Encoding")]
|
|
18
|
+
|
|
19
|
+
origin: Annotated[str, PropertyInfo(alias="Origin")]
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from typing import Union
|
|
4
|
+
from typing_extensions import TypeAlias
|
|
5
|
+
|
|
6
|
+
from .native_created import NativeCreated
|
|
7
|
+
from .native_duplicate import NativeDuplicate
|
|
8
|
+
|
|
9
|
+
__all__ = ["EventIngestResponse"]
|
|
10
|
+
|
|
11
|
+
EventIngestResponse: TypeAlias = Union[NativeCreated, NativeDuplicate]
|
|
@@ -0,0 +1,146 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
|
|
5
|
+
from typing import Union
|
|
6
|
+
from datetime import datetime
|
|
7
|
+
from typing_extensions import Literal, Annotated, TypedDict
|
|
8
|
+
|
|
9
|
+
from .._utils import PropertyInfo
|
|
10
|
+
|
|
11
|
+
__all__ = ["EventListParams"]
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
class EventListParams(TypedDict, total=False):
|
|
15
|
+
browser_name: str
|
|
16
|
+
"""Exact browser name, such as Chrome. Missing values do not match."""
|
|
17
|
+
|
|
18
|
+
city: str
|
|
19
|
+
"""
|
|
20
|
+
Exact, case-sensitive city name from the local lookup, with 1 to 256 Unicode
|
|
21
|
+
characters. Use country alongside city to distinguish places with the same name.
|
|
22
|
+
Missing locations do not match.
|
|
23
|
+
"""
|
|
24
|
+
|
|
25
|
+
continent: Literal["AF", "AN", "AS", "EU", "NA", "OC", "SA"]
|
|
26
|
+
"""Exact continent code from the local lookup. Missing locations do not match."""
|
|
27
|
+
|
|
28
|
+
country: str
|
|
29
|
+
"""Exact uppercase ISO 3166-1 alpha-2 country code, such as GB.
|
|
30
|
+
|
|
31
|
+
Missing locations do not match.
|
|
32
|
+
"""
|
|
33
|
+
|
|
34
|
+
cursor: str
|
|
35
|
+
"""Use next_cursor from the previous page.
|
|
36
|
+
|
|
37
|
+
Keep the same filters, sort_by and order. Video cursors from earlier versions
|
|
38
|
+
are invalid; start a new pagination sequence after upgrading.
|
|
39
|
+
"""
|
|
40
|
+
|
|
41
|
+
device_type: Literal["desktop", "mobile", "tablet", "unknown"]
|
|
42
|
+
"""Exact device class. unknown matches an explicit unknown value."""
|
|
43
|
+
|
|
44
|
+
event_name: Literal[
|
|
45
|
+
"chunkify.video.view_started",
|
|
46
|
+
"chunkify.video.view_snapshot",
|
|
47
|
+
"chunkify.video.playback_error",
|
|
48
|
+
"chunkify.video.view_ended",
|
|
49
|
+
"chunkify.video.playback_state_changed",
|
|
50
|
+
"chunkify.video.rendition_changed",
|
|
51
|
+
"chunkify.video.seek_completed",
|
|
52
|
+
"chunkify.video.subtitle_changed",
|
|
53
|
+
"chunkify.video.playback_rate_changed",
|
|
54
|
+
]
|
|
55
|
+
"""Raw-event queries only. Summaries and videos reject this parameter."""
|
|
56
|
+
|
|
57
|
+
from_: Annotated[Union[str, datetime], PropertyInfo(alias="from", format="iso8601")]
|
|
58
|
+
"""Inclusive RFC3339 occurrence-time lower bound, with timezone.
|
|
59
|
+
|
|
60
|
+
Summary/video queries apply it to the selected view_started event. Must be
|
|
61
|
+
before to.
|
|
62
|
+
"""
|
|
63
|
+
|
|
64
|
+
limit: int
|
|
65
|
+
"""Maximum rows on this page.
|
|
66
|
+
|
|
67
|
+
Events and videos always support pagination; summary, quality and engagement
|
|
68
|
+
support it only with group_by.
|
|
69
|
+
"""
|
|
70
|
+
|
|
71
|
+
order: Literal["asc", "desc"]
|
|
72
|
+
"""Sort direction.
|
|
73
|
+
|
|
74
|
+
Events and videos default to asc; views default to desc. Events sort by
|
|
75
|
+
ingestion sequence. Videos and views sort by sort_by with missing values last.
|
|
76
|
+
View ties use view_id in the requested direction; video metric ties use video_id
|
|
77
|
+
ascending.
|
|
78
|
+
"""
|
|
79
|
+
|
|
80
|
+
os_name: str
|
|
81
|
+
"""Exact operating-system name, such as macOS. Missing values do not match."""
|
|
82
|
+
|
|
83
|
+
page_origin: str
|
|
84
|
+
"""
|
|
85
|
+
Exact, case-sensitive page origin captured by the player, such as
|
|
86
|
+
https://example.com. Metrics use the first retained view start; raw events use
|
|
87
|
+
each event context. Missing values do not match.
|
|
88
|
+
"""
|
|
89
|
+
|
|
90
|
+
page_path: str
|
|
91
|
+
"""Exact, case-sensitive page path captured by the player, such as /watch/video.
|
|
92
|
+
|
|
93
|
+
Filter by page_origin as well to distinguish identical paths on different sites.
|
|
94
|
+
Metrics use the first retained view start; raw events use each event context.
|
|
95
|
+
Missing values do not match.
|
|
96
|
+
"""
|
|
97
|
+
|
|
98
|
+
playback_rate: str
|
|
99
|
+
"""
|
|
100
|
+
Playback rate from 0.01 to 16 with at most two decimals, such as 1, 1.5 or 2;
|
|
101
|
+
2.0 and 2 are the same rate. Metrics use the rate on the first retained view
|
|
102
|
+
start; raw events use each event's value.
|
|
103
|
+
"""
|
|
104
|
+
|
|
105
|
+
subtitle_language: str
|
|
106
|
+
"""
|
|
107
|
+
Exact, case-sensitive, non-blank subtitle language tag, such as fr or en-US; und
|
|
108
|
+
for a subtitles track without a language. Metrics use the language showing on
|
|
109
|
+
the first retained view start; raw events use each event's value. Views without
|
|
110
|
+
subtitles at start do not match.
|
|
111
|
+
"""
|
|
112
|
+
|
|
113
|
+
to: Annotated[Union[str, datetime], PropertyInfo(format="iso8601")]
|
|
114
|
+
"""Exclusive RFC3339 occurrence-time upper bound, with timezone.
|
|
115
|
+
|
|
116
|
+
Summary/video queries apply it to the selected view_started event.
|
|
117
|
+
"""
|
|
118
|
+
|
|
119
|
+
user_id: str
|
|
120
|
+
"""Exact integrator-supplied user ID.
|
|
121
|
+
|
|
122
|
+
Selects views by their start event; event lists match each event's own value.
|
|
123
|
+
Missing/null user IDs do not match. Reports with this filter read one stored row
|
|
124
|
+
per view.
|
|
125
|
+
"""
|
|
126
|
+
|
|
127
|
+
video_id: str
|
|
128
|
+
"""Exact video ID; must not be blank. Combined with all other filters using AND."""
|
|
129
|
+
|
|
130
|
+
video_title: str
|
|
131
|
+
"""Exact, case-sensitive video title.
|
|
132
|
+
|
|
133
|
+
Selects views by the title on their first retained start; event lists match each
|
|
134
|
+
event's own value. Views without a title do not match. Reports with this filter
|
|
135
|
+
read one stored row per view.
|
|
136
|
+
"""
|
|
137
|
+
|
|
138
|
+
view_id: str
|
|
139
|
+
"""Filter one playback attempt by view ID. Metrics use its first retained start."""
|
|
140
|
+
|
|
141
|
+
viewer_id: str
|
|
142
|
+
"""Exact viewer ID.
|
|
143
|
+
|
|
144
|
+
The Chunkify player SDK generates one per browser; missing/null viewer IDs do
|
|
145
|
+
not match.
|
|
146
|
+
"""
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
|
|
5
|
+
from typing import List, Optional
|
|
6
|
+
|
|
7
|
+
from .._models import BaseModel
|
|
8
|
+
|
|
9
|
+
__all__ = ["EventPage"]
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
class EventPage(BaseModel):
|
|
13
|
+
events: List["StoredEvent"]
|
|
14
|
+
|
|
15
|
+
next_cursor: Optional[str] = None
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
from .stored_event import StoredEvent
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from datetime import datetime
|
|
4
|
+
from typing_extensions import Literal
|
|
5
|
+
|
|
6
|
+
from .._models import BaseModel
|
|
7
|
+
|
|
8
|
+
__all__ = ["Export"]
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
class Export(BaseModel):
|
|
12
|
+
content_type: Literal["text/csv"]
|
|
13
|
+
|
|
14
|
+
download_url: str
|
|
15
|
+
|
|
16
|
+
expires_at: datetime
|
|
17
|
+
|
|
18
|
+
filename: str
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from typing import List
|
|
4
|
+
|
|
5
|
+
from .._models import BaseModel
|
|
6
|
+
|
|
7
|
+
__all__ = ["ExportColumns"]
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
class ExportColumns(BaseModel):
|
|
11
|
+
columns: List[str]
|
|
12
|
+
"""Available CSV column names in default output order."""
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
|
|
5
|
+
from typing_extensions import Literal, Required, TypedDict
|
|
6
|
+
|
|
7
|
+
from .._types import SequenceNotStr
|
|
8
|
+
from .export_query_param import ExportQueryParam
|
|
9
|
+
|
|
10
|
+
__all__ = ["ExportCreateParams"]
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
class ExportCreateParams(TypedDict, total=False):
|
|
14
|
+
resource: Required[
|
|
15
|
+
Literal[
|
|
16
|
+
"summary",
|
|
17
|
+
"quality",
|
|
18
|
+
"engagement",
|
|
19
|
+
"timeseries",
|
|
20
|
+
"videos",
|
|
21
|
+
"events",
|
|
22
|
+
"views",
|
|
23
|
+
"errors",
|
|
24
|
+
"dimensions",
|
|
25
|
+
"renditions",
|
|
26
|
+
"subtitles",
|
|
27
|
+
"playback_rates",
|
|
28
|
+
"retention",
|
|
29
|
+
]
|
|
30
|
+
]
|
|
31
|
+
|
|
32
|
+
columns: SequenceNotStr[str]
|
|
33
|
+
"""CSV column names in output order.
|
|
34
|
+
|
|
35
|
+
Omit for all columns. Get the available names from GET /v1/exports using the
|
|
36
|
+
same resource, kind and group_by. Unknown names, duplicates and empty selections
|
|
37
|
+
are rejected.
|
|
38
|
+
"""
|
|
39
|
+
|
|
40
|
+
query: ExportQueryParam
|