---
displayed_sidebar: homepage
---

import ParameterTypes from "@site/src/components/ParameterTypes"

# handler

 **handler**: (`req`: `Request`, `res`: `Response`) => Promise&#60;void&#62;

## Type declaration

### Parameters

<ParameterTypes parameters={[
  {
    "name": "req",
    "type": "`Request`",
    "description": "",
    "optional": false,
    "defaultValue": "",
    "expandable": false,
    "children": []
  },
  {
    "name": "res",
    "type": "`Response`",
    "description": "",
    "optional": false,
    "defaultValue": "",
    "expandable": false,
    "children": []
  }
]} expandUrl="https://docs.medusajs.com/development/entities/repositories#retrieving-a-list-of-records"/>

### Returns

<ParameterTypes parameters={[
  {
    "name": "Promise",
    "type": "Promise&#60;void&#62;",
    "optional": false,
    "defaultValue": "",
    "description": "",
    "expandable": false,
    "children": []
  }
]} />
