PUT
Update a service
Scope:
sales:services.writehttps://api.holded.com/api/v2/services/{serviceId}Updates an existing service. Only the fields included in the request body will be modified — omitted fields will keep their current value.
Parameters
Path parameters
serviceId
stringrequiredService ID (24-char hex ObjectId)
Request body
object
namestring
descriptionstring | null
pricenumber
costnumber | null
taxnumber | null
taxes[]string[] | null
Array of tax keys to apply. Retrieve valid keys from GET /api/v2/taxes before setting this field.
tags[]string[] | null
sales_channel_idstring | null
codestring | null
colorstring | null
durationnumber | null
Request
python
import requests
url = "https://api.holded.com/api/v2/services/{serviceId}"
headers = {
"Authorization": "Bearer YOUR_API_KEY",
"Accept": "application/json",
}
payload = {
"name": "Consulting",
"description": "Consulting service",
"price": 100,
"cost": 50,
"tax": 21,
"taxes": [
"string"
],
"tags": [
"string"
],
"sales_channel_id": "string",
"code": "string",
"color": "string",
"duration": 0
}
response = requests.put(url, headers=headers, json=payload)
print(response.json())Responses
Response
json
{
"id": "string"
}Success responses
200Service updatedapplication/jsonobject
idstring
Error responses
400Bad requestapplication/json401Invalid or missing API keyapplication/json403Insufficient permissionsapplication/json404Service not foundapplication/json429Rate limit exceededapplication/json