@transcodely/sdk 0.3.13 → 0.3.15

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.
package/dist/index.mjs CHANGED
@@ -1916,9 +1916,10 @@ var AutoProfileDefaults = class _AutoProfileDefaults extends Message {
1916
1916
  */
1917
1917
  qualityTier;
1918
1918
  /**
1919
- * Encoding mode: "fixed" (default, static CRF) or "auto" (input-aware constrained CRF).
1919
+ * Encoding mode: "auto" (default, input-aware constrained CRF) or "fixed" (static CRF).
1920
1920
  * In "auto" mode, the worker caps each variant's bitrate based on the input's bitrate
1921
- * and resolution ratio, preventing output from exceeding the input's quality ceiling.
1921
+ * and resolution ratio, preventing output from exceeding the input's quality ceiling,
1922
+ * and skips any ladder rung larger than the source instead of upscaling it.
1922
1923
  *
1923
1924
  * @generated from field: optional string encoding_mode = 5;
1924
1925
  */
@@ -2226,6 +2227,228 @@ var GetSpendResponse = class _GetSpendResponse extends Message {
2226
2227
  return proto3.util.equals(_GetSpendResponse, a, b);
2227
2228
  }
2228
2229
  };
2230
+ var GetPricingRequest = class _GetPricingRequest extends Message {
2231
+ /**
2232
+ * App ID. API-key callers may omit it or pass their own app; a different app
2233
+ * is rejected with PermissionDenied. Dashboard callers pass it to pick an app
2234
+ * in their organization; omitted selects the organization's first active
2235
+ * app in list order (the same default every app-scoped read uses).
2236
+ *
2237
+ * @generated from field: optional string app_id = 1;
2238
+ */
2239
+ appId;
2240
+ constructor(data) {
2241
+ super();
2242
+ proto3.util.initPartial(data, this);
2243
+ }
2244
+ static runtime = proto3;
2245
+ static typeName = "transcodely.v1.GetPricingRequest";
2246
+ static fields = proto3.util.newFieldList(() => [
2247
+ { no: 1, name: "app_id", kind: "scalar", T: 9, opt: true }
2248
+ ]);
2249
+ static fromBinary(bytes, options) {
2250
+ return new _GetPricingRequest().fromBinary(bytes, options);
2251
+ }
2252
+ static fromJson(jsonValue, options) {
2253
+ return new _GetPricingRequest().fromJson(jsonValue, options);
2254
+ }
2255
+ static fromJsonString(jsonString, options) {
2256
+ return new _GetPricingRequest().fromJsonString(jsonString, options);
2257
+ }
2258
+ static equals(a, b) {
2259
+ return proto3.util.equals(_GetPricingRequest, a, b);
2260
+ }
2261
+ };
2262
+ var PricingEntry = class _PricingEntry extends Message {
2263
+ /**
2264
+ * Charge class: codec, resolution, quality, feature, fee, storage, egress.
2265
+ * Other values may appear as new charges are introduced.
2266
+ *
2267
+ * @generated from field: string rule_type = 1;
2268
+ */
2269
+ ruleType = "";
2270
+ /**
2271
+ * Charge within its class, e.g. h264, 1080p, captions, processing_m.
2272
+ *
2273
+ * @generated from field: string rule_key = 2;
2274
+ */
2275
+ ruleKey = "";
2276
+ /**
2277
+ * Human label, e.g. "H.264".
2278
+ *
2279
+ * @generated from field: string label = 3;
2280
+ */
2281
+ label = "";
2282
+ /**
2283
+ * Human label of the class, e.g. "Encoding".
2284
+ *
2285
+ * @generated from field: string group_label = 4;
2286
+ */
2287
+ groupLabel = "";
2288
+ /**
2289
+ * What base_price is per: eur_per_output_minute, eur_per_source_minute,
2290
+ * eur_per_video, eur_per_job, eur_per_gb_month, eur_per_gb, or eur_per_unit
2291
+ * for a charge whose unit is not known yet. Empty for a charge that has only
2292
+ * a multiplier.
2293
+ *
2294
+ * @generated from field: string unit = 5;
2295
+ */
2296
+ unit = "";
2297
+ /**
2298
+ * The price per unit, in EUR, this app pays. Absent for a charge that has
2299
+ * only a multiplier.
2300
+ *
2301
+ * @generated from field: optional double base_price = 6;
2302
+ */
2303
+ basePrice;
2304
+ /**
2305
+ * The multiplier this app pays. Absent for a charge that has only a per-unit
2306
+ * price.
2307
+ *
2308
+ * @generated from field: optional double multiplier = 7;
2309
+ */
2310
+ multiplier;
2311
+ /**
2312
+ * True when this account has a custom rate for this charge, so base_price or
2313
+ * multiplier differs from the list price.
2314
+ *
2315
+ * @generated from field: bool custom = 8;
2316
+ */
2317
+ custom = false;
2318
+ /**
2319
+ * The public list price per unit, in EUR. Absent when base_price is.
2320
+ *
2321
+ * @generated from field: optional double list_base_price = 9;
2322
+ */
2323
+ listBasePrice;
2324
+ /**
2325
+ * The public list multiplier. Absent when multiplier is.
2326
+ *
2327
+ * @generated from field: optional double list_multiplier = 10;
2328
+ */
2329
+ listMultiplier;
2330
+ constructor(data) {
2331
+ super();
2332
+ proto3.util.initPartial(data, this);
2333
+ }
2334
+ static runtime = proto3;
2335
+ static typeName = "transcodely.v1.PricingEntry";
2336
+ static fields = proto3.util.newFieldList(() => [
2337
+ {
2338
+ no: 1,
2339
+ name: "rule_type",
2340
+ kind: "scalar",
2341
+ T: 9
2342
+ /* ScalarType.STRING */
2343
+ },
2344
+ {
2345
+ no: 2,
2346
+ name: "rule_key",
2347
+ kind: "scalar",
2348
+ T: 9
2349
+ /* ScalarType.STRING */
2350
+ },
2351
+ {
2352
+ no: 3,
2353
+ name: "label",
2354
+ kind: "scalar",
2355
+ T: 9
2356
+ /* ScalarType.STRING */
2357
+ },
2358
+ {
2359
+ no: 4,
2360
+ name: "group_label",
2361
+ kind: "scalar",
2362
+ T: 9
2363
+ /* ScalarType.STRING */
2364
+ },
2365
+ {
2366
+ no: 5,
2367
+ name: "unit",
2368
+ kind: "scalar",
2369
+ T: 9
2370
+ /* ScalarType.STRING */
2371
+ },
2372
+ { no: 6, name: "base_price", kind: "scalar", T: 1, opt: true },
2373
+ { no: 7, name: "multiplier", kind: "scalar", T: 1, opt: true },
2374
+ {
2375
+ no: 8,
2376
+ name: "custom",
2377
+ kind: "scalar",
2378
+ T: 8
2379
+ /* ScalarType.BOOL */
2380
+ },
2381
+ { no: 9, name: "list_base_price", kind: "scalar", T: 1, opt: true },
2382
+ { no: 10, name: "list_multiplier", kind: "scalar", T: 1, opt: true }
2383
+ ]);
2384
+ static fromBinary(bytes, options) {
2385
+ return new _PricingEntry().fromBinary(bytes, options);
2386
+ }
2387
+ static fromJson(jsonValue, options) {
2388
+ return new _PricingEntry().fromJson(jsonValue, options);
2389
+ }
2390
+ static fromJsonString(jsonString, options) {
2391
+ return new _PricingEntry().fromJsonString(jsonString, options);
2392
+ }
2393
+ static equals(a, b) {
2394
+ return proto3.util.equals(_PricingEntry, a, b);
2395
+ }
2396
+ };
2397
+ var GetPricingResponse = class _GetPricingResponse extends Message {
2398
+ /**
2399
+ * The app these prices are for.
2400
+ *
2401
+ * @generated from field: string app_id = 1;
2402
+ */
2403
+ appId = "";
2404
+ /**
2405
+ * Currency of every price. Always "EUR".
2406
+ *
2407
+ * @generated from field: string currency = 2;
2408
+ */
2409
+ currency = "";
2410
+ /**
2411
+ * Every chargeable item, grouped by class in display order.
2412
+ *
2413
+ * @generated from field: repeated transcodely.v1.PricingEntry entries = 3;
2414
+ */
2415
+ entries = [];
2416
+ constructor(data) {
2417
+ super();
2418
+ proto3.util.initPartial(data, this);
2419
+ }
2420
+ static runtime = proto3;
2421
+ static typeName = "transcodely.v1.GetPricingResponse";
2422
+ static fields = proto3.util.newFieldList(() => [
2423
+ {
2424
+ no: 1,
2425
+ name: "app_id",
2426
+ kind: "scalar",
2427
+ T: 9
2428
+ /* ScalarType.STRING */
2429
+ },
2430
+ {
2431
+ no: 2,
2432
+ name: "currency",
2433
+ kind: "scalar",
2434
+ T: 9
2435
+ /* ScalarType.STRING */
2436
+ },
2437
+ { no: 3, name: "entries", kind: "message", T: PricingEntry, repeated: true }
2438
+ ]);
2439
+ static fromBinary(bytes, options) {
2440
+ return new _GetPricingResponse().fromBinary(bytes, options);
2441
+ }
2442
+ static fromJson(jsonValue, options) {
2443
+ return new _GetPricingResponse().fromJson(jsonValue, options);
2444
+ }
2445
+ static fromJsonString(jsonString, options) {
2446
+ return new _GetPricingResponse().fromJsonString(jsonString, options);
2447
+ }
2448
+ static equals(a, b) {
2449
+ return proto3.util.equals(_GetPricingResponse, a, b);
2450
+ }
2451
+ };
2229
2452
  var AppService = {
2230
2453
  typeName: "transcodely.v1.AppService",
2231
2454
  methods: {
@@ -2348,6 +2571,18 @@ var AppService = {
2348
2571
  I: GetSpendRequest,
2349
2572
  O: GetSpendResponse,
2350
2573
  kind: MethodKind.Unary
2574
+ },
2575
+ /**
2576
+ * Get the prices an app pays: every chargeable item with its effective rate,
2577
+ * whether the account has a custom rate for it, and the public list price.
2578
+ *
2579
+ * @generated from rpc transcodely.v1.AppService.GetPricing
2580
+ */
2581
+ getPricing: {
2582
+ name: "GetPricing",
2583
+ I: GetPricingRequest,
2584
+ O: GetPricingResponse,
2585
+ kind: MethodKind.Unary
2351
2586
  }
2352
2587
  }
2353
2588
  };
@@ -2472,6 +2707,21 @@ var Apps = class {
2472
2707
  opts
2473
2708
  );
2474
2709
  }
2710
+ /**
2711
+ * Get the prices an app pays: every chargeable item with its effective EUR
2712
+ * rate, whether the account has a custom rate for it (`custom`), and the
2713
+ * public list price. Omit `id` to price the API key's own app (dashboard
2714
+ * callers: the organization's first active app). Prices are fixed when a job is
2715
+ * created, so a price change applies to jobs created after it.
2716
+ */
2717
+ getPricing(id, opts) {
2718
+ return this.transport.unary(
2719
+ AppService,
2720
+ AppService.methods.getPricing,
2721
+ new GetPricingRequest(id ? { appId: id } : {}),
2722
+ opts
2723
+ );
2724
+ }
2475
2725
  };
2476
2726
  var InvoiceStatus = /* @__PURE__ */ ((InvoiceStatus2) => {
2477
2727
  InvoiceStatus2[InvoiceStatus2["UNSPECIFIED"] = 0] = "UNSPECIFIED";
@@ -7053,6 +7303,9 @@ proto3.util.setEnumType(ToneMapping, "transcodely.v1.ToneMapping", [
7053
7303
  var HDRConfig = class _HDRConfig extends Message {
7054
7304
  /**
7055
7305
  * Target HDR format (required for passthrough and force modes).
7306
+ * `dolby_vision_5` and `dolby_vision_8` are refused at create until the
7307
+ * worker produces Dolby Vision output; a refused request creates no job and
7308
+ * is neither quoted nor billed.
7056
7309
  *
7057
7310
  * @generated from field: transcodely.v1.HDRFormat format = 1;
7058
7311
  */
@@ -7091,7 +7344,9 @@ var HDRConfig = class _HDRConfig extends Message {
7091
7344
  */
7092
7345
  contentLightLevel;
7093
7346
  /**
7094
- * Dolby Vision RPU file URL (for DV metadata injection).
7347
+ * Dolby Vision RPU file URL. Only accepted with a `dolby_vision_*` format,
7348
+ * which is refused at create until the worker produces Dolby Vision output,
7349
+ * so this field is currently unreachable.
7095
7350
  *
7096
7351
  * @generated from field: optional string rpu_url = 7;
7097
7352
  */
@@ -11828,6 +12083,10 @@ var OutputSpec = class _OutputSpec extends Message {
11828
12083
  * Encoding mode: "fixed" (default, static CRF) or "auto" (input-aware constrained CRF).
11829
12084
  * In "auto" mode, the worker caps each variant's bitrate based on the input's bitrate
11830
12085
  * and resolution ratio, preventing output from exceeding the input's quality ceiling.
12086
+ * "auto" also skips any ABR rung larger than the source instead of upscaling it.
12087
+ * A skipped rung is reported with status "skipped" and is not billed.
12088
+ * Outputs created since 2026-10-27 echo the resolved mode on responses (unset
12089
+ * resolves to "fixed"). Outputs created before then omit it: their mode was not stored.
11831
12090
  *
11832
12091
  * @generated from field: optional string encoding_mode = 14;
11833
12092
  */
@@ -12136,7 +12395,10 @@ var VariantPricingSnapshot = class _VariantPricingSnapshot extends Message {
12136
12395
  */
12137
12396
  actualCost;
12138
12397
  /**
12139
- * Variant encoding status: "pending", "processing", "completed", "failed".
12398
+ * Variant encoding status: "pending", "processing", "completed", "failed",
12399
+ * "canceled", or "skipped". A rung is "skipped" when `encoding_mode: auto`
12400
+ * left it unencoded because it would have upscaled the source. A skipped
12401
+ * rung has actual_cost 0 and is not billed.
12140
12402
  *
12141
12403
  * @generated from field: string status = 20;
12142
12404
  */
@@ -17075,6 +17337,13 @@ var UsageSummary = class _UsageSummary extends Message {
17075
17337
  */
17076
17338
  storageGbAvg = 0;
17077
17339
  /**
17340
+ * Storage cost of the period so far, as your invoice will carry it. Each
17341
+ * day is one GB-day: the day's stored bytes at the day's monthly price
17342
+ * divided by the days in that month. Days already billed are reported at
17343
+ * the rate they were billed at, so a later price or rate-card change never
17344
+ * re-prices them; the remaining days (see hosting_estimated_from) are
17345
+ * estimated the same way at your current rate.
17346
+ *
17078
17347
  * @generated from field: double storage_cost = 11;
17079
17348
  */
17080
17349
  storageCost = 0;
@@ -17089,6 +17358,10 @@ var UsageSummary = class _UsageSummary extends Message {
17089
17358
  */
17090
17359
  egressGb = 0;
17091
17360
  /**
17361
+ * Delivery cost of the period so far, as your invoice will carry it:
17362
+ * billed delivery at the rate it was billed at, delivery not billed yet
17363
+ * estimated at your current rate.
17364
+ *
17092
17365
  * @generated from field: double egress_cost = 21;
17093
17366
  */
17094
17367
  egressCost = 0;
@@ -17108,6 +17381,18 @@ var UsageSummary = class _UsageSummary extends Message {
17108
17381
  * @generated from field: string currency = 31;
17109
17382
  */
17110
17383
  currency = "";
17384
+ /**
17385
+ * First day (YYYY-MM-DD, UTC) whose storage or delivery cost is an
17386
+ * estimate rather than billed usage. Hosting is billed daily, through the
17387
+ * previous day, so while you store or deliver video the current period has
17388
+ * an estimated tail, and the estimate turns into the billed amount as each
17389
+ * day is billed. Empty when no day with hosting usage in the period is
17390
+ * still unbilled, which is when storage_cost and egress_cost match your
17391
+ * invoice (to within the sub-cent remainder carried to the next charge).
17392
+ *
17393
+ * @generated from field: string hosting_estimated_from = 32;
17394
+ */
17395
+ hostingEstimatedFrom = "";
17111
17396
  /**
17112
17397
  * Per-day usage breakdown for the billing period identified by
17113
17398
  * billing_month, oldest day first. With a billing anchor day other than 1,
@@ -17212,6 +17497,13 @@ var UsageSummary = class _UsageSummary extends Message {
17212
17497
  T: 9
17213
17498
  /* ScalarType.STRING */
17214
17499
  },
17500
+ {
17501
+ no: 32,
17502
+ name: "hosting_estimated_from",
17503
+ kind: "scalar",
17504
+ T: 9
17505
+ /* ScalarType.STRING */
17506
+ },
17215
17507
  { no: 40, name: "daily", kind: "message", T: DailyUsage, repeated: true }
17216
17508
  ]);
17217
17509
  static fromBinary(bytes, options) {
@@ -20150,7 +20442,7 @@ function backoff(attempt) {
20150
20442
  }
20151
20443
 
20152
20444
  // src/version.ts
20153
- var SDK_VERSION = "0.3.13";
20445
+ var SDK_VERSION = "0.3.15";
20154
20446
  var API_VERSION = "2026-05-03";
20155
20447
  var DEFAULT_BASE_URL = "https://api.transcodely.com";
20156
20448