{"id":29143451,"url":"https://github.com/vulpemventures/nigiri-chopsticks","last_synced_at":"2025-06-30T20:07:30.209Z","repository":{"id":48637374,"uuid":"175653200","full_name":"vulpemventures/nigiri-chopsticks","owner":"vulpemventures","description":"🔀  JSON HTTP proxy passtrough and authentication for 🍣Nigiri ","archived":false,"fork":false,"pushed_at":"2025-05-21T09:45:56.000Z","size":4615,"stargazers_count":5,"open_issues_count":0,"forks_count":7,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-06-30T15:57:02.410Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Go","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/vulpemventures.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-03-14T15:49:45.000Z","updated_at":"2025-06-02T14:58:35.000Z","dependencies_parsed_at":"2023-12-19T10:02:17.183Z","dependency_job_id":"62914316-5061-4503-9b0a-c6e283739365","html_url":"https://github.com/vulpemventures/nigiri-chopsticks","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"purl":"pkg:github/vulpemventures/nigiri-chopsticks","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vulpemventures%2Fnigiri-chopsticks","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vulpemventures%2Fnigiri-chopsticks/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vulpemventures%2Fnigiri-chopsticks/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vulpemventures%2Fnigiri-chopsticks/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/vulpemventures","download_url":"https://codeload.github.com/vulpemventures/nigiri-chopsticks/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vulpemventures%2Fnigiri-chopsticks/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":262842920,"owners_count":23373167,"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":"2025-06-30T20:07:26.247Z","updated_at":"2025-06-30T20:07:28.788Z","avatar_url":"https://github.com/vulpemventures.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Nigiri chopsticks\n\nThis is an API passthrough that simply proxies requests to the underlying services.\nIt expects an electrum REST server and an optional RPC server for faucet and custom broadcasting services.\n\n## Usage\n\nClone the repo:\n\n```bash\n$ git clone git@github.com:vulpmeventures/nigiri-chopsticks.git\n```\n\nRun tests:\n\n```\n$ bash scripts/test local\n```\n\nTo run tests locally you must have a running Nigiri instance.\n\nBuild for Linux x64:\n\n```bash\nnigiri-chopsticks $ bash scripts/build linux amd64\n```\n\nBuild for Mac:\n\n```bash\nnigiri-chopsticks $ bash scripts/build darwin amd64\n```\n\nRun:\n\n```bash\nnigiri-chopsticks $ ./build/nigiri-chopsticks-darwin-amd64\n```\n\n## Routes and Customization\n\nThe web server starts at default address `localhost:3000` with the following routes:\n\n- `/faucet` if faucet is enabled, to send funds to an address\n  - example for Bitcoin:\n  ```bash\n  $ curl -X POST --data '{\"address\": \"2MsnWskyHaHvcZUHA4gnR3G95EnUmZQjzM8\", \"amount\": 0.02}' http://localhost:3000/faucet\n  ```\n  - example for Liquid\n  ```bash\n  $ curl -X POST --data '{\"address\": \"2MsnWskyHaHvcZUHA4gnR3G95EnUmZQjzM8\", \"asset\": \"2dcf5a8834645654911964ec3602426fd3b9b4017554d3f9c19403e7fc1411d3\", \"amount\": 0.02}' http://localhost:3000/faucet\n  ```\n- `/mint` (only for Liquid chain) if faucet is enabled, to issue an asset and sent all issuance amount to an address\n  - example:\n  ```bash\n  $ curl -X POST --data '{\"address\": \"ert1q90dz89u8eudeswzynl3p2jke564ejc2cnfcwuq\", \"quantity\": 1000, \"name\": \"TokenName\", \"ticker\":\"TKN\"}' http://localhost:3000/mint\n  ```\n- `/registry` (only for Liquid chain) if faucet is enabled, to get extra info about one or more assets like `name` and `ticker`\n  ```bash\n  $ curl -X POST --data '{\"assets\": [\"2dcf5a8834645654911964ec3602426fd3b9b4017554d3f9c19403e7fc1411d3\"]}' http://localhost:3000/registry\n  # [{\"asset\":\"2dcf5a8834645654911964ec3602426fd3b9b4017554d3f9c19403e7fc1411d3\",\"contract\":{\"name\":\"test\",\"ticker\":\"TST\"},\"issuance_txin\":{\"txid\":\"a0891447adb288e5a49fa10ede7016788a1b3a175cfb423eb133e45f6cefca84\",\"vin\":0},\"name\":\"test\",\"ticker\":\"TST\"\n  ```\n- all [esplora](https://github.com/blockstream/esplora/blob/master/API.md) HTTP API endpoints\n\n**Note:**  \nIf mining is enabled, the esplora broadcast endpoint is wrapped so that a block is mined just after the transaction is published to get it confirmed; this is useful when running in regtest network.  \nAll requests to chopsticks are (optionally) logged using a logger inspired by [negroni](https://github.com/urfave/negroni) package.\n\n\n## Configuration: Command-Line Flags\n\n### Network Selection\n- `--chain` - Choose between bitcoin or liquid networks\n- `--wallet-name` - Specify wallet name (default: empty string `\"\"`)\n\n### Server Configuration\n- `--addr` - Server listening address (default: localhost:3000)\n- `--use-tls` - Enable/disable HTTPS (default: true)\n- `--use-logger` - Log all request/response activity\n\n### Bitcoin Node Connection\n- `--rpc-addr` - Bitcoin RPC server address (default: localhost:19001)\n- `--btc-cookie` - Bitcoin RPC credentials (default: admin1:123)\n\n### Liquid Node Connection\n- `--liquid-addr` - Liquid RPC server address (default: localhost:18884)\n- `--registry-path` - Path for asset registry database (Liquid only, defaults to current directory)\n\n### Electrum Server Connection\n- `--electrs-addr` - Electrs HTTP server address (default: localhost:3002)\n\n### Testing Utilities\n- `--use-faucet` - Enable /faucet endpoint for requesting funds\n- `--use-mining` - Enable automatic block mining after transaction broadcast\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvulpemventures%2Fnigiri-chopsticks","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fvulpemventures%2Fnigiri-chopsticks","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvulpemventures%2Fnigiri-chopsticks/lists"}