{"id":15887839,"url":"https://github.com/reddec/binp","last_synced_at":"2026-05-09T14:35:31.924Z","repository":{"id":57415170,"uuid":"336837435","full_name":"reddec/binp","owner":"reddec","description":"Basic Integration Platform - inspired by node-red","archived":false,"fork":false,"pushed_at":"2021-02-14T09:24:57.000Z","size":594,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-27T03:34:34.069Z","etag":null,"topics":["asyncio","automation","fastapi","integrations-framework","routify","svelte"],"latest_commit_sha":null,"homepage":"https://binp.readthedocs.io/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/reddec.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2021-02-07T16:47:13.000Z","updated_at":"2021-02-12T15:14:40.000Z","dependencies_parsed_at":"2022-09-01T16:41:51.155Z","dependency_job_id":null,"html_url":"https://github.com/reddec/binp","commit_stats":null,"previous_names":[],"tags_count":6,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/reddec%2Fbinp","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/reddec%2Fbinp/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/reddec%2Fbinp/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/reddec%2Fbinp/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/reddec","download_url":"https://codeload.github.com/reddec/binp/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246852990,"owners_count":20844503,"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":["asyncio","automation","fastapi","integrations-framework","routify","svelte"],"created_at":"2024-10-06T06:05:17.321Z","updated_at":"2026-05-09T14:35:31.849Z","avatar_url":"https://github.com/reddec.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Basic Integration Platform\n\n![PyPI](https://img.shields.io/pypi/v/binp)\n![PyPI - License](https://img.shields.io/pypi/l/binp)\n![PyPI - Python Version](https://img.shields.io/pypi/pyversions/binp)\n\n![logo-192](https://user-images.githubusercontent.com/6597086/107153224-4dc2d080-69a7-11eb-96d1-31c304fb821f.png)\n\nProvides a platform for automation with code-first approach,\nwith embedded batteries:\n\n* Tracing (journals)\n* Internal and user-defined API\n* Ultra-light but rich mobile-first UI\n* Embedded key-value storage\n\nIt is heavily inspired by node-red and aims to provide same\nenjoyment during development but without mess of nodes and connections\nfor tasks a little bit more complicated than just hello world.\n\nThe platform also tries to be easy in deployment and maintaining.\nCode could be stored in a SCM (ex: git) and persistent storage is just a single file that\ncould be backed up and restored trivially.\n\nBecause memory and CPU consumption relatively low a solution based on the platform\ncould be launched even on Raspberry Pi Zero with 512MB RAM.\n\n## Install\n\n`pip install binp uvicorn[standard]`\n\nExample:\n\n```python\nfrom random import randint\n\nfrom binp import BINP\n\nbinp = BINP()\n\n\n@binp.app.post('/random', response_model=int)\n@binp.journal\nasync def generate_random():\n    \"\"\"\n    Generate random number in range 0 ... 1024\n    \"\"\"\n    return randint(0, 1024)\n\n\n@binp.action\n@binp.journal\nasync def currency_rate():\n    \"\"\"\n    Fetch currency rate for EUR -\u003e USD\n    \"\"\"\n    # go to external service\n    euro = 1.3\n    await binp.journal.record('rates fetched', base_currency='USD', euro=euro)\n```\n\nSave as 'example.py' and run it by\n\n```\nuvicorn example:binp.app\n```\n\n\u003e TIP: pass `--reload` flag to `uvicorn` to support automatic reload during development\n\nIt will expose\n\n* http://127.0.0.1:8000 - UI and API\n* http://127.0.0.1:8000/docs - Swagger docs for user-defined APIs\n* http://127.0.0.1:8000/internal/docs - Swagger docs for internal APIs\n\n\n![Peek 2021-02-08 17-27](https://user-images.githubusercontent.com/6597086/107200766-14d03d80-6a33-11eb-96fc-5d132cb2862e.gif)\n\n![image](https://user-images.githubusercontent.com/6597086/107201190-a049ce80-6a33-11eb-94ac-dd4117d0ed52.png)\n\n\n## Configuration\n\nDefault configuration can be changed by environment variables:\n\n* `DEV` - set `DEV=true` to enable development mode\n* `DB_URL` - database SQLITE URL, default `sqlite:///data.db`\n\nHTTP port and binding address configured by `uvicorn`:\n\n* `--port` - set listening port, default `8000`\n* `--host` - set binding host, default `127.0.0.1`\n\n\nFor `uvicorn` command should be like\n\n    uvicorn \u003cpython file without .py\u003e:\u003cbinp instance\u003e.app","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Freddec%2Fbinp","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Freddec%2Fbinp","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Freddec%2Fbinp/lists"}