{"record":{"id":"f3e5508d86649a72","repo":"tinyhumansai/openhuman","slug":"please-paste-a-meeting-link","errorCode":null,"errorMessage":"Please paste a meeting link.","messagePattern":"Please paste a meeting link\\.","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"warning","filePath":"app/src/services/meetCallService.ts","lineNumber":228,"sourceCode":"  listenOnly?: boolean;\n};\n\ntype CoreBackendMeetJoinResponse = { ok: boolean; meet_url: string; platform: string };\n\n/**\n * Join a meeting via the backend's Recall.ai bot. Supports Google Meet,\n * Zoom, Microsoft Teams, and Webex.\n *\n * Calls the core RPC `openhuman.agent_meetings_join`, which emits `bot:join`\n * over the core's persistent Socket.IO connection to the backend. The backend\n * streams events back (`bot:reply`, `bot:harness`, `bot:transcript`, `bot:left`)\n * which the core bridges to the frontend as `agent_meetings:*` socket events.\n */\nexport async function joinMeetViaBackendBot(\n  input: BackendMeetJoinInput\n): Promise<{ meetUrl: string; platform: string }> {\n  const meetUrl = input.meetUrl.trim();\n  if (!meetUrl) throw new Error('Please paste a meeting link.');\n\n  // Dual-mascot slots (issue #4277), mapped to the backend's snake_case wire\n  // shape. Absent → backend falls back to `mascot_id`.\n  const slots = input.mascots?.filter(m => m.mascotId?.trim());\n  const mascots =\n    slots && slots.length > 0\n      ? slots.map(m => ({\n          mascot_id: m.mascotId.trim(),\n          name: m.name?.trim() || undefined,\n          voice_id: m.voiceId?.trim() || undefined,\n          rive_colors: mapRiveColors(m.riveColors),\n        }))\n      : undefined;\n\n  // Flow/state metadata only — no participant names, voices, or the meet URL.\n  log(\n    'backend bot join corr=%s dual=%s slots=%d singleMascot=%s riveColors=%s',\n    input.correlationId?.trim() || '-',","sourceCodeStart":210,"sourceCodeEnd":246,"githubUrl":"https://github.com/tinyhumansai/openhuman/blob/749120085864ce16e0f273c7b86fac7740b39c5b/app/src/services/meetCallService.ts#L210-L246","documentation":"Client-side input validation in joinMeetViaBackendBot: the user-supplied meetUrl is trimmed and, if empty, the function refuses to call the core at all. It guards the openhuman.agent_meetings_join RPC from being invoked with no join URL — the backend's Recall.ai bot has nothing to dial without it.","triggerScenarios":"joinMeetViaBackendBot({ meetUrl: '' }) or a whitespace-only link — i.e. the Join form submitted with an empty input; programmatic callers passing an unpopulated form field.","commonSituations":"Join button enabled without required-field validation; paste handlers that fail to fill state; automated flows calling join before collecting the URL.","solutions":["Validate before submit: disable the Join action until meetUrl.trim() is non-empty","Pre-validate the URL shape (Google Meet / Zoom / Teams / Webex) to also catch non-empty-but-invalid input before hitting the core","In the catch, map this message to an inline field error rather than a toast"],"exampleFix":"// before\nconst canJoin = true; // always clickable\n\n// after\nconst canJoin = input.meetUrl.trim().length > 0;\n<button disabled={!canJoin} onClick={() => joinMeetViaBackendBot(input)}>Join</button>","handlingStrategy":"validation","validationCode":"function hasMeetingLink(meetUrl: string): boolean {\n  return meetUrl.trim().length > 0;\n}","typeGuard":"const SUPPORTED = /^https:\\/\\/(meet\\.google\\.com|[a-z0-9.-]*zoom\\.us|teams\\.microsoft\\.com|[a-z0-9.-]*webex\\.com)\\//i;\nfunction isSupportedMeetUrl(u: string): boolean {\n  const s = u.trim();\n  return s.length > 0 && SUPPORTED.test(s);\n}","tryCatchPattern":"try {\n  await joinMeetViaBackendBot(input);\n} catch (err) {\n  if (err instanceof Error && err.message === 'Please paste a meeting link.') {\n    setFieldError('meetUrl', 'Paste a Google Meet, Zoom, Teams or Webex link.');\n    return;\n  }\n  throw err;\n}","preventionTips":["Disable the Join action until the trimmed URL is non-empty","Validate the provider pattern client-side so the core never sees unsupported links","Show this as an inline field error, not a toast"],"tags":["meet","validation","user-input","empty-url"],"backgroundTag":"empty-required-field","analyzedSha":"749120085864ce16e0f273c7b86fac7740b39c5b","analyzedAt":"2026-08-17T21:21:45.363Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}