# hibye-patient

> Eiada Patient App === This lib is a dependency for Eiada Doctor app to be able to share and reuse services like payment service

Latest version **1.5.0** (published 2021-08-12) · ISC license · 0 weekly downloads

## Install

```sh
npm install hibye-patient
pnpm add hibye-patient
yarn add hibye-patient
bun add hibye-patient
```

## Health

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

Positive: has types; no vulnerabilities; high quality score.

Warnings: low downloads; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.5.0 |
| Published | 2021-08-12 |
| First published | 2021-08-12 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | bundled |
| Module format | CommonJS |
| Node | 8.11.3 |
| Dependencies | 52 |
| Unpacked size | 517.1 KB |
| Known vulnerabilities | 0 (+65 in 12 direct dependencies) |
| Install scripts | yes |
| Maintainers | fadymagdy |

## Links

- npm: https://www.npmjs.com/package/hibye-patient
- Repository: https://github.com/fadysalib147/Patient-App
- Homepage: https://github.com/fadysalib147/Patient-App#readme
- Issues: https://github.com/fadysalib147/Patient-App/issues
- npm.io page: https://npm.io/package/hibye-patient

## Dependencies (52)

- [ejs](https://npm.io/package/ejs.md) ^3.0.1
- [i18n](https://npm.io/package/i18n.md) ^0.8.5
- [uuid](https://npm.io/package/uuid.md) ^3.1.0
- [axios](https://npm.io/package/axios.md) ^0.19.2
- [redis](https://npm.io/package/redis.md) ^2.8.0
- [config](https://npm.io/package/config.md) ^1.30.0
- [lodash](https://npm.io/package/lodash.md) ^4.17.15
- [moment](https://npm.io/package/moment.md) ^2.24.0
- [aws-sdk](https://npm.io/package/aws-sdk.md) ^2.580.0
- [express](https://npm.io/package/express.md) ^4.16.2
- [tedious](https://npm.io/package/tedious.md) ^2.3.1
- [@tsed/di](https://npm.io/package/@tsed/di.md) 5.31.2
- [bcryptjs](https://npm.io/package/bcryptjs.md) ^2.4.3
- [exitzero](https://npm.io/package/exitzero.md) ^1.0.1
- [mongoose](https://npm.io/package/mongoose.md) ^5.7.1
- [passport](https://npm.io/package/passport.md) ^0.4.0
- [cash-true](https://npm.io/package/cash-true.md) 0.0.2
- [crypto-js](https://npm.io/package/crypto-js.md) ^4.0.0
- [@tsed/core](https://npm.io/package/@tsed/core.md) 5.31.2
- [aws-lambda](https://npm.io/package/aws-lambda.md) ^0.1.2
- [nodemailer](https://npm.io/package/nodemailer.md) ^6.3.1
- [typescript](https://npm.io/package/typescript.md) ^3.6.3
- [@types/i18n](https://npm.io/package/@types/i18n.md) ^0.8.6
- [body-parser](https://npm.io/package/body-parser.md) ^1.18.2
- [compression](https://npm.io/package/compression.md) ^1.7.4
- [@tsed/common](https://npm.io/package/@tsed/common.md) 5.31.2
- [@types/redis](https://npm.io/package/@types/redis.md) ^2.8.14
- [jsonwebtoken](https://npm.io/package/jsonwebtoken.md) ^8.3.0
- [moment-range](https://npm.io/package/moment-range.md) ^4.0.2
- [randomstring](https://npm.io/package/randomstring.md) ^1.1.5
- [ts-log-debug](https://npm.io/package/ts-log-debug.md) 5.1.0
- [@tsed/swagger](https://npm.io/package/@tsed/swagger.md) 5.31.2
- [lambda-warmer](https://npm.io/package/lambda-warmer.md) ^1.2.1
- [patch-package](https://npm.io/package/patch-package.md) ^6.2.0
- [response-time](https://npm.io/package/response-time.md) ^2.3.2
- [passport-local](https://npm.io/package/passport-local.md) ^1.0.0
- [class-validator](https://npm.io/package/class-validator.md) ^0.11.0
- [email-validator](https://npm.io/package/email-validator.md) ^2.0.4
- [express-session](https://npm.io/package/express-session.md) ^1.15.6
- [moment-timezone](https://npm.io/package/moment-timezone.md) ^0.5.31
- [@types/crypto-js](https://npm.io/package/@types/crypto-js.md) ^3.1.47
- [class-transformer](https://npm.io/package/class-transformer.md) ^0.2.3
- [@types/response-time](https://npm.io/package/@types/response-time.md) ^2.3.4
- [express-bearer-token](https://npm.io/package/express-bearer-token.md) ^2.1.1
- [passport-google-token](https://npm.io/package/passport-google-token.md) ^0.1.2
- [aws-serverless-express](https://npm.io/package/aws-serverless-express.md) ^3.3.6
- [request-promise-native](https://npm.io/package/request-promise-native.md) ^1.0.8
- [voucher-code-generator](https://npm.io/package/voucher-code-generator.md) ^1.1.1
- [passport-facebook-token](https://npm.io/package/passport-facebook-token.md) ^3.3.0
- [class-transformer-validator](https://npm.io/package/class-transformer-validator.md) ^0.7.1
- [goodeggs-mongoose-timestamps](https://npm.io/package/goodeggs-mongoose-timestamps.md) ^1.0.0
- [@types/swagger-schema-official](https://npm.io/package/@types/swagger-schema-official.md) ^2.0.20

## Recent versions

- 1.5.0 (latest) — 2021-08-12
- 1.4.0 — 2021-08-12
- 1.3.0 — 2021-08-12

## README

Eiada Patient App
===
This lib is a dependency for Eiada Doctor app to be able to share and reuse services like payment service

## Notes about dates and timezone
- All dates are saved UTC to the db regardless of the machine/process timezone
- No need to convert dates generated by the code as it will be UTC by default when saving
- We must convert all dates come from user requests. Use `DateTzService.getDate()`
- For any date comparison, make sure that we compare a date/moment object as it has the tz stored inside it
  and will cast the dates to timestamp during comparisons
- Timestamp are always UTC regardless of the timezone of the machine/process
- Format all response dates to user timezone. Use `DateTzService.getFormattedDate()` 

## Testing payment Webhooks
Create a tunnel using this command `$ ssh -R 443:localhost:7000 ssh.localhost.run`  and use `https://GENERATED_URL`

## Test Accept Account for HiBye
- username: mouneer
- Password: P@ssw0rd

## Test Accept Account for a Doctor
- username: TestDoctor
- Password: P@ssw0rd

## Dev
- `$ ACCEPT_PAYMENTS_MODE=test;TZ=UTC npm run inspect`

## Prod
- Pushing to the master branch deploys to AWS Lambda

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