Skip to main content

jsonflattifier

Converts a JSON Document with nested objects and their parameters to the JSON Document with Flat Denormalised Data.

Installation

> pip install jsonflattifier

Input

{
  "name": "John",
  "has": [
    "apple",
    "peach"
  ]
}

Get flat JSON

> python3 -m jsonflattifier flattify '{"name":"John","has":["apple","peach"]}' --json --jsonpath-keys --no-table
[
  {
    "$['name']": "John",
    "$['has'][0]": "apple"
  },
  {
    "$['name']": "John",
    "$['has'][1]": "peach"
  }
]

Get CSV

> python3 -m jsonflattifier flattify '{"name":"John","has":["apple","peach"]}' --csv --no-table
['name'],['has']
John,apple
John,peach

Print Table

> python3 -m jsonflattifier flattify '{"name":"John","has":["apple","peach"]}'
['name'] ['has']
John apple
John peach

2 rows in set

More Examples

https://gitlab.com/v.grigoryevskiy/json-flattifier/-/tree/master/tests/data

Metadata

Release files for jsonflattifier 1.1.6

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for jsonflattifier 1.1.6
File Size Uploaded
jsonflattifier-1.1.6.tar.gz 5.2 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for jsonflattifier 1.1.6
File Interpreter ABI Platform
jsonflattifier-1.1.6-py3-none-any.whl Python 3 none any Details

Total release size: 12.8 kB

Release files / jsonflattifier-1.1.6.tar.gz

Download URL jsonflattifier-1.1.6.tar.gz
Size 5.2 kB
Tags Source
SHA-256 checksum
How to use checksums
ccfd9f3641a10ed19c7fcffcd71dbfc88df2c1e17afbc611a12e704adaad671f
BLAKE2b-256 checksum
How to use checksums
a105d899b135d351669912ad22b6b9a778ce6683d985e0adea7f96f4fba9fcba
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/49.2.0 requests-toolbelt/0.9.1 tqdm/4.47.0 CPython/3.7.3

Release files / jsonflattifier-1.1.6-py3-none-any.whl

Download URL jsonflattifier-1.1.6-py3-none-any.whl
Size 7.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
0b86eb623311975f75882998e2a7cecf8e4a19c75ec88fc99d5d535867ea2393
BLAKE2b-256 checksum
How to use checksums
9fba80ad7a4658d33888ed9b37dd1ee6ba217980e81d02bf532d160048798f01
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/49.2.0 requests-toolbelt/0.9.1 tqdm/4.47.0 CPython/3.7.3

Release history Release notifications | RSS feed

This release

1.1.6 This release

2 release files

1.1.5

2 release files

1.1.4

2 release files

1.1.3

1 release file

1.1.2

1 release file

1.1.1

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page