Emzagar / Hovita
Gateway, inbound auth, callback, mock sign
Vendor: Hovita — API host branded Emzagar.
Outbound (createEmzagarClient)
POST /auth/get/tokenPOST /get/pay/infoPOST /gateway/link/getPOST /sign/get/status
Sandbox: https://apisandbox.emzagar.com
Production: https://api.emzagar.com
Inbound (Emzagar → your app)
| Endpoint | Purpose |
|---|---|
POST /api/emzagar/auth/token | Issue HMAC bearer for Emzagar |
GET|POST /api/emzagar/document | Return base64 PDF for trackId (built on the fly from contentHtml; not read from an unsigned/ folder) |
POST /api/emzagar/callback | Receive signed PDF → complete session + QR |
Register these URLs in the Emzagar acquirer panel. EMZAGAR_PUBLIC_BASE_URL must be HTTPS reachable from Emzagar (tunnel in local dev).
Mock mode
EMZAGAR_MOCK=true skips the real gateway and opens /contract/sign/mock, which calls /api/contract/sign/mock-complete and runs the same completeContractSignSession path (signed file + QR stamp).
Sign roles
contractor | ceo — CEO credentials from EmzagarSettings singleton (id=global).
Critical product rule
Next Hovita round always uses the canonical signed/ PDF — never the QR-stamped file.