mirror of
https://github.com/HamletDuFromage/aio-switch-updater.git
synced 2024-11-14 06:06:43 +00:00
21 lines
No EOL
642 B
C++
21 lines
No EOL
642 B
C++
#pragma once
|
|
|
|
#define ON 1
|
|
#define OFF 0
|
|
|
|
#include <time.h>
|
|
#include <math.h>
|
|
#include <curl/curl.h>
|
|
|
|
#include <string>
|
|
#include <regex>
|
|
#include <switch.h>
|
|
|
|
#include "progress_event.hpp"
|
|
#include "json.hpp"
|
|
|
|
void downloadFile(const char *url, const char *output, int api);
|
|
std::tuple<std::vector<std::string>, std::vector<std::string>> fetchLinks(const char *url);
|
|
std::string fetchTitle(const char *url);
|
|
std::string downloadPage(const char* url, std::vector<std::string> headers = {}, std::string body = "");
|
|
nlohmann::json getRequest(std::string url, std::vector<std::string> headers = {}, std::string body = ""); |