code: public void saveMacros(MacroGroup group) throws NoResponseException, XMPPErrorException, NotConnectedException, InterruptedException {
          Macros request = new Macros();
          request.setType(IQ.Type.set);
          request.setTo(workgroupJID);
          request.setPersonal(true);
          request.setPersonalMacroGroup(group);
  
          connection.createStanzaCollectorAndSend(request).nextResultOrThrow();
      }
docs: Persists the Personal Macro for an agent.
  
  @param group the macro group to save.
  @throws XMPPErrorException
  @throws NoResponseException
  @throws NotConnectedException
  @throws InterruptedException