Skip to content
Docs
Get RestroPress

Coinbase Commerce Payment Gateway

Updated 2 min read
On this page

RestroPress Coinbase Commerce Payment Gateway adds a Coinbase Commerce option to checkout. The customer is sent to a Coinbase-hosted payment page to pay, then returned to your site. The plugin is a small first version (about 260 lines of code) and has limited order handling, described below.

Requirements#

  • RestroPress (no minimum version is declared in the plugin).
  • A Coinbase Commerce account and an API key.

Installation#

  1. Go to Plugins › Add New › Upload Plugin, upload the ZIP, install and activate.
  2. Go to RestroPress › Settings › Payment Gateways, enable Coinbase Commerce and save.
  3. Open the Coinbase Commerce section and enter your API key.

There is no licence key field in this plugin.

The Coinbase Commerce section of the payment gateway settings

Settings#

Found under RestroPress › Settings › Payment Gateways › Coinbase Commerce.

SettingWhat it doesDefault
API KeyYour Coinbase Commerce API key, sent in the X-CC-Api-Key header. Checkout shows "Coinbase Commerce configuration is incomplete." if empty.Empty
Test ModeCheckbox, "Enable test mode for Coinbase Commerce." The code reads this option but does not use it: the same API address is called either way.Unchecked

How it works#

  1. The customer picks Coinbase Commerce. No card form is shown.
  2. On placing the order, RestroPress creates a pending order and the plugin creates a fixed-price charge on Coinbase Commerce for the order total in the store currency, with the order number in the charge metadata.
  3. The customer is redirected to the hosted payment page returned by Coinbase. A cancel link points back to your checkout page.
  4. After paying, Coinbase sends the customer to ?rpress-listener=coinbase_commerce on your site. The plugin then looks up the order from an order_id query parameter, marks it complete, empties the cart and redirects to the success page.

Important limits visible in the code: the plugin does not receive Coinbase webhooks and does not ask Coinbase whether the charge was paid. This early version does not yet confirm payments with Coinbase, so do not use it for live payments. Treat this extension as incomplete and test it fully before relying on it. Refunds are not implemented.

Troubleshooting#

  • "Payment gateway error." at checkout: the Coinbase API call failed or did not return a hosted URL. With WP_DEBUG on, details are written to the PHP error log with the prefix [RPRESS Coinbase Commerce].
  • "Invalid response from Coinbase Commerce" after paying: the return request had no order_id parameter.
  • "Payment not found": the order_id did not match an order.

Changelog highlights#

The plugin ships no readme changelog. Plugin header version: 1.0.0.

Was this page helpful?