about summary refs log tree commit diff stats
path: root/include/YtdlpWrapper.hpp
blob: 9ee241024b6e039825417f01ecdd57e009aa1c9f (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#ifndef YTDLPWRAPPER_H
#define YTDLPWRAPPER_H
#include <string>
#include <vector>
#include <iostream>
#include <pybind11/embed.h>
#include <nlohmann/json.hpp>

class YtdlpWrapper {

    public:
        nlohmann::json getJsonSearch(const std::string& searchTerm, int limit = 1);
        Video::video getVideoByUrl(const std::string& url);
        std::vector<Video::video> searchVideos(const std::string& searchterm, int limit = 1);
    private:
        pybind11::object get_ytdl();       
}; 


#endif