Requested enhancements to the curent workflowy APIs
- Proposed: let create and move accept a position as well as top and bottom.
POST /nodes { "parent_id": "...", "name": "...", "position": { "after": "<item id>" } }
POST /nodes/{id}/move { "parent_id": "...", "position": { "before": "<item id>" } }
POST /nodes/{id}/move { "parent_id": "...", "position": { "index": 3 } }
- Proposed: a depth option on the children read.
GET /nodes?parent_id=...&depth=4
- Proposed: one call that applies a list of operations in order, counted as one request for rate limiting, with an option to apply all or none.
POST /batch { "atomic": true, "ops": [
{ "op": "create", "parent_id": "...", "name": "...", "position": { "after": "..." }, "children": [ ... ] },
{ "op": "update", "id": "...", "name": "..." },
{ "op": "move", "id": "...", "parent_id": "...", "position": { "index": 0 } } ] }
-
Proposed: a collapsed field on node reads, settable on update.
-
Proposed: two calls, atomic so a failure cannot leave half a line.
POST /nodes/{id}/split { "offset": 12 } // new item after, with the text from offset POST /nodes/{id}/merge { "into": "<previous id>" } // appends text and children, removes this item -
Proposed: a changes read with a cursor, or a webhook for item created, updated, moved, completed and deleted.
GET /changes?since=<cursor> -> { "cursor": "...", "changes": [ { "id": "...", "type": "updated" } ] } -
Proposed: delete moves the item to trash, with a restore call and a trash read, and a separate permanent delete.
DELETE /nodes/{id} // to trash POST /nodes/{id}/restore // back to its old place DELETE /nodes/{id}?permanent=true -
Proposed: publish the limits and send remaining-request and reset headers on every response, in addition to retry_after on a 429.
