IBV Scorecard API

Dearzy Model v4.1

REST API for automated bank statement scoring. Submit a JSON bank statement file and receive a full credit decision with MPCR, LDCR, ADCR metrics.

Endpoints

GET /health
Health check — returns server status and version.
GET /api/config
View active scoring configuration (read-only).
POST /api/score
Score a bank JSON statement. Returns decision, score, MPCR, LDCR, ADCR and full breakdown.

Request — multipart/form-data

FieldTypeDescription
json_fileFileBank statement JSON (.json) — required
loan_amountnumberRequested loan amount (default: 300)
customer_idstringCustomer identifier (metadata only)
abastringABA / routing number for account verification
accountstringAccount number for verification

Request — application/json

FieldDescription
jsonRaw JSON string or parsed object of bank statement
loan_amount, customer_id, aba, accountSame as above

Query Parameters

ParamValuesDescription
formatjson | html | bothResponse format. Default: json

Example — cURL (JSON response)

curl -X POST http://YOUR_SERVER:3000/api/score \
  -F "[email protected]" \
  -F "loan_amount=300" \
  -F "customer_id=CUST001" \
  -F "aba=021000021" \
  -F "account=123456789"

Example — cURL (HTML scorecard)

curl -X POST "http://YOUR_SERVER:3000/api/score?format=html" \
  -F "[email protected]" \
  -F "loan_amount=300" \
  -o scorecard.html

Example — JSON body

curl -X POST http://YOUR_SERVER:3000/api/score \
  -H "Content-Type: application/json" \
  -d '{
    "json": { "TransactionSummaries": [...], "Accounts": [...] },
    "loan_amount": 300,
    "customer_id": "CUST001"
  }'

Response fields (format=json)

FieldDescription
decisionAPPROVE / MANUAL REVIEW / DECLINE
repayment_probability0–100 probability score
score_pointsRaw score points
mpcrMonthly Payroll Coverage Ratio (monthly avg ÷ loan)
ldcrLargest Deposit Coverage Ratio
adcrAverage Deposit Coverage Ratio (new in v4.1)
avg_verified_depositAverage single verified deposit amount
decline_triggersArray of hard-decline reasons if any
manual_flagsArray of warning flags
strengthsArray of positive signals
score_rowsFull point-by-point breakdown array
aba_match / account_matchFULL_MATCH / PARTIAL_MATCH / NO_MATCH (when provided)

Authentication

If server.apiKeys is set in config.json, include the key in requests:

curl -H "X-Api-Key: your-key-here" -X POST http://YOUR_SERVER:3000/api/score ...

When no keys are configured, the API is open.

Server Configuration

Edit config.json on the server and send SIGHUP to reload without restart:

kill -HUP $(pgrep -f "node server.js")

Try it

Result