Title: Hosuke for Welcart
Author: kbsrco
Published: <strong>July 17, 2026</strong>
Last modified: July 17, 2026

---

Search plugins

![](https://ps.w.org/hosuke-welcart/assets/banner-772x250.png?rev=3612077)

![](https://ps.w.org/hosuke-welcart/assets/icon-256x256.png?rev=3612077)

# Hosuke for Welcart

 By [kbsrco](https://profiles.wordpress.org/kbsrco/)

[Download](https://downloads.wordpress.org/plugin/hosuke-welcart.0.1.31.zip)

 * [Details](https://wordpress.org/plugins/hosuke-welcart/#description)
 * [Reviews](https://wordpress.org/plugins/hosuke-welcart/#reviews)
 *  [Installation](https://wordpress.org/plugins/hosuke-welcart/#installation)
 * [Development](https://wordpress.org/plugins/hosuke-welcart/#developers)

 [Support](https://wordpress.org/support/plugin/hosuke-welcart/)

## Description

Hosuke is an independent restock notification plugin designed specifically for Welcart
e-Commerce. It is developed by Kobayashi Sharyo Co., Ltd. and is not officially 
affiliated with Welcart Inc.

When a shopper visits a product page whose SKU is currently sold out, Hosuke inserts
a “Notify me when back in stock” button. The shopper enters their email address,
and once the SKU’s stock transitions from 0 back to 1 or more, Hosuke automatically
dispatches a notification email so the shopper can return to buy. Turns sold-out
moments into recovered sales opportunities.

#### Key features

 * SKU-level registration (works with both single-SKU and multi-SKU products)
 * Automatic injection of the notify button next to the Welcart sold-out label via
   the standard `usces_filters_single_sku_zaiko_message` filter
 * Real-time stock change detection on product save
 * 15-minute WP-Cron background scan (catches stock changes made outside the admin
   UI)
 * Three customizable email templates: registration confirmation, restock notification,
   admin alert
 * `[hosuke_restock_list]` shortcode and sidebar widget to display recently restocked
   items
 * Both guest and Welcart-member registration flows (member email auto-fills)
 * Google reCAPTCHA v3 integration for spam protection
 * Per-IP rate limiting on the registration endpoint
 * Send queue with exponential-backoff retry (up to 3 attempts)
 * Automatic cleanup of expired notifications
 * GDPR / Japanese Personal Information Protection Act compliance via the WordPress
   Privacy Tools (Export / Erase)
 * One-click unsubscribe for shoppers (via email link or Welcart my-page)
 * CSV export from the admin panel
 * WP-CLI command: `wp hosuke send-queue`
 * REST API: `POST /wp-json/hosuke/v1/send-queue`, `GET /wp-json/hosuke/v1/restock-
   list`
 * Japanese and English translation files bundled

#### Requirements

 * WordPress 6.0 or higher
 * PHP 7.4 or higher
 * Welcart e-Commerce 2.9 or higher

#### About the author

Hosuke is developed and maintained by [Kobayashi Sharyo Co., Ltd.](https://kbsr.co.jp/?utm_source=hosuke&utm_medium=plugin&utm_campaign=readme)
as part of the kbsr product line for Welcart and WordPress.

Other kbsr products:

 * **Banto for Welcart** — Amazon Pay V2 payment gateway + 5-carrier shipping label
   integration for Welcart (paid)
 * **Bunsuke** — Japanese-focused AI writing assistance plugin for WordPress (paid)

See the [full product lineup](https://kbsr.co.jp/products/?utm_source=hosuke&utm_medium=plugin&utm_campaign=readme)
for details.

### Privacy Policy

Hosuke stores the following personal data:

 * Email address of subscribers
 * Optionally, Welcart member ID (if the subscriber is logged in at registration
   time)
 * Hashed IP address at registration (SHA-256, salted with WP `nonce_salt`)
 * User agent string
 * Timestamps: registration, notification sent, unsubscription

This data is used solely for the purpose of delivering the requested restock notification.

Data is automatically deleted after the configured retention period (default: 90
days after notification, 365 days for unfulfilled registrations).

WordPress Privacy Tools integration is provided for GDPR-style data export and deletion
requests.

### Third-Party Services

Hosuke can optionally integrate with **Google reCAPTCHA v3** for spam protection.

 * When enabled, the reCAPTCHA JavaScript library is loaded on product pages that
   display the notification button.
 * The reCAPTCHA token is sent to Google’s servers for verification.
 * Google’s terms and privacy policy apply: https://policies.google.com/privacy

This integration is off by default and must be explicitly enabled in Settings with
your own site key and secret.

## Installation

 1. Upload the `hosuke-welcart` folder to `/wp-content/plugins/`, or install via the
    Plugins screen in WordPress admin.
 2. Activate the plugin through the “Plugins” menu.
 3. Confirm that Welcart e-Commerce is active. A warning will appear if it is not.
 4. Go to “Hosuke  Settings” in the WordPress admin to configure reCAPTCHA, email templates,
    and other options.

## FAQ

### Is Welcart required?

Yes. Hosuke is designed to work in conjunction with the Welcart e-Commerce plugin.
If Welcart is inactive, a warning is displayed and Hosuke’s own hooks are not registered.

### Can I customize where the notify button appears?

By default, the button is auto-injected next to the Welcart sold-out label via the
standard `usces_filters_single_sku_zaiko_message` filter. You can turn auto-injection
off in the settings and place the button anywhere via the `hosuke_button_html` filter
or other Welcart hooks.

### Will notifications be sent for products that have never been out of stock?

No. The notify button only appears on SKUs that are currently sold out and do not
have “sellable while out of stock” enabled. Even if a shopper somehow registers 
on an in-stock SKU, the notification only fires at the moment stock transitions 
from 0 to 1 or more.

### Does it support multi-SKU products?

Yes. Notifications are managed at the SKU level, not the product level. Each SKU’s
stock is monitored independently.

### What happens when an email delivery fails?

Hosuke retries with exponential backoff, up to 3 times (configurable). If the maximum
retry count is exceeded, the notification is marked as failed and an alert email
is sent to the site administrator.

### Is Hosuke GDPR / Japanese Personal Information Protection Act compliant?

Yes. Hosuke integrates with the standard WordPress Privacy Tools:

 * Shoppers can request an export of their data via “Tools  Export Personal Data”
 * Shoppers can request erasure via “Tools  Erase Personal Data”

Both are keyed by email address. Consent capture at registration time is also configurable(
enabled by default).

### How do I test email delivery?

The “Hosuke  Restock Notifications” admin page has a “Test send” section at the 
bottom that lets you send any template to any address as a preview.

### Emails are not being delivered / go to the spam folder. What should I do?

Hosuke sends all notifications through the standard WordPress `wp_mail()` function.
Whether messages actually reach the inbox depends on your server’s mail configuration
and the DNS records (SPF/DKIM/DMARC) of your sending domain. Both are outside of
Hosuke’s control, so Hosuke cannot guarantee or measure deliverability.

Small operations may work fine with the default configuration, but if you are sending
to Gmail / Outlook / other strict providers, or dozens of messages per day, some
may be flagged as spam or silently discarded on the receiving side.

**Recommended**: install a major SMTP plugin ([WP Mail SMTP](https://wordpress.org/plugins/wp-mail-smtp/)/
[FluentSMTP](https://wordpress.org/plugins/fluent-smtp/) / [Post SMTP](https://wordpress.org/plugins/post-smtp/)
etc.) and connect it to an authenticated sending service (Amazon SES / SendGrid /
Mailgun / Postmark / Google Workspace / Microsoft 365 etc.). SMTP plugins transparently
intercept `wp_mail()` calls and re-send via the authenticated route. No changes 
to Hosuke are required.

Publishing proper SPF / DKIM / DMARC records for your sending domain is also the
single biggest factor determining Gmail deliverability.

### Is there a page where members can see their notification history?

Yes. Logged-in Welcart members can view and manage their notifications at `/?hosuke_my_notifications
=1`. Add a link from the Welcart my-page to this URL (or enable auto-injection in
the settings).

### Is data preserved when the plugin is deactivated?

Yes. Deactivating the plugin does not delete data. Data deletion is opt-in: only
when “Delete all data on uninstall” is enabled in the settings and the plugin is
uninstalled will custom tables and options be removed.

### Where do I get support?

For questions and bug reports, please use the [WordPress.org support forum](https://wordpress.org/support/plugin/hosuke-welcart/)
or the [Kobayashi Sharyo contact form](https://kbsr.co.jp/contact/?src=hosuke).

## Reviews

There are no reviews for this plugin.

## Contributors & Developers

“Hosuke for Welcart” is open source software. The following people have contributed
to this plugin.

Contributors

 *   [ kbsrco ](https://profiles.wordpress.org/kbsrco/)

[Translate “Hosuke for Welcart” into your language.](https://translate.wordpress.org/projects/wp-plugins/hosuke-welcart)

### Interested in development?

[Browse the code](https://plugins.trac.wordpress.org/browser/hosuke-welcart/), check
out the [SVN repository](https://plugins.svn.wordpress.org/hosuke-welcart/), or 
subscribe to the [development log](https://plugins.trac.wordpress.org/log/hosuke-welcart/)
by [RSS](https://plugins.trac.wordpress.org/log/hosuke-welcart/?limit=100&mode=stop_on_copy&format=rss).

## Changelog

#### 0.1.31

 * **Security hardening for legacy Welcart editor observer**: `Stock\ChangeDetector::
   onAdminInitDetectLegacyEditor()` now requires `edit_posts` before it does anything,
   verifies the Welcart `_wpnonce` field is present and valid, and additionally 
   checks `edit_post` for the specific post before scheduling a stock recheck at
   shutdown. The GET-only fallback for reading `post` has been removed, so the observer
   will only ever react to properly authenticated POST submissions from the Welcart
   legacy item editor.

#### 0.1.30

 * **Text Domain aligned with plugin slug**: Renamed the plugin’s text domain from`
   hosuke` to `hosuke-welcart` across all 269 i18n calls, the plugin header, the`
   load_textdomain()` bootstrap, and the language file names (`hosuke-welcart-ja.
   mo/po`, `hosuke-welcart.pot`). Required for translations at translate.wordpress.
   org to associate with the correct plugin slug.
 * **Description translated to English**: The `readme.txt` `== Description ==`, `
   == Installation ==`, `== Frequently Asked Questions ==`, and `== Screenshots 
   ==` sections have been rewritten in English. Japanese translations remain available
   via the bundled `.mo` file and translate.wordpress.org.
 * **Inline scripts converted to `wp_enqueue_script`**: The three inline `<script
   >` blocks in the admin templates editor and the frontend member-notifications
   component have been extracted to dedicated files under `assets/js/` and are now
   loaded via `wp_enqueue_script()`, with translated toast strings passed through`
   wp_localize_script()`.
 * **Sanitization hardening**: `Admin\TemplatesPage::handleSave` now passes the 
   decoded email body through `sanitize_textarea_field( wp_check_invalid_utf8( ...))`
   before saving, so template content is normalized to plain text. `Notification\
   Registrar` now wraps the `HTTP_USER_AGENT` fallback in `sanitize_text_field( 
   wp_unslash( ... ) )` instead of taking the raw server value.
 * **Cross-promo admin notice scoped**: The `Admin\CrossPromoNotice` in-admin notice
   now checks `get_current_screen()->id` and only renders on screens whose id contains`
   hosuke`, preventing the notice from appearing on unrelated admin pages (Guideline
   11 compliance).

#### 0.1.29

 * **Japanese-first documentation**: The plugin file `Description:` header, the `
   readme.txt` short description, and the `== Description ==` / `== Installation
   ==` / `== Frequently Asked Questions ==` / `== Screenshots ==` sections have 
   all been rewritten in Japanese. Welcart is a Japan-only e-commerce plugin, so
   the target audience of 報助 is 100 %% Japanese-speaking; keeping the primary 
   documentation in Japanese matches the audience. The `== Changelog ==` section
   is intentionally left in English for cross-project consistency.
 * **Author name**: Changed the plugin header `Author:` field from the English `
   Kobayashi Sharyo Co., Ltd.` to the Japanese `株式会社小林車輌`, matching the 
   display convention of the sister products `番頭 for Welcart` and `文助 for WordPress`.

#### 0.1.28

 * **Plugin display name**: Switched to the Japanese short form `報助 for Welcart`
   in both the plugin header and the `readme.txt` heading, matching the family branding
   convention shared with `番頭 for Welcart` and `文助 for WordPress` (all sister
   products under `株式会社小林車輌`). The WordPress.org slug remains `hosuke-welcart`.

#### 0.1.27

 * **Plugin Check warnings — critical fixes**: Addressed all Plugin Check warnings
   that WordPress.org reviewers typically flag as blockers:
    - **Plugin name consistency**: Aligned the `Plugin Name:` header in `hosuke.
      php` from the Japanese `報助 - Restock Notify for Welcart` to `Hosuke - Restock
      Notify for Welcart`, matching the `=== Hosuke - Restock Notify for Welcart
      ===` heading in `readme.txt` and the WordPress.org slug `hosuke-welcart`.
    - **`load_plugin_textdomain()` removed** from `Plugin::init()` and `hosuke.php`
      per WordPress 4.6+ automatic language pack loading. The early `load_textdomain()`
      call in `hosuke.php` remains to guarantee Japanese defaults during `register_activation_hook`(
      before `init`).
    - **Input sanitization** for `$_SERVER[REMOTE_ADDR]` in `RateLimiter::currentIp()`
      and `$_SERVER[REQUEST_METHOD]` in `ChangeDetector::onAdminInitDetectLegacyEditor()`—
      now wrapped with `wp_unslash()` + `sanitize_text_field()`.
    - **`TemplatesPage`**: Added a targeted `phpcs:ignore` with justification for
      the multi-field array `$_POST[ $option_key ]` assignment (each field — subject,
      from_name, from_email, body/body_b64 — is sanitized individually downstream).
    - **`NotificationsListTable`**: Added `WordPress.DB.PreparedSQLPlaceholders.
      ReplacementsWrongNumber` to the existing `phpcs:ignore` on the paginated results
      query where the placeholder count in the WHERE clause is dynamic.

#### 0.1.26

 * **Plugin Check compliance**: Resolved all 14 errors flagged by the WordPress.
   org Plugin Check tool as blockers for the initial submission:
    - i18n: Merged three concatenated multi-line email template strings in `Activator.
      php` into single string literals so that translation extractors can pick them
      up (`WordPress.WP.I18n.NonSingularStringLiteralText`).
    - i18n: Added `/* translators: */` comments before three placeholder-bearing`
      __()` calls in `templates-editor.php` and `modal.php` (`WordPress.WP.I18n.
      MissingTranslatorsComment`).
    - Security: Refactored `RestockListWidget::widget()` so the shortcode output
      is captured into a variable before being echoed, allowing the `phpcs:ignore`
      directive to attach cleanly to a single-line `echo` statement (`WordPress.
      Security.EscapeOutput.OutputNotEscaped`).
    - Security: Wrapped exception messages that interpolate user-derived data in`
      MailSender.php` with `esc_html()` in case they surface in error output (`WordPress.
      Security.EscapeOutput.ExceptionNotEscaped`).
    - File I/O: Added targeted `phpcs:ignore` directives with justification comments
      on the `fwrite()` and `fclose()` calls in `CsvExporter.php` that stream to`
      php://output` — `WP_Filesystem` is not applicable to output streams (`WordPress.
      WP.AlternativeFunctions.file_system_operations_fwrite/fclose`).

#### 0.1.25

 * **Meta**: Updated `Contributors:` field in readme.txt from the legacy `kbsr` 
   handle to the new `kbsrco` WordPress.org account created for plugin distribution.

#### 0.1.24

 * **Docs**: Updated the `== Screenshots ==` section descriptions to accurately 
   match the 5 captured screenshots that will be uploaded to the WordPress.org SVN`
   assets/` directory alongside the plugin.

#### 0.1.23

 * **Plugin URI**: Changed the plugin homepage header from `https://kbsr.co.jp/products/`
   to the new dedicated subdomain `https://hosuke.kbsr.co.jp/`. The “プラグインの
   サイトを表示” link on the WordPress plugins list now points there.
 * **Localization**: Status column values in the registrations list and send history(`
   pending` / `queued` / `notified` / `unsubscribed` / `expired` / `failed`) are
   now rendered with their Japanese labels (`登録中` / `送信待ち` / `送信済み` /`
   解除済み` / `期限切れ` / `失敗`) on Japanese sites — previously they showed the
   raw English enum values. The two “default” filter dropdown entries at the top
   of each list are also translated: `登録中/送信待ち (デフォルト)` on the registrations
   list and `送信済/解除/期限切/失敗 (デフォルト)` on the send history.
 * **Sender name / email**: The “From name” and “From email” fields on the Notification
   Emails page are now optional. If left blank, at send time the plugin resolves
   them dynamically — first from Welcart’s own `sender_name` / `sender_mail` settings,
   then from WordPress’s `blogname` / `admin_email`. This means Hosuke automatically
   follows any change site owners make to Welcart’s sender settings, without having
   to re-visit the Notification Emails page. Both fields now show the currently-
   resolved value as a placeholder and a description line (“Leave blank to inherit
   from Welcart / WordPress. Currently resolves to: …”) so operators can see at 
   a glance what will be used.

#### 0.1.22

 * **Localization fix**: The “invalid unsubscribe link” error message on the notify-
   off page was rendering the English source text (“This unsubscribe link is no 
   longer valid. It may have already been processed…”) because that specific string
   was missing from the Japanese `.po`. The Japanese-locale rendering now reads「
   この解除リンクは有効ではありません。既に解除済みか、通知データが削除されている
   可能性があります。」consistent with the surrounding “解除できませんでした” title.

#### 0.1.21

 * **My-page table now matches Welcart cart exactly**. The v0.1.20 table used generic
   dark-header styling I had picked from memory; the actual Welcart Basic cart uses
   a light-gray header (`#efefef`), a dotted table border (`1px dotted #ccc`), 5px
   cell padding, and 14px cells. Those computed styles are now applied verbatim 
   so the “登録中の再入荷通知” table is visually indistinguishable from `/usces-
   cart/`.
 * **Cart-style columns**: added thumbnail (48×48, WordPress featured image with
   Welcart Basic `crystal/default.svg` fallback), item name, and unit price (via
   Welcart’s `usces_crform()` for correct currency formatting). Columns now are `
   No. / thumbnail / 商品 / 価格 / ステータス / 解除`, using the same semantic HTML
   classes as Welcart (`num` / `thumbnail` / `productname` / `unitprice` / `stock`/`
   action`) plus the `aleft` / `aright` alignment classes, so custom child themes
   that already style the cart will style this table too.
 * **Extensibility**: the outer `hosuke-my-notifications__*` classes are preserved
   on the section, heading, table and status/action elements so site owners can 
   layer their own CSS on top without touching Welcart theme files.

#### 0.1.20

 * **Fix: my-page notification list rendered without styles.** The frontend stylesheet
   is only registered by the product-page `Assets` class, so on the Welcart my-page
   it was neither registered nor enqueued in v0.1.16-v0.1.19 — the injected section
   fell back to unstyled default browser layout. `MemberNotifications::maybeEnqueueMountStyles()`
   now `wp_register_style()` + `wp_enqueue_style()` the frontend CSS itself when
   it detects the Welcart my-page, so the section renders with the intended dark-
   header table styling regardless of what else is loaded on the page.
 * **Heading now matches Welcart 購入履歴**: the section heading is now `<h3>` (
   was `<h2>`), styled to Welcart Basic’s h3 spec — `font-size: 14px`, `font-weight:
   700`, `border-bottom: 1px solid #ccc`, `margin: 30px 0 20px`. It sits at the 
   same visual level as 購入履歴 and 会員情報編集.

#### 0.1.19

 * **Fix: button label was still `入荷したら通知を受け取る` on the settings screen
   after upgrading to v0.1.18.** The button-label migration was only wired to fire
   for installations upgrading from before v0.1.11 — anyone who was already on v0.1.11
   through v0.1.17 (with the old Japanese default persisted in `wp_options`) never
   ran it. The check now also runs as part of the v0.1.19 template-refresh migration,
   so anyone upgrading to this release picks up the new default `再入荷お知らせ通知`.
   Custom labels are still preserved.
 * **Fix: restock email body contradicted the plugin’s actual behavior.** The v0.1.18
   default body contained a mixed-model line that said “本商品のご購入後も、再入荷
   お知らせメールは自動配信されます” (implying a continuous / re-arm-until-cancelled
   model), which is not how Hosuke actually works. Hosuke fires exactly once per
   registration and then marks the notification as sent. The body has been corrected
   to `一度の入荷につき、お知らせメールは1回の配信となります。その後も配信をご希望
   の場合は、再度商品ページからお知らせのご登録をお願いいたします。` — this matches
   what the plugin actually does. The upgrade migration detects the short-lived 
   v0.1.18 body via marker and replaces it.

#### 0.1.18

 * **Button label**: Default frontend label is now `再入荷お知らせ通知` (was `入荷
   したら通知を受け取る`). On upgrade, sites whose stored label matches either of
   the two previous defaults (`Notify me when back in stock` or `入荷したら通知を
   受け取る`) are migrated to the new default. Custom labels are preserved.
 * **Admin sidebar**: Sub-menu item renamed from `通知メール` to `再入荷通知` to
   align with the “再入荷通知” terminology used across the plugin. The English label
   remains `Notification Emails`.
 * **Email defaults refreshed**: Default subject lines and body copy have been rewritten
   in the format commonly used by mainstream Japanese e-commerce stores. New subjects
   are `[shop_name] 再入荷お知らせメールを受付ました` for the registration confirmation,
   and `[shop_name] 再入荷のお知らせ - {item_name}` for the restock notification.
   Bodies use the ◇/■/* section markers, structured product-detail block, and standard
   disclaimer copy that Japanese shoppers already recognize. An upgrade migration
   replaces stored defaults from any earlier version (English v0.1.0–v0.1.10, Japanese
   v0.1.10–v0.1.17) with the new copy, based on marker phrases in the body. Edited
   templates are left untouched.
 * **My-page notification list**: Redesigned as a Welcart cart-style table (`No /
   Item / SKU / Status / Unsubscribe` columns, dark `#333` header row, bordered 
   cells, orange-outline unsubscribe button) to visually match `/usces-cart/` and
   the purchase history table on `/usces-member/`. Mobile viewports collapse to 
   a single-column card layout automatically.

#### 0.1.17

 * **Fix: Welcart my-page auto-injection now actually works.** v0.1.16 relied on`
   the_content` and a handful of Welcart action hooks (`usces_action_member_completion`
   etc.), none of which fire on Welcart Basic — the theme calls `usces_member()`
   directly from `page-uscesmember.php` and never routes through `the_content()`.
   This release adds a `wp_footer`-based fallback that server-renders the notifications
   HTML into a hidden container and then a small inline script moves it to the end
   of `#wc_member` / `#memberpages` / `.member-page` (whichever it finds first).
   Works on Welcart Basic, custom themes, and older/newer Welcart versions equally.
   The three earlier injection paths are kept in place — the shared `static` flag
   prevents duplicate rendering if any of them also fire.
 * Frontend stylesheet (`hosuke-frontend`) is now force-enqueued on the Welcart 
   my-page whenever the notifications section renders there — the my-page normally
   does not enqueue product-page assets, which meant the injected section could 
   render unstyled in v0.1.16.

#### 0.1.16

 * **Welcart my-page integration**: Registered members now see their active restock
   notifications directly on the Welcart my-page (`/usces-member/`). Each row shows
   the item title, SKU code, current status (Awaiting restock / Sending / Sent),
   and a one-click Unsubscribe link. This uses the same repository as the existing`?
   hosuke_my_notifications=1` view, so member unsubscribe tokens continue to work.
 * Auto-injection is on by default and can be turned off from Settings  Basic  “
   Show notifications on Welcart my-page”. Even when off, site owners can place 
   the list anywhere via the new `[hosuke_my_notifications]` shortcode.
 * The auto-injection routes through `the_content` (works with any theme that renders
   the member page through `the_content()`) plus a set of Welcart action hooks (`
   usces_action_member_completion`, `usces_action_member_form`, `usces_action_member_page_bottom`)
   so themes that expose those hooks work equally well. A per-request flag prevents
   duplicate rendering even if multiple routes fire.

#### 0.1.15

 * **About page**: Bunsuke card description is now translated to Japanese (was left
   in English in 0.1.14). Primary CTA button renamed from `View all kbsr products`
   to `View all products` / 「全プロダクトを見る」. Button text inside cards is 
   now horizontally centered (previously left-aligned because of the default WP `.
   button` `text-align: start`).
 * **Unsubscribe page**: All page copy is now properly localized for Japanese sites(
   previously the h1 title and the “click the link in the email” description rendered
   as English). The page title stored in `wp_posts.post_title` is auto-migrated 
   from `Restock Notifications` to `通知の解除` on Japanese sites — customized page
   titles are preserved.
 * **Unsubscribe page slug**: renamed the default slug from `hosuke-unsubscribe`
   to `notify-off` (shorter, action-oriented, no plugin-name prefix). The migration
   renames the existing page in place. Old sent emails still work — the redirect
   handler already sends any request that includes an `?hosuke_unsubscribe=TOKEN`
   query string to the current page permalink via a 302, so old email links from
   before the rename resolve correctly.
 * Added a `hosuke_unsubscribe_page_slug` filter so site owners can override the
   slug if `notify-off` conflicts with another page.

#### 0.1.14

 * **About page**: Renamed the cross-promo section title from `Other products by
   kbsr` to `Related products` for a shorter, less self-referential heading. The
   subtitle now reads `More tools from the same team, for Welcart stores and WordPress-
   powered sites.` Japanese translations added.
 * **About page**: Reduced product card size to roughly half. The grid now caps 
   each card at 260px wide (previously stretched full width when only two cards 
   were present), with tighter padding, smaller heading, and lighter button. Cards
   now line up compactly rather than dominating the page.

#### 0.1.13

 * **Docs**: Added an FAQ entry on email deliverability. Hosuke sends through the
   standard `wp_mail()` and cannot guarantee inbox delivery on its own. The FAQ 
   now recommends installing an SMTP plugin (WP Mail SMTP, FluentSMTP, Post SMTP,
   etc.) connected to an authenticated sending service, and reminds site operators
   to publish correct SPF, DKIM and DMARC records. This mirrors the guidance given
   by the official WooCommerce Back In Stock Notifications extension and matches
   accepted practice for automated store notifications.
 * **Metadata**: Bumped `Tested up to` to 7.0 (previous: 6.7) to reflect the currently
   supported WordPress line. `Requires at least` remains 6.0.

#### 0.1.12

 * **Notify button visual redesign**: The frontend notify button now inherits Welcart
   cart-button sizing (font-size 14px, padding 15px 24px, 3px radius, 1px letter-
   spacing, uppercase-ish CTA weight) and adds `.skubutton` alongside `.hosuke-notify-
   button` so themes that style the cart button will pick this one up too. Visually
   it is an outline pattern (transparent fill, orange border and label) that inverts
   to solid orange on hover, matching the cart button color exactly while remaining
   distinguishable from it. A small bell icon (inline SVG) sits at the left to signal“
   email notification”.

#### 0.1.11

 * **UX**: The default frontend button label “Notify me when back in stock” is now
   localized. Existing Japanese-locale sites that had the English default persisted
   in the database will be migrated to `入荷したら通知を受け取る` on upgrade (customized
   labels are preserved).
 * **About page**: Fixed dead cross-promotion links — Banto now points to `https://
   banto.kbsr.co.jp/` and Bunsuke to `https://bunsuke.kbsr.co.jp/` (previous URLs
   404’d).
 * **About page**: Added dark, minimal SVG thumbnails for each cross-promoted product,
   matching the tone of the actual product landing pages. Cards now have a hover
   elevation effect.

#### 0.1.10

 * **Bug fix: variable buttons no longer insert into the first Subject field when
   nothing is focused.** The JavaScript initializer was pre-seeding the “last focused”
   tracker to the first Subject field on page load, so clicking a variable badge
   without ever focusing anywhere inserted into `hosuke_templates_registration[subject]`.
   This has been removed — the tracker now only updates on genuine focus events.
   If no field has been focused, the variable is copied to the clipboard as documented.
 * **Bug fix: existing Japanese sites now get Japanese template defaults on upgrade.**
   Two problems combined to leave defaults in English: (a) WordPress 6.7+ defers`
   load_plugin_textdomain()` until `init` when called earlier, so `__()` during 
   activation returned the source (English) string; and (b) `add_option()` never
   overwrites existing values, so v0.1.3  v0.1.9 sites retained the English defaults
   even after we fixed the loading. This release loads the `.mo` file directly via`
   load_textdomain()` at plugin file load (bypassing the 6.7 deferral), and adds
   an upgrade migration that replaces English defaults with the current locale’s
   translations if — and only if — the current template exactly matches the known
   English default (customized templates are never touched). Japanese translations
   for all three template bodies (registration confirmation, restock notification,
   admin alert) have been added to `hosuke-ja.mo`.

#### 0.1.9

 * Admin UX improvements based on feedback:
 * **Notification Emails** (renamed from “Email Templates”): “Available variables”
   now shows as clickable buttons that insert the variable at the cursor position
   in the last focused Subject or Body field, with a Japanese description on each
   button. If no field is focused it falls back to copying the variable to the clipboard,
   with a toast confirmation.
 * **Settings**: Reorganized into a Basic / Advanced tab pattern. Basic tab shows
   General, Privacy, reCAPTCHA and Restock list page settings that most stores adjust.
   Advanced tab shows retry/queue tuning, retention days, spam thresholds, and uninstall
   behaviour that rarely need touching.
 * **Sidebar menu**: renamed the “メールテンプレ” item to “通知メール” (Notification
   Emails) for a more consistent, business-oriented label.
 * **Japanese defaults**: `load_plugin_textdomain()` is now called synchronously
   in the plugin bootstrap and inside the activation hook, so `__()` resolves to
   Japanese during `Activator::seedOptions()`. Sites with Japanese locale now get
   Japanese default email subjects and bodies out of the box, while other locales
   stay with the English defaults.

#### 0.1.8

 * Added a defensive `admin_init` fallback that scans all SKUs with pending notifications
   and reverifies them at shutdown of every admin request. This guarantees restock
   detection even if the `updated_post_meta` hook fails to fire for any reason (
   direct SQL, cache-only writes, etc.).
 * Added unconditional diagnostic logging via `error_log`: each `processSku` call
   now logs `post_id`, `sku`, `new_stock`, `prev_stock`, `is_restock` decision, 
   and pending notification count. The shutdown handler also logs which post_ids
   it is checking.

#### 0.1.7

 * Redesigned stock change detection to be transport-agnostic. Previously v0.1.2
   v0.1.6 tried to identify each Welcart save mechanism (`save_post`, `usces_action_save_product`,`
   admin.php?page=usces_itemedit` POST, `wp_ajax_item_sku_ajax`, etc.) and hook 
   into each one individually. Every one of these paths ends in a postmeta write,
   so this release hooks `updated_post_meta`, `added_post_meta`, and `deleted_post_meta`
   instead — capturing the change once, at the moment the write actually lands, 
   regardless of which surface triggered it. The captured post IDs are then re-checked
   at `shutdown` (fastcgi_finish_request first, so admin UX is unaffected). Non-
   Welcart posts pass through `isWelcartItem()` and are ignored, so this broad hook
   has no side effects.

#### 0.1.6

 * Corrected the AJAX action name used to detect per-SKU stock changes from the 
   Welcart legacy product editor. v0.1.5 hooked `wp_ajax_updateitemsku` / `additemsku`/`
   deleteitemsku` based on the sub-command passed to `itemSku.post()`, but the actual
   WordPress AJAX action name is `item_sku_ajax` (the sub-command is only a body
   parameter). Confirmed by intercepting the actual XHR request. The hook is now`
   wp_ajax_item_sku_ajax` at priority 1 (so it runs before Welcart’s handler calls`
   wp_die()`).

#### 0.1.5

 * Restock detection now fires reliably from the Welcart legacy product editor’s
   per-SKU update button. Investigation revealed that the per-SKU “更新” button 
   is a non-submit `<input type="button">` that triggers an AJAX call (`admin-ajax.
   php?action=updateitemsku`), not a form POST to `admin.php?page=usces_itemedit`.
   The v0.1.2/v0.1.4 detection hooks were missing this path entirely, so stock changes
   made from that button were only picked up 15 minutes later by the periodic scanner.
   This release adds hooks for `wp_ajax_updateitemsku`, `wp_ajax_additemsku`, and`
   wp_ajax_deleteitemsku`, so per-SKU stock changes are detected within seconds 
   instead of up to 15 minutes.

#### 0.1.4

 * Upgrade migrations now also run on plugin file replacement (in addition to explicit
   reactivation). Previously the v0.1.3 email template migration required the site
   owner to deactivate and reactivate the plugin, which many installations did not
   do. As a result, sites upgrading from v0.1.2 could remain on the old, spam-prone
   default subject/body. The migration now fires automatically via `admin_init` 
   when `hosuke_db_version` is behind the current release.
 * Mail sending now writes unconditional log entries (`error_log`) for every `wp_mail()`
   call — both the return value (TRUE/FALSE) and the subject line. In addition, `
   wp_mail_failed` errors from PHPMailer (SMTP errors, invalid addresses, etc.) 
   are captured and logged with the raw error data. This makes deliverability triage
   possible without turning on `WP_DEBUG`.

#### 0.1.3

 * Email deliverability improvements for the restock notification:
    - Added `List-Unsubscribe` and `List-Unsubscribe-Post: List-Unsubscribe=One-
      Click` headers (RFC 2369, RFC 8058). Gmail specifically favors messages with
      these headers and delivers them to the inbox at a much higher rate than automated
      mail without them.
    - Added `Auto-Submitted: auto-generated` header (RFC 3834) to declare the message
      is machine-generated, which reduces spam scoring and suppresses vacation-reply
      loops.
    - Default restock subject changed from `[shop] {item_name} is back in stock!`
      to `[shop] {item_name} is available again` (removed the exclamation mark and
      the “back in stock” phrase, both of which are strong spam-filter signals).
    - Default restock body reworded to remove promotional urgency phrases (“Good
      news!”, “stock is limited”, “sell out again quickly”) that measurably increase
      spam classification at Gmail/Outlook.
 * Upgrade migration: existing installations whose restock template still contains
   the v0.1.2 defaults are automatically updated to the new copy. Customized templates
   are left untouched.

#### 0.1.2

 * Unsubscribe page now uses a dedicated auto-created page (`/hosuke-unsubscribe/`)
   with the shortcode `[hosuke_unsubscribe]`, so it renders inside the theme’s normal`
   page.php` template — no more front-page hero visuals leaking into the unsubscribe
   view. Existing unsubscribe URLs in previously sent emails are automatically 302-
   redirected to the new page for backward compatibility.
 * Stock changes made from the Welcart legacy product editor (`admin.php?page=usces_itemedit`,
   including the per-SKU update button) are now detected and trigger restock notifications.
   This closes a gap where SKU-only meta updates bypassed the standard `save_post`
   hook.
 * Deferred SKU meta checks: SKU meta filters are now evaluated at `shutdown` (after
   all meta writes complete) so the stock snapshot reads the fresh value rather 
   than the pre-save value.
 * Admin “Registrations” list now links the product column to the Welcart product
   editor instead of the Gutenberg block editor.
 * Improved messaging on invalid/expired unsubscribe tokens.

#### 0.1.1

 * Restock notifications are now sent immediately when stock is restored (previously
   waited up to 5 minutes for the next cron tick).
 * WP-Cron self-heal: send queue is re-scheduled automatically if the event was 
   lost due to site migration or deactivation.
 * Notify button and modal submit now use the Welcart Basic orange to match the 
   theme. Colors can be overridden via the `--hosuke-primary` CSS custom property.
 * Unsubscribe page redesigned as a centered card with clearer status icon, item
   details, and call-to-action button.
 * Frontend CSS is now loaded on the unsubscribe page (previously only on product
   pages).

#### 0.1.0

 * Initial release.

## Meta

 *  Version **0.1.31**
 *  Last updated **1 day ago**
 *  Active installations **Fewer than 10**
 *  WordPress version ** 6.0 or higher **
 *  Tested up to **7.0.2**
 *  PHP version ** 7.4 or higher **
 * Tags
 * [ec](https://wordpress.org/plugins/tags/ec/)[ecommerce](https://wordpress.org/plugins/tags/ecommerce/)
   [notification](https://wordpress.org/plugins/tags/notification/)[restock](https://wordpress.org/plugins/tags/restock/)
   [Welcart](https://wordpress.org/plugins/tags/welcart/)
 *  [Advanced View](https://wordpress.org/plugins/hosuke-welcart/advanced/)

## Ratings

No reviews have been submitted yet.

[Your review](https://wordpress.org/support/plugin/hosuke-welcart/reviews/#new-post)

[See all reviews](https://wordpress.org/support/plugin/hosuke-welcart/reviews/)

## Contributors

 *   [ kbsrco ](https://profiles.wordpress.org/kbsrco/)

## Support

Got something to say? Need help?

 [View support forum](https://wordpress.org/support/plugin/hosuke-welcart/)