One occurrence of a repeating event doesn't happen
calendar.event.cancel_occurrence
POST/api/v1/households/{household_id}/commands/calendar.event.cancel_occurrence
- Command
- Rigel runs it
- Applies offline
Cancels a single occurrence, named by occurrence_start, without touching the rest. Use this for 'not this week', not a deletion. Cancelling it again changes nothing. Errors: event_not_found, event_owned_by_app, occurrence_not_found.
Parameters#
| Field | Description |
|---|---|
household_idpathstringrequired | The household's ID. |
Idempotency-Keyheaderstringoptional | The command's ID. Reuse it when retrying the same command. |
Request body#
JSON, as application/json.
| Field | Description |
|---|---|
event_idstringrequired | A calendar event ID, such as evt_01JC0000000000000000000000. |
occurrence_startstringrequired | Which occurrence, by its original start in the event's zone: 2026-11-14T09:00 for a timed event, 2026-11-14 for an all-day one. Use the occurrence_start that |
Response#
200 The command was applied.
| Field | Description |
|---|---|
resultobjectrequired | What the command returned, such as the IDs it created. |
versionintegerrequired | The household version after the command. |
Errors#
Every error has the same envelope: error.code, error.message, error.details, error.recovery and error.request_id.
| Status | Code | When |
|---|---|---|
400 | validation_failed | A field is missing, misspelled or out of range. details.fields lists each problem. |
401 | unauthenticated | The request has no valid session. |
404 | event_not_found |
|
404 | occurrence_not_found |
|
404 | not_found | The household doesn't exist, or you aren't a member of it. |
409 | event_owned_by_app | An event another app owns is refused. |
409 | idempotency_key_reused | The Idempotency-Key was already used for a different command. |
Examples#
These are real. Each scenario is one of the command's test cases, run on a household when this site was built, and the response is what the API returned.
Cancelling one Saturday adds a cancelled exception and leaves the series alone
curl -X POST 'https://rigel.house/api/v1/households/hh_01K9BKKP003AHRZ6DMV29GQY5C/commands/calendar.event.cancel_occurrence' \
-H "Cookie: rigel_session=$RIGEL_SESSION" \
-H 'Content-Type: application/json' \
-H 'Idempotency-Key: cmd_01JC4N0000AAAAAAAAAAAAAAAA' \
-d '{
"event_id": "evt_01JC000000000000000000000A",
"occurrence_start": "2025-11-15T09:00:00"
}'const response = await fetch("https://rigel.house/api/v1/households/hh_01K9BKKP003AHRZ6DMV29GQY5C/commands/calendar.event.cancel_occurrence", {
method: "POST",
headers: {
"Content-Type": "application/json",
"Idempotency-Key": "cmd_01JC4N0000AAAAAAAAAAAAAAAA",
Cookie: `rigel_session=${process.env.RIGEL_SESSION}`,
},
body: JSON.stringify({
event_id: "evt_01JC000000000000000000000A",
occurrence_start: "2025-11-15T09:00:00",
}),
});
const data = await response.json();POST /api/v1/households/hh_01K9BKKP003AHRZ6DMV29GQY5C/commands/calendar.event.cancel_occurrence HTTP/1.1
Host: rigel.house
Cookie: rigel_session=<your session>
Content-Type: application/json
Idempotency-Key: cmd_01JC4N0000AAAAAAAAAAAAAAAA
{
"event_id": "evt_01JC000000000000000000000A",
"occurrence_start": "2025-11-15T09:00:00"
}HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: req_01K9D9S2R0P9QNVX80S0WX3XD5
{
"result": {},
"version": 1
}An occurrence that already has changes keeps them and is cancelled
curl -X POST 'https://rigel.house/api/v1/households/hh_01K9BKKP003AHRZ6DMV29GQY5C/commands/calendar.event.cancel_occurrence' \
-H "Cookie: rigel_session=$RIGEL_SESSION" \
-H 'Content-Type: application/json' \
-H 'Idempotency-Key: cmd_01JC4N0000AAAAAAAAAAAAAAAA' \
-d '{
"event_id": "evt_01JC000000000000000000000A",
"occurrence_start": "2025-11-15T09:00"
}'const response = await fetch("https://rigel.house/api/v1/households/hh_01K9BKKP003AHRZ6DMV29GQY5C/commands/calendar.event.cancel_occurrence", {
method: "POST",
headers: {
"Content-Type": "application/json",
"Idempotency-Key": "cmd_01JC4N0000AAAAAAAAAAAAAAAA",
Cookie: `rigel_session=${process.env.RIGEL_SESSION}`,
},
body: JSON.stringify({
event_id: "evt_01JC000000000000000000000A",
occurrence_start: "2025-11-15T09:00",
}),
});
const data = await response.json();POST /api/v1/households/hh_01K9BKKP003AHRZ6DMV29GQY5C/commands/calendar.event.cancel_occurrence HTTP/1.1
Host: rigel.house
Cookie: rigel_session=<your session>
Content-Type: application/json
Idempotency-Key: cmd_01JC4N0000AAAAAAAAAAAAAAAA
{
"event_id": "evt_01JC000000000000000000000A",
"occurrence_start": "2025-11-15T09:00"
}HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: req_01K9D9S2R0PSV4ZT5SBR67VB0T
{
"result": {},
"version": 1
}Cancelling twice changes nothing but the event's version
curl -X POST 'https://rigel.house/api/v1/households/hh_01K9BKKP003AHRZ6DMV29GQY5C/commands/calendar.event.cancel_occurrence' \
-H "Cookie: rigel_session=$RIGEL_SESSION" \
-H 'Content-Type: application/json' \
-H 'Idempotency-Key: cmd_01JC4N0000AAAAAAAAAAAAAAAA' \
-d '{
"event_id": "evt_01JC000000000000000000000A",
"occurrence_start": "2025-11-15T09:00:00"
}'const response = await fetch("https://rigel.house/api/v1/households/hh_01K9BKKP003AHRZ6DMV29GQY5C/commands/calendar.event.cancel_occurrence", {
method: "POST",
headers: {
"Content-Type": "application/json",
"Idempotency-Key": "cmd_01JC4N0000AAAAAAAAAAAAAAAA",
Cookie: `rigel_session=${process.env.RIGEL_SESSION}`,
},
body: JSON.stringify({
event_id: "evt_01JC000000000000000000000A",
occurrence_start: "2025-11-15T09:00:00",
}),
});
const data = await response.json();POST /api/v1/households/hh_01K9BKKP003AHRZ6DMV29GQY5C/commands/calendar.event.cancel_occurrence HTTP/1.1
Host: rigel.house
Cookie: rigel_session=<your session>
Content-Type: application/json
Idempotency-Key: cmd_01JC4N0000AAAAAAAAAAAAAAAA
{
"event_id": "evt_01JC000000000000000000000A",
"occurrence_start": "2025-11-15T09:00:00"
}HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: req_01K9D9S2R0XHKMV1M5RR1DFTH4
{
"result": {},
"version": 1
}Cancelling the occurrence that has a pending reminder withdraws it and schedules the next one
curl -X POST 'https://rigel.house/api/v1/households/hh_01K9BKKP003AHRZ6DMV29GQY5C/commands/calendar.event.cancel_occurrence' \
-H "Cookie: rigel_session=$RIGEL_SESSION" \
-H 'Content-Type: application/json' \
-H 'Idempotency-Key: cmd_01JC4N0000AAAAAAAAAAAAAAAA' \
-d '{
"event_id": "evt_01JC000000000000000000000A",
"occurrence_start": "2025-11-15T09:00:00"
}'const response = await fetch("https://rigel.house/api/v1/households/hh_01K9BKKP003AHRZ6DMV29GQY5C/commands/calendar.event.cancel_occurrence", {
method: "POST",
headers: {
"Content-Type": "application/json",
"Idempotency-Key": "cmd_01JC4N0000AAAAAAAAAAAAAAAA",
Cookie: `rigel_session=${process.env.RIGEL_SESSION}`,
},
body: JSON.stringify({
event_id: "evt_01JC000000000000000000000A",
occurrence_start: "2025-11-15T09:00:00",
}),
});
const data = await response.json();POST /api/v1/households/hh_01K9BKKP003AHRZ6DMV29GQY5C/commands/calendar.event.cancel_occurrence HTTP/1.1
Host: rigel.house
Cookie: rigel_session=<your session>
Content-Type: application/json
Idempotency-Key: cmd_01JC4N0000AAAAAAAAAAAAAAAA
{
"event_id": "evt_01JC000000000000000000000A",
"occurrence_start": "2025-11-15T09:00:00"
}HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: req_01K9HXZGJ0KPE6BE53JRGTC12F
{
"result": {},
"version": 1
}A day the rule doesn't reach isn't an occurrence
curl -X POST 'https://rigel.house/api/v1/households/hh_01K9BKKP003AHRZ6DMV29GQY5C/commands/calendar.event.cancel_occurrence' \
-H "Cookie: rigel_session=$RIGEL_SESSION" \
-H 'Content-Type: application/json' \
-H 'Idempotency-Key: cmd_01JC4N0000AAAAAAAAAAAAAAAA' \
-d '{
"event_id": "evt_01JC000000000000000000000A",
"occurrence_start": "2025-11-14T09:00"
}'const response = await fetch("https://rigel.house/api/v1/households/hh_01K9BKKP003AHRZ6DMV29GQY5C/commands/calendar.event.cancel_occurrence", {
method: "POST",
headers: {
"Content-Type": "application/json",
"Idempotency-Key": "cmd_01JC4N0000AAAAAAAAAAAAAAAA",
Cookie: `rigel_session=${process.env.RIGEL_SESSION}`,
},
body: JSON.stringify({
event_id: "evt_01JC000000000000000000000A",
occurrence_start: "2025-11-14T09:00",
}),
});
const data = await response.json();POST /api/v1/households/hh_01K9BKKP003AHRZ6DMV29GQY5C/commands/calendar.event.cancel_occurrence HTTP/1.1
Host: rigel.house
Cookie: rigel_session=<your session>
Content-Type: application/json
Idempotency-Key: cmd_01JC4N0000AAAAAAAAAAAAAAAA
{
"event_id": "evt_01JC000000000000000000000A",
"occurrence_start": "2025-11-14T09:00"
}HTTP/1.1 404 Not Found
Content-Type: application/json
X-Request-Id: req_01K9D9S2R035ZVTN1ETPVCZVXT
{
"error": {
"code": "occurrence_not_found",
"message": "The event doesn't happen at 2025-11-14T09:00:00. No changes were applied.",
"details": {
"occurrence_start": "2025-11-14T09:00:00"
},
"recovery": "Read the current state, then send a command that fits it.",
"request_id": "req_01K9D9S2R035ZVTN1ETPVCZVXT"
}
}An all-day key doesn't fit a timed event
curl -X POST 'https://rigel.house/api/v1/households/hh_01K9BKKP003AHRZ6DMV29GQY5C/commands/calendar.event.cancel_occurrence' \
-H "Cookie: rigel_session=$RIGEL_SESSION" \
-H 'Content-Type: application/json' \
-H 'Idempotency-Key: cmd_01JC4N0000AAAAAAAAAAAAAAAA' \
-d '{
"event_id": "evt_01JC000000000000000000000A",
"occurrence_start": "2025-11-15"
}'const response = await fetch("https://rigel.house/api/v1/households/hh_01K9BKKP003AHRZ6DMV29GQY5C/commands/calendar.event.cancel_occurrence", {
method: "POST",
headers: {
"Content-Type": "application/json",
"Idempotency-Key": "cmd_01JC4N0000AAAAAAAAAAAAAAAA",
Cookie: `rigel_session=${process.env.RIGEL_SESSION}`,
},
body: JSON.stringify({
event_id: "evt_01JC000000000000000000000A",
occurrence_start: "2025-11-15",
}),
});
const data = await response.json();POST /api/v1/households/hh_01K9BKKP003AHRZ6DMV29GQY5C/commands/calendar.event.cancel_occurrence HTTP/1.1
Host: rigel.house
Cookie: rigel_session=<your session>
Content-Type: application/json
Idempotency-Key: cmd_01JC4N0000AAAAAAAAAAAAAAAA
{
"event_id": "evt_01JC000000000000000000000A",
"occurrence_start": "2025-11-15"
}HTTP/1.1 404 Not Found
Content-Type: application/json
X-Request-Id: req_01K9D9S2R098K869FZMSC5F6W9
{
"error": {
"code": "occurrence_not_found",
"message": "This event has a start time, so name the occurrence by its date and time, such as 2026-11-14T09:00. No changes were applied.",
"details": {
"occurrence_start": "2025-11-15"
},
"recovery": "Read the current state, then send a command that fits it.",
"request_id": "req_01K9D9S2R098K869FZMSC5F6W9"
}
}An event that doesn't repeat can't have one occurrence cancelled
curl -X POST 'https://rigel.house/api/v1/households/hh_01K9BKKP003AHRZ6DMV29GQY5C/commands/calendar.event.cancel_occurrence' \
-H "Cookie: rigel_session=$RIGEL_SESSION" \
-H 'Content-Type: application/json' \
-H 'Idempotency-Key: cmd_01JC4N0000AAAAAAAAAAAAAAAA' \
-d '{
"event_id": "evt_01JC000000000000000000000B",
"occurrence_start": "2025-11-11T15:30"
}'const response = await fetch("https://rigel.house/api/v1/households/hh_01K9BKKP003AHRZ6DMV29GQY5C/commands/calendar.event.cancel_occurrence", {
method: "POST",
headers: {
"Content-Type": "application/json",
"Idempotency-Key": "cmd_01JC4N0000AAAAAAAAAAAAAAAA",
Cookie: `rigel_session=${process.env.RIGEL_SESSION}`,
},
body: JSON.stringify({
event_id: "evt_01JC000000000000000000000B",
occurrence_start: "2025-11-11T15:30",
}),
});
const data = await response.json();POST /api/v1/households/hh_01K9BKKP003AHRZ6DMV29GQY5C/commands/calendar.event.cancel_occurrence HTTP/1.1
Host: rigel.house
Cookie: rigel_session=<your session>
Content-Type: application/json
Idempotency-Key: cmd_01JC4N0000AAAAAAAAAAAAAAAA
{
"event_id": "evt_01JC000000000000000000000B",
"occurrence_start": "2025-11-11T15:30"
}HTTP/1.1 404 Not Found
Content-Type: application/json
X-Request-Id: req_01K9D9S2R0F20GSKS9VH7DG1WM
{
"error": {
"code": "occurrence_not_found",
"message": "That event doesn't repeat, so it has no separate occurrences. Change the event itself. No changes were applied.",
"details": {
"occurrence_start": "2025-11-11T15:30:00"
},
"recovery": "Read the current state, then send a command that fits it.",
"request_id": "req_01K9D9S2R0F20GSKS9VH7DG1WM"
}
}An event another app owns is refused
curl -X POST 'https://rigel.house/api/v1/households/hh_01K9BKKP003AHRZ6DMV29GQY5C/commands/calendar.event.cancel_occurrence' \
-H "Cookie: rigel_session=$RIGEL_SESSION" \
-H 'Content-Type: application/json' \
-H 'Idempotency-Key: cmd_01JC4N0000AAAAAAAAAAAAAAAA' \
-d '{
"event_id": "evt_01JC000000000000000000000D",
"occurrence_start": "2025-11-21T09:00"
}'const response = await fetch("https://rigel.house/api/v1/households/hh_01K9BKKP003AHRZ6DMV29GQY5C/commands/calendar.event.cancel_occurrence", {
method: "POST",
headers: {
"Content-Type": "application/json",
"Idempotency-Key": "cmd_01JC4N0000AAAAAAAAAAAAAAAA",
Cookie: `rigel_session=${process.env.RIGEL_SESSION}`,
},
body: JSON.stringify({
event_id: "evt_01JC000000000000000000000D",
occurrence_start: "2025-11-21T09:00",
}),
});
const data = await response.json();POST /api/v1/households/hh_01K9BKKP003AHRZ6DMV29GQY5C/commands/calendar.event.cancel_occurrence HTTP/1.1
Host: rigel.house
Cookie: rigel_session=<your session>
Content-Type: application/json
Idempotency-Key: cmd_01JC4N0000AAAAAAAAAAAAAAAA
{
"event_id": "evt_01JC000000000000000000000D",
"occurrence_start": "2025-11-21T09:00"
}HTTP/1.1 409 Conflict
Content-Type: application/json
X-Request-Id: req_01K9D9S2R0B2QWKC7102722VSS
{
"error": {
"code": "event_owned_by_app",
"message": "Maintenance manages this event. Change it there. No changes were applied.",
"details": {
"app": "maintenance"
},
"recovery": "Read the current state, then send a command that fits it.",
"request_id": "req_01K9D9S2R0B2QWKC7102722VSS"
}
}The event must exist
curl -X POST 'https://rigel.house/api/v1/households/hh_01K9BKKP003AHRZ6DMV29GQY5C/commands/calendar.event.cancel_occurrence' \
-H "Cookie: rigel_session=$RIGEL_SESSION" \
-H 'Content-Type: application/json' \
-H 'Idempotency-Key: cmd_01JC4N0000AAAAAAAAAAAAAAAA' \
-d '{
"event_id": "evt_01JC000000000000000000000Z",
"occurrence_start": "2025-11-15T09:00:00"
}'const response = await fetch("https://rigel.house/api/v1/households/hh_01K9BKKP003AHRZ6DMV29GQY5C/commands/calendar.event.cancel_occurrence", {
method: "POST",
headers: {
"Content-Type": "application/json",
"Idempotency-Key": "cmd_01JC4N0000AAAAAAAAAAAAAAAA",
Cookie: `rigel_session=${process.env.RIGEL_SESSION}`,
},
body: JSON.stringify({
event_id: "evt_01JC000000000000000000000Z",
occurrence_start: "2025-11-15T09:00:00",
}),
});
const data = await response.json();POST /api/v1/households/hh_01K9BKKP003AHRZ6DMV29GQY5C/commands/calendar.event.cancel_occurrence HTTP/1.1
Host: rigel.house
Cookie: rigel_session=<your session>
Content-Type: application/json
Idempotency-Key: cmd_01JC4N0000AAAAAAAAAAAAAAAA
{
"event_id": "evt_01JC000000000000000000000Z",
"occurrence_start": "2025-11-15T09:00:00"
}HTTP/1.1 404 Not Found
Content-Type: application/json
X-Request-Id: req_01K9D9S2R03X0KZK1CC6CBYTYP
{
"error": {
"code": "event_not_found",
"message": "That event isn't on the calendar any more. No changes were applied.",
"details": {
"event_id": "evt_01JC000000000000000000000Z"
},
"recovery": "Read the current state, then send a command that fits it.",
"request_id": "req_01K9D9S2R03X0KZK1CC6CBYTYP"
}
}Skip one occurrence
For "not this week", without touching the rest.
curl -X POST 'https://rigel.house/api/v1/households/hh_01M6V9CS6GGVFCY7NAS8ZTQV95/commands/calendar.event.cancel_occurrence' \
-H "Cookie: rigel_session=$RIGEL_SESSION" \
-H 'Content-Type: application/json' \
-H 'Idempotency-Key: cmd_01M6V9CSK1B6FGS2RT090251T0' \
-d '{
"event_id": "evt_01M6V9CSHPG77MMGGKHAEJQ484",
"occurrence_start": "2026-11-24T17:00"
}'const response = await fetch("https://rigel.house/api/v1/households/hh_01M6V9CS6GGVFCY7NAS8ZTQV95/commands/calendar.event.cancel_occurrence", {
method: "POST",
headers: {
"Content-Type": "application/json",
"Idempotency-Key": "cmd_01M6V9CSK1B6FGS2RT090251T0",
Cookie: `rigel_session=${process.env.RIGEL_SESSION}`,
},
body: JSON.stringify({
event_id: "evt_01M6V9CSHPG77MMGGKHAEJQ484",
occurrence_start: "2026-11-24T17:00",
}),
});
const data = await response.json();POST /api/v1/households/hh_01M6V9CS6GGVFCY7NAS8ZTQV95/commands/calendar.event.cancel_occurrence HTTP/1.1
Host: rigel.house
Cookie: rigel_session=<your session>
Content-Type: application/json
Idempotency-Key: cmd_01M6V9CSK1B6FGS2RT090251T0
{
"event_id": "evt_01M6V9CSHPG77MMGGKHAEJQ484",
"occurrence_start": "2026-11-24T17:00"
}HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: req_01M6V9CSK2X313AZD1SPYJ1P9X
{
"result": {},
"version": 95
}For Rigel#
Rigel's tool for this command is calendar_event_cancel_occurrence. Rigel runs this on its own, then says what it did. The agent guide has the rest.