---
title: "Search discounts"
method: GET
path: "/v1/discounts/search"
tags: ["Discounts"]
---

# Search discounts

`GET /v1/discounts/search`

Search and list discount codes for a store with filters and pagination.

## Query parameters

- `page_number` number
- `page_size` number
- `product_id` string
- `status` 'active' | 'deleted'
- `type` 'percentage' | 'fixed'
- `created_after` string
- `created_before` string

## Response `200`

Successfully retrieved the list of discounts

- DiscountListEntity
  - `items` DiscountEntity[], required — List of discount items
    - `id` string, required — Unique identifier for the object.
    - `mode` 'test' | 'prod' | 'sandbox', required — String representing the environment.
    - `object` string, required — A string representing the object’s type. Objects of the same type share the same value.
    - `status` 'deleted' | 'active' | 'draft' | 'expired' | 'scheduled', required — The status of the discount (e.g., active, inactive).
    - `name` string, required — The name of the discount.
    - `code` string, required — The discount code. A unique identifier for the discount.
    - `type` 'percentage' | 'fixed', required — The type of the discount, either "percentage" or "fixed".
    - `amount` number — The amount of the discount. Can be a percentage or a fixed amount.
    - `currency` string — The currency of the discount. Only required if type is "fixed".
    - `percentage` number — The percentage of the discount. Only applicable if type is "percentage".
    - `expiry_date` string, date-time — The expiry date of the discount.
    - `max_redemptions` number — The maximum number of redemptions allowed for the discount.
    - `duration` 'forever' | 'once' | 'repeating' — The duration type for the discount.
    - `duration_in_months` number — The number of months the discount is valid for. Only applicable if the duration is "repeating" and the product is a subscription.
    - `applies_to_products` string[] — The list of product IDs to which this discount applies.
    - `redeem_count` number — The number of times this discount has been redeemed.
  - `pagination` PaginationEntity, required
    - `total_records` number, required — Total number of records in the list
    - `total_pages` number, required — Total number of pages available
    - `current_page` number, required — The current page number
    - `next_page` number, nullable, required — The next page number, or null if there is no next page
    - `prev_page` number, nullable, required — The previous page number, or null if there is no previous page

## Other responses

- `400` — Bad Request - Invalid input parameters
- `401` — Unauthorized - Invalid or missing API key
- `404` — Not Found - Resource does not exist

---

[API](https://skmtc.net/creem/apis/creem-api.md) · [All operations](https://skmtc.net/creem/apis/creem-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/creem/creem-api/revisions/aa593160d96c/schema)
