Required headers
Her istek üç zorunlu başlık içermelidir:
X-Timestamp | Saniye cinsinden Unix timestamp |
X-Signature | Hex formatında HMAC-SHA256 istek imzası |
X-Client-Id | Satıcı ID'niz |
Signature generation
İmza timestamp ve istek gövdesi temel alınarak oluşturulur.
Format:
{timestamp}.{canonicalBody}
Format description
timestamp | Saniye cinsinden geçerli Unix zamanı |
canonicalBody | Canonical formata dönüştürülmüş JSON istek gövdesi |
İmza algoritması:
Önemli gereksinimler:
Örnekler:
Authorization errors
401 Invalid X-Timestamp
{
"status": 401,
"message": "Invalid X-Timestamp"
}401 Expired X-Timestamp
{
"status": 401,
"message": "Expired X-Timestamp"
}401 Invalid X-Signature
{
"status": 401,
"message": "Invalid X-Signature"
}401 Invalid token
{
"status": 401,
"message": "Invalid token"
}401 Merchant secret not configured
{
"status": 401,
"message": "Merchant secret not configured"
}500 Internal Server Error
{
"status": 500,
"message": "Internal Server Error"
}