@transcodely/sdk 0.3.13 → 0.3.14
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/CHANGELOG.md +8 -0
- package/README.md +21 -1
- package/dist/index.cjs +250 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +155 -2
- package/dist/index.d.ts +155 -2
- package/dist/index.mjs +250 -1
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -2226,6 +2226,228 @@ var GetSpendResponse = class _GetSpendResponse extends Message {
|
|
|
2226
2226
|
return proto3.util.equals(_GetSpendResponse, a, b);
|
|
2227
2227
|
}
|
|
2228
2228
|
};
|
|
2229
|
+
var GetPricingRequest = class _GetPricingRequest extends Message {
|
|
2230
|
+
/**
|
|
2231
|
+
* App ID. API-key callers may omit it or pass their own app; a different app
|
|
2232
|
+
* is rejected with PermissionDenied. Dashboard callers pass it to pick an app
|
|
2233
|
+
* in their organization; omitted selects the organization's first active
|
|
2234
|
+
* app in list order (the same default every app-scoped read uses).
|
|
2235
|
+
*
|
|
2236
|
+
* @generated from field: optional string app_id = 1;
|
|
2237
|
+
*/
|
|
2238
|
+
appId;
|
|
2239
|
+
constructor(data) {
|
|
2240
|
+
super();
|
|
2241
|
+
proto3.util.initPartial(data, this);
|
|
2242
|
+
}
|
|
2243
|
+
static runtime = proto3;
|
|
2244
|
+
static typeName = "transcodely.v1.GetPricingRequest";
|
|
2245
|
+
static fields = proto3.util.newFieldList(() => [
|
|
2246
|
+
{ no: 1, name: "app_id", kind: "scalar", T: 9, opt: true }
|
|
2247
|
+
]);
|
|
2248
|
+
static fromBinary(bytes, options) {
|
|
2249
|
+
return new _GetPricingRequest().fromBinary(bytes, options);
|
|
2250
|
+
}
|
|
2251
|
+
static fromJson(jsonValue, options) {
|
|
2252
|
+
return new _GetPricingRequest().fromJson(jsonValue, options);
|
|
2253
|
+
}
|
|
2254
|
+
static fromJsonString(jsonString, options) {
|
|
2255
|
+
return new _GetPricingRequest().fromJsonString(jsonString, options);
|
|
2256
|
+
}
|
|
2257
|
+
static equals(a, b) {
|
|
2258
|
+
return proto3.util.equals(_GetPricingRequest, a, b);
|
|
2259
|
+
}
|
|
2260
|
+
};
|
|
2261
|
+
var PricingEntry = class _PricingEntry extends Message {
|
|
2262
|
+
/**
|
|
2263
|
+
* Charge class: codec, resolution, quality, feature, fee, storage, egress.
|
|
2264
|
+
* Other values may appear as new charges are introduced.
|
|
2265
|
+
*
|
|
2266
|
+
* @generated from field: string rule_type = 1;
|
|
2267
|
+
*/
|
|
2268
|
+
ruleType = "";
|
|
2269
|
+
/**
|
|
2270
|
+
* Charge within its class, e.g. h264, 1080p, captions, processing_m.
|
|
2271
|
+
*
|
|
2272
|
+
* @generated from field: string rule_key = 2;
|
|
2273
|
+
*/
|
|
2274
|
+
ruleKey = "";
|
|
2275
|
+
/**
|
|
2276
|
+
* Human label, e.g. "H.264".
|
|
2277
|
+
*
|
|
2278
|
+
* @generated from field: string label = 3;
|
|
2279
|
+
*/
|
|
2280
|
+
label = "";
|
|
2281
|
+
/**
|
|
2282
|
+
* Human label of the class, e.g. "Encoding".
|
|
2283
|
+
*
|
|
2284
|
+
* @generated from field: string group_label = 4;
|
|
2285
|
+
*/
|
|
2286
|
+
groupLabel = "";
|
|
2287
|
+
/**
|
|
2288
|
+
* What base_price is per: eur_per_output_minute, eur_per_source_minute,
|
|
2289
|
+
* eur_per_video, eur_per_job, eur_per_gb_month, eur_per_gb, or eur_per_unit
|
|
2290
|
+
* for a charge whose unit is not known yet. Empty for a charge that has only
|
|
2291
|
+
* a multiplier.
|
|
2292
|
+
*
|
|
2293
|
+
* @generated from field: string unit = 5;
|
|
2294
|
+
*/
|
|
2295
|
+
unit = "";
|
|
2296
|
+
/**
|
|
2297
|
+
* The price per unit, in EUR, this app pays. Absent for a charge that has
|
|
2298
|
+
* only a multiplier.
|
|
2299
|
+
*
|
|
2300
|
+
* @generated from field: optional double base_price = 6;
|
|
2301
|
+
*/
|
|
2302
|
+
basePrice;
|
|
2303
|
+
/**
|
|
2304
|
+
* The multiplier this app pays. Absent for a charge that has only a per-unit
|
|
2305
|
+
* price.
|
|
2306
|
+
*
|
|
2307
|
+
* @generated from field: optional double multiplier = 7;
|
|
2308
|
+
*/
|
|
2309
|
+
multiplier;
|
|
2310
|
+
/**
|
|
2311
|
+
* True when this account has a custom rate for this charge, so base_price or
|
|
2312
|
+
* multiplier differs from the list price.
|
|
2313
|
+
*
|
|
2314
|
+
* @generated from field: bool custom = 8;
|
|
2315
|
+
*/
|
|
2316
|
+
custom = false;
|
|
2317
|
+
/**
|
|
2318
|
+
* The public list price per unit, in EUR. Absent when base_price is.
|
|
2319
|
+
*
|
|
2320
|
+
* @generated from field: optional double list_base_price = 9;
|
|
2321
|
+
*/
|
|
2322
|
+
listBasePrice;
|
|
2323
|
+
/**
|
|
2324
|
+
* The public list multiplier. Absent when multiplier is.
|
|
2325
|
+
*
|
|
2326
|
+
* @generated from field: optional double list_multiplier = 10;
|
|
2327
|
+
*/
|
|
2328
|
+
listMultiplier;
|
|
2329
|
+
constructor(data) {
|
|
2330
|
+
super();
|
|
2331
|
+
proto3.util.initPartial(data, this);
|
|
2332
|
+
}
|
|
2333
|
+
static runtime = proto3;
|
|
2334
|
+
static typeName = "transcodely.v1.PricingEntry";
|
|
2335
|
+
static fields = proto3.util.newFieldList(() => [
|
|
2336
|
+
{
|
|
2337
|
+
no: 1,
|
|
2338
|
+
name: "rule_type",
|
|
2339
|
+
kind: "scalar",
|
|
2340
|
+
T: 9
|
|
2341
|
+
/* ScalarType.STRING */
|
|
2342
|
+
},
|
|
2343
|
+
{
|
|
2344
|
+
no: 2,
|
|
2345
|
+
name: "rule_key",
|
|
2346
|
+
kind: "scalar",
|
|
2347
|
+
T: 9
|
|
2348
|
+
/* ScalarType.STRING */
|
|
2349
|
+
},
|
|
2350
|
+
{
|
|
2351
|
+
no: 3,
|
|
2352
|
+
name: "label",
|
|
2353
|
+
kind: "scalar",
|
|
2354
|
+
T: 9
|
|
2355
|
+
/* ScalarType.STRING */
|
|
2356
|
+
},
|
|
2357
|
+
{
|
|
2358
|
+
no: 4,
|
|
2359
|
+
name: "group_label",
|
|
2360
|
+
kind: "scalar",
|
|
2361
|
+
T: 9
|
|
2362
|
+
/* ScalarType.STRING */
|
|
2363
|
+
},
|
|
2364
|
+
{
|
|
2365
|
+
no: 5,
|
|
2366
|
+
name: "unit",
|
|
2367
|
+
kind: "scalar",
|
|
2368
|
+
T: 9
|
|
2369
|
+
/* ScalarType.STRING */
|
|
2370
|
+
},
|
|
2371
|
+
{ no: 6, name: "base_price", kind: "scalar", T: 1, opt: true },
|
|
2372
|
+
{ no: 7, name: "multiplier", kind: "scalar", T: 1, opt: true },
|
|
2373
|
+
{
|
|
2374
|
+
no: 8,
|
|
2375
|
+
name: "custom",
|
|
2376
|
+
kind: "scalar",
|
|
2377
|
+
T: 8
|
|
2378
|
+
/* ScalarType.BOOL */
|
|
2379
|
+
},
|
|
2380
|
+
{ no: 9, name: "list_base_price", kind: "scalar", T: 1, opt: true },
|
|
2381
|
+
{ no: 10, name: "list_multiplier", kind: "scalar", T: 1, opt: true }
|
|
2382
|
+
]);
|
|
2383
|
+
static fromBinary(bytes, options) {
|
|
2384
|
+
return new _PricingEntry().fromBinary(bytes, options);
|
|
2385
|
+
}
|
|
2386
|
+
static fromJson(jsonValue, options) {
|
|
2387
|
+
return new _PricingEntry().fromJson(jsonValue, options);
|
|
2388
|
+
}
|
|
2389
|
+
static fromJsonString(jsonString, options) {
|
|
2390
|
+
return new _PricingEntry().fromJsonString(jsonString, options);
|
|
2391
|
+
}
|
|
2392
|
+
static equals(a, b) {
|
|
2393
|
+
return proto3.util.equals(_PricingEntry, a, b);
|
|
2394
|
+
}
|
|
2395
|
+
};
|
|
2396
|
+
var GetPricingResponse = class _GetPricingResponse extends Message {
|
|
2397
|
+
/**
|
|
2398
|
+
* The app these prices are for.
|
|
2399
|
+
*
|
|
2400
|
+
* @generated from field: string app_id = 1;
|
|
2401
|
+
*/
|
|
2402
|
+
appId = "";
|
|
2403
|
+
/**
|
|
2404
|
+
* Currency of every price. Always "EUR".
|
|
2405
|
+
*
|
|
2406
|
+
* @generated from field: string currency = 2;
|
|
2407
|
+
*/
|
|
2408
|
+
currency = "";
|
|
2409
|
+
/**
|
|
2410
|
+
* Every chargeable item, grouped by class in display order.
|
|
2411
|
+
*
|
|
2412
|
+
* @generated from field: repeated transcodely.v1.PricingEntry entries = 3;
|
|
2413
|
+
*/
|
|
2414
|
+
entries = [];
|
|
2415
|
+
constructor(data) {
|
|
2416
|
+
super();
|
|
2417
|
+
proto3.util.initPartial(data, this);
|
|
2418
|
+
}
|
|
2419
|
+
static runtime = proto3;
|
|
2420
|
+
static typeName = "transcodely.v1.GetPricingResponse";
|
|
2421
|
+
static fields = proto3.util.newFieldList(() => [
|
|
2422
|
+
{
|
|
2423
|
+
no: 1,
|
|
2424
|
+
name: "app_id",
|
|
2425
|
+
kind: "scalar",
|
|
2426
|
+
T: 9
|
|
2427
|
+
/* ScalarType.STRING */
|
|
2428
|
+
},
|
|
2429
|
+
{
|
|
2430
|
+
no: 2,
|
|
2431
|
+
name: "currency",
|
|
2432
|
+
kind: "scalar",
|
|
2433
|
+
T: 9
|
|
2434
|
+
/* ScalarType.STRING */
|
|
2435
|
+
},
|
|
2436
|
+
{ no: 3, name: "entries", kind: "message", T: PricingEntry, repeated: true }
|
|
2437
|
+
]);
|
|
2438
|
+
static fromBinary(bytes, options) {
|
|
2439
|
+
return new _GetPricingResponse().fromBinary(bytes, options);
|
|
2440
|
+
}
|
|
2441
|
+
static fromJson(jsonValue, options) {
|
|
2442
|
+
return new _GetPricingResponse().fromJson(jsonValue, options);
|
|
2443
|
+
}
|
|
2444
|
+
static fromJsonString(jsonString, options) {
|
|
2445
|
+
return new _GetPricingResponse().fromJsonString(jsonString, options);
|
|
2446
|
+
}
|
|
2447
|
+
static equals(a, b) {
|
|
2448
|
+
return proto3.util.equals(_GetPricingResponse, a, b);
|
|
2449
|
+
}
|
|
2450
|
+
};
|
|
2229
2451
|
var AppService = {
|
|
2230
2452
|
typeName: "transcodely.v1.AppService",
|
|
2231
2453
|
methods: {
|
|
@@ -2348,6 +2570,18 @@ var AppService = {
|
|
|
2348
2570
|
I: GetSpendRequest,
|
|
2349
2571
|
O: GetSpendResponse,
|
|
2350
2572
|
kind: MethodKind.Unary
|
|
2573
|
+
},
|
|
2574
|
+
/**
|
|
2575
|
+
* Get the prices an app pays: every chargeable item with its effective rate,
|
|
2576
|
+
* whether the account has a custom rate for it, and the public list price.
|
|
2577
|
+
*
|
|
2578
|
+
* @generated from rpc transcodely.v1.AppService.GetPricing
|
|
2579
|
+
*/
|
|
2580
|
+
getPricing: {
|
|
2581
|
+
name: "GetPricing",
|
|
2582
|
+
I: GetPricingRequest,
|
|
2583
|
+
O: GetPricingResponse,
|
|
2584
|
+
kind: MethodKind.Unary
|
|
2351
2585
|
}
|
|
2352
2586
|
}
|
|
2353
2587
|
};
|
|
@@ -2472,6 +2706,21 @@ var Apps = class {
|
|
|
2472
2706
|
opts
|
|
2473
2707
|
);
|
|
2474
2708
|
}
|
|
2709
|
+
/**
|
|
2710
|
+
* Get the prices an app pays: every chargeable item with its effective EUR
|
|
2711
|
+
* rate, whether the account has a custom rate for it (`custom`), and the
|
|
2712
|
+
* public list price. Omit `id` to price the API key's own app (dashboard
|
|
2713
|
+
* callers: the organization's first active app). Prices are fixed when a job is
|
|
2714
|
+
* created, so a price change applies to jobs created after it.
|
|
2715
|
+
*/
|
|
2716
|
+
getPricing(id, opts) {
|
|
2717
|
+
return this.transport.unary(
|
|
2718
|
+
AppService,
|
|
2719
|
+
AppService.methods.getPricing,
|
|
2720
|
+
new GetPricingRequest(id ? { appId: id } : {}),
|
|
2721
|
+
opts
|
|
2722
|
+
);
|
|
2723
|
+
}
|
|
2475
2724
|
};
|
|
2476
2725
|
var InvoiceStatus = /* @__PURE__ */ ((InvoiceStatus2) => {
|
|
2477
2726
|
InvoiceStatus2[InvoiceStatus2["UNSPECIFIED"] = 0] = "UNSPECIFIED";
|
|
@@ -20150,7 +20399,7 @@ function backoff(attempt) {
|
|
|
20150
20399
|
}
|
|
20151
20400
|
|
|
20152
20401
|
// src/version.ts
|
|
20153
|
-
var SDK_VERSION = "0.3.
|
|
20402
|
+
var SDK_VERSION = "0.3.14";
|
|
20154
20403
|
var API_VERSION = "2026-05-03";
|
|
20155
20404
|
var DEFAULT_BASE_URL = "https://api.transcodely.com";
|
|
20156
20405
|
|