Developers
Start building
AI/Tool reference/Channels/Swap tables

Swap tables

The 6 tools of the Swap tables toolset in the Channels area, with their permissions, approval rules and inputs.

On this page

Toolset feed_lookups, 6 tools.

Records

feed_lookup

A table that swaps a store value for the value a site wants (e.g. category names, colour names), used by feed rules. List shows each table with its source, row count, last refresh, last error and the rules that read it; get adds its rows and updated_at for a change.

  • Permission: feeds.read
  • Tools: feed_lookup_list, feed_lookup_get

Actions

feed_lookup_create

Create a swap table from rows the merchant gave or a shared Google Sheet link.

Checked as the table editor checks it (up to 20000 rows). Needs swap tables in the plan.

  • Action key: feed_lookup.create
  • Permission: feeds.write
  • Approval: Always waits for a person to approve it.
  • Effect: Changes the live store.
  • Retries: runs at most once; a repeat with the same idempotency key returns the first result.
FieldTypeRequiredDescription
namestringyes1 to 120 characters
contentobject, one shape of:yesWhere the rows come from: typed in, a CSV text, or a shared Google Sheet link
content[source=inline].sourcestringyesalways "inline"
content[source=inline].rowslist of objectyesat most 20000 items
content[source=inline].rows[].keystringyesThe store value. at most 500 characters
content[source=inline].rows[].valuestringyesThe site's value. at most 2000 characters
content[source=csv].sourcestringyesalways "csv"
content[source=csv].csvstringyesat most 2097152 characters
content[source=sheet].sourcestringyesalways "sheet"
content[source=sheet].urlstringyesA shared Google Sheet link the merchant gave. 1 to 2000 characters

Example inputs:

{
  "name": "Colours",
  "content": {
    "source": "inline",
    "rows": [
      {
        "key": "Piros",
        "value": "Red"
      }
    ]
  }
}
{
  "name": "Sizes",
  "content": {
    "source": "sheet",
    "url": "https://docs.google.com/spreadsheets/d/abc/edit"
  }
}

feed_lookup_delete

Delete a swap table; refused while a rule still reads it.

  • Action key: feed_lookup.delete
  • Permission: feeds.write
  • Approval: Always waits for a person to approve it.
  • Effect: Changes the live store.
  • Destructive: in compact mode it runs with run_destructive_action.
  • Retries: safe to repeat with the same input.
FieldTypeRequiredDescription
lookup_idstringyesSwap table ID. 1 to 64 characters

Example input:

{
  "lookup_id": "019bb2a5-91bc-7241-8a8d-06e8c0daaa94"
}

feed_lookup_refresh

Read a sheet-backed swap table from its Google Sheet again.

  • Action key: feed_lookup.refresh
  • Permission: feeds.write
  • Approval: Runs without approval.
  • Effect: Changes the live store.
  • Retries: safe to repeat with the same input.
FieldTypeRequiredDescription
lookup_idstringyesSwap table ID. 1 to 64 characters

Example input:

{
  "lookup_id": "019bb2a5-91bc-7241-8a8d-06e8c0daaa94"
}

feed_lookup_update

Rename a swap table, replace its rows, or both.

Send the updated_at read with feed_lookup_get as expected_updated_at: a table changed meanwhile refuses the change. A rename is written into every rule that reads the table. Needs swap tables in the plan.

  • Action key: feed_lookup.update
  • Permission: feeds.write
  • Approval: Always waits for a person to approve it.
  • Effect: Changes the live store.
  • Retries: safe to repeat with the same input.
FieldTypeRequiredDescription
lookup_idstringyesSwap table ID. 1 to 64 characters
expected_updated_atstringyesupdated_at as read. format date-time
namestring1 to 120 characters
contentobject, one shape of:Where the rows come from: typed in, a CSV text, or a shared Google Sheet link
content[source=inline].sourcestringyesalways "inline"
content[source=inline].rowslist of objectyesat most 20000 items
content[source=inline].rows[].keystringyesThe store value. at most 500 characters
content[source=inline].rows[].valuestringyesThe site's value. at most 2000 characters
content[source=csv].sourcestringyesalways "csv"
content[source=csv].csvstringyesat most 2097152 characters
content[source=sheet].sourcestringyesalways "sheet"
content[source=sheet].urlstringyesA shared Google Sheet link the merchant gave. 1 to 2000 characters
languagestringLanguage of the note on the rules a rename rewrites; en by default. one of "en", "hu"

Example input:

{
  "lookup_id": "019bb2a5-91bc-7241-8a8d-06e8c0daaa94",
  "expected_updated_at": "2026-10-01T10:00:00Z",
  "name": "Colour names"
}
Last updated