Update Web Client Settings
Updates the web client settings of the platform.
HTTP Request
PATCH/api/settings/web_client
Authorization
Authorization
- Required: Yes
- Permission: Staff or Admin
- Authentication: Token authentication
Request Body
| Field | Type | Required | Description |
|---|---|---|---|
| web_client_failed_payment_url | URL | No | URL for failed payment redirects (default: "http://localhost:8000/failed_payment") |
| web_client_successful_payment_url | URL | No | URL for successful payment redirects (default: "http://localhost:8000/successful_payment") |
Example Requests
- 🐍 Python
- 🌐 Curl
1import requests
2
3# Update web client settings
4response = requests.patch('http://www.example.com/api/settings/web_client',
5 headers={'Authorization': 'Token <your_api_key>'},
6 json={
7 "web_client_failed_payment_url": "http://www.example.com/failed_payment",
8 "web_client_successful_payment_url": "http://www.example.com/successful_payment"
9 }
10)
11print(response.json())1# Update web client settings
2curl -X PATCH "http://www.example.com/api/settings/web_client" -H "Authorization: Token <your_api_key>" -d '{
3 "web_client_failed_payment_url": "http://www.example.com/failed_payment",
4 "web_client_successful_payment_url": "http://www.example.com/successful_payment"
5}'Status Codes
| Code | Description |
|---|---|
| 200 | Request logs retrieved successfully |
| 400 | Bad request — invalid query parameters |
| 401 | Unauthorized — authentication required |
| 403 | Forbidden — insufficient permissions |
| 500 | Internal server error |
Response Fields
| Field | Type | Description |
|---|---|---|
| web_client_failed_payment_url | URL | URL for failed payment redirects (default: "http://localhost:8000/failed_payment") |
| web_client_successful_payment_url | URL | URL for successful payment redirects (default: "http://localhost:8000/successful_payment") |