paddle_list_discounts | R Documentation |
Fetches a paginated list of discounts from the Paddle API. By default, only active discounts are returned.
paddle_list_discounts(
id = NULL,
code = NULL,
status = NULL,
mode = NULL,
after = NULL,
order_by = NULL,
per_page = NULL
)
id |
Character vector of discount IDs (e.g., '"dsc_xxx"'). Optional. |
code |
Character vector of discount codes. Optional. |
status |
Character vector of discount statuses (one of '"active"', '"archived"'). Optional. |
mode |
Character. Filter discounts by mode (one of '"standard"', '"custom"'). Optional. |
after |
Character. Return entities after the specified Paddle ID (used for pagination). Optional. |
order_by |
Character. Ordering string (e.g., '"id[ASC]"' or '"created_at[DESC]"'). Optional. |
per_page |
Integer. Number of results per page (max 200). Optional, defaults to 50. |
A list containing discount data and pagination metadata.
set_paddle_mode("sandbox")
result <- paddle_list_discounts()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.