I couldn't get a new token from the refresh token using the function in the sdk nor the example code here.
so to make it work I had to:
1) Modify the function getAccessTokenFromRefreshToken on meli.php
adding
$result = $result['json'];
before the result so that it could return the correct information, otherwise it couldn't get to the values in the return
2) When getting the array back with the new token, I did not only have to set the new token, but also the user id so that the SDK would take and work with the new tokem
I couldn't get a new token from the refresh token using the function in the sdk nor the example code here.
so to make it work I had to:
1) Modify the function getAccessTokenFromRefreshToken on meli.php adding
$result = $result['json']; before the result so that it could return the correct information, otherwise it couldn't get to the values in the return
2) When getting the array back with the new token, I did not only have to set the new token, but also the user id so that the SDK would take and work with the new tokem
$accessToken = $meli->getAccessTokenFromRefreshToken($refresh_token);
I hope this helps someone else with the same issue I had.