{"record":{"id":"f68899fa22672b7c","repo":"RocketChat/Rocket.Chat","slug":"invalid-call","errorCode":null,"errorMessage":"invalid call","messagePattern":"invalid call","errorType":"exception","errorClass":"Error","httpStatus":500,"severity":"error","filePath":"apps/meteor/server/modules/core-apps/videoconf.module.ts","lineNumber":19,"sourceCode":"import type { IUiKitCoreApp, UiKitCoreAppBlockActionPayload } from '@rocket.chat/core-services';\nimport { VideoConf } from '@rocket.chat/core-services';\nimport type * as UiKit from '@rocket.chat/ui-kit';\n\nimport { i18n } from '../../lib/i18n';\n\nexport class VideoConfModule implements IUiKitCoreApp {\n\tappId = 'videoconf-core';\n\n\tasync blockAction(payload: UiKitCoreAppBlockActionPayload): Promise<UiKit.ServerInteraction | undefined> {\n\t\tconst {\n\t\t\ttriggerId,\n\t\t\tactionId,\n\t\t\tpayload: { blockId: callId },\n\t\t\tuser: { _id: userId } = {},\n\t\t} = payload;\n\n\t\tif (!callId) {\n\t\t\tthrow new Error('invalid call');\n\t\t}\n\n\t\tif (actionId === 'join') {\n\t\t\tawait VideoConf.join(userId, callId, {});\n\t\t}\n\n\t\tif (actionId === 'info') {\n\t\t\tconst blocks = await VideoConf.getInfo(callId, userId);\n\n\t\t\treturn {\n\t\t\t\ttype: 'modal.open',\n\t\t\t\ttriggerId,\n\t\t\t\tappId: this.appId,\n\t\t\t\tview: {\n\t\t\t\t\tappId: this.appId,\n\t\t\t\t\tid: `${callId}-info`,\n\t\t\t\t\ttitle: {\n\t\t\t\t\t\ttype: 'plain_text',","sourceCodeStart":1,"sourceCodeEnd":37,"githubUrl":"https://github.com/RocketChat/Rocket.Chat/blob/b2c16d5842cbe6b69b59bdf6fc5e5f1afcd1f0b0/apps/meteor/server/modules/core-apps/videoconf.module.ts#L1-L37","documentation":"VideoConfModule.blockAction (appId 'videoconf-core') takes payload.blockId as the video-call id for the 'join' and 'info' actions of the conferencing widget. If blockId is absent it throws 'invalid call' before any call lookup happens — this is a payload-shape failure, not an unknown-conference failure.","triggerScenarios":"Dispatching a videoconf-core blockAction (join/info buttons of the video call popup or ringing banner) whose payload has no blockId — reconstructed interaction objects or skeleton test payloads.","commonSituations":"Custom clients driving the video popup programmatically; payloads rebuilt after a re-render; copied payloads where blockId was renamed or dropped.","solutions":["Pass the call id unchanged in payload.blockId, exactly as delivered by the original interaction","Validate the payload shape (blockId present) before dispatching","Keep the original interaction object from the popup/ringer instead of reconstructing it"],"exampleFix":"// before\napi.call('uiKit', { appId: 'videoconf-core', actionId: 'join', payload: {} }); // throws 'invalid call'\n\n// after\napi.call('uiKit', { appId: 'videoconf-core', actionId: 'join', payload: { blockId: callId } });","handlingStrategy":"validation","validationCode":"const hasCallId = (p: any): boolean => Boolean(p?.payload?.blockId);","typeGuard":"const isVideoConfAction = (p: unknown): p is { payload: { blockId: string } } =>\n  typeof p === 'object' && p !== null && typeof (p as any).payload?.blockId === 'string';","tryCatchPattern":null,"preventionTips":["Carry the call id in payload.blockId exactly as the popup delivered it","Re-render the video popup from server state instead of caching reconstructed payloads","Assert blockId presence in dev builds before dispatching join/info"],"tags":["uikit","video-conference","payload-validation"],"backgroundTag":"uikit-payload-validation-failed","analyzedSha":"b2c16d5842cbe6b69b59bdf6fc5e5f1afcd1f0b0","analyzedAt":"2026-08-18T15:26:39.429Z","contentChangedAt":"2026-08-18T15:26:39.429Z","schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}