Financial Core
PROVIDER: SAFARICOM DARAJA
Shortcode Configuration
The system binds to a `payoutTill` or Paybill number. You must configure fees separately for Collection (Input) and Payout (Output).
Collection (C2B / STK)
Customer pays Business.
Input: collectionFee
{ percent: 0.0, fixed: 0.0 }
{ percent: 0.0, fixed: 0.0 }
Fee applied on top of the requested amount.
Payout (B2C)
Business pays Customer/Staff.
Input: payoutFee
{ percent: 0.0, fixed: 0.0 }
{ percent: 0.0, fixed: 0.0 }
Fee deducted from the transferred amount.
Transaction Lifecycle
T+0s
PENDINGRecord created in local DB. No API call yet.
T+1s
REQUESTEDSTK Push triggered via Daraja. `MerchantRequestID` received.
T+15s
PAIDCallback received. PIN validated. Funds in Till.
Error
FAILEDUser cancelled, wrong PIN, or timeout (60s).
Sensitive Data
Credential Storage
Consumer Key and Secret are encrypted at rest. However, `PassKey` is used to sign requests.
NEVER commit production credentials to git. Use the configured Environment Variables or the secure Dashboard Settings UI.