Ejemplo n.º 1
0
 /**
  * Gets the default currency id for the asigned country
  */
 function get_default_currency($country_id = null)
 {
     $mp = new MPShop();
     $url = "https://api.mercadolibre.com/sites/" . $country_id;
     $header = array('Accept: application/json');
     $mp_site = $mp->DoPost(null, $url, $header, '200', 'none', 'get');
     return $mp_site["default_currency_id"];
 }
Ejemplo n.º 2
0
 public function GetMethods($country_id = null)
 {
     $mp = new MPShop();
     $url = "https://api.mercadolibre.com/sites/" . $country_id . "/payment_methods";
     $header = array('Accept: application/json');
     $methods = $mp->DoPost(null, $url, $header, '200', 'none', 'get');
     return $methods;
 }