Simple GET request works.
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
parent
0b525bb748
commit
cac3e0b505
|
@ -57,7 +57,7 @@ public:
|
|||
* @since 0.1.0
|
||||
*/
|
||||
[[nodiscard]]
|
||||
answer_type get(API::endpoint_type endpoint) const;
|
||||
answer_type get(API::endpoint_type endpoint);
|
||||
|
||||
/*!
|
||||
* @brief Make a HTTP GET call.
|
||||
|
@ -67,7 +67,7 @@ public:
|
|||
* @since 0.1.0
|
||||
*/
|
||||
[[nodiscard]]
|
||||
answer_type get(string endpoint) const;
|
||||
answer_type get(string endpoint);
|
||||
|
||||
private:
|
||||
Instance &_instance;
|
||||
|
|
|
@ -23,17 +23,17 @@ Request::Request(Instance &instance)
|
|||
: _instance{instance}
|
||||
{}
|
||||
|
||||
answer_type Request::get(API::endpoint_type endpoint) const
|
||||
answer_type Request::get(API::endpoint_type endpoint)
|
||||
{
|
||||
answer_type answer;
|
||||
answer.body = API{endpoint}.to_string();
|
||||
return answer;
|
||||
}
|
||||
|
||||
answer_type Request::get(string endpoint) const
|
||||
answer_type Request::get(string endpoint)
|
||||
{
|
||||
answer_type answer;
|
||||
answer.body = endpoint;
|
||||
answer.body = make_request(http_method::GET, "https://ip.tastytea.de/");
|
||||
return answer;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user