Skip to content

Overview

  • Version: 2.0
  • Servers: https://api.xsolla.com/merchant/v2/

This API reference describes endpoints for managing subscriptions, coupons, and promotions. To get more information about Subscriptions, see the product guide and the glossary.

Download OpenAPI description
Languages
Servers
Mock server
https://xsolla.redocly.app/_mock/api/subscriptions/
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations

Request

Security
projectUserJwtAuth
Path
project_idinteger\d+required
Bodyapplication/jsonrequired

Redeem a coupon by its code

codestring

Coupon code

Default null
Example: "abcde"
curl -i -X POST \
  'https://xsolla.redocly.app/_mock/api/subscriptions/api/user/v1/projects/{project_id}/redeem_coupon' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "code": "abcde"
  }'

Responses

The coupon has been successfully redeemed

Bodyapplication/json
Response
application/json
{ "status": "successful" }
Operations
Operations