패키지, 저장소 및 앱 카테고리 검색

패키지 상세v4.0.1

whatsapp

WhatsApp Business API와 통합할 수 있는 Flutter 패키지입니다. Flutter 앱에서 메시지, 제품, 미디어 및 위치를 직접 보낼 수 있습니다.

AndroidiOSWebmacOSWindowsLinux
30일 다운로드
196
좋아요
212
Pub 점수
140

패키지 설치

flutter pub add whatsapp

패키지 개요

공개 정보를 바탕으로 생성한 선택 가이드입니다.

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 원문 스냅샷입니다. 최신 내용은 저장소에서 확인하세요.

WhatsApp Flutter Banner

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.

Pub Likes Pub Points Pub Monthly Downloads GitHub Issues GitHub PRs GitHub Forks

Rohit Chouhan Sponsor


Documentation

Full documentation for the WhatsApp Flutter package is available at whatsapp-flutter.github.io.

You can switch the documentation version using the version selector at the top of the page (version:).

Other useful links:


New Features in v4

  • 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 API
const accessToken = 'YOUR_ACCESS_TOKEN';

// Your WhatsApp Business phone number ID
const fromNumberId = 'YOUR_PHONE_NUMBER_ID';

// Create WhatsApp client instance
final whatsapp = WhatsApp(accessToken, fromNumberId);

try {
  // Send a simple text message
  var 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 message
  print('Message ID: ${message.getMessageId()}');
  // Get and print the recipient number
  print('Message sent to: ${message.getContactId()}');
  // Get and print the full API response body
  print('API Response: ${message.getFullResponse()}');
} on WhatsAppException catch (e) {
  // Message failed to send
  // Print HTTP error code returned by the API
  print('HTTP Code: ${e.statusCode}');
  // Print exact error details from WhatsApp Cloud API
  print('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');
}

📌 Looking for a Better Example?

👉 Check out this working example here:
🔗 pub.dev WhatsApp Example

Contributors

chouhan-rahul

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.

Copyright and License

Copyright © 2022 Rohit Chouhan. Licensed under the MIT LICENSE.

카테고리

의존성

의존성 목록 2 개

소스 저장소

이 패키지를 사용하는 프로젝트

아직 데이터가 없습니다.