#pragma once #include #include #include "PokemonCard.h" /** @brief direct api access class */ class PokemonTCGAPIClient { public: PokemonTCGAPIClient(); virtual ~PokemonTCGAPIClient(); private: const char* API_URL = "https://api.pokemontcg.io/v2"; virtual nlohmann::json raw_request(const char* endpoint, cpr::Parameters params); virtual nlohmann::json raw_get_cards(const char* query); virtual nlohmann::json raw_get_card(const char* id); virtual nlohmann::json raw_get_sets(const char* query); public: virtual std::vector get_cards_by_query(const char* query); virtual std::vector get_set_cards(const char* set_name); virtual PokemonCard* get_full_card(const char* id); virtual std::vector get_sets(); };