{"record":{"id":"9a6a00f87b806b00","repo":"remotion-dev/remotion","slug":"params-must-be-renderer","errorCode":null,"errorMessage":"Params must be renderer","messagePattern":"Params must be renderer","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"packages/serverless/src/handlers/renderer.ts","lineNumber":72,"sourceCode":"\tparams: ServerlessPayload<Provider>;\n\toptions: Options;\n\tlogs: BrowserLog[];\n\tonStream: OnStream<Provider>;\n\tproviderSpecifics: ProviderSpecifics<Provider>;\n\tinsideFunctionSpecifics: InsideFunctionSpecifics<Provider>;\n\tonBrowserInstance: (browserInstance: LaunchedBrowser) => void;\n\tonMediaFiles:\n\t\t| ((options: {\n\t\t\t\tvideoOutputLocation: string;\n\t\t\t\taudioOutputLocation: string | null;\n\t\t\t\tisAudioOnly: boolean;\n\t\t\t\tcompletedAt: number;\n\t\t  }) => Promise<void>)\n\t\t| null;\n\tcancelSignal: CancelSignal | null;\n}): Promise<{}> => {\n\tif (params.type !== ServerlessRoutines.renderer) {\n\t\tthrow new Error('Params must be renderer');\n\t}\n\n\tconst chromiumOptions =\n\t\tinsideFunctionSpecifics.normalizeChromiumOptions?.({\n\t\t\tchromiumOptions: params.chromiumOptions,\n\t\t\tlogLevel: params.logLevel,\n\t\t}) ?? params.chromiumOptions;\n\n\tif (params.launchFunctionConfig.version !== VERSION) {\n\t\tthrow new Error(\n\t\t\t`The version of the function that was specified as \"rendererFunctionName\" is ${VERSION} but the version of the function that invoked the render is ${params.launchFunctionConfig.version}. Please make sure that the version of the function that is specified as \"rendererFunctionName\" is the same as the version of the function that is invoked.`,\n\t\t);\n\t}\n\n\tconst inputPropsPromise = decompressInputProps({\n\t\tbucketName: params.bucketName,\n\t\texpectedBucketOwner: options.expectedBucketOwner,\n\t\tregion: insideFunctionSpecifics.getCurrentRegionInFunction(),","sourceCodeStart":54,"sourceCodeEnd":90,"githubUrl":"https://github.com/remotion-dev/remotion/blob/b2f4e34732f3c6c222ea029413e22dc402218cd7/packages/serverless/src/handlers/renderer.ts#L54-L90","documentation":"The serverless renderer Lambda handler validates that the incoming payload has type === ServerlessRoutines.renderer before doing any work. Any other routine type dispatched to this handler is a programming/routing error, so it throws immediately.","triggerScenarios":"Invoking the renderer function's renderHandler with a payload whose `type` field is not 'renderer' — e.g. sending a launch routine payload to the renderer function, hand-crafted Lambda invocations, or wrongly wired sqs/lambda routing.","commonSituations":"Manually invoking the Lambda for testing with wrong payload; mixing up launch vs renderer function names so a launch payload reaches rendererHandler; custom orchestration code that constructs its own params.","solutions":["Ensure the renderer Lambda is only invoked by the launch function with a payload of type ServerlessRoutines.renderer","Call renderMediaOnLambda()/renderOnLambda instead of invoking the Lambda directly so the correct payload is built","Check that rendererFunctionName points at the renderer function, not the orchestrator function","Inspect the invoking payload's `type` field in CloudWatch logs and fix the caller"],"exampleFix":"// before (manual invoke)\nawait lambda.send(new InvokeCommand({ FunctionName: rendererFn, Payload: JSON.stringify({ type: 'launch', ... }) }));\n// after\nawait renderMediaOnLambda({ functionName: rendererFn, serveUrl, composition, region });","handlingStrategy":"validation","validationCode":"if (payload.type === 'renderer') {\n  await invokeRenderer(payload);\n}","typeGuard":"const isRendererParams = (p: unknown): p is RendererParams =>\n  typeof p === 'object' && p !== null && (p as {type?: string}).type === 'renderer';","tryCatchPattern":"try {\n  await renderHandler({ inputProps, ... });\n} catch (e) {\n  if ((e as Error).message === 'Params must be renderer') {\n    // wrong payload routed to renderer function; fix caller\n  } else { throw e; }\n}","preventionTips":["Never invoke the renderer Lambda manually; use renderMediaOnLambda()/renderOnLambda","Verify rendererFunctionName points to the renderer, not the launch function","Log and inspect payload.type before dispatch"],"tags":["lambda","serverless","validation","internal"],"backgroundTag":"invalid-argument-value","analyzedSha":"b2f4e34732f3c6c222ea029413e22dc402218cd7","analyzedAt":"2026-09-09T13:27:51.281Z","contentChangedAt":"2026-09-09T13:27:51.281Z","schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}