Create
POST
/:tenantId/appointment-typesBody
json
{
"name": "Check up",
"is_default": 0,
"color": "#973544",
"status": 1
}| Key | Type | Required | Description |
|---|---|---|---|
| name | string | yes | The name of the appointment type. |
| is_default | integer | no | Indicates if it's the default type 0: No (default) 1: Yes |
| color | string | no | The color associated with the appointment type. |
| status | integer | no | The status of the appointment type 0: Inactive 1: Active (default) |
Response
HTTP 200 OK
json
{
"data": {
"id": 335,
"name": "Check up",
"status": 1,
"is_default": false,
"color": "#973544",
"deleted_at": null,
"created_at": "2024-11-29T06:14:12.000000Z",
"updated_at": "2024-11-29T06:14:12.000000Z"
}
}HTTP 422 Unprocessable Content
json
{
"message": "The name field is required.",
"errors": {
"name": [
"The name field is required."
]
}
}