# Format JSON

## How does the JSON Step work?

The JSON Step allows you to structure the output of your workflow into a standardized JSON format. This is done by selecting the keys and values of the different steps you want to expose in the output.

## How to Configure a JSON Step

The JSON Step is fairly intuitive. Given that you're formatting the output of a previous step, it will typically flow directly into your End step.

You can name the "key" and "value" to whatever you choose, and you can choose to populate them with the input of prior steps:

{% @arcade/embed url="<https://app.arcade.software/share/BtyQUAfSJf5dzhIWUVIR>" flowId="BtyQUAfSJf5dzhIWUVIR" %}

Clicking the **"Add Variable +"** button will let you define additional fields within your JSON output.

## Example

Let's walk through a quick example of using a JSON Step to achieve our desired output in a JSON format.

Our workflow takes a simple string input (city name), and utilizes an LLM Step to generate a quick historic description of the city. We'll insert our JSON Step after this, formatting our output as:

```
{
  "city_name": "Los Angeles",
  "description": "The full description of the city."
}
```

{% @arcade/embed url="<https://app.arcade.software/share/2XKC3NgLFXFs5zJYKZNJ>" flowId="2XKC3NgLFXFs5zJYKZNJ" %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.airops.com/actions/workflow-concepts/workflow-steps/logic-steps/json.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
