transcodely 0.3.8__py3-none-any.whl → 0.3.9__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.
transcodely/__init__.py CHANGED
@@ -67,6 +67,7 @@ from .types import (
67
67
  DRMConfig,
68
68
  HDRConfig,
69
69
  HLSConfig,
70
+ IngestRule,
70
71
  Invoice,
71
72
  InvoiceLineItem,
72
73
  InvoiceLineType,
@@ -85,6 +86,9 @@ from .types import (
85
86
  Preset,
86
87
  PresetVariant,
87
88
  Resolution,
89
+ StorageEvent,
90
+ StorageEventSource,
91
+ StorageEventStatus,
88
92
  StreamingConfig,
89
93
  SubtitleResult,
90
94
  SubtitleTrack,
@@ -149,6 +153,7 @@ __all__ = [
149
153
  "FieldViolation",
150
154
  "HDRConfig",
151
155
  "HLSConfig",
156
+ "IngestRule",
152
157
  "InvalidRequestError",
153
158
  "Invoice",
154
159
  "InvoiceLineItem",
@@ -174,6 +179,9 @@ __all__ = [
174
179
  "PresetVariant",
175
180
  "RateLimitError",
176
181
  "Resolution",
182
+ "StorageEvent",
183
+ "StorageEventSource",
184
+ "StorageEventStatus",
177
185
  "StreamingConfig",
178
186
  "SubtitleResult",
179
187
  "SubtitleTrack",
transcodely/client.py CHANGED
@@ -13,6 +13,7 @@ from .resources.apps import Apps
13
13
  from .resources.billing import Billing
14
14
  from .resources.events import Events
15
15
  from .resources.health import Health
16
+ from .resources.ingest_rules import IngestRules
16
17
  from .resources.jobs import Jobs
17
18
  from .resources.memberships import Memberships
18
19
  from .resources.organizations import Organizations
@@ -63,6 +64,7 @@ class Transcodely:
63
64
  self._videos: Videos | None = None
64
65
  self._presets: Presets | None = None
65
66
  self._origins: Origins | None = None
67
+ self._ingest_rules: IngestRules | None = None
66
68
  self._apps: Apps | None = None
67
69
  self._api_keys: ApiKeys | None = None
68
70
  self._organizations: Organizations | None = None
@@ -111,6 +113,13 @@ class Transcodely:
111
113
  self._origins = Origins(self._transport)
112
114
  return self._origins
113
115
 
116
+ @property
117
+ def ingest_rules(self) -> IngestRules:
118
+ """Ingest rules: watch a bucket, transcode what lands in it."""
119
+ if self._ingest_rules is None:
120
+ self._ingest_rules = IngestRules(self._transport)
121
+ return self._ingest_rules
122
+
114
123
  @property
115
124
  def apps(self) -> Apps:
116
125
  if self._apps is None:
@@ -52,15 +52,25 @@ class Events:
52
52
  def list(
53
53
  self,
54
54
  *,
55
- app_id: str,
55
+ app_id: str | None = None,
56
56
  type: str | None = None,
57
57
  created_after: datetime | None = None,
58
58
  created_before: datetime | None = None,
59
59
  limit: int | None = None,
60
60
  opts: CallOptions | None = None,
61
61
  ) -> Page[Event]:
62
+ """List events, newest first.
63
+
64
+ ``app_id`` is an optional filter. An API-key caller may omit it and get
65
+ their key's own app; passing a different app's ID is refused with
66
+ ``permission_denied``. A portal user who omits it gets the events of
67
+ every app in the organization.
68
+ """
69
+
62
70
  def fetch(cursor: str | None) -> PageContents[Event]:
63
- req = webhook_pb2.ListEventsRequest(app_id=app_id)
71
+ req = webhook_pb2.ListEventsRequest()
72
+ if app_id is not None:
73
+ req.app_id = app_id
64
74
  if type is not None:
65
75
  req.type = type
66
76
  if created_after is not None:
@@ -0,0 +1,183 @@
1
+ """Ingest rule resource — watch a bucket, transcode what lands in it.
2
+
3
+ An ingest rule is a standing instruction on one readable storage origin: when
4
+ an object matching its filters appears, create the job its action describes.
5
+ Your storage provider posts object-created events to the rule's
6
+ ``endpoint_url``, authenticated with the rule's secret, so no server of yours is
7
+ in the path. Amazon S3 via SNS, Google Cloud Storage via a Pub/Sub push
8
+ subscription, Supabase Storage via a database webhook, and a generic shape for
9
+ anything else are all recognised from the payload.
10
+
11
+ Duplicate deliveries are absorbed: an object is identified by
12
+ (rule, bucket, key, etag) and produces exactly one job.
13
+
14
+ The inbound endpoint itself is not part of this SDK — your storage provider
15
+ calls it, not you.
16
+ """
17
+
18
+ from __future__ import annotations
19
+
20
+ from typing import Any, cast
21
+
22
+ from .._transport.transport import CallOptions, Transport
23
+ from ..pagination import Page, PageContents
24
+ from ..v1 import ingest_rule_pb2
25
+ from ._helpers import assign_pagination, fill_from_dict, resolve_enum
26
+
27
+ _SERVICE = "transcodely.v1.IngestRuleService"
28
+
29
+
30
+ class IngestRules:
31
+ def __init__(self, transport: Transport) -> None:
32
+ self._t = transport
33
+
34
+ def create(self, **kwargs: Any) -> ingest_rule_pb2.CreateIngestRuleResponse:
35
+ """Create a rule on a readable origin.
36
+
37
+ The whole response is returned because ``secret`` rides on it: the
38
+ inbound secret is shown once, here, and cannot be read back. Store it
39
+ wherever the event sender will read it from.
40
+ """
41
+ req = fill_from_dict(ingest_rule_pb2.CreateIngestRuleRequest(), kwargs)
42
+ return self._t.unary(_SERVICE, "Create", req, ingest_rule_pb2.CreateIngestRuleResponse())
43
+
44
+ def get(self, id: str, opts: CallOptions | None = None) -> ingest_rule_pb2.IngestRule:
45
+ """Fetch a rule by ID (``ing_*``).
46
+
47
+ The secret is never returned again — the rule carries only
48
+ ``secret_prefix`` and ``secret_hint``.
49
+ """
50
+ req = ingest_rule_pb2.GetIngestRuleRequest(id=id)
51
+ return self._t.unary(
52
+ _SERVICE, "Get", req, ingest_rule_pb2.GetIngestRuleResponse(), opts
53
+ ).rule
54
+
55
+ def list(
56
+ self,
57
+ *,
58
+ origin_id: str | None = None,
59
+ enabled: bool | None = None,
60
+ app_id: str | None = None,
61
+ limit: int | None = None,
62
+ opts: CallOptions | None = None,
63
+ ) -> Page[ingest_rule_pb2.IngestRule]:
64
+ """Rules in scope, newest first."""
65
+
66
+ def fetch(cursor: str | None) -> PageContents[ingest_rule_pb2.IngestRule]:
67
+ req = ingest_rule_pb2.ListIngestRulesRequest()
68
+ if origin_id is not None:
69
+ req.origin_id = origin_id
70
+ if enabled is not None:
71
+ req.enabled = enabled
72
+ if app_id is not None:
73
+ req.app_id = app_id
74
+ assign_pagination(req.pagination, limit=limit, cursor=cursor)
75
+ res = self._t.unary(
76
+ _SERVICE, "List", req, ingest_rule_pb2.ListIngestRulesResponse(), opts
77
+ )
78
+ return PageContents(
79
+ items=list(res.rules), next_cursor=res.pagination.next_cursor or None
80
+ )
81
+
82
+ return Page(fetch)
83
+
84
+ def update(self, **kwargs: Any) -> ingest_rule_pb2.UpdateIngestRuleResponse:
85
+ """Update name, enabled state, filters or action, optionally rotating the secret.
86
+
87
+ The update MERGES: it applies only what it carries, down to the
88
+ individual filters and the individual parts of the action. Narrowing a
89
+ rule to a new prefix is ``filters={"prefix": "raw/"}`` and nothing else
90
+ — the suffix, content-type and size filters are untouched.
91
+
92
+ Removing something rather than changing it takes the two clear flags.
93
+ ``clear_filters=True`` empties the filter set before ``filters`` is
94
+ applied, so on its own it widens the rule to everything in the bucket.
95
+ ``clear_action=True`` replaces the action outright, and ``action`` must
96
+ then be complete — at least one output and exactly one destination.
97
+ That is the only way to drop an action's thumbnails or metadata, since
98
+ a repeated or map field sent empty reads as "not sent". For the same
99
+ reason ``managed=False`` does not turn managed storage off; it leaves
100
+ the destination alone, so send ``output_origin_id`` instead.
101
+
102
+ The whole response is returned: a rotation puts the new secret on it
103
+ (once, and the previous secret keeps working for 24 hours), and
104
+ switching a paused rule back on reports how many deliveries it declined
105
+ while off in ``events_skipped_while_disabled``.
106
+ """
107
+ req = fill_from_dict(ingest_rule_pb2.UpdateIngestRuleRequest(), kwargs)
108
+ return self._t.unary(_SERVICE, "Update", req, ingest_rule_pb2.UpdateIngestRuleResponse())
109
+
110
+ def delete(self, id: str, opts: CallOptions | None = None) -> ingest_rule_pb2.IngestRule:
111
+ """Delete a rule; its endpoint stops accepting events immediately.
112
+
113
+ The events it already received are kept, and the rule as it stood at
114
+ deletion is returned.
115
+ """
116
+ req = ingest_rule_pb2.DeleteIngestRuleRequest(id=id)
117
+ return self._t.unary(
118
+ _SERVICE, "Delete", req, ingest_rule_pb2.DeleteIngestRuleResponse(), opts
119
+ ).rule
120
+
121
+ def list_events(
122
+ self,
123
+ *,
124
+ rule_id: str | None = None,
125
+ status: int | str | None = None,
126
+ app_id: str | None = None,
127
+ limit: int | None = None,
128
+ opts: CallOptions | None = None,
129
+ ) -> Page[ingest_rule_pb2.StorageEvent]:
130
+ """Every delivery received and what came of it, newest first.
131
+
132
+ ``status`` accepts the simplified wire string (``"skipped"``) as well as
133
+ the generated constant.
134
+ """
135
+ resolved_status = (
136
+ None
137
+ if status is None
138
+ else resolve_enum(status, ingest_rule_pb2.StorageEventStatus.DESCRIPTOR)
139
+ )
140
+
141
+ def fetch(cursor: str | None) -> PageContents[ingest_rule_pb2.StorageEvent]:
142
+ req = ingest_rule_pb2.ListIngestEventsRequest()
143
+ if rule_id is not None:
144
+ req.rule_id = rule_id
145
+ if resolved_status is not None:
146
+ # resolve_enum returns a plain int; the field is typed as the enum.
147
+ req.status = cast("ingest_rule_pb2.StorageEventStatus", resolved_status)
148
+ if app_id is not None:
149
+ req.app_id = app_id
150
+ assign_pagination(req.pagination, limit=limit, cursor=cursor)
151
+ res = self._t.unary(
152
+ _SERVICE, "ListEvents", req, ingest_rule_pb2.ListIngestEventsResponse(), opts
153
+ )
154
+ return PageContents(
155
+ items=list(res.events), next_cursor=res.pagination.next_cursor or None
156
+ )
157
+
158
+ return Page(fetch)
159
+
160
+ def test(self, **kwargs: Any) -> ingest_rule_pb2.TestIngestRuleResponse:
161
+ """Dry-run an object key against a rule. Nothing is stored, no job is created.
162
+
163
+ Reports whether the filters match and, when they do, the exact job
164
+ request the rule would submit. Supply ``etag`` when you want the
165
+ preview to name the idempotency key a real delivery would carry — the
166
+ key is derived from it.
167
+ """
168
+ req = fill_from_dict(ingest_rule_pb2.TestIngestRuleRequest(), kwargs)
169
+ return self._t.unary(_SERVICE, "Test", req, ingest_rule_pb2.TestIngestRuleResponse())
170
+
171
+ def replay_event(
172
+ self, event_id: str, opts: CallOptions | None = None
173
+ ) -> ingest_rule_pb2.StorageEvent:
174
+ """Re-queue a skipped or refused event (``sev_*``).
175
+
176
+ Deduplication is permanent: re-sending the event, or re-uploading the
177
+ same bytes, is absorbed and produces nothing. The event is reset rather
178
+ than duplicated, so it keeps its id and its history.
179
+ """
180
+ req = ingest_rule_pb2.ReplayIngestEventRequest(event_id=event_id)
181
+ return self._t.unary(
182
+ _SERVICE, "ReplayEvent", req, ingest_rule_pb2.ReplayIngestEventResponse(), opts
183
+ ).event
@@ -126,12 +126,22 @@ class WebhookEndpoints:
126
126
  def list(
127
127
  self,
128
128
  *,
129
- app_id: str,
129
+ app_id: str | None = None,
130
130
  limit: int | None = None,
131
131
  opts: CallOptions | None = None,
132
132
  ) -> Page[webhook_pb2.WebhookEndpoint]:
133
+ """List webhook endpoints, newest first.
134
+
135
+ ``app_id`` is an optional filter. An API-key caller may omit it and get
136
+ their key's own app; passing a different app's ID is refused with
137
+ ``permission_denied``. A portal user who omits it gets the endpoints of
138
+ every app in the organization.
139
+ """
140
+
133
141
  def fetch(cursor: str | None) -> PageContents[webhook_pb2.WebhookEndpoint]:
134
- req = webhook_pb2.ListWebhookEndpointsRequest(app_id=app_id)
142
+ req = webhook_pb2.ListWebhookEndpointsRequest()
143
+ if app_id is not None:
144
+ req.app_id = app_id
135
145
  pagination = common_pb2.PaginationRequest()
136
146
  if limit is not None:
137
147
  pagination.limit = limit
transcodely/types.py CHANGED
@@ -140,12 +140,23 @@ from transcodely.v1.common_pb2 import (
140
140
  VideoCodec,
141
141
  )
142
142
 
143
- # Content-aware encoding is currently unavailable: the API rejects any job
144
- # create request that sets ``content_aware`` (per-title or auto-ABR) on an
145
- # output with InvalidArgument — rule ``parameter_unsupported`` on
146
- # ``outputs[i].content_aware`` — until worker support ships. These types stay
147
- # re-exported for forward compatibility.
143
+ # ``ContentAwareConfig`` turns on per-title encoding for one output: the worker
144
+ # finds the CRF this source needs to reach the VMAF target and encodes the
145
+ # declared ladder at it, priced at 1.5x. The ladder is unchanged, so the price
146
+ # quoted at create still holds, and what the search decided comes back on
147
+ # ``report.content_aware``.
148
+ #
149
+ # ``ContentAwareMode.CONTENT_AWARE_MODE_PER_TITLE`` is accepted.
150
+ # ``CONTENT_AWARE_MODE_AUTO_ABR`` is still rejected at create with
151
+ # InvalidArgument — rule ``parameter_unsupported`` on
152
+ # ``outputs[i].content_aware`` — because it would change the number of
153
+ # renditions after the job was quoted per rendition. ``AutoABRConfig`` is
154
+ # re-exported for that mode and has no effect until it ships.
148
155
  # See https://github.com/transcodely/api/issues/167.
156
+ #
157
+ # Per-title also needs at least one video rendition that is not pinned to an
158
+ # explicit bitrate (``parameter_incompatible`` at create) and a source of at
159
+ # least 120 seconds (``per_title_source_too_short``, at probe).
149
160
  from transcodely.v1.content_aware_pb2 import (
150
161
  AutoABRConfig,
151
162
  ContentAnalysis,
@@ -175,6 +186,32 @@ from transcodely.v1.health_pb2 import (
175
186
  HealthCheckResponse,
176
187
  )
177
188
 
189
+ # Ingest rules.
190
+ from transcodely.v1.ingest_rule_pb2 import (
191
+ CreateIngestRuleRequest,
192
+ CreateIngestRuleResponse,
193
+ DeleteIngestRuleRequest,
194
+ DeleteIngestRuleResponse,
195
+ GetIngestRuleRequest,
196
+ GetIngestRuleResponse,
197
+ IngestRule,
198
+ IngestRuleAction,
199
+ IngestRuleFilters,
200
+ ListIngestEventsRequest,
201
+ ListIngestEventsResponse,
202
+ ListIngestRulesRequest,
203
+ ListIngestRulesResponse,
204
+ ReplayIngestEventRequest,
205
+ ReplayIngestEventResponse,
206
+ StorageEvent,
207
+ StorageEventSource,
208
+ StorageEventStatus,
209
+ TestIngestRuleRequest,
210
+ TestIngestRuleResponse,
211
+ UpdateIngestRuleRequest,
212
+ UpdateIngestRuleResponse,
213
+ )
214
+
178
215
  # Jobs.
179
216
  from transcodely.v1.job_pb2 import (
180
217
  AudioTrackConfig,
@@ -200,6 +237,13 @@ from transcodely.v1.job_pb2 import (
200
237
  JobStatus,
201
238
  ListJobsRequest,
202
239
  ListJobsResponse,
240
+ OutputReport,
241
+ OutputReportAudio,
242
+ OutputReportColor,
243
+ OutputReportContentAware,
244
+ OutputReportMismatch,
245
+ OutputReportVerdict,
246
+ OutputReportVideo,
203
247
  OutputSpec,
204
248
  OutputStatus,
205
249
  OutputVariantResult,
@@ -472,6 +516,8 @@ __all__ = [
472
516
  "CreateBillingPortalSessionResponse",
473
517
  "CreateFromUrlRequest",
474
518
  "CreateFromUrlResponse",
519
+ "CreateIngestRuleRequest",
520
+ "CreateIngestRuleResponse",
475
521
  "CreateJobRequest",
476
522
  "CreateJobResponse",
477
523
  "CreateMultipartUploadRequest",
@@ -491,6 +537,8 @@ __all__ = [
491
537
  "DRMKeyServerConfig",
492
538
  "DRMSystem",
493
539
  "DailyUsage",
540
+ "DeleteIngestRuleRequest",
541
+ "DeleteIngestRuleResponse",
494
542
  "DeleteVideoRequest",
495
543
  "DeleteWebhookEndpointRequest",
496
544
  "DeleteWebhookEndpointResponse",
@@ -520,6 +568,8 @@ __all__ = [
520
568
  "GetBudgetResponse",
521
569
  "GetEndpointHealthRequest",
522
570
  "GetEndpointHealthResponse",
571
+ "GetIngestRuleRequest",
572
+ "GetIngestRuleResponse",
523
573
  "GetInvoiceRequest",
524
574
  "GetInvoiceResponse",
525
575
  "GetJobRequest",
@@ -566,6 +616,9 @@ __all__ = [
566
616
  "HostingConfig",
567
617
  "HttpCredentials",
568
618
  "HttpOriginConfig",
619
+ "IngestRule",
620
+ "IngestRuleAction",
621
+ "IngestRuleFilters",
569
622
  "InputMetadata",
570
623
  "Invoice",
571
624
  "InvoiceLineItem",
@@ -585,6 +638,10 @@ __all__ = [
585
638
  "ListAppsResponse",
586
639
  "ListEventsRequest",
587
640
  "ListEventsResponse",
641
+ "ListIngestEventsRequest",
642
+ "ListIngestEventsResponse",
643
+ "ListIngestRulesRequest",
644
+ "ListIngestRulesResponse",
588
645
  "ListInvoicesRequest",
589
646
  "ListInvoicesResponse",
590
647
  "ListJobsRequest",
@@ -617,6 +674,13 @@ __all__ = [
617
674
  "OriginRef",
618
675
  "OriginStatus",
619
676
  "OutputFormat",
677
+ "OutputReport",
678
+ "OutputReportAudio",
679
+ "OutputReportColor",
680
+ "OutputReportContentAware",
681
+ "OutputReportMismatch",
682
+ "OutputReportVerdict",
683
+ "OutputReportVideo",
620
684
  "OutputSpec",
621
685
  "OutputStatus",
622
686
  "OutputVariantResult",
@@ -631,6 +695,8 @@ __all__ = [
631
695
  "R2Jurisdiction",
632
696
  "R2OriginConfig",
633
697
  "RemoveMembershipRequest",
698
+ "ReplayIngestEventRequest",
699
+ "ReplayIngestEventResponse",
634
700
  "ResendEventRequest",
635
701
  "ResendEventResponse",
636
702
  "Resolution",
@@ -649,12 +715,17 @@ __all__ = [
649
715
  "SettleOutstandingBalanceRequest",
650
716
  "SettleOutstandingBalanceResponse",
651
717
  "Settlement",
718
+ "StorageEvent",
719
+ "StorageEventSource",
720
+ "StorageEventStatus",
652
721
  "StreamingConfig",
653
722
  "SubtitleFormat",
654
723
  "SubtitleOperation",
655
724
  "SubtitleResult",
656
725
  "SubtitleStreamInfo",
657
726
  "SubtitleTrack",
727
+ "TestIngestRuleRequest",
728
+ "TestIngestRuleResponse",
658
729
  "ThumbnailFormat",
659
730
  "ThumbnailMode",
660
731
  "ThumbnailResult",
@@ -668,6 +739,8 @@ __all__ = [
668
739
  "UpdateBudgetResponse",
669
740
  "UpdateHostingConfigRequest",
670
741
  "UpdateHostingConfigResponse",
742
+ "UpdateIngestRuleRequest",
743
+ "UpdateIngestRuleResponse",
671
744
  "UpdateMeRequest",
672
745
  "UpdateMeResponse",
673
746
  "UpdateMembershipRoleRequest",
@@ -27,7 +27,7 @@ from google.protobuf import timestamp_pb2 as google_dot_protobuf_dot_timestamp__
27
27
  from transcodely.v1 import common_pb2 as transcodely_dot_v1_dot_common__pb2
28
28
 
29
29
 
30
- DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x1ctranscodely/v1/api_key.proto\x12\x0etranscodely.v1\x1a\x1b\x62uf/validate/validate.proto\x1a\x1fgoogle/protobuf/timestamp.proto\x1a\x1btranscodely/v1/common.proto\"\x96\x04\n\x06\x41PIKey\x12\x0e\n\x02id\x18\x01 \x01(\tR\x02id\x12\x15\n\x06\x61pp_id\x18\r \x01(\tR\x05\x61ppId\x12\x12\n\x04name\x18\x02 \x01(\tR\x04name\x12 \n\x0b\x64\x65scription\x18\x03 \x01(\tR\x0b\x64\x65scription\x12\x1d\n\nkey_prefix\x18\x04 \x01(\tR\tkeyPrefix\x12\x19\n\x08key_hint\x18\x05 \x01(\tR\x07keyHint\x12\x16\n\x06scopes\x18\x07 \x03(\tR\x06scopes\x12\x41\n\x0clast_used_at\x18\x08 \x01(\x0b\x32\x1a.google.protobuf.TimestampH\x00R\nlastUsedAt\x88\x01\x01\x12>\n\nexpires_at\x18\t \x01(\x0b\x32\x1a.google.protobuf.TimestampH\x01R\texpiresAt\x88\x01\x01\x12\x39\n\ncreated_at\x18\n \x01(\x0b\x32\x1a.google.protobuf.TimestampR\tcreatedAt\x12\x1d\n\nis_revoked\x18\x0b \x01(\x08R\tisRevoked\x12>\n\nrevoked_at\x18\x0c \x01(\x0b\x32\x1a.google.protobuf.TimestampH\x02R\trevokedAt\x88\x01\x01\x42\x0f\n\r_last_used_atB\r\n\x0b_expires_atB\r\n\x0b_revoked_atJ\x04\x08\x06\x10\x07R\x0b\x65nvironment\"\xfa\x01\n\x13\x43reateAPIKeyRequest\x12!\n\x04name\x18\x01 \x01(\tB\r\xbaH\nr\x05\x10\x01\x18\xff\x01\xc8\x01\x01R\x04name\x12*\n\x0b\x64\x65scription\x18\x02 \x01(\tB\x08\xbaH\x05r\x03\x18\xe8\x07R\x0b\x64\x65scription\x12>\n\nexpires_at\x18\x04 \x01(\x0b\x32\x1a.google.protobuf.TimestampH\x00R\texpiresAt\x88\x01\x01\x12\x32\n\x06\x61pp_id\x18\x05 \x01(\tB\x1b\xbaH\x18r\x16\x32\x14^app_[a-zA-Z0-9_-]+$R\x05\x61ppIdB\r\n\x0b_expires_atJ\x04\x08\x03\x10\x04R\x0b\x65nvironment\"_\n\x14\x43reateAPIKeyResponse\x12/\n\x07\x61pi_key\x18\x01 \x01(\x0b\x32\x16.transcodely.v1.APIKeyR\x06\x61piKey\x12\x16\n\x06secret\x18\x02 \x01(\tR\x06secret\"A\n\x10GetAPIKeyRequest\x12-\n\x02id\x18\x01 \x01(\tB\x1d\xbaH\x1ar\x15\x32\x13^ak_[a-zA-Z0-9_-]+$\xc8\x01\x01R\x02id\"D\n\x11GetAPIKeyResponse\x12/\n\x07\x61pi_key\x18\x01 \x01(\x0b\x32\x16.transcodely.v1.APIKeyR\x06\x61piKey\"\xd7\x01\n\x12ListAPIKeysRequest\x12\'\n\x0finclude_revoked\x18\x02 \x01(\x08R\x0eincludeRevoked\x12\x41\n\npagination\x18\x03 \x01(\x0b\x32!.transcodely.v1.PaginationRequestR\npagination\x12\x37\n\x06\x61pp_id\x18\x04 \x01(\tB\x1b\xbaH\x18r\x16\x32\x14^app_[a-zA-Z0-9_-]+$H\x00R\x05\x61ppId\x88\x01\x01\x42\t\n\x07_app_idJ\x04\x08\x01\x10\x02R\x0b\x65nvironment\"\x8c\x01\n\x13ListAPIKeysResponse\x12\x31\n\x08\x61pi_keys\x18\x01 \x03(\x0b\x32\x16.transcodely.v1.APIKeyR\x07\x61piKeys\x12\x42\n\npagination\x18\x02 \x01(\x0b\x32\".transcodely.v1.PaginationResponseR\npagination\"f\n\x13RevokeAPIKeyRequest\x12-\n\x02id\x18\x01 \x01(\tB\x1d\xbaH\x1ar\x15\x32\x13^ak_[a-zA-Z0-9_-]+$\xc8\x01\x01R\x02id\x12 \n\x06reason\x18\x02 \x01(\tB\x08\xbaH\x05r\x03\x18\xf4\x03R\x06reason\"G\n\x14RevokeAPIKeyResponse\x12/\n\x07\x61pi_key\x18\x01 \x01(\x0b\x32\x16.transcodely.v1.APIKeyR\x06\x61piKey2\xd6\x02\n\rAPIKeyService\x12S\n\x06\x43reate\x12#.transcodely.v1.CreateAPIKeyRequest\x1a$.transcodely.v1.CreateAPIKeyResponse\x12J\n\x03Get\x12 .transcodely.v1.GetAPIKeyRequest\x1a!.transcodely.v1.GetAPIKeyResponse\x12O\n\x04List\x12\".transcodely.v1.ListAPIKeysRequest\x1a#.transcodely.v1.ListAPIKeysResponse\x12S\n\x06Revoke\x12#.transcodely.v1.RevokeAPIKeyRequest\x1a$.transcodely.v1.RevokeAPIKeyResponseb\x06proto3')
30
+ DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x1ctranscodely/v1/api_key.proto\x12\x0etranscodely.v1\x1a\x1b\x62uf/validate/validate.proto\x1a\x1fgoogle/protobuf/timestamp.proto\x1a\x1btranscodely/v1/common.proto\"\x96\x04\n\x06\x41PIKey\x12\x0e\n\x02id\x18\x01 \x01(\tR\x02id\x12\x15\n\x06\x61pp_id\x18\r \x01(\tR\x05\x61ppId\x12\x12\n\x04name\x18\x02 \x01(\tR\x04name\x12 \n\x0b\x64\x65scription\x18\x03 \x01(\tR\x0b\x64\x65scription\x12\x1d\n\nkey_prefix\x18\x04 \x01(\tR\tkeyPrefix\x12\x19\n\x08key_hint\x18\x05 \x01(\tR\x07keyHint\x12\x16\n\x06scopes\x18\x07 \x03(\tR\x06scopes\x12\x41\n\x0clast_used_at\x18\x08 \x01(\x0b\x32\x1a.google.protobuf.TimestampH\x00R\nlastUsedAt\x88\x01\x01\x12>\n\nexpires_at\x18\t \x01(\x0b\x32\x1a.google.protobuf.TimestampH\x01R\texpiresAt\x88\x01\x01\x12\x39\n\ncreated_at\x18\n \x01(\x0b\x32\x1a.google.protobuf.TimestampR\tcreatedAt\x12\x1d\n\nis_revoked\x18\x0b \x01(\x08R\tisRevoked\x12>\n\nrevoked_at\x18\x0c \x01(\x0b\x32\x1a.google.protobuf.TimestampH\x02R\trevokedAt\x88\x01\x01\x42\x0f\n\r_last_used_atB\r\n\x0b_expires_atB\r\n\x0b_revoked_atJ\x04\x08\x06\x10\x07R\x0b\x65nvironment\"\xfd\x01\n\x13\x43reateAPIKeyRequest\x12!\n\x04name\x18\x01 \x01(\tB\r\xbaH\nr\x05\x10\x01\x18\xff\x01\xc8\x01\x01R\x04name\x12*\n\x0b\x64\x65scription\x18\x02 \x01(\tB\x08\xbaH\x05r\x03\x18\xe8\x07R\x0b\x64\x65scription\x12>\n\nexpires_at\x18\x04 \x01(\x0b\x32\x1a.google.protobuf.TimestampH\x00R\texpiresAt\x88\x01\x01\x12\x35\n\x06\x61pp_id\x18\x05 \x01(\tB\x1e\xbaH\x1br\x16\x32\x14^app_[a-zA-Z0-9_-]+$\xd8\x01\x01R\x05\x61ppIdB\r\n\x0b_expires_atJ\x04\x08\x03\x10\x04R\x0b\x65nvironment\"_\n\x14\x43reateAPIKeyResponse\x12/\n\x07\x61pi_key\x18\x01 \x01(\x0b\x32\x16.transcodely.v1.APIKeyR\x06\x61piKey\x12\x16\n\x06secret\x18\x02 \x01(\tR\x06secret\"A\n\x10GetAPIKeyRequest\x12-\n\x02id\x18\x01 \x01(\tB\x1d\xbaH\x1ar\x15\x32\x13^ak_[a-zA-Z0-9_-]+$\xc8\x01\x01R\x02id\"D\n\x11GetAPIKeyResponse\x12/\n\x07\x61pi_key\x18\x01 \x01(\x0b\x32\x16.transcodely.v1.APIKeyR\x06\x61piKey\"\xd7\x01\n\x12ListAPIKeysRequest\x12\'\n\x0finclude_revoked\x18\x02 \x01(\x08R\x0eincludeRevoked\x12\x41\n\npagination\x18\x03 \x01(\x0b\x32!.transcodely.v1.PaginationRequestR\npagination\x12\x37\n\x06\x61pp_id\x18\x04 \x01(\tB\x1b\xbaH\x18r\x16\x32\x14^app_[a-zA-Z0-9_-]+$H\x00R\x05\x61ppId\x88\x01\x01\x42\t\n\x07_app_idJ\x04\x08\x01\x10\x02R\x0b\x65nvironment\"\x8c\x01\n\x13ListAPIKeysResponse\x12\x31\n\x08\x61pi_keys\x18\x01 \x03(\x0b\x32\x16.transcodely.v1.APIKeyR\x07\x61piKeys\x12\x42\n\npagination\x18\x02 \x01(\x0b\x32\".transcodely.v1.PaginationResponseR\npagination\"f\n\x13RevokeAPIKeyRequest\x12-\n\x02id\x18\x01 \x01(\tB\x1d\xbaH\x1ar\x15\x32\x13^ak_[a-zA-Z0-9_-]+$\xc8\x01\x01R\x02id\x12 \n\x06reason\x18\x02 \x01(\tB\x08\xbaH\x05r\x03\x18\xf4\x03R\x06reason\"G\n\x14RevokeAPIKeyResponse\x12/\n\x07\x61pi_key\x18\x01 \x01(\x0b\x32\x16.transcodely.v1.APIKeyR\x06\x61piKey2\xd6\x02\n\rAPIKeyService\x12S\n\x06\x43reate\x12#.transcodely.v1.CreateAPIKeyRequest\x1a$.transcodely.v1.CreateAPIKeyResponse\x12J\n\x03Get\x12 .transcodely.v1.GetAPIKeyRequest\x1a!.transcodely.v1.GetAPIKeyResponse\x12O\n\x04List\x12\".transcodely.v1.ListAPIKeysRequest\x1a#.transcodely.v1.ListAPIKeysResponse\x12S\n\x06Revoke\x12#.transcodely.v1.RevokeAPIKeyRequest\x1a$.transcodely.v1.RevokeAPIKeyResponseb\x06proto3')
31
31
 
32
32
  _globals = globals()
33
33
  _builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals)
@@ -39,7 +39,7 @@ if not _descriptor._USE_C_DESCRIPTORS:
39
39
  _globals['_CREATEAPIKEYREQUEST'].fields_by_name['description']._loaded_options = None
40
40
  _globals['_CREATEAPIKEYREQUEST'].fields_by_name['description']._serialized_options = b'\272H\005r\003\030\350\007'
41
41
  _globals['_CREATEAPIKEYREQUEST'].fields_by_name['app_id']._loaded_options = None
42
- _globals['_CREATEAPIKEYREQUEST'].fields_by_name['app_id']._serialized_options = b'\272H\030r\0262\024^app_[a-zA-Z0-9_-]+$'
42
+ _globals['_CREATEAPIKEYREQUEST'].fields_by_name['app_id']._serialized_options = b'\272H\033r\0262\024^app_[a-zA-Z0-9_-]+$\330\001\001'
43
43
  _globals['_GETAPIKEYREQUEST'].fields_by_name['id']._loaded_options = None
44
44
  _globals['_GETAPIKEYREQUEST'].fields_by_name['id']._serialized_options = b'\272H\032r\0252\023^ak_[a-zA-Z0-9_-]+$\310\001\001'
45
45
  _globals['_LISTAPIKEYSREQUEST'].fields_by_name['app_id']._loaded_options = None
@@ -51,21 +51,21 @@ if not _descriptor._USE_C_DESCRIPTORS:
51
51
  _globals['_APIKEY']._serialized_start=140
52
52
  _globals['_APIKEY']._serialized_end=674
53
53
  _globals['_CREATEAPIKEYREQUEST']._serialized_start=677
54
- _globals['_CREATEAPIKEYREQUEST']._serialized_end=927
55
- _globals['_CREATEAPIKEYRESPONSE']._serialized_start=929
56
- _globals['_CREATEAPIKEYRESPONSE']._serialized_end=1024
57
- _globals['_GETAPIKEYREQUEST']._serialized_start=1026
58
- _globals['_GETAPIKEYREQUEST']._serialized_end=1091
59
- _globals['_GETAPIKEYRESPONSE']._serialized_start=1093
60
- _globals['_GETAPIKEYRESPONSE']._serialized_end=1161
61
- _globals['_LISTAPIKEYSREQUEST']._serialized_start=1164
62
- _globals['_LISTAPIKEYSREQUEST']._serialized_end=1379
63
- _globals['_LISTAPIKEYSRESPONSE']._serialized_start=1382
64
- _globals['_LISTAPIKEYSRESPONSE']._serialized_end=1522
65
- _globals['_REVOKEAPIKEYREQUEST']._serialized_start=1524
66
- _globals['_REVOKEAPIKEYREQUEST']._serialized_end=1626
67
- _globals['_REVOKEAPIKEYRESPONSE']._serialized_start=1628
68
- _globals['_REVOKEAPIKEYRESPONSE']._serialized_end=1699
69
- _globals['_APIKEYSERVICE']._serialized_start=1702
70
- _globals['_APIKEYSERVICE']._serialized_end=2044
54
+ _globals['_CREATEAPIKEYREQUEST']._serialized_end=930
55
+ _globals['_CREATEAPIKEYRESPONSE']._serialized_start=932
56
+ _globals['_CREATEAPIKEYRESPONSE']._serialized_end=1027
57
+ _globals['_GETAPIKEYREQUEST']._serialized_start=1029
58
+ _globals['_GETAPIKEYREQUEST']._serialized_end=1094
59
+ _globals['_GETAPIKEYRESPONSE']._serialized_start=1096
60
+ _globals['_GETAPIKEYRESPONSE']._serialized_end=1164
61
+ _globals['_LISTAPIKEYSREQUEST']._serialized_start=1167
62
+ _globals['_LISTAPIKEYSREQUEST']._serialized_end=1382
63
+ _globals['_LISTAPIKEYSRESPONSE']._serialized_start=1385
64
+ _globals['_LISTAPIKEYSRESPONSE']._serialized_end=1525
65
+ _globals['_REVOKEAPIKEYREQUEST']._serialized_start=1527
66
+ _globals['_REVOKEAPIKEYREQUEST']._serialized_end=1629
67
+ _globals['_REVOKEAPIKEYRESPONSE']._serialized_start=1631
68
+ _globals['_REVOKEAPIKEYRESPONSE']._serialized_end=1702
69
+ _globals['_APIKEYSERVICE']._serialized_start=1705
70
+ _globals['_APIKEYSERVICE']._serialized_end=2047
71
71
  # @@protoc_insertion_point(module_scope)
@@ -26,7 +26,7 @@ from buf.validate import validate_pb2 as buf_dot_validate_dot_validate__pb2
26
26
  from transcodely.v1 import common_pb2 as transcodely_dot_v1_dot_common__pb2
27
27
 
28
28
 
29
- DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\"transcodely/v1/content_aware.proto\x12\x0etranscodely.v1\x1a\x1b\x62uf/validate/validate.proto\x1a\x1btranscodely/v1/common.proto\"\xb1\x02\n\rAutoABRConfig\x12\x31\n\x0cmin_variants\x18\x01 \x01(\x05\x42\t\xbaH\x06\x1a\x04\x18\x14(\x02H\x00R\x0bminVariants\x88\x01\x01\x12\x31\n\x0cmax_variants\x18\x02 \x01(\x05\x42\t\xbaH\x06\x1a\x04\x18\x14(\x02H\x01R\x0bmaxVariants\x88\x01\x01\x12K\n\x0emin_resolution\x18\x03 \x01(\x0e\x32\x1a.transcodely.v1.ResolutionB\x08\xbaH\x05\x82\x01\x02\x10\x01R\rminResolution\x12K\n\x0emax_resolution\x18\x04 \x01(\x0e\x32\x1a.transcodely.v1.ResolutionB\x08\xbaH\x05\x82\x01\x02\x10\x01R\rmaxResolutionB\x0f\n\r_min_variantsB\x0f\n\r_max_variants\"\xf2\x01\n\x12\x43ontentAwareConfig\x12\x41\n\x04mode\x18\x01 \x01(\x0e\x32 .transcodely.v1.ContentAwareModeB\x0b\xbaH\x08\x82\x01\x02\x10\x01\xc8\x01\x01R\x04mode\x12=\n\x0bvmaf_target\x18\x02 \x01(\x01\x42\x17\xbaH\x14\x12\x12\x19\x00\x00\x00\x00\x00\xc0X@)\x00\x00\x00\x00\x00\x80Q@H\x00R\nvmafTarget\x88\x01\x01\x12=\n\x08\x61uto_abr\x18\x03 \x01(\x0b\x32\x1d.transcodely.v1.AutoABRConfigH\x01R\x07\x61utoAbr\x88\x01\x01\x42\x0e\n\x0c_vmaf_targetB\x0b\n\t_auto_abr\"\xa7\x01\n\x0f\x43ontentAnalysis\x12)\n\x10\x63omplexity_score\x18\x01 \x01(\x01R\x0f\x63omplexityScore\x12!\n\x0cmotion_score\x18\x02 \x01(\x01R\x0bmotionScore\x12#\n\rtexture_score\x18\x03 \x01(\x01R\x0ctextureScore\x12!\n\x0c\x63ontent_type\x18\x04 \x01(\tR\x0b\x63ontentType*y\n\x10\x43ontentAwareMode\x12\"\n\x1e\x43ONTENT_AWARE_MODE_UNSPECIFIED\x10\x00\x12 \n\x1c\x43ONTENT_AWARE_MODE_PER_TITLE\x10\x01\x12\x1f\n\x1b\x43ONTENT_AWARE_MODE_AUTO_ABR\x10\x02\x62\x06proto3')
29
+ DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\"transcodely/v1/content_aware.proto\x12\x0etranscodely.v1\x1a\x1b\x62uf/validate/validate.proto\x1a\x1btranscodely/v1/common.proto\"\xb1\x02\n\rAutoABRConfig\x12\x31\n\x0cmin_variants\x18\x01 \x01(\x05\x42\t\xbaH\x06\x1a\x04\x18\x14(\x02H\x00R\x0bminVariants\x88\x01\x01\x12\x31\n\x0cmax_variants\x18\x02 \x01(\x05\x42\t\xbaH\x06\x1a\x04\x18\x14(\x02H\x01R\x0bmaxVariants\x88\x01\x01\x12K\n\x0emin_resolution\x18\x03 \x01(\x0e\x32\x1a.transcodely.v1.ResolutionB\x08\xbaH\x05\x82\x01\x02\x10\x01R\rminResolution\x12K\n\x0emax_resolution\x18\x04 \x01(\x0e\x32\x1a.transcodely.v1.ResolutionB\x08\xbaH\x05\x82\x01\x02\x10\x01R\rmaxResolutionB\x0f\n\r_min_variantsB\x0f\n\r_max_variants\"\xf2\x01\n\x12\x43ontentAwareConfig\x12\x41\n\x04mode\x18\x01 \x01(\x0e\x32 .transcodely.v1.ContentAwareModeB\x0b\xbaH\x08\x82\x01\x02\x10\x01\xc8\x01\x01R\x04mode\x12=\n\x0bvmaf_target\x18\x02 \x01(\x01\x42\x17\xbaH\x14\x12\x12\x19\x00\x00\x00\x00\x00@X@)\x00\x00\x00\x00\x00\x00T@H\x00R\nvmafTarget\x88\x01\x01\x12=\n\x08\x61uto_abr\x18\x03 \x01(\x0b\x32\x1d.transcodely.v1.AutoABRConfigH\x01R\x07\x61utoAbr\x88\x01\x01\x42\x0e\n\x0c_vmaf_targetB\x0b\n\t_auto_abr\"\xa7\x01\n\x0f\x43ontentAnalysis\x12)\n\x10\x63omplexity_score\x18\x01 \x01(\x01R\x0f\x63omplexityScore\x12!\n\x0cmotion_score\x18\x02 \x01(\x01R\x0bmotionScore\x12#\n\rtexture_score\x18\x03 \x01(\x01R\x0ctextureScore\x12!\n\x0c\x63ontent_type\x18\x04 \x01(\tR\x0b\x63ontentType*y\n\x10\x43ontentAwareMode\x12\"\n\x1e\x43ONTENT_AWARE_MODE_UNSPECIFIED\x10\x00\x12 \n\x1c\x43ONTENT_AWARE_MODE_PER_TITLE\x10\x01\x12\x1f\n\x1b\x43ONTENT_AWARE_MODE_AUTO_ABR\x10\x02\x62\x06proto3')
30
30
 
31
31
  _globals = globals()
32
32
  _builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals)
@@ -44,7 +44,7 @@ if not _descriptor._USE_C_DESCRIPTORS:
44
44
  _globals['_CONTENTAWARECONFIG'].fields_by_name['mode']._loaded_options = None
45
45
  _globals['_CONTENTAWARECONFIG'].fields_by_name['mode']._serialized_options = b'\272H\010\202\001\002\020\001\310\001\001'
46
46
  _globals['_CONTENTAWARECONFIG'].fields_by_name['vmaf_target']._loaded_options = None
47
- _globals['_CONTENTAWARECONFIG'].fields_by_name['vmaf_target']._serialized_options = b'\272H\024\022\022\031\000\000\000\000\000\300X@)\000\000\000\000\000\200Q@'
47
+ _globals['_CONTENTAWARECONFIG'].fields_by_name['vmaf_target']._serialized_options = b'\272H\024\022\022\031\000\000\000\000\000@X@)\000\000\000\000\000\000T@'
48
48
  _globals['_CONTENTAWAREMODE']._serialized_start=835
49
49
  _globals['_CONTENTAWAREMODE']._serialized_end=956
50
50
  _globals['_AUTOABRCONFIG']._serialized_start=113