How to get the list of registered countries via API?

URL: http://www.namedoseusite.com.br/api_ds_products_ots.php?action=Countries





Header Parameter format
token base64_encode ()
Secret base64_encode ()
email base64_encode ()

Php Sample:

  // sample country

$ URL = $ tabain_url. ' /API_DS_Products_Ors.php? Action = Countries ' ;;

$ CH = curl_init ($ URL);
Curl_Setopt ($ CH, Curlopt_Returntransfer, True);
curl_setopt ($ CH, curlopt_ssl_verifypeer, false);
Curl_Setopt ($ CH, Curlopt_httpheader, Array (
' CONTENT-TYPE: Application/JSON ',
"Cache-Control: No-Cache",
' TOKEN: ' . base64_encode ($ token),
' Secret: ' . base64_encode ($ secret),
' E-mail: ' . base64_encode ($ email),
' CONTENT-LENGTH: ' . Strlen ($ data_string)))
);

$ result = curl_exec ($ CH);
Curl_Close ($ CH);

print_r ($ result);

// sample EOF Countries

return:

id
Text

Leave a Reply 0