Skip to content

feat(sequences): sequence CRUD and sequence email management - #15

Merged
imjohnbo merged 1 commit into
catchup/01-clientfrom
catchup/02-sequences
Aug 20, 2026
Merged

feat(sequences): sequence CRUD and sequence email management#15
imjohnbo merged 1 commit into
catchup/01-clientfrom
catchup/02-sequences

Conversation

@imjohnbo

@imjohnbo imjohnbo commented Aug 20, 2026

Copy link
Copy Markdown
Owner

Part 2 of 8. Base: #14.

What this adds

Sequence CRUD:

kit sequences get <id>
kit sequences create --name <name> [...]
kit sequences update <id> [...]
kit sequences delete <id>

Sequence emails, nested under sequences:

kit sequences emails list <sequenceId>
kit sequences emails get <sequenceId> <id>
kit sequences emails create <sequenceId> --subject <s> --delay-value <n> --delay-unit <days|hours>
kit sequences emails update <sequenceId> <id> [...]
kit sequences emails delete <sequenceId> <id>

list and get accept --include stats. emails list also accepts --include-content.

Design notes

The update commands send only the fields that the user names. An update therefore never wipes a field by accident. The tests cover this.

The CLI validates send days, send hour, delay unit, and ID lists before it sends the request. A bad value reads as a CLI error instead of a 422.

validateNumericId rejects zero. Send hour and email position both allow zero. This branch adds validateIntInRange and validateEnum to the client for those cases.

Review notes

Tests: 147 before, 198 after. The 51 new tests assert the exact request for every new command.

Closes #6
Part of #4
Part of #7


The stack

Merge from the top down. Each part builds on the one above it.

PR Contents
1 #14 Client query support and shared helpers
2 #15 (this one) Sequence CRUD and sequence emails
3 #16 Posts and snippets
4 #17 Broadcast filters, account-wide stats, link clicks
5 #18 Subscriber slim listing, warnings, filter
6 #19 Tag rename, remove-by-email, bulk delete
7 #20 Account endpoints and purchase create
8 #21 Spec coverage map and its tests

Base branch: main for part 1, the previous part's branch for the rest.
GitHub retargets each base to main as the part below it merges.

Closes the gap the spec-change issues flagged for sequences.

Sequence CRUD (issue #4):
  kit sequences get <id>
  kit sequences create --name <name> [...]
  kit sequences update <id> [...]
  kit sequences delete <id>

Sequence emails (issue #6), nested under sequences:
  kit sequences emails list <sequenceId>
  kit sequences emails get <sequenceId> <id>
  kit sequences emails create <sequenceId> --subject --delay-value --delay-unit
  kit sequences emails update <sequenceId> <id> [...]
  kit sequences emails delete <sequenceId> <id>

Both list and get accept --include stats, which the spec added alongside the
description changes in issue #7. Sequence email list also accepts
--include-content.

Update commands send only the fields the user names, so an update never wipes a
field by accident. Send days, send hour, delay unit, and ID lists are validated
before the request goes out.

Adds validateIntInRange and validateEnum to the client. validateNumericId
rejects zero, which send hour and position both allow.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Kit API spec update: 5 added

1 participant