{"id":30939179,"url":"https://github.com/imranc07/json-merge-py","last_synced_at":"2026-05-20T05:05:13.595Z","repository":{"id":313470787,"uuid":"1051539215","full_name":"imranc07/json-merge-py","owner":"imranc07","description":"A Python project for reading, manipulating, and merging JSON files without data overlap. Demonstrates JSON handling, list iteration, nested value extraction, and writing updated JSON outputs.","archived":false,"fork":false,"pushed_at":"2025-09-06T08:23:22.000Z","size":9,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-09-06T10:05:52.097Z","etag":null,"topics":["json","list-iteration","nested-values","python"],"latest_commit_sha":null,"homepage":"https://github.com/imranc07/json-merge-py.git","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/imranc07.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-09-06T07:48:24.000Z","updated_at":"2025-09-06T08:23:25.000Z","dependencies_parsed_at":"2025-09-06T10:05:58.666Z","dependency_job_id":null,"html_url":"https://github.com/imranc07/json-merge-py","commit_stats":null,"previous_names":["imranc07/json-merge-py"],"tags_count":null,"template":false,"template_full_name":null,"purl":"pkg:github/imranc07/json-merge-py","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/imranc07%2Fjson-merge-py","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/imranc07%2Fjson-merge-py/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/imranc07%2Fjson-merge-py/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/imranc07%2Fjson-merge-py/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/imranc07","download_url":"https://codeload.github.com/imranc07/json-merge-py/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/imranc07%2Fjson-merge-py/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":274509963,"owners_count":25299071,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-09-10T02:00:12.551Z","response_time":83,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["json","list-iteration","nested-values","python"],"created_at":"2025-09-10T19:09:50.237Z","updated_at":"2026-05-20T05:05:13.566Z","avatar_url":"https://github.com/imranc07.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# 🗂️ JSON Data Manipulation \u0026 Merging in Python\n\n## 📌 Problem Statement\n\nCreate a Python script that:\n1. Reads data from JSON files\n2. Loops through a list of items\n3. Extracts nested values\n4. Merges multiple JSON files **without overlap**\n\n------------------------------------------------------------------------\n\n## 📜 Project Overview\n\nThis project demonstrates how to work with JSON files in Python using\nthe built-in `json` module.\nIt covers:\n- Reading JSON files\n- Iterating through list values (e.g., skills)\n- Extracting nested dictionary values (e.g., job role, years, company)\n- Adding new keys to JSON data\n- Merging multiple JSON files into one consolidated JSON file\n\n------------------------------------------------------------------------\n\n## 📂 File Structure\n\n    project/\n    │── data1.json          # Sample JSON file (Employee 1)\n    │── data2.json          # Sample JSON file (Employee 2)\n    │── json_read_write.py  # Main Python script\n    │── updated_data1.json  # Output after modifying data1.json\n    │── updated_data2.json  # Output after modifying data2.json\n    │── merged_data.json    # Final merged JSON file\n    │── README.md           # Documentation\n\n------------------------------------------------------------------------\n\n## ▶️ How to Run\n\n1.  Clone this repository\n\n    ``` bash\n    git clone https://github.com/your-username/json-merge-py.git\n    cd json-merge-py\n    ```\n\n2.  Make sure Python 3 is installed on your system.\n\n3.  Run the script:\n\n    ``` bash\n    python json_read_write.py\n    ```\n\n4.  Check the generated files:\n\n    -   `updated_data1.json`\n    -   `updated_data2.json`\n    -   `merged_data.json`\n\n------------------------------------------------------------------------\n\n## ✅ Example Output\n\n### Original Data (`data1.json`)\n\n``` json\n{\n    \"id\": 101,\n    \"name\": \"Imran Ahmad\",\n    \"skills\": [\"Python\", \"Selenium\", \"PyTest\"],\n    \"experience\": {\n        \"role\": \"Automation Tester\",\n        \"years\": 3,\n        \"company\": \"Heaven of Freedom\"\n    }\n}\n```\n\n### Updated Data (`updated_data1.json`)\n\n``` json\n{\n    \"id\": 101,\n    \"name\": \"Imran Ahmad\",\n    \"skills\": [\"Python\", \"Selenium\", \"PyTest\"],\n    \"experience\": {\n        \"role\": \"Automation Tester\",\n        \"years\": 3,\n        \"company\": \"Heaven of Freedom\"\n    },\n    \"status\": \"processed\"\n}\n```\n\n### Merged Data (`merged_data.json`)\n\n``` json\n[\n    {\n        \"id\": 101,\n        \"name\": \"Imran Ahmad\",\n        \"skills\": [\"Python\", \"Selenium\", \"PyTest\"],\n        \"experience\": {\n            \"role\": \"Automation Tester\",\n            \"years\": 3,\n            \"company\": \"Heaven of Freedom\"\n        },\n        \"status\": \"processed\"\n    },\n    {\n        \"id\": 102,\n        \"name\": \"Nahid Anjum\",\n        \"skills\": [\"Java\", \"TestNG\", \"API Testing\"],\n        \"experience\": {\n            \"role\": \"QA Engineer\",\n            \"years\": 2,\n            \"company\": \"Never More\"\n        },\n        \"status\": \"rejected\"\n    }\n]\n```\n\n------------------------------------------------------------------------\n\n## 🛠️ Technologies Used\n\n-   Python 3\n-   JSON module\n\n------------------------------------------------------------------------\n\n## 🚀 Future Improvements\n\n-   Add support for **merging all JSON files dynamically** from a\n    folder.\n-   Include **error handling** for malformed or empty JSON files.\n-   Extend script to handle **nested merges** across multiple levels.\n-   Add **unit tests** to validate JSON processing.\n-   Provide a **command-line interface (CLI)** for flexible usage.\n\n------------------------------------------------------------------------\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fimranc07%2Fjson-merge-py","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fimranc07%2Fjson-merge-py","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fimranc07%2Fjson-merge-py/lists"}