{"id":23780699,"url":"https://github.com/hunter87ff/flapi","last_synced_at":"2025-08-23T11:09:19.164Z","repository":{"id":267014543,"uuid":"899155772","full_name":"Hunter87ff/flapi","owner":"Hunter87ff","description":"A free and open source api for devs to get data of their given schema. it helps to make development faster without the headache of data collection.","archived":false,"fork":false,"pushed_at":"2025-06-28T04:33:53.000Z","size":3406,"stargazers_count":6,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-08-23T11:06:26.722Z","etag":null,"topics":["fastapi","fill-api","flapi","mock-data-generator","public-api"],"latest_commit_sha":null,"homepage":"https://flapi.sprucbot.tech/ ","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Hunter87ff.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","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},"funding":{"github":"hunter87ff","patreon":"peepalfarm","open_collective":null,"ko_fi":null,"tidelift":null,"community_bridge":null,"liberapay":null,"issuehunt":null,"otechie":null,"lfx_crowdfunding":null,"custom":"https://peepalfarm.org/support"}},"created_at":"2024-12-05T18:13:10.000Z","updated_at":"2025-06-28T04:33:57.000Z","dependencies_parsed_at":"2025-07-17T20:05:43.076Z","dependency_job_id":null,"html_url":"https://github.com/Hunter87ff/flapi","commit_stats":null,"previous_names":["hunter87ff/flapi"],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/Hunter87ff/flapi","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Hunter87ff%2Fflapi","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Hunter87ff%2Fflapi/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Hunter87ff%2Fflapi/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Hunter87ff%2Fflapi/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Hunter87ff","download_url":"https://codeload.github.com/Hunter87ff/flapi/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Hunter87ff%2Fflapi/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":271746767,"owners_count":24813582,"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-08-23T02:00:09.327Z","response_time":69,"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":["fastapi","fill-api","flapi","mock-data-generator","public-api"],"created_at":"2025-01-01T11:15:56.385Z","updated_at":"2025-08-23T11:09:19.102Z","avatar_url":"https://github.com/Hunter87ff.png","language":"Python","funding_links":["https://github.com/sponsors/hunter87ff","https://patreon.com/peepalfarm","https://peepalfarm.org/support"],"categories":[],"sub_categories":[],"readme":"[![](https://img.shields.io/static/v1?label=Sponsor\u0026message=%E2%9D%A4\u0026logo=GitHub\u0026color=%23fe8e86)](https://github.com/sponsors/hunter87ff)  \n![GitHub Release](https://img.shields.io/github/v/release/hunter87ff/flapi?logo=Github\u0026label=Release)\n[![Language](https://img.shields.io/static/v1?label=Lang\u0026message=Python\u0026logo=Python\u0026color=blue\u0026logoColor=cyan)](#)\n[![Security Rating](https://sonarcloud.io/api/project_badges/measure?project=Hunter87ff_flapi\u0026metric=security_rating)](#)\n\n\u003cimg class=\"resp-img\" src=\"https://raw.githubusercontent.com/Hunter87ff/flapi/main/assets/img/flapi.png\" alt=\"Flapi\" style=\"border-radius:5px;\"/\u003e\n\nFlapi (derived from \"Fill API\" term) is a free-to-use service tailored for frontend developers. It generates mock data effortlessly based on your custom schemas, speeding up your workflow and simplifying development.\n\n## Why Flapi?\n\n**Fully Customizable Data:** Define your schema, and Flapi fills it in no time.\n\n**Dynamic Multi-Response:** Flapi can generate different responses for the same schema in one call (amount parameter).\n\n**Frontend-Centric Design:** Build and test interfaces without backend dependencies.\n\n**Completely Free:** Designed with developers in mind to make their lives easier.\n\n**Let Flapi fill your API needs for mock data and take your development to the next level!**\n\n\n## Example Code\n```python\n\nimport requests\n\nresponse = requests.get(\n    \"https://flapi.sprucbot.tech/v1/gen?amount=2\", \n    json={\n        \"name\" : \"name()\",\n        \"email\" : \"email(domain=hg.co)\",\n        \"age\" : \"age(min=78$max=200)\",\n        \"address\" : \"address()\",\n        \"created_at\" : \"date()\",\n        \"phone\" : \"phone(code=87)\",\n        \"ids\" : \"list-int(amount=3$max=2)\",\n        \"employee\" : {\n            \"_$amount\" : 1,\n            \"name\" : \"name()\",\n            \"position\" : \"text(len=5)\",\n            \"clients\" : {\n                \"_$amount\" : 2,\n                \"deal\" : \"int(len=5)\",\n                \"name\" : \"name()\",\n                \"email\" : \"email(domain=hg.co)\"\n            }\n        }\n    }\n)\n\nif response.status_code == 200:\n    data = response.json()\n    print(data)\nelse:\n    print(f\"Error: {response.status_code}\")\n\n```\n\n\n**Example Response**\n\n```json\n{\n  \"name\": \"Jennifer Huynh\",\n  \"email\": \"kristenturner@hg.co\",\n  \"age\": 125,\n  \"address\": \"959 Holden Corner Apt. 103\\nEast Matthew, IN 93214\",\n  \"created_at\": \"18-12-2003\",\n  \"phone\": \"+87-9487346280\",\n  \"ids\": [1,2,1],\n  \"employee\": [\n    {\n      \"_$amount\": 1,\n      \"name\": \"Jason Hartman\",\n      \"position\": \"PM.\",\n      \"clients\": [\n        {\n          \"_$amount\": 2,\n          \"deal\": 55503,\n          \"name\": \"Nicole Parker\",\n          \"email\": \"yhopkins@hg.co\"\n        },\n        {\n          \"_$amount\": 2,\n          \"deal\": 35965,\n          \"name\": \"Mark Thomas\",\n          \"email\": \"kirsten79@hg.co\"\n        }\n      ]\n    }\n  ]\n}\n```\n\n## Routes\nBase URL: https://flapi.sprucbot.tech/v1/gen\n### /v1/gen\nGenerates mock data based on the provided schema. The schema is passed as a JSON object in the request body. The response will be a JSON object with the generated data. The amount parameter can be used to generate multiple responses with the same schema.\n\n#### Endpoint Parameters\n\n- **amount** - The number of responses to generate. Default: 1.\n- **schema** - The schema for the data to generate. instead of schema query parameter, you can pass the schema in the request body.\n\n\n## Types and Parameters\nTypes and parameters are used to define the schema for the data you want to generate. Here are the available types and parameters:\n\n\n### Types\n- [**int()**](#int) - Generates a random integer within the specified range.\n- [**float()**](#float) - Generates a random float within the specified range.\n- [**bool()**](#bool) - Generates a random boolean value.\n\n- [**name()**](#name) - Generates a random name.\n- [**email()**](#email) - Generates a random email address with the specified domain.\n- [**password()**](#password) - Generates a random password with the specified length.\n- [**age()**](#age) - Generates a random age within the specified range.\n- [**address()**](#address) - Generates a random address.\n- [**date()**](#date) - Generates a random date.\n- [**phone()**](#phone) - Generates a random phone number with the specified country code.\n- [**text()**](#text) - Generates random text with the specified length.\n- [**subject()**](#subject) - Generates a random subject.\n- [**description()**](#description) - Generates a random description.\n- [**list-int()**](#list-int) - Generates a list of random integers with the specified amount and range.\n- [**list-str()**](#list-str) - Generates a list of random strings with the specified amount and length.\n- [**object{}**](#object) - Generates an object with the specified keys and types.\n\n\n## Parameters\n\n### int\n- **min** - The minimum value of the integer. Default: 0.\n- **max** - The maximum value of the integer. Default: 100.\n\nexample : \n```json\n{\n    \"int\" : \"int(min=5$max=10)\"\n}\n```\n\n### float\n- **min** - The minimum value of the float. Default: 0.0\n- **max** - The maximum value of the float. Default: 100.0\n\nexample : \n```json\n{\n    \"float\" : \"float(min=5$max=10)\"\n}\n```\n\n### bool\n- No parameters.\n\nexample : \n```json\n{\n    \"bool\" : \"bool()\"\n}\n```\n\n\n### name\n- No parameters.\n\nexample : \n```json\n{\n    \"name\" : \"name()\"\n}\n```\n\n\n### email\n- **domain** - The domain of the email address. Default: gmail.com.\n\nexample : \n```json\n{\n    \"email\" : \"email(domain=hg.co)\"\n}\n```\n\n### password\n- **len** - The length of the password. Default: 8.\n\nexample : \n```json\n{\n    \"pass\" : \"password(len=8)\"\n}\n```\n\n\n### age\n- **min** - The minimum age. Default: 18.\n- **max** - The maximum age. Default: 100.\n\nexample : \n```json\n{\n    \"age\" : \"age(min=78$max=200)\"\n}\n```\n\n\n### address\n- No parameters.\n\nexample : \n```json\n{\n    \"address\" : \"address()\"\n}\n```\n\n\n### date\n- **between** - The date range. Default: `2000-2024`\n- **format** - The date format. Default: `%d/%m/%Y`\n- **era** - can be `now` so it will generate the current date. \nexample : \n```json\n{\n    \"dob\" : \"date(between=2000-2006)\"\n}\n```\n\n\n### phone\n- **code** - The country code of the phone number. Default: 91.\n\nexample : \n```json\n{\n    \"phone\" : \"phone(code=87)\"\n}\n```\n\n\n### text\n- **len** - The length of the text. Default: 10.\n\nexample : \n```json\n{\n    \"text\" : \"text(len=5)\"\n}\n```\n\n### subject\n- **category** - The category of the subject. Default: `any`\n - - Categories : \n    - - `computer_science` or `cs`\n    - - `science` : Science related subjects\n    - - `commerce` : Commerce related subjects\n    - - `arts` : Arts related subjects\n    - - `engineering` : Engineering related subjects\n    - - `medical` : Medical related subjects\n    - - `law` : Law related subjects\n    - - `any` : any random subject\n\nexample :\n```json\n{\n    \"subject\" : \"subject(category=commerce)\"\n}\n```\n\n### description\n- **words** - The number of words in the description. Default: 3.\n\nexample : \n```json\n{\n    \"description\" : \"description(words=5)\"\n}\n```\n\n### Image\n- **width** - The width of the image. Default: 200.\n- **height** - The height of the image. Default: 200.\n\nexample : \n```json\n{\n    \"image\" : \"image(width=300$height=300)\"\n}\n```\n\n## List Types\nThe list types are used to generate a list of values based on the specified schema. \n\n### list-int\n- **amount** - The number of integers to generate. Default: 3.\n- **min** - The minimum value of the integers. Default: 0.\n- **max** - The maximum value of the integers. Default: 100.\n\nexample : \n```json\n{\n    \"list\" : \"list-int(amount=2$max=5)\"\n}\n```\n\n\n### list-str\n- **amount** - The number of strings to generate. Default: 3.\n- **len** - The length of the strings. Default: 10.\n\nexample : \n```json\n{\n    \"list\" : \"list-str(amount=2$len=5)\"\n}\n```\n\n### list-name\n- **amount** - The number of names to generate. Default: 3.\n\nexample : \n```json\n{\n    \"list\" : \"list-name(amount=2)\"\n}\n```\n\n### list-email\n- **amount** - The number of email addresses to generate. Default: 3.\n- **domain** - The domain of the email addresses. Default: gmail.com.\n\nexample : \n```json\n{\n    \"list\" : \"list-email(amount=2$domain=hg.co)\"\n}\n```\n\n### list-subject\n- **amount** - The number of subjects to generate. Default: 3.\n- **category** - The category of the subjects. Default: any.\n\nexample : \n```json\n{\n    \"list\" : \"list-subject(amount=2$category=cs)\"\n}\n```\n\n\n### object\nObject type defination is a bit different from others. It requires a key and a type. The key is the name of the object's property, and the type is the schema of the object property's value. The object type can also have the _$amount parameter to generate multiple objects with the same schema.\n- **_$amount** - The number of objects to generate. Default: 1.\n\n\nexample : \n```json\n{\n    \"obj\" : {\n        \"_$amount\" : 2, \n        \"name\" : \"name()\",\n        \"email\" : \"email(domain=hg.co)\",\n        \"pass\" : \"password(len=8)\"\n    }\n}\n```\n\n## Contributing\nContributions are welcome! Please feel free to submit a pull request or open an issue if you have any suggestions or feedback.\n\n## License\nThis project is licensed under the MIT License - see the [LICENSE](https://github.com/Hunter87ff/flapi/blob/main/LICENSE) for more details.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhunter87ff%2Fflapi","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhunter87ff%2Fflapi","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhunter87ff%2Fflapi/lists"}