{"id":18542866,"url":"https://github.com/ben-d-anderson/nanopay","last_synced_at":"2025-05-15T05:09:52.009Z","repository":{"id":109145286,"uuid":"550426043","full_name":"Ben-D-Anderson/NanoPay","owner":"Ben-D-Anderson","description":"Self-hostable payment processor for the NANO cryptocurrency.","archived":false,"fork":false,"pushed_at":"2022-11-13T15:16:22.000Z","size":127,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-02-17T08:44:02.711Z","etag":null,"topics":["api-rest","blockchain","cryptocurrency","java","library","nanocurrency","payment-processing"],"latest_commit_sha":null,"homepage":"","language":"Java","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/Ben-D-Anderson.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","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}},"created_at":"2022-10-12T18:43:52.000Z","updated_at":"2022-10-19T11:20:48.000Z","dependencies_parsed_at":"2023-04-09T14:48:45.552Z","dependency_job_id":null,"html_url":"https://github.com/Ben-D-Anderson/NanoPay","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Ben-D-Anderson%2FNanoPay","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Ben-D-Anderson%2FNanoPay/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Ben-D-Anderson%2FNanoPay/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Ben-D-Anderson%2FNanoPay/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Ben-D-Anderson","download_url":"https://codeload.github.com/Ben-D-Anderson/NanoPay/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254276461,"owners_count":22043868,"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":["api-rest","blockchain","cryptocurrency","java","library","nanocurrency","payment-processing"],"created_at":"2024-11-06T20:10:58.835Z","updated_at":"2025-05-15T05:09:51.985Z","avatar_url":"https://github.com/Ben-D-Anderson.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# NanoPay\n\n**Warning: This project is a work-in-progress and may not function 100% correctly. There is also a lack of documentation.**\n\nA self-hostable payment processor for the [NANO cryptocurrency](https://www.nano.org). This project uses the standard\nconcept of 'payments' to abstract away the blockchain and function as a simple, high-level payment processor.\n\nOnce a payment is completed in NanoPay, the funds are forwarded to the configured 'storage wallet'. Any under-payments\nor over-payments are automatically refunded to the sender.\n\nBy default, NanoPay uses a third-party NANO RPC node ([nanos.cc](https://api.nanos.cc/) - limited to 5000 requests/day). It\nis recommended that you connect NanoPay to your own NANO node to increase service reliability and remove usage limits.\n\n## Building From Source\n\n### Prerequisites\n\nIn order to build this project, you are required to have and use the following tools:\n- Git\n- JDK 16\n- Apache Maven\n\n### Steps\n\nFirst, clone the git repository by executing the following command (ensure to use the `--recursive` flag):\n```bash\ngit clone --recursive https://github.com/Ben-D-Anderson/NanoPay\n```\nNext, navigate into the cloned repository and build the project as follows:\n```bash\ncd NanoPay \u0026\u0026 mvn clean install -Dmaven.javadoc.skip=true -Dgpg.skip\n```\n\n### Running the REST API\n\nTo run the HTTP REST API, execute the following command (where `{VERSION}` is the version of NanoPay you cloned):\n```bash\n$ java -jar nanopay-webapi/target/nanopay-webapi-{VERSION}.jar\n```\n\n## NanoPay as a library\n\nThe `nanopay-core` module contains the main backbone of the NanoPay payment processor - everything from wallet management\nto blockchain interactions. This is ideal if you are a developer wanting to use the payment processor through pure Java,\nwithout the REST API.\n\n### Brief Codebase Overview\n\nIn NanoPay, a new NANO wallet is created for each requested transaction. The design philosophy is centred around the\nidea of 'alive' and 'dead' wallets, comparable to \"waiting for\" and \"either given up waiting for, or completed\"\npayments, respectively.\n\nThe `WalletStorage` interface provides arbitrary storage for alive and dead wallets, with a range of default\nimplementations to pick from. The `WalletDeathLogger` interface provides arbitrary logging capability for when wallets\nare declared dead (note: this is in addition to the default wallet death callbacks).\n\nThe `NanoPay.Builder` class follows a typical builder design pattern and is used to construct `NanoPay` instances. An\nextensive example of its usage can be found in `ConfigurationParser.java`, under the `nanopay-webapi` module.\n\n### Maven Dependency\n\nHaving built NanoPay from source, the modules will be in your local Maven repository. You can then include it as a dependency\nin a Maven project by adding the following to the `dependencies` section of your `pom.xml`:\n```xml\n\u003cdependency\u003e\n    \u003cgroupId\u003ecom.terraboxstudios\u003c/groupId\u003e\n    \u003cartifactId\u003enanopay-core\u003c/artifactId\u003e\n    \u003cversion\u003e{VERSION}\u003c/version\u003e\n    \u003cscope\u003ecompile\u003c/scope\u003e\n\u003c/dependency\u003e\n```\n\n### Database Integration ([Hibernate](https://en.wikipedia.org/wiki/Hibernate_(framework)))\n\nIf you are planning to use a database to store any NanoPay-related information, you can add the `nanopay-hibernate-storage`\nmodule as a dependency to your project:\n```xml\n\u003cdependency\u003e\n    \u003cgroupId\u003ecom.terraboxstudios\u003c/groupId\u003e\n    \u003cartifactId\u003enanopay-hibernate-storage\u003c/artifactId\u003e\n    \u003cversion\u003e{VERSION}\u003c/version\u003e\n    \u003cscope\u003ecompile\u003c/scope\u003e\n\u003c/dependency\u003e\n```\nThis will provide access to the classes `HibernateWalletStorage` and `HibernateWalletDeathLogger`. Don't forget, you\nwill still need to add the dependency for your chosen database's driver into your project too.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fben-d-anderson%2Fnanopay","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fben-d-anderson%2Fnanopay","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fben-d-anderson%2Fnanopay/lists"}