🧾 My personal CLI app to manage my invoices via Web Scraping.

Overview

ALM Invoices CLI

License: MIT

My personal CLI (Command Line Interface) app to manage my invoices via Web Scraping.

WIP (Work in Progress): For now only the list command is fully implemented. The generate command will be finished in the next couple of weeks.

Motivation

I'm using a SaaS (Software as a Service) to generate invoices in my own company however it doesn't provide/expose an API for developers like me that want to automate tedious tasks! Do I have a solution? Of course, as a developer nothing is impossible! Via Web Scrapping (with a headless browser to perform browser automation) I'm able to interact with the Web Application and perform all the operations.

Technologies

  • Typescript (selected ES2020 as target because I assume Node.js version 14 or higher is being used)
  • Node.js
  • Puppeteer (headless browser automation)
  • ESLint + Prettier + Husky
  • Yarn
  • Pkg (create executable file)
  • Meow (parse command line arguments + help functionalities) - I could use Yargs, OCLIF, Commander.js, or other CLI libraries for more complex CLI applications
  • Inquirer.js (to ask questions to the user)

Btw, as I'm talking about CLI apps, there is another cool package that you can use to simplify shell commands executions if needed: Sheeljs.

How to execute the CLI

As I'm not distributing the CLI to the public / NPM registry, you can install it globally in your machine via Yarn or NPM:

  yarn global add .
  # OR
  npm install -g .

Let’s say I want to distribute this for only certain persons that don't have a proper Node environment in their machine. For that, I package my CLI as a single executable, using the pkg module from Vercel. The binary is available in the bin/<os> folder (also available in compressed format). For now, only macOS is supported.

Requirements: Set up the following environment variables (please check .env.example): USER_INVOICE, INVOICE_URL and PWD_INVOICE in your system.

Resources

https://medium.com/geekculture/building-a-node-js-cli-with-typescript-packaged-and-distributed-via-homebrew-15ba2fadcb81

https://kirablog.hashnode.dev/build-a-cli-using-nodejs#heading-adding-logic

License

MIT License © alexmarqs

You might also like...

A command-line tool to manage Deno scripts installed via deno install

🏞️ nublar nublar is a command-line tool to manage your scripts installed via deno install. 🛳️ Installation deno install --allow-read --allow-write -

Dec 26, 2022

A simple web app to manage your time and energy wisely with to do list app.

To Do list Manage your time and energy wisely with to list app. Built With HTML, CSS JavaScript, Webpack Live Demo Live Demo Link Getting Started To g

Oct 21, 2022

🤗 A CLI for running Stable Diffusion locally via a REST API on an M1/M2 MacBook

Stable Diffusion REST API A CLI for running Stable Diffusion locally via a REST API on an M1/M2 MacBook Pre-requisites An M1/M2 MacBook Homebrew Pytho

Dec 26, 2022

Atlan is a CLI that helps you to manage local dockerized infrastructure without any needed knowledge on Docker and Docker Compose.

Atlan is a CLI that helps you to manage local dockerized infrastructure without any needed knowledge on Docker and Docker Compose.

Atlan CLI Atlan is a CLI that helps you to manage local dockerized infrastructure without any needed knowledge on Docker and Docker Compose. What is A

Aug 17, 2022

Tesodev-search-app - Personal Search App with React-Hooks

Tesodev-search-app - Personal Search App with React-Hooks

Tesodev-search-app Personal Search App with React-Hooks View on Heroku : [https://tesodev-staff-search-app.herokuapp.com/] Instructions Clone this rep

Nov 10, 2022

To-Do list a web app for tracking personal progress through the day. Users can input a list of tasks and mark them as completed once they are done. Built with JavaScript and Webpack

To-do-List-Project To Do List Project Description. This project creates a simple HTML list of To Do tasks. It was built using webpack and served by a

Jul 8, 2022

SimpleProject is a web app that allows users to create projects and manage them in a Kanban board.

SimpleProject is a web app that allows users to create projects and manage them in a Kanban board.

What is SimpleProject SimpleProject is a web app that allows users to create projects and manage them in a kanban board. SimpleProject was built with

Nov 23, 2022

Node-cli-starter - Basic starter kit for building Node CLI applications with TypeScript.

node-cli-starter Minimal starter kit for building Node CLI applications with TypeScript. Getting Started To get started clone repo locally and run npm

May 17, 2022

A CLI tool to create a NodeJS project with TypeScript CTSP is a CLI tool to make easier to start a new NodeJS project and configure Typescript on it.

A CLI tool to create a NodeJS project with TypeScript CTSP is a CLI tool to make easier to start a new NodeJS project and configure Typescript on it.

CTSP- Create TS Project A CLI tool to create a NodeJS project with TypeScript CTSP is a CLI tool to make easier to start a new NodeJS project and conf

Sep 13, 2022
Comments
  • chore(deps): bump minimist from 1.2.5 to 1.2.6

    chore(deps): bump minimist from 1.2.5 to 1.2.6

    Bumps minimist from 1.2.5 to 1.2.6.

    Commits

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    • @dependabot use these labels will set the current labels as the default for future PRs for this repo and language
    • @dependabot use these reviewers will set the current reviewers as the default for future PRs for this repo and language
    • @dependabot use these assignees will set the current assignees as the default for future PRs for this repo and language
    • @dependabot use this milestone will set the current milestone as the default for future PRs for this repo and language

    You can disable automated security fix PRs for this repo from the Security Alerts page.

    dependencies 
    opened by dependabot[bot] 0
Owner
Alexandre Marques
Tech Dev @ 🌍 💻
Alexandre Marques
Web app that generates BOLT11 invoices from an LNURL or Lightning Address.

LNURL Pay ⚡️ Web app that generates BOLT11 invoices from an LNURL or Lightning Address. Getting Started First, run the development server: npm run dev

Sam Samskies 7 Nov 3, 2022
A simple backend app for managing invoices and tracking their payments for the Monero cryptocurrency.

Simpla Vendejo API This app runs a view-only Monero wallet to verify payments and keeps track of them in a MySQL database. /create_invoice Method: POS

Ben Evanoff 6 Jun 30, 2022
An API built for an invoices manager app using TypeScript and Prisma with Node and Express.

Invoices App API An API built for the invoices manager app using TypeScript and Prisma with Node and Express. Run locally To run locally, you need to

Waleed Alfaifi 4 Oct 17, 2022
A simple library that I use for web scraping. Uses htmlparser2 to parse dom.

Docpa A simple library that I use for web scraping. Uses htmlparser2 to parse dom. Usage const Docpa = require("docpa") const doc = new Docpa(`<html>

Roshan Acharya 2 Jan 21, 2022
A web scraping / data mining script for extracting beginner-friendly github repos from Y Combinator's company database

A web scraping / data mining script for extracting beginner-friendly github repos from Y Combinator's company database

Oscar Mier 27 Nov 24, 2022
App to manage maintenance calls. App to manage maintenance calls. This application was created for the purpose of studies.

App to manage maintenance calls. App to manage maintenance calls. This application was created for the purpose of studies.

Rodrigo Gonçalves 112 Dec 26, 2022
Scraping data dari 21cineplex untuk keperluan hobby dan riset, tidak ada hal yang berbahaya atau dapat merugikan website sumber.

21cineplex-api Scraping data dari 21cineplex untuk keperluan hobby dan riset, tidak ada hal yang berbahaya atau dapat merugikan website sumber. Softwa

Vava Heirro 8 Jun 25, 2022
Dump of a 5 day small scale data scraping project on the io game "arras.io"

Arras DB A bot built to scan all arras.io game servers (besides sandbox) in search of bulk server and player data. This bot was run 5 days straight, a

ABC 3 Jul 19, 2022
A personal semantic search engine capable of surfacing relevant bookmarks, journal entries, notes, blogs, contacts, and more, built on an efficient document embedding algorithm and Monocle's personal search index.

Revery ?? Revery is a semantic search engine that operates on my Monocle search index. While Revery lets me search through the same database of tens o

Linus Lee 215 Dec 30, 2022