Skip to main content

Get Json path from a nested json document. specify notation dot or bracket

Project description

JSONPathGenerator

Python project to generate Json path in notations dot or bracket.

funtion to convert a nested json to nested dictionary enumerating the lists to child dictionaries

INSTALLATION

pip install jsonpathgenerator

USAGE

from jsonpathgenerator import jsonpath

js = jsonpath()

js.get_json_path(json-line,notation='dot')

notation = "dot"

notation = "bracket"

Usage Examples

js = jsonpath()

with open('sample_json.json','r') as file:
    json_line=json.load(file)
    json_path_list=js.get_json_path(json_line,notation="bracket")
    print(json_path_list)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

jsonpathgenerator-0.0.2.tar.gz (15.1 kB view hashes)

Uploaded Source

Built Distribution

jsonpathgenerator-0.0.2-py3-none-any.whl (15.0 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page