Skip to content

docs(mail): document user sender lists#1622

Open
infeng wants to merge 1 commit into
larksuite:mainfrom
infeng:feat/778f950
Open

docs(mail): document user sender lists#1622
infeng wants to merge 1 commit into
larksuite:mainfrom
infeng:feat/778f950

Conversation

@infeng

@infeng infeng commented Jun 26, 2026

Copy link
Copy Markdown
Collaborator

Adds mail CLI documentation for managing a user's sender allow and block lists.

  • Documents the new allow/block sender list operations in the mail skill guide.
  • Adds a focused reference page covering request shapes, response fields, and common workflows.
  • Updates the mail domain template so generated skill content includes the new sender list capabilities.

Summary by CodeRabbit

  • Documentation
    • Added guidance for managing user-level sender allow/block lists in mail workflows.
    • Clarified the difference between personal sender lists and tenant-level sender lists.
    • Included examples for listing, searching, adding, and removing senders from allow/block lists.
    • Updated the workflow to note when user confirmation is required before making changes.

@coderabbitai

coderabbitai Bot commented Jun 26, 2026

Copy link
Copy Markdown

Review Change Stack

📝 Walkthrough

Walkthrough

Docs add user-level sender allow/block list guidance to the mail skill templates and reference material, including core definitions, confirmation rules, workflow placement, and CLI examples for listing, adding, and removing entries.

Changes

User-level sender list docs

Layer / File(s) Summary
Concepts and confirmation
skill-template/domains/mail.md, skills/lark-mail/SKILL.md
Adds user-level sender allow/block list definitions and marks their create/remove writes as explicit-confirmation operations.
Workflow updates
skill-template/domains/mail.md, skills/lark-mail/SKILL.md
Adds a user-level sender list workflow step and shortcut reference, and renumbers later workflow items.
CLI reference
skill-template/domains/mail.md, skills/lark-mail/SKILL.md, skills/lark-mail/references/lark-mail-user-sender-lists.md
Adds dedicated examples for listing, batch-adding, and batch-removing user-scoped sender lists, plus scope and authorization notes.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~2 minutes

Possibly related PRs

  • larksuite/cli#749: Updates the same mail write-confirmation rules family, including explicit preview/confirmation behavior for write operations.

Suggested labels

documentation

Suggested reviewers

  • haidaodashushu
  • chanthuang

Poem

A bunny hopped through docs by moonlit glow,
With sender lists lined up in tidy row.
Whitelist, blacklist—hop, hop, hooray,
The CLI carrots guide the way. 🐇

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title is concise and accurately describes the main change: documenting user sender lists for mail.
Description check ✅ Passed It covers Summary and Changes clearly, though the template’s Test Plan and Related Issues sections are omitted.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@github-actions github-actions Bot added domain/mail PR touches the mail domain size/M Single-domain feat or fix with limited business impact labels Jun 26, 2026

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick comments (2)
skill-template/domains/mail.md (1)

492-512: 📐 Maintainability & Code Quality | 🔵 Trivial | 💤 Low value

Consider completing the example matrix for sender list operations.

The three examples cover an asymmetric mix: allow_senders list, blocked_senders batch_create, and allow_senders batch_remove. For clarity, consider showing a complete cycle for one resource (e.g., also include allow_senders batch_create) or symmetric pairs (e.g., also show blocked_senders batch_remove). This helps readers infer the pattern without guessing which resource supports which operation.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@skill-template/domains/mail.md` around lines 492 - 512, The sender list
examples are incomplete and asymmetrical, which makes the operation pattern hard
to infer. Update the examples under user_mailbox.allow_senders /
user_mailbox.blocked_senders to show a complete or symmetric set of CRUD-style
operations, such as adding the missing allow_senders batch_create example or
adding a blocked_senders batch_remove example. Keep the existing user_mailbox.*
symbols and align the examples so readers can see matching list/create/remove
usage for each resource.
skills/lark-mail/references/lark-mail-user-sender-lists.md (1)

29-62: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick win

Clarify the request shape asymmetry between batch_create and batch_remove.

batch_create uses --data '{"items":[{"sender":"...","sender_type":1}]}' while batch_remove uses --data '{"senders":["..."]}'. This is a significant shape difference (objects with sender_type vs plain strings). Consider adding a brief inline note explaining that batch_remove only requires the sender/ domain identifier because the list type is already implicit in the resource path, whereas batch_create must disambiguate email vs domain via sender_type.

This reduces user confusion and support burden.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@skills/lark-mail/references/lark-mail-user-sender-lists.md` around lines 29 -
62, Clarify the payload shape difference in the Lark Mail sender list examples
by adding a brief note near the `batch_create` and `batch_remove` sections in
`lark-mail-user-sender-lists.md`: `batch_create` on `user_mailbox.allow_senders`
and `user_mailbox.blocked_senders` needs `items` objects with `sender_type` to
distinguish email vs domain, while `batch_remove` only needs a `senders` array
of identifiers because the resource already implies the list type. Keep the
examples unchanged, but add the explanation where readers can see both
`batch_create` and `batch_remove` usage together.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Nitpick comments:
In `@skill-template/domains/mail.md`:
- Around line 492-512: The sender list examples are incomplete and asymmetrical,
which makes the operation pattern hard to infer. Update the examples under
user_mailbox.allow_senders / user_mailbox.blocked_senders to show a complete or
symmetric set of CRUD-style operations, such as adding the missing allow_senders
batch_create example or adding a blocked_senders batch_remove example. Keep the
existing user_mailbox.* symbols and align the examples so readers can see
matching list/create/remove usage for each resource.

In `@skills/lark-mail/references/lark-mail-user-sender-lists.md`:
- Around line 29-62: Clarify the payload shape difference in the Lark Mail
sender list examples by adding a brief note near the `batch_create` and
`batch_remove` sections in `lark-mail-user-sender-lists.md`: `batch_create` on
`user_mailbox.allow_senders` and `user_mailbox.blocked_senders` needs `items`
objects with `sender_type` to distinguish email vs domain, while `batch_remove`
only needs a `senders` array of identifiers because the resource already implies
the list type. Keep the examples unchanged, but add the explanation where
readers can see both `batch_create` and `batch_remove` usage together.

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: b82878eb-f6ee-4a59-b562-60b2c0fa54ce

📥 Commits

Reviewing files that changed from the base of the PR and between 8a268aa and c4067ab.

📒 Files selected for processing (3)
  • skill-template/domains/mail.md
  • skills/lark-mail/SKILL.md
  • skills/lark-mail/references/lark-mail-user-sender-lists.md

@github-actions

github-actions Bot commented Jun 26, 2026

Copy link
Copy Markdown

PR Quality Summary

CI did not complete successfully. Use the failed check links below to decide whether this PR needs a code change or a rerun.

Failed checks

  • deterministic-gate — failure — details
  • results — failure — details

deterministic-gate

  • skill_command_referenceskills/lark-mail/SKILL.md:276 — example references unknown command "mail user_mailbox.allow_senders list" — Action: update the example to use a command present in the command manifest
  • skill_command_referenceskills/lark-mail/SKILL.md:280 — example references unknown command "mail user_mailbox.blocked_senders batch_create" — Action: update the example to use a command present in the command manifest
  • skill_command_referenceskills/lark-mail/SKILL.md:285 — example references unknown command "mail user_mailbox.allow_senders batch_remove" — Action: update the example to use a command present in the command manifest
  • skill_command_referenceskills/lark-mail/references/lark-mail-user-sender-lists.md:19 — example references unknown command "mail user_mailbox.allow_senders list" — Action: update the example to use a command present in the command manifest
  • skill_command_referenceskills/lark-mail/references/lark-mail-user-sender-lists.md:23 — example references unknown command "mail user_mailbox.blocked_senders list" — Action: update the example to use a command present in the command manifest
  • skill_command_referenceskills/lark-mail/references/lark-mail-user-sender-lists.md:33 — example references unknown command "mail user_mailbox.allow_senders batch_create" — Action: update the example to use a command present in the command manifest
  • skill_command_referenceskills/lark-mail/references/lark-mail-user-sender-lists.md:38 — example references unknown command "mail user_mailbox.blocked_senders batch_create" — Action: update the example to use a command present in the command manifest
  • skill_command_referenceskills/lark-mail/references/lark-mail-user-sender-lists.md:54 — example references unknown command "mail user_mailbox.allow_senders batch_remove" — Action: update the example to use a command present in the command manifest
  • skill_command_referenceskills/lark-mail/references/lark-mail-user-sender-lists.md:59 — example references unknown command "mail user_mailbox.blocked_senders batch_remove" — Action: update the example to use a command present in the command manifest

@github-actions

Copy link
Copy Markdown

🚀 PR Preview Install Guide

🧰 CLI update

npm i -g https://pkg.pr.new/larksuite/cli/@larksuite/cli@c4067ab16ef28ac52069b10b771c54b32df7c11f

🧩 Skill update

npx skills add infeng/cli#feat/778f950 -y -g

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

domain/mail PR touches the mail domain size/M Single-domain feat or fix with limited business impact

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant