2.6.40 • Published 2 months ago

hajonsoft-eagle v2.6.40

Weekly downloads
-
License
ISC
Repository
-
Last release
2 months ago

🦅 Eagle

We control chrome using eagle. Eagle is built on top of puppeteer and can send data to any website.

Getting started

Note: for Apple M1 Chip choose "open with rosetta" when configuring your terminal in order to successfully install packages.

Once packages are installed via rosetta, you can use node . from a regular terminal without a problem.

You may need to install chromium via brew.

git clone https://github.com/hajonsoft/hajonsoft-eagle.git
cd hajonsoft-eagle
npm i
node . [file=FILENAME[.zip]] [noimage] [WORKFLOWNAME-only] [verbose-url=[url]] [slow]

Note: Eagle will use data.json from its root, WORKFLOWNAME values (login, main, create-group, create-mutamer)

Verbose mode

node . verbose

Enable extraction of DOM elements every few seconds to a log file as they appear

node . verbose-url="https://www.etawaf.com/tawaf43/index.html?locale=en"

Extract DOM elements for one page only and only one time no intervals

Puppeteer

Use node and puppeteer to automate passenger data exchange with third party sites like

  • Way to Umrah
  • Bab Al Umrah
  • Gabul Ya Hajj
  • Tawaf
  • Ehaj
  • Visit Saudi
  • other local visa systems

Puppeteer should easily be installed using npm i puppeteer check package.json for the version we use. If it is 5.5.0 then this uses chromium version 818858 (go using 997535). If 14.0.0no then r991974

Some machines refuse to install puppeteer and chromium and one way of overcoming this install error is by installing manually from here.

For example on M1 machine you can download here directly (it's an Intel build, but runs fine via Rosetta 2 on M1 – get chrome-mac.zip). Also notice the revision for chromium in the url. Read this article for more info.

Open a rosetta terminal => This is just a regular terminal (with use rosetta checked in settings)
brew install chromium
go to Applications, try to open chromium, if you get warning, try to right click open
which chromium
  `will print the path. Mine is /opt/homebrew/bin/chromium`
open your shell config mine is => ~/.zshrc
export PUPPETEER_SKIP_CHROMIUM_DOWNLOAD=true
export PUPPETEER_EXECUTABLE_PATH=`which chromium`

Make sure which chromium points to the correct path and that you can open it free of warnings, try right click open if you get warnings.

To start a recorder (not helpful)

npx @puppeteer/recorder [url]

npx @puppeteer/recorder https://www.waytoumrah.com/prj_umrah/eng/eng_frmlogin.aspx
npx @puppeteer/recorder https://eumra.com/
npx @puppeteer/recorder https://www.etawaf.com/tawaf43/index.html?locale=en

To send a photo

I used this site for testing https://anonfiles.com/

a better approach to uploading file is https://www.codegrepper.com/code-examples/javascript/upload+file+from+local+puppeteer

Basically await input.uploadFile(${pathFile}/travis_1.png) instead of fileChooser below

      // 1. Create pointer for fileChooser
      let futureFileChooser = page.waitForFileChooser();

      // 2. Browse to select image
        await page.evaluate(() =>
        document
          .querySelector("#ctl00_ContentHolder_ImageUploaderControl")
          .click()
      );
      // 3. Wait for the file chooser
      let fileChooser = await futureFileChooser;

      // 4. Perform anything while file chooser is opened
      const resizedPhotoPath = path.join(
        util.photosFolder,
        `${data.travellers[counter].passportNumber}_200x200.jpg`
      );
      await sharp(photoPath, {
              fit: sharp.fit.inside,
              withoutEnlargement: true,
            }).resize(200, 200).toFile(resizedPhotoPath);

      // 5. Accept the image into the file chooser
      await fileChooser.accept([resizedPhotoPath]);

user message

Since we communicate with advanced eagle users in these messages, we color console.log messages

console.log('\x1b[7m', "message","\x1b[0m");

If you use ansi color your must reset using "\x1b[0m" Here is the reference for ansi colors

Budgie

node . budgie List all budgie entries

node . budgie key:value node . budgie PlaceOfResidence:"New place of birth" Set PlaceOfResidence to new value

SMS

We use third party provider for SMS, you must have an api_key to purchase sms tokens. HAJonSoft gladly shares api_key, but feel free to override with your own api_key with, contact us for details. https://sms-activate.org/en/getNumber

alialiayman@gmail.com/ Paris until 4

https://www.receivesms.co/ https://receive-smss.com/ https://smsreceivefree.com/

Vision Api

To use vision api, enable billing in console.googlcloud.com, search for Vision api, enable it, create service account in credentials, then download a json in to ./scan/auth/key.json and you are good to image to text with google latest ML

Benefits of Eagle

1- Quick atomic send (no looking for photos, vaccine file or residence permit) 2- Resubmit in one click with eagle vs all clicks without 3- Reuse the same data to print artifacts 4- capture important data as they appear on screen like mofa number 5- Platform for support. We can't support outside HAJonSoft. We can send thousands of passports quickly. 6- Reduce risk of Ehaj timeout 7- With google vision, You don't need expensive 3M scanner. We read issue date too. 8- Early validation/alert about expired passports or duplicate 9- MRZ Manipulation to fix Ehaj limitations ex. German passport 10- Photo capture and resize is actually a challenging time consuming task. 11- Import mofa number, automate hajj smart form 12- Can fix issuing authority mistake on passports issued with wrong MRZ or unrecognized nationality ex. Zimbabway or cambodian messed up MRZ. even solve Ehaj parsing issues too 13- passwordless login with two factor authentication 14- Captcha elimination

References

css escape characters. Sometimes an external visa system uses special character in the selector like . or : (\3A)

CSS represents escaped characters in a different way. Escapes start with a backslash followed by the hexadecimal number that represents the character's hexadecimal Unicode code point value.

https://www.w3.org/International/questions/qa-escapes#:~:text=CSS%20represents%20escaped%20characters%20in,that%20is%20all%20you%20need.

Gmail https://developers.google.com/gmail/api/quickstart/nodejs

Captcha https://2captcha.com/enterpage

Release process https://youtu.be/IdHik3GxV0Q

2.6.40

2 months ago

2.6.39

5 months ago

2.6.38

7 months ago

2.6.37

7 months ago

2.6.36

7 months ago

2.6.35

7 months ago

2.6.34

8 months ago

2.6.27

8 months ago

2.6.29

8 months ago

2.6.33

8 months ago

2.6.31

8 months ago

2.6.25

9 months ago

2.6.23

9 months ago

2.6.22

9 months ago

2.6.21

9 months ago

2.6.20

9 months ago

2.6.19

9 months ago

2.6.15

9 months ago

2.6.16

9 months ago

2.6.17

9 months ago

2.6.18

9 months ago

2.6.11

9 months ago

2.6.14

9 months ago

2.6.3

9 months ago

2.6.2

9 months ago

2.6.5

9 months ago

2.6.4

9 months ago

2.6.6

9 months ago

2.6.9

9 months ago

2.6.8

9 months ago

2.5.84

9 months ago

2.5.82

9 months ago

2.5.77

9 months ago

2.5.78

9 months ago

2.5.79

9 months ago

2.5.80

9 months ago

2.5.75

9 months ago

2.5.71

10 months ago

2.5.72

10 months ago

2.5.74

10 months ago

2.5.70

10 months ago

2.5.69

10 months ago

2.5.66

10 months ago

2.5.68

10 months ago

2.5.64

10 months ago

2.5.63

10 months ago

2.5.61

10 months ago

2.5.60

10 months ago

2.5.59

10 months ago

2.5.58

10 months ago

2.5.54

10 months ago

2.5.56

10 months ago

2.5.57

10 months ago

2.5.52

10 months ago

2.5.48

11 months ago

2.5.49

11 months ago

2.5.51

11 months ago

2.5.47

11 months ago

2.5.46

11 months ago

2.5.44

1 year ago

2.5.45

12 months ago

2.5.40

1 year ago

2.5.38

1 year ago

2.5.39

1 year ago

2.5.36

1 year ago

2.5.33

1 year ago

2.5.34

1 year ago

2.5.35

1 year ago

2.5.18

2 years ago

2.5.19

2 years ago

2.5.29

1 year ago

2.5.25

2 years ago

2.5.26

1 year ago

2.5.27

1 year ago

2.5.28

1 year ago

2.5.22

2 years ago

2.5.23

2 years ago

2.5.24

2 years ago

2.5.20

2 years ago

2.5.32

1 year ago

2.5.30

1 year ago

2.5.31

1 year ago

2.4.70

2 years ago

2.5.6

2 years ago

2.5.8

2 years ago

2.5.7

2 years ago

2.5.14

2 years ago

2.5.15

2 years ago

2.5.17

2 years ago

2.5.11

2 years ago

2.5.12

2 years ago

2.5.2

2 years ago

2.4.58

2 years ago

2.5.1

2 years ago

2.4.57

2 years ago

2.5.4

2 years ago

2.5.3

2 years ago

2.4.59

2 years ago

2.4.54

2 years ago

2.4.53

2 years ago

2.4.56

2 years ago

2.4.55

2 years ago

2.4.69

2 years ago

2.4.65

2 years ago

2.4.64

2 years ago

2.4.67

2 years ago

2.4.66

2 years ago

2.4.61

2 years ago

2.4.60

2 years ago

2.4.63

2 years ago

2.4.62

2 years ago

2.4.28

2 years ago

2.4.39

2 years ago

2.4.36

2 years ago

2.4.35

2 years ago

2.4.38

2 years ago

2.4.32

2 years ago

2.4.34

2 years ago

2.4.33

2 years ago

2.4.47

2 years ago

2.4.46

2 years ago

2.4.49

2 years ago

2.4.48

2 years ago

2.4.42

2 years ago

2.4.41

2 years ago

2.4.40

2 years ago

2.4.50

2 years ago

2.4.52

2 years ago

2.4.51

2 years ago

2.4.27

2 years ago

2.4.26

2 years ago

2.4.23

2 years ago

2.4.1

2 years ago

2.4.0

2 years ago

2.4.3

2 years ago

2.4.2

2 years ago

2.4.5

2 years ago

2.4.4

2 years ago

2.4.18

2 years ago

2.4.17

2 years ago

2.4.19

2 years ago

2.4.14

2 years ago

2.4.13

2 years ago

2.4.16

2 years ago

2.4.15

2 years ago

2.4.12

2 years ago

2.4.11

2 years ago

2.4.7

2 years ago

2.4.6

2 years ago

2.4.9

2 years ago

2.4.8

2 years ago

2.4.22

2 years ago

2.3.9

2 years ago

2.3.13

2 years ago

2.3.12

2 years ago

2.3.14

2 years ago

2.3.6

2 years ago

2.3.5

2 years ago

2.3.4

2 years ago

2.3.3

2 years ago

2.3.2

2 years ago

2.3.1

2 years ago

2.2.33

2 years ago

2.2.32

2 years ago

2.2.30

2 years ago

2.2.28

2 years ago

2.2.27

2 years ago

2.2.25

2 years ago

2.2.24

2 years ago

2.2.23

2 years ago

2.2.22

2 years ago

2.2.21

2 years ago

2.2.20

2 years ago

2.2.19

2 years ago

2.2.18

2 years ago

2.2.17

2 years ago

2.2.16

2 years ago

2.2.15

2 years ago

2.2.14

2 years ago

2.2.13

2 years ago

2.2.12

2 years ago

2.2.11

2 years ago

2.2.10

2 years ago

2.2.9

2 years ago

2.2.8

2 years ago

2.2.7

2 years ago

2.2.6

2 years ago

2.2.5

2 years ago

2.2.2

2 years ago

2.2.1

2 years ago

2.2.0

2 years ago

2.1.13

2 years ago

2.1.12

2 years ago

2.1.11

2 years ago

2.1.10

2 years ago

2.1.9

2 years ago

2.1.8

2 years ago

2.1.7

2 years ago

2.1.6

2 years ago

2.1.5

2 years ago

2.1.4

2 years ago

2.1.3

2 years ago

2.1.2

2 years ago

2.1.1

2 years ago

2.1.0

2 years ago

2.0.6

2 years ago

2.0.5

2 years ago

2.0.4

2 years ago

2.0.3

2 years ago

2.0.2

2 years ago

2.0.1

2 years ago

2.0.0

2 years ago

1.2.6

2 years ago

1.2.5

2 years ago

1.2.4

2 years ago

1.2.3

2 years ago

1.2.2

2 years ago

1.2.1

2 years ago

1.1.15

2 years ago

1.1.14

2 years ago

1.1.13

2 years ago

1.1.12

2 years ago

1.1.11

2 years ago

1.1.10

2 years ago

1.1.9

2 years ago

1.1.8

2 years ago

1.1.7

2 years ago

1.1.6

2 years ago

1.1.5

2 years ago

1.1.4

2 years ago

1.1.3

2 years ago

1.1.2

2 years ago

1.1.1

2 years ago

1.1.0

2 years ago