WhatsAppBussinesApi.Dotnet
1.0.2
dotnet add package WhatsAppBussinesApi.Dotnet --version 1.0.2
NuGet\Install-Package WhatsAppBussinesApi.Dotnet -Version 1.0.2
<PackageReference Include="WhatsAppBussinesApi.Dotnet" Version="1.0.2" />
paket add WhatsAppBussinesApi.Dotnet --version 1.0.2
#r "nuget: WhatsAppBussinesApi.Dotnet, 1.0.2"
// Install WhatsAppBussinesApi.Dotnet as a Cake Addin #addin nuget:?package=WhatsAppBussinesApi.Dotnet&version=1.0.2 // Install WhatsAppBussinesApi.Dotnet as a Cake Tool #tool nuget:?package=WhatsAppBussinesApi.Dotnet&version=1.0.2
WhatsAppBussinesApi.Dotnet Package
This NuGet package provides classes and functionalities to integrate the WhatsApp Business API into .NET 8 and higher projects. In this initial version, it supports building message objects and sending them in the following formats:
Text Messages:
- Text messages
- Messages with images (supports image/jpeg and image/png)
- Messages with location
- Document messages
- Interactive messages
Templates:
- Template with text
- Template with text and header
- Template with text, header, and buttons
Configuration
- Package installation:
dotnet add package WhatsAppBussinesApi.Dotnet
- Import the necessary classes into your project:
using WhatsAppBusinessApi.Dotnet;
- Add the service in Program.cs:
builder.Services.AddWhatsAppBusinessApi();
- Add your credentials in appSettings.json:
"WhatsAppBusiness": { "PhoneNumber": "", // WhatsApp phone number identifier "BearerToken": "", // Authentication Bearer Token "Version": "" // API version to use }
Make sure to replace PhoneNumber, BearerToken, and Version with the corresponding values from your WhatsApp Business account.
Example
Note:
This package will be continuously updated to include more methods supported by the WhatsApp Business API. In the following days, additional examples and explanations for constructing and utilizing classes will be provided.
Thank you for using WhatsApp Business API .NET Package!
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net8.0 is compatible. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. |
-
net8.0
- Microsoft.Extensions.Configuration (>= 8.0.0)
- Newtonsoft.Json (>= 13.0.3)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.