Not logged in. · Lost password · Register
Forum: agsXMPP RSS
Avatar
anvu85 #1
Member since Jan 2013 · 5 posts
Group memberships: Members
Show profile · Link to this post
Subject: How to use XEP-0184 with agsXMPP library
Hi Alex,
I am writing a xmpp client using agsXMPP, not Matrix, and I have to implement XEP-0184 message delivery receipts or ACK in order to send back an ACK to a device after my client receives and process a command sent by that device.
How should I implement this protocol? My client and my device can chat to each other already. I also implemented my receipt/ACK message to look like the example provided by the XEP-0184 Protocol:
  1. <message
  2.     from='kingrichard@royalty.england.lit/throne'
  3.     id='bi29sg183b4v'
  4.     to='northumberland@shakespeare.lit/westminster'>
  5.  <received xmlns='urn:xmpp:receipts' id='richard2-4.1.247'/>
  6. </message>

But is this enough? Since when I do iq with disco#info from Spark to my client:
  1. <iq from='northumberland@shakespeare.lit/westminster'
  2.     id='disco1'
  3.     to='kingrichard@royalty.england.lit/throne'
  4.     type='get'>
  5.  <query xmlns='http://jabber.org/protocol/disco#info'/>
  6. </iq>
I don't see <feature var='urn:xmpp:receipts'/> response from my client.
How do I use agsXMPP to confirm that my client support that 'urn:xmpp:receipts' namespace?
This post was edited on 2015-07-29, 12:09 by Alex.
Avatar
Alex #2
Member since Feb 2003 · 4322 posts · Location: Germany
Group memberships: Administrators, Members
Show profile · Link to this post
Quote by anvu85:
Hi Alex,
I am writing a xmpp client using agsXMPP, not Matrix, and I have to implement XEP-0184 message delivery receipts or ACK in order to send back an ACK to a device after my client receives and process a command sent by that device.
How should I implement this protocol?

It is in the  agsXMPP.protocol.extensions.msgreceipts namespace. Just add those objects as a children to your messages-

  1. msg.Add(new Request());

Quote by anvu85:
I don't see <feature var='urn:xmpp:receipts'/> response from my client.
How do I use agsXMPP to confirm that my client support that 'urn:xmpp:receipts' namespace?

by using a DiscoManager and adding this to your DiscoInfo in XmppClientConnection

Alex
Avatar
anvu85 #3
Member since Jan 2013 · 5 posts
Group memberships: Members
Show profile · Link to this post
Thanks Alex,
I'll try it.
An.
Close Smaller – Larger + Reply to this post:
Verification code: VeriCode Please enter the word from the image into the text field below. (Type the letters only, lower case is okay.)
Smileys: :-) ;-) :-D :-p :blush: :cool: :rolleyes: :huh: :-/ <_< :-( :'( :#: :scared: 8-( :nuts: :-O
Special characters:
Forum: agsXMPP RSS