"use strict";

Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.getLastMessage = getLastMessage;
var _client = require("@xmpp/client");
function getLastMessage(client, roomJID) {
  const message = (0, _client.xml)('iq', {
    type: 'set',
    to: roomJID,
    id: 'GetArchive'
  }, (0, _client.xml)('query', {
    xmlns: 'urn:xmpp:mam:2'
  }, (0, _client.xml)('set', {
    xmlns: 'http://jabber.org/protocol/rsm'
  }, (0, _client.xml)('max', {}, '1'), (0, _client.xml)('before'))));
  client.send(message);
}
//# sourceMappingURL=getLastMessageArchive.xmpp.js.map