<?php
declare(strict_types=1);

if ( ! defined( 'ABSPATH' ) ) {
	exit;
}

class BotBlockerPaymentData {

	public static function getPaths(): array {
		return array(
			'/wc-api/',
			'/wc-ajax/',
			'/wp-json/wc/',
			'/wp-json/wc-',
			'/wp-json/edd/',
			'/wp-json/edd-',
			'/wp-json/easy-digital-downloads/',
			'/wp-json/give-api/',
			'/wp-json/givewp/',
			'/wp-json/give/',
			'/wp-json/wpe-',
			'/wp-json/restrict-content-pro/',
			'/wp-json/restrict-content/',
			'/wp-json/rcp/',
			'/wp-json/memberpress/',
			'/wp-json/mepr/',
			'/wp-json/mp/',
			'/wp-json/paid-memberships-pro/',
			'/wp-json/paidmembershipspro/',
			'/wp-json/pmpro/',
			'/wp-json/surecart/',
			'/wp-json/jigoshop/',
			'/wp-json/shopp/',
			'/wp-json/ecwid/',
			'/wp-json/stripe/',
			'/wp-json/wc-stripe/',
			'/wp-json/paypal/',
			'/wp-json/wc-paypal/',
			'/wp-json/mollie/',
			'/wp-json/wc-mollie/',
			'/wp-json/adyen/',
			'/wp-json/braintree/',
			'/wp-json/square/',
			'/wp-json/razorpay/',
			'/wp-json/yookassa/',
			'/wp-json/tinkoff/',
			'/wp-json/cloudpayments/',
			'/wp-json/robokassa/',
			'/wp-json/sberbank/',
			'/wp-json/wayforpay/',
			'/wp-json/liqpay/',
			'/wp-json/fondy/',
			'/wp-json/payu/',
			'/wp-json/wepay/',
			'/wp-json/authorize-net/',
			'/wp-json/authorizenet/',
			'/wp-json/authnet/',
			'/wp-json/2checkout/',
			'/wp-json/2co/',
			'/wp-json/twocheckout/',
			'/wp-json/payment/',
			'/wp-json/payments/',
			'/wp-json/webhook/',
			'/wp-json/webhooks/',
			'/wp-json/ipn/',
			'/wp-json/notifications/',
			'/wp-json/payment-gateway/',
			'/wp-json/easydigitaldownloads/',
			'/wp-json/woocommerce-subscriptions/',
			'/wp-json/wcs/',
			'/wp-json/wc-subscriptions/',
			'/wp-json/yith-wcsbs/',
			'/wp-json/yith-paypal-payouts/',
			'/wp-json/dokan/',
			'/wp-json/wcfm/',
			'/wp-json/wc-vendors/',
			'/wp-json/funnelkit/',
			'/wp-json/cartflows/',
			'/wp-json/wc-piriform/',
			'/wp-json/contact-form-7/',
			'/wp-json/formidable/',
			'/wp-json/wpforms/',
			'/wp-json/gf/',
			'/wp-json/ninja-forms/',
			'/wp-json/forminator/',
			'/wp-json/fluentform/',
			'/wp-json/checkout/',
			'/wp-json/revolut/',
			'/wp-json/wcpay/',
			'/wp-json/woocommerce-payments/',
			'/wp-json/checkout-com/',
			'/wp-json/checkoutcom/',
			'/wp-json/cko/',
			'/wp-json/mercadopago/',
			'/wp-json/mercado-pago/',
			'/wp-json/payfast/',
			'/wp-json/paygate/',
			'/wp-json/paytm/',
			'/wp-json/cashfree/',
			'/wp-json/instamojo/',
			'/wp-json/ccavenue/',
			'/wp-json/billdesk/',
			'/wp-json/omise/',
			'/wp-json/xendit/',
			'/wp-json/midtrans/',
			'/wp-json/doku/',
			'/wp-json/hitpay/',
			'/wp-json/paymongo/',
			'/wp-json/dragonpay/',
			'/wp-json/pesapal/',
			'/wp-json/mpesa/',
			'/wp-json/safaricom/',
			'/wp-json/dpo/',
			'/wp-json/dpopay/',
			'/wp-json/yoco/',
			'/wp-json/ozow/',
			'/wp-json/multisafepay/',
			'/wp-json/buckaroo/',
			'/wp-json/paynl/',
			'/wp-json/pay-nl/',
			'/wp-json/paytrail/',
			'/wp-json/przelewy24/',
			'/wp-json/p24/',
			'/wp-json/redsys/',
			'/wp-json/bizum/',
			'/wp-json/nexi/',
			'/wp-json/satispay/',
			'/wp-json/viva-wallet/',
			'/wp-json/vivawallet/',
			'/wp-json/unzer/',
			'/wp-json/heidelpay/',
			'/wp-json/worldline/',
			'/wp-json/ingenico/',
			'/wp-json/ogone/',
			'/wp-json/moneris/',
			'/wp-json/elavon/',
			'/wp-json/converge/',
			'/wp-json/global-payments/',
			'/wp-json/globalpayments/',
			'/wp-json/first-data/',
			'/wp-json/firstdata/',
			'/wp-json/cybersource/',
			'/wp-json/bambora/',
			'/wp-json/opayo/',
			'/wp-json/sagepay/',
			'/wp-json/coinbase-commerce/',
			'/wp-json/coinbase/',
			'/wp-json/coinpayments/',
			'/wp-json/bitpay/',
			'/wp-json/crypto-com/',
			'/wp-json/cryptocom/',
			'/wp-json/nowpayments/',
			'/wp-json/opennode/',
			'/wp-json/open-node/',
			'/wp-json/alipay/',
			'/wp-json/wechatpay/',
			'/wp-json/wechat-pay/',
			'/wp-json/dlocal/',
			'/wp-json/paysera/',
			'/wp-json/payrexx/',
			'/wp-json/trustly/',
			'/wp-json/klarna/',
			'/wp-json/paystack/',
			'/wp-json/flutterwave/',
			'/wp-json/gocardless/',
			'/wp-json/paddle/',
			'/wp-json/eway/',
			'/wp-json/worldpay/',
			'/wp-json/afterpay/',
			'/wp-json/clearpay/',
			'/wp-json/sezzle/',
			'/wp-json/affirm/',
			'/wp-json/iyzico/',
			'/wp-json/ipay/',
			'/wp-json/amazon-pay/',
			'/wp-json/amazon-payments/',
			'/wp-json/apple-pay/',
			'/wp-json/google-pay/',
			'/wp-json/samsung-pay/',
			'/wp-json/mir-pay/',
			'/wp-json/qiwi/',
			'/wp-json/webmoney/',
			'/wp-json/yandex-money/',
			'/wp-json/yandex-kassa/',
			'/wp-json/yoomoney/',
			'paypal-ipn-listener',
			'paypal_ipn_listener',
			'ppec-paypal-listener',
			'ipn-listener',
			'paypal-listener',
			'gf_paypal_ipn',
			'gf_stripe_webhook',
			'gravityformsstripe',
			'gravityformspaypal',
			'gravityformssquare',
			'gravityformsmollie',
			'gravityformsauthorizenet',
		);
	}

	public static function getQueryKeys(): array {
		return array(
			'wc-api',
			'wc-ajax',
			'edd-api',
			'edd-listener',
			'edd_action',
			'sandbox_payment',
			'give-listener',
			'give_listener',
			'give-action',
			'give-api',
			'givewp-listener',
			'givewp_listener',
			'givewp-webhook',
			'givewp_webhook',
			'mepr-listener',
			'mepr_listener',
			'mepr-txn-num',
			'mepr_transaction_id',
			'mepr_ipn',
			'mepr_gateway',
			'memberpress-listener',
			'rcp-listener',
			'rcp_listener',
			'rcp_gateway',
			'pmpro_action',
			'pmpro-listener',
			'pmpro_listener',
			'pmpro_ipn',
			'gf_page',
			'wcb_listener',
			'wcs-listener',
			'callback_handler',
			'jigoshop_action',
			'shopp_xco',
			'sc_action',
			'surecart-webhook',
			'surecart_webhook',
			'ecwid_callback',
			'cardpay_listener',
			'paypal_ipn',
			'paypal-ipn',
			'paypal-ipn-listener',
			'paypal_ipn_listener',
			'paypal_listener',
			'paypal_action',
			'ppec-paypal-listener',
			'stripe_webhook',
			'stripe_listener',
			'mollie_webhook',
			'mollie_return',
			'adyen_webhook',
			'adyen_notification',
			'braintree_webhook',
			'square_webhook',
			'razorpay_webhook',
			'yookassa_callback',
			'yookassa_notify',
			'tinkoff_callback',
			'tinkoff_notification',
			'cloudpayments_callback',
			'cloudpayments_check',
			'cloudpayments_pay',
			'robokassa_result',
			'robokassa_success',
			'robokassa_fail',
			'sberbank_callback',
			'wayforpay_callback',
			'wayforpay_service',
			'liqpay_callback',
			'fondy_callback',
			'payu_callback',
			'wepay_ipn',
			'authnet_silent_post',
			'authnet_webhook',
			'authorize_net_silent_post',
			'authorize_net_webhook',
			'2checkout_ins',
			'2checkout_webhook',
			'2co_ins',
			'2co_webhook',
			'twocheckout_ins',
			'twocheckout_webhook',
			'revolut_webhook',
			'revolut_callback',
			'wcpay_webhook',
			'woocommerce_payments_webhook',
			'checkoutcom_webhook',
			'checkout_com_webhook',
			'cko_webhook',
			'mercadopago_webhook',
			'mercadopago_ipn',
			'mercado_pago_webhook',
			'mercado_pago_ipn',
			'payfast_itn',
			'payfast_notify',
			'payfast_webhook',
			'paygate_notify',
			'paygate_callback',
			'paytm_callback',
			'paytm_webhook',
			'cashfree_webhook',
			'cashfree_callback',
			'instamojo_webhook',
			'instamojo_callback',
			'ccavenue_response',
			'ccavenue_callback',
			'billdesk_response',
			'billdesk_callback',
			'omise_webhook',
			'xendit_webhook',
			'xendit_callback',
			'midtrans_notification',
			'midtrans_callback',
			'doku_notify',
			'doku_callback',
			'hitpay_webhook',
			'hitpay_callback',
			'paymongo_webhook',
			'paymongo_callback',
			'dragonpay_callback',
			'dragonpay_postback',
			'pesapal_notification',
			'pesapal_callback',
			'mpesa_callback',
			'safaricom_callback',
			'dpo_callback',
			'dpopay_callback',
			'yoco_webhook',
			'yoco_callback',
			'ozow_notify',
			'ozow_callback',
			'multisafepay_notify',
			'multisafepay_webhook',
			'buckaroo_push',
			'buckaroo_webhook',
			'paynl_notify',
			'paynl_webhook',
			'paytrail_callback',
			'paytrail_webhook',
			'p24_callback',
			'przelewy24_callback',
			'przelewy24_notification',
			'redsys_notification',
			'redsys_callback',
			'bizum_notification',
			'bizum_callback',
			'nexi_notify',
			'nexi_callback',
			'satispay_webhook',
			'vivawallet_webhook',
			'viva_wallet_webhook',
			'unzer_webhook',
			'heidelpay_webhook',
			'worldline_webhook',
			'worldline_callback',
			'ingenico_webhook',
			'ogone_callback',
			'moneris_callback',
			'elavon_callback',
			'converge_callback',
			'globalpayments_webhook',
			'global_payments_webhook',
			'firstdata_webhook',
			'first_data_webhook',
			'cybersource_webhook',
			'bambora_webhook',
			'opayo_callback',
			'opayo_notification',
			'sagepay_callback',
			'coinbase_commerce_webhook',
			'coinbase_webhook',
			'coinpayments_ipn',
			'bitpay_ipn',
			'cryptocom_webhook',
			'crypto_com_webhook',
			'nowpayments_ipn',
			'nowpayments_webhook',
			'opennode_webhook',
			'open_node_webhook',
			'alipay_notify',
			'alipay_callback',
			'wechatpay_notify',
			'wechat_pay_notify',
			'wechatpay_callback',
			'dlocal_webhook',
			'paysera_callback',
			'paysera_webhook',
			'payrexx_webhook',
			'trustly_notification',
			'trustly_webhook',
			'klarna_push',
			'klarna_callback',
			'paystack_webhook',
			'flutterwave_webhook',
			'gocardless_webhook',
			'paddle_webhook',
			'eway_callback',
			'worldpay_callback',
			'afterpay_webhook',
			'clearpay_webhook',
			'sezzle_webhook',
			'affirm_webhook',
			'iyzico_callback',
			'ipay_callback',
			'amazon_payments_callback',
			'amazon_pay_callback',
			'apple_pay_callback',
			'google_pay_callback',
			'samsung_pay_callback',
			'mir_pay_callback',
			'qiwi_callback',
			'webmoney_callback',
			'yandex_money_callback',
			'yandex_kassa_callback',
			'yoomoney_callback',
			'postback',
			'payment_postback',
			'gateway_postback',
			'webhook',
			'ipn',
			'gateway_callback',
			'payment_callback',
			'payment_notification',
		);
	}

	public static function getActions(): array {
		return array(
			'paypal_ipn',
			'paypal-ipn',
			'paypal_pdt',
			'paypal_listener',
			'paypal_express_review_order',
			'paypal_express_cancel_order',
			'woocommerce_paypal_listener',
			'ppec_paypal_listener',
			'paypal_braintree_check_nonce',
			'paypal_payment_status',
			'paypal_advanced',
			'paypal_payouts',
			'wpec_paypal_ipn',
			'edd_paypal_ipn',
			'edd_paypal_pdt',
			'gf_paypal_ipn',
			'mepr_paypal_standard_ipn',
			'mepr_paypal_standard_return',
			'rcp_paypal_express_listener',
			'pmpro_paypal_ipn',
			'pmpro_paypal_express_ipn',
			'give_paypal_ipn',
			'give_paypalpro_listener',
			'stripe_webhook',
			'wc_stripe_webhook',
			'wc-stripe-webhook',
			'woocommerce_stripe_webhook',
			'stripe_listener',
			'stripe_payment_intent',
			'stripe_charge',
			'stripe_connect',
			'edd_stripe_event',
			'edd_stripe_listen_for_stripe',
			'gf_stripe_webhook',
			'gf_stripe_listener',
			'mepr_stripe_webhook',
			'rcp_stripe_webhook',
			'pmpro_stripe_webhook',
			'give_stripe_webhook',
			'yookassa_callback',
			'yookassa_notify',
			'yookassa_webhook',
			'wc_yookassa_callback',
			'woocommerce_yookassa_callback',
			'tinkoff_callback',
			'tinkoff_notification',
			'tinkoff_acquiring',
			'wc_tinkoff_callback',
			'tinkoff_pay_callback',
			'cloudpayments_check',
			'cloudpayments_pay',
			'cloudpayments_confirm',
			'cloudpayments_fail',
			'cloudpayments_refund',
			'cloudpayments_recurrent',
			'cloudpayments_callback',
			'wc_cloudpayments_callback',
			'robokassa_result',
			'robokassa_success',
			'robokassa_fail',
			'robokassa_callback',
			'wc_robokassa_callback',
			'sberbank_callback',
			'sberbank_status',
			'sberbank_acquiring',
			'wc_sberbank_callback',
			'sber_callback',
			'liqpay_callback',
			'liqpay_response',
			'liqpay_server_url',
			'wc_liqpay_callback',
			'fondy_callback',
			'fondy_response',
			'wc_fondy_callback',
			'wayforpay_callback',
			'wayforpay_service',
			'wc_wayforpay_callback',
			'mollie_webhook',
			'mollie_return',
			'mollie_payments_webhook',
			'wc_mollie_webhook',
			'adyen_notification',
			'adyen_webhook',
			'wc_adyen_notification',
			'braintree_webhook',
			'wc_braintree_webhook',
			'square_webhook',
			'square_callback',
			'wc_square_webhook',
			'razorpay_webhook',
			'razorpay_callback',
			'wc_razorpay_webhook',
			'authnet_silent_post',
			'authnet_webhook',
			'authorize_net_aim_webhook',
			'2checkout_ins',
			'twocheckout_ins',
			'twocheckout_webhook',
			'wc_twocheckout_webhook',
			'payu_callback',
			'payu_response',
			'payu_listener',
			'wc_payu_callback',
			'wepay_ipn',
			'wepay_callback',
			'wc_wepay_webhook',
			'revolut_webhook',
			'revolut_callback',
			'wc_revolut_webhook',
			'wc_revolut_callback',
			'checkout_com_webhook',
			'checkoutcom_webhook',
			'cko_webhook',
			'wc_checkout_com_webhook',
			'wc_checkoutcom_webhook',
			'wc_cko_webhook',
			'mercadopago_webhook',
			'mercadopago_ipn',
			'mercado_pago_webhook',
			'mercado_pago_ipn',
			'wc_mercadopago_webhook',
			'wc_mercado_pago_webhook',
			'payfast_itn',
			'payfast_notify',
			'payfast_webhook',
			'wc_payfast_itn',
			'wc_payfast_notify',
			'paygate_notify',
			'paygate_callback',
			'wc_paygate_callback',
			'paytm_callback',
			'paytm_webhook',
			'wc_paytm_callback',
			'cashfree_webhook',
			'cashfree_callback',
			'wc_cashfree_webhook',
			'instamojo_webhook',
			'instamojo_callback',
			'wc_instamojo_webhook',
			'ccavenue_response',
			'ccavenue_callback',
			'wc_ccavenue_callback',
			'billdesk_response',
			'billdesk_callback',
			'wc_billdesk_callback',
			'omise_webhook',
			'wc_omise_webhook',
			'xendit_webhook',
			'xendit_callback',
			'wc_xendit_webhook',
			'midtrans_notification',
			'midtrans_callback',
			'wc_midtrans_notification',
			'doku_notify',
			'doku_callback',
			'wc_doku_notify',
			'hitpay_webhook',
			'hitpay_callback',
			'wc_hitpay_webhook',
			'paymongo_webhook',
			'paymongo_callback',
			'wc_paymongo_webhook',
			'dragonpay_callback',
			'dragonpay_postback',
			'wc_dragonpay_callback',
			'pesapal_ipn',
			'pesapal_callback',
			'pesapal_notification',
			'wc_pesapal_callback',
			'mpesa_callback',
			'safaricom_callback',
			'wc_mpesa_callback',
			'dpo_callback',
			'dpopay_callback',
			'wc_dpo_callback',
			'wc_dpopay_callback',
			'yoco_webhook',
			'yoco_callback',
			'wc_yoco_webhook',
			'ozow_notify',
			'ozow_callback',
			'wc_ozow_callback',
			'multisafepay_notify',
			'multisafepay_webhook',
			'wc_multisafepay_notification',
			'wc_multisafepay_webhook',
			'buckaroo_push',
			'buckaroo_webhook',
			'wc_buckaroo_push',
			'paynl_notify',
			'paynl_webhook',
			'wc_paynl_notify',
			'paytrail_callback',
			'paytrail_webhook',
			'wc_paytrail_callback',
			'przelewy24_callback',
			'przelewy24_notification',
			'p24_callback',
			'wc_przelewy24_callback',
			'wc_p24_callback',
			'redsys_notification',
			'redsys_callback',
			'wc_redsys_notification',
			'bizum_notification',
			'bizum_callback',
			'wc_bizum_callback',
			'nexi_notify',
			'nexi_callback',
			'wc_nexi_callback',
			'satispay_webhook',
			'wc_satispay_webhook',
			'vivawallet_webhook',
			'viva_wallet_webhook',
			'wc_vivawallet_webhook',
			'wc_viva_wallet_webhook',
			'unzer_webhook',
			'wc_unzer_webhook',
			'heidelpay_webhook',
			'wc_heidelpay_webhook',
			'worldline_webhook',
			'worldline_callback',
			'wc_worldline_webhook',
			'ingenico_webhook',
			'ingenico_callback',
			'wc_ingenico_webhook',
			'ogone_callback',
			'ogone_webhook',
			'wc_ogone_callback',
			'moneris_callback',
			'moneris_webhook',
			'wc_moneris_callback',
			'elavon_callback',
			'elavon_webhook',
			'converge_callback',
			'wc_elavon_callback',
			'wc_converge_callback',
			'globalpayments_webhook',
			'global_payments_webhook',
			'wc_globalpayments_webhook',
			'wc_global_payments_webhook',
			'firstdata_webhook',
			'first_data_webhook',
			'wc_firstdata_webhook',
			'wc_first_data_webhook',
			'cybersource_webhook',
			'wc_cybersource_webhook',
			'bambora_webhook',
			'wc_bambora_webhook',
			'opayo_callback',
			'opayo_notification',
			'opayo_webhook',
			'wc_opayo_callback',
			'coinbase_commerce_webhook',
			'coinbase_webhook',
			'wc_coinbase_commerce_webhook',
			'coinpayments_ipn',
			'coinpayments_webhook',
			'wc_coinpayments_ipn',
			'bitpay_ipn',
			'bitpay_webhook',
			'wc_bitpay_ipn',
			'cryptocom_webhook',
			'crypto_com_webhook',
			'wc_crypto_com_webhook',
			'nowpayments_ipn',
			'nowpayments_webhook',
			'wc_nowpayments_ipn',
			'opennode_webhook',
			'open_node_webhook',
			'wc_opennode_webhook',
			'alipay_notify',
			'alipay_callback',
			'wc_alipay_callback',
			'wechatpay_notify',
			'wechat_pay_notify',
			'wechatpay_callback',
			'wc_wechatpay_callback',
			'dlocal_webhook',
			'wc_dlocal_webhook',
			'paysera_callback',
			'paysera_webhook',
			'wc_paysera_callback',
			'payrexx_webhook',
			'wc_payrexx_webhook',
			'trustly_notification',
			'trustly_webhook',
			'wc_trustly_notification',
			'afterpay_webhook',
			'wc_afterpay_webhook',
			'clearpay_webhook',
			'wc_clearpay_webhook',
			'sezzle_webhook',
			'wc_sezzle_webhook',
			'affirm_webhook',
			'wc_affirm_webhook',
			'klarna_push',
			'klarna_callback',
			'wc_klarna_push',
			'iyzico_callback',
			'wc_iyzico_callback',
			'ipay_callback',
			'wc_ipay_callback',
			'paystack_webhook',
			'wc_paystack_webhook',
			'flutterwave_webhook',
			'wc_flutterwave_webhook',
			'gocardless_webhook',
			'wc_gocardless_webhook',
			'paddle_webhook',
			'wc_paddle_webhook',
			'eway_callback',
			'wc_eway_callback',
			'sagepay_callback',
			'wc_sagepay_callback',
			'worldpay_callback',
			'wc_worldpay_callback',
			'amazon_payments_callback',
			'wc_amazon_pa_callback',
			'apple_pay_callback',
			'google_pay_callback',
			'samsung_pay_callback',
			'mir_pay_callback',
			'qiwi_callback',
			'wc_qiwi_callback',
			'webmoney_callback',
			'wc_webmoney_callback',
			'yandex_money_callback',
			'wc_yandex_money_callback',
			'subscription_status_changed_via_webhook',
			'gateway_ipn',
			'gateway_callback',
			'gateway_webhook',
			'gateway_notification',
			'payment_callback',
			'payment_webhook',
			'payment_notification',
			'payment_success',
			'payment_failure',
			'payment_status',
			'payment_handler',
			'payment_check',
			'ipn_handler',
			'ipn_listener',
			'webhook_handler',
			'webhook_listener',
			'recurring_callback',
			'recurring_webhook',
			'subscription_callback',
			'subscription_webhook',
		);
	}

	public static function getActionSubstrings(): array {
		return array(
			'_webhook',
			'_ipn',
			'webhook_',
			'ipn_',
			'paypal_',
			'stripe_',
			'mollie_',
			'adyen_',
			'braintree_',
			'square_',
			'razorpay_',
			'yookassa_',
			'tinkoff_',
			'cloudpayments_',
			'robokassa_',
			'sberbank_',
			'liqpay_',
			'fondy_',
			'wayforpay_',
			'revolut_',
			'checkout_com_',
			'checkoutcom_',
			'cko_',
			'mercadopago_',
			'mercado_pago_',
			'payfast_',
			'paygate_',
			'paytm_',
			'cashfree_',
			'instamojo_',
			'ccavenue_',
			'billdesk_',
			'omise_',
			'xendit_',
			'midtrans_',
			'doku_',
			'hitpay_',
			'paymongo_',
			'dragonpay_',
			'pesapal_',
			'mpesa_',
			'safaricom_',
			'dpo_',
			'dpopay_',
			'yoco_',
			'ozow_',
			'multisafepay_',
			'buckaroo_',
			'paynl_',
			'paytrail_',
			'przelewy24_',
			'p24_',
			'redsys_',
			'bizum_',
			'nexi_',
			'satispay_',
			'vivawallet_',
			'viva_wallet_',
			'unzer_',
			'heidelpay_',
			'worldline_',
			'ingenico_',
			'ogone_',
			'moneris_',
			'elavon_',
			'converge_',
			'globalpayments_',
			'global_payments_',
			'firstdata_',
			'first_data_',
			'cybersource_',
			'bambora_',
			'opayo_',
			'coinbase_commerce_',
			'coinbase_',
			'coinpayments_',
			'bitpay_',
			'cryptocom_',
			'crypto_com_',
			'nowpayments_',
			'opennode_',
			'open_node_',
			'alipay_',
			'wechatpay_',
			'wechat_pay_',
			'dlocal_',
			'paysera_',
			'payrexx_',
			'trustly_',
			'afterpay_',
			'clearpay_',
			'sezzle_',
			'affirm_',
			'payment_callback',
			'payment_notification',
			'gateway_callback',
			'gateway_notification',
			'gateway_ipn',
		);
	}

	public static function getSignatureHeaders(): array {
		return array(
			'HTTP_STRIPE_SIGNATURE',
			'HTTP_PAYPAL_TRANSMISSION_SIG',
			'HTTP_PAYPAL_AUTH_ALGO',
			'HTTP_PAYPAL_TRANSMISSION_ID',
			'HTTP_PAYPAL_CERT_URL',
			'HTTP_X_PAYPAL_SIGNATURE',
			'HTTP_X_YOOKASSA_SIGNATURE',
			'HTTP_X_YOOKASSA_EVENT',
			'HTTP_X_TINKOFF_SIGN',
			'HTTP_X_SBERBANK_SIGNATURE',
			'HTTP_X_CLOUDPAYMENTS_HMAC',
			'HTTP_CONTENT_HMAC',
			'HTTP_X_SQUARE_SIGNATURE',
			'HTTP_X_SQUARE_HMACSHA256_SIGNATURE',
			'HTTP_X_RAZORPAY_SIGNATURE',
			'HTTP_X_ADYEN_SIGNATURE',
			'HTTP_X_MOLLIE_SIGNATURE',
			'HTTP_X_BRAINTREE_SIGNATURE',
			'HTTP_BRAINTREE_SIGNATURE',
			'HTTP_X_AUTHORIZENET_SIGNATURE',
			'HTTP_X_PAYSTACK_SIGNATURE',
			'HTTP_X_FLUTTERWAVE_SIGNATURE',
			'HTTP_X_KLARNA_SIGNATURE',
			'HTTP_X_GOCARDLESS_WEBHOOK_SIGNATURE',
			'HTTP_PADDLE_SIGNATURE',
			'HTTP_X_PADDLE_SIGNATURE',
			'HTTP_X_EWAY_SIGNATURE',
			'HTTP_X_WORLDPAY_SIGNATURE',
			'HTTP_X_SAGEPAY_SIGNATURE',
			'HTTP_X_2CO_SIGNATURE',
			'HTTP_REVOLUT_SIGNATURE',
			'HTTP_X_REVOLUT_SIGNATURE',
			'HTTP_CKO_SIGNATURE',
			'HTTP_CHECKOUT_SIGNATURE',
			'HTTP_CHECKOUT_COM_SIGNATURE',
			'HTTP_X_CHECKOUT_SIGNATURE',
			'HTTP_X_CHECKOUT_COM_SIGNATURE',
			'HTTP_X_MERCADOPAGO_SIGNATURE',
			'HTTP_X_MERCADO_PAGO_SIGNATURE',
			'HTTP_X_PAYFAST_SIGNATURE',
			'HTTP_X_PAYGATE_SIGNATURE',
			'HTTP_X_PAYTM_CHECKSUM',
			'HTTP_X_CASHFREE_SIGNATURE',
			'HTTP_X_INSTAMOJO_SIGNATURE',
			'HTTP_X_CCAVENUE_SIGNATURE',
			'HTTP_X_BILLDESK_SIGNATURE',
			'HTTP_X_OMISE_SIGNATURE',
			'HTTP_X_XENDIT_SIGNATURE',
			'HTTP_X_CALLBACK_TOKEN',
			'HTTP_X_MIDTRANS_SIGNATURE',
			'HTTP_X_DOKU_SIGNATURE',
			'HTTP_X_HITPAY_SIGNATURE',
			'HTTP_PAYMONGO_SIGNATURE',
			'HTTP_X_PAYMONGO_SIGNATURE',
			'HTTP_X_DRAGONPAY_SIGNATURE',
			'HTTP_X_PESAPAL_SIGNATURE',
			'HTTP_X_MPESA_SIGNATURE',
			'HTTP_X_SAFARICOM_SIGNATURE',
			'HTTP_X_DPO_SIGNATURE',
			'HTTP_X_DPOPAY_SIGNATURE',
			'HTTP_X_YOCO_SIGNATURE',
			'HTTP_X_OZOW_SIGNATURE',
			'HTTP_X_MULTISAFEPAY_SIGNATURE',
			'HTTP_X_BUCKAROO_SIGNATURE',
			'HTTP_X_PAYNL_SIGNATURE',
			'HTTP_X_PAYTRAIL_SIGNATURE',
			'HTTP_X_P24_SIGNATURE',
			'HTTP_X_PRZELEWY24_SIGNATURE',
			'HTTP_X_REDSYS_SIGNATURE',
			'HTTP_X_BIZUM_SIGNATURE',
			'HTTP_X_NEXI_SIGNATURE',
			'HTTP_X_SATISPAY_SIGNATURE',
			'HTTP_X_VIVAWALLET_SIGNATURE',
			'HTTP_X_VIVA_WALLET_SIGNATURE',
			'HTTP_X_UNZER_SIGNATURE',
			'HTTP_X_HEIDELPAY_SIGNATURE',
			'HTTP_X_WORLDLINE_SIGNATURE',
			'HTTP_X_INGENICO_SIGNATURE',
			'HTTP_X_OGONE_SIGNATURE',
			'HTTP_X_MONERIS_SIGNATURE',
			'HTTP_X_ELAVON_SIGNATURE',
			'HTTP_X_CONVERGE_SIGNATURE',
			'HTTP_X_GLOBALPAYMENTS_SIGNATURE',
			'HTTP_X_GLOBAL_PAYMENTS_SIGNATURE',
			'HTTP_X_FIRSTDATA_SIGNATURE',
			'HTTP_X_FIRST_DATA_SIGNATURE',
			'HTTP_X_CYBERSOURCE_SIGNATURE',
			'HTTP_X_BAMBORA_SIGNATURE',
			'HTTP_X_OPAYO_SIGNATURE',
			'HTTP_X_COINBASE_SIGNATURE',
			'HTTP_X_CC_WEBHOOK_SIGNATURE',
			'HTTP_X_COINPAYMENTS_SIGNATURE',
			'HTTP_X_BITPAY_SIGNATURE',
			'HTTP_X_CRYPTO_COM_SIGNATURE',
			'HTTP_X_NOWPAYMENTS_SIG',
			'HTTP_X_NOWPAYMENTS_SIGNATURE',
			'HTTP_X_OPENNODE_SIGNATURE',
			'HTTP_X_ALIPAY_SIGNATURE',
			'HTTP_X_WECHATPAY_SIGNATURE',
			'HTTP_X_WECHAT_PAY_SIGNATURE',
			'HTTP_X_DLOCAL_SIGNATURE',
			'HTTP_X_PAYSERA_SIGNATURE',
			'HTTP_X_PAYREXX_SIGNATURE',
			'HTTP_X_TRUSTLY_SIGNATURE',
			'HTTP_X_AFTERPAY_SIGNATURE',
			'HTTP_X_CLEARPAY_SIGNATURE',
			'HTTP_X_SEZZLE_SIGNATURE',
			'HTTP_X_AFFIRM_SIGNATURE',
			'HTTP_X_WEBHOOK_SIGNATURE',
			'HTTP_X_PAYMENT_SIGNATURE',
			'HTTP_X_GATEWAY_SIGNATURE',
			'HTTP_X_HOOK_SIGNATURE',
		);
	}

	public static function getUserAgents(): array {
		return array(
			'Stripe/',
			'Stripe ',
			'PayPal IPN',
			'PayPal-Webhook',
			'PayPal/',
			'Mollie',
			'Adyen',
			'Braintree',
			'Square-',
			'Razorpay',
			'YooMoney',
			'YooKassa',
			'CloudPayments',
			'Robokassa',
			'Tinkoff',
			'Sberbank',
			'WayForPay',
			'LiqPay',
			'Fondy',
			'Klarna',
			'Paystack',
			'Flutterwave',
			'GoCardless',
			'Paddle',
			'2Checkout',
			'Authorize.Net',
			'Payment-Notification',
			'Webhook-Notification',
			'Revolut',
			'Checkout.com',
			'CheckoutCom',
			'MercadoPago',
			'Mercado Pago',
			'PayFast',
			'PayGate',
			'Paytm',
			'Cashfree',
			'Instamojo',
			'CCAvenue',
			'BillDesk',
			'Omise',
			'Xendit',
			'Midtrans',
			'DOKU',
			'HitPay',
			'PayMongo',
			'Dragonpay',
			'Pesapal',
			'M-Pesa',
			'Safaricom',
			'DPO Pay',
			'DPO',
			'Yoco',
			'Ozow',
			'MultiSafepay',
			'Buckaroo',
			'Pay.nl',
			'Paytrail',
			'Przelewy24',
			'P24',
			'Redsys',
			'Bizum',
			'Nexi',
			'Satispay',
			'Viva Wallet',
			'VivaWallet',
			'Unzer',
			'Heidelpay',
			'Worldline',
			'Ingenico',
			'Ogone',
			'Moneris',
			'Elavon',
			'Converge',
			'GlobalPayments',
			'Global Payments',
			'FirstData',
			'First Data',
			'CyberSource',
			'Bambora',
			'Opayo',
			'SagePay',
			'Coinbase Commerce',
			'Coinbase',
			'CoinPayments',
			'BitPay',
			'Crypto.com',
			'NOWPayments',
			'OpenNode',
			'Alipay',
			'WeChat Pay',
			'WeChatPay',
			'dLocal',
			'Paysera',
			'Payrexx',
			'Trustly',
			'Afterpay',
			'Clearpay',
			'Sezzle',
			'Affirm',
			'Iyzico',
			'iPay',
			'Amazon Pay',
			'Apple Pay',
			'Google Pay',
			'Samsung Pay',
			'Mir Pay',
			'Qiwi',
			'WebMoney',
			'Yandex Money',
		);
	}

	public static function getEcommercePluginClasses(): array {
		return array(
			'WooCommerce',
			'Easy_Digital_Downloads',
			'WP_eCommerce',
			'Jigoshop',
			'Shopp',
			'Give',
			'MeprCtrlFactory',
			'RCP_Member',
			'Paid_Memberships_Pro',
			'WooCommerce_Subscriptions',
			'WC_Subscriptions',
			'SureCart\\Plugin',
			'Cart66Cloud',
			'WPEasyCart',
			'Ecwid_Shopping_Cart',
			'EDD_Recurring',
			'WPInv_Plugin',
			'GetPaid',
			'TutorLMS\\Tutor',
			'LearnDash_Settings_Section',
			'WC_Vendors',
			'WCFM',
			'WeDevs_Dokan',
			'CartFlows',
			'FunnelKit\\WooFunnels',
		);
	}

	public static function getEcommercePluginConstants(): array {
		return array(
			'WC_PLUGIN_FILE',
			'WC_VERSION',
			'EDD_VERSION',
			'EDD_PLUGIN_FILE',
			'WPSC_VERSION',
			'JIGOSHOP_VERSION',
			'SHOPP_VERSION',
			'GIVE_VERSION',
			'MEPR_VERSION',
			'RCP_PLUGIN_VERSION',
			'PMPRO_VERSION',
			'WCS_INIT_TIMESTAMP',
			'SURECART_PLUGIN_FILE',
			'WPINV_VERSION',
			'GETPAID_VERSION',
		);
	}

	public static function detectEcommerce(): bool {
		foreach ( self::getEcommercePluginClasses() as $class ) {
			if ( class_exists( $class ) ) {
				return true;
			}
		}
		foreach ( self::getEcommercePluginConstants() as $const ) {
			if ( defined( $const ) ) {
				return true;
			}
		}
		if ( function_exists( 'is_plugin_active' ) ) {
			$slugs = array(
				'woocommerce/woocommerce.php',
				'easy-digital-downloads/easy-digital-downloads.php',
				'easy-digital-downloads-pro/easy-digital-downloads.php',
				'wp-e-commerce/wp-shopping-cart.php',
				'jigoshop/jigoshop.php',
				'shopp/Shopp.php',
				'give/give.php',
				'memberpress/memberpress.php',
				'restrict-content-pro/restrict-content-pro.php',
				'paid-memberships-pro/paid-memberships-pro.php',
				'woocommerce-subscriptions/woocommerce-subscriptions.php',
				'surecart/surecart.php',
				'wpeasycart/wpeasycart.php',
				'ecwid-shopping-cart/ecwid-shopping-cart.php',
				'invoicing/invoicing.php',
				'wp-invoicing/wp-invoicing.php',
				'cart66-cloud/cart66-cloud.php',
				'dokan-lite/dokan.php',
				'wc-vendors/class-wc-vendors.php',
				'wc-frontend-manager/wc_frontend_manager.php',
				'cartflows/cartflows.php',
				'funnel-builder/funnel-builder.php',
			);
			foreach ( $slugs as $slug ) {
				if ( is_plugin_active( $slug ) ) {
					return true;
				}
			}
		}
		return false;
	}

}
