Giter VIP home page Giter VIP logo

greg-agent's Introduction

greg-agent ๐ŸŒฑ

Exposes a read-only JSON API which lists basic information about the plants you've registered in the Greg app, including:

  • Plant Nickname
  • Plant Species
  • Plant Health (boolean value)
  • Thumbnail and Public Sharing URLs

I made this app for fun and to learn more about Express and Docker - I have no connection to the team behind the Greg app, apart from being an app user myself!

Authentication

To use this app, you'll need your bearer token from the Greg app. This can be extracted using packet sniffing software, which can read HTTPS requests from your phone and thus extract the bearer token from the request header. I used Charles. Using this app means your bearer token remains private, yet basic information about your plants is available on the web via a JSON API!

Important
Accessing internal APIs may represent a violation of the ToS for the service you're using. I spoke to the team at Greg who encouraged me to use their internal APIs for this project. Please make your own informed decisions when using this code, and reach out to the Greg team directly before deploying this server.

Configuration

This app is configured using environment variables. The following options are supported:

Key Mandatory? Comments
SVR_GREG_TOKEN Yes A valid bearer token for the Greg API
SVR_PORT No By default, server will listen on 3000
SVR_REFRESH_INT No Cache refresh interval. The default is set to 1800 seconds (30 mins)

greg-agent's People

Contributors

abiddiscombe avatar

Stargazers

 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.