Skip to main content
Code: auth.unauthorized
HTTP: 401 Unauthorized

What happened

The API rejected the request during authentication before your route handler ran.

Safe message

We could not verify this request. Please try again later.
Use err.safeMessage or err.displayMessage in customer UI, not err.message.

Why this happened

The request did not include valid signed API credentials (Morapay-Key, Morapay-Timestamp, Morapay-Signature).

How to fix it

Initialize Morapay with your pk_* and sk_* pair on the server. Never expose sk_* in browser code.

UI hint

Programmatic handling