AVAILABLE WITH BUSINESS SUBSCRIPTION
Request: POST /gamification/points/withdraw
Permissions to Run the Request
Account Owner, Account Administrators, Department Administrators, Publishers, or custom roles.
Department Administrators, and users with a custom role can deduct points only from users belonging to departments they manage and their sub-departments.
Header | Description |
---|
Authorization (required) | Access token. You can obtain a token by making a request.
|
Parameter | Description |
---|
userId (required) | The ID of the user whose points you want to deduct. |
amount (required) | The amount of points to be deducted. |
reason (required) | The reason for deducting the points. |
Response Codes
Code | Text | Description |
---|
200 | OK | The points are successfully deducted. |
400 | Bad Request | A request error. |
401 | Unauthorized | An authorization error. |
403 | Permission denied | The user doesn't have enough permissions to fulfill the request. |
Sample Request
POST /gamification/points/withdraw https/1.1
Host: api-learn.ispringlearn.com
Authorization: p-1sJDjmULL5DdpXPJTcbm4jVIaWVHvNmrjAxATRbNE
Content-Type: application/xml
Accept: application/xml
<?xml version="1.0" encoding="UTF-8"?>
<withdrawGamificationPoints>
<userId>2c180ffc-8841-11e9-b68a-0242c0a85016</userId>
<amount>10</amount>
<reason>string</reason>
</withdrawGamificationPoints>
XML
Sample Response