Install
This is the repository archive. It installs, but the folder name will carry the branch suffix and updates will not flow.
Install straight from GitHub with WP-CLI:
wp plugin install https://github.com/mnpezz/coinos-wordpress-rewards/archive/refs/heads/main.zipWP Zap Rewards - Bitcoin Lightning Rewards Plugin
Reward your users with Bitcoin via Lightning Network for comments, reviews, and purchases!
Features
⚡ Instant Bitcoin Lightning Payments via Coinos API
- Reward users for comments
- Reward users for product reviews
- Give cashback on purchases
- Automatic payment processing
- No manual intervention needed!
Quick Setup
1. Get a Coinos Account
- Go to coinos.io
- Create a free account
- Fund your account with some Bitcoin/Lightning
- Go to Settings → API and generate a full access token (not read-only)
2. Configure the Plugin
- In WordPress admin, go to Zap Rewards → Settings
- Enter your Coinos API token
- Click "Test API Connection" to verify it works
- Configure your reward amounts:
- Comments: 10 sats (recommended)
- Reviews: 50 sats (recommended)
- Purchases: 21% cashback (recommended)
3. Tell Your Users
Users need to add their Lightning receiving address in one of two ways:
- Recommended way: Create a Coinos account and enter just their username
- Alternative way: Enter a Lightning username
Users can set this in:
- My Account → ⚡ Zap Rewards (for registered users)
- During checkout (for WooCommerce purchases)
How It Works
For Comments
When an approved comment is posted:
- User must be logged in (no anonymous comments)
- User must have set their Lightning address
- Reward is sent instantly via Coinos API
- Daily limit prevents spam (default: 5 comments/day)
For Reviews
Same as comments, but typically a higher reward amount.
For Purchases
When a WooCommerce order is marked as "Completed":
- Calculates cashback percentage
- Converts to satoshis based on order total
- Sends payment automatically
Important Notes
Security
- Keep your Coinos API token secure
- Never share it or commit it to version control
- The token has full access to your Coinos account
Payment Types
The plugin supports:
-
Internal Coinos payments (if user enters their Coinos username)
- ✅ Instant and free
- ✅ No Lightning fees
- ✅ Recommended for most users
-
Lightning Network payments (if user enters a Lightning invoice)
- ⚠️ Subject to Lightning network fees
- ⚠️ Requires valid invoice
Satoshi Amounts
- 1 Bitcoin = 100,000,000 satoshis (sats)
- 100 sats ≈ $0.10 USD (varies with BTC price)
- Minimum payment: 1 sat
Troubleshooting
Payments Not Sending
- Check API token is correct
- Verify Coinos account has sufficient balance
- Check user has valid Lightning address set
- Look at Pending Rewards page in admin for errors
Test Connection Fails
- Verify API token is a full access token (not read-only)
- Check your internet connection
- Verify Coinos API is accessible from your server
Users Not Receiving Rewards
- User must have Lightning address set BEFORE earning rewards
- For purchases: ensure WooCommerce is installed and orders are marked "Completed"
- Check daily limits aren't exceeded
Database
The plugin creates one table: wp_zap_rewards
Columns:
id- Unique reward IDuser_id- WordPress user IDzap_address- Lightning address/Coinos usernamereward_type- Type: comment, review, or purchaseamount- Amount in satoshisstatus- Status: pending, completed, or failedblock_hash- Payment hash from Coinoserror_message- Error details if payment failedcomment_id- Comment ID (for comment/review rewards)order_id- Order ID (for purchase rewards)created_at- Timestamp
Support & Development
Viewing Rewards
Users can view their reward history at: My Account → ⚡ Zap Rewards
Admins can view all rewards and retry failed payments at: WP Admin → Zap Rewards → Pending Rewards
API Documentation
Full Coinos API docs: Coinos API
Related Plugins:
Credits
Powered by:
- Coinos - Bitcoin Lightning wallet and API
- Bitcoin Lightning Network
License
This plugin is provided as-is. Use at your own risk. Always test with small amounts first!