Airtable response missing "Record id" field

Describe the problem/error/question

n8n is incorrectly managing/merging the fields from the base.

Example-

  1. Table 1 (should work but is not working)
    https://airtable.com/appcMcvlwHqRsxxEX/shriNVUGEPSWiNqUa

  2. Table 2 (modified version of Table 1, which is what is working apparently)
    Airtable - Grid view

Please share your workflow

Share the output returned by the last node

  1. Output of Table 1 →

  2. Output of Table 2 →

The id field is incorrectly merged in the first (actual) scenario, which leads to the data (and thus the Airtable node) becoming unusable (without extra workarounds).

Information on your n8n setup

  • n8n version: 1.21.0
  • Database (default: SQLite): Postgres
  • n8n EXECUTIONS_PROCESS setting (default: own, main): main
  • Running n8n via (Docker, npm, n8n cloud, desktop app): Docker
  • Operating system: Windows

Hey @shrey-42,

That makes sense as typically when using JSON you shouldn’t have duplicate key names which fits the RFC

What I don’t know though is if we merge this or if Airtable only returns the one field either way having 2 ID keys would lead to invalid json and would make it hard to work with.

Do you have a possible solution in mind that could work?

The Airtable API provides correct response.
Also, the Airtable node used to provide the response correctly, until some time ago.

Example:

Hey @shrey-42,

That is handy so the change we made in the overhaul was to not include the fields object and we flatten it instead which is causing only one id field to be returned to provide valid json.

We might need to add a simplify option and have it enabled by default so the raw response can be used instead.

1 Like

NODE-1001 is the internal dev ticket to look at changing this.

1 Like

Shall wait for that.