Purchases logs from a category, deducts wallet balance, and returns the purchased details.
Use a unique idempotency_key for every checkout attempt. Reusing the same key with the same payload returns the original response; reusing it with different data is rejected.
BodyTypeDescription
category_idintegerRequired. Existing active log category ID.
quantityintegerRequired. Minimum 1, maximum 100.
idempotency_keystringRequired. Unique key for this checkout attempt.
cURL
curl -X POST "https://www.expresslogs.org/api/v1/logs/orders" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{
"category_id": 12,
"quantity": 2,
"idempotency_key": "website-order-20260507-0001"
}'
201 Response
{
"success": true,
"data": {
"order_id": "logs-api-ABC1234567-1778112000",
"status": "completed",
"product_id": 12,
"product_name": "Facebook Logs",
"quantity": 2,
"unit_price": "2500.00",
"total": "5000.00",
"currency": "NGN",
"balance_after": "10000.00",
"items": [
{
"serial": 1,
"details": "purchased log details",
"video": null
}
]
}
}