iachat/enterprise/app
Shivam Mishra 7651c18b48
feat: firecrawl branding api [UPM-15] (#13903)
Adds `WebsiteBrandingService` (OSS) with an Enterprise override using
Firecrawl v2 to extract branding and business data from a URL for
onboarding auto-fill.

OSS version uses HTTParty + Nokogiri to extract:
- Business name (og:site_name or title)
- Language (html lang)
- Favicon
- Social links from `<a>` tags

Enterprise version makes a single Firecrawl call to fetch:
- Structured JSON (name, language, industry via LLM)
- Branding (favicon, primary color)
- Page links

Falls back to OSS if Firecrawl is unavailable or fails.

Social handles (WhatsApp, Facebook, Instagram, Telegram, TikTok, LINE)
are parsed deterministically via a shared `SocialLinkParser`.

> We use links for socials, since the LLM extraction was unreliable,
mostly returned empty, and hallucinated in some rare scenarios

## How to test

```ruby
# OSS (no Firecrawl key needed)
WebsiteBrandingService.new('chatwoot.com').perform

# Enterprise (requires CAPTAIN_FIRECRAWL_API_KEY)
WebsiteBrandingService.new('notion.so').perform
WebsiteBrandingService.new('postman.com').perform
```

Verify the returned hash includes business_name, language,
industry_category, social_handles, and branding with
favicon/primary_color.

<img width="908" height="393" alt="image"
src="https://github.com/user-attachments/assets/e3696887-d366-485a-89a0-8e1a9698a788"
/>
2026-03-30 11:32:03 +05:30
..
builders fix: restrict existing user sign-in to account members (#13793) 2026-03-13 12:22:25 +05:30
controllers feat: support bulk select and delete for documents (#13907) 2026-03-26 19:48:12 +05:30
dispatchers/enterprise feat(ee): Add Captain features (#10665) 2025-01-14 16:15:47 -08:00
drops feat: Add push/email notification support for SLA (#9140) 2024-03-29 20:27:21 +11:00
fields fix: Render all account limit fields (#13435) 2026-02-04 20:21:07 +05:30
finders/enterprise feat: Conversation API to return applied_sla and sla_events (#9174) 2024-04-01 23:30:07 +05:30
helpers feat: allow captain to access contact attributes (#13850) 2026-03-20 16:15:06 +05:30
jobs fix: handoff only if conversation pending (#13882) 2026-03-23 17:09:58 +05:30
listeners feat: Add support for realtime-events in copilot-threads and copilot-messages (#11557) 2025-05-22 22:25:05 -07:00
mailers/enterprise/agent_notifications chore: fix sla email notifications (#9192) 2024-04-04 21:16:49 +05:30
models fix: resolve V2 capacity bypass in team assignment (#13904) 2026-03-27 15:38:17 +05:30
policies feat(help-center): enable drag-and-drop category reordering (#13706) 2026-03-05 12:53:38 +05:30
presenters/enterprise/conversations feat: UI to show the SLA threshold in chat screen (#9146) 2024-04-04 15:46:46 +05:30
services feat: firecrawl branding api [UPM-15] (#13903) 2026-03-30 11:32:03 +05:30
views feat: Backend - Companies API endpoint with pagination and search (#12840) 2025-11-18 14:28:56 +05:30