Bug Description
contact +get-user and contact +search-user shortcuts do not return the email field, even when the contact:user.email:readonly scope has been granted. However, calling the raw API directly via lark-cli api does return the email field correctly.
Steps to Reproduce
-
Grant the contact:user.email:readonly scope:
lark-cli auth login --scope "contact:user.email:readonly"
-
Use +get-user shortcut — email missing:
lark-cli contact +get-user --user-id "ou_xxxx"
Response only contains name, user_id, i18n_name — no email field.
-
Use +search-user shortcut — email missing:
lark-cli contact +search-user --query "张三" --format json
Response contains name, open_id, department_ids, avatar — no email field.
-
Call raw API directly — email present ✅:
lark-cli api GET "/open-apis/contact/v3/users/ou_xxxx?user_id_type=open_id"
Response correctly includes "email": "xxx@company.com".
Expected Behavior
When contact:user.email:readonly scope is granted, both +get-user and +search-user should include the email (and enterprise_email) field in their output, consistent with the raw API response.
Environment
- lark-cli version: 1.0.13
- OS: macOS (Darwin, arm64)
Workaround
Use lark-cli api GET to call the raw contact API directly, or use lark-cli mail multi_entity search which does return the email field.
Bug Description
contact +get-userandcontact +search-usershortcuts do not return theemailfield, even when thecontact:user.email:readonlyscope has been granted. However, calling the raw API directly vialark-cli apidoes return the email field correctly.Steps to Reproduce
Grant the
contact:user.email:readonlyscope:lark-cli auth login --scope "contact:user.email:readonly"Use
+get-usershortcut — email missing:lark-cli contact +get-user --user-id "ou_xxxx"Response only contains
name,user_id,i18n_name— noemailfield.Use
+search-usershortcut — email missing:lark-cli contact +search-user --query "张三" --format jsonResponse contains
name,open_id,department_ids,avatar— noemailfield.Call raw API directly — email present ✅:
lark-cli api GET "/open-apis/contact/v3/users/ou_xxxx?user_id_type=open_id"Response correctly includes
"email": "xxx@company.com".Expected Behavior
When
contact:user.email:readonlyscope is granted, both+get-userand+search-usershould include theemail(andenterprise_email) field in their output, consistent with the raw API response.Environment
Workaround
Use
lark-cli api GETto call the raw contact API directly, or uselark-cli mail multi_entity searchwhich does return the email field.