Browse Plugins

Developer Hooks

The plugin provides action hooks and filter hooks for developers who need to run custom code when events happen or modify plugin behavior.

Action Hooks

These fire after the plugin processes a webhook event. Use them to run custom code – like syncing data to a CRM, sending custom notifications, or updating external systems.

wcls_order_created
wcls_order_refunded
wcls_subscription_created
wcls_subscription_updated
wcls_subscription_cancelled
wcls_subscription_paused
wcls_subscription_unpaused
wcls_subscription_resumed
wcls_subscription_expired
wcls_subscription_payment_success
wcls_subscription_payment_failed
wcls_subscription_payment_recovered
wcls_license_key_created
wcls_license_key_updated

All action hooks receive three parameters: $order (WooCommerce order object), $event_data (Lemon Squeezy event data), and $full_payload (complete webhook payload). The license key hooks receive $order, $license_key (or $event_data), and $event_data.

Filter Hooks

Use these to customize plugin behavior without editing plugin files.

Filter What It Does Default
wcls_button_color Change the checkout button color #7C3AED
wcls_is_available Control when the payment gateway shows up true (when enabled)
wcls_icon Swap the gateway icon shown at checkout Credit card icons
wcls_checkout_expiry_seconds How long checkout URLs stay valid 1800 (30 minutes)
wcls_default_variant_id Set a fallback variant ID when none is configured Empty string