Choose the permission for the task
Keep your existing staff interface. Your backend calls these Management APIs after authenticating its own staff; Management keys must never reach the browser. Obtain an approved environment and check its installed capabilities and the owner-issued scopes. This documentation describes tested development behavior, not a deployment or activation guarantee.
The catalogue contains business service terms. Publication selects which eligible services appear on the booking website. Presentation contains explicitly public contact details and image URLs. These resources share service IDs but have separate versions and permissions.
These are business-wide permissions. Provider/calendar grants are not required and do not grant them. Existing keys are unchanged. Editing content does not activate website intake, connect WhatsApp, send a message or give a customer phone proof.
| Task | Required scopes |
|---|---|
| Read business services | services:read |
| Synchronize the current service catalogue | services:read and services:sync |
| Create, edit, reorder or delete services; recover these commands | services:read and services:write |
| Read website selection and presentation | website-content:read |
| Replace website selection or presentation; recover these commands | website-content:read and website-content:write |
Edit a treatment without changing accepted bookings
priceMajor and removalPriceMajor use major currency units: 120 means 120, not 1.20. Retain the returned currency label; the customer booking API has its own minor-unit fields. Do not share a money converter without checking the contract.
Where admitted for the business, the owner can choose a fixed price, a range or a price decided at the visit. A fixed numeric priceMajor, including a real zero, clears an earlier range. A priceRangeMajor object {min,max} stores a range with priceMajor:null; both bounds use major units, max must exceed min, and the amounts must be nonnegative with at most two decimal places. Do not send a numeric priceMajor together with a range object. Range admission is currently scoped to HALA; this does not enable ranges for other businesses.
To clear a range, send priceRangeMajor:null. For an unpriced consultation, send priceMajor:null and priceRangeMajor:null. Omitting the range preserves it during partial or duration-only edits, including an older client’s null-price write; omit priceMajor too when it was not edited. Public priceMinor and accepted exact base/total prices can be null. Optional priceRangeMinor uses integer minor units. Never coerce a null to zero, use a range minimum as an exact charge, or substitute today’s catalogue price for accepted terms.
Edits affect future quotes and preserve accepted appointment terms. Creating or activating a service does not automatically select it for the website. Reactivating a service that was already selected can restore its public eligibility. Catalogue changes use the separate service synchronization feed below; the appointment feed does not replicate them.
Load current services
GET the complete catalogue or one service. The list’s HTTP ETag is for catalogue reorder. For service edits, quote the item’s serviceVersion or use the ETag from its detail GET. Preserve values the user has not edited, including nullable legacy values.
Read complete business service catalogueRead one business catalogue serviceCreate or change terms
Create with an explicit mode and changes object. PATCH only edited fields in changes, using the service ETag as If-Match. Mode and legacyDurationMinutes cannot be changed in place. A service-duration service requires that business capability and valid duration/removal terms.
Create a business catalogue serviceEdit or deactivate a business catalogue serviceReview removal
Prefer deactivation when a service has appointment references. DELETE refuses SERVICE_IN_USE and also refuses removal of the last explicit provider-service link, because that would broaden provider eligibility. Successful deletion cleans that service’s current publication and image references.
Delete an unreferenced business catalogue serviceReorder the complete list
Send every current service ID exactly once in orderedIds, with the catalogue ETag. Include inactive and hidden rows; a filtered list is not a complete order. More than 1,000 services returns CATALOGUE_TOO_LARGE rather than a truncated editable list.
Reorder complete business service catalogue
Render fixed, estimated and unknown prices distinctly
The following values are illustrative formatting cases, not captured API responses. They use the Customer API service priceMinor and optional priceRangeMinor fields. Management service and calendar fields use major units instead. Apply these cases only after validating the complete response; range admission remains scoped to HALA.
Check for null before numeric conversion: JavaScript Number(null) and a fallback such as priceMinor ?? 0 both produce a false zero price. Preserve the optional range through response validators, server-to-browser mappings, caches and UI props. A new server field alone does not update an older client that drops it.
Before enabling ranges, verify these cases in the treatment list, current quote, review step, accepted receipt and administrator editor. Re-read authoritative terms after a selection change; retain frozen accepted terms during recovery. This check complements schema compatibility and does not authorize reconstructing an accepted price from the current catalogue.
| Validated customer price fields | Customer-facing meaning |
|---|---|
| priceMinor: 35000; no range | Fixed price: ₪350. |
| priceMinor: 0; no range | An explicit zero price: ₪0. Zero must not become “price decided at the visit”. |
| priceMinor: null; priceRangeMinor: {min:35000,max:60000} | Estimated range: ₪350–600. Neither bound is an agreed fixed charge. |
| priceMinor: null; no range | Price decided at the visit. Do not display ₪0 or “free”. |
| Required price field missing, malformed, or reported unavailable | Price unavailable. Do not invent an exact price, range or at-visit agreement. |
Keep your own catalogue current
The feed includes inactive services and current publication/deletion advice. Changes from CRAD’s native admin, setup and delegated APIs are covered, including dependency changes without a direct service edit. It is current-state convergence, not historical values or a second editable source of truth.
A snapshot member with removed:true or a changes event with current:null means remove or hide only that service’s CRAD projection, preserving your private fields. Snapshot membership can be deleted while you page it. A non-null current is authoritative even when an older event has type:removed; do not delete that newer current value.
Keep service, provider, customer and appointment streams separate. On lost access, hide the affected CRAD projection and preserve your own private fields. Rebuild on an expired cursor or changed projection epoch. Before editing, read the current item and use its own ETag; before booking, obtain a fresh quote and availability. A sync watermark never replaces either check.
Start with an explicit sync grant
Request services:read and services:sync and check installed serviceSync support. Start a service snapshot with {}. Store its cursor and stage the returned membership through service-changes.
Begin service synchronizationRead service membership or changesApply current values and the next cursor together
Read every page, including pages with no visible events. Apply services by serviceId and retain context for catalogue ordering and managed creation. Stage snapshot membership until kind:snapshot has hasMore:false; its nextCursor starts the changes stream. A signal’s current projection may already include a newer edit; apply current, not the event type alone.
Acknowledge durable progress
A kind:snapshot page with hasMore:true returns a partial cursor: save it for paging, but do not ACK it. The final snapshot page’s nextCursor is ACKable. Every kind:changes page’s nextCursor is ACKable after applying that page, even when hasMore:true or events is empty. In your database, commit the applied data, nextCursor and one pending ACK UUID together. POST that exact cursor with the UUID as Idempotency-Key. Retry an uncertain ACK unchanged; inspect currentProjectionEpoch and bootstrapRequired even on replay.
Acknowledge applied service changes
Choose which services appear online
GET service-publication returns the full bounded service options, current selected serviceIds, eligibility and a quoted pub:<version> ETag. Keep selected IDs even when they are absent from your current filtered view. Up to 100 services can be selected from at most 1,000 options.
PUT sends the complete desired serviceIds selection, not additions or removals. Start from the current read, apply the user’s choices and submit its unchanged ETag in If-Match. An empty array removes the public selection. The server checks current eligibility; SERVICE_NOT_PUBLISHABLE requires reviewing the selection.
Selection does not define catalogue order or activate website intake. Current activity, supported booking terms and site configuration still determine whether a selected service can be booked.
Keep the customer’s treatment picker connected to the selected published catalogue, including any unpriced consultation option. Use the service ID the customer selects. Publication is not authority to skip the choice or infer a booking service from catalogue order or a service name. Existing treatment identities, marketing content and accepted bookings remain intact.
Maintain public details and images
GET public-presentation returns localized location text, contactPhone, websiteUrl, imageUrl and serviceImages. PUT replaces the full presentation object. Preserve fields not edited in your form and use the quoted pres:<version> ETag; a publication ETag is not interchangeable.
Images are public HTTPS URL references, not uploads. Host the files yourself before saving their URLs. The server rejects private/internal URLs and unknown or foreign service IDs. There may be up to 100 service images with 2,048-character URLs, and up to 300 characters per localized location. A service ID may occur only once, regardless of UUID letter case.
The presentation request permits up to 1 MiB of JSON to accommodate these URLs. Publication and ordinary service bodies allow 8 KiB; the complete catalogue reorder alone allows 64 KiB. Oversized requests return 413. These limits do not authorize uploading image bytes.
Keep accepted results separate from current state
Persist one operation UUID and the exact request before every write. Use it as Idempotency-Key. After a timeout, recover that UUID from the matching operation endpoint before deciding what to do next. Recovery is read-only and requires current read/write authority for the same integration; an authorized rotated key can recover its earlier operations.
A not_found result does not prove an in-flight request cannot commit. Retain the original UUID, payload and precondition for an explicit exact retry. Do not create a new UUID or automatically replace If-Match with a newer version. A genuine version conflict requires refresh and user review.
receipt is the immutable accepted result. current is the presently authorized state and can differ after later edits. Deleting a service must not rewrite an earlier accepted image or selection receipt. For publication only, a later catalogue above 1,000 services can return current:null with currentUnavailableReason:catalogue_too_large while preserving that accepted receipt. Show the acceptance and explain that current content is unavailable; do not repeat the write.