This repository contains an easy-to-use and well-documented .NET assembly for communicating with an XMPP server. It supports basic Instant Messaging and Presence funtionality as well as a variety of XMPP extensions.
The library fully implements the XMPP Core and XMPP IM specifications and thusly provides the basic XMPP instant messaging (IM) and presence functionality. In addition, the library offers support for most of the optional procotol extensions. More specifically, the following features are supported:
-
XEP-0004 Data Forms
-
XEP-0020 Feature Negotiation
-
XEP-0030 Service Discovery
-
XEP-0045 Multi-User Chat
-
XEP-0047 In-Band Bytestreams
-
XEP-0055 Jabber Search
-
XEP-0059 Result Set Management
-
XEP-0065 SOCKS5 Bytestreams
-
XEP-0077 In-Band Registration
-
XEP-0082 XMPP Date and Time Profiles
-
XEP-0084 User Avatar
-
XEP-0085 Chat State Notifications
-
XEP-0092 Software Version
-
XEP-0095 Stream Initiation
-
XEP-0096 SI File Transfer
-
XEP-0107 User Mood
-
XEP-0108 User Activity
-
XEP-0115 Entity Capabilities
-
XEP-0118 User Tune
-
XEP-0136 Message Archiving
-
XEP-0153 vCard-Based Avatars
-
XEP-0163 Personal Eventing Protocol
-
XEP-0191 Blocking Command
-
XEP-0199 XMPP Ping
-
XEP-0202 Entity Time
-
XEP-0203 Delayed Delivery
-
XEP-0224 Attention
-
XEP-0231 Bits of Binary
-
XEP-0279 Server IP Check
-
XEP-0280 Message Carbons
-
XEP-0313 Message Archive Management
-
XEP-0363 HTTP Upload File
-
Simplified Blocking
-
API designed to be very easy to use
-
Well documented with lots of example code
-
Free to use in commercial and personal projects (MIT License)
You can always get the latest binary package on Nuget or download the binaries as a .zip archive from GitHub. The documentation is also available for offline viewing as HTML or CHM and can be downloaded from here and here, respectively.
To use the library add the Net.Xmpp.dll assembly to your project references in Visual Studio. Here's a simple example that initializes a new instance of the XmppClient class and connects to an XMPP server:
using System;
using Net.Xmpp;
using Net.Xmpp.Client;
namespace Test {
class Program {
static void Main(string[] args) {
/* connect on port 5222 using TLS/SSL if available */
using (var client = new XmppClient("jabber.se", "username", "password"))
{
Console.WriteLine("Connected as " + client.Jid);
}
}
}
}
Please see the documentation for a getting started guide, examples and details on using the classes and methods exposed by the Net.Xmpp assembly.
The Net.Xmpp library is copyright © 2020 LUZ Soluções Financeiras. The previous Sharp.Xmpp library is copyright © 2015 Panagiotis Georgiou Stathopoulos. The initial S22.Xmpp library is copyright © 2013-2014 Torben Könke.
This library is released under the MIT license.