TypeError thrown

json_decode(): Argument #1 ($json) must be of type string, WP_Error given