# Order Delivered

This endpoint allows merchants to notify the Keeta platform that an order has been successfully delivered to the customer for merchant self-delivery orders.
**Notes:**
1. This API is exclusively for **merchant self-delivery orders** where the merchant manages their own delivery service.
2. Calling this endpoint marks the order as completed.
3. Courier information can be updated if needed.
4. This API does not support duplicate calls for the same order.

Endpoint: POST /order/delivered
Version: v.1.0.0

## Request fields (application/json):

  - `orderViewId` (integer, required)
    Unique identifier for orders on Keeta platform
    Example: 123456789

  - `shopId` (integer, required)
    Unique identifier of the Keeta store
    Example: 987654321

  - `courierInfo` (object)
    Comprehensive courier information for self-delivery orders, including personal details, contact information, and vehicle specifications.

  - `courierInfo.courierId` (integer)
    Unique identifier for the courier, generated by the vendor system
    Example: 123456

  - `courierInfo.courierName` (string)
    Full name of the courier responsible for delivery
    Example: أحمد محمد

  - `courierInfo.courierPhone` (string)
    Primary contact phone number of the courier
    Example: 501234567

  - `courierInfo.courierVehicle` (integer)
    Type of vehicle used by the courier for delivery:
    Enum: "1", "2", "3", "4"

  - `courierInfo.courierPhoneInterCode` (string)
    International dialing code for the courier phone number (e.g., "966" for Saudi Arabia)
    Example: 966

  - `courierInfo.vehiclePlateNumber` (string)
    License plate number of the delivery vehicle
    Example: DXB-A-12345

  - `courierInfo.courierLastName` (string)
    Last name (family name) of the courier
    Example: محمد

  - `courierInfo.courierFirstName` (string)
    First name (given name) of the courier
    Example: أحمد

## Response 200:

  - `200` (unknown)
    Order delivery confirmation successful

## Response 200 fields (application/json):

  - `code` (integer, required)
    **Response Codes for Order Delivered:**
- **0**: Success - Order delivery delivered successful
- **109000000**: Request parameter error (specific details in message field)
  - "orderViewId is null"
  - "shopId is null"
- **209000101**: Order does not exist
- **2090006003**: This order is not a merchant self-delivery order
- **309000000**: System error
    Example: 0

  - `message` (string, required)
    Text description corresponding to the status code, explaining the operation result or error cause to users.
    Example: Success

