From cf164be8f7e1e65a933d7074b5d43100340a8277 Mon Sep 17 00:00:00 2001 From: ysyneu Date: Mon, 14 Sep 2026 02:46:14 -0700 Subject: [PATCH 1/7] feat(member): add member notify command --- go.mod | 2 +- go.sum | 4 +- internal/cli/zz_generated_manifest.go | 1 + internal/cli/zz_generated_members.go | 63 ++++++++++++++++++++++ internal/cli/zz_generated_response_help.go | 1 + skills/flashduty/reference/member.md | 14 +++++ 6 files changed, 82 insertions(+), 3 deletions(-) diff --git a/go.mod b/go.mod index f7edce6..ab750ab 100644 --- a/go.mod +++ b/go.mod @@ -3,7 +3,7 @@ module github.com/flashcatcloud/flashduty-cli go 1.25.1 require ( - github.com/flashcatcloud/go-flashduty v0.15.3-0.20260914093700-c688445d02c3 + github.com/flashcatcloud/go-flashduty v0.15.3-0.20260914093721-fce7fad70984 github.com/mattn/go-runewidth v0.0.29 github.com/spf13/cobra v1.10.2 github.com/spf13/pflag v1.0.10 diff --git a/go.sum b/go.sum index 1d29788..db458c7 100644 --- a/go.sum +++ b/go.sum @@ -1,8 +1,8 @@ github.com/clipperhouse/uax29/v2 v2.2.0 h1:ChwIKnQN3kcZteTXMgb1wztSgaU+ZemkgWdohwgs8tY= github.com/clipperhouse/uax29/v2 v2.2.0/go.mod h1:EFJ2TJMRUaplDxHKj1qAEhCtQPW2tJSwu5BF98AuoVM= github.com/cpuguy83/go-md2man/v2 v2.0.6/go.mod h1:oOW0eioCTA6cOiMLiUPZOpcVxMig6NIQQ7OS05n1F4g= -github.com/flashcatcloud/go-flashduty v0.15.3-0.20260914093700-c688445d02c3 h1:Fq3FELZmnEzyeAsHBV9o3pfhjMONonhHFdecRFqw0m8= -github.com/flashcatcloud/go-flashduty v0.15.3-0.20260914093700-c688445d02c3/go.mod h1:YpHiTYXR5NXBI/rGRZfUy537XMkhdCkwA8NW1QoRHwk= +github.com/flashcatcloud/go-flashduty v0.15.3-0.20260914093721-fce7fad70984 h1:EGTGeKUR1Z3QsnJdm/ny7/cp1zI9ea2sXf2f1gXCAhI= +github.com/flashcatcloud/go-flashduty v0.15.3-0.20260914093721-fce7fad70984/go.mod h1:YpHiTYXR5NXBI/rGRZfUy537XMkhdCkwA8NW1QoRHwk= github.com/inconshreveable/mousetrap v1.1.0 h1:wN+x4NVGpMsO7ErUn/mUI3vEoE6Jt13X2s0bqwp9tc8= github.com/inconshreveable/mousetrap v1.1.0/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLfsEA9PFc4w1p2J65bw= github.com/mattn/go-runewidth v0.0.29 h1:3oGF3R/S2N9DQ3ptftzVIvg2eicmojCzlwBEmqEPDfQ= diff --git a/internal/cli/zz_generated_manifest.go b/internal/cli/zz_generated_manifest.go index 5ca9441..a4d53e9 100644 --- a/internal/cli/zz_generated_manifest.go +++ b/internal/cli/zz_generated_manifest.go @@ -181,6 +181,7 @@ var generatedOpIDs = []string{ "memberInfo", "memberInvite", "memberList", + "memberNotify", "memberResetInfo", "memberRevokeRole", "memberUpdateRole", diff --git a/internal/cli/zz_generated_members.go b/internal/cli/zz_generated_members.go index 5724112..ac61fdf 100644 --- a/internal/cli/zz_generated_members.go +++ b/internal/cli/zz_generated_members.go @@ -374,6 +374,68 @@ Response fields ('data' envelope is unwrapped — rows are nested under items[]; return cmd } +func genMembersMemberNotifyCmd() *cobra.Command { + var dataJSON string + var fHTML string + var fPersonIDs []int + var fSubject string + cmd := &cobra.Command{ + Use: "notify", + Short: "Notify members", + Long: `Notify members. + +Send an email to account members on behalf of the caller, with content the caller supplies. Only callable with a credential minted for an AI SRE session; any other credential is rejected with 'AccessDenied'. Delivery is asynchronous — 'accepted' means the email was queued, not that it was delivered. + +API: POST /member/notify (memberNotify) + +Request fields: + --html string (required) — Email body as an HTML fragment (no ''/''/'' wrapper needed). Required, up to 512,000 bytes of raw UTF-8 input, and must be non-empty after sanitization. Sanitized server-side: '