Skip to content

v0.4.0

Choose a tag to compare

@github-actions github-actions released this 21 Jul 23:56
b195e36

Square Terminal for WooCommerce 0.4.0

This release makes Terminal setup visible: you can now see which readers Square knows about, and why one might not be selectable.

Added

Check for readers

The gateway settings screen has a Check for readers button that lists, separately:

  • Paired with this plugin — Terminals paired through this plugin's own Device Codes. These are the ones selectable at checkout.
  • Other Terminals on this Square account — Terminals Square can see that were paired elsewhere, for example through the Square dashboard or the Square POS app.

The distinction matters. Terminal API Device Codes belong to the application that created them, so a Terminal paired outside this plugin is real, online, and still not usable for checkouts here until it is paired with Create Device Code. Previously that situation produced an empty selector with no explanation.

Pre-filled setup from the official Square plugin

If the official WooCommerce Square plugin is configured, Environment and Location ID are pre-filled from it, so the same values do not have to be looked up twice.

Only those two non-secret values are read. Access and refresh tokens are never read, copied, stored, or logged; the two plugins keep entirely separate Square connections, and the field description says so. Values populate the form and are not stored until you press Save changes — a value you have already saved always wins.

Fixed

  • Device discovery now logs every outcome, not just failures. Skipped (no location or token), served from cache, or completed with a count — each writes a line. A check that ran and found nothing used to look exactly like a check that never ran, which is what made an empty device selector so hard to diagnose.

Upgrade notes

  • No settings changes required.
  • If your Terminal was paired through the Square dashboard rather than this plugin, use Check for readers to confirm Square can see it, then Create Device Code and enter the code on the Terminal to make it selectable at checkout.
  • Requires PHP 8.1+, WordPress 6.5+, and WooCommerce 8.0+.

Verification status

  • Observed: composer lint 20/20, composer test 173 tests / 647 assertions, composer test:js 26/26.
  • Observed: both reader lookups run against Square's live Sandbox API without error and return correctly empty results for an account with no hardware.
  • Not verified: rendering of a populated reader list against real hardware, and the pre-filled fields as displayed in a browser. The sandbox account has no Terminals, so a populated list is covered by unit tests only.