WP Manifestindependent plugin directory
manifest / ecommerce / coinos-wordpress-rewards

WP Zap Rewards

send rewards to your users for commenting, reviewing products, or give them sats back on every purchase with this wordpress plugin using coinos api

★ 3stars

Install

Download source zip No release zip yet

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.zip
No built-in updater. New versions won't appear under Dashboard → Updates. Install new releases yourself, or let Git Updater track the repository.

WP 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

  1. Go to coinos.io
  2. Create a free account
  3. Fund your account with some Bitcoin/Lightning
  4. Go to Settings → API and generate a full access token (not read-only)

2. Configure the Plugin

  1. In WordPress admin, go to Zap Rewards → Settings
  2. Enter your Coinos API token
  3. Click "Test API Connection" to verify it works
  4. 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:

  1. Recommended way: Create a Coinos account and enter just their username
  2. 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:

  1. Internal Coinos payments (if user enters their Coinos username)

    • ✅ Instant and free
    • ✅ No Lightning fees
    • ✅ Recommended for most users
  2. 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

  1. Check API token is correct
  2. Verify Coinos account has sufficient balance
  3. Check user has valid Lightning address set
  4. 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 ID
  • user_id - WordPress user ID
  • zap_address - Lightning address/Coinos username
  • reward_type - Type: comment, review, or purchase
  • amount - Amount in satoshis
  • status - Status: pending, completed, or failed
  • block_hash - Payment hash from Coinos
  • error_message - Error details if payment failed
  • comment_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

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!