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

daedalus-server

v0.2.1

Published

A deployable API server using express.js and my own npm package: crystalys!

Downloads

5

Readme

Daedalus

A deployable API server using express.js, crystalys, and demon-edge!

The Daedalus tool suite will help you hit the ground running with your new Dota 2 related project!

Set up is painless, and the whole tool suite is easy to use! (At least I like to think)

The other parts of this tool suite, crystalys and demon-edge are there to make your life easier as well!

In order to get Daedalus set up, there are a few quick steps you need to follow:

##Step 0: Pre-requisites

All you need in order to use this tool suite is:

  • node
  • npm
  • git

##Step 1: Obtain a Steam API key

You can grab your own API key from Steam here.

Just sign in to steam, and click on the button to have it generated for you!

##Step 2: Install and configure daedalus-server

Run git clone https://github.com/Flascher/daedalus.git and you've now got yourself a copy!
To configure daedalus-server open up the daedalus folder, then edit config.json.

You should see these defaults:

{
  "apiKey": "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
  "domain": "0.0.0.0",
  "port":   "80",
  "corsEnabled": false
}

The apiKey should be replaced with your API key you got in Step 1.
The domain and port are meant to tell daedalus where its running (these are just passed into Express.js app.listen function)
The corsEnabled key is false by default, but if you intend to connect to your server from a separate domain, you'll need to make this true.

##Step 3: Start the server

You can accomplish this one of two ways:

  • cd into the daedalus root folder and run npm start
  • Run node path/to/daedalus/src/index.js

Congrats! You're now running a daedalus-server that will act as a proxy to Valve's Web API!

##Ok, but why?

One of the agreements you accepted with Valve when you signed up for an API key is that you would not distribute that API key to anyone else. This means that if you make calls to their API server from the client side, you are exposing your API key to users and thus breaking their agreement.

Plus I think making some function calls like:

DemonEdge.api.Match.GetMatchHistory.heroID(1).matchesRequested(30).sendRequest();

is much easier than hard coding a string to https://api.steampowered.com/IDOTA2Match_570/GetMatchHistory/v1?key=xxxx&hero_id=1&matches_requested=30, but maybe that's just me.

##Bugs

As of right now, there are no currently known bugs within the Daedalus tool suite, but please, if you find any bugs in any part of the tool suite, create an issue on the corresponding tool's github repo, or send me an email at [email protected].

Thanks so much, and I hope you enjoy the Daedalus tool suite!