@expertcomptabledev/impots.gouv.bot
v0.7.6
Published
A bot to crawl impots.gouv.fr
Downloads
96
Maintainers
Readme
impots.gouv.bot
Impots.gouv.bot is a tool to crawl http://www.impots.gouv.fr pro account, and get all informations available with cli
or with node module
.
Requirements
To use impots.gouv.bot, you must install :
- node.js >= 9.X
Get started
- Install cli using npm
npm install -g @expertcomptabledev/impots.gouv.bot
- Try login command
➜ ~ impots login --email <your-email> --password <your-password>
@expertcomptabledev/impots.gouv.bot ✔ success Logged in your impot.gouv.fr account
How to
Use CLI commands
All commands must use impots
prefix, ex. ➜ ~ impots login ...
You can ask help everywhere using --help
flag.
login
: test login into your account (OK)companies
: get list of your companies (OK)declarations
: get declarations by type (in progress)declare
: get declare view by type (OK)
Use lib in node project
- Install impots.gouv.bot into your project using
npm install @expertcomptabledev/impots.gouv.bot --save
- Import impots.gouv.bot into your code
import * as impots from '@expertcomptabledev/impots.gouv.bot';
- Use it !
const companies = await impots.getCompanies(email, password);
Must print in your console a table with your companie list.
Below an example of list formatted into table using tty-table
:
┌───────┬───────────┬──────────────────────────────┐
│ # │ SIREN │ Name │
├───────┼───────────┼──────────────────────────────┤
│ 1 │ XXX1X6X9X │ SAS XLA AXSUXXNXES │
├───────┼───────────┼──────────────────────────────┤
│ 2 │ XX9X614X5 │ SAS XXXEXCAP XXXXNCE │
├───────┼───────────┼──────────────────────────────┤
...