500.001.1001Daraja API errorM-Pesa error 500.001.1001: Server error — merchant does not exist or insufficient funds
This is a Daraja API error — Safaricom rejects the request itself, before any customer prompt, usually over authentication or payload validation.
What causes it
A server-side error (HTTP 500), commonly a nonexistent merchant/shortcode or, for B2C, insufficient funds in the business account.
How to fix it
Verify the shortcode/merchant configuration and business account balance, then retry or contact Safaricom support.
How paylod handles this
paylod manages Daraja OAuth tokens, request signing, and payload formatting for you — the whole class of authentication and malformed-request errors is handled by the wrapper, so you send one clean REST call and get a typed response.
See the paylod M-Pesa API