Enhancement: set wiki node position among siblings on move/create
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 43/100
Research direction
Start with the wiki +move and wiki +node-create command definitions and the SDK's service/wiki/v2 request types, including MoveSpaceNodeReqBody. Check whether the upstream Lark Open API now supports a sibling-position field; the matching larksuite/oapi-sdk-go request may determine when this work can begin. Done means the supported ordering option is exposed by both commands and behaves as documented for move and create.
Written by the indexing model from the issue text.
Description
Summary
Please let wiki +move and wiki +node-create say where a node should go among its siblings, not just which parent it goes under.
Current behaviour
lark-cli wiki +move (v1.0.98) accepts --node-token, --target-parent-token, --target-space-id, --source-space-id, --obj-type / --obj-token and --apply. +node-create likewise only takes a parent. Lark decides where the node lands among its siblings, and the order can only be changed by dragging the node in the web UI.
This is a gap in the Open API rather than in the CLI: POST /open-apis/wiki/v2/spaces/:space_id/nodes/:node_token/move only accepts target_parent_token and target_space_id, and node create has no position field. So this request is really for the API, with CLI flags to follow. I filed a matching request on larksuite/oapi-sdk-go.
Proposed enhancement
Any one of these would solve it:
- An optional
prev_node_token(orbefore/aftersibling token) on the move and create endpoints, exposed as e.g.--after-node-token/--before-node-token. - A writable
sort_idon move and create, exposed as--sort-id. - A dedicated reorder endpoint that moves a node among its current siblings without changing its parent, e.g.
lark-cli wiki +node-reorder --node-token X --after-node-token Y.
Why
The wiki is a natural target for automated publishing: release notes, changelogs, runbooks and generated reports written by CI or by agents through lark-cli. Those trees have a meaningful order, such as newest release first or chapters in sequence. Today every automated publish lands in a position the publisher can't control, so a person has to open the wiki and drag the node into place after each run. That makes a fully automated pipeline impossible and lets the tree drift out of order whenever someone forgets.
The workarounds aren't good. One parent folder per item fragments the tree. Prefixing titles with dates or versions changes the titles readers see and still doesn't control the displayed order. A hand-kept index page duplicates the tree it's meant to describe.
Lark's own UI already supports placing a node anywhere among its siblings, so this would bring the API and CLI up to what the product can already do.
Environment
- lark-cli 1.0.98
- Also checked:
github.com/larksuite/oapi-sdk-go/v3v3.12.2,service/wiki/v2MoveSpaceNodeReqBody
- Dominant language
- Go
- Stars
- 18.2k
- Forks
- 1.4k
- Avg merge
- 1d 3h
- Merged PRs (30d)
- 18
Getting set up
- No Dockerfile or Docker Compose file
- Has a pull request template
- No contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from larksuite/cli
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 66/100
Maintainers usually reply within 1 day
-
domain/im
Difficulty 2/5 1-3 hours Newbie friendliness 85/100
Maintainers usually reply within 1 day
-
bug domain/doc
Difficulty 1/5 Under an hour Newbie friendliness 77/100
Maintainers usually reply within 1 day
-
mail: all-ASCII draft bodies are hard-wrapped every 998 bytes, inserting newlines inside words and tagsPossibly taken @linye157 claimed this 26 days ago. Opendomain/mail
Difficulty 2/5 1-3 hours Newbie friendliness 80/100
Maintainers usually reply within 1 day
-
auth: a 429 from the Token Endpoint during refresh deletes a still-valid loginPossibly taken @linye157 claimed this 26 days ago. Openbug domain/auth domain/im
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
larksuite/cli#2869 · 5 comments ·
Maintainers usually reply within 1 day
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
github/github-mcp-server#3960 ·
Maintainers usually reply within 3 days
-
Difficulty 1/5 Under an hour Newbie friendliness 78/100
JuliusBrussee/caveman#1594 ·
Maintainers usually reply within 1 day
-
C-bug O-community X-blathers-triaged
Difficulty 2/5 1-3 hours Newbie friendliness 66/100
cockroachdb/cockroach#176264 · 1 comment ·
-
security trivy
Difficulty 2/5 1-3 hours Newbie friendliness 67/100
kubefleet-dev/kubefleet#1068 ·
Maintainers usually reply within 3 days