---
title: "POST /api/appointment_templates"
method: POST
path: "/api/appointment_templates"
tags: ["Clinical"]
---

# POST /api/appointment_templates

`POST /api/appointment_templates`

Create appointment templates for a doctor's calendar

## Query parameters

- `profile` integer
- `office` integer
- `doctor` integer

## Response `201`

Created

- AppointmentTemplate — Appointment templates are blocks of time during which a doctor usually sees appointments with the same profile. These may have a longer duration then the corresponding profile, in which case they may allow multiple appointments to be booked during that period.
  - `profile` integer, required — ID of the appointment profile to default to
  - `scheduled_time` string, required
  - `archived` boolean — Indicats that the object has been soft-deleted and should not be used
  - `week_days` integer[] — Array of integers that indicate week days (`0` = Monday, ..., `6` = Sunday)
  - `office` integer, required
  - `open_slots` object[] — Array of time intervals during which the template is available. Only computed if the available and verbose query parameters are passed. Note that only slots long enough to fit an appointment with the corresponding profile are included.
    - `start` string
    - `end` string
  - `date_end` string
  - `date_start` string
  - `exam_room` integer, required — **1-based** index for the exam room
  - `duration` integer — Length of an appointment in minutes
  - `id` integer

## Other responses

- `400` — Bad Request
- `401` — Unauthorized
- `403` — Permission Denied
- `404` — Not Found
- `405` — Method Not Allowed
- `500` — Internal Server Error

---

[API](https://skmtc.net/drchrono/apis/untitled-api.md) · [All operations](https://skmtc.net/drchrono/apis/untitled-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/drchrono/untitled-api/versions/e595797fe800/schema)
