Timestamp
Generate and validate secure UNIX timestamps for every KwikPaisa API request to ensure request authenticity, improve transaction security, and protect APIs against replay attacks, unauthorized request
KwikPaisa APIs require a valid UNIX timestamp in every API request to ensure secure communication and protect APIs against replay attacks and unauthorized request reuse.
The timestamp must be sent in the X-TIMESTAMP header for every authenticated API request.
What is X-TIMESTAMP?
X-TIMESTAMP represents the current UNIX timestamp in seconds.
KwikPaisa uses this timestamp to:
Validate request freshness
Prevent replay attacks
Verify request authenticity
Improve API security
Example Header
X-TIMESTAMP: 1778659835Generate Timestamp
The timestamp should always be generated dynamically before sending an API request.
Important Notes
Timestamp must always be generated in UNIX seconds format
Generate a fresh timestamp for every API request
Expired timestamps may be rejected
Server and client system time should remain synchronized
Reusing old timestamps may invalidate requests
Replay Attack Protection
KwikPaisa validates timestamps to protect APIs against replay attacks.
Replay attacks occur when previously valid API requests are reused maliciously.
Using dynamic timestamps helps:
Prevent duplicate request execution
Improve request security
Validate request freshness
Example API Request
Common Errors
401 Unauthorized
Possible reasons:
Expired timestamp
Invalid timestamp format
Timestamp mismatch
Missing
X-TIMESTAMPheader
Best Practices
Always generate timestamps server-side
Synchronize server time using NTP
Never hardcode timestamps
Generate timestamps immediately before requests
Validate timestamps while processing webhooks
Last updated
