# Add a reminder to a group

`POST /api/v1/vaults/{vault}/groups/{group}/reminders`

Write a reminder about a group as a whole, with a date of its own. The change is written to the account log.

Groups are not yet available to every account. Until they are available to yours, every endpoint here answers 404.

A starts_on before today answers 422 on starts_on, saying a reminder cannot start in the past. One that happens once, dated today, whose hour has already passed, answers 422 on time, saying the time for this reminder has already passed today.

A name left empty once reduced to plain text answers 422 on name, asking to say what the reminder is about. A time zone the application does not know answers 422 on timezone.

## Parameters

- `vault` (string, required): The vault the group lives in, named either by the readable name it reports as slug or by its id.
- `group` (uuid, required): The id of the group. One addressed through the wrong vault, deleted, or belonging to another account, answers 404.
- `name` (string, required): What the reminder says. Up to 255 characters, reduced to plain text.
- `starts_on` (string, required): The first date, written as a year, a month and a day.
- `cadence` (string, required): One of once, weekly, monthly or yearly.
- `interval` (integer, optional): How many of those between two dates, from 1 to 99. Ignored for once.
- `time` (string, required): The local hour to be told at, as hours and minutes.
- `timezone` (string, optional): The time zone that hour is read in. Your own when left out.

## Returns

The reminder object that was added.

- `data` (object): The reminder.
- `data.type` (string): Always reminder. It names the kind of record, so a caller holding several kinds can tell them apart without looking at where they came from.
- `data.id` (string): The id of this record, as a string even when it reads as a number. It is what every endpoint naming this record takes.
- `data.attributes` (object): Everything the record holds.
- `data.attributes.name` (string): What the reminder says when it comes due.
- `data.attributes.source` (string): Where its date comes from. Always manual for a group, since a group has no date of its own for a reminder to read.
- `data.attributes.starts_on` (string): The first date, written as a year, a month and a day.
- `data.attributes.field` (object): The date on a contact a reminder reads. Always null for a group.
- `data.attributes.contact` (object): The contact a reminder is about. Always null for a group.
- `data.attributes.entity` (object): The record a reminder is about. Always null for a group.
- `data.attributes.group` (object): The group the reminder is about.
- `data.attributes.group.id` (uuid): The id of the group.
- `data.attributes.group.name` (string): What the group is called.
- `data.attributes.cadence` (string): How often it comes back: once, weekly, monthly or yearly.
- `data.attributes.interval` (integer): How many of those between two dates. Every 3 months is monthly with an interval of 3.
- `data.attributes.time` (string): The local hour it is told at, on the day itself.
- `data.attributes.timezone` (string): The time zone that hour is read in, fixed when the reminder was made.
- `data.attributes.is_active` (boolean): Whether it still produces dates.
- `data.attributes.inactive_reason` (string): Why it stopped, such as record_deleted. Null while it is active.
- `data.attributes.next_date` (string): The next date it comes due, or null when nothing is ahead of it.
- `data.attributes.created_at` (timestamp): When the reminder was made, as a count of seconds since 1970.
- `data.links` (object): Where to find this record.
- `data.links.self` (string): The absolute address this record is read from.

## Rate limit

Sixty requests per minute, per user, shared by every key and device. Every answer carries the budget left in `X-RateLimit-Remaining`.

## Request

```sh
curl https://people.hansyeoh.com/api/v1/vaults/dunder-mifflin/groups/5d2a7c91-3e48-4b06-9f1d-a83c60e2b4f7/reminders \
  -X POST \
  -H "Authorization: Bearer $MONICA_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
      "name": "Book the conference room for the birthday party",
      "starts_on": "2026-11-20",
      "cadence": "monthly",
      "interval": "1",
      "time": "09:00",
      "timezone": "America/New_York"
  }'
```

```javascript
const response = await fetch('https://people.hansyeoh.com/api/v1/vaults/dunder-mifflin/groups/5d2a7c91-3e48-4b06-9f1d-a83c60e2b4f7/reminders', {
  method: 'POST',
  headers: { Authorization: `Bearer ${token}`, 'Content-Type': 'application/json' },
  body: JSON.stringify({
    name: 'Book the conference room for the birthday party',
    starts_on: '2026-11-20',
    cadence: 'monthly',
    interval: '1',
    time: '09:00',
    timezone: 'America/New_York',
  }),
})
const data = await response.json()
```

```php
$response = Http::withToken($token)->post('https://people.hansyeoh.com/api/v1/vaults/dunder-mifflin/groups/5d2a7c91-3e48-4b06-9f1d-a83c60e2b4f7/reminders', [
    'name' => 'Book the conference room for the birthday party',
    'starts_on' => '2026-11-20',
    'cadence' => 'monthly',
    'interval' => '1',
    'time' => '09:00',
    'timezone' => 'America/New_York',
]);
```

## Response

`201`

```json
{
    "data": {
        "type": "reminder",
        "id": "7c1e4a82-5b39-4d07-8f62-c3a9e0d51b84",
        "attributes": {
            "name": "Book the conference room for the birthday party",
            "source": "manual",
            "starts_on": "2026-11-20",
            "field": null,
            "contact": null,
            "entity": null,
            "group": {
                "id": "5d2a7c91-3e48-4b06-9f1d-a83c60e2b4f7",
                "name": "Party planning committee"
            },
            "cadence": "monthly",
            "interval": 1,
            "time": "09:00",
            "timezone": "America/New_York",
            "is_active": true,
            "inactive_reason": null,
            "next_date": "2026-11-20",
            "created_at": 1791547200
        },
        "links": {
            "self": "https://people.hansyeoh.com/api/v1/vaults/dunder-mifflin/groups/5d2a7c91-3e48-4b06-9f1d-a83c60e2b4f7/reminders/7c1e4a82-5b39-4d07-8f62-c3a9e0d51b84"
        }
    }
}
```
