/* * distroquery_api - API for querying data generated by distromatic * * Copyright (C) 2024 by Silvan Calarco * * This program is free software; you can redistribute it and/or modify it under * the terms of version 2 of the GNU General Public License as published by the * Free Software Foundation. * * This program is distributed in the hope that it will be useful, but WITHOUT * ANY WARRANTY, to the extent permitted by law; without even the implied * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. * See the GNU General Public License for more details. * * You should have received a copy of the GNU General Public License along with * this program; if not, write to the Free Software Foundation, Inc., * 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA. */ #ifndef __DISTROQUERY_API_H #define __DISTROQUERY_API_H #define API_PREFIX "/api/v1/" #include #include #include #include #include "config.h" using namespace std; using json = nlohmann::json; class DistroqueryAPI { public: DistroqueryAPI(configTag* conf); void getApiResponse(string path_info); private: configTag *config; json configToJsonRepositories(); }; #endif // __DISTROQUERY_API_H