summaryrefslogtreecommitdiff
path: root/src/uaLookup.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/uaLookup.hpp')
-rw-r--r--src/uaLookup.hpp16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/uaLookup.hpp b/src/uaLookup.hpp
new file mode 100644
index 0000000..5492f05
--- /dev/null
+++ b/src/uaLookup.hpp
@@ -0,0 +1,16 @@
+#pragma once
+
+#include <curl/curl.h>
+#include <stdexcept>
+#include <string>
+
+namespace WebStat {
+ class CurlError : public std::runtime_error {
+ public:
+ explicit CurlError(CURLcode code, const char * msg) : std::runtime_error {msg}, code(code) { }
+
+ CURLcode code;
+ };
+
+ std::string getUserAgentDetail(std::string_view uas, const char * baseUrl = "https://useragentstring.com");
+}