---
title: "Add times to a class's calendar, or a calendar appointment's: a date, a start and end (or all day, or overnight), how it repeats and who teaches. Its sessions are made about a year ahead."
method: POST
path: "/series"
tags: ["series"]
---

# Add times to a class's calendar, or a calendar appointment's: a date, a start and end (or all day, or overnight), how it repeats and who teaches. Its sessions are made about a year ahead.

`POST /series`

## Request

- Base URL: `https://daybag.io/api/v1`
- URL: `https://daybag.io/api/v1/series`
- Auth: HTTP bearer

## Request body

- object
  - `starts_on` string, date, required: The first time's local date (YYYY-MM-DD) in the org's time zone
  - `start_time` string, nullable: Local start, HH:MM. Leave start_time and end_time out for all day
  - `end_time` string, nullable: Local end, HH:MM; before the start with span_days 1 runs overnight
  - `span_days` integer: Days from a time's date to the date it ends (default 0): 1 runs overnight; all day, the extra whole days
  - `repeat` 'none' | 'daily' | 'weekly' | 'monthly' | 'yearly' | 'weekdays': How it repeats (default none)
  - `capacity` integer, nullable: Classes only: seats for these times; null uses the class's
  - `teacher` string, uuid, nullable: Who teaches it: a member's user id (Settings → Team); null for nobody. Anyone not on your team answers 400 not_a_member. Copied to each of its times; a change reaches every time to come
  - `ends_on` string, date, nullable: Local calendar date (YYYY-MM-DD) in the org's time zone
  - `offering_id` string, uuid, required

## Response `201`

Success

- object
  - `id` string, required
  - `org_id` string, required
  - `offering_id` string, required
  - `starts_on` string, required: The first time's local date
  - `start_time` string, nullable, required: Local HH:MM:SS; null with end_time null is all day
  - `end_time` string, nullable, required
  - `span_days` integer, required: Days from a time's date to the date it ends
  - `repeat` 'none' | 'daily' | 'weekly' | 'monthly' | 'yearly' | 'weekdays', required: none · daily · weekly (its first date's weekday) · monthly (that weekday of the month, e.g. the last Tuesday) · yearly · weekdays (Monday to Friday)
  - `capacity` integer, nullable, required: A class's seats for these times; null uses the class's
  - `ends_on` string, nullable: A repeat's last local date, that day included; null repeats on
  - `made_until` string, required: Its sessions exist through this local date; repeats are kept about a year ahead
  - `teacher` object, nullable: Who teaches it; null for nobody
    - `user_id` string, required
    - `name` string, required: Their name, or their email's local part until they set one
  - `created_at` string, required: ISO 8601 timestamp (UTC)

## Other responses

- `default`: Error

---

[API](https://skmtc.dev/daybag/apis/daybooked-io-api.md) · [All operations](https://skmtc.dev/daybag/apis/daybooked-io-api/llms.txt) · [OpenAPI document](https://skmtc.dev/daybag/apis/daybooked-io-api/revisions/1f576dead370?raw)
