Download OpenAPI specification:Download
Part of the REST API v2 Reference.
Operations about RevenueCat Billing discounts.
GET /projects/{project_id}/discountsPOST /projects/{project_id}/discountsGET /projects/{project_id}/discounts/{discount_id}DELETE /projects/{project_id}/discounts/{discount_id}PATCH /projects/{project_id}/discounts/{discount_id}POST /projects/{project_id}/discounts/{discount_id}/actions/enablePOST /projects/{project_id}/discounts/{discount_id}/actions/disableGET /projects/{project_id}/discounts/{discount_id}/discount_codesPOST /projects/{project_id}/discounts/{discount_id}/discount_codesDELETE /projects/{project_id}/discounts/{discount_id}/discount_codes/{discount_code}Lists RevenueCat Billing discounts for the project. This endpoint requires the following permission(s): project_configuration:discounts:read. This endpoint belongs to the Project Configuration domain, which has a default rate limit of 60 requests per minute.
| project_id required | string <= 255 characters Example: proj1ab2c3d4 ID of the project |
| starting_after | string Example: starting_after=ent12354 Pagination cursor. Pass the id of the last item from the previous page to fetch the next page; omit for the first page. |
| limit | integer Default: 20 Example: limit=10 Maximum number of items to return per page. Values below 1 or above 100 are clamped to that range rather than rejected. |
{- "object": "list",
- "items": [
- {
- "object": "discount",
- "id": "discnt1a2b3c4d5e",
- "identifier": "spring_2026",
- "customer_facing_name": "Spring sale",
- "type": "percentage",
- "duration_mode": "one_time",
- "eligibility": "everyone",
- "time_window": "P1M",
- "disabled_at": 1762273200000,
- "percentage": 20,
- "created_at": 1762270200000,
- "updated_at": 1762270200000
}
], - "next_page": "/v2/projects/proj1ab2c3d4/discounts?starting_after=discntab21dac",
- "url": "/v2/projects/proj1ab2c3d4/discounts"
}Creates a RevenueCat Billing discount. This endpoint requires the following permission(s): project_configuration:discounts:read_write. This endpoint belongs to the Project Configuration domain, which has a default rate limit of 60 requests per minute.
| project_id required | string <= 255 characters Example: proj1ab2c3d4 ID of the project |
| identifier required | string [ 1 .. 100 ] characters The customizable discount identifier (developer-defined). | ||||||||
| customer_facing_name required | string [ 3 .. 1024 ] characters Name displayed to customers for this discount. | ||||||||
| type required | string Enum: "percentage" "fixed_amount" The type of discount to apply. | ||||||||
| percentage | integer [ 1 .. 100 ] Percentage value for percentage discounts. | ||||||||
object Fixed amount values by currency for fixed amount discounts. | |||||||||
| |||||||||
| duration_mode required | string Enum: "one_time" "time_window" "forever" The discount duration mode. | ||||||||
| eligibility required | string Enum: "everyone" "never_purchased" "never_subscribed" "never_subscribed_to_the_same_product" Eligibility criteria for this discount. | ||||||||
| time_window | string^(-?)P(?=\d|T\d)(?:(\d+)Y)?(?:(\d+)M)?(?:(\d+... ISO-8601 duration when using time window duration mode. | ||||||||
| product_identifiers | Array of strings Product identifiers that this discount applies to. | ||||||||
{- "identifier": "spring_2026",
- "customer_facing_name": "Spring sale",
- "type": "percentage",
- "percentage": 20,
- "fixed_amounts": {
- "property1": {
- "currency": "USD",
- "amount": 4.99
}, - "property2": {
- "currency": "USD",
- "amount": 4.99
}
}, - "duration_mode": "one_time",
- "eligibility": "everyone",
- "time_window": "P1M",
- "product_identifiers": [
- "com.acme.product1",
- "com.acme.product2"
]
}{- "object": "discount",
- "id": "discnt1a2b3c4d5e",
- "identifier": "spring_2026",
- "customer_facing_name": "Spring sale",
- "type": "percentage",
- "duration_mode": "one_time",
- "eligibility": "everyone",
- "time_window": "P1M",
- "disabled_at": 1762273200000,
- "percentage": 20,
- "created_at": 1762270200000,
- "updated_at": 1762270200000
}Returns a RevenueCat Billing discount. This endpoint requires the following permission(s): project_configuration:discounts:read. This endpoint belongs to the Project Configuration domain, which has a default rate limit of 60 requests per minute.
| project_id required | string <= 255 characters Example: proj1ab2c3d4 ID of the project |
| discount_id required | string [ 1 .. 255 ] characters Example: discnt1a2b3c4d5e The id of the RevenueCat Billing discount. |
{- "object": "discount",
- "id": "discnt1a2b3c4d5e",
- "identifier": "spring_2026",
- "customer_facing_name": "Spring sale",
- "type": "percentage",
- "duration_mode": "one_time",
- "eligibility": "everyone",
- "time_window": "P1M",
- "disabled_at": 1762273200000,
- "percentage": 20,
- "created_at": 1762270200000,
- "updated_at": 1762270200000
}Deletes a RevenueCat Billing discount. This endpoint requires the following permission(s): project_configuration:discounts:read_write. This endpoint belongs to the Project Configuration domain, which has a default rate limit of 60 requests per minute.
| project_id required | string <= 255 characters Example: proj1ab2c3d4 ID of the project |
| discount_id required | string [ 1 .. 255 ] characters Example: discnt1a2b3c4d5e The id of the RevenueCat Billing discount. |
{- "object": "app",
- "id": "string",
- "deleted_at": 1658399423658
}Updates a RevenueCat Billing discount offer. This endpoint requires the following permission(s): project_configuration:discounts:read_write. This endpoint belongs to the Project Configuration domain, which has a default rate limit of 60 requests per minute.
| project_id required | string <= 255 characters Example: proj1ab2c3d4 ID of the project |
| discount_id required | string [ 1 .. 255 ] characters Example: discnt1a2b3c4d5e The id of the RevenueCat Billing discount. |
| customer_facing_name | string [ 3 .. 1024 ] characters Name displayed to customers for this discount. | ||||||||
| type | string Enum: "percentage" "fixed_amount" The type of discount to apply. | ||||||||
| percentage | integer [ 1 .. 100 ] Percentage value for percentage discounts. | ||||||||
object Fixed amount values by currency for fixed amount discounts. | |||||||||
| |||||||||
| duration_mode | string Enum: "one_time" "time_window" "forever" The discount duration mode. | ||||||||
| eligibility | string Enum: "everyone" "never_purchased" "never_subscribed" "never_subscribed_to_the_same_product" Eligibility criteria for this discount. | ||||||||
| time_window | string^(-?)P(?=\d|T\d)(?:(\d+)Y)?(?:(\d+)M)?(?:(\d+... ISO-8601 duration when using time window duration mode. | ||||||||
| product_identifiers | Array of strings Product identifiers that this discount applies to. | ||||||||
{- "customer_facing_name": "Spring sale 2026",
- "type": "percentage",
- "percentage": 25,
- "fixed_amounts": {
- "property1": {
- "currency": "USD",
- "amount": 4.99
}, - "property2": {
- "currency": "USD",
- "amount": 4.99
}
}, - "duration_mode": "one_time",
- "eligibility": "everyone",
- "time_window": "P1M",
- "product_identifiers": [
- "com.acme.product1",
- "com.acme.product2"
]
}{- "object": "discount",
- "id": "discnt1a2b3c4d5e",
- "identifier": "spring_2026",
- "customer_facing_name": "Spring sale",
- "type": "percentage",
- "duration_mode": "one_time",
- "eligibility": "everyone",
- "time_window": "P1M",
- "disabled_at": 1762273200000,
- "percentage": 20,
- "created_at": 1762270200000,
- "updated_at": 1762270200000
}Enables a RevenueCat Billing discount. This endpoint requires the following permission(s): project_configuration:discounts:read_write. This endpoint belongs to the Project Configuration domain, which has a default rate limit of 60 requests per minute.
| project_id required | string <= 255 characters Example: proj1ab2c3d4 ID of the project |
| discount_id required | string [ 1 .. 255 ] characters Example: discnt1a2b3c4d5e The id of the RevenueCat Billing discount. |
{- "object": "discount",
- "id": "discnt1a2b3c4d5e",
- "identifier": "spring_2026",
- "customer_facing_name": "Spring sale",
- "type": "percentage",
- "duration_mode": "one_time",
- "eligibility": "everyone",
- "time_window": "P1M",
- "disabled_at": 1762273200000,
- "percentage": 20,
- "created_at": 1762270200000,
- "updated_at": 1762270200000
}Disables a RevenueCat Billing discount. This endpoint requires the following permission(s): project_configuration:discounts:read_write. This endpoint belongs to the Project Configuration domain, which has a default rate limit of 60 requests per minute.
| project_id required | string <= 255 characters Example: proj1ab2c3d4 ID of the project |
| discount_id required | string [ 1 .. 255 ] characters Example: discnt1a2b3c4d5e The id of the RevenueCat Billing discount. |
{- "object": "discount",
- "id": "discnt1a2b3c4d5e",
- "identifier": "spring_2026",
- "customer_facing_name": "Spring sale",
- "type": "percentage",
- "duration_mode": "one_time",
- "eligibility": "everyone",
- "time_window": "P1M",
- "disabled_at": 1762273200000,
- "percentage": 20,
- "created_at": 1762270200000,
- "updated_at": 1762270200000
}Lists redemption codes for a RevenueCat Billing discount. This endpoint requires the following permission(s): project_configuration:discounts:read. This endpoint belongs to the Project Configuration domain, which has a default rate limit of 60 requests per minute.
| project_id required | string <= 255 characters Example: proj1ab2c3d4 ID of the project |
| discount_id required | string [ 1 .. 255 ] characters Example: discnt1a2b3c4d5e The id of the RevenueCat Billing discount. |
| starting_after | string Example: starting_after=ent12354 Pagination cursor. Pass the id of the last item from the previous page to fetch the next page; omit for the first page. |
| limit | integer Default: 20 Example: limit=10 Maximum number of items to return per page. Values below 1 or above 100 are clamped to that range rather than rejected. |
{- "object": "list",
- "items": [
- {
- "object": "discount_code",
- "code": "SPRING_2026",
- "created_at": 1712145600000
}
], - "next_page": "/v2/projects/proj1ab2c3d4/discounts/discnt1a2b3c4d5e/discount_codes?starting_after=SPRING_2026",
- "url": "/v2/projects/proj1ab2c3d4/discounts/discnt1a2b3c4d5e/discount_codes"
}Creates redemption codes for a RevenueCat Billing discount. This endpoint requires the following permission(s): project_configuration:discounts:read_write. This endpoint belongs to the Project Configuration domain, which has a default rate limit of 60 requests per minute.
| project_id required | string <= 255 characters Example: proj1ab2c3d4 ID of the project |
| discount_id required | string [ 1 .. 255 ] characters Example: discnt1a2b3c4d5e The id of the RevenueCat Billing discount. |
| codes required | Array of strings [ 1 .. 10000 ] items [ items [ 1 .. 255 ] characters ^[A-Za-z0-9_]+$ ] List of discount codes to create and attach to the discount. |
{- "codes": [
- "SPRING_2026"
]
}[- {
- "object": "discount_code",
- "code": "SPRING_2026",
- "created_at": 1712145600000
}
]Deletes a redemption code from a RevenueCat Billing discount. This endpoint requires the following permission(s): project_configuration:discounts:read_write. This endpoint belongs to the Project Configuration domain, which has a default rate limit of 60 requests per minute.
| project_id required | string <= 255 characters Example: proj1ab2c3d4 ID of the project |
| discount_id required | string [ 1 .. 255 ] characters Example: discnt1a2b3c4d5e The id of the RevenueCat Billing discount. |
| discount_code required | string [ 1 .. 255 ] characters ^[A-Za-z0-9_]+$ Example: SPRING_2026 The discount code to remove from the RevenueCat Billing discount. |
{- "object": "app",
- "id": "string",
- "deleted_at": 1658399423658
}All API v2 resources, one page each. General concepts (authentication, pagination, rate limits, error handling) live on the API v2 overview.