---
title: "Flatten JSON (x402)"
method: GET
path: "/x402/v2/flatten-json"
tags: ["x402"]
---

# Flatten JSON (x402)

`GET /x402/v2/flatten-json`

## Request

- Base URL: `https://api.strale.io`
- URL: `https://api.strale.io/x402/v2/flatten-json`
- Auth: none required

Flatten nested JSON to dot-notation keys. E.g. {a:{b:[1,2]}} → {'a.b.0':1,'a.b.1':2}. Configurable delimiter and array handling. Algorithmic.

## Query parameters

- `data` unknown, required
- `delimiter` string: Default '.'
- `array_handling` string: 'index' or 'stringify'

## Response `200`

Success

- object
  - `flattened` object
  - `key_count` integer
  - `max_depth_found` integer

## Other responses

- `402`: Payment required (x402 — pay with USDC on Base)

---

[API](https://skmtc.dev/strale/apis/strale-api-2.md) · [All operations](https://skmtc.dev/strale/apis/strale-api-2/llms.txt) · [OpenAPI document](https://skmtc.dev/strale/apis/strale-api-2/revisions/a5293878cfc6?raw)
