{"id":19121314,"url":"https://github.com/cryptoadvance/spectrum","last_synced_at":"2025-08-17T11:11:34.625Z","repository":{"id":37836831,"uuid":"497021073","full_name":"cryptoadvance/spectrum","owner":"cryptoadvance","description":"Electrum adaptor simulating Bitcoin RPC protocol","archived":false,"fork":false,"pushed_at":"2024-06-25T12:20:24.000Z","size":273,"stargazers_count":9,"open_issues_count":12,"forks_count":12,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-07-07T01:06:13.282Z","etag":null,"topics":["specter-desktop"],"latest_commit_sha":null,"homepage":"","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/cryptoadvance.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":"2022-05-27T14:09:00.000Z","updated_at":"2024-11-19T11:36:07.000Z","dependencies_parsed_at":"2024-05-01T16:13:21.566Z","dependency_job_id":"d931c192-70c6-4573-b2dc-3bbe60a125f1","html_url":"https://github.com/cryptoadvance/spectrum","commit_stats":{"total_commits":46,"total_committers":6,"mean_commits":7.666666666666667,"dds":0.6521739130434783,"last_synced_commit":"53b4218aad6f037c235d1b3268423789365fa245"},"previous_names":[],"tags_count":23,"template":false,"template_full_name":null,"purl":"pkg:github/cryptoadvance/spectrum","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cryptoadvance%2Fspectrum","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cryptoadvance%2Fspectrum/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cryptoadvance%2Fspectrum/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cryptoadvance%2Fspectrum/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cryptoadvance","download_url":"https://codeload.github.com/cryptoadvance/spectrum/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cryptoadvance%2Fspectrum/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":270837583,"owners_count":24654391,"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-17T02:00:09.016Z","response_time":129,"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":["specter-desktop"],"created_at":"2024-11-09T05:16:44.902Z","updated_at":"2025-08-17T11:11:34.586Z","avatar_url":"https://github.com/cryptoadvance.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Spectrum - Specter Desktop + Electrum\n\nThis is a electrum-adapter. It exposes a Bitcoin-Core style API while using an electron API in the backend. It might be useful in specific usecases, e.g. having better performance when connecting to a electrum-server via Tor. In order to do that, it needs a Database. Quite easily you can use a kind of builtin SQLite. Depending on your usecase, you might want to use an external DB.\n\n## Modes of usage\n\nThis can be used either in standalone mode or as a specter-extension. The second option is probably the main use-case.\n\n## Standalone\n\nGet this to work with something like that:\n```\npython3 --version # Make sure you have at least 3.8. Might also work with lower versions though\nvirtualenv --python=python3 .env\n. ./.env/bin/activate\npip3 install -e .\n\n# If you have a electrum server running on localhost:\npython3 -m cryptoadvance.spectrum server --config cryptoadvance.spectrum.config.NigiriLocalElectrumLiteConfig\n\n# If you want to run on mainnet and use emzy's Server\npython3 -m cryptoadvance.spectrum server --config cryptoadvance.spectrum.config.EmzyElectrumLiteConfig\n\n# Using Emzy's server but with a postgres\nexport DB_USERNAME=bla\nexport DB_PASSWORD=blub\npython3 -m cryptoadvance.spectrum server --config cryptoadvance.spectrum.config.EmzyElectrumPostgresConfig\n```\n\nCheck the `config.py` for the env-vars which need to be exported in order to connect to something different than localhost.\n\n## Specter Extension\n\nIn order to get a development environment:\n```\nvirtualenv --python=python3 .env\n. ./.env/bin/activate\npip3 install -e .\npip3 install cryptoadvance.specter\npython3 -m cryptoadvance.specter server --config DevelopmentConfig --debug\n```\n\n\n## TODO:\n\n- refill keypool when address is used or new address is requested\n- flask `debug=True` flag creates two electrum sockets that notify twice - this causes duplications in the database\n- reconnect with electrum on disconnect\n- add support for credentials / cookie file for RPC calls\n\n\n## Run the Tests\n\n```sh\npip3 install -e \".[test]\"\npytest\n```\n\n## Development\n\nBefore your create a PR, make sure to [blackify](https://github.com/psf/black) all your changes. In order to automate that,\nthere is a git [pre-commit hook](https://ljvmiranda921.github.io/notebook/2018/06/21/precommits-using-black-and-flake8/) which you can simply install like this:\n```\npre-commit install\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcryptoadvance%2Fspectrum","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcryptoadvance%2Fspectrum","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcryptoadvance%2Fspectrum/lists"}