/api/v1/training/services/{training-service-id}Update a training service.
| Permission | Description |
|---|---|
training_services.update | Update your own training services |
training_services.update_any | Update training services for any user |
| Name | Type | Required | Description |
|---|---|---|---|
title | string | No | Title of the training service (max 255) |
description | string | No | Description (max 2000, optional) |
price | int | No | Price of the training service |
discount | float | No | Discount percentage (nullable, default 0) |
category | string | No | Category of training service: diet_plan, workout_plan, other |
major_ids | array | No | Array of major IDs that this training service covers |
All parameters are optional. If omitted, they will not be updated. You can set them to null if desired.
<training service resource>
| Status | Error Type | Reference |
|---|---|---|
| 422 | Validation Error | Validation error |
| 401 | Unauthorized | Authentication error |
| 403 | Forbidden | Permission error |