> ## Documentation Index
> Fetch the complete documentation index at: https://docs.usedora.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Rider Delivery History

### 📝 Summary

This endpoint retrieves the delivery history of a specific rider, including details about the deliveries they have completed, their status, and relevant timestamps. The history can be filtered by date, status, and other optional parameters.

***

### Requests

##### Example

<Expandable>
  ```json theme={null}
  {
    "paginate": "1",
    "per_page": "10",
    "filter": "all",
    "start_date": "",
    "end_date": ""
  }
  ```
</Expandable>

##### Params

<Expandable>
  **Description:**

  | Name         | Location | Type   | Required | Description |       |           |
  | ------------ | -------- | ------ | -------- | ----------- | ----- | --------- |
  | `paginate`   | query    | string | yes      | none        |       |           |
  | `per_page`   | query    | string | yes      | none        |       |           |
  | `filter`     | query    | string | yes      | all         | today | yesterday |
  | `start_date` | query    | string | yes      | optional    |       |           |
  | `end_date`   | query    | string | yes      | optional    |       |           |
</Expandable>

### Responses

| HTTP Status Code                 | Meaning                                                          | Description | Data schema |
| -------------------------------- | ---------------------------------------------------------------- | ----------- | ----------- |
| <Badge color="green">200</Badge> | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1)          | none        | Inline      |
| <Badge color="red">422</Badge>   | [Bad Request](https://tools.ietf.org/html/rfc7231#section-6.3.1) | none        | Inline      |

<ResponseExample>
  ```json sample response theme={null}
  {
  "status": "success",
  "data": {
  "current_page": 1,
  "data": [
    {
      "uuid": "4560f59a-d071-4854-a098-2978ba373004",
      "order_number": "14192541",
      "fleet_identity_number": "68316349",
      "status": "Awaiting-Pickup",
      "delivery_type": "intra_state",
      "sender_longitude": null,
      "sender_latitude": null,
      "customer_longitude": null,
      "customer_latitude": null,
      "delivery_fee": "3000",
      "currency": "NGN",
      "note": null,
      "creation_mode": "Manual",
      "created_at": "2024-01-06T17:02:09.000000Z",
      "customer_detail": {
        "uuid": "21803e28-08b7-4b23-b3f6-49161f8a6a4c",
        "customer_name": "TundeNasri",
        "customer_email": "sinoma@gmail.com",
        "customer_phone_number": "08065302534",
        "customer_phone_code": "234",
        "customer_address": "12 Ahmadu Bello way, Central Business District, Abuja",
        "created_at": "2024-01-06T07:28:13.000000Z"
      },
      "sender_detail": {
        "uuid": "62c70575-366c-44c3-893e-504abce1f667",
        "sender_name": "Nuel Geek",
        "sender_phone": "08087168391",
        "sender_email": "sender@example.com",
        "sender_phonecode": "234",
        "sender_address": "2 Umuleri street, Lagos",
        "created_at": "2024-01-06T17:02:09.000000Z",
        "updated_at": "2024-01-06T17:03:26.000000Z"
      },
      "items": [
        {
          "uuid": "99594223-8c39-49be-aefb-a1704e2e2650",
          "item_description": "Packaged makeup for mama emma's birthday celebration",
          "item_quantity": 2,
          "item_value": "43500.00",
          "currency": "NGN",
          "created_at": "2024-01-06T17:02:09.000000Z"
        },
        {
          "uuid": "801f2638-4a26-444d-9409-c5f54667e449",
          "item_description": "Eva soap pack",
          "item_quantity": 1,
          "item_value": "4000.00",
          "currency": "NGN",
          "created_at": "2024-01-06T17:03:26.000000Z"
        },
        {
          "uuid": "68751dcf-4440-4b51-9dbc-9e161b21ce2b",
          "item_description": "Cannon Camera",
          "item_quantity": 1,
          "item_value": "30000.00",
          "currency": "NGN",
          "created_at": "2024-01-06T17:03:26.000000Z"
        }
      ],
      "rider_info": {
        "uuid": "69234d24-61c1-4d68-a232-7a04d71f2b0e",
        "riderid": "71762164",
        "name": "Kelly Chimaobi",
        "address": "Aso housing estate, lugbe",
        "phone_number": "07081131771",
        "phone_code": "234",
        "email": "kyl@gmail.com",
        "vehicle_plate_number": "Ae93480G",
        "photo": "https://usedora-bucket-dev.s3.amazonaws.com/photos/S97Eie0RU6bdafmq5OjV9HeZkuCYdL0UNaT4SP52.jpg",
        "total_completed_delivery": 0,
        "active": false,
        "number_of_ongoing_deliveries": 0,
        "total_revenue_by_rider": "0",
        "rider_ongoing_deliveries": null,
        "created_at": "2024-01-06T08:02:20.000000Z"
      }
    }
  ],
  "first_page_url": "http://127.0.0.1:8000/api/riders/delivery_history/69234d24-61c1-4d68-a232-7a04d71f2b0e?page=1",
  "from": 1,
  "last_page": 1,
  "last_page_url": "http://127.0.0.1:8000/api/riders/delivery_history/69234d24-61c1-4d68-a232-7a04d71f2b0e?page=1",
  "links": [
    {
      "url": null,
      "label": "&laquo; Previous",
      "active": false
    },
    {
      "url": "http://127.0.0.1:8000/api/riders/delivery_history/69234d24-61c1-4d68-a232-7a04d71f2b0e?page=1",
      "label": "1",
      "active": true
    },
    {
      "url": null,
      "label": "Next &raquo;",
      "active": false
    }
  ],
  "next_page_url": null,
  "path": "http://127.0.0.1:8000/api/riders/delivery_history/69234d24-61c1-4d68-a232-7a04d71f2b0e",
  "per_page": 5,
  "prev_page_url": null,
  "to": 1,
  "total": 1
  }
  }
  ```
</ResponseExample>
