@remotion/lambda 3.0.0-lambda.208 → 3.0.0-lambda.288
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/api/create-function.d.ts +3 -2
- package/dist/api/create-function.d.ts.map +1 -1
- package/dist/api/create-function.js +16 -5
- package/dist/api/create-function.js.map +1 -1
- package/dist/api/delete-function.d.ts +7 -6
- package/dist/api/delete-function.d.ts.map +1 -1
- package/dist/api/delete-function.js +2 -2
- package/dist/api/delete-function.js.map +1 -1
- package/dist/api/delete-site.d.ts +5 -5
- package/dist/api/delete-site.d.ts.map +1 -1
- package/dist/api/delete-site.js +2 -2
- package/dist/api/delete-site.js.map +1 -1
- package/dist/api/deploy-function.d.ts +13 -10
- package/dist/api/deploy-function.d.ts.map +1 -1
- package/dist/api/deploy-function.js +8 -9
- package/dist/api/deploy-function.js.map +1 -1
- package/dist/api/deploy-site.d.ts +3 -3
- package/dist/api/deploy-site.d.ts.map +1 -1
- package/dist/api/deploy-site.js +4 -2
- package/dist/api/deploy-site.js.map +1 -1
- package/dist/api/download-media.d.ts +19 -0
- package/dist/api/download-media.d.ts.map +1 -0
- package/dist/api/download-media.js +55 -0
- package/dist/api/download-media.js.map +1 -0
- package/dist/api/download-video.d.ts +7 -3
- package/dist/api/download-video.d.ts.map +1 -1
- package/dist/api/download-video.js +7 -3
- package/dist/api/download-video.js.map +1 -1
- package/dist/api/enable-s3-website.d.ts.map +1 -1
- package/dist/api/enable-s3-website.js +0 -1
- package/dist/api/enable-s3-website.js.map +1 -1
- package/dist/api/estimate-price.d.ts +14 -0
- package/dist/api/estimate-price.d.ts.map +1 -0
- package/dist/api/estimate-price.js +34 -0
- package/dist/api/estimate-price.js.map +1 -0
- package/dist/api/get-buckets.d.ts.map +1 -1
- package/dist/api/get-buckets.js +1 -7
- package/dist/api/get-buckets.js.map +1 -1
- package/dist/api/get-function-info.d.ts +3 -4
- package/dist/api/get-function-info.d.ts.map +1 -1
- package/dist/api/get-function-info.js +1 -1
- package/dist/api/get-function-info.js.map +1 -1
- package/dist/api/get-functions.d.ts +7 -6
- package/dist/api/get-functions.d.ts.map +1 -1
- package/dist/api/get-functions.js +2 -2
- package/dist/api/get-functions.js.map +1 -1
- package/dist/api/get-or-create-bucket.d.ts +5 -6
- package/dist/api/get-or-create-bucket.d.ts.map +1 -1
- package/dist/api/get-or-create-bucket.js +2 -2
- package/dist/api/get-or-create-bucket.js.map +1 -1
- package/dist/api/get-regions.d.ts +8 -0
- package/dist/api/get-regions.d.ts.map +1 -0
- package/dist/api/get-regions.js +14 -0
- package/dist/api/get-regions.js.map +1 -0
- package/dist/api/get-render-progress.d.ts +12 -10
- package/dist/api/get-render-progress.d.ts.map +1 -1
- package/dist/api/get-render-progress.js +4 -4
- package/dist/api/get-render-progress.js.map +1 -1
- package/dist/api/get-sites.d.ts +12 -4
- package/dist/api/get-sites.d.ts.map +1 -1
- package/dist/api/get-sites.js +8 -3
- package/dist/api/get-sites.js.map +1 -1
- package/dist/api/iam-validation/simulate.d.ts +13 -4
- package/dist/api/iam-validation/simulate.d.ts.map +1 -1
- package/dist/api/iam-validation/simulate.js +7 -0
- package/dist/api/iam-validation/simulate.js.map +1 -1
- package/dist/api/iam-validation/suggested-policy.d.ts +2 -2
- package/dist/api/iam-validation/suggested-policy.js +2 -2
- package/dist/api/render-media-on-lambda.d.ts +52 -0
- package/dist/api/render-media-on-lambda.d.ts.map +1 -0
- package/dist/api/render-media-on-lambda.js +64 -0
- package/dist/api/render-media-on-lambda.js.map +1 -0
- package/dist/api/render-still-on-lambda.d.ts +25 -22
- package/dist/api/render-still-on-lambda.d.ts.map +1 -1
- package/dist/api/render-still-on-lambda.js +3 -3
- package/dist/api/render-still-on-lambda.js.map +1 -1
- package/dist/api/render-video-on-lambda.d.ts +27 -1
- package/dist/api/render-video-on-lambda.d.ts.map +1 -1
- package/dist/api/render-video-on-lambda.js +9 -5
- package/dist/api/render-video-on-lambda.js.map +1 -1
- package/dist/cli/args.d.ts +0 -3
- package/dist/cli/args.d.ts.map +1 -1
- package/dist/cli/args.js +1 -3
- package/dist/cli/args.js.map +1 -1
- package/dist/cli/commands/functions/deploy.d.ts.map +1 -1
- package/dist/cli/commands/functions/deploy.js +14 -4
- package/dist/cli/commands/functions/deploy.js.map +1 -1
- package/dist/cli/commands/functions/index.d.ts.map +1 -1
- package/dist/cli/commands/functions/index.js +7 -0
- package/dist/cli/commands/functions/index.js.map +1 -1
- package/dist/cli/commands/functions/ls.d.ts.map +1 -1
- package/dist/cli/commands/functions/ls.js +4 -7
- package/dist/cli/commands/functions/ls.js.map +1 -1
- package/dist/cli/commands/functions/rm.d.ts.map +1 -1
- package/dist/cli/commands/functions/rm.js +2 -2
- package/dist/cli/commands/functions/rm.js.map +1 -1
- package/dist/cli/commands/functions/rmall.d.ts +3 -0
- package/dist/cli/commands/functions/rmall.d.ts.map +1 -0
- package/dist/cli/commands/functions/rmall.js +41 -0
- package/dist/cli/commands/functions/rmall.js.map +1 -0
- package/dist/cli/commands/regions.d.ts +3 -0
- package/dist/cli/commands/regions.d.ts.map +1 -0
- package/dist/cli/commands/regions.js +11 -0
- package/dist/cli/commands/regions.js.map +1 -0
- package/dist/cli/commands/render/render.d.ts.map +1 -1
- package/dist/cli/commands/render/render.js +7 -9
- package/dist/cli/commands/render/render.js.map +1 -1
- package/dist/cli/commands/sites/create.d.ts.map +1 -1
- package/dist/cli/commands/sites/create.js +10 -5
- package/dist/cli/commands/sites/create.js.map +1 -1
- package/dist/cli/commands/sites/index.d.ts.map +1 -1
- package/dist/cli/commands/sites/index.js +4 -0
- package/dist/cli/commands/sites/index.js.map +1 -1
- package/dist/cli/commands/sites/ls.d.ts.map +1 -1
- package/dist/cli/commands/sites/ls.js +8 -5
- package/dist/cli/commands/sites/ls.js.map +1 -1
- package/dist/cli/commands/sites/rm.d.ts.map +1 -1
- package/dist/cli/commands/sites/rm.js +11 -3
- package/dist/cli/commands/sites/rm.js.map +1 -1
- package/dist/cli/commands/sites/rmall.d.ts +3 -0
- package/dist/cli/commands/sites/rmall.d.ts.map +1 -0
- package/dist/cli/commands/sites/rmall.js +49 -0
- package/dist/cli/commands/sites/rmall.js.map +1 -0
- package/dist/cli/commands/still.d.ts.map +1 -1
- package/dist/cli/commands/still.js +31 -9
- package/dist/cli/commands/still.js.map +1 -1
- package/dist/cli/help.d.ts.map +1 -1
- package/dist/cli/help.js +9 -1
- package/dist/cli/help.js.map +1 -1
- package/dist/cli/index.d.ts.map +1 -1
- package/dist/cli/index.js +13 -3
- package/dist/cli/index.js.map +1 -1
- package/dist/cli/is-cli.d.ts +3 -0
- package/dist/cli/is-cli.d.ts.map +1 -0
- package/dist/cli/is-cli.js +11 -0
- package/dist/cli/is-cli.js.map +1 -0
- package/dist/client.d.ts +4 -4
- package/dist/client.d.ts.map +1 -1
- package/dist/client.js +8 -7
- package/dist/client.js.map +1 -1
- package/dist/functions/chunk-optimization/get-frame-ranges-from-profile.d.ts +4 -1
- package/dist/functions/chunk-optimization/get-frame-ranges-from-profile.d.ts.map +1 -1
- package/dist/functions/chunk-optimization/optimize-profile.d.ts +8 -2
- package/dist/functions/chunk-optimization/optimize-profile.d.ts.map +1 -1
- package/dist/functions/chunk-optimization/plan-frame-ranges.d.ts +4 -1
- package/dist/functions/chunk-optimization/plan-frame-ranges.d.ts.map +1 -1
- package/dist/functions/chunk-optimization/simulate-frame-ranges.d.ts +4 -1
- package/dist/functions/chunk-optimization/simulate-frame-ranges.d.ts.map +1 -1
- package/dist/functions/helpers/calculate-price-from-bucket.js +3 -3
- package/dist/functions/helpers/calculate-price-from-bucket.js.map +1 -1
- package/dist/functions/helpers/clean-tmpdir.d.ts.map +1 -1
- package/dist/functions/helpers/clean-tmpdir.js +0 -1
- package/dist/functions/helpers/clean-tmpdir.js.map +1 -1
- package/dist/functions/helpers/concat-videos.d.ts.map +1 -1
- package/dist/functions/helpers/concat-videos.js +4 -0
- package/dist/functions/helpers/concat-videos.js.map +1 -1
- package/dist/functions/helpers/create-post-render-data.d.ts +1 -1
- package/dist/functions/helpers/create-post-render-data.d.ts.map +1 -1
- package/dist/functions/helpers/create-post-render-data.js +2 -2
- package/dist/functions/helpers/create-post-render-data.js.map +1 -1
- package/dist/functions/helpers/delete-chunks.d.ts +1 -1
- package/dist/functions/helpers/delete-chunks.d.ts.map +1 -1
- package/dist/functions/helpers/delete-chunks.js.map +1 -1
- package/dist/functions/helpers/get-post-render-data.d.ts +1 -1
- package/dist/functions/helpers/get-post-render-data.d.ts.map +1 -1
- package/dist/functions/helpers/get-progress.d.ts +3 -2
- package/dist/functions/helpers/get-progress.d.ts.map +1 -1
- package/dist/functions/helpers/get-progress.js +25 -3
- package/dist/functions/helpers/get-progress.js.map +1 -1
- package/dist/functions/helpers/write-post-render-data.d.ts +1 -1
- package/dist/functions/helpers/write-post-render-data.d.ts.map +1 -1
- package/dist/functions/index.d.ts +1 -0
- package/dist/functions/index.d.ts.map +1 -1
- package/dist/functions/index.js +5 -1
- package/dist/functions/index.js.map +1 -1
- package/dist/functions/launch.d.ts.map +1 -1
- package/dist/functions/launch.js +8 -7
- package/dist/functions/launch.js.map +1 -1
- package/dist/functions/progress.d.ts +1 -0
- package/dist/functions/progress.d.ts.map +1 -1
- package/dist/functions/progress.js +1 -0
- package/dist/functions/progress.js.map +1 -1
- package/dist/functions/still.js +2 -2
- package/dist/functions/still.js.map +1 -1
- package/dist/index.d.ts +18 -17
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +11 -7
- package/dist/index.js.map +1 -1
- package/dist/pricing/calculate-price.d.ts +1 -1
- package/dist/pricing/calculate-price.js +1 -1
- package/dist/pricing/estimate-price.d.ts +15 -0
- package/dist/pricing/estimate-price.d.ts.map +1 -0
- package/dist/pricing/estimate-price.js +34 -0
- package/dist/pricing/estimate-price.js.map +1 -0
- package/dist/shared/aws-clients.d.ts +1 -0
- package/dist/shared/aws-clients.d.ts.map +1 -1
- package/dist/shared/aws-clients.js +59 -30
- package/dist/shared/aws-clients.js.map +1 -1
- package/dist/shared/check-credentials.d.ts.map +1 -1
- package/dist/shared/check-credentials.js +16 -4
- package/dist/shared/check-credentials.js.map +1 -1
- package/dist/shared/constants.d.ts +1 -1
- package/dist/shared/constants.d.ts.map +1 -1
- package/dist/shared/constants.js +1 -1
- package/dist/shared/constants.js.map +1 -1
- package/dist/shared/docs-url.d.ts +1 -1
- package/dist/shared/docs-url.d.ts.map +1 -1
- package/dist/shared/docs-url.js +1 -1
- package/dist/shared/docs-url.js.map +1 -1
- package/dist/shared/validate-frames-per-lambda.d.ts +2 -0
- package/dist/shared/validate-frames-per-lambda.d.ts.map +1 -0
- package/dist/shared/validate-frames-per-lambda.js +22 -0
- package/dist/shared/validate-frames-per-lambda.js.map +1 -0
- package/dist/shared/validate-site-name.d.ts +2 -0
- package/dist/shared/validate-site-name.d.ts.map +1 -0
- package/dist/shared/validate-site-name.js +12 -0
- package/dist/shared/validate-site-name.js.map +1 -0
- package/package.json +6 -6
- package/remotionlambda.zip +0 -0
- package/dist/api/convert-to-serve-url.d.ts +0 -2
- package/dist/api/convert-to-serve-url.d.ts.map +0 -1
- package/dist/api/convert-to-serve-url.js +0 -13
- package/dist/api/convert-to-serve-url.js.map +0 -1
- package/dist/api/validate-frames-per-lambda.d.ts +0 -2
- package/dist/api/validate-frames-per-lambda.d.ts.map +0 -1
- package/dist/api/validate-frames-per-lambda.js +0 -26
- package/dist/api/validate-frames-per-lambda.js.map +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"get-buckets.d.ts","sourceRoot":"","sources":["../../src/api/get-buckets.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,SAAS,EAAC,MAAM,wBAAwB,CAAC;AAIjD,oBAAY,kBAAkB,GAAG;IAChC,IAAI,EAAE,MAAM,CAAC;IACb,YAAY,EAAE,MAAM,CAAC;IACrB,MAAM,EAAE,SAAS,CAAC;CAClB,CAAC;
|
|
1
|
+
{"version":3,"file":"get-buckets.d.ts","sourceRoot":"","sources":["../../src/api/get-buckets.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,SAAS,EAAC,MAAM,wBAAwB,CAAC;AAIjD,oBAAY,kBAAkB,GAAG;IAChC,IAAI,EAAE,MAAM,CAAC;IACb,YAAY,EAAE,MAAM,CAAC;IACrB,MAAM,EAAE,SAAS,CAAC;CAClB,CAAC;AAEF,eAAO,MAAM,oBAAoB,WACxB,SAAS;qBAEA,kBAAkB,EAAE;EAoCrC,CAAC"}
|
package/dist/api/get-buckets.js
CHANGED
|
@@ -4,18 +4,12 @@ exports.getRemotionS3Buckets = void 0;
|
|
|
4
4
|
const client_s3_1 = require("@aws-sdk/client-s3");
|
|
5
5
|
const aws_clients_1 = require("../shared/aws-clients");
|
|
6
6
|
const constants_1 = require("../shared/constants");
|
|
7
|
-
// TODO: In the CLI, warn everytime this function gets called about more than 1 bucket.
|
|
8
7
|
const getRemotionS3Buckets = async (region) => {
|
|
9
8
|
const { Buckets } = await (0, aws_clients_1.getS3Client)(region).send(new client_s3_1.ListBucketsCommand({}));
|
|
10
9
|
if (!Buckets) {
|
|
11
10
|
return { remotionBuckets: [] };
|
|
12
11
|
}
|
|
13
|
-
const remotionBuckets = Buckets.filter((b) => {
|
|
14
|
-
var _a;
|
|
15
|
-
return ((_a = b.Name) === null || _a === void 0 ? void 0 : _a.startsWith(constants_1.REMOTION_BUCKET_PREFIX)) &&
|
|
16
|
-
// TODO: Rename other buckets in Jonnys account bucket first
|
|
17
|
-
!b.Name.startsWith('remotion-binaries');
|
|
18
|
-
});
|
|
12
|
+
const remotionBuckets = Buckets.filter((b) => { var _a; return (_a = b.Name) === null || _a === void 0 ? void 0 : _a.startsWith(constants_1.REMOTION_BUCKET_PREFIX); });
|
|
19
13
|
const locations = await Promise.all(remotionBuckets.map((bucket) => {
|
|
20
14
|
return (0, aws_clients_1.getS3Client)(region).send(new client_s3_1.GetBucketLocationCommand({
|
|
21
15
|
Bucket: bucket.Name,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"get-buckets.js","sourceRoot":"","sources":["../../src/api/get-buckets.ts"],"names":[],"mappings":";;;AAAA,kDAAgF;AAEhF,uDAAkD;AAClD,mDAA2D;
|
|
1
|
+
{"version":3,"file":"get-buckets.js","sourceRoot":"","sources":["../../src/api/get-buckets.ts"],"names":[],"mappings":";;;AAAA,kDAAgF;AAEhF,uDAAkD;AAClD,mDAA2D;AAQpD,MAAM,oBAAoB,GAAG,KAAK,EACxC,MAAiB,EAGf,EAAE;IACJ,MAAM,EAAC,OAAO,EAAC,GAAG,MAAM,IAAA,yBAAW,EAAC,MAAM,CAAC,CAAC,IAAI,CAAC,IAAI,8BAAkB,CAAC,EAAE,CAAC,CAAC,CAAC;IAC7E,IAAI,CAAC,OAAO,EAAE;QACb,OAAO,EAAC,eAAe,EAAE,EAAE,EAAC,CAAC;KAC7B;IAED,MAAM,eAAe,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,WAC5C,OAAA,MAAA,CAAC,CAAC,IAAI,0CAAE,UAAU,CAAC,kCAAsB,CAAC,CAAA,EAAA,CAC1C,CAAC;IAEF,MAAM,SAAS,GAAG,MAAM,OAAO,CAAC,GAAG,CAClC,eAAe,CAAC,GAAG,CAAC,CAAC,MAAM,EAAE,EAAE;QAC9B,OAAO,IAAA,yBAAW,EAAC,MAAM,CAAC,CAAC,IAAI,CAC9B,IAAI,oCAAwB,CAAC;YAC5B,MAAM,EAAE,MAAM,CAAC,IAAc;SAC7B,CAAC,CACF,CAAC;IACH,CAAC,CAAC,CACF,CAAC;IAEF,MAAM,mBAAmB,GAAG,eAAe,CAAC,GAAG,CAC9C,CAAC,MAAM,EAAE,CAAC,EAAsB,EAAE;;QACjC,OAAO;YACN,YAAY,EAAG,MAAM,CAAC,YAAqB,CAAC,OAAO,EAAE;YACrD,IAAI,EAAE,MAAM,CAAC,IAAc;YAC3B,4EAA4E;YAC5E,MAAM,EAAE,CAAC,MAAA,SAAS,CAAC,CAAC,CAAC,CAAC,kBAAkB,mCAAI,WAAW,CAAc;SACrE,CAAC;IACH,CAAC,CACD,CAAC;IACF,OAAO;QACN,eAAe,EAAE,mBAAmB,CAAC,MAAM,CAAC,CAAC,MAAM,EAAE,EAAE;YACtD,OAAO,MAAM,CAAC,MAAM,KAAK,MAAM,CAAC;QACjC,CAAC,CAAC;KACF,CAAC;AACH,CAAC,CAAC;AAvCW,QAAA,oBAAoB,wBAuC/B"}
|
|
@@ -6,17 +6,16 @@ export declare type FunctionInfo = {
|
|
|
6
6
|
memorySizeInMb: number;
|
|
7
7
|
version: LambdaVersions | null;
|
|
8
8
|
};
|
|
9
|
-
declare type
|
|
9
|
+
export declare type GetFunctionInfoInput = {
|
|
10
10
|
region: AwsRegion;
|
|
11
11
|
functionName: string;
|
|
12
12
|
};
|
|
13
13
|
/**
|
|
14
14
|
* @description Given a region and function name, returns information about the function such as version, memory size and timeout.
|
|
15
|
-
* @link https://remotion
|
|
15
|
+
* @link https://v3.remotion.dev/docs/lambda/getfunctioninfo
|
|
16
16
|
* @param {AwsRegion} options.region The region in which the function resides in.
|
|
17
17
|
* @param {string} options.functionName The name of the function
|
|
18
18
|
* @return {Promise<FunctionInfo>} Promise resolving to information about the function.
|
|
19
19
|
*/
|
|
20
|
-
export declare const getFunctionInfo: ({ region, functionName, }:
|
|
21
|
-
export {};
|
|
20
|
+
export declare const getFunctionInfo: ({ region, functionName, }: GetFunctionInfoInput) => Promise<FunctionInfo>;
|
|
22
21
|
//# sourceMappingURL=get-function-info.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"get-function-info.d.ts","sourceRoot":"","sources":["../../src/api/get-function-info.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,SAAS,EAAC,MAAM,wBAAwB,CAAC;AAEjD,OAAO,EAAC,cAAc,EAAC,MAAM,qBAAqB,CAAC;AAInD,oBAAY,YAAY,GAAG;IAC1B,YAAY,EAAE,MAAM,CAAC;IACrB,gBAAgB,EAAE,MAAM,CAAC;IACzB,cAAc,EAAE,MAAM,CAAC;IACvB,OAAO,EAAE,cAAc,GAAG,IAAI,CAAC;CAC/B,CAAC;AAEF,
|
|
1
|
+
{"version":3,"file":"get-function-info.d.ts","sourceRoot":"","sources":["../../src/api/get-function-info.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,SAAS,EAAC,MAAM,wBAAwB,CAAC;AAEjD,OAAO,EAAC,cAAc,EAAC,MAAM,qBAAqB,CAAC;AAInD,oBAAY,YAAY,GAAG;IAC1B,YAAY,EAAE,MAAM,CAAC;IACrB,gBAAgB,EAAE,MAAM,CAAC;IACzB,cAAc,EAAE,MAAM,CAAC;IACvB,OAAO,EAAE,cAAc,GAAG,IAAI,CAAC;CAC/B,CAAC;AAEF,oBAAY,oBAAoB,GAAG;IAClC,MAAM,EAAE,SAAS,CAAC;IAClB,YAAY,EAAE,MAAM,CAAC;CACrB,CAAC;AAEF;;;;;;GAMG;AACH,eAAO,MAAM,eAAe,8BAGzB,oBAAoB,KAAG,QAAQ,YAAY,CAqB7C,CAAC"}
|
|
@@ -7,7 +7,7 @@ const get_function_version_1 = require("../shared/get-function-version");
|
|
|
7
7
|
const validate_aws_region_1 = require("../shared/validate-aws-region");
|
|
8
8
|
/**
|
|
9
9
|
* @description Given a region and function name, returns information about the function such as version, memory size and timeout.
|
|
10
|
-
* @link https://remotion
|
|
10
|
+
* @link https://v3.remotion.dev/docs/lambda/getfunctioninfo
|
|
11
11
|
* @param {AwsRegion} options.region The region in which the function resides in.
|
|
12
12
|
* @param {string} options.functionName The name of the function
|
|
13
13
|
* @return {Promise<FunctionInfo>} Promise resolving to information about the function.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"get-function-info.js","sourceRoot":"","sources":["../../src/api/get-function-info.ts"],"names":[],"mappings":";;;AAAA,0DAA0D;AAE1D,uDAAsD;AAEtD,yEAAkE;AAClE,uEAAgE;AAchE;;;;;;GAMG;AACI,MAAM,eAAe,GAAG,KAAK,EAAE,EACrC,MAAM,EACN,YAAY,
|
|
1
|
+
{"version":3,"file":"get-function-info.js","sourceRoot":"","sources":["../../src/api/get-function-info.ts"],"names":[],"mappings":";;;AAAA,0DAA0D;AAE1D,uDAAsD;AAEtD,yEAAkE;AAClE,uEAAgE;AAchE;;;;;;GAMG;AACI,MAAM,eAAe,GAAG,KAAK,EAAE,EACrC,MAAM,EACN,YAAY,GACU,EAAyB,EAAE;;IACjD,IAAA,uCAAiB,EAAC,MAAM,CAAC,CAAC;IAE1B,MAAM,CAAC,YAAY,EAAE,OAAO,CAAC,GAAG,MAAM,OAAO,CAAC,GAAG,CAAC;QACjD,IAAA,6BAAe,EAAC,MAAM,CAAC,CAAC,IAAI,CAC3B,IAAI,kCAAkB,CAAC;YACtB,YAAY,EAAE,YAAY;SAC1B,CAAC,CACF;QACD,IAAA,yCAAkB,EAAC;YAClB,YAAY;YACZ,MAAM;SACN,CAAC;KACF,CAAC,CAAC;IAEH,OAAO;QACN,YAAY;QACZ,gBAAgB,EAAE,MAAA,YAAY,CAAC,aAAa,0CAAE,OAAiB;QAC/D,cAAc,EAAE,MAAA,YAAY,CAAC,aAAa,0CAAE,UAAoB;QAChE,OAAO;KACP,CAAC;AACH,CAAC,CAAC;AAxBW,QAAA,eAAe,mBAwB1B"}
|
|
@@ -1,16 +1,17 @@
|
|
|
1
1
|
import { AwsRegion } from '../pricing/aws-regions';
|
|
2
2
|
import { FunctionInfo } from './get-function-info';
|
|
3
|
+
export declare type GetFunctionsInput = {
|
|
4
|
+
region: AwsRegion;
|
|
5
|
+
compatibleOnly: boolean;
|
|
6
|
+
};
|
|
3
7
|
/**
|
|
4
8
|
*
|
|
5
9
|
*
|
|
6
10
|
* @description Lists Remotion Lambda render functions deployed to AWS Lambda.
|
|
7
|
-
* @link https://remotion
|
|
11
|
+
* @link https://v3.remotion.dev/docs/lambda/getfunctions
|
|
8
12
|
* @param options.region The region of which the functions should be listed.
|
|
9
13
|
* @param options.compatibleOnly Whether only functions compatible with the installed version of Remotion Lambda should be returned.
|
|
10
|
-
* @returns An array with the objects containing information about the deployed functions.
|
|
14
|
+
* @returns {Promise<FunctionInfo[]>} An array with the objects containing information about the deployed functions.
|
|
11
15
|
*/
|
|
12
|
-
export declare const getFunctions: (options:
|
|
13
|
-
region: AwsRegion;
|
|
14
|
-
compatibleOnly: boolean;
|
|
15
|
-
}) => Promise<FunctionInfo[]>;
|
|
16
|
+
export declare const getFunctions: (options: GetFunctionsInput) => Promise<FunctionInfo[]>;
|
|
16
17
|
//# sourceMappingURL=get-functions.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"get-functions.d.ts","sourceRoot":"","sources":["../../src/api/get-functions.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,SAAS,EAAC,MAAM,wBAAwB,CAAC;AAIjD,OAAO,EAAC,YAAY,EAAC,MAAM,qBAAqB,CAAC;AAEjD
|
|
1
|
+
{"version":3,"file":"get-functions.d.ts","sourceRoot":"","sources":["../../src/api/get-functions.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,SAAS,EAAC,MAAM,wBAAwB,CAAC;AAIjD,OAAO,EAAC,YAAY,EAAC,MAAM,qBAAqB,CAAC;AAEjD,oBAAY,iBAAiB,GAAG;IAC/B,MAAM,EAAE,SAAS,CAAC;IAClB,cAAc,EAAE,OAAO,CAAC;CACxB,CAAC;AAEF;;;;;;;;GAQG;AACH,eAAO,MAAM,YAAY,YACf,iBAAiB,KACxB,QAAQ,YAAY,EAAE,CA0CxB,CAAC"}
|
|
@@ -9,10 +9,10 @@ const get_function_version_1 = require("../shared/get-function-version");
|
|
|
9
9
|
*
|
|
10
10
|
*
|
|
11
11
|
* @description Lists Remotion Lambda render functions deployed to AWS Lambda.
|
|
12
|
-
* @link https://remotion
|
|
12
|
+
* @link https://v3.remotion.dev/docs/lambda/getfunctions
|
|
13
13
|
* @param options.region The region of which the functions should be listed.
|
|
14
14
|
* @param options.compatibleOnly Whether only functions compatible with the installed version of Remotion Lambda should be returned.
|
|
15
|
-
* @returns An array with the objects containing information about the deployed functions.
|
|
15
|
+
* @returns {Promise<FunctionInfo[]>} An array with the objects containing information about the deployed functions.
|
|
16
16
|
*/
|
|
17
17
|
const getFunctions = async (options) => {
|
|
18
18
|
const lambdas = await (0, aws_clients_1.getLambdaClient)(options.region).send(new client_lambda_1.ListFunctionsCommand({}));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"get-functions.js","sourceRoot":"","sources":["../../src/api/get-functions.ts"],"names":[],"mappings":";;;AAAA,0DAA4D;AAE5D,uDAAsD;AACtD,mDAAsE;AACtE,yEAAkE;
|
|
1
|
+
{"version":3,"file":"get-functions.js","sourceRoot":"","sources":["../../src/api/get-functions.ts"],"names":[],"mappings":";;;AAAA,0DAA4D;AAE5D,uDAAsD;AACtD,mDAAsE;AACtE,yEAAkE;AAQlE;;;;;;;;GAQG;AACI,MAAM,YAAY,GAAG,KAAK,EAChC,OAA0B,EACA,EAAE;IAC5B,MAAM,OAAO,GAAG,MAAM,IAAA,6BAAe,EAAC,OAAO,CAAC,MAAM,CAAC,CAAC,IAAI,CACzD,IAAI,oCAAoB,CAAC,EAAE,CAAC,CAC5B,CAAC;IAEF,MAAM,eAAe,GAAG,CAAC,OAAO,CAAC,SAAS,IAAI,EAAE,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE;;QAC9D,OAAO,MAAA,CAAC,CAAC,YAAY,0CAAE,UAAU,CAAC,4BAAgB,CAAC,CAAC;IACrD,CAAC,CAAC,CAAC;IAEH,MAAM,OAAO,GAAG,MAAM,OAAO,CAAC,GAAG,CAChC,eAAe,CAAC,GAAG,CAAC,KAAK,EAAE,EAAE,EAAE,EAAE;QAChC,IAAI;YACH,MAAM,OAAO,GAAG,MAAM,IAAA,yCAAkB,EAAC;gBACxC,YAAY,EAAE,EAAE,CAAC,YAAsB;gBACvC,MAAM,EAAE,OAAO,CAAC,MAAM;aACtB,CAAC,CAAC;YACH,OAAO,OAAO,CAAC;SACf;QAAC,OAAO,GAAG,EAAE;YACb,OAAO,IAAI,CAAC;SACZ;IACF,CAAC,CAAC,CACF,CAAC;IAEF,MAAM,IAAI,GAAG,eAAe,CAAC,GAAG,CAAC,CAAC,MAAM,EAAE,CAAC,EAAgB,EAAE;QAC5D,OAAO;YACN,YAAY,EAAE,MAAM,CAAC,YAAsB;YAC3C,OAAO,EAAE,OAAO,CAAC,CAAC,CAAC;YACnB,cAAc,EAAE,MAAM,CAAC,UAAoB;YAC3C,gBAAgB,EAAE,MAAM,CAAC,OAAiB;SAC1C,CAAC;IACH,CAAC,CAAC,CAAC;IACH,IAAI,CAAC,OAAO,CAAC,cAAc,EAAE;QAC5B,OAAO,IAAI,CAAC;KACZ;IAED,OAAO,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE;QACxB,IAAI,CAAC,OAAO,CAAC,cAAc,EAAE;YAC5B,OAAO,IAAI,CAAC;SACZ;QAED,OAAO,CAAC,CAAC,OAAO,KAAK,2BAAe,CAAC;IACtC,CAAC,CAAC,CAAC;AACJ,CAAC,CAAC;AA5CW,QAAA,YAAY,gBA4CvB"}
|
|
@@ -1,17 +1,16 @@
|
|
|
1
1
|
import { AwsRegion } from '../pricing/aws-regions';
|
|
2
|
-
declare type GetOrCreateBucketInput = {
|
|
2
|
+
export declare type GetOrCreateBucketInput = {
|
|
3
3
|
region: AwsRegion;
|
|
4
4
|
onBucketEnsured?: () => void;
|
|
5
5
|
};
|
|
6
|
-
declare type
|
|
6
|
+
export declare type GetOrCreateBucketOutput = {
|
|
7
7
|
bucketName: string;
|
|
8
8
|
};
|
|
9
9
|
/**
|
|
10
10
|
* @description Creates a bucket for Remotion Lambda in your S3 account. If one already exists, it will get returned instead.
|
|
11
|
-
* @link
|
|
11
|
+
* @link https://v3.remotion.dev/docs/lambda/getorcreatebucket
|
|
12
12
|
* @param options.region The region in which you want your S3 bucket to reside in.
|
|
13
|
-
* @returns
|
|
13
|
+
* @returns {Promise<GetOrCreateBucketOutput>} An object containing the `bucketName`.
|
|
14
14
|
*/
|
|
15
|
-
export declare const getOrCreateBucket: (options: GetOrCreateBucketInput) => Promise<
|
|
16
|
-
export {};
|
|
15
|
+
export declare const getOrCreateBucket: (options: GetOrCreateBucketInput) => Promise<GetOrCreateBucketOutput>;
|
|
17
16
|
//# sourceMappingURL=get-or-create-bucket.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"get-or-create-bucket.d.ts","sourceRoot":"","sources":["../../src/api/get-or-create-bucket.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,SAAS,EAAC,MAAM,wBAAwB,CAAC;AAOjD,
|
|
1
|
+
{"version":3,"file":"get-or-create-bucket.d.ts","sourceRoot":"","sources":["../../src/api/get-or-create-bucket.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,SAAS,EAAC,MAAM,wBAAwB,CAAC;AAOjD,oBAAY,sBAAsB,GAAG;IACpC,MAAM,EAAE,SAAS,CAAC;IAClB,eAAe,CAAC,EAAE,MAAM,IAAI,CAAC;CAC7B,CAAC;AAEF,oBAAY,uBAAuB,GAAG;IACrC,UAAU,EAAE,MAAM,CAAC;CACnB,CAAC;AACF;;;;;GAKG;AACH,eAAO,MAAM,iBAAiB,YACpB,sBAAsB,KAC7B,QAAQ,uBAAuB,CA8BjC,CAAC"}
|
|
@@ -8,9 +8,9 @@ const enable_s3_website_1 = require("./enable-s3-website");
|
|
|
8
8
|
const get_buckets_1 = require("./get-buckets");
|
|
9
9
|
/**
|
|
10
10
|
* @description Creates a bucket for Remotion Lambda in your S3 account. If one already exists, it will get returned instead.
|
|
11
|
-
* @link
|
|
11
|
+
* @link https://v3.remotion.dev/docs/lambda/getorcreatebucket
|
|
12
12
|
* @param options.region The region in which you want your S3 bucket to reside in.
|
|
13
|
-
* @returns
|
|
13
|
+
* @returns {Promise<GetOrCreateBucketOutput>} An object containing the `bucketName`.
|
|
14
14
|
*/
|
|
15
15
|
const getOrCreateBucket = async (options) => {
|
|
16
16
|
var _a, _b;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"get-or-create-bucket.js","sourceRoot":"","sources":["../../src/api/get-or-create-bucket.ts"],"names":[],"mappings":";;;AACA,mDAA2D;AAC3D,uDAAiD;AACjD,mDAA6C;AAC7C,2DAAoD;AACpD,+CAAmD;
|
|
1
|
+
{"version":3,"file":"get-or-create-bucket.js","sourceRoot":"","sources":["../../src/api/get-or-create-bucket.ts"],"names":[],"mappings":";;;AACA,mDAA2D;AAC3D,uDAAiD;AACjD,mDAA6C;AAC7C,2DAAoD;AACpD,+CAAmD;AAUnD;;;;;GAKG;AACI,MAAM,iBAAiB,GAAG,KAAK,EACrC,OAA+B,EACI,EAAE;;IACrC,MAAM,EAAC,eAAe,EAAC,GAAG,MAAM,IAAA,kCAAoB,EAAC,OAAO,CAAC,MAAM,CAAC,CAAC;IACrE,IAAI,eAAe,CAAC,MAAM,GAAG,CAAC,EAAE;QAC/B,MAAM,IAAI,KAAK,CACd,8BAA8B,eAAe,CAAC,GAAG,CAChD,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,IAAI,CACb,wBACA,OAAO,CAAC,MACT,oBAAoB,kCAAsB,0EAA0E,CACpH,CAAC;KACF;IAED,IAAI,eAAe,CAAC,MAAM,KAAK,CAAC,EAAE;QACjC,MAAA,OAAO,CAAC,eAAe,+CAAvB,OAAO,CAAoB,CAAC;QAC5B,OAAO,EAAC,UAAU,EAAE,eAAe,CAAC,CAAC,CAAC,CAAC,IAAI,EAAC,CAAC;KAC7C;IAED,MAAM,UAAU,GAAG,kCAAsB,GAAG,IAAA,wBAAU,GAAE,CAAC;IAEzD,MAAM,IAAA,4BAAY,EAAC;QAClB,UAAU;QACV,MAAM,EAAE,OAAO,CAAC,MAAM;KACtB,CAAC,CAAC;IACH,MAAA,OAAO,CAAC,eAAe,+CAAvB,OAAO,CAAoB,CAAC;IAC5B,MAAM,IAAA,mCAAe,EAAC;QACrB,MAAM,EAAE,OAAO,CAAC,MAAM;QACtB,UAAU;KACV,CAAC,CAAC;IAEH,OAAO,EAAC,UAAU,EAAC,CAAC;AACrB,CAAC,CAAC;AAhCW,QAAA,iBAAiB,qBAgC5B"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { AwsRegion } from '../pricing/aws-regions';
|
|
2
|
+
/**
|
|
3
|
+
* @description Gets an array of all supported AWS regions of this release of Remotion Lambda.
|
|
4
|
+
* @link https://v3.remotion.dev/docs/lambda/getregions
|
|
5
|
+
* @returns {AwsRegion[]} A list of AWS regions.
|
|
6
|
+
*/
|
|
7
|
+
export declare const getRegions: () => readonly AwsRegion[];
|
|
8
|
+
//# sourceMappingURL=get-regions.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get-regions.d.ts","sourceRoot":"","sources":["../../src/api/get-regions.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,SAAS,EAAC,MAAM,wBAAwB,CAAC;AAGjD;;;;GAIG;AACH,eAAO,MAAM,UAAU,QAAO,SAAS,SAAS,EAE/C,CAAC"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.getRegions = void 0;
|
|
4
|
+
const regions_1 = require("../regions");
|
|
5
|
+
/**
|
|
6
|
+
* @description Gets an array of all supported AWS regions of this release of Remotion Lambda.
|
|
7
|
+
* @link https://v3.remotion.dev/docs/lambda/getregions
|
|
8
|
+
* @returns {AwsRegion[]} A list of AWS regions.
|
|
9
|
+
*/
|
|
10
|
+
const getRegions = () => {
|
|
11
|
+
return regions_1.AWS_REGIONS;
|
|
12
|
+
};
|
|
13
|
+
exports.getRegions = getRegions;
|
|
14
|
+
//# sourceMappingURL=get-regions.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get-regions.js","sourceRoot":"","sources":["../../src/api/get-regions.ts"],"names":[],"mappings":";;;AACA,wCAAuC;AAEvC;;;;GAIG;AACI,MAAM,UAAU,GAAG,GAAyB,EAAE;IACpD,OAAO,qBAAW,CAAC;AACpB,CAAC,CAAC;AAFW,QAAA,UAAU,cAErB"}
|
|
@@ -1,17 +1,19 @@
|
|
|
1
1
|
import { AwsRegion } from '../pricing/aws-regions';
|
|
2
|
+
import { RenderProgress } from '../shared/constants';
|
|
3
|
+
export declare type GetRenderInput = {
|
|
4
|
+
functionName: string;
|
|
5
|
+
bucketName: string;
|
|
6
|
+
renderId: string;
|
|
7
|
+
region: AwsRegion;
|
|
8
|
+
};
|
|
2
9
|
/**
|
|
3
|
-
* @description Gets the current status of a render originally triggered via
|
|
4
|
-
* @link https://remotion
|
|
10
|
+
* @description Gets the current status of a render originally triggered via renderMediaOnLambda().
|
|
11
|
+
* @link https://v3.remotion.dev/docs/lambda/getrenderprogress
|
|
5
12
|
* @param {string} params.functionName The name of the function used to trigger the render.
|
|
6
13
|
* @param {string} params.bucketName The name of the bucket that was used in the render.
|
|
7
|
-
* @param {string} params.renderId The ID of the render that was returned by `
|
|
14
|
+
* @param {string} params.renderId The ID of the render that was returned by `renderMediaOnLambda()`.
|
|
8
15
|
* @param {AwsRegion} params.region The region in which the render was triggered.
|
|
9
|
-
* @returns See documentation for this function to see all properties on the return object.
|
|
16
|
+
* @returns {Promise<RenderProgress>} See documentation for this function to see all properties on the return object.
|
|
10
17
|
*/
|
|
11
|
-
export declare const getRenderProgress: ({ functionName, bucketName, renderId, region, }:
|
|
12
|
-
functionName: string;
|
|
13
|
-
bucketName: string;
|
|
14
|
-
renderId: string;
|
|
15
|
-
region: AwsRegion;
|
|
16
|
-
}) => Promise<import("../shared/constants").RenderProgress>;
|
|
18
|
+
export declare const getRenderProgress: ({ functionName, bucketName, renderId, region, }: GetRenderInput) => Promise<RenderProgress>;
|
|
17
19
|
//# sourceMappingURL=get-render-progress.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"get-render-progress.d.ts","sourceRoot":"","sources":["../../src/api/get-render-progress.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,SAAS,EAAC,MAAM,wBAAwB,CAAC;
|
|
1
|
+
{"version":3,"file":"get-render-progress.d.ts","sourceRoot":"","sources":["../../src/api/get-render-progress.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,SAAS,EAAC,MAAM,wBAAwB,CAAC;AAEjD,OAAO,EAAiB,cAAc,EAAC,MAAM,qBAAqB,CAAC;AAEnE,oBAAY,cAAc,GAAG;IAC5B,YAAY,EAAE,MAAM,CAAC;IACrB,UAAU,EAAE,MAAM,CAAC;IACnB,QAAQ,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,SAAS,CAAC;CAClB,CAAC;AAEF;;;;;;;;GAQG;AACH,eAAO,MAAM,iBAAiB,oDAK3B,cAAc,KAAG,QAAQ,cAAc,CAUzC,CAAC"}
|
|
@@ -4,13 +4,13 @@ exports.getRenderProgress = void 0;
|
|
|
4
4
|
const call_lambda_1 = require("../shared/call-lambda");
|
|
5
5
|
const constants_1 = require("../shared/constants");
|
|
6
6
|
/**
|
|
7
|
-
* @description Gets the current status of a render originally triggered via
|
|
8
|
-
* @link https://remotion
|
|
7
|
+
* @description Gets the current status of a render originally triggered via renderMediaOnLambda().
|
|
8
|
+
* @link https://v3.remotion.dev/docs/lambda/getrenderprogress
|
|
9
9
|
* @param {string} params.functionName The name of the function used to trigger the render.
|
|
10
10
|
* @param {string} params.bucketName The name of the bucket that was used in the render.
|
|
11
|
-
* @param {string} params.renderId The ID of the render that was returned by `
|
|
11
|
+
* @param {string} params.renderId The ID of the render that was returned by `renderMediaOnLambda()`.
|
|
12
12
|
* @param {AwsRegion} params.region The region in which the render was triggered.
|
|
13
|
-
* @returns See documentation for this function to see all properties on the return object.
|
|
13
|
+
* @returns {Promise<RenderProgress>} See documentation for this function to see all properties on the return object.
|
|
14
14
|
*/
|
|
15
15
|
const getRenderProgress = async ({ functionName, bucketName, renderId, region, }) => {
|
|
16
16
|
return (0, call_lambda_1.callLambda)({
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"get-render-progress.js","sourceRoot":"","sources":["../../src/api/get-render-progress.ts"],"names":[],"mappings":";;;AACA,uDAAiD;AACjD,
|
|
1
|
+
{"version":3,"file":"get-render-progress.js","sourceRoot":"","sources":["../../src/api/get-render-progress.ts"],"names":[],"mappings":";;;AACA,uDAAiD;AACjD,mDAAmE;AASnE;;;;;;;;GAQG;AACI,MAAM,iBAAiB,GAAG,KAAK,EAAE,EACvC,YAAY,EACZ,UAAU,EACV,QAAQ,EACR,MAAM,GACU,EAA2B,EAAE;IAC7C,OAAO,IAAA,wBAAU,EAAC;QACjB,YAAY;QACZ,IAAI,EAAE,0BAAc,CAAC,MAAM;QAC3B,OAAO,EAAE;YACR,UAAU;YACV,QAAQ;SACR;QACD,MAAM;KACN,CAAC,CAAC;AACJ,CAAC,CAAC;AAfW,QAAA,iBAAiB,qBAe5B"}
|
package/dist/api/get-sites.d.ts
CHANGED
|
@@ -7,12 +7,20 @@ declare type Site = {
|
|
|
7
7
|
id: string;
|
|
8
8
|
serveUrl: string;
|
|
9
9
|
};
|
|
10
|
-
declare type
|
|
10
|
+
export declare type GetSitesInput = {
|
|
11
|
+
region: AwsRegion;
|
|
12
|
+
};
|
|
13
|
+
export declare type GetSitesOutput = {
|
|
11
14
|
sites: Site[];
|
|
12
15
|
buckets: BucketWithLocation[];
|
|
13
16
|
};
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
+
/**
|
|
18
|
+
*
|
|
19
|
+
* @description Gets all the deployed sites for a certain AWS region.
|
|
20
|
+
* @link https://v3.remotion.dev/docs/lambda/getsites
|
|
21
|
+
* @param {AwsRegion} params.region The AWS region that you want to query for.
|
|
22
|
+
* @returns {Promise<GetSitesOutput>} A Promise containing an object with `sites` and `bucket` keys. Consult documentation for details.
|
|
23
|
+
*/
|
|
24
|
+
export declare const getSites: ({ region, }: GetSitesInput) => Promise<GetSitesOutput>;
|
|
17
25
|
export {};
|
|
18
26
|
//# sourceMappingURL=get-sites.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"get-sites.d.ts","sourceRoot":"","sources":["../../src/api/get-sites.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,SAAS,EAAC,MAAM,wBAAwB,CAAC;AAIjD,OAAO,EAAC,kBAAkB,EAAuB,MAAM,eAAe,CAAC;AAEvE,aAAK,IAAI,GAAG;IACX,WAAW,EAAE,MAAM,CAAC;IACpB,YAAY,EAAE,MAAM,GAAG,IAAI,CAAC;IAC5B,UAAU,EAAE,MAAM,CAAC;IACnB,EAAE,EAAE,MAAM,CAAC;IACX,QAAQ,EAAE,MAAM,CAAC;CACjB,CAAC;AAEF,
|
|
1
|
+
{"version":3,"file":"get-sites.d.ts","sourceRoot":"","sources":["../../src/api/get-sites.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,SAAS,EAAC,MAAM,wBAAwB,CAAC;AAIjD,OAAO,EAAC,kBAAkB,EAAuB,MAAM,eAAe,CAAC;AAEvE,aAAK,IAAI,GAAG;IACX,WAAW,EAAE,MAAM,CAAC;IACpB,YAAY,EAAE,MAAM,GAAG,IAAI,CAAC;IAC5B,UAAU,EAAE,MAAM,CAAC;IACnB,EAAE,EAAE,MAAM,CAAC;IACX,QAAQ,EAAE,MAAM,CAAC;CACjB,CAAC;AAEF,oBAAY,aAAa,GAAG;IAC3B,MAAM,EAAE,SAAS,CAAC;CAClB,CAAC;AAEF,oBAAY,cAAc,GAAG;IAC5B,KAAK,EAAE,IAAI,EAAE,CAAC;IACd,OAAO,EAAE,kBAAkB,EAAE,CAAC;CAC9B,CAAC;AAEF;;;;;;GAMG;AACH,eAAO,MAAM,QAAQ,gBAElB,aAAa,KAAG,QAAQ,cAAc,CA2DxC,CAAC"}
|
package/dist/api/get-sites.js
CHANGED
|
@@ -6,8 +6,13 @@ const constants_1 = require("../shared/constants");
|
|
|
6
6
|
const get_account_id_1 = require("../shared/get-account-id");
|
|
7
7
|
const make_s3_url_1 = require("../shared/make-s3-url");
|
|
8
8
|
const get_buckets_1 = require("./get-buckets");
|
|
9
|
-
|
|
10
|
-
|
|
9
|
+
/**
|
|
10
|
+
*
|
|
11
|
+
* @description Gets all the deployed sites for a certain AWS region.
|
|
12
|
+
* @link https://v3.remotion.dev/docs/lambda/getsites
|
|
13
|
+
* @param {AwsRegion} params.region The AWS region that you want to query for.
|
|
14
|
+
* @returns {Promise<GetSitesOutput>} A Promise containing an object with `sites` and `bucket` keys. Consult documentation for details.
|
|
15
|
+
*/
|
|
11
16
|
const getSites = async ({ region, }) => {
|
|
12
17
|
var _a;
|
|
13
18
|
const { remotionBuckets } = await (0, get_buckets_1.getRemotionS3Buckets)(region);
|
|
@@ -21,7 +26,7 @@ const getSites = async ({ region, }) => {
|
|
|
21
26
|
expectedBucketOwner: accountId,
|
|
22
27
|
});
|
|
23
28
|
for (const file of ls) {
|
|
24
|
-
const siteKeyMatch = (_a = file.Key) === null || _a === void 0 ? void 0 : _a.match(/sites\/([0-9a-zA-Z]+)\/(.*)$/);
|
|
29
|
+
const siteKeyMatch = (_a = file.Key) === null || _a === void 0 ? void 0 : _a.match(/sites\/([0-9a-zA-Z-!_.*'()]+)\/(.*)$/);
|
|
25
30
|
if (!siteKeyMatch) {
|
|
26
31
|
throw new Error(`A file was found in the bucket "${bucket.name}" with the key ${file.Key} which is an unexpected folder structure. Delete this file.`);
|
|
27
32
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"get-sites.js","sourceRoot":"","sources":["../../src/api/get-sites.ts"],"names":[],"mappings":";;;AAAA,gDAAiD;AAEjD,mDAAgD;AAChD,6DAAsD;AACtD,uDAAqD;AACrD,+CAAuE;
|
|
1
|
+
{"version":3,"file":"get-sites.js","sourceRoot":"","sources":["../../src/api/get-sites.ts"],"names":[],"mappings":";;;AAAA,gDAAiD;AAEjD,mDAAgD;AAChD,6DAAsD;AACtD,uDAAqD;AACrD,+CAAuE;AAmBvE;;;;;;GAMG;AACI,MAAM,QAAQ,GAAG,KAAK,EAAE,EAC9B,MAAM,GACS,EAA2B,EAAE;;IAC5C,MAAM,EAAC,eAAe,EAAC,GAAG,MAAM,IAAA,kCAAoB,EAAC,MAAM,CAAC,CAAC;IAC7D,MAAM,SAAS,GAAG,MAAM,IAAA,6BAAY,EAAC,EAAC,MAAM,EAAC,CAAC,CAAC;IAE/C,MAAM,KAAK,GAA0B,EAAE,CAAC;IAExC,KAAK,MAAM,MAAM,IAAI,eAAe,EAAE;QACrC,MAAM,EAAE,GAAG,MAAM,IAAA,aAAQ,EAAC;YACzB,UAAU,EAAE,MAAM,CAAC,IAAI;YACvB,MAAM,EAAE,IAAA,uBAAW,EAAC,EAAE,CAAC;YACvB,MAAM;YACN,mBAAmB,EAAE,SAAS;SAC9B,CAAC,CAAC;QAEH,KAAK,MAAM,IAAI,IAAI,EAAE,EAAE;YACtB,MAAM,YAAY,GAAG,MAAA,IAAI,CAAC,GAAG,0CAAE,KAAK,CACnC,sCAAsC,CACtC,CAAC;YACF,IAAI,CAAC,YAAY,EAAE;gBAClB,MAAM,IAAI,KAAK,CACd,mCAAmC,MAAM,CAAC,IAAI,kBAAkB,IAAI,CAAC,GAAG,6DAA6D,CACrI,CAAC;aACF;YAED,MAAM,CAAC,EAAE,MAAM,CAAC,GAAG,YAAY,CAAC;YAChC,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,EAAE;gBACnB,KAAK,CAAC,MAAM,CAAC,GAAG;oBACf,WAAW,EAAE,CAAC;oBACd,UAAU,EAAE,MAAM,CAAC,IAAI;oBACvB,YAAY,EAAE,IAAI;oBAClB,EAAE,EAAE,MAAM;oBACV,QAAQ,EAAE,IAAA,4BAAc,EAAC;wBACxB,UAAU,EAAE,MAAM,CAAC,IAAI;wBACvB,MAAM;wBACN,SAAS,EAAE,IAAA,uBAAW,EAAC,MAAM,CAAC;qBAC9B,CAAC;iBACF,CAAC;aACF;YAED,IAAI,IAAI,CAAC,YAAY,EAAE;gBACtB,MAAM,mBAAmB,GAAG,KAAK,CAAC,MAAM,CAAC,CAAC,YAAY,CAAC;gBACvD,IACC,mBAAmB,KAAK,IAAI;oBAC5B,IAAI,CAAC,YAAY,CAAC,OAAO,EAAE,GAAG,mBAAmB,EAChD;oBACD,KAAK,CAAC,MAAM,CAAC,CAAC,YAAY,GAAG,IAAI,CAAC,YAAY,CAAC,OAAO,EAAE,CAAC;iBACzD;aACD;YAED,IAAI,IAAI,CAAC,IAAI,EAAE;gBACd,KAAK,CAAC,MAAM,CAAC,CAAC,WAAW,IAAI,IAAI,CAAC,IAAI,CAAC;aACvC;SACD;KACD;IAED,MAAM,UAAU,GAAW,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,GAAG,CAAC,CAAC,MAAM,EAAE,EAAE;QAC5D,OAAO,KAAK,CAAC,MAAM,CAAC,CAAC;IACtB,CAAC,CAAC,CAAC;IACH,OAAO,EAAC,KAAK,EAAE,UAAU,EAAE,OAAO,EAAE,eAAe,EAAC,CAAC;AACtD,CAAC,CAAC;AA7DW,QAAA,QAAQ,YA6DnB"}
|
|
@@ -1,10 +1,19 @@
|
|
|
1
1
|
import { AwsRegion } from '../../pricing/aws-regions';
|
|
2
2
|
import { SimulationResult } from './simulate-rule';
|
|
3
3
|
export declare const logPermissionOutput: (output: SimulationResult) => string;
|
|
4
|
-
export declare
|
|
4
|
+
export declare type SimulatePermissionsInput = {
|
|
5
5
|
region: AwsRegion;
|
|
6
|
-
onSimulation?: (
|
|
7
|
-
}
|
|
6
|
+
onSimulation?: (result: SimulationResult) => void;
|
|
7
|
+
};
|
|
8
|
+
export declare type SimulatePermissionsOutput = {
|
|
8
9
|
results: SimulationResult[];
|
|
9
|
-
}
|
|
10
|
+
};
|
|
11
|
+
/**
|
|
12
|
+
* @description Simulates calls using the AWS Simulator to validate the correct permissions.
|
|
13
|
+
* @link http://v3.remotion.dev/docs/lambda/simulatepermissions
|
|
14
|
+
* @param {AwsRegion} options.region The region which you would like to validate
|
|
15
|
+
* @param {(result: SimulationResult) => void} options.onSimulation The region which you would like to validate
|
|
16
|
+
* @returns {Promise<SimulatePermissionsOutput>} See documentation for detailed response structure.
|
|
17
|
+
*/
|
|
18
|
+
export declare const simulatePermissions: (options: SimulatePermissionsInput) => Promise<SimulatePermissionsOutput>;
|
|
10
19
|
//# sourceMappingURL=simulate.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"simulate.d.ts","sourceRoot":"","sources":["../../../src/api/iam-validation/simulate.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,SAAS,EAAC,MAAM,2BAA2B,CAAC;AAEpD,OAAO,EAA6B,gBAAgB,EAAC,MAAM,iBAAiB,CAAC;AAY7E,eAAO,MAAM,mBAAmB,WAAY,gBAAgB,WAE3D,CAAC;AAEF,
|
|
1
|
+
{"version":3,"file":"simulate.d.ts","sourceRoot":"","sources":["../../../src/api/iam-validation/simulate.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,SAAS,EAAC,MAAM,2BAA2B,CAAC;AAEpD,OAAO,EAA6B,gBAAgB,EAAC,MAAM,iBAAiB,CAAC;AAY7E,eAAO,MAAM,mBAAmB,WAAY,gBAAgB,WAE3D,CAAC;AAEF,oBAAY,wBAAwB,GAAG;IACtC,MAAM,EAAE,SAAS,CAAC;IAClB,YAAY,CAAC,EAAE,CAAC,MAAM,EAAE,gBAAgB,KAAK,IAAI,CAAC;CAClD,CAAC;AAEF,oBAAY,yBAAyB,GAAG;IACvC,OAAO,EAAE,gBAAgB,EAAE,CAAC;CAC5B,CAAC;AAEF;;;;;;GAMG;AACH,eAAO,MAAM,mBAAmB,YACtB,wBAAwB,KAC/B,QAAQ,yBAAyB,CAwBnC,CAAC"}
|
|
@@ -17,6 +17,13 @@ const logPermissionOutput = (output) => {
|
|
|
17
17
|
return [getEmojiForStatus(output.decision), output.name].join(' ');
|
|
18
18
|
};
|
|
19
19
|
exports.logPermissionOutput = logPermissionOutput;
|
|
20
|
+
/**
|
|
21
|
+
* @description Simulates calls using the AWS Simulator to validate the correct permissions.
|
|
22
|
+
* @link http://v3.remotion.dev/docs/lambda/simulatepermissions
|
|
23
|
+
* @param {AwsRegion} options.region The region which you would like to validate
|
|
24
|
+
* @param {(result: SimulationResult) => void} options.onSimulation The region which you would like to validate
|
|
25
|
+
* @returns {Promise<SimulatePermissionsOutput>} See documentation for detailed response structure.
|
|
26
|
+
*/
|
|
20
27
|
const simulatePermissions = async (options) => {
|
|
21
28
|
var _a;
|
|
22
29
|
const user = await (0, aws_clients_1.getIamClient)(options.region).send(new client_iam_1.GetUserCommand({}));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"simulate.js","sourceRoot":"","sources":["../../../src/api/iam-validation/simulate.ts"],"names":[],"mappings":";;;AAAA,oDAAmD;AAEnD,0DAAsD;AACtD,mDAA6E;AAC7E,yDAAuD;AAEvD,MAAM,iBAAiB,GAAG,CAAC,QAAsB,EAAE,EAAE;IACpD,QAAQ,QAAQ,EAAE;QACjB,KAAK,SAAS;YACb,OAAO,GAAG,CAAC;QACZ;YACC,OAAO,GAAG,CAAC;KACZ;AACF,CAAC,CAAC;AAEK,MAAM,mBAAmB,GAAG,CAAC,MAAwB,EAAE,EAAE;IAC/D,OAAO,CAAC,iBAAiB,CAAC,MAAM,CAAC,QAAQ,CAAC,EAAE,MAAM,CAAC,IAAI,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AACpE,CAAC,CAAC;AAFW,QAAA,mBAAmB,uBAE9B;
|
|
1
|
+
{"version":3,"file":"simulate.js","sourceRoot":"","sources":["../../../src/api/iam-validation/simulate.ts"],"names":[],"mappings":";;;AAAA,oDAAmD;AAEnD,0DAAsD;AACtD,mDAA6E;AAC7E,yDAAuD;AAEvD,MAAM,iBAAiB,GAAG,CAAC,QAAsB,EAAE,EAAE;IACpD,QAAQ,QAAQ,EAAE;QACjB,KAAK,SAAS;YACb,OAAO,GAAG,CAAC;QACZ;YACC,OAAO,GAAG,CAAC;KACZ;AACF,CAAC,CAAC;AAEK,MAAM,mBAAmB,GAAG,CAAC,MAAwB,EAAE,EAAE;IAC/D,OAAO,CAAC,iBAAiB,CAAC,MAAM,CAAC,QAAQ,CAAC,EAAE,MAAM,CAAC,IAAI,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AACpE,CAAC,CAAC;AAFW,QAAA,mBAAmB,uBAE9B;AAWF;;;;;;GAMG;AACI,MAAM,mBAAmB,GAAG,KAAK,EACvC,OAAiC,EACI,EAAE;;IACvC,MAAM,IAAI,GAAG,MAAM,IAAA,0BAAY,EAAC,OAAO,CAAC,MAAM,CAAC,CAAC,IAAI,CAAC,IAAI,2BAAc,CAAC,EAAE,CAAC,CAAC,CAAC;IAE7E,IAAI,CAAC,IAAI,IAAI,CAAC,IAAI,CAAC,IAAI,EAAE;QACxB,MAAM,IAAI,KAAK,CAAC,4BAA4B,CAAC,CAAC;KAC9C;IAED,MAAM,OAAO,GAAuB,EAAE,CAAC;IAEvC,KAAK,MAAM,GAAG,IAAI,sCAAmB,EAAE;QACtC,MAAM,MAAM,GAAG,MAAM,IAAA,4BAAY,EAAC;YACjC,WAAW,EAAE,GAAG,CAAC,OAAO;YACxB,GAAG,EAAE,IAAI,CAAC,IAAI,CAAC,GAAa;YAC5B,MAAM,EAAE,OAAO,CAAC,MAAM;YACtB,QAAQ,EAAE,GAAG,CAAC,QAAQ;YACtB,OAAO,EAAE,CAAC;SACV,CAAC,CAAC;QACH,KAAK,MAAM,GAAG,IAAI,MAAM,EAAE;YACzB,OAAO,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;YAClB,MAAA,OAAO,CAAC,YAAY,+CAApB,OAAO,EAAgB,GAAG,CAAC,CAAC;SAC5B;KACD;IAED,OAAO,EAAC,OAAO,EAAC,CAAC;AAClB,CAAC,CAAC;AA1BW,QAAA,mBAAmB,uBA0B9B"}
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* @description Returns an inline JSON policy to be assigned to the AWS user whose credentials are being used for excuting CLI commands or calling Node.JS functions.
|
|
3
|
-
* @link https://remotion
|
|
3
|
+
* @link https://v3.remotion.dev/docs/lambda/getuserpolicy
|
|
4
4
|
*/
|
|
5
5
|
export declare const getUserPolicy: () => string;
|
|
6
6
|
export declare const ROLE_NAME = "remotion-lambda-role";
|
|
7
7
|
/**
|
|
8
8
|
* @description Returns an inline JSON policy to be assigned to the 'remotion-lambda-role' role that needs to be created in your AWS account.
|
|
9
|
-
* @link https://remotion
|
|
9
|
+
* @link https://v3.remotion.dev/docs/lambda/getrolepolicy
|
|
10
10
|
*/
|
|
11
11
|
export declare const getRolePolicy: () => string;
|
|
12
12
|
//# sourceMappingURL=suggested-policy.d.ts.map
|
|
@@ -31,14 +31,14 @@ const suggestedRolePolicy = {
|
|
|
31
31
|
};
|
|
32
32
|
/**
|
|
33
33
|
* @description Returns an inline JSON policy to be assigned to the AWS user whose credentials are being used for excuting CLI commands or calling Node.JS functions.
|
|
34
|
-
* @link https://remotion
|
|
34
|
+
* @link https://v3.remotion.dev/docs/lambda/getuserpolicy
|
|
35
35
|
*/
|
|
36
36
|
const getUserPolicy = () => JSON.stringify(suggestedPolicy, null, 2);
|
|
37
37
|
exports.getUserPolicy = getUserPolicy;
|
|
38
38
|
exports.ROLE_NAME = 'remotion-lambda-role';
|
|
39
39
|
/**
|
|
40
40
|
* @description Returns an inline JSON policy to be assigned to the 'remotion-lambda-role' role that needs to be created in your AWS account.
|
|
41
|
-
* @link https://remotion
|
|
41
|
+
* @link https://v3.remotion.dev/docs/lambda/getrolepolicy
|
|
42
42
|
*/
|
|
43
43
|
const getRolePolicy = () => JSON.stringify(suggestedRolePolicy, null, 2);
|
|
44
44
|
exports.getRolePolicy = getRolePolicy;
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
import { FrameRange, ImageFormat, LogLevel, PixelFormat, ProResProfile } from 'remotion';
|
|
2
|
+
import { AwsRegion } from '../pricing/aws-regions';
|
|
3
|
+
import { Privacy } from '../shared/constants';
|
|
4
|
+
export declare type RenderMediaOnLambdaInput = {
|
|
5
|
+
region: AwsRegion;
|
|
6
|
+
functionName: string;
|
|
7
|
+
serveUrl: string;
|
|
8
|
+
composition: string;
|
|
9
|
+
inputProps: unknown;
|
|
10
|
+
codec: 'h264-mkv' | 'mp3' | 'aac' | 'wav';
|
|
11
|
+
imageFormat: ImageFormat;
|
|
12
|
+
crf?: number | undefined;
|
|
13
|
+
envVariables?: Record<string, string>;
|
|
14
|
+
pixelFormat?: PixelFormat;
|
|
15
|
+
proResProfile?: ProResProfile;
|
|
16
|
+
privacy: Privacy;
|
|
17
|
+
quality?: number;
|
|
18
|
+
maxRetries: number;
|
|
19
|
+
framesPerLambda?: number;
|
|
20
|
+
enableChunkOptimization?: boolean;
|
|
21
|
+
logLevel?: LogLevel;
|
|
22
|
+
frameRange?: FrameRange;
|
|
23
|
+
};
|
|
24
|
+
export declare type RenderMediaOnLambdaOutput = {
|
|
25
|
+
renderId: string;
|
|
26
|
+
bucketName: string;
|
|
27
|
+
};
|
|
28
|
+
/**
|
|
29
|
+
* @description Triggers a render on a lambda given a composition and a lambda function.
|
|
30
|
+
* @link https://v3.remotion.dev/docs/lambda/rendermediaonlambda
|
|
31
|
+
* @param params.functionName The name of the Lambda function that should be used
|
|
32
|
+
* @param params.serveUrl The URL of the deployed project
|
|
33
|
+
* @param params.composition The ID of the composition which should be rendered.
|
|
34
|
+
* @param params.inputProps The input props that should be passed to the composition.
|
|
35
|
+
* @param params.codec The video codec which should be used for encoding.
|
|
36
|
+
* @param params.imageFormat In which image format the frames should be rendered.
|
|
37
|
+
* @param params.crf The constant rate factor to be used during encoding.
|
|
38
|
+
* @param params.envVariables Object containing environment variables to be inserted into the video environment
|
|
39
|
+
* @param params.proResProfile The ProRes profile if rendering a ProRes video
|
|
40
|
+
* @param params.quality JPEG quality if JPEG was selected as the image format.
|
|
41
|
+
* @param params.region The AWS region in which the video should be rendered.
|
|
42
|
+
* @param params.maxRetries How often rendering a chunk may fail before the video render gets aborted.
|
|
43
|
+
* @param params.enableChunkOptimization Whether Remotion should restructure and optimize chunks for subsequent renders. Default true.
|
|
44
|
+
* @param params.logLevel Level of logging that Lambda function should perform. Default "info".
|
|
45
|
+
* @returns {Promise<RenderMediaOnLambdaOutput>} See documentation for detailed structure
|
|
46
|
+
*/
|
|
47
|
+
export declare const renderMediaOnLambda: ({ functionName, serveUrl, inputProps, codec, imageFormat, crf, envVariables, pixelFormat, proResProfile, quality, region, maxRetries, composition, framesPerLambda, privacy, enableChunkOptimization, logLevel, frameRange, }: RenderMediaOnLambdaInput) => Promise<RenderMediaOnLambdaOutput>;
|
|
48
|
+
/**
|
|
49
|
+
* @deprecated Renamed to renderMediaOnLambda()
|
|
50
|
+
*/
|
|
51
|
+
export declare const renderVideoOnLambda: ({ functionName, serveUrl, inputProps, codec, imageFormat, crf, envVariables, pixelFormat, proResProfile, quality, region, maxRetries, composition, framesPerLambda, privacy, enableChunkOptimization, logLevel, frameRange, }: RenderMediaOnLambdaInput) => Promise<RenderMediaOnLambdaOutput>;
|
|
52
|
+
//# sourceMappingURL=render-media-on-lambda.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"render-media-on-lambda.d.ts","sourceRoot":"","sources":["../../src/api/render-media-on-lambda.ts"],"names":[],"mappings":"AAAA,OAAO,EACN,UAAU,EACV,WAAW,EAEX,QAAQ,EACR,WAAW,EACX,aAAa,EACb,MAAM,UAAU,CAAC;AAClB,OAAO,EAAC,SAAS,EAAC,MAAM,wBAAwB,CAAC;AAEjD,OAAO,EAGN,OAAO,EACP,MAAM,qBAAqB,CAAC;AAI7B,oBAAY,wBAAwB,GAAG;IACtC,MAAM,EAAE,SAAS,CAAC;IAClB,YAAY,EAAE,MAAM,CAAC;IACrB,QAAQ,EAAE,MAAM,CAAC;IACjB,WAAW,EAAE,MAAM,CAAC;IACpB,UAAU,EAAE,OAAO,CAAC;IACpB,KAAK,EAAE,UAAU,GAAG,KAAK,GAAG,KAAK,GAAG,KAAK,CAAC;IAC1C,WAAW,EAAE,WAAW,CAAC;IACzB,GAAG,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IACzB,YAAY,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IACtC,WAAW,CAAC,EAAE,WAAW,CAAC;IAC1B,aAAa,CAAC,EAAE,aAAa,CAAC;IAC9B,OAAO,EAAE,OAAO,CAAC;IACjB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,UAAU,EAAE,MAAM,CAAC;IACnB,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,uBAAuB,CAAC,EAAE,OAAO,CAAC;IAClC,QAAQ,CAAC,EAAE,QAAQ,CAAC;IACpB,UAAU,CAAC,EAAE,UAAU,CAAC;CACxB,CAAC;AAEF,oBAAY,yBAAyB,GAAG;IACvC,QAAQ,EAAE,MAAM,CAAC;IACjB,UAAU,EAAE,MAAM,CAAC;CACnB,CAAC;AAEF;;;;;;;;;;;;;;;;;;GAkBG;AAEH,eAAO,MAAM,mBAAmB,kOAmB7B,wBAAwB,KAAG,QAAQ,yBAAyB,CA8B9D,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,mBAAmB,kOAnC7B,wBAAwB,KAAG,QAAQ,yBAAyB,CAmCT,CAAC"}
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.renderVideoOnLambda = exports.renderMediaOnLambda = void 0;
|
|
4
|
+
const remotion_1 = require("remotion");
|
|
5
|
+
const call_lambda_1 = require("../shared/call-lambda");
|
|
6
|
+
const constants_1 = require("../shared/constants");
|
|
7
|
+
const convert_to_serve_url_1 = require("../shared/convert-to-serve-url");
|
|
8
|
+
const validate_frames_per_lambda_1 = require("../shared/validate-frames-per-lambda");
|
|
9
|
+
/**
|
|
10
|
+
* @description Triggers a render on a lambda given a composition and a lambda function.
|
|
11
|
+
* @link https://v3.remotion.dev/docs/lambda/rendermediaonlambda
|
|
12
|
+
* @param params.functionName The name of the Lambda function that should be used
|
|
13
|
+
* @param params.serveUrl The URL of the deployed project
|
|
14
|
+
* @param params.composition The ID of the composition which should be rendered.
|
|
15
|
+
* @param params.inputProps The input props that should be passed to the composition.
|
|
16
|
+
* @param params.codec The video codec which should be used for encoding.
|
|
17
|
+
* @param params.imageFormat In which image format the frames should be rendered.
|
|
18
|
+
* @param params.crf The constant rate factor to be used during encoding.
|
|
19
|
+
* @param params.envVariables Object containing environment variables to be inserted into the video environment
|
|
20
|
+
* @param params.proResProfile The ProRes profile if rendering a ProRes video
|
|
21
|
+
* @param params.quality JPEG quality if JPEG was selected as the image format.
|
|
22
|
+
* @param params.region The AWS region in which the video should be rendered.
|
|
23
|
+
* @param params.maxRetries How often rendering a chunk may fail before the video render gets aborted.
|
|
24
|
+
* @param params.enableChunkOptimization Whether Remotion should restructure and optimize chunks for subsequent renders. Default true.
|
|
25
|
+
* @param params.logLevel Level of logging that Lambda function should perform. Default "info".
|
|
26
|
+
* @returns {Promise<RenderMediaOnLambdaOutput>} See documentation for detailed structure
|
|
27
|
+
*/
|
|
28
|
+
const renderMediaOnLambda = async ({ functionName, serveUrl, inputProps, codec, imageFormat, crf, envVariables, pixelFormat, proResProfile, quality, region, maxRetries, composition, framesPerLambda, privacy, enableChunkOptimization, logLevel, frameRange, }) => {
|
|
29
|
+
(0, validate_frames_per_lambda_1.validateFramesPerLambda)(framesPerLambda);
|
|
30
|
+
const realServeUrl = await (0, convert_to_serve_url_1.convertToServeUrl)(serveUrl, region);
|
|
31
|
+
const res = await (0, call_lambda_1.callLambda)({
|
|
32
|
+
functionName,
|
|
33
|
+
type: constants_1.LambdaRoutines.start,
|
|
34
|
+
payload: {
|
|
35
|
+
framesPerLambda: framesPerLambda !== null && framesPerLambda !== void 0 ? framesPerLambda : constants_1.DEFAULT_FRAMES_PER_LAMBDA,
|
|
36
|
+
composition,
|
|
37
|
+
serveUrl: realServeUrl,
|
|
38
|
+
inputProps,
|
|
39
|
+
codec,
|
|
40
|
+
imageFormat,
|
|
41
|
+
crf,
|
|
42
|
+
envVariables,
|
|
43
|
+
pixelFormat,
|
|
44
|
+
proResProfile,
|
|
45
|
+
quality,
|
|
46
|
+
maxRetries,
|
|
47
|
+
privacy,
|
|
48
|
+
enableChunkOptimization,
|
|
49
|
+
logLevel: logLevel !== null && logLevel !== void 0 ? logLevel : remotion_1.Internals.Logging.DEFAULT_LOG_LEVEL,
|
|
50
|
+
frameRange: frameRange !== null && frameRange !== void 0 ? frameRange : null,
|
|
51
|
+
},
|
|
52
|
+
region,
|
|
53
|
+
});
|
|
54
|
+
return {
|
|
55
|
+
renderId: res.renderId,
|
|
56
|
+
bucketName: res.bucketName,
|
|
57
|
+
};
|
|
58
|
+
};
|
|
59
|
+
exports.renderMediaOnLambda = renderMediaOnLambda;
|
|
60
|
+
/**
|
|
61
|
+
* @deprecated Renamed to renderMediaOnLambda()
|
|
62
|
+
*/
|
|
63
|
+
exports.renderVideoOnLambda = exports.renderMediaOnLambda;
|
|
64
|
+
//# sourceMappingURL=render-media-on-lambda.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"render-media-on-lambda.js","sourceRoot":"","sources":["../../src/api/render-media-on-lambda.ts"],"names":[],"mappings":";;;AAAA,uCAOkB;AAElB,uDAAiD;AACjD,mDAI6B;AAC7B,yEAAiE;AACjE,qFAA6E;AA4B7E;;;;;;;;;;;;;;;;;;GAkBG;AAEI,MAAM,mBAAmB,GAAG,KAAK,EAAE,EACzC,YAAY,EACZ,QAAQ,EACR,UAAU,EACV,KAAK,EACL,WAAW,EACX,GAAG,EACH,YAAY,EACZ,WAAW,EACX,aAAa,EACb,OAAO,EACP,MAAM,EACN,UAAU,EACV,WAAW,EACX,eAAe,EACf,OAAO,EACP,uBAAuB,EACvB,QAAQ,EACR,UAAU,GACgB,EAAsC,EAAE;IAClE,IAAA,oDAAuB,EAAC,eAAe,CAAC,CAAC;IACzC,MAAM,YAAY,GAAG,MAAM,IAAA,wCAAiB,EAAC,QAAQ,EAAE,MAAM,CAAC,CAAC;IAC/D,MAAM,GAAG,GAAG,MAAM,IAAA,wBAAU,EAAC;QAC5B,YAAY;QACZ,IAAI,EAAE,0BAAc,CAAC,KAAK;QAC1B,OAAO,EAAE;YACR,eAAe,EAAE,eAAe,aAAf,eAAe,cAAf,eAAe,GAAI,qCAAyB;YAC7D,WAAW;YACX,QAAQ,EAAE,YAAY;YACtB,UAAU;YACV,KAAK;YACL,WAAW;YACX,GAAG;YACH,YAAY;YACZ,WAAW;YACX,aAAa;YACb,OAAO;YACP,UAAU;YACV,OAAO;YACP,uBAAuB;YACvB,QAAQ,EAAE,QAAQ,aAAR,QAAQ,cAAR,QAAQ,GAAI,oBAAS,CAAC,OAAO,CAAC,iBAAiB;YACzD,UAAU,EAAE,UAAU,aAAV,UAAU,cAAV,UAAU,GAAI,IAAI;SAC9B;QACD,MAAM;KACN,CAAC,CAAC;IACH,OAAO;QACN,QAAQ,EAAE,GAAG,CAAC,QAAQ;QACtB,UAAU,EAAE,GAAG,CAAC,UAAU;KAC1B,CAAC;AACH,CAAC,CAAC;AAjDW,QAAA,mBAAmB,uBAiD9B;AAEF;;GAEG;AACU,QAAA,mBAAmB,GAAG,2BAAmB,CAAC"}
|