Exploriment / hcloud-php

PHP library for the Hetzner Cloud API by Exploriment
MIT License
28 stars 8 forks source link

Invalid input: root must be an object #2

Closed Vladdy88 closed 6 years ago

Vladdy88 commented 6 years ago

I tried to implement the reboot and shutdown method from HetznerCloud\Servers but I keep getting the error : exception 'Exploriment\HetznerCloud\Exceptions\ApiInvalidInput' with message 'invalid input: root must be an object' in /home/hvbeta/public_html/modules/addons/hv_hetzner/vendor/exploriment/hcloud-php/src/Http.php:123 I tried to check the input of the request method from Http class and it looks ok :

string(6) "597685" string(31) "servers/597685/actions/shutdown" 
array(0) { } 
array(0) { } 

I also tried the API from Hetzner directly with curl and it works, so the problem must be somewhere at the method that sends the request, but I cannot figure out where.

dyhli commented 6 years ago

Should be fixed!

Vladdy88 commented 6 years ago

Yes, it works now! Thank you again!