Core resources


Administration


Booking flow

Service discounts

Discounts per service

The service discount object

Attributes

iduuid

Unique identifier

service_iduuid
services.id

Identifier of the related service

created_attimestamp with time zone

Creation timestamp

updated_attimestamp with time zone

Last modification timestamp

definitionjsonb

Definition of the discount

namejsonb

Localized name

The service discount object
{
"id": "00000000-0000-0000-0000-000000000000",
"service_id": "00000000-0000-0000-0000-000000000000",
"created_at": "2024-05-22T01:37:14.115Z",
"updated_at": "2024-05-22T01:37:14.115Z",
"definition": {},
"name": {}
}

List service discounts

Filters

idFilter<uuid>

Unique identifier

service_idFilter<uuid>

Identifier of the related service

created_atFilter<timestamp with time zone>

Creation timestamp

updated_atFilter<timestamp with time zone>

Last modification timestamp

definitionFilter<jsonb>

Definition of the discount

nameFilter<jsonb>

Localized name

Responses

200

A list of service discounts with the selected columns

206

Partial Content

GET/service_discounts
curl -X GET "https://api.bookingmood.com/v1/service_discounts?select=*" \
  -H "Authorization: Bearer YOUR_API_KEY"

Create service discounts

Body

Partial<ServiceDiscount>
| Array<Partial<ServiceDiscount>>

Responses

201

The newly created service discounts with the selected columns

POST/service_discounts
curl -X POST "https://api.bookingmood.com/v1/service_discounts" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -d '[]'

Delete service discounts

Filters

idFilter<uuid>

Unique identifier

service_idFilter<uuid>

Identifier of the related service

created_atFilter<timestamp with time zone>

Creation timestamp

updated_atFilter<timestamp with time zone>

Last modification timestamp

definitionFilter<jsonb>

Definition of the discount

nameFilter<jsonb>

Localized name

Responses

204

The deleted service discounts with the selected columns

DELETE/service_discounts
curl -X DELETE "https://api.bookingmood.com/v1/service_discounts" \
  -H "Authorization: Bearer YOUR_API_KEY"

Update service discounts

Filters

idFilter<uuid>

Unique identifier

service_idFilter<uuid>

Identifier of the related service

created_atFilter<timestamp with time zone>

Creation timestamp

updated_atFilter<timestamp with time zone>

Last modification timestamp

definitionFilter<jsonb>

Definition of the discount

nameFilter<jsonb>

Localized name

Body

Partial<ServiceDiscount>

Responses

204

The updated service discounts with the selected columns

PATCH/service_discounts
curl -X PATCH "https://api.bookingmood.com/v1/service_discounts" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -d '{}'