{"id":15357206,"url":"https://github.com/gera2ld/json-server.py","last_synced_at":"2025-04-15T06:43:02.647Z","repository":{"id":43468268,"uuid":"194435430","full_name":"gera2ld/json-server.py","owner":"gera2ld","description":"Fake REST API with zero coding","archived":false,"fork":false,"pushed_at":"2022-10-11T12:05:17.000Z","size":25,"stargazers_count":23,"open_issues_count":1,"forks_count":9,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-04-15T06:42:57.214Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"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/gera2ld.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}},"created_at":"2019-06-29T18:09:06.000Z","updated_at":"2025-03-04T12:47:59.000Z","dependencies_parsed_at":"2022-09-21T02:30:53.874Z","dependency_job_id":null,"html_url":"https://github.com/gera2ld/json-server.py","commit_stats":null,"previous_names":[],"tags_count":8,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gera2ld%2Fjson-server.py","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gera2ld%2Fjson-server.py/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gera2ld%2Fjson-server.py/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gera2ld%2Fjson-server.py/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/gera2ld","download_url":"https://codeload.github.com/gera2ld/json-server.py/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":249023727,"owners_count":21199958,"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","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":[],"created_at":"2024-10-01T12:34:00.170Z","updated_at":"2025-04-15T06:43:02.628Z","avatar_url":"https://github.com/gera2ld.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# json-server.py\n\n[![PyPI](https://img.shields.io/pypi/v/json-server.py.svg)](https://pypi.org/project/json-server.py/)\n\nFake REST API with zero coding.\n\nThis project is heavily inspired by [json-server](https://github.com/typicode/json-server) in JavaScript.\n\nRequires Python 3.6+.\n\n## Installation\n\nIt's highly recommended to install with [pipx](https://pipxproject.github.io/pipx/).\n\n```sh\n$ pipx install json-server.py\n```\n\nOr install with pip at your own risk:\n\n```sh\n$ pip3 install json-server.py\n```\n\n## Get Started\n\nCreate a `db.json` file with following content:\n\n```json\n{\n  \"posts\": []\n}\n```\n\nStart a server:\n\n```sh\n$ json-server db.json\n```\n\nCreate a post:\n\n```sh\n$ curl -H 'content-type: application/json' -d '{\"content\":\"blablabla\"}' http://localhost:3000/posts\n```\n\nList all posts:\n\n```sh\n$ curl http://localhost:3000/posts\n```\n\n## Usage\n\n```\nUsage: json-server [OPTIONS] [FILENAME]\n\n  Start a JSON server.\n\n  FILENAME refers to the JSON file where your data is stored. `db.json` will\n  be used if not specified.\n\nOptions:\n  --version        Show the version and exit.\n  -b, --bind TEXT  Set address to bind, default as `:3000`\n  --help           Show this message and exit.\n```\n\n**Note:**\n\n- Collections must be contained in your data file before starting the server, otherwise the server cannot decide the type of resources.\n\n### Examples\n\n```sh\n# Start with default config\n$ json-server\n\n# Listen on port 3000\n$ json-server -b :3000\n\n# Specify a json file\n$ json-server db.json\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgera2ld%2Fjson-server.py","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgera2ld%2Fjson-server.py","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgera2ld%2Fjson-server.py/lists"}