Overview
The Coupon Management APIs provide comprehensive functionality for creating discount codes, managing promotional campaigns, tracking coupon usage, and analyzing campaign effectiveness across the TalentG platform.Base URL
Authentication
Coupon management requires admin-level authentication for creation and management operations.Coupon CRUD Operations
List Coupons
Create Coupon
Update Coupon
Delete Coupon
Coupon Validation & Application
Validate Coupon (Already documented in Payments API)
The coupon validation endpoint is documented in the Payments API section.Apply Coupon (Already documented in Payments API)
The coupon application endpoint is documented in the Payments API section.Coupon Usage Tracking
Get Coupon Usage Details
Bulk Operations
Bulk Create Coupons
Bulk Update Coupons
Coupon Types
Percentage Discount
Reduces the total amount by a percentage.Fixed Amount Discount
Reduces the total amount by a fixed amount in paise.Free Access
Provides 100% discount for complete free access.Applicable Services
Coupons can be restricted to specific services/features:| Service Key | Description |
|---|---|
strength_finder | Strength Finder Assessment |
premium_support | Premium Support Access |
advanced_analytics | Advanced Analytics Dashboard |
training_programs | Training Programs Access |
all | All services (wildcard) |
Error Handling
Common Error Codes
| Code | HTTP Status | Description |
|---|---|---|
UNAUTHORIZED | 401 | User not authenticated |
FORBIDDEN | 403 | Admin access required |
COUPON_EXISTS | 409 | Coupon code already exists |
INVALID_DISCOUNT | 400 | Invalid discount configuration |
USAGE_LIMIT_EXCEEDED | 400 | Coupon usage limit reached |
COUPON_EXPIRED | 400 | Coupon has expired |
Error Response Format
Rate Limiting
- Read operations: 1000 requests per hour per user
- Create/Update operations: 500 requests per hour per user
- Bulk operations: 50 requests per hour per user
- Validation operations: 2000 requests per hour per user
SDK Examples
Best Practices
Coupon Code Format
- Use uppercase letters and numbers only
- Keep codes between 6-12 characters
- Avoid special characters except underscores
- Make codes memorable and brandable
Usage Limits
- Set reasonable usage limits to prevent abuse
- Consider per-user limits for fairness
- Monitor usage patterns and adjust limits as needed
Expiration Management
- Set appropriate expiration dates based on campaign goals
- Consider timezone implications for global users
- Provide clear expiration notifications
Security Considerations
- Validate all coupon inputs server-side
- Implement rate limiting on validation endpoints
- Log all coupon usage for audit trails
- Use secure random generation for bulk codes
Coupon codes are case-sensitive and should be validated exactly as entered by users. Always implement server-side validation to prevent abuse.
Coupon analytics are automatically tracked and can be viewed through the Analytics API. Monitor campaign performance regularly to optimize promotional strategies.