Add from collection
add_from_collectionAdd an item from the user's Collection into a project as a self-contained COPY. Pass the destination projectId, plus the sourceProjectId + elementId of an item from list_collection. Copies that layer (a whole group brings its children) plus its image/clip/font bytes into the destination at fresh ids and its original canvas position — fully detached, so it is immediately yours to edit and nothing links back to the source (deleting or changing the source never affects this copy). The element must actually be in the source project's collection and you must be able to read that project. An open editor on the destination picks the copy up within a few seconds — no refresh needed. Returns { addedElementId, count }.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"projectId": "<projectId>",
"sourceProjectId": "<sourceProjectId>",
"elementId": "<elementId>"
},
"name": "add_from_collection"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| elementId | Yes | The item's element id (from list_collection) — any leaf or group.<id>. | |
| projectId | Yes | Destination project the item is copied INTO. | |
| sourceProjectId | Yes | The item's home project id (from list_collection). |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ok | Yes | Whether the call succeeded. | |
| data | No | The payload, shaped by the tool. | |
| note | No | What to do next when not ready. | |
| error | No | Why it failed. | |
| status | No | For cache-backed readers: whether the answer was ready. | |
| editorUrl | No | Opens this project in the editor. |