Flutter 패키지로, 개발자가 Flutter 애플리케이션에서 직접 메시지, 제품 카탈로그, 미디어 파일 및 위치 데이터를 보낼 수 있도록 WhatsApp Business API와의 통합을 가능하게 합니다. Android, iOS, Web, macOS, Windows, Linux를 지원하는 원활한 크로스플랫폼 커뮤니케이션을 위해 설계되었습니다. 이 패키지는 WhatsApp를 통해 풍부한 콘텐츠를 보내는 것을 단순화하여 고객 참여, 주문 확인, 자동 알림에 이상적입니다. 공식 WhatsApp Business API 위에 구축되어 신뢰성 있고 안전한 메시징을 보장합니다.
사용 사례
주문 확인 보내기
자동 고객 알림
제품 카탈로그 공유
위치 업데이트 전송
미디어 파일 공유
고객 지원 메시지
주요 기능
텍스트, 미디어 및 위치를 포함한 메시지 유형을 지원합니다
WhatsApp Business API와 통합
크로스 플랫폼 호환성
Flutter pub로 간편한 설정
실시간 메시지 전달
제품 카탈로그 공유
적합한 대상
전자상거래 앱
고객 서비스 플랫폼
비즈니스 커뮤니케이션 도구
자동 알림 시스템
WhatsApp 통합이 필요한 모바일 앱
고려 사항
WhatsApp Business API 접근 권한 필요
적절한 인증 설정이 필요합니다
사업자 계정 확인이 필요할 수 있습니다
레이트 제한이 적용됩니다
안정적인 인터넷 연결에 의존합니다
WhatsApp 정책 준수
원본 README
연결된 소스 저장소의 README 원문 스냅샷입니다. 최신 내용은 저장소에서 확인하세요.
This Flutter package allows you to integrate the WhatsApp Business API into your Flutter applications. It enables sending messages, media, templates, managing business information, creating interactives and flows, sending catalog messages, and more. The package is updated to support the latest WhatsApp Business API v23.0.
Performance Improvements – Optimized core methods, now up to 3x faster than previous versions.
Web Platform Support – Now supports fully compatibility with Flutter Web for most features.
Service-Specific Methods – Each service now provides dedicated getters for cleaner and more explicit usage.
Flow Messages – Added support for interactive flow messages to improve user engagement.
Catalog & Product Messages – Send product details and catalog messages for e-commerce use cases.
Resumable Uploads – Support for creating and managing resumable upload sessions for large files.
Error Handling Enhancements – Improved and added WhatsAppException handling with detailed error types.
Bug Fixes – Resolved multiple issues affecting stability and reliability.
API Upgrade – Updated to support WhatsApp Business API v23.0 (stable).
Basic Usage
// Access token provided by Meta for WhatsApp Cloud APIconst accessToken = 'YOUR_ACCESS_TOKEN';
// Your WhatsApp Business phone number IDconst fromNumberId = 'YOUR_PHONE_NUMBER_ID';
// Create WhatsApp client instancefinal whatsapp = WhatsApp(accessToken, fromNumberId);
try {
// Send a simple text messagevar message = await whatsapp.sendMessage(
phoneNumber: 'RECEIPT_NUMBER', // Recipient's phone number in international format
text: 'Hi, how are you?', // Message content
);
// Message sent successfully// Get and print the unique ID of the sent messageprint('Message ID: ${message.getMessageId()}');
// Get and print the recipient numberprint('Message sent to: ${message.getContactId()}');
// Get and print the full API response bodyprint('API Response: ${message.getFullResponse()}');
} onWhatsAppExceptioncatch (e) {
// Message failed to send// Print HTTP error code returned by the APIprint('HTTP Code: ${e.statusCode}');
// Print exact error details from WhatsApp Cloud APIprint('API Error: ${e.message}');
// Print type of request error (e.g., validation, authorization, etc.)print('Request Error: ${e.errorType}');
} catch (e) {
print('Unexpected error: $e');
}
Have you found a bug or have a suggestion of how to enhance WhatsApp Package? Open an issue or pull request and we will take a look at it as soon as possible.
Report bugs or issues
You are welcome to open a ticket on github if any problems arise. New ideas are always welcome.