topological_sort
Sort record IDs or entity types by dependency order, placing parents before children for reliable data migration.
Instructions
Sort a list of entity types / record IDs in dependency order (parents before children). Useful for relationship-aware migration — e.g. migrate Epics before Stories before Sub-tasks. Provide nodes (IDs) and edges ([parentId, childId] pairs). Returns the sorted order.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| nodes | Yes | List of record or type identifiers | |
| edges | Yes | Dependency edges: [parent, child] |