"Received unknown parameter: api_version"
Upon installing Stripe 5.4, the error above is triggered on any System.check
call. Stripe returns a 400 error of type "parameter unknown".
Since it fails during an API call, there's an unformatted backtrace available, but it's difficult to sanitize. I'm including the limited backtrace here:
Jul 16 07:03:58 [info] $backTrace = #0 /var/www/example.megaphonetech.com/htdocs/sites/all/modules/civicrm/CRM/Core/Error.php(463): CRM_Core_Error::backtrace("backTrace", TRUE)
#1 /var/www/example.megaphonetech.com/htdocs/sites/all/modules/civicrm/CRM/Core/Invoke.php(55): CRM_Core_Error::handleUnhandledException(Object(Stripe\Error\InvalidRequest))
#2 /var/www/example.megaphonetech.com/htdocs/sites/all/modules/civicrm/drupal/civicrm.module(444): CRM_Core_Invoke::invoke((Array:1))
#3 /var/www/example.megaphonetech.com/htdocs/includes/menu.inc(527): civicrm_invoke()
#4 /var/www/example.megaphonetech.com/htdocs/index.php(21): menu_execute_active_handler()
#5 {main}
Here's a relevant portion of the unformatted backtrace:
array(6) {
["file"]=>
string(131) "/var/www/example.megaphonetech.com/htdocs/sites/all/civicrm-custom/extensions/com.drastikbydesign.stripe/CRM/Stripe/Webhook.php"
["line"]=>
int(51)
["function"]=>
string(21) "checkAndUpdateWebhook"
["class"]=>
string(18) "CRM_Stripe_Webhook"
["type"]=>
string(2) "::"
["args"]=>
array(1) {
[0]=>
object(Stripe\WebhookEndpoint)#411 (9) {
["id"]=>
string(27) "<redacted>"
["object"]=>
string(16) "webhook_endpoint"
["api_version"]=>
string(10) "2019-03-14"
["application"]=>
NULL
["created"]=>
int(1558111760)
["enabled_events"]=>
array(1) {
[0]=>
string(1) "*"
}
["livemode"]=>
bool(false)
["status"]=>
string(7) "enabled"
["url"]=>
string(59) "https://example.megaphonetech.com/civicrm/payment/ipn/2"
}
}
}