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

@earnkeeper/ekp-sdk-nestjs

v2.0.3

Published

The Nest.js software development kit for EarnKeeper.io plugins

Downloads

72

Readme

EKP - Earnkeeper Plugins

ekp is the plugin system for earnkeeper.io. It allows you to scrape the blockchain for the information you want to see and display it in tables and graphs for everyone.

screenshot of earnkeeper plugins page

Why?

We started earnkeeper.io to provide unbiased, detailed and honest analysis of projects in the cryptocurrency Play 2 Earn space.

Games are being released in this space very quickly, and we can cover only a very small portion of them. Our community on Discord is already brimming with users who love the site and want to help.

We don't want to open source the site itself, as it would be impossible to provide a secure experience to those who trust https://earnkeeper.io showing at the top of their browser.

So instead, we are exposing as much functionality as we possibly can through a websocket specification to any externally hosted webservice.

We love https://dune.xyz, it gets low skill users into a place where they can create analytics very quickly. But we got stuck trying to model certain games, it didn't have the power we needed, and its quite difficult to personalize the results to your users.

We are trying to find a way to give developers the power they need for complex analysis, and the flexibility for personalized display results. All while being able to block dangerous interactions with user's wallets.

This repository contains the specification, and a starter project in node.js to get you up and running. Join our Discord to get help or information directly!

Getting Started

Fork and clone this repository.

It contains a fully functioning plugin, which we actually use on https://app.earnkeeper.io.

We don't want to re-invent the wheel, so we use the following open source libraries and frameworks in our code:

  • Typescript
  • NestJs
  • Socket.io
  • TypeORM
  • Postgres
  • EthersJs
  • JsonForms
  • Werf
  • Docker
  • Kubernetes
  • Helm
  • Grafana Loki
  • NocoDB

You are free to use any you like, its your plugin after all! You don't even have to use javascript, it can be python, go, whatever you like to develop in. All we specify is a protocol that earnkeeper.io understands.

This project is only intended to get you a start in the language and frameworks that we use ourselves.

We use github to host our code, and github actions to automate our deploys.

To run the example plugin locally...

Create a .env file in the root of the ekp directory:

BSCSCAN_API_KEY=
DATABASE_URL=postgres://postgres:postgres@localhost:5432/ekp
DATABASE_SSL=disable

Append your BSC SCAN api key to the end of the first line, you can create one here.. You will use this key to pull logs from the blockchain.

Append your Moralis API details to the end of the last two lines, you can create a free Moralis server and get your details here and here.

You will need a postgres database running on your local machine, if your connection details are different for your local instance, you can change them on the second line.

Then run the following to start the app locally.

yarn install
nest start farms

Go to https://playground.earnkeeper.io/plugins, add a new plugin with url: http://localhost:3001.

After clicking save, you should see the same list of farms that you see on the main site!

You can continue to make changes to your local, and these changes will immediately reflect at https://playground.earnkeeper.io.

Once you are ready to share your creation with the world, follow the deploy instructions below, and share the public host name of your provider with users, they will add your plugin in exactly the same way.

Talk to us in Discord about bundling your plugin with the official earnkeeper site, so that everyone has access to it!

Deployment

Once you are ready to deploy, check out the deployment instructions here.