Quickly create a new Feishu cloud document.
How to Use
/feishu-create "文档标题"
Execution Flow
- Create an empty document
feishu-cli doc create --title "<title>" --output json
-
Add permission (required) After creationmust immediatelygrant
user@example.comthefull_accesspermission:feishu-cli perm add <document_id> --doc-type docx --member-type email --member-id user@example.com --perm full_access --notificationfull_access permission includes:
- Manage collaborators (add/remove members, set permissions)
- Edit document content (modify, delete, add)
- Manage document settings (copy, move, delete document)
- View historical versions
- Export document
-
Send notification (required) Use a Feishu message to notify the user that the document has been created:
feishu-cli msg send --receive-id-type email --receive-id user@example.com --text "文档已创建:https://feishu.cn/docx/<document_id>" -
Return result
- Document ID
- Document URL
Output Format
已创建文档!
文档 ID: <document_id>
文档链接: https://feishu.cn/docx/<document_id>
权限: 已添加 full_access 给 user@example.com
Optional Parameters
| Parameter | Description |
|---|---|
| --folder | Specify the parent folder Token |
Permission Requirements
docx:document- Document read/writedrive:permission:member:create- Add collaborators
Notes
Rules that must be followed:
- After creating the documentmust immediatelyadd the
full_accesspermission touser@example.com - Must send a Feishu message to notify the user that the operation is complete
- The return result must include the permission addition status
Example
# 创建简单文档
/feishu-create "项目计划"
# 创建带时间戳的文档
/feishu-create "会议纪要-$(date +%Y%m%d)"