npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

epic-games-store-crawler

v0.2.1

Published

A crawler to retrieve store data from the Epic Games store

Downloads

11

Readme

epic-games-store-crawler

epic-games-store-crawler is a crawler, which retrieves data from the Epic Games Store. It's purpose is to provide easy to access methods to crawl specific store data such as current game prices, free games, categories, etc.

Installation

Install using npm

npm install epic-games-store-crawler

Install using yarn

yarn add epic-games-store-crawler

Install using source

Clone the repository
git clone https://github.com/DonkeyCo/epic-games-store-crawler.git

Install dependencies
npm install or yarn install

Run build script
npm run build or yarn run build

Use files in dist folder for coding

Usage

Import module

To use epic-games-store-crawler you have to import it: \

// with require
var egsCrawler = require('epic-games-store-crawler)';
var crawler = egsCrawler.Crawler;
// with import
import { Crawler } from 'epic-games-store-crawler';

Using module - Examples

1 - Crawling catalog items

Crawler.getItems({
    allowedCountries: 'DE',
    category: 'games/edition/base|bundle/games|editors',
    count: 30,
    country: 'DE',
    locale: 'de'
});
{
    "Catalog": {
        "searchStore":{
            "elements":[{
                "title":"Generic Game",
                "id":"3x4mpl31d",
                "namespace":"example",
                "description":"Generic Description",
                "seller": {
                    "name":"Generic"
                },
                "price": {
                    "totalPrice": {
                        "discountPrice":0,
                        "originalPrice":0,
                        "voucherDiscount":0,
                        "discount":0,
                        "currencyCode":"EUR",
                        "currencyInfo": {
                            "decimals":2
                        }
                    }
                },
                "promotions": { 
                    "promotionalOffers": [{
                        "promotionalOffers":[{
                            "startDate":"2020-08-13T15:00:00.000Z",
                            "endDate":"2020-08-20T15:00:00.000Z"
                        }]
                    }]
                }
            }]
        }
    }
}

2 - Crawling free games

Crawler.getFreeGames({
    allowCountries: 'DE',
    country: 'DE',
    locale: 'de'
});
// Returns
{
    "Catalog": {
        "searchStore":{
            "elements":[{
                "title":"Generic Game",
                "id":"3x4mpl31d",
                "namespace":"example",
                "description":"Generic Description",
                "seller": {
                    "name":"Generic"
                },
                "price": {
                    "totalPrice": {
                        "discountPrice":0,
                        "originalPrice":0,
                        "voucherDiscount":0,
                        "discount":0,
                        "currencyCode":"EUR",
                        "currencyInfo": {
                            "decimals":2
                        }
                    }
                },
                "promotions": { 
                    "promotionalOffers": [{
                        "promotionalOffers":[{
                            "startDate":"2020-08-13T15:00:00.000Z",
                            "endDate":"2020-08-20T15:00:00.000Z"
                        }]
                    }]
                }
            }]
        }
    }
}

3 - Crawling catalog tags

Crawler.getCatalogTags({
    namespace: 'epic',
    locale: 'de',
    start: 0,
    count: 999
});
// Returns
{
    "Catalog": {
        "tags": {
            "elements": [{
                "aliases": [],
                "id":"9547",
                "name":"WINDOWS",
                "referenceCount":259,
                "status":"ACTIVE"  
            }]
        }
    }
}

4 - Crawling news

Crawler.getNews('de', 30);
[{
    "jcr:isCheckedOut":true,
    "link":"/path/to/something",
    "_title":"title",
    "_noIndex":false,
    "_images_":[
        "https://example.com/image.png"
    ],"jcr:baseVersion":"abc-def-ghi",
    "_urlPattern":"/path/to/something",
    "lastModified":"2020-08-13T14:28:09.556Z",
    "_locale":"de",
    "_id":"abc-def-ghi",
    "trending":false,
    "image":"https://example.com/image.png",
    "trendingImage":"https://example.com/image.png",
    "cat":"Launcher",
    "_type":"Common Post Link",
    "sticky":false,
    "short":"Short text. Lorem Ipsum",
    "title":"Title. Lorem Ipsum",
    "date":"2020-08-13T19:00:00.000Z",
    "externalLink":"/path/to/something",
    "slug":"this-is-a-slug",
    "url":"/path/to/something",
    "urlPattern":"/path/to/something"
}]

Contribution

If you are interested in contributing, feel free to create a PR or an issue.