# List Reward Redemptions — Bonusly

> Return paginated reward redemption records for the caller's company, with optional filtering by user email, date range, and fulfillment status. This is a company-wide admin report, not just the caller's own redemptions. See the…

- Key: `bonusly-list-reward-redemptions`
- Type: Action (Read-only)
- Version: 0.0.2
- App: Bonusly (`bonusly`) — https://pipedream.com/apps/bonusly.md
- This page (HTML): https://pipedream.com/apps/bonusly/actions/list-reward-redemptions
- Hints: read-only · open-world
- Source: https://github.com/PipedreamHQ/pipedream/blob/master/components/bonusly/actions/list-reward-redemptions/list-reward-redemptions.mjs

## Description

Return paginated reward redemption records for the caller's company, with optional filtering by user email, date range, and fulfillment status. This is a company-wide admin report, not just the caller's own redemptions. [See the documentation](https://docs.bonus.ly/reference/adminrewardsredemptionsreport-1)

## Props

| Prop | Type | Required | Description |
|---|---|---|---|
| `userEmail` | `string` | No | Filter to redemptions made by this user's email address, e.g. john.smith@company.com. |
| `startDate` | `string` | No | Only include redemptions on or after this date, e.g. 2026-01-01. |
| `endDate` | `string` | No | Only include redemptions on or before this date, e.g. 2026-06-30. |
| `unfulfilled` | `boolean` | No | Set to true to return only redemptions that haven't been fulfilled yet. |
| `aasmState` | `string` | No | Filter by the redemption's internal state (e.g. approved, pending, declined). Bonusly's docs don't publish the full list of accepted values, so confirm against a real redemption's aasm_state field if this filter returns no results. Leave blank to include redemptions in any state. |
| `range` | `string` | No | A predefined date range shortcut, if supported by your Bonusly plan (e.g. this_month). Start Date/End Date take precedence when both are set. |
| `page` | `integer` | No | Page number to fetch, starting at 1. |
| `perPage` | `integer` | No | Number of redemptions to return per page. |
| `sort` | `string` | No | Field to sort results by, e.g. created_at. |
| `direction` | `string` | No | Sort direction for the Sort Field, e.g. asc or desc. |

## Run it

**MCP**

```ts
import { Client } from "@modelcontextprotocol/sdk/client/index.js"
import { StreamableHTTPClientTransport } from "@modelcontextprotocol/sdk/client/streamableHttp.js"
import { PipedreamClient } from "@pipedream/sdk"

const pd = new PipedreamClient({
  projectId: process.env.PIPEDREAM_PROJECT_ID!,
  clientId: process.env.PIPEDREAM_CLIENT_ID!,
  clientSecret: process.env.PIPEDREAM_CLIENT_SECRET!,
  projectEnvironment: "production",
})

const accessToken = await pd.rawAccessToken

const transport = new StreamableHTTPClientTransport(
  new URL("https://remote.mcp.pipedream.net/v3"),
  {
    requestInit: {
      headers: {
        Authorization: `Bearer ${accessToken}`,
        "x-pd-project-id": process.env.PIPEDREAM_PROJECT_ID!,
        "x-pd-environment": "production",
        "x-pd-external-user-id": "{external_user_id}", // any stable ID for this user in your system
        "x-pd-app-slug": "bonusly",
      },
    },
  },
)

const mcp = new Client({ name: "my-agent", version: "1.0.0" })
await mcp.connect(transport)

const { tools } = await mcp.listTools()

// listTools() hands your model this tool's input schema, so it can
// fill the arguments itself:
const result = await mcp.callTool({
  name: "bonusly-list-reward-redemptions",
  arguments: {
    userEmail: "User Email",
    startDate: "Start Date",
  },
})
```

**TypeScript**

```ts
import { PipedreamClient } from "@pipedream/sdk"

const pd = new PipedreamClient({
  projectId: process.env.PIPEDREAM_PROJECT_ID!,
  clientId: process.env.PIPEDREAM_CLIENT_ID!,
  clientSecret: process.env.PIPEDREAM_CLIENT_SECRET!,
  projectEnvironment: "production",
})

const result = await pd.actions.run({
  id: "bonusly-list-reward-redemptions",
  externalUserId: "{external_user_id}", // any stable ID for this user in your system
  configuredProps: {
    bonusly: { authProvisionId: "apn_xxxxxxx" },
    userEmail: "User Email",
    startDate: "Start Date",
  },
})

console.log(result)
```

**cURL**

```bash
curl -X POST https://api.pipedream.com/v1/connect/{project_id}/actions/run \
  -H "Content-Type: application/json" \
  -H "X-PD-Environment: production" \
  -H "Authorization: Bearer {access_token}" \
  -d '{
    "external_user_id": "{external_user_id}",
    "id": "bonusly-list-reward-redemptions",
    "configured_props": {
      "bonusly": { "authProvisionId": "apn_xxxxxxx" },
      "userEmail": "User Email",
      "startDate": "Start Date"
    }
  }'
```

---

- App: https://pipedream.com/apps/bonusly.md · All apps: https://pipedream.com/apps
