Giter Club home page Giter Club logo

ecommerce-analytics-middleware's Introduction

info

  • loads selected data from Magento/Google Analytics and uploads it (aggregated) to this NodeJS middleware to be shown in a Data-Model
  • confidential info (such as credentials) should be kept in the ./config/ folder

internal documentation from hackathon

https://lemundo.atlassian.net/wiki/spaces/DT/pages/2011758615/Ecommerce+Analytics

example data gathered

{"ga_users":"5327","ga_newusers":"4427","ga_sessions":"6229","orders_number":"32","items_ordered":"49","items_per_order":1.53125,"average_order_value":"45.43468750","revenue_month":"679.3900","revenue_year":"1453.9100","revenue_all_time":"1453.9100","data_source":"magento","created_at":"2021-12-22 15:35:20"}

steps taken

  • successfully gathered data from Magento and GA
  • got a dummy server working with GET and POST requests. It runs locally and is available through ngrok - Online in One Line.
    • [Source] there was a problem installing it on my machine. I’ve followed the instructions and ended up with zsh: command not found: ngrok. This was solved by typing this on the Terminal:
sudo mv ngrok /usr/local/bin
  • successfully sent JSON-encoded data to it through a POST request
  • successfully connected the node.js app to the BigQuery project.
  • created Table and Dataset in the Google Cloud project
  • programmed an NodeJS local function to receive GA data and send it to Google Cloud

requirements:

  • JSON file with credentials
  • @google-cloud/bigquery npm package
  • sample code used
  • user permissions granted to the Google Project’s client_email (you can see it in the JSON file)

ecommerce-analytics-middleware's People

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.