Extract Field
Pull one field or a nested path, such as title or authorMeta.name, out of JSON data, and send it on as text, as a list to run once per item, or as JSON.
The Extract Field node pulls one field, or a nested path of fields, out of JSON data. Choose the field from the fields detected in the upstream data, or type a dot path such as authorMeta.name. The node sends the result as one text, as a list that can run the next node once per value, or as raw JSON. It runs instantly and costs no credits.
When to use it
- Pull the
titleorurlof every search result out of Web Scrape before a batch. - Take a nested value, such as the author's name inside each scraped post.
- Turn a JSON array into a list of texts for a Prompt node.
- Reach deeply nested data by chaining two Extract Field nodes.
Quick start
Add the node
Press Tab on the canvas and choose Automate › Logic & Data › Extract Field.
Connect JSON data
Wire a node that sends JSON into the Source input, for example Web Scrape or a Prompt node that answers in JSON.
Choose the field
Open the settings panel. Once the upstream node has a result, Field lists the fields it found. Choose one, or choose Custom path… and type a dot path.
Choose the output type and run
Set Output Type to Text, List or JSON, and run the node. Output Preview shows the result.
Inputs and outputs
| Input or output | Accepts or sends | What it does |
|---|---|---|
| Source | JSON, text that contains JSON, or a list | The data to read. |
| Text or JSON | Text, a list or JSON | The extracted values, in the format chosen under Output Type. The output is labeled JSON when the output type is JSON. |
Settings
| Setting | What it does |
|---|---|
| Field | The field to extract. Detected fields appear once an upstream node is connected and has data. (whole item) uses each element of an array as it is. Custom path… switches to a typed Path. |
| Path | A dot path such as caption or authorMeta.name. When the data is an array, the path runs against each element. Leave it empty to use each element as it is. ← Back to field list returns to the detected fields. |
| Output Type | Text, the default, joins the values into one text, one value per line. List sends each value as a separate item, which works with the Item and Each connection modes. JSON sends the raw value, to chain another Extract Field or a node that reads JSON. |
Keep two fields paired
To use two fields of the same array together, for example prompt and negative from a list of concepts:
- Add one Extract Field per field, both with Output Type set to List.
- Wire each one into its own input of the next node, with both connections set to Each. You can also wire them into two columns of a List.
The two lists pair up by array element: run 3 gets the prompt and the negative of element 3. An element without a negative gives that run no negative, and the runs after it do not shift. A run never starts for an element that has no value at all. A field that only some elements have, such as a video link, therefore runs once per value that exists.
Picking by position counts only the values that exist. Item N, ranges and Bundle count existing values, and the Text output lists the existing values, one per line.
When the JSON comes from an AI model
When a Prompt node writes the JSON, ask it to return raw JSON only, without a code fence and without a sentence before or after it. Otherwise, Extract Field fails with the error "Input is not valid JSON".
Credits
Extract Field is free.
Tips
- Connect first, then choose. The Field list fills from the upstream data, so you do not need to remember key names.
- Flat lists. When the JSON is already a flat list, such as
["a", "b", "c"], leave Field on (whole item) and set Output Type to List. - Nested objects. Use dot notation in Path, such as
videoMeta.duration. - Arrays in the middle of a path. Chain two nodes. The first extracts
itemswith Output Type set to JSON; the second extractstitlefrom each item. - Filter first. To keep only some items before you extract, use Filter List.
Frequently asked questions
Related
Web Scrape
Filter List
List
Prompt
Lists and batching
Last updated on
Router
Send a workflow down one or more named routes. Choose the route yourself, turn several on at once, or let conditions on the incoming data decide.
QA Check
Score a text from 0 to 1 with an AI model for content, quality, consistency or safety, and get an approved or rejected decision with a short reason.