talonic_sources_sync_settings
Read, or change, how a connected source stays in sync. Without interval and scope it only reads the current settings. With interval (off, every_minute, hourly, daily, weekly) and/or scope (which folders, labels, pages or prefixes are watched: an object with type = the connection's kind and entries; read the current settings first and change that shape) it changes them, and only for the connection's author or a workspace owner. A schedule other than off needs at least one scope entry. Call the change only when the user asked for it. NOT FOR syncing once now: talonic_sources_sync_now.
Availability
Listed when the session can read the workspace's sources (sources:read on a connector session); connecting, importing and sync settings need sources:write. Being listed only means the tool is visible: Talonic checks your role again on every call.
Behaviour and cost
- Not read-only. It can add to or change workspace data.
Parameters
| Parameter | Type | Description |
|---|---|---|
| connection_id * | string | The connection id from talonic_sources_connections |
| interval | "off" | "every_minute" | "hourly" | "daily" | "weekly" | New schedule; omit to keep it |
| scope | object | What is watched: { type, entries }; omit to keep it |
Example
// talonic_sources_sync_settings({ "connection_id": "1111…", "interval": "daily" })
{ "interval": "daily", "scope": { "type": "google_drive", "entries": [{ "kind": "folder", "folderId": "f_1", "name": "Invoices" }] } }Errors
A failed call comes back as a tool error with the HTTP status and a message that says what to change. Troubleshooting lists the common ones.