Paymail Inspector
CLI application for interacting with paymail service providers
Table of Contents
- Installation
- Commands
- Documentation
- Examples & Tests
- Code Standards
- Usage
- Maintainers
- Contributing
- License
Installation
Install with brew
brew tap mrz1836/paymail-inspector && brew install paymail-inspector
paymail
Install using a compiled binary on Linux, Mac or Windows (Mac example)
curl -LkSs https://github.com/mrz1836/paymail-inspector/releases/download/v0.3.7/paymail-inspector_macOS_64-bit.tar.gz -o app.tar.gz
tar -zxf app.tar.gz && cd ./app/
./paymail
Install with go
go get github.com/mrz1836/paymail-inspector
cd /$GOPATH/src/github.com/mrz1836/paymail-inspector && make install
paymail
Commands
brfc
List all known brfc specifications (view example)
paymail brfc list
Generate a new
BRFC ID
for a new specification (view example)
paymail brfc generate --title "BRFC Specifications" --author "andy (nChain)" --version 1
Search all brfc specifications (id, title, author) (view example)
paymail brfc search nChain
capabilities
Lists the available capabilities of the paymail service (view example)
paymail capabilities moneybutton.com
p2p
Starts a P2P payment request and returns (n) outputs of (
script
,satoshis
,address
) (view example)
paymail p2p [email protected]
resolve
Returns the
pubkey
,output script
,address
andprofile
for a given paymail address (view example)
paymail resolve [email protected]
validate
Runs several validations on the paymail service for DNSSEC, SSL, SRV and required capabilities (view example)
paymail validate moneybutton.com
verify
Verifies if a paymail is associated to a pubkey (view example)
paymail verify [email protected] 02ead23149a1e33df17325ec7a7ba9e0b20c674c57c630f527d69b866aa9b65b10
whois
Searches all public paymail providers for a given handle (view example)
paymail whois mrz
Documentation
Get started with the examples. View the generated golang godocs.
All the generated command documentation can be found in docs/commands.
This application was built using the official paymail specifications.
Additional paymail information can also be found via MoneyButton's documentation.
BRFCs
Implemented- BRFC ID Assignment (assignment)
- Service Discovery (b2aa66e26b43)
- Public Key Infrastructure (pki) (0c4339ef99c2)
- Basic Address Resolution (759684b1a19a)
- Verify Public Key Owner (a9f510c16bde)
- PayTo Protocol Prefix (7bd25e5a1fc6)
- Public Profile (f12f968c92d6)
- P2P Payment Destination (2a40af698840)
- Sender Validation (6745385c3fc0)
- P2P Transactions (5f1323cddf31)
- Receiver Approvals (3d7c2ca83a46)
- Merchant API (ce852c4c2cd1)
- JSON Envelope Specification (298e080a4598)
- Fee Specification (fb567267440a)
- MinerID (07f0786cdab6)
- MinerID Extension: FeeSpec (62b21572ca46)
- MinerID Extension: MinerParams (1b1d980b5b72)
- MinerID Extension: BlockInfo (a224052ad433)
- MinerID Extension: BlockBind (b8930c2bbf5d)
- SPV Channels API Specification (d534abdf761f)
Public Paymail Providers
Integrated Services
Custom Configuration
The configuration file should be located in your $HOME/paymail
folder and named config.yaml
.
View the example config file.
You can also specify a custom configuration file using --config "/folder/path/file.yaml"
Local Database (Cache)
The database is located in your $HOME/paymail
folder.
To clear the entire database:
paymail --flush-cache
Run commands ignoring local cache:
paymail whois mrz --no-cache
Package Dependencies
- badger for persistent database storage
- bsvd and bsvutil for BSV script functionality
- chalk for colorful logs
- cobra and viper for an easy configuration & CLI application development
- columnize for displaying terminal data in columns
- dns package for advanced DNS functionality
- go-homedir to find the home directory
- go-paymail for Paymail library support
- go-sanitize for sanitation and data formatting
- go-validate for domain/email/ip validations
- resty for custom HTTP client support
Application Deployment
goreleaser for easy binary deployment to Github and can be installed via: brew install goreleaser
.
The .goreleaser.yml file is used to configure goreleaser.
Use make release-snap
to create a snapshot version of the release, and finally make release
to ship to production.
The release can also be deployed to a homebrew
repository: homebrew-paymail-inspector.
Makefile Commands
View all makefile
commands
make help
List of all current commands:
all Runs multiple commands
build Build all binaries (darwin, linux, windows)
clean Remove previous builds and any test cache data
clean-mods Remove all the Go mod cache
coverage Shows the test coverage
darwin Build for Darwin (macOS amd64)
gen-docs Generate documentation from all available commands (fresh install)
gif-render Render gifs in .github dir (find/replace text etc)
godocs Sync the latest tag with GoDocs
help Show this help message
install Install the application
install-go Install the application (Using Native Go)
lint Run the golangci-lint application (install if not found)
linux Build for Linux (amd64)
release Full production release (creates release in Github)
release Runs common.release then runs godocs
release-snap Test the full release (build binaries)
release-test Full production test release (everything except deploy)
replace-version Replaces the version in HTML/JS (pre-deploy)
tag Generate a new tag and push (tag version=0.0.0)
tag-remove Remove a tag if found (tag-remove version=0.0.0)
tag-update Update an existing tag to current commit (tag-update version=0.0.0)
test Runs vet, lint and ALL tests
test-ci Runs all tests via CI (exports coverage)
test-ci-no-race Runs all tests via CI (no race) (exports coverage)
test-ci-short Runs unit tests via CI (exports coverage)
test-short Runs vet, lint and tests (excludes integration tests)
uninstall Uninstall the application (and remove files)
update-linter Update the golangci-lint package (macOS only)
update-terminalizer Update the terminalizer application
vet Run the Go vet application
windows Build for Windows (amd64)
Examples & Tests
All unit tests and examples run via Github Actions and uses Go version 1.15.x. View the configuration file.
Run all tests (including integration tests)
make test
Code Standards
Read more about this Go project's code standards.
Usage
View all the examples and see the commands above
All the generated command documentation can be found in docs/commands.
Maintainers
MrZ | Satchmo |
Contributing
View the contributing guidelines and please follow the code of conduct.
How can I help?
All kinds of contributions are welcome
Credits
Inspiration and code snippets from dnssec and check-ssl
Utilized terminalizer to record example gifs