/****************************************************************************
 * This file is part of the project AqHome.
 * AqHome (c) by 2025 Martin Preuss, all rights reserved.
 *
 * The license for this file can be found in the file COPYING which you
 * should have received along with this file.
 ****************************************************************************/

#ifndef AQHOME_CGI_MDATACLIENT_H
#define AQHOME_CGI_MDATACLIENT_H

#include <aqhome-cgi/modules/common/mservice.h>

#include <aqcgi/request.h>

#include "aqhome/aqhome.h"
#include "aqhome/dataclient/client.h"

#include <gwenhywfar/buffer.h>



typedef void (*AQH_MODDATACLIENT_RUN_FN)(AQCGI_MODULE *m, AQCGI_REQUEST *rq, AQCGI_SESSION *session, AQH_DATACLIENT *dc, GWEN_BUFFER *dbuf);


void AQH_ModDataClient_Extend(AQCGI_MODULE *m, AQCGI_SERVICE *sv, const char *baseFolder);
void AQH_ModDataClient_HandleRequest(AQCGI_MODULE *m,
                                     AQCGI_REQUEST *rq,
                                     AQCGI_SESSION *session,
                                     AQH_MODDATACLIENT_RUN_FN runFn,
                                     GWEN_BUFFER *dbuf);




#endif

