# impassai

> passport ocr

Latest version **1.0.1** (published 2018-08-29) · ISC license · 0 weekly downloads

## Install

```sh
npm install impassai
pnpm add impassai
yarn add impassai
bun add impassai
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.1 |
| Published | 2018-08-29 |
| First published | 2018-08-29 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 254 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | tomas gao |
| Maintainers | dingning239 |
| Keywords | passport, ocr, image, china |

## Links

- npm: https://www.npmjs.com/package/impassai
- npm.io page: https://npm.io/package/impassai

## Alternatives

- [exif-parser](https://npm.io/package/exif-parser.md) — 3.8M weekly downloads
- [vite-plugin-compression](https://npm.io/package/vite-plugin-compression.md) — 569.5K weekly downloads
- [pica](https://npm.io/package/pica.md) — 442.4K weekly downloads
- [@reportportal/client-javascript](https://npm.io/package/@reportportal/client-javascript.md) — 408.8K weekly downloads
- [@tldraw/state](https://npm.io/package/@tldraw/state.md) — 316.0K weekly downloads

## Recent versions

- 1.0.1 (latest) — 2018-08-29
- 1.0.0 — 2018-08-29

## README

Entry passport identification API description
Interface Overview
Service Introduction
Passport recognition, according to the passport image uploaded by the user, returns the completed two-dimensional code of China entry card.
Explain
Impassai is stored as an nodejs package on official website http://registry.npmjs.org.
The third party users can install the impassai module through the NPM command. The installation commands are as follows
$PROJECT indicates the user's directory of projects.
#cd $PROJECT
#npm install impassai
If the following prompt appears, it means the installation is successful.
+ ipassai@1.0.0
Added 1 package in 1.569s
Interface method
Var imgocr=require ("imgocr")
Imgocr. portocr ('your appid','your appkey','your secretkey','Passport filename','base 64 image')
Imgocr.ipassreg ("your fullname", "your email")
Sample:
Var imgocr=require ('./imgocr.js')
Imgocr.portocr ('1534992612943',
'JXd8iKS4EjToMEHCkLfHlDOL',
'hAfwC8MGaXqPSH8lprQWaTo1VGBgzOvL',
'111.png',
'/9j/4AAQSkZJRgABAQAASABIAAD/4QBYRXhpZgAAT')
This method generates a two-dimensional code image called "result. png" in the current project directory, which can be used directly by users.
Imgocr.ipassreg ('fullname','email.com')
This method will register an access user in ipassai cloud and assign appid, appkey, secretkey.
Interface method imgocr.portocr parameter specification
Parameter name required type specification
Appid is the only identifier for a string access project, and the accessor needs to register by calling the interface function ipassreg
Appkey is the AK in the JSON returned by the string registered user interface.
Secretkey is the SK in the JSON returned by the string registered user interface.
Filename is the filename of the passport that the string user prepares to upload (it is recommended to call uniquevalue in share.js to generate a 32-bit random code)
Filebuffer is the base64 encoding string for string users to upload their passport pictures.
Interface method imgocr.ipassreg parameter specification
Parameter name required type specification
Fullname is the name of the registered user of string.
Email is the e-mail address of string registered users.

---
_Source: https://npm.io/package/impassai · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
