OfficeGest
Workshop/Appointments

List appointments

Returns workshop calendar events within the given date range, optionally filtered by employee, warehouse or department. With vehicle_plate, the date range becomes optional and every appointment of that vehicle is returned. With search, the date range becomes optional and the endpoint returns the matching appointments from any date, ranked by relevance and capped, with a meta object describing the cap.

GET
/workshop/appointments
AuthorizationBearer <token>

In: header

Query Parameters

employee_id?integer

Filter by employee ID.

warehouse_id?integer

Filter by warehouse ID.

department_id?integer

Filter by department ID.

service_order?integer

Filter by service order number.

rescheduled_from?integer

Filter appointments rescheduled from the given appointment ID.

vehicle_plate?string

Exact vehicle plate. When present, the date range becomes optional and every appointment of the vehicle is returned, uncapped.

search?string

Text search on subject, customer name, vehicle plate and service order number. When present, the date range becomes optional and the search is global; results are ranked by relevance and capped (see meta).

start?string

Start of the date range. Required unless search or vehicle_plate is present, and always required together with end.

Formatdate-time
end?string

End of the date range. Required unless search or vehicle_plate is present, and always required together with start.

Formatdate-time

Response Body

curl -X GET "https://og-tenant1.test:8003/api/v2/workshop/appointments?employee_id=0&warehouse_id=0&department_id=0&service_order=0&rescheduled_from=0&vehicle_plate=string&search=string&start=2019-08-24T14%3A15%3A22Z&end=2019-08-24T14%3A15%3A22Z"
{
  "data": [
    {
      "resource": "string"
    }
  ]
}
{
  "data": {
    "code": "VALIDATION_FAILED",
    "message": "The given data was invalid.",
    "errors": {
      "email": [
        "The email field is required."
      ]
    }
  },
  "meta": {
    "trace_id": "9f86d081884c7d659a2feaa0c55ad01568f3a1c2b4d5e"
  }
}
{
  "data": {
    "code": "VALIDATION_FAILED",
    "message": "The given data was invalid.",
    "errors": {
      "email": [
        "The email field is required."
      ]
    }
  },
  "meta": {
    "trace_id": "9f86d081884c7d659a2feaa0c55ad01568f3a1c2b4d5e"
  }
}
{
  "data": {
    "code": "VALIDATION_FAILED",
    "message": "The given data was invalid.",
    "errors": {
      "email": [
        "The email field is required."
      ]
    }
  },
  "meta": {
    "trace_id": "9f86d081884c7d659a2feaa0c55ad01568f3a1c2b4d5e"
  }
}
{
  "data": {
    "code": "VALIDATION_FAILED",
    "message": "The given data was invalid.",
    "errors": {
      "email": [
        "The email field is required."
      ]
    }
  },
  "meta": {
    "trace_id": "9f86d081884c7d659a2feaa0c55ad01568f3a1c2b4d5e"
  }
}