mikew
October 12, 2021, 6:39pm
1
Your software
My Mautic version is: 4.0.1
My PHP version is: 7.4
My Database type and version is:
Your problem
My problem is:
I am trying to setup a simple web hook action inside a campaign.
When I do this in the 4.0.1 environment and fire off the campaign it fails and I see this error:
Last execution error: Passing in the “body” request option as an array to send a request is not supported. Please use the “form_params” request option to send a application/x-www-form-urlencoded request, or the “multipart” request option to send a multipart/form-data request.
I then went and tested this from a 3.x installation and everything worked perfectly.
@rcheesley where should this be documented ?
1 Like
@mikew I think that it would probably sit in the developer docs under the Webhooks section.
@alanhartless is just doing some work on refactoring and moving it over to Read the Docs though, so maybe drop him a line on Slack?
This reads more like a bug. That error message is likely coming from the client the campaign code is using to deliver the request. It’s possible an upgrade to a dependency in M4 changed something.
@mikew can you provide a screenshot of your campaign action ( mask or remove anything sensitive).
mikew
October 17, 2021, 7:10am
4
HI @alanhartless1
I used the most simple web hook, no authentication, tried putting in values in both header and data with same results:
mikew
November 5, 2021, 8:53am
5
Hey @alanhartless1
Here are some of the errors I am seeing:
and this is what I was seeing in the system log:
[2021-11-05 04:35:58] mautic.NOTICE: PHP Notice - SessionHandler::gc(): ps_files_cleanup_dir: opendir(/var/lib/php/sessions) failed: Permission denied (13) - in file /var/www/mautic/vendor/symfony/http-foundation/Session/Storage/Handler/StrictSessionHandler.php - at line 106 {"maxlifetime":1440} []
[2021-11-05 07:17:38] mautic.NOTICE: PHP Notice - SessionHandler::gc(): ps_files_cleanup_dir: opendir(/var/lib/php/sessions) failed: Permission denied (13) - in file /var/www/mautic/vendor/symfony/http-foundation/Session/Storage/Handler/StrictSessionHandler.php - at line 106 {"maxlifetime":1440} []
[2021-11-05 07:28:14] mautic.NOTICE: PHP Notice - Undefined index: path - in file /var/www/mautic/app/bundles/CoreBundle/Controller/ExceptionController.php - at line 120 {"request":"[object] (Symfony\\Component\\HttpFoundation\\Request: GET //console HTTP/1.1\r\nAccept-Encoding: gzip\r\nConnection: close\r\nContent-Length: \r\nContent-Type: \r\nHost: ams.rocketpot.io\r\nReferer: https://161.35.210.173:443/console/\r\nUser-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/78.0.3904.108 Safari/537.36\r\nX-Php-Ob-Level: 1\r\n\r\n)","exception":"[object] (Symfony\\Component\\Debug\\Exception\\FlattenException: {})","logger":null,"class":"Symfony\\Component\\HttpKernel\\Exception\\NotFoundHttpException","currentContent":"","layout":"Error","code":404,"anonymous":true,"baseTemplate":"MauticCoreBundle:Default:slim.html.php","templatePage":false,"template":"MauticCoreBundle:Error:404.html.php","templating":"[object] (Symfony\\Bundle\\FrameworkBundle\\Templating\\DelegatingEngine: {})","statusText":"Not Found","url":"//console","urlParts":{"host":"console"}} []
[2021-11-05 08:39:53] mautic.WARNING: PHP Warning - html_entity_decode() expects parameter 1 to be string, array given - in file /var/www/mautic/app/bundles/CoreBundle/Helper/AbstractFormFieldHelper.php - at line 204 {"list":[{"label":{"label":"","value":""},"value":0}],"choices":[],"label":{"label":"","value":""},"value":0} []
[2021-11-05 08:40:02] mautic.WARNING: PHP Warning - html_entity_decode() expects parameter 1 to be string, array given - in file /var/www/mautic/app/bundles/CoreBundle/Helper/AbstractFormFieldHelper.php - at line 204 {"list":[{"label":{"label":"","value":""},"value":0}],"choices":[],"label":{"label":"","value":""},"value":0} []