Orders
Get Order
Get details of a specific order
GET
Get Order
Retrieves detailed information about a specific order. Users can only access their own orders.
Authentication
This endpoint requires authentication. Include a valid JWT token in the Authorization header.Path Parameters
The unique identifier of the order to retrieve
Response
Unique identifier for the order
ID of the user who placed the order
Total amount for the order (decimal as string)
Current status of the orderPossible values:
pending- Order has been created but not yet processedshipped- Order has been shippeddelivered- Order has been deliveredcancelled- Order has been cancelled
ISO 8601 timestamp when the order was created
ISO 8601 timestamp when the order was last updated
Array of order items
Unique identifier for the order item
ID of the parent order
ID of the product
Quantity of the product ordered
Price of the product at the time of purchase (decimal as string)
Product details
Product ID
Product name
Product description
Current price of the product (decimal as string)
URL to the product image
Current stock level
ID of the product’s category
Error Responses
401 Unauthorized
Returned when the authentication token is missing or invalid.404 Not Found
Returned when:- The order does not exist
- The order belongs to a different user
Get Order