HW agent API 2.28.0

API section

Reconciliation

Daily reconciliation: every terminal payment and refund is matched with a receipt for the same amount, the terminal total with the receipt total; with an OFD export (CSV) — receipts missing in the OFD and OFD receipts not printed through the agent.

GET/api/v1/reconciliationDaily terminal and register reconciliation
POST/api/v1/reconciliationReconciliation with an OFD export
GET/api/v1/reconciliation/ledgerDaily reconciliation journal

Daily terminal and register reconciliation#

GET/api/v1/reconciliation

Every terminal payment and refund is matched with a receipt for the same card amount, the terminal total with the receipt total. Data — the agent reconciliation journal (receipts and card operations through the agent). date — the day, today by default

Parameters

NameInTypeDescription
datequerystring date

Response 200 application/json

Fields · Report
  • datestring date
  • okboolean
  • errorsinteger int32
  • warningsinteger int32
  • summarySummary
    13 fields · Summary
    • terminalPaymentsTotal
      2 fields · Total
      • countinteger int32
      • suminteger int64
    • terminalRefundsTotal
      2 fields · Total
      • countinteger int32
      • suminteger int64
    • terminalCancelsTotal
      2 fields · Total
      • countinteger int32
      • suminteger int64
    • terminalNetinteger int64
    • receiptsTotal
      2 fields · Total
      • countinteger int32
      • suminteger int64
    • returnsTotal
      2 fields · Total
      • countinteger int32
      • suminteger int64
    • correctionsTotal
      2 fields · Total
      • countinteger int32
      • suminteger int64
    • kktCashinteger int64
    • kktCardinteger int64
    • kktCardNetinteger int64
    • ofdRowsinteger int32
    • ofdSuminteger int64
    • ofdOtherFninteger int32
  • issuesarray of Issue
    8 fields · Issue
    • codestring
    • severitystring
      values: ERROR WARNING
    • atstring date-time
    • registerinteger int32
    • terminalinteger int32
    • fdinteger int64
    • amountinteger int64
    • messagestring

Errors — problem+json with a code field, see error codes.

Request example

curl
curl 'http://localhost:7790/api/v1/reconciliation'
curl
curl 'https://cloud.hw-connector.ru/agent/api/v1/reconciliation' \
  -H 'X-Api-Key: hwk_…' \
  -H 'X-Device-Id: 42'

Reconciliation with an OFD export#

POST/api/v1/reconciliation

The same plus a receipt export from the OFD account (CSV: document number, amount, fiscal drive and date if available): receipt in the journal but not in the OFD; in the OFD but not printed through the agent; amounts differ

Request body application/json required

Fields · OfdRequest
  • datestring daterequired
  • ofdCsvstringrequired
    from 0
    to 20000000
JSON
{
  "date": "2026-11-01",
  "ofdCsv": "string"
}

Response 200 application/json

Fields · Report
  • datestring date
  • okboolean
  • errorsinteger int32
  • warningsinteger int32
  • summarySummary
    13 fields · Summary
    • terminalPaymentsTotal
      2 fields · Total
      • countinteger int32
      • suminteger int64
    • terminalRefundsTotal
      2 fields · Total
      • countinteger int32
      • suminteger int64
    • terminalCancelsTotal
      2 fields · Total
      • countinteger int32
      • suminteger int64
    • terminalNetinteger int64
    • receiptsTotal
      2 fields · Total
      • countinteger int32
      • suminteger int64
    • returnsTotal
      2 fields · Total
      • countinteger int32
      • suminteger int64
    • correctionsTotal
      2 fields · Total
      • countinteger int32
      • suminteger int64
    • kktCashinteger int64
    • kktCardinteger int64
    • kktCardNetinteger int64
    • ofdRowsinteger int32
    • ofdSuminteger int64
    • ofdOtherFninteger int32
  • issuesarray of Issue
    8 fields · Issue
    • codestring
    • severitystring
      values: ERROR WARNING
    • atstring date-time
    • registerinteger int32
    • terminalinteger int32
    • fdinteger int64
    • amountinteger int64
    • messagestring

Errors — problem+json with a code field, see error codes.

Request example

curl
curl -X POST 'http://localhost:7790/api/v1/reconciliation' \
  -H 'Content-Type: application/json' \
  --data '{"date":"2026-11-01","ofdCsv":"string"}'
curl
curl -X POST 'https://cloud.hw-connector.ru/agent/api/v1/reconciliation' \
  -H 'X-Api-Key: hwk_…' \
  -H 'X-Device-Id: 42' \
  -H 'Content-Type: application/json' \
  --data '{"date":"2026-11-01","ofdCsv":"string"}'

Daily reconciliation journal#

GET/api/v1/reconciliation/ledger

Receipts and card operations through the agent: amounts by payment type, document number, RRN

Parameters

NameInTypeDescription
datequerystring date

Response 200 application/json

Array · Entry
  • kindstring
  • atstring date-time
  • registerinteger int32
  • terminalinteger int32
  • opstring
  • fdinteger int64
  • fnstring
  • shiftinteger int32
  • totalinteger int64
  • cashinteger int64
  • cardinteger int64
  • otherinteger int64
  • rrnstring
  • authCodestring
  • cardNumberstring

Errors — problem+json with a code field, see error codes.

Request example

curl
curl 'http://localhost:7790/api/v1/reconciliation/ledger'
curl
curl 'https://cloud.hw-connector.ru/agent/api/v1/reconciliation/ledger' \
  -H 'X-Api-Key: hwk_…' \
  -H 'X-Device-Id: 42'