static void Main(string[] args) { AppModel appModel = PlayStoreScraper.ParseAppUrls("/store/apps/details?id=com.NNGames.starchef_android").Result; Console.WriteLine($"App Name: {appModel.Name}, App URL: {appModel.Url}, {appModel.CurrentVersion}, {appModel.CoverImageUrl}"); }
static void Main(string[] args) { // Initialize all of the possible proxies ProxyLoader.InitializeProxies(); // These keywords should be given to me. Each keyword has a different proxy // Before running a keyword, you should check if proxy is working (anything other than 200 means that we should try another one) // get these keywords from the database string[] keywords = { "Russia" }; // get them from the database as well string[] categories = { "store/apps/collection/topselling_free", "store/apps/collection/topselling_paid", "store/apps/collection/topselling_new_free" }; //string[] fieldNames = { // "Url", "ScrapedDate", "Name", "Developer", "IsTopDeveloper", "DeveloperURL", "PublicationDate", // "Category", "IsFree", "Price", "CoverImageUrl", "Description", "ReviewScore", "ReviewTotal", // "FiveStarsReviews", "FourStarsReviews", "ThreeStarsReviews", "TwoStarsReviews", // "OneStarReviewCount", "AppSize", "Installs", "CurrentVersion", "MinimumOSVersion", "ContentRating", // "HaveInAppPurchases", "InAppPriceRange", "DeveloperEmail", "DeveloperWebsite", "DeveloperPrivacyPolicy" //}; //string outputFilePath = @"./result"; PlayStoreScraper.CrawlByCategories(categories, 1000); // This one is working //PlayStoreScraper.CrawlByKeywords(keywords, 1000); Console.ReadLine(); }
static void Main(string[] args) { string[] keywords = { "game", "browser" }; string[] fieldNames = { "Url", "ScrapedDate", "Name", "Developer", "IsTopDeveloper", "DeveloperURL", "PublicationDate", "Category", "IsFree", "Price", "CoverImageUrl", "Description", "ReviewScore", "ReviewTotal", "FiveStarsReviews", "FourStarsReviews", "ThreeStarsReviews", "TwoStarsReviews", "OneStarReviewCount", "AppSize", "Installs", "CurrentVersion", "MinimumOSVersion", "ContentRating", "HaveInAppPurchases", "InAppPriceRange", "DeveloperEmail", "DeveloperWebsite", "DeveloperPrivacyPolicy" }; string outputFilePath = @"./result"; IExporter exporter = null; // Export to CSV file. // NOTE: You can also implement your own Exporter class. // Please see IExporter and CSVExporter class for example. exporter = new CSVExporter(outputFilePath + ".csv", fieldNames); // Start crawling for the keywords with maximum 30 Apps result and download delay 1 second. PlayStoreScraper.Crawl(keywords, exporter, 30, 1000); // Same example with exporting to JSON file exporter = new JSONExporter(outputFilePath + ".json", fieldNames); PlayStoreScraper.Crawl(keywords, exporter, 30, 1000); // Same example with callback method PlayStoreScraper.Crawl(keywords, null, 30, 1000, appModel => { Console.WriteLine("App Name: {0}, App URL: {1}", appModel.Name, appModel.Url); }); }