Services

This API documentation outlines the functionalities for managing services within Whautomate. It follows the CRUD (Create, Read, Update, Delete) paradigm, enabling you to perform the following actions

This API offers functionalities to:

  • Creating new services: Establish new service entries, defining their names, descriptions, pricing structures, and associating them with relevant categories.

  • Accessing service information: Retrieve details of all available services or a specific service by its unique identifier.

  • Updating service details: Modify existing services to keep information accurate and reflect any changes. This might involve updating names, descriptions, pricing, or category associations.

  • Removing services: Permanently delete services that are no longer offered, ensuring a clean and up-to-date service catalogue.

get
Query parameters
locationIdstringOptional
limitstringOptional
pagestringOptional
serviceTypestringOptional
searchTextstringOptional
Header parameters
x-api-keystringRequired
Responses
200
200 response
application/json
get
GET /v1/services HTTP/1.1
Host: <YOUR HOST>
x-api-key: text
Accept: */*
200

200 response

[
  {
    "id": "text",
    "serviceType": "APPOINTMENT",
    "name": "text",
    "location": {
      "id": "text",
      "title": "text"
    },
    "durationMinutes": 1,
    "categories": [
      {
        "id": "text",
        "name": "text"
      }
    ],
    "staffs": [
      {
        "id": "text",
        "name": "text"
      }
    ],
    "numberOfParticipants": 1,
    "type": "LOCATION_VISIT",
    "sellingPrice": 1,
    "costPrice": 1,
    "taxOverrides": [
      {
        "id": "text",
        "name": "text",
        "percentage": "text"
      }
    ],
    "isCustomCredit": true,
    "credits": 1,
    "active": true,
    "allowOnlineBooking": true,
    "acceptPaymentOnline": true,
    "advanceSettings": {
      "advanceBookingLimitDays": 1,
      "blockTimeAfterAppointment": 1
    },
    "addOnAppliesTo": "SELECTED_SERVICES",
    "addOnServices": [
      {
        "id": "text",
        "name": "text"
      }
    ],
    "sortOrder": 1
  }
]
post
Header parameters
x-api-keystringRequired
Body
idstringOptional
serviceTypestring · enumRequiredPossible values:
namestringRequired
durationMinutesintegerOptional
numberOfParticipantsnumberOptional
typestring · enumOptionalPossible values:
sellingPricenumberRequired
costPricenumberOptional
isCustomCreditbooleanOptional
creditsintegerOptional
activebooleanOptional
allowOnlineBookingbooleanOptional
acceptPaymentOnlinebooleanOptional
addOnAppliesTostring · enumOptionalPossible values:
sortOrderintegerOptional
Responses
200
200 response
application/json
Responseobject · EmptySchema
post
POST /v1/services HTTP/1.1
Host: <YOUR HOST>
x-api-key: text
Content-Type: application/json
Accept: */*
Content-Length: 618

{
  "id": "text",
  "serviceType": "APPOINTMENT",
  "name": "text",
  "location": {
    "id": "text",
    "title": "text"
  },
  "durationMinutes": 1,
  "categories": [
    {
      "id": "text",
      "name": "text"
    }
  ],
  "staffs": [
    {
      "id": "text",
      "name": "text"
    }
  ],
  "numberOfParticipants": 1,
  "type": "LOCATION_VISIT",
  "sellingPrice": 1,
  "costPrice": 1,
  "taxOverrides": [
    {
      "id": "text",
      "name": "text",
      "percentage": "text"
    }
  ],
  "isCustomCredit": true,
  "credits": 1,
  "active": true,
  "allowOnlineBooking": true,
  "acceptPaymentOnline": true,
  "advanceSettings": {
    "advanceBookingLimitDays": 1,
    "blockTimeAfterAppointment": 1
  },
  "addOnAppliesTo": "SELECTED_SERVICES",
  "addOnServices": [
    {
      "id": "text",
      "name": "text"
    }
  ],
  "sortOrder": 1
}
200

200 response

{}
get
Path parameters
serviceIdstringRequired
Header parameters
x-api-keystringRequired
Responses
200
200 response
application/json
get
GET /v1/services/{serviceId} HTTP/1.1
Host: <YOUR HOST>
x-api-key: text
Accept: */*
200

200 response

{
  "id": "text",
  "serviceType": "APPOINTMENT",
  "name": "text",
  "location": {
    "id": "text",
    "title": "text"
  },
  "durationMinutes": 1,
  "categories": [
    {
      "id": "text",
      "name": "text"
    }
  ],
  "staffs": [
    {
      "id": "text",
      "name": "text"
    }
  ],
  "numberOfParticipants": 1,
  "type": "LOCATION_VISIT",
  "sellingPrice": 1,
  "costPrice": 1,
  "taxOverrides": [
    {
      "id": "text",
      "name": "text",
      "percentage": "text"
    }
  ],
  "isCustomCredit": true,
  "credits": 1,
  "active": true,
  "allowOnlineBooking": true,
  "acceptPaymentOnline": true,
  "advanceSettings": {
    "advanceBookingLimitDays": 1,
    "blockTimeAfterAppointment": 1
  },
  "addOnAppliesTo": "SELECTED_SERVICES",
  "addOnServices": [
    {
      "id": "text",
      "name": "text"
    }
  ],
  "sortOrder": 1
}
put
Path parameters
serviceIdstringRequired
Header parameters
x-api-keystringRequired
Responses
200
200 response
application/json
put
PUT /v1/services/{serviceId} HTTP/1.1
Host: <YOUR HOST>
x-api-key: text
Accept: */*
200

200 response

{
  "id": "text",
  "serviceType": "APPOINTMENT",
  "name": "text",
  "location": {
    "id": "text",
    "title": "text"
  },
  "durationMinutes": 1,
  "categories": [
    {
      "id": "text",
      "name": "text"
    }
  ],
  "staffs": [
    {
      "id": "text",
      "name": "text"
    }
  ],
  "numberOfParticipants": 1,
  "type": "LOCATION_VISIT",
  "sellingPrice": 1,
  "costPrice": 1,
  "taxOverrides": [
    {
      "id": "text",
      "name": "text",
      "percentage": "text"
    }
  ],
  "isCustomCredit": true,
  "credits": 1,
  "active": true,
  "allowOnlineBooking": true,
  "acceptPaymentOnline": true,
  "advanceSettings": {
    "advanceBookingLimitDays": 1,
    "blockTimeAfterAppointment": 1
  },
  "addOnAppliesTo": "SELECTED_SERVICES",
  "addOnServices": [
    {
      "id": "text",
      "name": "text"
    }
  ],
  "sortOrder": 1
}

Last updated