https://github.com/anquii/electrumx
A JSON-RPC 2.0 client implementation of ElectrumX in Swift
https://github.com/anquii/electrumx
electrum electrum-client electrumx ios macos swift swift-package swift-package-manager
Last synced: about 1 month ago
JSON representation
A JSON-RPC 2.0 client implementation of ElectrumX in Swift
- Host: GitHub
- URL: https://github.com/anquii/electrumx
- Owner: anquii
- License: mit
- Created: 2023-05-08T11:04:05.000Z (about 3 years ago)
- Default Branch: main
- Last Pushed: 2023-08-05T11:30:19.000Z (almost 3 years ago)
- Last Synced: 2023-08-05T13:42:34.251Z (almost 3 years ago)
- Topics: electrum, electrum-client, electrumx, ios, macos, swift, swift-package, swift-package-manager
- Language: Swift
- Homepage:
- Size: 7.81 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# ElectrumX
[](#platforms)
[](#swift-package-manager)
[](https://github.com/anquii/ElectrumX/blob/main/LICENSE)
A [JSON-RPC 2.0](https://www.jsonrpc.org/specification) client implementation of [ElectrumX](https://github.com/spesmilo/electrumx/pull/90) in Swift.
## Platforms
- macOS 10.15+
- iOS 13+
## Installation
### Swift Package Manager
Add the following line to your `Package.swift` file:
```swift
.package(url: "https://github.com/anquii/ElectrumX.git", from: "0.1.0")
```
...or integrate with Xcode via `File -> Swift Packages -> Add Package Dependency...` using the URL of the repository.
## Usage
```swift
import ElectrumX
let service = ElectrumXService(endpoint: endpoint, parameters: parameters)
try await service.startConnection()
try await service.version(params: versionParams)
let response = try await service.balance(scriptHash: scriptHash)
try await service.cancelConnection()
```
## License
`ElectrumX` is licensed under the terms of the MIT license. See the [LICENSE](LICENSE) file for more information.
## Donations
If you've found this software useful, please consider making a small contribution to one of these crypto addresses:
```
XNAV: xNTYqoQDzsiB5Cff9Wpt65AgZxYkt1GFy7KwuDafqRU2bcAZqoZUW4Q9TZ9QRHSy8cPsM5ALkJasizJCmqSNP9CosxrF2RbKHuDz5uJVUBcKJfvnb3RZaWygr8Bhuqbpc3DsgfB3ayc
XMR: 49jzT7Amu9BCvc5q3PGiUzWXEBQTLQw68a2KvBFTMs7SHjeWgrSKgxs69ycFWQupyw9fpR6tdT8Hp5h3KksrBG9m4c8aXiG
BTC: bc1q7hehfmnq67x5k7vz0cnc75qyflkqtxe2avjkyw
ETH (ERC-20) & BNB (BEP-20): 0xe08e383B4042749dE5Df57d48c57A690DC322b8d
```