This is the code I am using (made from example provided on the web of mercadopago ):
require_once ( 'mercadopago.php');
$mp = new MP('xxxxxxxxxxx', 'xxxxxxxxxxxxxxxxxxxxxxxxxx');
$params = array(
"dimensions" => "30x30x30,500",
"zip_code" => "5700",
"item_price"=>"100.58",
"free_method" => "73328" // optional
);
$response = $mp->get("/shipping_options", $params);
print_r($response);
I am getting the following error in the print_r($response)
when trying to connect with the mercadopago API, specifically to $mp->get("/shipping_options", $params);
:
Array (
[status] => 400
[response] => Array (
[message] => Malformed access_token: null
[error] => bad_request
[status] => 400
[cause] => Array ( )
)
)
Does anyone know what happens? How can I solve this problem?