{"id":26187273,"url":"https://github.com/devils2ndself/kherson-underground","last_synced_at":"2026-04-13T03:01:57.084Z","repository":{"id":41446110,"uuid":"508854169","full_name":"devils2ndself/kherson-underground","owner":"devils2ndself","description":"Prize winning Telegram Hack-a-TON #1 submission - RenTON","archived":false,"fork":false,"pushed_at":"2022-07-03T17:38:40.000Z","size":1532,"stargazers_count":0,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2023-03-11T16:33:22.857Z","etag":null,"topics":["blockchain","cryptocurrency","hackathon","nodejs","react"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","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/devils2ndself.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":"2022-06-29T21:43:43.000Z","updated_at":"2022-09-07T18:30:52.000Z","dependencies_parsed_at":"2022-08-10T02:27:04.096Z","dependency_job_id":null,"html_url":"https://github.com/devils2ndself/kherson-underground","commit_stats":null,"previous_names":[],"tags_count":null,"template":null,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devils2ndself%2Fkherson-underground","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devils2ndself%2Fkherson-underground/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devils2ndself%2Fkherson-underground/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devils2ndself%2Fkherson-underground/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/devils2ndself","download_url":"https://codeload.github.com/devils2ndself/kherson-underground/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243131013,"owners_count":20241177,"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":["blockchain","cryptocurrency","hackathon","nodejs","react"],"created_at":"2025-03-11T23:48:57.917Z","updated_at":"2025-12-27T06:31:21.021Z","avatar_url":"https://github.com/devils2ndself.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# RenTON  \n\n## Kherson Underground team's submission for Telegram Hack-a-TON #1\n\nBicycle/e-scooter rental prototype that processes transactions in TON TestNet blockchain.\n\nThe working prototype can be found [here](https://web-renton.herokuapp.com/) (https://web-renton.herokuapp.com/).\n\n### Functional [Payment Channel service](https://github.com/devils2ndself/kherson-underground/blob/main/chariton-api/services/tonService.js)\n  - Workflow:\n    - Define a Service class instance.\n    - Call `initWallets()` to initialize the user and the system wallets for payment channels and remember them - _only done once per runtime_.\n    \n    - Now we can work with payment channels and off-chain transactions as many time as we want - _however, only 1 contract at a given moment per service instance_.  \n    - Call `startChannel()` method to deploy the channel, top up channel wallet balances (deposits), and initialize the channel.  \n      This can be done as many times as we want in runtime; however it will not start a new channel if an active channel already exists.\n    - `pay(amount)` will perform an off-chain transfer from the User's wallet balance to the System's balance inside the payment channel.  \n      Can be called as many times as possible until the channel is closed.\n    - Calling `closeChannel()` will close the payment channel and push it to the blockchain, distributing the funds between the two wallets.  \n      Will reject if there is no active payment channel in service instance.  \n\n  - The two TestNet wallets' addresses that we were using are `EQDGi47qkbNPyUCctuhzkbNfVfTCvWf-2CvNUbEpfB6ru9Up` (user) and `EQAKU7BeY8nGhFvYWjbVuFUEXAGweQEroUzENxSQjyBtVEgH` (system).\n \n  - The active payment channel will have a new id and address each time one is started. \n\n### A couple of other notes:\n  - The rent price for transportation is stored in USDT, being converted to TON via CoinMarketCap API.\n\n  - Putting payment channels to hosting had it's own challenges of maximum transactions limits, so we made a decision of not uploading it to the production, but it works great in local environment.\n  \n  - ChariTON was our previous idea and we couldn't rename the main folders at that stage.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdevils2ndself%2Fkherson-underground","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdevils2ndself%2Fkherson-underground","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdevils2ndself%2Fkherson-underground/lists"}