Repository navigation
v1.5.0: SDKs 1.5.0
Install: npm install cheki-verify@1.5.0 · pip install cheki==1.5.0 · composer require cheki/cheki:^1.5 · dart pub add cheki:^1.5.0 · go get github.com/1RB/cheki/sdks/go@v1.5.0
The first registry release of the SDK rework: npm, PyPI and Packagist 1.4.1 were built from June 2026 code, so everything listed under 1.4.1 below reaches those registries now.
Safer retries (all SDKs, one shared rule). At most one retry, and only where it is safe:
GET(banks, health): a network error or a 5xx.POST /api/verify: a network error, or a 429/503 with aRetry-Afterof at most 60 s.POST /api/verify/batch: only a 429/503 with a shortRetry-After. A batch is never replayed after a 5xx (a 504 means it ran out of server time) or a network error, because the replay hit every bank again and charged every receipt against the rate limit.- Never: timeouts, other 4xx, a geo-blocked bank (502 with
fallbackUrl, which used to cost an extra ~9 s for the same answer), or an error markedretryable: false. A 429 withoutRetry-Afteris no longer retried. sdks/fixtures/api-contract.jsongainedretryCases, which every SDK's tests run.
Fixes
- Dart: responses are decoded as UTF-8 from the bytes, and
httpmust be 1.4.0+ (olderhttpdecodedapplication/jsonwithout a charset as latin1, garbling Amharic names and messages). The Dart SDK constraint is now>=3.4.0, ashttp1.4.0 requires. - Python: direct mode no longer turns off TLS verification for Awash (Awash serves a complete, publicly trusted chain), so nobody on the network path can forge an Awash receipt.
- Python: a
requests.Sessionyou pass in is no longer modified. TheUser-Agentand API key go on each request, so the key never leaks to other hosts the session calls, andclose()leaves your session open. - Python: batch
indexis the position in the response even if a malformed item is skipped, and an item withoutbankraisesValueError(it raisedKeyError). - PHP: cURL is limited to HTTP(S);
curl_close()calls removed (deprecated in PHP 8.5).
Added
betaon banks in Python, Go, PHP and Dart (TypeScript always sets it now): true for M-Pesa and ZamZam.orderId/order_id/OrderIDon results (CBE Birr receipts).- Batch error items keep
fallbackUrlwhen the server sends one. getReceiptUrlrejects a ZamZam receipt id that is not digits only, as the server does.RECOMMENDED_BATCH_CHUNK(15) in every SDK; the docs explain chunking long lists.
Packaging
- Python: the API client depends on
requests>=2.33.0andurllib3>=2.8.0only.beautifulsoup4andpdfplumbermoved to thecheki[direct]extra for the deprecated direct mode (pdfplumber>=0.11.9,pdfminer.six>=20251230); without it direct mode raisesDirectModeUnavailableError. The wheel shipsLICENSE(SPDXlicense = "MIT"). Python 3.14 is tested. - PHP: requires PHP 8.1+; CI tests 8.1, 8.3 and 8.4. The Packagist package contains only the SDK (
.gitattributesexport-ignore), and the rootcomposer.jsonmatchessdks/php/composer.json. - TypeScript:
engines.nodeis>=20. - Go: CI tests the
go 1.21floor and the current release. - Dart: pubspec description within pub.dev's 60 to 180 characters.
Release pipeline
scripts/bump-version.sh --files-only X.Y.Z(release PR) and--tag-only X.Y.Z(tag the merged main); it also updates the Go install pin and checks this changelog.publish.ymlfails when a registry already has the version (except on a re-run), checks the wheel and the Packagist dist, and ends with a job that polls every registry until it serves the release from the tagged commit (scripts/check-registries.mjs).
Full PR: #50 · Changelog: https://github.com/1RB/cheki/blob/v1.5.0/CHANGELOG.md