feat(mail): mailforward write endpoints — add / update / delete#167
Merged
Conversation
First #13 write slice: add_mailforward / update_mailforward / delete_mailforward via `kasapi-cli mail forwards add|update|delete`. delete and update are gated by the #109 confirmation prompt (update_mailforward replaces the whole target list and is irreversible); add is reversible and not prompted. All three honour --dry-run (#132) and emit a #131 audit record, through the shared cli.runWriteE runner and the new non-gated cli.ResolveWrite counterpart of cli.ResolveDestructive — the first end-to-end exercise of the gate/audit/dry-run seam. Closes #115 Closes #109 Closes #131 Closes #132
This was referenced May 17, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
First #13 write slice —
add_mailforward/update_mailforward/delete_mailforward:kasapi-cli mail forwards add <addr> --target …,… update <addr> --target …,… delete <addr>.deleteandupdateare gated by the feat(cli): destructive-write confirmation infrastructure (--yes / interactive prompt) #109 confirmation prompt (update_mailforwardreplaces the whole target list and is irreversible);addis reversible and not prompted.--dry-run(feat(cli): --dry-run for write commands #132) and emit a feat(cli): structured write-action audit log #131 audit record.cli.runWriteErunner and the new non-gatedcli.ResolveWritecounterpart ofcli.ResolveDestructive— first end-to-end exercise of the gate/audit/dry-run seam.Commands live in
internal/cli/mail.go(theforwardstree already lives there), not a separateinternal/cli/mailforward.goas the issue text predated the consolidation.Closes #115
Closes #109
Closes #131
Closes #132