Skip to content

Update a service

Request

Partially updates a service with a merge-patch body (RFC 7396); application/json is accepted with the same semantics. A missing field is left unchanged, so {} changes nothing. null clears online_booking_name (online booking shows name again), online_booking_description, and price_max_minor (a "from X" price); null on any other field fails with 422 field_not_nullable. Team Member links are written through updateTeamMemberServices; only a package change also relinks them (see Packages).

  • Prices. When price_min_minor comes without price_max_minor, a stored single price stays single (the maximum follows the new minimum), a stored range keeps its maximum (a new minimum above it fails with 422), and a stored "from X" price stays "from". The money rules of createService apply.
  • Packages. package is merged field by field (ServicePackageUpdate), and package.components replaces the whole list. After a change of package or of the package price, Altegio recalculates the duration, the status and, for sum or discount pricing, the price from the current components. It also links the package to every Team Member who provides at least one component, as on creation, and unlinks the other Team Members when the token subject may edit Team Member services and durations. The pricing rules of createService apply to the resulting package. duration_seconds of a package is computed from its components and fails with 422 field_immutable.
  • Online booking. Changing online_booking_enabled switches online booking for every Team Member link of the service. When the plan of the Location does not allow switching online booking of services, a change fails with 422 field_immutable; the stored value passes. An online_booking_name equal to name changes nothing while the service has no own online name: online booking keeps following name. When the service has an own online name, the sent value becomes the new own name even if it equals name; send null to make online booking follow name again.
  • Duration. A new duration_seconds also becomes the duration of the Team Member links of the service when they all had the same duration and the token subject may edit Team Member services and durations, as in Altegio.
  • Unlisted category. When the stored category is not listed in the Location (category_id reads null), a request without category_id keeps that category.
  • Field permissions. Changing a field the token subject may not change in Altegio fails with 403 permission_denied and an errors[] item per field: name and online_booking_name; category_id; price_min_minor, price_max_minor, package.pricing_type and package.price_discount_percent; online_booking_enabled.
  • Chain services. A service managed by its chain (chain_id set) fails with 422 field_immutable and an errors[] item per field on a change to name, online_booking_name, category_id, duration_seconds or package, to the prices when the chain manages the price, and to online_booking_description when the chain manages the description.
  • Type. type fails with 422 field_immutable unless it equals the current value.

Sending the stored value of a protected field passes. A service of another Location, a deleted service, a category, or a missing id fails with the same 404 resource_not_found. Another media type fails with 415 unsupported_media_type, broken JSON or a body that is not an object with 400 malformed_request.

Security
OAuth2(Required scopes: services:write) or ApiKey
Path
location_idintegerrequired

Identifier of the Location. Verified against the credential on every call — a Location the credential cannot access responds with 404.

service_idintegerrequired

Identifier of the service.

Bodyrequired
typestring

Immutable. The current value is accepted; another value fails with 422 field_immutable.

Enum:"simple""package"
namestring, [ 1 .. 16000 ] characters

Internal name shown to the business in Altegio. A link (a URL or any word.word without a space, such as Dr.Lash) fails with 422, as do a blank name, a name of 0 alone, and characters outside the Basic Multilingual Plane (emoji).

online_booking_namestring or null, [ 1 .. 16000 ] characters

Client-facing name for online booking; null removes it, and online booking shows name again. An empty or blank string and 0 alone fail with 422. A link (a URL or any word.word without a space, such as Dr.Lash) fails with 422. Characters outside the Basic Multilingual Plane (emoji) fail with 422.

online_booking_descriptionstring or null, <= 16000 characters

Description for clients in online booking. Plain text. A < must be followed by a space: Altegio treats any other < as the start of an HTML tag and drops everything up to the next >, or to the end of the text, so such a value fails with 422. null or an empty string removes the description. Characters outside the Basic Multilingual Plane (emoji) fail with 422.

category_idinteger

A category listed by listServiceCategories in this Location, other than a chain category. Any other id fails with 422 validation_failed at /category_id.

online_booking_enabledboolean

Whether clients can book the service online. A change also switches online booking for every Team Member link of the service.

duration_secondsinteger, multiple of 300, [ 0 .. 86400 ]

Default duration in seconds, from 0 to 86400 in 5-minute steps. Set on a simple service; a package computes it from the components, and sending it for a package fails with 422 field_immutable.

price_min_minorinteger, [ 0 .. 99999999999999 ]

Price, or the lower bound of a price range, in integer minor units of the Location currency. For a package, only when the resulting package.pricing_type is manual; sending the stored value passes.

price_max_minorinteger or null, [ 0 .. 99999999999999 ]

Upper bound of the price in integer minor units; null makes a "from X" price. A value below the resulting price_min_minor fails with 422. For a package, only when the resulting package.pricing_type is manual; sending the stored value passes.

packageobject(ServicePackageUpdate)

Merge-patch of the package settings, for package services only: a missing field is left unchanged, null fails with 422 field_not_nullable. The rules of ServicePackageCreate apply to the resulting package: price_discount_percent only with a resulting pricing_type of discount, the service prices only with manual; sending a stored value passes. Switching to manual without a price keeps the stored price. status and the component fields id and position are read-only and fail with 422 field_immutable; the order of a component is its place in components.

curl -i -X PATCH \
  'https://developer.alteg.io/_mock/en/b2b-v3/openapi/locations/{location_id}/services/{service_id}' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'Content-Type: application/merge-patch+json' \
  -d '{
    "price_min_minor": 280000
  }'

Responses

The updated service.

Headers
RateLimit-Remaininginteger, (int32), >= 0

Requests left in the most constrained policy window that applies to this request.

RateLimit-Resetinteger, (int32), >= 0

On 429, seconds until the most constrained policy frees up; it equals Retry-After there. On a successful response it reports the length of that policy's window rather than the time left in the current one, so treat it as the window size, not as a countdown — the counter to pace against is RateLimit-Remaining.

RateLimit-Policystring

Most constrained policy applied to the request, as <limit>;w=<window in seconds>.

Example:"10;w=60"
X-Request-Idstring

Request identifier for support and log correlation.

Bodyapplication/json
idintegerread-onlyrequired
objectstringread-onlyrequired
Value:"service"
typestringrequired

Service kind. Immutable after creation (422 field_immutable). A package service bundles several simple services of the same Location; it appears in the same list and is scheduled by the same service_id.

Default:"simple"
Enum:"simple""package"
namestringrequired

Internal name shown to the business in Altegio, as the business entered it; not translated.

online_booking_namestringrequired

Client-facing name shown in online booking, as the business entered it; equals name when no separate online booking name is set. Not translated.

online_booking_descriptionstring or nullrequired

Description of the service for clients in online booking, as the business entered it in Altegio; plain text. null when there is none.

category_idinteger or nullrequired

Service category (listServiceCategories); null when the category is not listed in this Location.

chain_idinteger or nullread-onlyrequired

Id of the chain that manages the service; null for a service of this Location alone. A chain service is edited in the chain: updateService fails with 422 field_immutable on the fields the chain manages, deleteService with 409 conflict.

duration_secondsintegerrequired

Default duration of the service in seconds (the Location-wide default, 3600 when none is set). For a package, Altegio computes it from the components.

weightintegerread-onlyrequired

Display order the business set in Altegio (higher first). Lists are ordered by id; sort by weight on the client. A service created through createService gets 0, like one created in Altegio.

price_min_minorintegerrequired

Base price of the service in this Location, integer minor units of the Location currency, as set by the business: a single price or the lower bound of a range; 0 for a free service and for an "up to Y" price. For a package, the package price stored in Altegio. Team Member prices by grade can differ.

price_max_minorinteger or nullrequired

Upper bound of the base price, integer minor units of the Location currency. Equals price_min_minor for a single price; greater for a range from price_min_minor to this value, or for an "up to Y" price when price_min_minor is 0; 0 for a free service (both bounds 0); null for a "from X" price without an upper bound (price_min_minor above 0).

currencystringread-onlyrequired

ISO 4217, server-controlled by the Location.

online_booking_enabledbooleanrequired

The business's online booking setting for this service in the Location. It does not mean that free time is available; free slots come from the availability operations.

team_member_idsArray of integersread-onlyrequired

Team Members providing this service. Read-only here; links are written through updateTeamMemberServices.

packageServicePackage (object) or nullrequired
One of:

Package settings and components of a service with type: package.

created_atstring or null, (date-time)read-onlyrequired

UTC; null when the creation date is not stored.

team_membersArray of objects(ServiceTeamMemberLink)read-only

Settings of each Team Member from team_member_ids for this service. Present only when requested with include[]=team_members.

Response
{ "id": 100, "object": "service", "type": "simple", "name": "Men's haircut", "online_booking_name": "Haircut for men", "online_booking_description": "Wash, cut and styling.", "category_id": 205, "chain_id": null, "duration_seconds": 3600, "weight": 2, "currency": "EUR", "online_booking_enabled": true, "team_member_ids": [ 321, 322 ], "package": null, "created_at": "2026-07-01T08:00:00Z", "price_min_minor": 250000, "price_max_minor": 300000 }