Guides
WooCommerce plugin
Install and configure the FlatCryptoPay for WooCommerce plugin: API key, webhook secret, order statuses and test mode.
The FlatCryptoPay for WooCommerce plugin adds a "Crypto or card" payment method to your store. Customers are sent to the hosted pay page, and the order is updated automatically by a signed webhook, with a status re-check when the customer returns.
Requirements
- WordPress 6.0+ and WooCommerce 7.0+, PHP 7.4+.
- Store currency USD, EUR, GBP, CAD or AUD.
- Your site reachable over HTTPS (for the webhook).
- Compatible with High-Performance Order Storage (HPOS) and the block-based Cart and Checkout.
Install
- In WordPress, go to Plugins → Add New → Upload Plugin and upload
flatcryptopay-for-woocommerce.zip. Activate it. - Go to WooCommerce → Settings → Payments → FlatCryptoPay.
- Paste an API key from your dashboard. Start with a
fcp_test_key; the settings page shows a test-mode notice. - Copy the webhook URL shown on the settings page:
https://YOUR-SHOP/wp-json/flatcryptopay/v1/webhook. - In the FlatCryptoPay dashboard, open Webhooks, add that URL and copy the signing secret back into the plugin's Webhook signing secret field. Save.
- Place a test order, click Simulate payment on the pay page and confirm the order moves to Processing.
- Switch to a
fcp_live_key when you are ready.
Settings
| Setting | Description |
|---|---|
| Title / Description | What customers see at checkout. |
| API key | fcp_live_ or fcp_test_ key. Stored in your WordPress options. |
| Webhook signing secret | whsec_ secret of the endpoint you created for this store. |
| Invoice expiry | Minutes before an unpaid invoice expires (15 to 10080). |
| Paid order status | Processing (default) or Completed for digital goods. |
| Debug log | Writes to WooCommerce → Status → Logs (keys are never logged). |
Order flow
- At checkout the plugin creates an invoice with the order total, currency and order number, using an idempotency key so retries never duplicate invoices.
- The order is set to Pending payment and the customer is redirected to the pay page.
invoice.processingputs the order On hold with a note;invoice.paidcompletes payment (Processing or Completed) and records the method, network and transaction hash.invoice.expiredorinvoice.canceledcancel the order if it is still pending.
Before changing any order, the plugin re-fetches the invoice from the API and checks the status, amount, currency and order id, so a forged or replayed webhook cannot mark an order paid.
Troubleshooting
- Orders stay pending: check the webhook URL and secret, then use "Send test event" in the dashboard and look at the response code. Security plugins or firewalls sometimes block
/wp-json/requests. - Payment method missing at checkout: your store currency is not supported, or the API key is empty.
- 401 on webhooks: the signing secret in the plugin does not match the endpoint, or your server clock is off by more than 5 minutes.