SKitLs.Bots.Telegram.AdvancedMessages
2.0.1
Prefix Reserved
Delivery System ParseMode and ReplyToMessageId now nullable.
See the version list below for details.
dotnet add package SKitLs.Bots.Telegram.AdvancedMessages --version 2.0.1
NuGet\Install-Package SKitLs.Bots.Telegram.AdvancedMessages -Version 2.0.1
<PackageReference Include="SKitLs.Bots.Telegram.AdvancedMessages" Version="2.0.1" />
paket add SKitLs.Bots.Telegram.AdvancedMessages --version 2.0.1
#r "nuget: SKitLs.Bots.Telegram.AdvancedMessages, 2.0.1"
// Install SKitLs.Bots.Telegram.AdvancedMessages as a Cake Addin #addin nuget:?package=SKitLs.Bots.Telegram.AdvancedMessages&version=2.0.1 // Install SKitLs.Bots.Telegram.AdvancedMessages as a Cake Tool #tool nuget:?package=SKitLs.Bots.Telegram.AdvancedMessages&version=2.0.1
SKitLs.Bots.Telegram.AdvancedMessages
An extension project built upon the SKitLs.Bots.Telegram.Core Framework.
Offers enhanced methods for sending messages in Telegram bots.
Description
SKitLs.Bots.Telegram.AdvancedMessages serves as an extension to the SKitLs.Bots.Telegram Framework, enriching the message-sending functionality in Telegram bots. The primary objective of this extension is to offer improved methods for message creation and delivery, thus enabling more flexible and interactive communication with users.
The key functionalities of this extension include:
Advanced Delivery:
The
AdvancedDeliverySystem
is an enhanced implementation of theIDeliveryService
interface, designed to facilitate seamless interaction with message classes within the library. Replacing theDefaultDeliverySystem
, this feature introduces a more sophisticated and versatile approach to message handling.Menus:
The extension empowers the creation of messages with integrated inline menus, allowing users to interact with the bot seamlessly without leaving the chat window. Also you can augment messages with Reply Markups, presenting users with a set of buttons to choose from, leading to prompt responses and actions, thereby streamlining interactions.
Message Formatting (WIP):
SKitLs.Bots.Telegram.AdvancedMessages provides the ability to format text messages with various styles, such as bold, italic, and stroke text. This enables more expressive and comprehensible presentation of textual information.
As part of the expansion plan, developers aim to introduce functionality for sending audio files, media, and documents. This enhancement will facilitate more efficient exchange of diverse content types between bots and users, elevating the quality and diversity of communication.
SKitLs.Bots.Telegram.AdvancedMessages is committed to empowering Telegram bot developers with tools to create more interactive, informative, and user-friendly messages, thereby enhancing the overall user experience and satisfaction.
Setup
Requirements
Before running the project, please ensure that you have the following dependencies installed and properly configured in your development environment.
- Telegram.Bot 19.0.0 or higher
- SKitLs.Bots.Telegram.Core 2.1.3 or higher
- SKitLs.Bots.Telegram.ArgedInteractions 1.3.3 or higher
Installation
Using Terminal Command:
To install the project using the terminal command, follow these steps:
- Open the terminal or command prompt.
- Run command:
dotnet add package SKitLs.Bots.Telegram.AdvancedMessages
Using NuGet Packages Manager:
To install the project using the NuGet Packages Manager, perform the following steps:
- Open your preferred Integrated Development Environment (IDE) that supports NuGet package management (e.g., Visual Studio).
- Create a new project or open an existing one.
- Select "Project" > "Manage NuGet Packages"
- In the "Browse" tab, search for the project package you want to install.
- Click on the "Install" button to add the selected package to your project.
- Follow any additional setup instructions or configurations provided in the project's documentation.
Downloading Source Code and Direct Linking:
To install the project by downloading the source code and directly linking it to your project, adhere to the following steps:
- Visit the project repository on GitHub
- Click on the "Code" button and select "Download ZIP" to download the project's source code as a zip archive.
- Extract the downloaded zip archive to the desired location on your local machine.
- Open your existing project or create a new one in your IDE.
- Add the downloaded project files to your solution using the "Add Existing Project" option in your IDE's solution explorer.
- Reference the project in your solution and ensure any required dependencies are resolved.
- Follow any additional setup or configuration instructions provided in the project's documentation.
Please note that each method may have specific requirements or configurations that need to be followed for successful installation. Refer to the project's documentation for any additional steps or considerations.
Do not forget to download and install appropriate localization pack from GitHub.
Usage
Update Delivery System
BotBuilder.NewBuilder()
.CustomDelivery(new AdvancedDeliverySystem())
.Build()
.Listen();
Design your message
var mes = new OutputMessageText("Message with inline menu");
var menu = new InlineMenu();
menu.Add(someCallback);
menu.Add(new UrlButton("Href", "https://linktoyoursource.example");
mes.Menu = menu;
var mes = new OutputMessageText("Message with reply menu");
var menu = new ReplyMenu()
{
ColumnsCount = 2,
};
menu.Add("Text instead of button");
menu.Add(new RelpyButton("Text but button"));
menu.Add(new RequestUserButton("Request User", 242085, true).OnlyUsers());
mes.Menu = menu;
Build content on context
var mes = new MultiblockMessage("display.localkey");
mes.ContentBuilder = Localize;
async Task<MultiblockMessage> Localize(MultiblockMessage sender, ICastedUpdate? update)
{
var key = sender.GetBody();
var text = update?.Owner.ResolveBotString(key) ?? key;
return new MultiblockMessage(text);
}
Contributors
Currently, there are no contributors actively involved in this project. However, our team is eager to welcome contributions from anyone interested in advancing the project's development.
We value every contribution and look forward to collaborating with individuals who share our vision and passion for this endeavor. Your participation will be greatly appreciated in moving the project forward.
Thank you for considering contributing to our project.
License
This project is distributed under the terms of the MIT License.
Copyright (C) SKitLs 2023
Developer contact
For any issues related to the project, please feel free to reach out to us through the project's GitHub page. We welcome bug reports, feedback, and any other inquiries that can help us improve the project.
You can also contact the project owner directly via their GitHub profile at the following link or email: skitlsdev@gmail.com
Your collaboration and support are highly appreciated, and we will do our best to address any concerns or questions promptly and professionally. Thank you for your interest in our project.
Notes
Thank you for choosing our solution for your needs, and we look forward to contributing to your project's success.
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net6.0 is compatible. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 was computed. 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. |
-
net6.0
- SKitLs.Bots.Telegram.ArgedInteractions (>= 1.3.3)
- SKitLs.Bots.Telegram.Core (>= 2.1.3)
- Telegram.Bot (>= 19.0.0)
NuGet packages (3)
Showing the top 3 NuGet packages that depend on SKitLs.Bots.Telegram.AdvancedMessages:
Package | Downloads |
---|---|
SKitLs.Bots.Telegram.PageNavs
Allows to create special navigational menus. An extension project built upon the SKitLs.Bots.Telegram.Core Framework. |
|
SKitLs.Bots.Telegram.BotProcesses
Provides methods of creating bot processes with advanced textual input mechanics. An extension project built upon the SKitLs.Bots.Telegram.Core Framework. |
|
SKitLs.Bots.Telegram.DataBases
Package Description |
GitHub repositories
This package is not used by any popular GitHub repositories.
Version | Downloads | Last updated | |
---|---|---|---|
3.0.3 | 204 | 3/26/2024 | |
3.0.3-alpha2 | 56 | 3/25/2024 | |
3.0.3-alpha1 | 92 | 3/25/2024 | |
3.0.3-alpha0 | 93 | 3/25/2024 | |
3.0.2 | 157 | 3/25/2024 | |
3.0.1 | 104 | 3/25/2024 | |
3.0.0 | 107 | 3/24/2024 | |
3.0.0-alpha3 | 97 | 3/24/2024 | |
3.0.0-alpha2 | 104 | 3/24/2024 | |
3.0.0-alpha1 | 97 | 3/24/2024 | |
3.0.0-alpha0 | 100 | 3/23/2024 | |
2.2.1 | 158 | 3/21/2024 | |
2.2.1-alpha1 | 161 | 9/9/2023 | |
2.2.1-alpha0 | 118 | 9/9/2023 | |
2.2.0 | 381 | 8/19/2023 | |
2.1.1 | 197 | 8/13/2023 | |
2.0.3 | 197 | 8/13/2023 | |
2.0.2 | 195 | 8/13/2023 | |
2.0.1 | 313 | 8/12/2023 | |
2.0.0 | 186 | 8/11/2023 | |
1.1.0 | 256 | 8/2/2023 | |
1.0.0 | 307 | 7/25/2023 |
(+) IClonable support Added to:
1. IOutputMessage implementations
2. IMessageMenu implementations